Repository: cybercongress/go-cyber Branch: main Commit: 11938962e29c Files: 582 Total size: 7.9 MB Directory structure: gitextract__ww5i2x0/ ├── .dockerignore ├── .gitattributes ├── .github/ │ ├── ISSUE_TEMPLATE/ │ │ ├── bug_report.md │ │ ├── feature_request.md │ │ └── gitcoin-issue-template.md │ └── tests.yml ├── .gitignore ├── .golangci.yml ├── .goreleaser.yml ├── CHANGELOG.md ├── CONTRIBUTING.md ├── Dockerfile ├── LICENSE ├── Makefile ├── README.md ├── app/ │ ├── ante.go │ ├── app.go │ ├── apptesting/ │ │ ├── events.go │ │ └── test_suite.go │ ├── encoding.go │ ├── export.go │ ├── forks.go │ ├── genesis.go │ ├── helpers/ │ │ ├── contracts.go │ │ ├── global_errors.go │ │ └── mock.go │ ├── keepers/ │ │ ├── keepers.go │ │ └── keys.go │ ├── modules.go │ ├── params/ │ │ ├── const.go │ │ ├── encoding.go │ │ └── weights.go │ ├── prefix.go │ ├── proof_exempt.go │ ├── proof_exempt_test.go │ ├── test_helpers.go │ └── upgrades/ │ ├── types.go │ ├── v2/ │ │ ├── constants.go │ │ └── upgrades.go │ ├── v3/ │ │ ├── constants.go │ │ └── upgrades.go │ ├── v4/ │ │ ├── constants.go │ │ └── upgrades.go │ ├── v5/ │ │ ├── constants.go │ │ └── forks.go │ ├── v6/ │ │ ├── burn.go │ │ ├── constants.go │ │ └── upgrades.go │ └── v7/ │ ├── constants.go │ └── upgrades.go ├── buf.work.yaml ├── client/ │ └── docs/ │ ├── docs.go │ ├── static/ │ │ └── openapi.yml │ ├── swagger.yaml │ └── template/ │ └── index.tpl ├── cmd/ │ ├── cyber/ │ │ ├── cmd/ │ │ │ └── root.go │ │ └── main.go │ └── iavltool/ │ ├── README.md │ ├── cmd/ │ │ └── root.go │ └── main.go ├── contrib/ │ ├── Dockerfile │ ├── devtools/ │ │ ├── Makefile │ │ ├── dockerfile │ │ └── proto-tools-installer.sh │ ├── links-load.sh │ ├── localnet-blocks-test.sh │ ├── reset-chain.sh │ └── single-node.sh ├── docker-compose.yml ├── docs/ │ ├── README.md │ ├── cyber_ledger_guide.md │ ├── cyberlink_content.md │ ├── deploy_contract.md │ ├── help/ │ │ └── problem_to_install_drivers.md │ ├── keystore.md │ ├── menu/ │ │ └── index.md │ ├── multisig_guide.md │ ├── port_forwarding_guide.md │ ├── proto/ │ │ ├── proto-docs.md │ │ └── protodoc-markdown.tmpl │ ├── rpc.md │ ├── run_validator.md │ ├── send_txs.md │ ├── setup_cyber_configuration.md │ ├── setup_dev_env.md │ ├── soft2-soft3-concepts.md │ ├── supported_gpu_list.md │ ├── ultimate_commands_guide.md │ └── upgrade-plan.md ├── entrypoint.sh ├── go.mod ├── go.sum ├── merkle/ │ ├── node.go │ ├── proof.go │ ├── subtree.go │ ├── tree.go │ ├── tree_test.go │ └── util.go ├── networks/ │ ├── bostrom/ │ │ ├── cyberfrey-upgrade-guide.md │ │ ├── deploy_node_from_snapshot.md │ │ ├── genesis-validator.md │ │ ├── genesis.json │ │ ├── gentxs/ │ │ │ ├── bloqhub.json │ │ │ ├── gentx-0base.vc.json │ │ │ ├── gentx-39a20a7d84c6e91c6638f5a685a13f655e050ee0.json │ │ │ ├── gentx-5b59d7daadd971a9613b2efcc3c6eab0777f5f29.json │ │ │ ├── gentx-5e8522bef5ceca507e05aa0d5f67f37a70222c73.json │ │ │ ├── gentx-77d27615009fc703ece46901792cc8750cccd0de.json │ │ │ ├── gentx-822b374bf2ca56c49fd565d149cd7cb6d175d8cb.json │ │ │ ├── gentx-902fb751851e474133ee4ba1e646f49237b50edf.json │ │ │ ├── gentx-Amber.json │ │ │ ├── gentx-Bro_n_Bro.json │ │ │ ├── gentx-Hailbiafra.json │ │ │ ├── gentx-MindPool.json │ │ │ ├── gentx-Nett.json │ │ │ ├── gentx-NodeMarsel.json │ │ │ ├── gentx-Node_masters.json │ │ │ ├── gentx-P2P.ORG.json │ │ │ ├── gentx-PLap.json │ │ │ ├── gentx-POSTHUMAN.json │ │ │ ├── gentx-StakeAngle.json │ │ │ ├── gentx-a99b8bcb07d027895bcc2abe6baa866174b5ec23.json │ │ │ ├── gentx-alinode.json │ │ │ ├── gentx-blue.json │ │ │ ├── gentx-citizen-cosmos.json │ │ │ ├── gentx-csaxial.json │ │ │ ├── gentx-dd4dd317f85209964232cbbe772c242c50bbbe58.json │ │ │ ├── gentx-dobry.json │ │ │ ├── gentx-f1b4b596730ed81d33dbcf051870f0b7b50d6306.json │ │ │ ├── gentx-goto5k.json │ │ │ ├── gentx-kiwi.json │ │ │ ├── gentx-qwertys318.json │ │ │ ├── gentx-spectrum.json │ │ │ ├── gentx-sta.json │ │ │ └── gentx.json │ │ ├── peers.md │ │ ├── unsigned-genesis.json │ │ ├── v3-upgrade-guide.md │ │ └── v4-upgrade-guide.md │ └── space-pussy/ │ ├── deploy_node_from_snapshot.md │ ├── genesis-validator.md │ ├── genesis.json │ ├── gentxs/ │ │ ├── bloqhub.json │ │ ├── gentx-Citizen-Cosmos.json │ │ ├── gentx-Developer.json │ │ ├── gentx-Kerman.json │ │ ├── gentx-MikeLitoris.json │ │ ├── gentx-POSTHUMAN.json │ │ ├── gentx-Papsan.json │ │ ├── gentx-SAMPLE.json │ │ ├── gentx-Stigga.json │ │ ├── gentx-ToTheMars.json │ │ ├── gentx-Traneco.json │ │ ├── gentx-bro-n-bro.json │ │ ├── gentx-chainmaniacs.json │ │ ├── gentx-cyberG.json │ │ ├── gentx-denwer.json │ │ ├── gentx-goto5k.json │ │ ├── gentx-joy_prophet.json │ │ ├── gentx-linak.json │ │ ├── gentx-lux8net.json │ │ ├── gentx-space.json │ │ ├── gentx-web34ever.json │ │ └── mimino.json │ ├── get_peers/ │ │ ├── getpeers.nu │ │ └── getpeers.sh │ ├── peers.md │ ├── pussy_snapshot_deploy_guide.md │ └── unsigned-genesis.json ├── plugins/ │ ├── types/ │ │ ├── custom_querier.go │ │ ├── dispatch_msg.go │ │ ├── stargate_querier.go │ │ ├── stargate_queries.go │ │ └── types.go │ └── wasm.go ├── proto/ │ ├── buf.gen.doc.yaml │ ├── buf.gen.gogo.yaml │ ├── buf.gen.swagger.yaml │ ├── buf.yaml │ ├── cyber/ │ │ ├── bandwidth/ │ │ │ └── v1beta1/ │ │ │ ├── genesis.proto │ │ │ ├── query.proto │ │ │ ├── tx.proto │ │ │ └── types.proto │ │ ├── clock/ │ │ │ └── v1/ │ │ │ ├── clock.proto │ │ │ ├── genesis.proto │ │ │ ├── query.proto │ │ │ └── tx.proto │ │ ├── dmn/ │ │ │ └── v1beta1/ │ │ │ ├── genesis.proto │ │ │ ├── query.proto │ │ │ ├── tx.proto │ │ │ └── types.proto │ │ ├── graph/ │ │ │ └── v1beta1/ │ │ │ ├── query.proto │ │ │ ├── tx.proto │ │ │ └── types.proto │ │ ├── grid/ │ │ │ └── v1beta1/ │ │ │ ├── genesis.proto │ │ │ ├── query.proto │ │ │ ├── tx.proto │ │ │ └── types.proto │ │ ├── liquidity/ │ │ │ └── v1beta1/ │ │ │ ├── genesis.proto │ │ │ ├── liquidity.proto │ │ │ ├── query.proto │ │ │ └── tx.proto │ │ ├── rank/ │ │ │ └── v1beta1/ │ │ │ ├── genesis.proto │ │ │ ├── pagination.proto │ │ │ ├── query.proto │ │ │ ├── tx.proto │ │ │ └── types.proto │ │ └── resources/ │ │ └── v1beta1/ │ │ ├── genesis.proto │ │ ├── query.proto │ │ ├── tx.proto │ │ └── types.proto │ └── osmosis/ │ └── tokenfactory/ │ └── v1beta1/ │ ├── authority_metadata.proto │ ├── genesis.proto │ ├── params.proto │ ├── query.proto │ └── tx.proto ├── scripts/ │ ├── install_cyber.sh │ ├── merge_protoc.py │ ├── protoc_swagger_openapi_gen.sh │ └── protocgen.sh ├── start_script.sh ├── types/ │ ├── account.go │ └── coins.go ├── utils/ │ ├── context.go │ └── io.go └── x/ ├── bandwidth/ │ ├── abci.go │ ├── client/ │ │ └── cli/ │ │ └── query.go │ ├── exported/ │ │ └── exported.go │ ├── keeper/ │ │ ├── blocks.go │ │ ├── genesis.go │ │ ├── grpc_query.go │ │ ├── keeper.go │ │ ├── migrator.go │ │ ├── msg_server.go │ │ └── snapshotter.go │ ├── migrations/ │ │ └── v2/ │ │ └── migrate.go │ ├── module.go │ ├── spec/ │ │ ├── 00_concepts.md │ │ ├── 01_api.md │ │ ├── 02_state.md │ │ ├── 03_state_transitions.md │ │ ├── 06_params.md │ │ ├── 07_wasm.md │ │ ├── 08_errors.md │ │ ├── 09_cli.md │ │ └── README.md │ ├── types/ │ │ ├── codec.go │ │ ├── errors.go │ │ ├── expected_keepers.go │ │ ├── genesis.go │ │ ├── genesis.pb.go │ │ ├── keys.go │ │ ├── msgs.go │ │ ├── params.go │ │ ├── params_legacy.go │ │ ├── query.pb.go │ │ ├── query.pb.gw.go │ │ ├── tx.pb.go │ │ └── types.pb.go │ └── wasm/ │ └── interface.go ├── clock/ │ ├── README.md │ ├── abci.go │ ├── abci_test.go │ ├── client/ │ │ └── cli/ │ │ ├── query.go │ │ └── tx.go │ ├── genesis.go │ ├── genesis_test.go │ ├── keeper/ │ │ ├── clock.go │ │ ├── keeper.go │ │ ├── keeper_test.go │ │ ├── msg_server.go │ │ ├── msg_server_test.go │ │ ├── querier.go │ │ └── querier_test.go │ ├── module.go │ ├── spec/ │ │ ├── 01_concepts.md │ │ ├── 02_state.md │ │ ├── 03_integration.md │ │ ├── 04_clients.md │ │ └── README.md │ └── types/ │ ├── clock.pb.go │ ├── codec.go │ ├── codec_test.go │ ├── errors.go │ ├── genesis.pb.go │ ├── keys.go │ ├── msgs.go │ ├── msgs_test.go │ ├── params.go │ ├── params_test.go │ ├── query.pb.go │ ├── query.pb.gw.go │ ├── tx.pb.go │ └── tx.pb.gw.go ├── cyberbank/ │ ├── abci.go │ ├── keeper/ │ │ ├── genesis.go │ │ ├── keeper.go │ │ ├── proxy.go │ │ └── snapshotter.go │ ├── module.go │ ├── spec/ │ │ ├── 00_concepts.md │ │ ├── 02_state.md │ │ ├── 03_state_transitions.md │ │ └── README.md │ └── types/ │ ├── expected_keepers.go │ ├── hook.go │ └── keys.go ├── dmn/ │ ├── abci.go │ ├── client/ │ │ └── cli/ │ │ └── query.go │ ├── exported/ │ │ └── exported.go │ ├── keeper/ │ │ ├── genesis.go │ │ ├── grpc_query.go │ │ ├── keeper.go │ │ ├── migrator.go │ │ └── msg_server.go │ ├── migrations/ │ │ └── v2/ │ │ └── migrate.go │ ├── module.go │ ├── types/ │ │ ├── codec.go │ │ ├── errors.go │ │ ├── events.go │ │ ├── expected_keepers.go │ │ ├── genesis.go │ │ ├── genesis.pb.go │ │ ├── keys.go │ │ ├── msgs.go │ │ ├── params.go │ │ ├── params_legacy.go │ │ ├── querier.go │ │ ├── query.pb.go │ │ ├── query.pb.gw.go │ │ ├── thought.go │ │ ├── tx.pb.go │ │ └── types.pb.go │ └── wasm/ │ └── interface.go ├── graph/ │ ├── abci.go │ ├── client/ │ │ └── cli/ │ │ ├── query.go │ │ └── tx.go │ ├── keeper/ │ │ ├── genesis.go │ │ ├── graph.go │ │ ├── grpc_query.go │ │ ├── index.go │ │ ├── msg_server.go │ │ ├── neudeg.go │ │ ├── particles.go │ │ └── snapshotter.go │ ├── module.go │ ├── types/ │ │ ├── codec.go │ │ ├── compact_link.go │ │ ├── cyberlinks.go │ │ ├── errors.go │ │ ├── events.go │ │ ├── keys.go │ │ ├── msgs.go │ │ ├── particles_filter.go │ │ ├── querier.go │ │ ├── query.pb.go │ │ ├── query.pb.gw.go │ │ ├── tx.pb.go │ │ └── types.pb.go │ └── wasm/ │ └── interface.go ├── grid/ │ ├── client/ │ │ └── cli/ │ │ ├── query.go │ │ └── tx.go │ ├── exported/ │ │ └── exported.go │ ├── keeper/ │ │ ├── genesis.go │ │ ├── grpc_query.go │ │ ├── keeper.go │ │ ├── migrator.go │ │ └── msg_server.go │ ├── migrations/ │ │ └── v2/ │ │ └── migrate.go │ ├── module.go │ ├── spec/ │ │ ├── 00_concepts.md │ │ ├── 01_api.md │ │ ├── 02_state.md │ │ ├── 03_state_transitions.md │ │ ├── 04_messages.md │ │ ├── 05_events.md │ │ ├── 06_params.md │ │ ├── 07_wasm.md │ │ ├── 08_errors.md │ │ ├── 09_cli.md │ │ └── README.md │ ├── types/ │ │ ├── codec.go │ │ ├── errors.go │ │ ├── events.go │ │ ├── expected_keepers.go │ │ ├── genesis.go │ │ ├── genesis.pb.go │ │ ├── keys.go │ │ ├── msgs.go │ │ ├── params.go │ │ ├── params_legacy.go │ │ ├── query.pb.go │ │ ├── query.pb.gw.go │ │ ├── route.go │ │ ├── tx.pb.go │ │ └── types.pb.go │ └── wasm/ │ └── interface.go ├── liquidity/ │ ├── abci.go │ ├── client/ │ │ └── cli/ │ │ ├── flags.go │ │ ├── query.go │ │ └── tx.go │ ├── exported/ │ │ └── exported.go │ ├── genesis.go │ ├── handler.go │ ├── keeper/ │ │ ├── batch.go │ │ ├── genesis.go │ │ ├── grpc_query.go │ │ ├── invariants.go │ │ ├── keeper.go │ │ ├── liquidity_pool.go │ │ ├── migrator.go │ │ ├── msg_server.go │ │ ├── store.go │ │ └── swap.go │ ├── migrations/ │ │ └── v3/ │ │ └── migrate.go │ ├── module.go │ ├── spec/ │ │ ├── 01_concepts.md │ │ ├── 02_state.md │ │ ├── 03_state_transitions.md │ │ ├── 04_messages.md │ │ ├── 05_begin_block.md │ │ ├── 06_end_block.md │ │ ├── 07_events.md │ │ ├── 08_params.md │ │ └── README.md │ ├── types/ │ │ ├── codec.go │ │ ├── codec_test.go │ │ ├── errors.go │ │ ├── events.go │ │ ├── expected_keepers.go │ │ ├── genesis.go │ │ ├── genesis.pb.go │ │ ├── keys.go │ │ ├── liquidity.pb.go │ │ ├── liquidity_pool.go │ │ ├── msgs.go │ │ ├── params.go │ │ ├── params_legacy.go │ │ ├── querier.go │ │ ├── query.pb.go │ │ ├── query.pb.gw.go │ │ ├── swap.go │ │ ├── tx.pb.go │ │ └── utils.go │ └── wasm/ │ └── liquidity.go ├── rank/ │ ├── abci.go │ ├── client/ │ │ └── cli/ │ │ └── query.go │ ├── cuda/ │ │ ├── Makefile │ │ ├── cbdrank.h │ │ ├── rank.cu │ │ ├── test_rank.cu │ │ └── types.h │ ├── exported/ │ │ └── exported.go │ ├── keeper/ │ │ ├── calculate.go │ │ ├── calculate_cpu.go │ │ ├── calculate_gpu.go │ │ ├── calculate_gpu_nop.go │ │ ├── calculate_mock.go │ │ ├── genesis.go │ │ ├── grpc_query.go │ │ ├── keeper.go │ │ ├── migrator.go │ │ ├── msg_server.go │ │ └── snapshotter.go │ ├── migrations/ │ │ └── v2/ │ │ └── migrate.go │ ├── module.go │ ├── types/ │ │ ├── codec.go │ │ ├── compute.go │ │ ├── context.go │ │ ├── expected_keepers.go │ │ ├── genesis.go │ │ ├── genesis.pb.go │ │ ├── index.go │ │ ├── index_types.go │ │ ├── keys.go │ │ ├── msgs.go │ │ ├── pagination.pb.go │ │ ├── params.go │ │ ├── params_legacy.go │ │ ├── querier.go │ │ ├── query.pb.go │ │ ├── query.pb.gw.go │ │ ├── rank.go │ │ ├── tx.pb.go │ │ └── types.pb.go │ └── wasm/ │ └── interface.go ├── resources/ │ ├── client/ │ │ └── cli/ │ │ ├── query.go │ │ └── tx.go │ ├── exported/ │ │ └── exported.go │ ├── keeper/ │ │ ├── genesis.go │ │ ├── grpc_query.go │ │ ├── keeper.go │ │ ├── migrator.go │ │ └── msg_server.go │ ├── migrations/ │ │ └── v2/ │ │ └── migrate.go │ ├── module.go │ ├── spec/ │ │ ├── 00_concepts.md │ │ ├── 01_api.md │ │ ├── 02_state.md │ │ ├── 03_state_transitions.md │ │ ├── 04_messages.md │ │ ├── 05_events.md │ │ ├── 06_params.md │ │ ├── 07_wasm.md │ │ ├── 08_errors.md │ │ ├── 09_cli.md │ │ └── README.md │ ├── types/ │ │ ├── account.go │ │ ├── codec.go │ │ ├── errors.go │ │ ├── events.go │ │ ├── expected_keepers.go │ │ ├── genesis.go │ │ ├── genesis.pb.go │ │ ├── keys.go │ │ ├── msgs.go │ │ ├── params.go │ │ ├── params_legacy.go │ │ ├── period.go │ │ ├── query.pb.go │ │ ├── query.pb.gw.go │ │ ├── tx.pb.go │ │ └── types.pb.go │ └── wasm/ │ └── interface.go ├── staking/ │ ├── module.go │ └── msg_server.go └── tokenfactory/ ├── README.md ├── client/ │ └── cli/ │ ├── query.go │ └── tx.go ├── exported/ │ └── exported.go ├── keeper/ │ ├── admins.go │ ├── admins_test.go │ ├── bankactions.go │ ├── createdenom.go │ ├── createdenom_test.go │ ├── creators.go │ ├── genesis.go │ ├── genesis_test.go │ ├── grpc_query.go │ ├── keeper.go │ ├── keeper_test.go │ ├── migrator.go │ ├── msg_server.go │ ├── msg_server_test.go │ └── params.go ├── migrations/ │ └── v2/ │ ├── migrate.go │ └── migrate_test.go ├── module.go ├── testhelpers/ │ └── authz.go ├── types/ │ ├── authorityMetadata.go │ ├── authorityMetadata.pb.go │ ├── capabilities.go │ ├── codec.go │ ├── codec_test.go │ ├── denoms.go │ ├── denoms_test.go │ ├── errors.go │ ├── events.go │ ├── expected_keepers.go │ ├── genesis.go │ ├── genesis.pb.go │ ├── genesis_test.go │ ├── keys.go │ ├── msgs.go │ ├── msgs_test.go │ ├── params.go │ ├── params.pb.go │ ├── params_legacy.go │ ├── query.pb.go │ ├── query.pb.gw.go │ └── tx.pb.go └── wasm/ ├── custom_msg_test.go ├── custom_query_test.go ├── helpers_test.go ├── message_plugin.go ├── queries.go ├── query_plugin.go ├── types/ │ ├── msg.go │ ├── query.go │ └── types.go ├── validate_msg_test.go └── validate_queries_test.go ================================================ FILE CONTENTS ================================================ ================================================ FILE: .dockerignore ================================================ eulet-5 mytestnet ================================================ FILE: .gitattributes ================================================ client/docs/swagger-ui/* linguist-vendored ================================================ FILE: .github/ISSUE_TEMPLATE/bug_report.md ================================================ --- name: Bug report about: Create a report to help us improve --- ### Current Behavior [comment]: # (Describe what actually happened.) ### Expected Behavior [comment]: # (Describe what you expected to happen.) ### Reproduction [comment]: # (Describe how we can replicate the bug step by step.) ### Log [comment]: # (Also you can attach log to this issue.) ### Additional Information [comment]: # (Any other information that would be useful, content, screenshots, etc.) ================================================ FILE: .github/ISSUE_TEMPLATE/feature_request.md ================================================ --- name: Feature request about: Suggest an idea for this project --- ### User Story [comment]: # (As a , I want to so that .) ### Why Is this Needed? [comment]: # (Describe the problem and why this task is needed. Provide description of the current state, what you would like to happen, and what actually happen) *Summary*: ### Definition of Done [comment]: # (Any other information that would be useful, bullets are helpful.) ### Additional Information [comment]: # (Any other information that would be useful, content, screenshots, etc.) ================================================ FILE: .github/ISSUE_TEMPLATE/gitcoin-issue-template.md ================================================ --- name: Add Issue to Gitcoin about: This is recommended issue template for gitcoin --- #### Overview [Here](https://github.com/cybercongress/cyberd/blob/master/README.md) you can explore our project --- #### Current project situation Current project situation section where you can explain why we need to solve this task --- #### Task description Explain task clearly with details --- #### Required skills - List; - required; - skills; - here. --- #### Contribution rules [Here](https://github.com/cybercongress/cyberd/blob/master/CONTRIBUTING.md) you can learn how to contribute to our project --- #### Definition of done Explain what you actually want to see as a result: - [ ] you can - [ ] also - [ ] use checkboxes --- #### Extra information Bounty amount | 999 ETH ------------ | ------------- Experience level | beginner / intermediate / advanced Project length | hours / days / weeks / mounths Expires in | 2 weeks / 1 mounth / 3 mounths / 6 mounths / 1 year Bounty type | bug / feature / security / other ================================================ FILE: .github/tests.yml ================================================ # https://github.com/mvdan/github-actions-golang on: [push, pull_request] name: Test jobs: test: strategy: matrix: go-version: [1.19.x, 1.20.x] os: [ubuntu-latest, macos-latest, windows-latest] runs-on: ${{ matrix.os }} steps: - uses: actions/checkout@v3 - uses: actions/setup-go@v4 with: go-version: ${{ matrix.go-version }} - run: go test ./... ================================================ FILE: .gitignore ================================================ # OS .DS_Store *.swp *.swo *.swl *.swm *.swn .vscode .idea # Build vendor build tools/bin/* examples/build/* docs/_build docs/tutorial dist tools-stamp docs/node_modules NULL # Data - ideally these don't exist baseapp/data/* client/lcd/keys/* mytestnet testnet testnets # Testing coverage.txt profile.out # Vagrant .vagrant/ *.box *.log vagrant # IDE .idea/ *.iml # Graphviz dependency-graph.png # Latex *.aux *.out *.synctex.gz contract_tests/* # Wasm contracts # Scripts *.mjs *.wasm cmd/iavltool/*.txt # Local infrastructure docs (not part of codebase) local/ # Claude Code .claude/ CLAUDE.md ================================================ FILE: .golangci.yml ================================================ run: # timeout for analysis, e.g. 30s, 5m, default is 1m timeout: 10m tests: true linters: disable-all: true enable: - bodyclose - depguard - dogsled - errcheck - goconst - gocritic - gofumpt - revive - gosec - gosimple - govet - ineffassign - misspell - nakedret - exportloopref - staticcheck - stylecheck - typecheck - unconvert - unused - unparam - misspell linters-settings: gosec: excludes: - G404 ================================================ FILE: .goreleaser.yml ================================================ builds: - main: ./cyberdcli binary: cyberdcli env: - CGO_ENABLED=0 - GO111MODULE=on goos: - linux - darwin - windows goarch: - amd64 checksum: name_template: '{{ .ProjectName }}_checksums.txt' changelog: sort: asc filters: exclude: - '^docs:' - '^test:' - '^CI:' - Merge pull request nfpm: name_template: '{{ .Binary }}_{{ .Os }}_{{ .Arch }}_{{ .Version }}' replacements: darwin: macOS 386: i386 amd64: x86_64 homepage: https://github.com/cybercongress description: Distributed search engine maintainer: Cyber Admin license: MIT vendor: cyber.Congress formats: - deb - rpm dependencies: - git recommends: - rpm archive: name_template: '{{ .Binary }}_{{ .Os }}_{{ .Arch }}_{{ .Version }}' replacements: darwin: MacOS linux: Linux windows: Windows 386: i386 amd64: x86_64 format: zip format_overrides: - goos: linux format: tar.gz wrap_in_directory: true files: - none* ================================================ FILE: CHANGELOG.md ================================================ # Change Log ## [Unreleased](https://github.com/cybercongress/go-cyber/tree/HEAD) [Full Changelog](https://github.com/cybercongress/go-cyber/compare/v0.1.6...HEAD) **Closed issues:** - Disable karma calculations [\#552](https://github.com/cybercongress/go-cyber/issues/552) - Upgrade to Launchpad [\#550](https://github.com/cybercongress/go-cyber/issues/550) - Test onchain upgrade against docker container [\#541](https://github.com/cybercongress/go-cyber/issues/541) - Upgrade to sdk 38.5 and tm 33.6 [\#530](https://github.com/cybercongress/go-cyber/issues/530) - Delegations not indexed with bank module wrapper [\#521](https://github.com/cybercongress/go-cyber/issues/521) - Security upgrade with bump to 0.38.3/0.33.3 [\#518](https://github.com/cybercongress/go-cyber/issues/518) - Rename cyberdcli [\#481](https://github.com/cybercongress/go-cyber/issues/481) - Euler-6 release [\#463](https://github.com/cybercongress/go-cyber/issues/463) - Md style error in run\_validator.md [\#445](https://github.com/cybercongress/go-cyber/issues/445) - Support easy install with brew tap [\#426](https://github.com/cybercongress/go-cyber/issues/426) - Validator setup using Tendermint KMS + Ledger [\#393](https://github.com/cybercongress/go-cyber/issues/393) - Delegation of energy and power [\#329](https://github.com/cybercongress/go-cyber/issues/329) - Daemon for autoclaiming of validators rewards [\#280](https://github.com/cybercongress/go-cyber/issues/280) **Merged pull requests:** - Indexing rewards of withdraw proxy account [\#579](https://github.com/cybercongress/go-cyber/pull/579) ([litvintech](https://github.com/litvintech)) - Skip indexing of not existed account [\#578](https://github.com/cybercongress/go-cyber/pull/578) ([litvintech](https://github.com/litvintech)) - Fixed call of rank rpc endpoint [\#572](https://github.com/cybercongress/go-cyber/pull/572) ([litvintech](https://github.com/litvintech)) - Fixed freeing of allocated memory [\#571](https://github.com/cybercongress/go-cyber/pull/571) ([litvintech](https://github.com/litvintech)) - Energy module [\#565](https://github.com/cybercongress/go-cyber/pull/565) ([litvintech](https://github.com/litvintech)) - Uints rank's values [\#564](https://github.com/cybercongress/go-cyber/pull/564) ([litvintech](https://github.com/litvintech)) - Extra APIs [\#563](https://github.com/cybercongress/go-cyber/pull/563) ([litvintech](https://github.com/litvintech)) - upgrade\_fixes\_to\_run\_val [\#545](https://github.com/cybercongress/go-cyber/pull/545) ([mrlp4](https://github.com/mrlp4)) - fixes to upgrade guide [\#537](https://github.com/cybercongress/go-cyber/pull/537) ([mrlp4](https://github.com/mrlp4)) - Update script.sh [\#536](https://github.com/cybercongress/go-cyber/pull/536) ([SaveTheAles](https://github.com/SaveTheAles)) - Update naming for docs build to go-cyber [\#535](https://github.com/cybercongress/go-cyber/pull/535) ([SaveTheAles](https://github.com/SaveTheAles)) - Software upgrade documentation [\#534](https://github.com/cybercongress/go-cyber/pull/534) ([litvintech](https://github.com/litvintech)) - Delegation tracking and Darwin upgrade [\#533](https://github.com/cybercongress/go-cyber/pull/533) ([litvintech](https://github.com/litvintech)) - Master docs update [\#532](https://github.com/cybercongress/go-cyber/pull/532) ([mrlp4](https://github.com/mrlp4)) - Upgraded to sdk 38.5 and tm 33.6 [\#531](https://github.com/cybercongress/go-cyber/pull/531) ([litvintech](https://github.com/litvintech)) - upd repo name to go-cyber [\#527](https://github.com/cybercongress/go-cyber/pull/527) ([mrlp4](https://github.com/mrlp4)) - docs\_fixes [\#526](https://github.com/cybercongress/go-cyber/pull/526) ([mrlp4](https://github.com/mrlp4)) - fixes\_tun\_val\_guide [\#525](https://github.com/cybercongress/go-cyber/pull/525) ([mrlp4](https://github.com/mrlp4)) - fix\_daemon\_name [\#523](https://github.com/cybercongress/go-cyber/pull/523) ([mrlp4](https://github.com/mrlp4)) - Upgrade sdk and tm versions due to security issue [\#519](https://github.com/cybercongress/go-cyber/pull/519) ([litvintech](https://github.com/litvintech)) - docs\_update [\#517](https://github.com/cybercongress/go-cyber/pull/517) ([mrlp4](https://github.com/mrlp4)) ## [v0.1.6](https://github.com/cybercongress/go-cyber/tree/v0.1.6) (2020-04-03) [Full Changelog](https://github.com/cybercongress/go-cyber/compare/euler-5...v0.1.6) **Closed issues:** - Update docs for euler-6 [\#503](https://github.com/cybercongress/go-cyber/issues/503) - Add network load endpoint [\#499](https://github.com/cybercongress/go-cyber/issues/499) - Remove graph merkling due storage iterator non-determinism [\#496](https://github.com/cybercongress/go-cyber/issues/496) - Add used karma to cyberlink's events [\#495](https://github.com/cybercongress/go-cyber/issues/495) - The error during the signing tx with imported eth key [\#494](https://github.com/cybercongress/go-cyber/issues/494) - Refactore http client [\#493](https://github.com/cybercongress/go-cyber/issues/493) - Provide NewEventManager to links handler [\#488](https://github.com/cybercongress/go-cyber/issues/488) - Upgrade to cosmwasm 0.7 [\#484](https://github.com/cybercongress/go-cyber/issues/484) - Apply infinite gas meter to ante handler [\#483](https://github.com/cybercongress/go-cyber/issues/483) - Fix iteration over links storage [\#482](https://github.com/cybercongress/go-cyber/issues/482) - Rename cyberlink msg [\#480](https://github.com/cybercongress/go-cyber/issues/480) - Deploy first WASM contract to Euler-6 [\#479](https://github.com/cybercongress/go-cyber/issues/479) - Refactore module to go-cyber [\#478](https://github.com/cybercongress/go-cyber/issues/478) - Add cosmwasm build stage in Dockerfile [\#470](https://github.com/cybercongress/go-cyber/issues/470) - Prepare genesis file of Euler-6 [\#466](https://github.com/cybercongress/go-cyber/issues/466) - Export cyberlinks from Euler-5 [\#465](https://github.com/cybercongress/go-cyber/issues/465) - Test online upgrades in Euler-6 [\#464](https://github.com/cybercongress/go-cyber/issues/464) - Upgrade link's custom storage to sdk's storage [\#462](https://github.com/cybercongress/go-cyber/issues/462) - Update swagger.yaml for LCD [\#461](https://github.com/cybercongress/go-cyber/issues/461) - Unexpected bandwidth regeneration after a transaction [\#460](https://github.com/cybercongress/go-cyber/issues/460) - NaN rank values for objects after agent's full power transfer [\#455](https://github.com/cybercongress/go-cyber/issues/455) - Add events to link msg [\#454](https://github.com/cybercongress/go-cyber/issues/454) - Wrong app hash calculated after node restart. [\#453](https://github.com/cybercongress/go-cyber/issues/453) - Error in RPC response, top endpoint [\#451](https://github.com/cybercongress/go-cyber/issues/451) - Upgrade to cosmos-sdk v0.38.0 [\#449](https://github.com/cybercongress/go-cyber/issues/449) - Fix overall karma calculation [\#448](https://github.com/cybercongress/go-cyber/issues/448) - Standalone changes of modules balance shouldn't trigger a rank recalculation [\#446](https://github.com/cybercongress/go-cyber/issues/446) - Command list from euler 3 update [\#433](https://github.com/cybercongress/go-cyber/issues/433) - Upgrade to Cosmos-SDK 0.38.0 [\#429](https://github.com/cybercongress/go-cyber/issues/429) - Update run\_validator guide for Euler-dev [\#423](https://github.com/cybercongress/go-cyber/issues/423) - WASM integration [\#381](https://github.com/cybercongress/go-cyber/issues/381) **Merged pull requests:** - upd to cli-install script [\#516](https://github.com/cybercongress/go-cyber/pull/516) ([mrlp4](https://github.com/mrlp4)) - update ci script for changelog generator [\#515](https://github.com/cybercongress/go-cyber/pull/515) ([SaveTheAles](https://github.com/SaveTheAles)) - update repo name at changelog generator [\#514](https://github.com/cybercongress/go-cyber/pull/514) ([SaveTheAles](https://github.com/SaveTheAles)) - Improve band and rank params init [\#513](https://github.com/cybercongress/go-cyber/pull/513) ([litvintech](https://github.com/litvintech)) - Upd genesis hash at run\_validator [\#512](https://github.com/cybercongress/go-cyber/pull/512) ([mrlp4](https://github.com/mrlp4)) - Euler-6 release [\#511](https://github.com/cybercongress/go-cyber/pull/511) ([litvintech](https://github.com/litvintech)) - Updated README [\#510](https://github.com/cybercongress/go-cyber/pull/510) ([litvintech](https://github.com/litvintech)) - Remove http client [\#509](https://github.com/cybercongress/go-cyber/pull/509) ([litvintech](https://github.com/litvintech)) - Add swagger bundle for cyber [\#508](https://github.com/cybercongress/go-cyber/pull/508) ([litvintech](https://github.com/litvintech)) - Documentation update for 0.1.6 [\#507](https://github.com/cybercongress/go-cyber/pull/507) ([mrlp4](https://github.com/mrlp4)) - Install cybercli script [\#506](https://github.com/cybercongress/go-cyber/pull/506) ([mrlp4](https://github.com/mrlp4)) - Update run validator guide [\#504](https://github.com/cybercongress/go-cyber/pull/504) ([mrlp4](https://github.com/mrlp4)) - Remove merkling of graph [\#501](https://github.com/cybercongress/go-cyber/pull/501) ([litvintech](https://github.com/litvintech)) - Add RPC endpoint for network load [\#500](https://github.com/cybercongress/go-cyber/pull/500) ([litvintech](https://github.com/litvintech)) - Fixed ethereum private key import [\#498](https://github.com/cybercongress/go-cyber/pull/498) ([litvintech](https://github.com/litvintech)) - Add used karma to cyberlinks events [\#497](https://github.com/cybercongress/go-cyber/pull/497) ([litvintech](https://github.com/litvintech)) - Fix event manager for NewLinksHangler [\#492](https://github.com/cybercongress/go-cyber/pull/492) ([litvintech](https://github.com/litvintech)) - Fix iteration over links storage [\#491](https://github.com/cybercongress/go-cyber/pull/491) ([litvintech](https://github.com/litvintech)) - Rename cyberlink msg [\#490](https://github.com/cybercongress/go-cyber/pull/490) ([litvintech](https://github.com/litvintech)) - Upgrade to cosmwasm 0.7 [\#489](https://github.com/cybercongress/go-cyber/pull/489) ([litvintech](https://github.com/litvintech)) - Add custom ante handler with applied infinity gas meter [\#487](https://github.com/cybercongress/go-cyber/pull/487) ([litvintech](https://github.com/litvintech)) - Add cosmwasm docker build stage [\#486](https://github.com/cybercongress/go-cyber/pull/486) ([litvintech](https://github.com/litvintech)) - Added cosmwasm module [\#477](https://github.com/cybercongress/go-cyber/pull/477) ([litvintech](https://github.com/litvintech)) - Upgrade to cosmos-SDK v0.38.1 [\#476](https://github.com/cybercongress/go-cyber/pull/476) ([litvintech](https://github.com/litvintech)) - Fixed NaN in weights calculation in CPU/GPU [\#475](https://github.com/cybercongress/go-cyber/pull/475) ([litvintech](https://github.com/litvintech)) - Euler-5.1 [\#473](https://github.com/cybercongress/go-cyber/pull/473) ([litvintech](https://github.com/litvintech)) - Fixed calculation of overall karma [\#459](https://github.com/cybercongress/go-cyber/pull/459) ([litvintech](https://github.com/litvintech)) - Fixed triggering of rank calculation by modules [\#458](https://github.com/cybercongress/go-cyber/pull/458) ([litvintech](https://github.com/litvintech)) - Added skipping of NaN objects during sorting [\#457](https://github.com/cybercongress/go-cyber/pull/457) ([litvintech](https://github.com/litvintech)) - Updated index.md [\#442](https://github.com/cybercongress/go-cyber/pull/442) ([mrlp4](https://github.com/mrlp4)) - fixed title ultimate guide; fixed folders names [\#441](https://github.com/cybercongress/go-cyber/pull/441) ([mrlp4](https://github.com/mrlp4)) ## [euler-5](https://github.com/cybercongress/go-cyber/tree/euler-5) (2019-12-20) [Full Changelog](https://github.com/cybercongress/go-cyber/compare/v0.1.5-rc1...euler-5) **Closed issues:** - Bump tendermint/cosmos-sdk to 0.32.8/0.37.4 [\#437](https://github.com/cybercongress/go-cyber/issues/437) - Add overall karma stats [\#435](https://github.com/cybercongress/go-cyber/issues/435) - Add instructions for easy install and use non-validating version of cyberdcli [\#425](https://github.com/cybercongress/go-cyber/issues/425) - euler-x params discussion [\#422](https://github.com/cybercongress/go-cyber/issues/422) - Add rank and bandwidth modules LCD endpoints [\#419](https://github.com/cybercongress/go-cyber/issues/419) - Add max block bandwidth parameter [\#415](https://github.com/cybercongress/go-cyber/issues/415) - Make cross testing of data preparation code for GPU [\#413](https://github.com/cybercongress/go-cyber/issues/413) - Fix CLI output on txs [\#412](https://github.com/cybercongress/go-cyber/issues/412) - Add Makefile for rank CUDA kernel [\#409](https://github.com/cybercongress/go-cyber/issues/409) - CUDA kernel for Rank Merkle Tree calculation [\#401](https://github.com/cybercongress/go-cyber/issues/401) - Sync fail due to possible DB corruption [\#397](https://github.com/cybercongress/go-cyber/issues/397) - Add instructions to use without docker [\#389](https://github.com/cybercongress/go-cyber/issues/389) - Update docs on inflation params from euler-5 [\#385](https://github.com/cybercongress/go-cyber/issues/385) - Ability to launch validator from blockchain backup [\#384](https://github.com/cybercongress/go-cyber/issues/384) - Top CIDs endpoint [\#378](https://github.com/cybercongress/go-cyber/issues/378) - Index of used by account bandwidth for linking [\#371](https://github.com/cybercongress/go-cyber/issues/371) - Snapshot of Cosmos Hub for euler-5 [\#369](https://github.com/cybercongress/go-cyber/issues/369) - Configure BIP44 path [\#368](https://github.com/cybercongress/go-cyber/issues/368) - Get actual data on euler-4 validators uptime [\#360](https://github.com/cybercongress/go-cyber/issues/360) - Set size limit for CIDv1 [\#346](https://github.com/cybercongress/go-cyber/issues/346) - Prepare genesis for euler-5 with proofs flow [\#339](https://github.com/cybercongress/go-cyber/issues/339) - Adjust consensus and cyberd params for euler-5 [\#338](https://github.com/cybercongress/go-cyber/issues/338) - Add table of seed/validator nodes to README for euler-4 [\#319](https://github.com/cybercongress/go-cyber/issues/319) - Advanced export [\#318](https://github.com/cybercongress/go-cyber/issues/318) - Make profiling [\#317](https://github.com/cybercongress/go-cyber/issues/317) - Move bandwidth logic to ante handler [\#249](https://github.com/cybercongress/go-cyber/issues/249) - Download genesis files on start of docker container [\#224](https://github.com/cybercongress/go-cyber/issues/224) - Refactor daemon/cmd package [\#199](https://github.com/cybercongress/go-cyber/issues/199) - index stats rpc add block time fields [\#176](https://github.com/cybercongress/go-cyber/issues/176) **Merged pull requests:** - 0.1.5 docs cleanup [\#439](https://github.com/cybercongress/go-cyber/pull/439) ([mrlp4](https://github.com/mrlp4)) - Bump cosmos-sdk and tendermint versions [\#438](https://github.com/cybercongress/go-cyber/pull/438) ([litvintech](https://github.com/litvintech)) - Added used overall karma generated by agents [\#436](https://github.com/cybercongress/go-cyber/pull/436) ([litvintech](https://github.com/litvintech)) - Implemented top cids endpoint and top processing [\#434](https://github.com/cybercongress/go-cyber/pull/434) ([litvintech](https://github.com/litvintech)) - run\_validator\_fixes [\#432](https://github.com/cybercongress/go-cyber/pull/432) ([mrlp4](https://github.com/mrlp4)) - add Tendermint KMS with Leger validator setup [\#431](https://github.com/cybercongress/go-cyber/pull/431) ([mrlp4](https://github.com/mrlp4)) - Update README.md [\#430](https://github.com/cybercongress/go-cyber/pull/430) ([serejandmyself](https://github.com/serejandmyself)) - ledger\_guide\_cyberd [\#428](https://github.com/cybercongress/go-cyber/pull/428) ([mrlp4](https://github.com/mrlp4)) - create run\_validator for euler-dev testnet [\#427](https://github.com/cybercongress/go-cyber/pull/427) ([mrlp4](https://github.com/mrlp4)) - Remove outdated whitepaper [\#424](https://github.com/cybercongress/go-cyber/pull/424) ([cyb-master](https://github.com/cyb-master)) - 419 band and rank modules endpoints [\#420](https://github.com/cybercongress/go-cyber/pull/420) ([litvintech](https://github.com/litvintech)) - Client upgrade [\#418](https://github.com/cybercongress/go-cyber/pull/418) ([litvintech](https://github.com/litvintech)) - Added stat for used for linking band [\#417](https://github.com/cybercongress/go-cyber/pull/417) ([litvintech](https://github.com/litvintech)) - \#320 add advanced guides [\#390](https://github.com/cybercongress/go-cyber/pull/390) ([SaveTheAles](https://github.com/SaveTheAles)) ## [v0.1.5-rc1](https://github.com/cybercongress/go-cyber/tree/v0.1.5-rc1) (2019-11-01) [Full Changelog](https://github.com/cybercongress/go-cyber/compare/v0.1.4...v0.1.5-rc1) **Closed issues:** - Change to native ante handler [\#403](https://github.com/cybercongress/go-cyber/issues/403) - Parallelization data preparation for GPU [\#400](https://github.com/cybercongress/go-cyber/issues/400) - Add Makefile [\#396](https://github.com/cybercongress/go-cyber/issues/396) - Cyberd Ledger support guide [\#391](https://github.com/cybercongress/go-cyber/issues/391) - Refactor DesirableNetworkBandwidthForRecoveryPeriod [\#386](https://github.com/cybercongress/go-cyber/issues/386) - Damping factor as onchain parameter [\#379](https://github.com/cybercongress/go-cyber/issues/379) - Upgrade to cosmos-sdk 0.37.0 [\#377](https://github.com/cybercongress/go-cyber/issues/377) - Fix search index loading [\#373](https://github.com/cybercongress/go-cyber/issues/373) - Upgrade mint module [\#356](https://github.com/cybercongress/go-cyber/issues/356) - Remove old distribution [\#353](https://github.com/cybercongress/go-cyber/issues/353) - Add validate-genesis command to CLI [\#335](https://github.com/cybercongress/go-cyber/issues/335) - Governance parameterization of bandwidth parameters [\#332](https://github.com/cybercongress/go-cyber/issues/332) - Governance parameterization of rank window [\#331](https://github.com/cybercongress/go-cyber/issues/331) - Adjusting of link weight [\#330](https://github.com/cybercongress/go-cyber/issues/330) - Answer why CyberD is better for Web3 then Google [\#328](https://github.com/cybercongress/go-cyber/issues/328) - Exclude at the current stage the consideration of the behavioural factor in the search for ordinary users [\#327](https://github.com/cybercongress/go-cyber/issues/327) - New distribution [\#316](https://github.com/cybercongress/go-cyber/issues/316) - Create list of supported and tested GPUs [\#315](https://github.com/cybercongress/go-cyber/issues/315) - Upgrade to cosmos-sdk 0.34.4 [\#313](https://github.com/cybercongress/go-cyber/issues/313) - Update development environment documentation [\#311](https://github.com/cybercongress/go-cyber/issues/311) - RPC endpoint for cid rank proofs [\#309](https://github.com/cybercongress/go-cyber/issues/309) - Fix pictures in whitepaper [\#303](https://github.com/cybercongress/go-cyber/issues/303) - Error during rewards withdrawal [\#302](https://github.com/cybercongress/go-cyber/issues/302) - Merkle proofs for link storage [\#299](https://github.com/cybercongress/go-cyber/issues/299) - Add backup and restore validator keys guide. [\#286](https://github.com/cybercongress/go-cyber/issues/286) - Move bandwidth and rank constants to params store [\#284](https://github.com/cybercongress/go-cyber/issues/284) - Cyberadmin telegram-bot for cyberd [\#281](https://github.com/cybercongress/go-cyber/issues/281) - Align current network capabilities with cyberCongress pricing model [\#262](https://github.com/cybercongress/go-cyber/issues/262) - Add keystore doc [\#256](https://github.com/cybercongress/go-cyber/issues/256) - Finish Proof of Code genesis drop [\#294](https://github.com/cybercongress/go-cyber/issues/294) - Full validating quorum [\#195](https://github.com/cybercongress/go-cyber/issues/195) - Infinity race problem. [\#172](https://github.com/cybercongress/go-cyber/issues/172) - Rank calculation period automatic adjustment [\#142](https://github.com/cybercongress/go-cyber/issues/142) - Slow node start-up. [\#138](https://github.com/cybercongress/go-cyber/issues/138) - RPC get cid rank endpoint [\#116](https://github.com/cybercongress/go-cyber/issues/116) - CheckTx doesn't include coins that will be minted in current block [\#113](https://github.com/cybercongress/go-cyber/issues/113) **Merged pull requests:** - Added max block band params and validation [\#421](https://github.com/cybercongress/go-cyber/pull/421) ([litvintech](https://github.com/litvintech)) - 318 advanced export [\#416](https://github.com/cybercongress/go-cyber/pull/416) ([litvintech](https://github.com/litvintech)) - Remove outdated whitepaper from docs [\#414](https://github.com/cybercongress/go-cyber/pull/414) ([SaveTheAles](https://github.com/SaveTheAles)) - Added makefile for rank, added tag CUDA for daemon build [\#411](https://github.com/cybercongress/go-cyber/pull/411) ([litvintech](https://github.com/litvintech)) - Band refactoring [\#408](https://github.com/cybercongress/go-cyber/pull/408) ([litvintech](https://github.com/litvintech)) - Damping factor and tolerance as onchain params [\#407](https://github.com/cybercongress/go-cyber/pull/407) ([litvintech](https://github.com/litvintech)) - Refactoring of data preparation for GPU, added workers [\#406](https://github.com/cybercongress/go-cyber/pull/406) ([litvintech](https://github.com/litvintech)) - Added native ante handler [\#405](https://github.com/cybercongress/go-cyber/pull/405) ([litvintech](https://github.com/litvintech)) - Added Makefile, updated Dockerfile for [\#404](https://github.com/cybercongress/go-cyber/pull/404) ([litvintech](https://github.com/litvintech)) - Update band parameters [\#399](https://github.com/cybercongress/go-cyber/pull/399) ([vasilistefanenko](https://github.com/vasilistefanenko)) - Sdk 37 upgrade [\#395](https://github.com/cybercongress/go-cyber/pull/395) ([vasilistefanenko](https://github.com/vasilistefanenko)) - add Ledger support guide [\#392](https://github.com/cybercongress/go-cyber/pull/392) ([mrlp4](https://github.com/mrlp4)) - Upgrade SDK to 0.37.0 LTS [\#388](https://github.com/cybercongress/go-cyber/pull/388) ([litvintech](https://github.com/litvintech)) - 352 link node [\#387](https://github.com/cybercongress/go-cyber/pull/387) ([vasilistefanenko](https://github.com/vasilistefanenko)) - Update README.md [\#376](https://github.com/cybercongress/go-cyber/pull/376) ([serejandmyself](https://github.com/serejandmyself)) - Search index fix [\#375](https://github.com/cybercongress/go-cyber/pull/375) ([litvintech](https://github.com/litvintech)) - Awesome README [\#374](https://github.com/cybercongress/go-cyber/pull/374) ([litvintech](https://github.com/litvintech)) - add governance overview article [\#367](https://github.com/cybercongress/go-cyber/pull/367) ([SaveTheAles](https://github.com/SaveTheAles)) - Update multisig\_guide.md [\#366](https://github.com/cybercongress/go-cyber/pull/366) ([serejandmyself](https://github.com/serejandmyself)) - Upgrade to cosmos-sdk [\#362](https://github.com/cybercongress/go-cyber/pull/362) ([litvintech](https://github.com/litvintech)) - Merkle tree for links [\#361](https://github.com/cybercongress/go-cyber/pull/361) ([litvintech](https://github.com/litvintech)) - Removed old distribution [\#358](https://github.com/cybercongress/go-cyber/pull/358) ([litvintech](https://github.com/litvintech)) - Upgrade to cosmos-hub mint module [\#357](https://github.com/cybercongress/go-cyber/pull/357) ([litvintech](https://github.com/litvintech)) - 309 rank proof [\#355](https://github.com/cybercongress/go-cyber/pull/355) ([janus](https://github.com/janus)) - Fixes fatal mistake in distribution [\#348](https://github.com/cybercongress/go-cyber/pull/348) ([cyb-master](https://github.com/cyb-master)) - Format hotfix [\#347](https://github.com/cybercongress/go-cyber/pull/347) ([cyb-master](https://github.com/cyb-master)) - Edit GPU list according to @litvintech comments [\#345](https://github.com/cybercongress/go-cyber/pull/345) ([SaveTheAles](https://github.com/SaveTheAles)) - Change get-cyb description [\#344](https://github.com/cybercongress/go-cyber/pull/344) ([SaveTheAles](https://github.com/SaveTheAles)) - Add keystore managment guide \#256 [\#343](https://github.com/cybercongress/go-cyber/pull/343) ([SaveTheAles](https://github.com/SaveTheAles)) - Merkle tree for links [\#340](https://github.com/cybercongress/go-cyber/pull/340) ([litvintech](https://github.com/litvintech)) - Final fixes of paper [\#334](https://github.com/cybercongress/go-cyber/pull/334) ([cyb-master](https://github.com/cyb-master)) - Problem with install NVIDIA drivers [\#326](https://github.com/cybercongress/go-cyber/pull/326) ([wimel](https://github.com/wimel)) - update run\_validator [\#325](https://github.com/cybercongress/go-cyber/pull/325) ([wimel](https://github.com/wimel)) - \#320 add multisig guide create and send [\#324](https://github.com/cybercongress/go-cyber/pull/324) ([SaveTheAles](https://github.com/SaveTheAles)) - Some Dan's fixes [\#323](https://github.com/cybercongress/go-cyber/pull/323) ([ghost](https://github.com/ghost)) - Proposal of the new distribution [\#322](https://github.com/cybercongress/go-cyber/pull/322) ([cyb-master](https://github.com/cyb-master)) - Cosmos-sdk upgrade to 0.34.4 [\#314](https://github.com/cybercongress/go-cyber/pull/314) ([litvintech](https://github.com/litvintech)) - Updated docs for dev env setup [\#312](https://github.com/cybercongress/go-cyber/pull/312) ([litvintech](https://github.com/litvintech)) - Add goveralls support for test coverage [\#305](https://github.com/cybercongress/go-cyber/pull/305) ([arturalbov](https://github.com/arturalbov)) ## [v0.1.4](https://github.com/cybercongress/go-cyber/tree/v0.1.4) (2019-03-15) [Full Changelog](https://github.com/cybercongress/go-cyber/compare/v0.1.3...v0.1.4) **Closed issues:** - Consensus Failure [\#293](https://github.com/cybercongress/go-cyber/issues/293) - Enabled send [\#290](https://github.com/cybercongress/go-cyber/issues/290) - move debug logic to x/debug module [\#288](https://github.com/cybercongress/go-cyber/issues/288) - Add doc of using help feature of cli [\#287](https://github.com/cybercongress/go-cyber/issues/287) - Infinity loop in rank end blocker if node was restarted before x00 blocks. [\#283](https://github.com/cybercongress/go-cyber/issues/283) - Add doc about editing moniker and openning 26656 port. [\#282](https://github.com/cybercongress/go-cyber/issues/282) - Centralized network communication [\#257](https://github.com/cybercongress/go-cyber/issues/257) - Get supply [\#158](https://github.com/cybercongress/go-cyber/issues/158) - Development start guide [\#78](https://github.com/cybercongress/go-cyber/issues/78) **Merged pull requests:** - 0.1.4 [\#298](https://github.com/cybercongress/go-cyber/pull/298) ([hleb-albau](https://github.com/hleb-albau)) - \#293 Handle bank delegation method in inmem index update mechanism [\#297](https://github.com/cybercongress/go-cyber/pull/297) ([hleb-albau](https://github.com/hleb-albau)) - 138 links storage [\#295](https://github.com/cybercongress/go-cyber/pull/295) ([hleb-albau](https://github.com/hleb-albau)) - \#78 Dev Env docs [\#292](https://github.com/cybercongress/go-cyber/pull/292) ([hleb-albau](https://github.com/hleb-albau)) - \#290 Enable send [\#291](https://github.com/cybercongress/go-cyber/pull/291) ([hleb-albau](https://github.com/hleb-albau)) - \#288 Move debug code to x/debug [\#289](https://github.com/cybercongress/go-cyber/pull/289) ([hleb-albau](https://github.com/hleb-albau)) - \#158 Get supply [\#285](https://github.com/cybercongress/go-cyber/pull/285) ([hleb-albau](https://github.com/hleb-albau)) ## [v0.1.3](https://github.com/cybercongress/go-cyber/tree/v0.1.3) (2019-03-01) [Full Changelog](https://github.com/cybercongress/go-cyber/compare/v0.1.2...v0.1.3) **Closed issues:** - Remove full index loading for next rank in link index [\#275](https://github.com/cybercongress/go-cyber/issues/275) - Generate lottery results cmd [\#273](https://github.com/cybercongress/go-cyber/issues/273) - Can not explore existing account if it have not any outgoing transactions [\#238](https://github.com/cybercongress/go-cyber/issues/238) - distribution validator slashes don't work in cybercli [\#237](https://github.com/cybercongress/go-cyber/issues/237) - Enable governance module [\#193](https://github.com/cybercongress/go-cyber/issues/193) **Merged pull requests:** - minor docs reorg fixes [\#279](https://github.com/cybercongress/go-cyber/pull/279) ([SaveTheAles](https://github.com/SaveTheAles)) - \#193 Enable governance module [\#278](https://github.com/cybercongress/go-cyber/pull/278) ([hleb-albau](https://github.com/hleb-albau)) - Remove full index loading for next rank in link index [\#277](https://github.com/cybercongress/go-cyber/pull/277) ([arturalbov](https://github.com/arturalbov)) - \#273 Generate lottery results cmd [\#274](https://github.com/cybercongress/go-cyber/pull/274) ([hleb-albau](https://github.com/hleb-albau)) - add staging [\#272](https://github.com/cybercongress/go-cyber/pull/272) ([SaveTheAles](https://github.com/SaveTheAles)) - add folder removing [\#271](https://github.com/cybercongress/go-cyber/pull/271) ([SaveTheAles](https://github.com/SaveTheAles)) - Docs ci upd [\#270](https://github.com/cybercongress/go-cyber/pull/270) ([SaveTheAles](https://github.com/SaveTheAles)) ## [v0.1.2](https://github.com/cybercongress/go-cyber/tree/v0.1.2) (2019-02-23) [Full Changelog](https://github.com/cybercongress/go-cyber/compare/v0.1.1...v0.1.2) **Closed issues:** - Update to cosmos 0.32.0 [\#265](https://github.com/cybercongress/go-cyber/issues/265) - Rank calculation failed: out of memory [\#264](https://github.com/cybercongress/go-cyber/issues/264) - Download golang only once during docker build. [\#259](https://github.com/cybercongress/go-cyber/issues/259) - Do not calculate rank, if there is no new links on last window. [\#258](https://github.com/cybercongress/go-cyber/issues/258) - Http client only new links option for submit endpoint [\#254](https://github.com/cybercongress/go-cyber/issues/254) - Add fail at height debug flags [\#250](https://github.com/cybercongress/go-cyber/issues/250) - Different bandwidth price on same block height [\#247](https://github.com/cybercongress/go-cyber/issues/247) - Add more seeds into initial config [\#244](https://github.com/cybercongress/go-cyber/issues/244) - Consensus failure after node restart [\#243](https://github.com/cybercongress/go-cyber/issues/243) - Extend isLinkExist endpoint with possibility not specify address param [\#242](https://github.com/cybercongress/go-cyber/issues/242) - Search returns 500 error when previously unexisted "from" CID added [\#241](https://github.com/cybercongress/go-cyber/issues/241) - Create awesome gif for readme [\#239](https://github.com/cybercongress/go-cyber/issues/239) - Add staking/validators endpoint to node RPC [\#235](https://github.com/cybercongress/go-cyber/issues/235) - Rest server blocks cli keystore file [\#233](https://github.com/cybercongress/go-cyber/issues/233) - Add cyberd rest light-client to docker image [\#230](https://github.com/cybercongress/go-cyber/issues/230) - Losе token on testnet [\#227](https://github.com/cybercongress/go-cyber/issues/227) - Launch 0.1.1 testnet [\#205](https://github.com/cybercongress/go-cyber/issues/205) - Cannot interact with node [\#203](https://github.com/cybercongress/go-cyber/issues/203) - Update cyberd.ai [\#185](https://github.com/cybercongress/go-cyber/issues/185) - Cyberd release scheme. [\#180](https://github.com/cybercongress/go-cyber/issues/180) - CI: Cyberd docker image building. Include genesis file [\#160](https://github.com/cybercongress/go-cyber/issues/160) - Improve building of links index for search queries [\#145](https://github.com/cybercongress/go-cyber/issues/145) - Store initial supply from genesis file \(used by mint\) [\#115](https://github.com/cybercongress/go-cyber/issues/115) - Genesis state generator [\#92](https://github.com/cybercongress/go-cyber/issues/92) - Webscoket API [\#76](https://github.com/cybercongress/go-cyber/issues/76) - Distribution [\#27](https://github.com/cybercongress/go-cyber/issues/27) - Ranking research [\#24](https://github.com/cybercongress/go-cyber/issues/24) - Define distribution in paper [\#5](https://github.com/cybercongress/go-cyber/issues/5) **Merged pull requests:** - 0.1.2 [\#269](https://github.com/cybercongress/go-cyber/pull/269) ([hleb-albau](https://github.com/hleb-albau)) - Refactoring of search index. Fix links export [\#268](https://github.com/cybercongress/go-cyber/pull/268) ([arturalbov](https://github.com/arturalbov)) - Launch euler-2 testnet [\#267](https://github.com/cybercongress/go-cyber/pull/267) ([hleb-albau](https://github.com/hleb-albau)) - \#265 Update to cosmos 0.32.0 [\#266](https://github.com/cybercongress/go-cyber/pull/266) ([hleb-albau](https://github.com/hleb-albau)) - Consensus failure after node restart [\#263](https://github.com/cybercongress/go-cyber/pull/263) ([arturalbov](https://github.com/arturalbov)) - Do not calculate rank, if there is no new links on last window. [\#261](https://github.com/cybercongress/go-cyber/pull/261) ([arturalbov](https://github.com/arturalbov)) - Client submit only new links flag [\#260](https://github.com/cybercongress/go-cyber/pull/260) ([hleb-albau](https://github.com/hleb-albau)) - Improve building of links index for search queries [\#255](https://github.com/cybercongress/go-cyber/pull/255) ([arturalbov](https://github.com/arturalbov)) - \#244 Add moon as seed node [\#253](https://github.com/cybercongress/go-cyber/pull/253) ([hleb-albau](https://github.com/hleb-albau)) - \#250 Add fail at height debug flag [\#251](https://github.com/cybercongress/go-cyber/pull/251) ([hleb-albau](https://github.com/hleb-albau)) - \#247 Different bandwidth price on same block height [\#248](https://github.com/cybercongress/go-cyber/pull/248) ([hleb-albau](https://github.com/hleb-albau)) - \#242 Extend isLinkExist endpoint with possibility not specify address [\#246](https://github.com/cybercongress/go-cyber/pull/246) ([hleb-albau](https://github.com/hleb-albau)) - \#242 Extend isLinkExist endpoint with possibility not specify address [\#245](https://github.com/cybercongress/go-cyber/pull/245) ([hleb-albau](https://github.com/hleb-albau)) - Add staking/validators endpoint to node RPC [\#236](https://github.com/cybercongress/go-cyber/pull/236) ([arturalbov](https://github.com/arturalbov)) - Rest server blocks cli keystore file [\#234](https://github.com/cybercongress/go-cyber/pull/234) ([arturalbov](https://github.com/arturalbov)) - UPD run validator md [\#232](https://github.com/cybercongress/go-cyber/pull/232) ([SaveTheAles](https://github.com/SaveTheAles)) - Add cyberd rest light-client to docker image [\#231](https://github.com/cybercongress/go-cyber/pull/231) ([arturalbov](https://github.com/arturalbov)) - Fix docs [\#228](https://github.com/cybercongress/go-cyber/pull/228) ([arturalbov](https://github.com/arturalbov)) - upd run-validator.md [\#225](https://github.com/cybercongress/go-cyber/pull/225) ([SaveTheAles](https://github.com/SaveTheAles)) ## [v0.1.1](https://github.com/cybercongress/go-cyber/tree/v0.1.1) (2019-01-31) [Full Changelog](https://github.com/cybercongress/go-cyber/compare/euler-1...v0.1.1) **Closed issues:** - Mass testing of cyberd-testnet 0.1.1 [\#219](https://github.com/cybercongress/go-cyber/issues/219) - Export 0.1.1 genesis from 0.1.0 testnet. [\#215](https://github.com/cybercongress/go-cyber/issues/215) - Setup 0.1.1 chain params for staking, distr, slashing, mint modules. [\#201](https://github.com/cybercongress/go-cyber/issues/201) - Error on replay with wrong app hash calculation \(block \#914381\) [\#197](https://github.com/cybercongress/go-cyber/issues/197) ## [euler-1](https://github.com/cybercongress/go-cyber/tree/euler-1) (2019-01-31) [Full Changelog](https://github.com/cybercongress/go-cyber/compare/euler-1.1-dev1...euler-1) **Merged pull requests:** - Euler 0.1.1 [\#223](https://github.com/cybercongress/go-cyber/pull/223) ([arturalbov](https://github.com/arturalbov)) - Fix import reader [\#222](https://github.com/cybercongress/go-cyber/pull/222) ([arturalbov](https://github.com/arturalbov)) - Landing update [\#220](https://github.com/cybercongress/go-cyber/pull/220) ([asadovka](https://github.com/asadovka)) - DISCUSS: Chain params for 0.1.1 network [\#202](https://github.com/cybercongress/go-cyber/pull/202) ([hleb-albau](https://github.com/hleb-albau)) ## [euler-1.1-dev1](https://github.com/cybercongress/go-cyber/tree/euler-1.1-dev1) (2019-01-30) [Full Changelog](https://github.com/cybercongress/go-cyber/compare/euler-1.1-dev0...euler-1.1-dev1) **Closed issues:** - Link msg bandwidth cost doesn't take into account links count [\#216](https://github.com/cybercongress/go-cyber/issues/216) - Docker image with possibility to select compute unit [\#211](https://github.com/cybercongress/go-cyber/issues/211) **Merged pull requests:** - \#215 Fix pou distribution uses share not percentage [\#221](https://github.com/cybercongress/go-cyber/pull/221) ([hleb-albau](https://github.com/hleb-albau)) - \#215 Fix gentx commands. [\#218](https://github.com/cybercongress/go-cyber/pull/218) ([hleb-albau](https://github.com/hleb-albau)) ## [euler-1.1-dev0](https://github.com/cybercongress/go-cyber/tree/euler-1.1-dev0) (2019-01-29) [Full Changelog](https://github.com/cybercongress/go-cyber/compare/v0.1.0...euler-1.1-dev0) **Closed issues:** - Fix typos [\#207](https://github.com/cybercongress/go-cyber/issues/207) - Update landing for 0.4 whitepaper [\#204](https://github.com/cybercongress/go-cyber/issues/204) - Fix validator manual [\#189](https://github.com/cybercongress/go-cyber/issues/189) - Update to tendermint v29.0 [\#187](https://github.com/cybercongress/go-cyber/issues/187) - Links Exporter [\#184](https://github.com/cybercongress/go-cyber/issues/184) - Change mint module to default cosmos module [\#181](https://github.com/cybercongress/go-cyber/issues/181) - Change Bandwidth Price to Average for 24h Sliding Window [\#179](https://github.com/cybercongress/go-cyber/issues/179) - High bandwidth cost for create validator msg [\#178](https://github.com/cybercongress/go-cyber/issues/178) - Bandwidth Specification Change [\#177](https://github.com/cybercongress/go-cyber/issues/177) - Add rpc endpoint to submit signed link and send messages [\#173](https://github.com/cybercongress/go-cyber/issues/173) - Tx size reduction: switch to more compact links tx encoding. [\#171](https://github.com/cybercongress/go-cyber/issues/171) - Current Bandwidth do not respect price [\#168](https://github.com/cybercongress/go-cyber/issues/168) - index entities count endpoint [\#165](https://github.com/cybercongress/go-cyber/issues/165) - negative bandwidnt [\#164](https://github.com/cybercongress/go-cyber/issues/164) - Add ipfs hashes to release [\#161](https://github.com/cybercongress/go-cyber/issues/161) - Change token name from CBD to CYB in the testnetwork [\#157](https://github.com/cybercongress/go-cyber/issues/157) - Wrong CYB allocation in Genesis [\#156](https://github.com/cybercongress/go-cyber/issues/156) - Update docker with 0.1.0 version [\#154](https://github.com/cybercongress/go-cyber/issues/154) - Add more issues templates. [\#153](https://github.com/cybercongress/go-cyber/issues/153) - Move import\_private command to keys subcomand [\#152](https://github.com/cybercongress/go-cyber/issues/152) - Add trust-node by default in cli [\#151](https://github.com/cybercongress/go-cyber/issues/151) - Handle import of ethereum privkeys with 0x [\#150](https://github.com/cybercongress/go-cyber/issues/150) - Numerous small fixes in whitepaper [\#89](https://github.com/cybercongress/go-cyber/issues/89) - Cyberd landing make up [\#36](https://github.com/cybercongress/go-cyber/issues/36) - Whitepaper 0.4 [\#25](https://github.com/cybercongress/go-cyber/issues/25) **Merged pull requests:** - CI: testnet ipfs files hashes [\#217](https://github.com/cybercongress/go-cyber/pull/217) ([arturalbov](https://github.com/arturalbov)) - WIP: CI Cyberd docker image building. Include genesis file [\#214](https://github.com/cybercongress/go-cyber/pull/214) ([arturalbov](https://github.com/arturalbov)) - \#197 Error on replay with wrong app hash calculation [\#213](https://github.com/cybercongress/go-cyber/pull/213) ([hleb-albau](https://github.com/hleb-albau)) - Links exporter [\#210](https://github.com/cybercongress/go-cyber/pull/210) ([arturalbov](https://github.com/arturalbov)) - R4R \#181 Constant Block Reward [\#209](https://github.com/cybercongress/go-cyber/pull/209) ([hleb-albau](https://github.com/hleb-albau)) - 157 change token protocol name [\#208](https://github.com/cybercongress/go-cyber/pull/208) ([hleb-albau](https://github.com/hleb-albau)) - Fix typos get\_CYB.md [\#206](https://github.com/cybercongress/go-cyber/pull/206) ([serejandmyself](https://github.com/serejandmyself)) - R4R: \#156 Add Missing euler tokens cmd [\#200](https://github.com/cybercongress/go-cyber/pull/200) ([hleb-albau](https://github.com/hleb-albau)) - Update to cosmos-sdk v0.30.0 [\#198](https://github.com/cybercongress/go-cyber/pull/198) ([hleb-albau](https://github.com/hleb-albau)) - Tx size reduction: switch to more compact links tx encoding [\#192](https://github.com/cybercongress/go-cyber/pull/192) ([arturalbov](https://github.com/arturalbov)) - Fix rank calculation context data [\#191](https://github.com/cybercongress/go-cyber/pull/191) ([hleb-albau](https://github.com/hleb-albau)) - Important fixes in validators manual [\#190](https://github.com/cybercongress/go-cyber/pull/190) ([cyb-master](https://github.com/cyb-master)) - Change Bandwidth Price to Average for 24h Sliding Window [\#188](https://github.com/cybercongress/go-cyber/pull/188) ([arturalbov](https://github.com/arturalbov)) - R4R Update cosmos to latest develop [\#186](https://github.com/cybercongress/go-cyber/pull/186) ([hleb-albau](https://github.com/hleb-albau)) - \#153 Add more issues templates. [\#183](https://github.com/cybercongress/go-cyber/pull/183) ([hleb-albau](https://github.com/hleb-albau)) - \#178 \#168 Bandwidth price + Msg cost for non link txes [\#182](https://github.com/cybercongress/go-cyber/pull/182) ([hleb-albau](https://github.com/hleb-albau)) - \#173 Add rpc endpoint to submit signed link and send messages [\#174](https://github.com/cybercongress/go-cyber/pull/174) ([hleb-albau](https://github.com/hleb-albau)) - Technical notes on euler release [\#169](https://github.com/cybercongress/go-cyber/pull/169) ([cyb-master](https://github.com/cyb-master)) - Handle import of ethereum privkeys with 0x. Trust node by default [\#167](https://github.com/cybercongress/go-cyber/pull/167) ([arturalbov](https://github.com/arturalbov)) - \#164 fix rpc negative bw \#165 add index entities count endpoint [\#166](https://github.com/cybercongress/go-cyber/pull/166) ([hleb-albau](https://github.com/hleb-albau)) - Move import\_private command to keys subcomand [\#159](https://github.com/cybercongress/go-cyber/pull/159) ([arturalbov](https://github.com/arturalbov)) ## [v0.1.0](https://github.com/cybercongress/go-cyber/tree/v0.1.0) (2019-01-06) [Full Changelog](https://github.com/cybercongress/go-cyber/compare/v0.0.8...v0.1.0) **Closed issues:** - Cannot check balance using cli [\#149](https://github.com/cybercongress/go-cyber/issues/149) - Cli: Add possibility to restore acc from priv keys [\#146](https://github.com/cybercongress/go-cyber/issues/146) - Index out of range for cids with not calculated rank yet. [\#139](https://github.com/cybercongress/go-cyber/issues/139) - CID rank merkle proofs [\#133](https://github.com/cybercongress/go-cyber/issues/133) - Go mod Ci dependency error [\#128](https://github.com/cybercongress/go-cyber/issues/128) - Update to cosmos 29 [\#126](https://github.com/cybercongress/go-cyber/issues/126) - Simple go cyberd client [\#122](https://github.com/cybercongress/go-cyber/issues/122) - Write down bandwidth specification [\#114](https://github.com/cybercongress/go-cyber/issues/114) - Consensus hash [\#112](https://github.com/cybercongress/go-cyber/issues/112) - Add remainig bandwidth endpoint [\#109](https://github.com/cybercongress/go-cyber/issues/109) - Make docker container based on nvidia-gpu image. [\#104](https://github.com/cybercongress/go-cyber/issues/104) - Index transactions by addresses. [\#103](https://github.com/cybercongress/go-cyber/issues/103) - Calculate rank in ||, post results each 600 blocks. [\#101](https://github.com/cybercongress/go-cyber/issues/101) - Account inmem balances should be updated by wrapping accountKeeper [\#99](https://github.com/cybercongress/go-cyber/issues/99) - Get rid of RPC proxy [\#94](https://github.com/cybercongress/go-cyber/issues/94) - Linkchains support [\#91](https://github.com/cybercongress/go-cyber/issues/91) - Include addresses into knowledge graph [\#90](https://github.com/cybercongress/go-cyber/issues/90) - Graphics for whitepaper [\#88](https://github.com/cybercongress/go-cyber/issues/88) - Add bandwidth by stake [\#77](https://github.com/cybercongress/go-cyber/issues/77) - Launch testnet Euler [\#73](https://github.com/cybercongress/go-cyber/issues/73) - Test Ethereum Network Statistical Significance [\#52](https://github.com/cybercongress/go-cyber/issues/52) - Cyberd landing design [\#51](https://github.com/cybercongress/go-cyber/issues/51) - Simulation [\#31](https://github.com/cybercongress/go-cyber/issues/31) - Link Chain PoC | Zeronet [\#26](https://github.com/cybercongress/go-cyber/issues/26) - Write benchmark and test SpringRank with different amount of objects/edges [\#22](https://github.com/cybercongress/go-cyber/issues/22) - Parse Ethereum network and calculate SpringRank [\#21](https://github.com/cybercongress/go-cyber/issues/21) - Research basic chains fundamentals [\#15](https://github.com/cybercongress/go-cyber/issues/15) - Perfomance testing of Solana [\#10](https://github.com/cybercongress/go-cyber/issues/10) - Research on perfomance of consensus computers [\#9](https://github.com/cybercongress/go-cyber/issues/9) - Perfomance testing scenario for cyberd [\#8](https://github.com/cybercongress/go-cyber/issues/8) **Merged pull requests:** - \[euler\] Launch euler testnet [\#148](https://github.com/cybercongress/go-cyber/pull/148) ([hleb-albau](https://github.com/hleb-albau)) - Cli: Add possibility to restore acc from priv keys [\#147](https://github.com/cybercongress/go-cyber/pull/147) ([arturalbov](https://github.com/arturalbov)) - Rank merkle proofs [\#144](https://github.com/cybercongress/go-cyber/pull/144) ([arturalbov](https://github.com/arturalbov)) - Setup bw params [\#143](https://github.com/cybercongress/go-cyber/pull/143) ([hleb-albau](https://github.com/hleb-albau)) - Merkle tree implementation [\#141](https://github.com/cybercongress/go-cyber/pull/141) ([arturalbov](https://github.com/arturalbov)) - \#139 Index out of range for cids with not calculated rank yet. [\#140](https://github.com/cybercongress/go-cyber/pull/140) ([hleb-albau](https://github.com/hleb-albau)) - Fix http client and rank logs [\#137](https://github.com/cybercongress/go-cyber/pull/137) ([hleb-albau](https://github.com/hleb-albau)) - \[euler-dev3\] New testnet [\#136](https://github.com/cybercongress/go-cyber/pull/136) ([hleb-albau](https://github.com/hleb-albau)) - \#101 Copy state before index creation [\#135](https://github.com/cybercongress/go-cyber/pull/135) ([hleb-albau](https://github.com/hleb-albau)) - \#92 Populate state with random addresses [\#134](https://github.com/cybercongress/go-cyber/pull/134) ([hleb-albau](https://github.com/hleb-albau)) - Small fixes [\#131](https://github.com/cybercongress/go-cyber/pull/131) ([arturalbov](https://github.com/arturalbov)) - Parallel rank calculation [\#130](https://github.com/cybercongress/go-cyber/pull/130) ([arturalbov](https://github.com/arturalbov)) - Update stake index every block [\#129](https://github.com/cybercongress/go-cyber/pull/129) ([hleb-albau](https://github.com/hleb-albau)) - \#126 Update to cosmos 29 [\#127](https://github.com/cybercongress/go-cyber/pull/127) ([hleb-albau](https://github.com/hleb-albau)) - Refactoring [\#125](https://github.com/cybercongress/go-cyber/pull/125) ([hleb-albau](https://github.com/hleb-albau)) - Various Bug fixes [\#124](https://github.com/cybercongress/go-cyber/pull/124) ([hleb-albau](https://github.com/hleb-albau)) - In-memory storages refactoring [\#123](https://github.com/cybercongress/go-cyber/pull/123) ([arturalbov](https://github.com/arturalbov)) - \#114 Write bw specification [\#121](https://github.com/cybercongress/go-cyber/pull/121) ([hleb-albau](https://github.com/hleb-albau)) - WIP \#114 Add cbdbank module [\#120](https://github.com/cybercongress/go-cyber/pull/120) ([hleb-albau](https://github.com/hleb-albau)) - Update readme [\#119](https://github.com/cybercongress/go-cyber/pull/119) ([hleb-albau](https://github.com/hleb-albau)) - Clean up folders [\#118](https://github.com/cybercongress/go-cyber/pull/118) ([arturalbov](https://github.com/arturalbov)) - \#103 Index transactions by signers. [\#117](https://github.com/cybercongress/go-cyber/pull/117) ([hleb-albau](https://github.com/hleb-albau)) ## [v0.0.8](https://github.com/cybercongress/go-cyber/tree/v0.0.8) (2018-12-11) [Full Changelog](https://github.com/cybercongress/go-cyber/compare/v0.0.7...v0.0.8) **Closed issues:** - Cid validation [\#93](https://github.com/cybercongress/go-cyber/issues/93) - Update to cosmos-sdk version 0.26.1 [\#79](https://github.com/cybercongress/go-cyber/issues/79) - Add possibility to join for new validators. [\#75](https://github.com/cybercongress/go-cyber/issues/75) - Calculate rank using GPU [\#74](https://github.com/cybercongress/go-cyber/issues/74) - Create basic wiki cyberd indexer [\#71](https://github.com/cybercongress/go-cyber/issues/71) - Build node releases with cleveldb [\#59](https://github.com/cybercongress/go-cyber/issues/59) - Remove 'cosmosaccaddr' prefix from cyberd address [\#39](https://github.com/cybercongress/go-cyber/issues/39) - Create cyberd PoC based on Cosmos SDK [\#37](https://github.com/cybercongress/go-cyber/issues/37) - Make up cyberd landing [\#87](https://github.com/cybercongress/go-cyber/issues/87) - Draw logo for cyberd [\#16](https://github.com/cybercongress/go-cyber/issues/16) - Build basic economic model [\#1](https://github.com/cybercongress/go-cyber/issues/1) **Merged pull requests:** - \#76 Define Basic RPC specification [\#111](https://github.com/cybercongress/go-cyber/pull/111) ([hleb-albau](https://github.com/hleb-albau)) - \#104 Make docker container based on nvidia-gpu image [\#110](https://github.com/cybercongress/go-cyber/pull/110) ([hleb-albau](https://github.com/hleb-albau)) - \[DON'T MERGE\] Add bandwidth by stake. Part 2. [\#108](https://github.com/cybercongress/go-cyber/pull/108) ([arturalbov](https://github.com/arturalbov)) - Add bandwidth by stake Part 1 [\#107](https://github.com/cybercongress/go-cyber/pull/107) ([arturalbov](https://github.com/arturalbov)) - \#93 Cid validation [\#106](https://github.com/cybercongress/go-cyber/pull/106) ([hleb-albau](https://github.com/hleb-albau)) - \#78 Add guide `How to join network as validator` [\#105](https://github.com/cybercongress/go-cyber/pull/105) ([hleb-albau](https://github.com/hleb-albau)) - \#1 Build basic economic model [\#102](https://github.com/cybercongress/go-cyber/pull/102) ([hleb-albau](https://github.com/hleb-albau)) - Update cosmos to 0.27.0 [\#100](https://github.com/cybercongress/go-cyber/pull/100) ([hleb-albau](https://github.com/hleb-albau)) - Small fixes for validators joining [\#98](https://github.com/cybercongress/go-cyber/pull/98) ([arturalbov](https://github.com/arturalbov)) - Remove poc folder [\#97](https://github.com/cybercongress/go-cyber/pull/97) ([hleb-albau](https://github.com/hleb-albau)) - Add possibility to join for new validators [\#96](https://github.com/cybercongress/go-cyber/pull/96) ([arturalbov](https://github.com/arturalbov)) - Calculate eth network significance [\#85](https://github.com/cybercongress/go-cyber/pull/85) ([hleb-albau](https://github.com/hleb-albau)) - 74 gpu rank calculation [\#83](https://github.com/cybercongress/go-cyber/pull/83) ([hleb-albau](https://github.com/hleb-albau)) - Remove 'cosmosaccaddr' prefix from cyberd address [\#82](https://github.com/cybercongress/go-cyber/pull/82) ([arturalbov](https://github.com/arturalbov)) - UPD docs\_upd job [\#81](https://github.com/cybercongress/go-cyber/pull/81) ([SaveTheAles](https://github.com/SaveTheAles)) - Update cosmos-sdk version to 0.26.1 [\#80](https://github.com/cybercongress/go-cyber/pull/80) ([arturalbov](https://github.com/arturalbov)) ## [v0.0.7](https://github.com/cybercongress/go-cyber/tree/v0.0.7) (2018-10-25) [Full Changelog](https://github.com/cybercongress/go-cyber/compare/v0.0.6...v0.0.7) **Closed issues:** - Proxy service. Add search pagination [\#69](https://github.com/cybercongress/go-cyber/issues/69) - Proxy service. Search request with "spaces" fails [\#67](https://github.com/cybercongress/go-cyber/issues/67) - Non-deterministic rank calculation [\#66](https://github.com/cybercongress/go-cyber/issues/66) - Claim service: increment tx sequence manually [\#64](https://github.com/cybercongress/go-cyber/issues/64) - Add send tokens endpoint to proxy [\#62](https://github.com/cybercongress/go-cyber/issues/62) **Merged pull requests:** - \#71 Create basic wiki cyberd indexer [\#72](https://github.com/cybercongress/go-cyber/pull/72) ([hleb-albau](https://github.com/hleb-albau)) - Proxy service. Add search pagination [\#70](https://github.com/cybercongress/go-cyber/pull/70) ([arturalbov](https://github.com/arturalbov)) - Proxy service. Search request with spaces fails [\#68](https://github.com/cybercongress/go-cyber/pull/68) ([arturalbov](https://github.com/arturalbov)) - Claim service: increment tx sequence manually [\#65](https://github.com/cybercongress/go-cyber/pull/65) ([arturalbov](https://github.com/arturalbov)) ## [v0.0.6](https://github.com/cybercongress/go-cyber/tree/v0.0.6) (2018-10-24) [Full Changelog](https://github.com/cybercongress/go-cyber/compare/v0.0.5...v0.0.6) ## [v0.0.5](https://github.com/cybercongress/go-cyber/tree/v0.0.5) (2018-10-23) [Full Changelog](https://github.com/cybercongress/go-cyber/compare/v0.0.4...v0.0.5) **Closed issues:** - \[RPC\] Fix small finding [\#57](https://github.com/cybercongress/go-cyber/issues/57) ## [v0.0.4](https://github.com/cybercongress/go-cyber/tree/v0.0.4) (2018-10-23) [Full Changelog](https://github.com/cybercongress/go-cyber/compare/v0.0.3...v0.0.4) **Closed issues:** - Service to claim cyberd zeronet tokens [\#61](https://github.com/cybercongress/go-cyber/issues/61) - Update cosmos-sdk to latest dev branch version [\#56](https://github.com/cybercongress/go-cyber/issues/56) - Perfomance Degradation: Heavy Disk Usage [\#50](https://github.com/cybercongress/go-cyber/issues/50) **Merged pull requests:** - Add send tokens endpoint to proxy [\#63](https://github.com/cybercongress/go-cyber/pull/63) ([arturalbov](https://github.com/arturalbov)) - Claim service [\#60](https://github.com/cybercongress/go-cyber/pull/60) ([arturalbov](https://github.com/arturalbov)) - \#57 \[RPC\] Fix small finding [\#58](https://github.com/cybercongress/go-cyber/pull/58) ([hleb-albau](https://github.com/hleb-albau)) - Update cosmos-sdk to latest dev branch version [\#53](https://github.com/cybercongress/go-cyber/pull/53) ([hleb-albau](https://github.com/hleb-albau)) ## [v0.0.3](https://github.com/cybercongress/go-cyber/tree/v0.0.3) (2018-10-19) [Full Changelog](https://github.com/cybercongress/go-cyber/compare/v0.0.2...v0.0.3) **Closed issues:** - RPC Client: /search on non existing cid return first added cid [\#48](https://github.com/cybercongress/go-cyber/issues/48) - CLI: Add "wait\_for\_confirmation" Flag [\#47](https://github.com/cybercongress/go-cyber/issues/47) - Write validation logic of IPFS hash for Losion Zeronet [\#18](https://github.com/cybercongress/go-cyber/issues/18) - Genesis Zeronet [\#17](https://github.com/cybercongress/go-cyber/issues/17) - Performance testing of Zeronet [\#4](https://github.com/cybercongress/go-cyber/issues/4) **Merged pull requests:** - Add cyberdproxy process to docker container. Add status endpoint [\#55](https://github.com/cybercongress/go-cyber/pull/55) ([arturalbov](https://github.com/arturalbov)) - Proxy rpc [\#54](https://github.com/cybercongress/go-cyber/pull/54) ([arturalbov](https://github.com/arturalbov)) ## [v0.0.2](https://github.com/cybercongress/go-cyber/tree/v0.0.2) (2018-10-05) [Full Changelog](https://github.com/cybercongress/go-cyber/compare/v0.0.1...v0.0.2) **Closed issues:** - Cosmos PoC: Integrate Rank Calculation [\#43](https://github.com/cybercongress/go-cyber/issues/43) - Cosmos PoC: Extenend Standart Tendermint RPC API [\#42](https://github.com/cybercongress/go-cyber/issues/42) - Implement persistent storage for links. [\#40](https://github.com/cybercongress/go-cyber/issues/40) - run extra node for cyberd [\#20](https://github.com/cybercongress/go-cyber/issues/20) **Merged pull requests:** - Fix search on non existing cid [\#49](https://github.com/cybercongress/go-cyber/pull/49) ([arturalbov](https://github.com/arturalbov)) - Add Circle CI build job [\#46](https://github.com/cybercongress/go-cyber/pull/46) ([arturalbov](https://github.com/arturalbov)) - Extenend Standart Tendermint RPC API [\#45](https://github.com/cybercongress/go-cyber/pull/45) ([arturalbov](https://github.com/arturalbov)) - \#43 Simplest Rank [\#44](https://github.com/cybercongress/go-cyber/pull/44) ([hleb-albau](https://github.com/hleb-albau)) - \#40 introduce in-memory store [\#41](https://github.com/cybercongress/go-cyber/pull/41) ([hleb-albau](https://github.com/hleb-albau)) - \#37 redesign db, app refactor [\#38](https://github.com/cybercongress/go-cyber/pull/38) ([hleb-albau](https://github.com/hleb-albau)) - Cosmos POC: Clean up CLI [\#35](https://github.com/cybercongress/go-cyber/pull/35) ([arturalbov](https://github.com/arturalbov)) - Update cyberd/cosmos README [\#34](https://github.com/cybercongress/go-cyber/pull/34) ([arturalbov](https://github.com/arturalbov)) ## [v0.0.1](https://github.com/cybercongress/go-cyber/tree/v0.0.1) (2018-09-25) **Closed issues:** - Make cyberd docs to be included into common wiki. [\#32](https://github.com/cybercongress/go-cyber/issues/32) - Write LT/NLT logic to Losion Zeronet [\#19](https://github.com/cybercongress/go-cyber/issues/19) - Research basic technologies [\#14](https://github.com/cybercongress/go-cyber/issues/14) - Research basic papers [\#13](https://github.com/cybercongress/go-cyber/issues/13) - Perfomance testing of Ethermint [\#12](https://github.com/cybercongress/go-cyber/issues/12) - Perfomance testing of Plasma [\#11](https://github.com/cybercongress/go-cyber/issues/11) - Perfomance testing of PoA networks [\#7](https://github.com/cybercongress/go-cyber/issues/7) - Cleanup paper [\#6](https://github.com/cybercongress/go-cyber/issues/6) - Perfomance testing of EOS [\#3](https://github.com/cybercongress/go-cyber/issues/3) **Merged pull requests:** - Genesis zeronet: Cosmos SDK [\#33](https://github.com/cybercongress/go-cyber/pull/33) ([arturalbov](https://github.com/arturalbov)) - \[WIP\] 21 calculate spring rank for ethereum [\#23](https://github.com/cybercongress/go-cyber/pull/23) ([hleb-albau](https://github.com/hleb-albau)) - Fixing typo [\#2](https://github.com/cybercongress/go-cyber/pull/2) ([trummax](https://github.com/trummax)) \* *This Change Log was automatically generated by [github_changelog_generator](https://github.com/skywinder/Github-Changelog-Generator)* ================================================ FILE: CONTRIBUTING.md ================================================ # Contributing to go-cyber Thank you for considering a contribution to **go-cyber**! This guide explains how to: * Get started * Development workflow * Get help if you encounter trouble ## Get in touch Before starting to work on a feature or a fix, please open an issue to discuss the use case or bug with us. This can save both you and us a lot of time. For any non-trivial change, we'll ask you to create a short design document explaining: * Why is this change done? What's the use case? * What test cases should it have? What could go wrong? * How will it roughly be implemented? (We'll happily provide code pointers to save you time) ## Development Workflow ### Development Setup Please, use [development environment setup guide](./docs/help/setup_dev_env.md). ### Creating Commits And Writing Commit Messages The commit messages that accompany your code changes are an important piece of documentation, please follow these guidelines when writing commit messages: * Keep commits discrete: avoid including multiple unrelated changes in a single commit * Keep commits self-contained: avoid spreading a single change across multiple commits. A single commit should make sense in isolation * Include GitHub issue in the commit message on a first line at the beginning. Example: ``` #123 Refactor CONTRIBUTING.md --Add Creating Commits And Writing Commit Messages Section ``` ### Submitting Your Change After you submit your pull request, a core developer will review it. It is normal that this takes several iterations, so don't get discouraged by change requests. They ensure the high quality that we all enjoy. ## Getting Help If you run into any trouble, please reach out to us on the issue you are working on. ## Our Thanks We deeply appreciate your effort toward improving go-cyber. For any contribution, large or small, you will be immortalized in the release notes for the version you've contributed to. ================================================ FILE: Dockerfile ================================================ ########################################################################################### # Build cyber ########################################################################################### FROM ubuntu:20.04 ENV GO_VERSION '1.22.7' ENV GO_ARCH 'linux-amd64' ENV GO_BIN_SHA 'fc5d49b7a5035f1f1b265c17aa86e9819e6dc9af8260ad61430ee7fbe27881bb' ENV DEBIAN_FRONTEND=noninteractive ENV DAEMON_HOME /root/.cyber ENV DAEMON_RESTART_AFTER_UPGRADE=true ENV DAEMON_ALLOW_DOWNLOAD_BINARIES=true ENV DAEMON_LOG_BUFFER_SIZE=1048 ENV UNSAFE_SKIP_BACKUP=true ENV DAEMON_NAME cyber ENV BUILD_DIR /build ENV PATH /usr/local/go/bin:/root/.cargo/bin:/root/cargo/env:/root/.cyber/scripts:$PATH ENV CUDA_VER '11.4.4-1' ENV PATH="/usr/local/go/bin:/usr/local/cuda/bin:$PATH" # Install go and required deps ########################################################################################### RUN apt-get update && apt-get install -y --no-install-recommends wget ca-certificates \ && wget -O go.tgz https://golang.org/dl/go${GO_VERSION}.linux-amd64.tar.gz \ && echo "${GO_BIN_SHA} *go.tgz" | sha256sum -c - \ && tar -C /usr/local -xzf go.tgz \ && rm go.tgz \ && go version COPY . /sources WORKDIR /sources # Install CUDA, build tools and compile cyber ########################################################################################### RUN apt-get update && apt-get -y install --no-install-recommends \ make gcc g++ \ curl \ gnupg \ git \ software-properties-common \ # nvidia-cuda-toolkit \ # Install cuda selected version instead nvidia-cuda-toolkit && wget https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2004/x86_64/cuda-ubuntu2004.pin \ && mv cuda-ubuntu2004.pin /etc/apt/preferences.d/cuda-repository-pin-600 \ && apt-key adv --fetch-keys https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2004/x86_64/3bf863cc.pub \ && add-apt-repository "deb https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2004/x86_64/ /" \ && apt-get update \ && apt-get install cuda=${CUDA_VER} -y --no-install-recommends \ && mkdir -p /cyber/cosmovisor/upgrades/v3/bin \ && mkdir -p /cyber/cosmovisor/upgrades/v4/bin \ && mkdir -p /cyber/cosmovisor/upgrades/v6/bin \ && mkdir -p /cyber/cosmovisor/upgrades/v7/bin \ # Compile cyber for v3 version ########################################################################################### && git checkout v3.0.1 \ && cd /sources/x/rank/cuda \ && make build \ && cd /sources \ && make build CUDA_ENABLED=true \ && cp ./build/cyber /cyber/cosmovisor/upgrades/v3/bin/ \ && rm -rf ./build \ # Compile cyber for v4 version ########################################################################################### && git checkout v5.2.0 \ && cd /sources/x/rank/cuda \ && make build \ && cd /sources \ && make build CUDA_ENABLED=true \ && cp ./build/cyber /cyber/cosmovisor/upgrades/v4/bin/ \ && rm -rf ./build \ # Compile cyber for v6 version ########################################################################################### && git checkout v6.0.1 \ && cd /sources/x/rank/cuda \ && make build \ && cd /sources \ && make build CUDA_ENABLED=true \ && cp ./build/cyber /cyber/cosmovisor/upgrades/v6/bin/ \ && rm -rf ./build \ # Compile cyber for v7 version ########################################################################################### && git checkout v7.0.2 \ && cd /sources/x/rank/cuda \ && make build \ && cd /sources \ && make build CUDA_ENABLED=true \ && cp ./build/cyber /cyber/cosmovisor/upgrades/v7/bin/ \ && rm -rf ./build \ # Cleanup ########################################################################################### && apt-get purge -y git \ make \ cuda \ gcc g++ \ curl \ gnupg \ python3.8 \ && go clean --cache -i \ && apt-get remove --purge '^nvidia-.*' -y \ && apt-get autoremove -y \ && apt-get clean # Install cosmovisor ########################################################################################### RUN wget -O cosmovisor.tgz https://github.com/cosmos/cosmos-sdk/releases/download/cosmovisor%2Fv1.5.0/cosmovisor-v1.5.0-linux-amd64.tar.gz \ && tar -xzf cosmovisor.tgz \ && cp cosmovisor /usr/bin/cosmovisor \ && chmod +x /usr/bin/cosmovisor \ && rm cosmovisor.tgz && rm -fR $BUILD_DIR/* && rm -fR $BUILD_DIR/.*[a-z] # Copy startup scripts and genesis ########################################################################################### WORKDIR / COPY start_script.sh start_script.sh COPY entrypoint.sh /entrypoint.sh RUN wget -O /genesis.json https://gateway.ipfs.cybernode.ai/ipfs/QmYubyVNfghD4xCrTFj26zBwrF9s5GJhi1TmxvrwmJCipr \ && chmod +x start_script.sh \ && chmod +x /entrypoint.sh # Start ############################################################################### EXPOSE 26656 26657 1317 9090 26660 ENTRYPOINT ["/entrypoint.sh"] CMD ["./start_script.sh"] ================================================ FILE: LICENSE ================================================ Cyber License Don’t believe, don’t fear, don’t ask. ================================================ FILE: Makefile ================================================ #!/usr/bin/make -f CUDA_ENABLED ?= false LEDGER_ENABLED ?= true VERSION := $(shell echo $(shell git describe --tags) | sed 's/^v//') COMMIT := $(shell git log -1 --format='%H') BFT_VERSION := $(shell go list -m github.com/cometbft/cometbft | sed 's:.* ::') BINDIR ?= $(GOPATH)/bin BUILDDIR ?= $(CURDIR)/build/ # for dockerized protobuf tools DOCKER := $(shell which docker) BUF_IMAGE=bufbuild/buf@sha256:3cb1f8a4b48bd5ad8f09168f10f607ddc318af202f5c057d52a45216793d85e5 #v1.4.0 DOCKER_BUF := $(DOCKER) run --rm -v $(CURDIR):/workspace --workdir /workspace $(BUF_IMAGE) HTTPS_GIT := https://github.com/cybercongress/go-cyber.git export GO111MODULE = on ############################################################################### ### Build Flags/Tags ### ############################################################################### build_tags = netgo ifeq ($(LEDGER_ENABLED),true) ifeq ($(OS),Windows_NT) GCCEXE = $(shell where gcc.exe 2> NUL) ifeq ($(GCCEXE),) $(error gcc.exe not installed for ledger support, please install or set LEDGER_ENABLED=false) else build_tags += ledger endif else UNAME_S = $(shell uname -s) ifeq ($(UNAME_S),OpenBSD) $(warning OpenBSD detected, disabling ledger support (https://github.com/cosmos/cosmos-sdk/issues/1988)) else GCC = $(shell command -v gcc 2> /dev/null) ifeq ($(GCC),) $(error gcc not installed for ledger support, please install or set LEDGER_ENABLED=false) else build_tags += ledger endif endif endif endif ifeq ($(CUDA_ENABLED),true) NVCC_RESULT := $(shell which nvcc 2> NULL) NVCC_TEST := $(notdir $(NVCC_RESULT)) ifeq ($(NVCC_TEST),nvcc) build_tags += cuda else $(error CUDA not installed for GPU support, please install or set CUDA_ENABLED=false) endif endif build_tags += $(BUILD_TAGS) build_tags := $(strip $(build_tags)) whitespace := empty = $(whitespace) $(whitespace) comma := , build_tags_comma_sep := $(subst $(empty),$(comma),$(build_tags)) ldflags = -X github.com/cosmos/cosmos-sdk/version.Name=cyber \ -X github.com/cosmos/cosmos-sdk/version.AppName=cyber \ -X github.com/cosmos/cosmos-sdk/version.Version=$(VERSION) \ -X github.com/cosmos/cosmos-sdk/version.Commit=$(COMMIT) \ -X "github.com/cosmos/cosmos-sdk/version.BuildTags=$(build_tags_comma_sep)" \ -X github.com/cometbft/cometbft/version.BFTVer=$(BFT_VERSION) ldflags += $(LDFLAGS) ldflags := $(strip $(ldflags)) BUILD_FLAGS := -tags "$(build_tags_comma_sep)" -ldflags '$(ldflags)' -trimpath include contrib/devtools/Makefile all: build format lint test .PHONY: all ############################################################################### ### Build ### ############################################################################### build: go.sum go build $(BUILD_FLAGS) -o $(BUILDDIR) ./cmd/cyber install: go.sum go install $(BUILD_FLAGS) ./cmd/cyber .PHONY: build install ############################################################################### ### Tools / Dependencies ### ############################################################################### go-mod-cache: go.sum @echo "--> Download go modules to local cache" @go mod download go.sum: go.mod @echo "--> Ensure dependencies have not been modified" go mod verify go mod tidy .PHONY: go.sum .PHONY: go.sum go-mod-cache ############################################################################### ### Localnet ### ############################################################################### # TODO update localnet flow #build-docker-cybernode: build-linux # $(MAKE) -C networks/local # ## Run a 4-node testnet locally #localnet-start: localnet-stop # @if ! [ -f build/node0/cyber/config/genesis.json ]; then docker run --rm -v $(CURDIR)/build:/cyber:Z cybercongress/cyber testnet --v 4 -o . --starting-ip-address 192.168.10.2 --keyring-backend=test --chain-id=chain-local ; fi # docker-compose up -d # ## Stop testnet #localnet-stop: # docker-compose down ############################################################################### ### Linting ### ############################################################################### format-tools: go install mvdan.cc/gofumpt@v0.4.0 go install github.com/client9/misspell/cmd/misspell@v0.3.4 go install golang.org/x/tools/cmd/goimports@latest lint: format-tools golangci-lint run --tests=false find . -name '*.go' -type f -not -path "./vendor*" -not -path "*.git*" -not -path "*_test.go" | xargs gofumpt -d format: format-tools find . -name '*.go' -type f -not -path "./vendor*" -not -path "*.git*" -not -path "./client/docs/statik/statik.go" | xargs gofumpt -w find . -name '*.go' -type f -not -path "./vendor*" -not -path "*.git*" -not -path "./client/docs/statik/statik.go" | xargs misspell -w find . -name '*.go' -type f -not -path "./vendor*" -not -path "*.git*" -not -path "./client/docs/statik/statik.go" | xargs goimports -w -local github.com/cybercongress/go-cyber ############################################################################### ### Protobuf ### ############################################################################### protoVer=0.13.1 protoImageName=ghcr.io/cosmos/proto-builder:$(protoVer) protoImage=$(DOCKER) run --rm -v $(CURDIR):/workspace --workdir /workspace $(protoImageName) proto-all: proto-format proto-lint proto-gen proto-gen: @echo "Generating Protobuf files" @$(protoImage) sh ./scripts/protocgen.sh proto-format: @echo "Formatting Protobuf files" @$(protoImage) find ./ -name "*.proto" -exec clang-format -i {} \; # npm install -g swagger2openapi swagger-merger swagger-combine proto-swagger-gen: @echo "Generating Protobuf Swagger OpenAPI" @./scripts/protoc_swagger_openapi_gen.sh proto-lint: @$(DOCKER_BUF) lint --error-format=json proto-check-breaking: @$(DOCKER_BUF) breaking --against $(HTTPS_GIT)#branch=main ############################################################################### ### Docs ### ############################################################################### # TODO update statik and swagger flow #update-swagger-docs: statik proto-swagger-gen # $(BINDIR)/statik -src=client/docs/swagger-ui -dest=client/docs -f -m # #.PHONY: update-swagger-docs ================================================ FILE: README.md ================================================ # go-cyber Collective intelligence substrate. Convergent computation over a knowledge graph with on-chain diffusion model, built on Cosmos SDK. [![version](https://img.shields.io/github/release/cyberia-to/go-cyber.svg?style=flat-square)](https://github.com/cyberia-to/go-cyber/releases/latest) ![Cosmos-SDK](https://img.shields.io/static/v1.svg?label=cosmos-sdk&message=0.47.16&color=blue&style=flat-square) ![CometBFT](https://img.shields.io/static/v1.svg?label=cometbft&message=0.37.18&color=blue&style=flat-square) ![IBC](https://img.shields.io/static/v1.svg?label=ibc-go&message=7.10.0&color=blue&style=flat-square) ![CosmWasm](https://img.shields.io/static/v1.svg?label=wasmd&message=0.46.0&color=blue&style=flat-square) [![license](https://img.shields.io/badge/License-Cyber-brightgreen.svg?style=flat-square)](https://github.com/cyberia-to/go-cyber/blob/main/LICENSE) ## Networks | Network | Hub | Launch | Token | |---|---|---|---| | [Bostrom](https://cyb.ai) | Bootloader Hub | 2021 | BOOT | | [Space Pussy](https://spacepussy.ai) | Meme Community Network | 2022 | PUSSY | ## Build ```bash make install ``` Without GPU (CLI-only, connects to remote node): ```bash make install CUDA_ENABLED=false ``` ## Quick Start - RPC: `https://rpc.bostrom.cybernode.ai/` - REST: `https://lcd.bostrom.cybernode.ai/` - Seed: `d0518ce9881a4b0c5872e5e9b7c4ea8d760dad3f@85.10.207.173:26656` Use [localbostrom](networks/local/) for local development. ## Documentation See [docs/](docs/README.md) for validator setup, CLI guides, module specs, and tutorials. ================================================ FILE: app/ante.go ================================================ package app import ( errorsmod "cosmossdk.io/errors" wasmkeeper "github.com/CosmWasm/wasmd/x/wasm/keeper" wasmtypes "github.com/CosmWasm/wasmd/x/wasm/types" storetypes "github.com/cosmos/cosmos-sdk/store/types" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" "github.com/cosmos/cosmos-sdk/x/auth/ante" ibcante "github.com/cosmos/ibc-go/v7/modules/core/ante" ibckeeper "github.com/cosmos/ibc-go/v7/modules/core/keeper" ) // HandlerOptions extend the SDK's AnteHandler options by requiring the IBC // channel keeper. type HandlerOptions struct { ante.HandlerOptions IBCKeeper *ibckeeper.Keeper WasmConfig *wasmtypes.WasmConfig WasmKeeper *wasmkeeper.Keeper TXCounterStoreKey storetypes.StoreKey TxEncoder sdk.TxEncoder // ProofExemptContracts is a list of CosmWasm contract addresses // whose "submit_proof" execute messages are exempt from gas fees. // This allows miners to submit PoW proofs without holding tokens. ProofExemptContracts []string } func NewAnteHandler(options HandlerOptions) (sdk.AnteHandler, error) { if options.AccountKeeper == nil { return nil, errorsmod.Wrap(sdkerrors.ErrLogic, "account keeper is required for AnteHandler") } if options.BankKeeper == nil { return nil, errorsmod.Wrap(sdkerrors.ErrLogic, "bank keeper is required for AnteHandler") } if options.SignModeHandler == nil { return nil, errorsmod.Wrap(sdkerrors.ErrLogic, "sign mode handler is required for ante builder") } if options.WasmConfig == nil { return nil, errorsmod.Wrap(sdkerrors.ErrLogic, "wasm config is required for ante builder") } if options.TXCounterStoreKey == nil { return nil, errorsmod.Wrap(sdkerrors.ErrLogic, "tx counter key is required for ante builder") } sigGasConsumer := options.SigGasConsumer if sigGasConsumer == nil { sigGasConsumer = ante.DefaultSigVerificationGasConsumer } anteDecorators := []sdk.AnteDecorator{ ante.NewSetUpContextDecorator(), // outermost AnteDecorator. SetUpContext must be called first wasmkeeper.NewLimitSimulationGasDecorator(options.WasmConfig.SimulationGasLimit), // after setup context to enforce limits early wasmkeeper.NewCountTXDecorator(options.TXCounterStoreKey), wasmkeeper.NewGasRegisterDecorator(options.WasmKeeper.GetGasRegister()), ante.NewExtensionOptionsDecorator(options.ExtensionOptionChecker), ante.NewValidateBasicDecorator(), ante.NewTxTimeoutHeightDecorator(), ante.NewValidateMemoDecorator(options.AccountKeeper), ante.NewConsumeGasForTxSizeDecorator(options.AccountKeeper), NewProofExemptDecorator(options.HandlerOptions, options.ProofExemptContracts), ante.NewSetPubKeyDecorator(options.AccountKeeper), // SetPubKeyDecorator must be called before all signature verification decorators ante.NewValidateSigCountDecorator(options.AccountKeeper), ante.NewSigGasConsumeDecorator(options.AccountKeeper, sigGasConsumer), ante.NewSigVerificationDecorator(options.AccountKeeper, options.SignModeHandler), ante.NewIncrementSequenceDecorator(options.AccountKeeper), ibcante.NewRedundantRelayDecorator(options.IBCKeeper), } return sdk.ChainAnteDecorators(anteDecorators...), nil } ================================================ FILE: app/app.go ================================================ package app import ( autocliv1 "cosmossdk.io/api/cosmos/autocli/v1" "cosmossdk.io/math" "fmt" "github.com/cometbft/cometbft/crypto" "github.com/cometbft/cometbft/libs/bytes" "github.com/cosmos/cosmos-sdk/crypto/keys/ed25519" "github.com/cosmos/cosmos-sdk/server" storetypes "github.com/cosmos/cosmos-sdk/store/types" "github.com/cosmos/cosmos-sdk/types/bech32" "github.com/cosmos/cosmos-sdk/x/bank" bankkeeper "github.com/cosmos/cosmos-sdk/x/bank/keeper" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" distrtypes "github.com/cosmos/cosmos-sdk/x/distribution/types" v7 "github.com/cybercongress/go-cyber/v7/app/upgrades/v7" slashingtypes "github.com/cosmos/cosmos-sdk/x/slashing/types" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" v5 "github.com/cybercongress/go-cyber/v7/app/upgrades/v5" v6 "github.com/cybercongress/go-cyber/v7/app/upgrades/v6" "github.com/cybercongress/go-cyber/v7/client/docs" bandwidthkeeper "github.com/cybercongress/go-cyber/v7/x/bandwidth/keeper" cyberbankkeeper "github.com/cybercongress/go-cyber/v7/x/cyberbank/keeper" graphkeeper "github.com/cybercongress/go-cyber/v7/x/graph/keeper" rankkeeper "github.com/cybercongress/go-cyber/v7/x/rank/keeper" "io" "os" "time" reflectionv1 "cosmossdk.io/api/cosmos/reflection/v1" "github.com/cosmos/cosmos-sdk/runtime" "github.com/cosmos/cosmos-sdk/x/auth/posthandler" v2 "github.com/cybercongress/go-cyber/v7/app/upgrades/v2" v3 "github.com/cybercongress/go-cyber/v7/app/upgrades/v3" v4 "github.com/cybercongress/go-cyber/v7/app/upgrades/v4" "github.com/cosmos/cosmos-sdk/client/grpc/tmservice" ibcclientclient "github.com/cosmos/ibc-go/v7/modules/core/02-client/client" "github.com/cybercongress/go-cyber/v7/app/keepers" "github.com/cybercongress/go-cyber/v7/app/upgrades" dbm "github.com/cometbft/cometbft-db" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/codec/types" servertypes "github.com/cosmos/cosmos-sdk/server/types" authtx "github.com/cosmos/cosmos-sdk/x/auth/tx" "github.com/spf13/cast" abci "github.com/cometbft/cometbft/abci/types" "github.com/cometbft/cometbft/libs/log" tmos "github.com/cometbft/cometbft/libs/os" "github.com/cosmos/cosmos-sdk/baseapp" nodeservice "github.com/cosmos/cosmos-sdk/client/grpc/node" "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/server/api" "github.com/cosmos/cosmos-sdk/server/config" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" "github.com/cosmos/cosmos-sdk/version" "github.com/cosmos/cosmos-sdk/x/auth/ante" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" "github.com/cosmos/cosmos-sdk/x/crisis" paramsclient "github.com/cosmos/cosmos-sdk/x/params/client" paramstypes "github.com/cosmos/cosmos-sdk/x/params/types" upgradeclient "github.com/cosmos/cosmos-sdk/x/upgrade/client" upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" tmproto "github.com/cometbft/cometbft/proto/tendermint/types" "github.com/CosmWasm/wasmd/x/wasm" wasmkeeper "github.com/CosmWasm/wasmd/x/wasm/keeper" wasmtypes "github.com/CosmWasm/wasmd/x/wasm/types" tmjson "github.com/cometbft/cometbft/libs/json" govclient "github.com/cosmos/cosmos-sdk/x/gov/client" "github.com/cybercongress/go-cyber/v7/utils" runtimeservices "github.com/cosmos/cosmos-sdk/runtime/services" ) const ( appName = "BostromHub" Name = "bostrom" ) // We pull these out so we can set them with LDFLAGS in the Makefile var ( NodeDir = ".cyber" Bech32Prefix = "bostrom" Upgrades = []upgrades.Upgrade{v2.Upgrade, v3.Upgrade, v4.Upgrade, v6.Upgrade, v7.Upgrade} Forks = []upgrades.Fork{v5.Fork} ) // These constants are derived from the above variables. // These are the ones we will want to use in the code, based on // any overrides above var ( // DefaultNodeHome default home directories for wasmd DefaultNodeHome = os.ExpandEnv("$HOME/") + NodeDir ) func getGovProposalHandlers() []govclient.ProposalHandler { return []govclient.ProposalHandler{ paramsclient.ProposalHandler, upgradeclient.LegacyProposalHandler, upgradeclient.LegacyCancelProposalHandler, ibcclientclient.UpdateClientProposalHandler, ibcclientclient.UpgradeProposalHandler, } } //// module accounts that are allowed to receive tokens //var allowedReceivingModAcc = map[string]bool{ // distrtypes.ModuleName: true, //} var ( _ runtime.AppI = (*App)(nil) _ servertypes.Application = (*App)(nil) ) // App extends an ABCI application, but with most of its parameters exported. // They are exported for convenience in creating helper functions, as object // capabilities aren't needed for testing. type App struct { *baseapp.BaseApp keepers.AppKeepers aminoCodec *codec.LegacyAmino appCodec codec.Codec txConfig client.TxConfig interfaceRegistry types.InterfaceRegistry invCheckPeriod uint ModuleManager *module.Manager sm *module.SimulationManager configurator module.Configurator } // New returns a reference to an initialized Cyber Consensus Computer. func NewBostromApp( logger log.Logger, db dbm.DB, traceStore io.Writer, loadLatest bool, appOpts servertypes.AppOptions, wasmOpts []wasmkeeper.Option, baseAppOptions ...func(*baseapp.BaseApp), ) *App { wasmtypes.MaxWasmSize = 2 * 1024 * 1024 // 2MB encodingConfig := MakeEncodingConfig() appCodec, legacyAmino := encodingConfig.Codec, encodingConfig.Amino interfaceRegistry := encodingConfig.InterfaceRegistry txConfig := encodingConfig.TxConfig // App Opts skipGenesisInvariants := cast.ToBool(appOpts.Get(crisis.FlagSkipGenesisInvariants)) invCheckPeriod := cast.ToUint(appOpts.Get(server.FlagInvCheckPeriod)) bApp := baseapp.NewBaseApp( appName, logger, db, txConfig.TxDecoder(), baseAppOptions...) bApp.SetCommitMultiStoreTracer(traceStore) bApp.SetVersion(version.Version) bApp.SetInterfaceRegistry(interfaceRegistry) bApp.SetTxEncoder(txConfig.TxEncoder()) app := &App{ BaseApp: bApp, aminoCodec: legacyAmino, appCodec: appCodec, txConfig: txConfig, interfaceRegistry: interfaceRegistry, invCheckPeriod: invCheckPeriod, } // Setup keepers app.AppKeepers = keepers.NewAppKeepers( appCodec, bApp, legacyAmino, keepers.GetMaccPerms(), invCheckPeriod, logger, appOpts, wasmOpts, ) /**** Module Options ****/ // NOTE: Any module instantiated in the module manager that is later modified // must be passed by reference here. app.ModuleManager = module.NewManager(appModules(app, encodingConfig, skipGenesisInvariants)...) // During begin block slashing happens after distr.BeginBlocker so that // there is nothing left over in the validator fee pool, so as to keep the // CanWithdrawInvariant invariant. // NOTE: staking module is required if HistoricalEntries param > 0 // NOTE: capability module's beginblocker must come before any modules using capabilities (e.g. IBC) // Tell the app's module manager how to set the order of BeginBlockers, which are run at the beginning of every block. app.ModuleManager.SetOrderBeginBlockers(orderBeginBlockers()...) app.ModuleManager.SetOrderEndBlockers(orderEndBlockers()...) // NOTE: The genutils module must occur after staking so that pools are // properly initialized with tokens from genesis accounts. // NOTE: The genutils module must also occur after auth so that it can access the params from auth. // NOTE: Capability module must occur first so that it can initialize any capabilities // so that other modules that want to create or claim capabilities afterwards in InitChain // can do so safely. app.ModuleManager.SetOrderInitGenesis(orderInitBlockers()...) // Uncomment if you want to set a custom migration order here. // NOTE: can be useful for future upgrades // app.mm.SetOrderMigrations(custom order) app.ModuleManager.RegisterInvariants(app.CrisisKeeper) // NOTE hack to register bank's module services because of custom wrapper // from sdk.bank/module.go: AppModule RegisterServices // m := keeper.NewMigrator(am.keeper.(keeper.BaseKeeper)) // NOTE skip bank module from native services registration then initialize manually app.configurator = module.NewConfigurator(appCodec, app.MsgServiceRouter(), app.GRPCQueryRouter()) delete(app.ModuleManager.Modules, banktypes.ModuleName) app.ModuleManager.RegisterServices(app.configurator) autocliv1.RegisterQueryServer(app.GRPCQueryRouter(), runtimeservices.NewAutoCLIQueryService(app.ModuleManager.Modules)) app.ModuleManager.Modules[banktypes.ModuleName] = bank.NewAppModule(appCodec, app.CyberbankKeeper.Proxy, app.AccountKeeper, app.GetSubspace(banktypes.ModuleName)) banktypes.RegisterMsgServer(app.configurator.MsgServer(), bankkeeper.NewMsgServerImpl(app.CyberbankKeeper.Proxy)) banktypes.RegisterQueryServer(app.configurator.QueryServer(), app.CyberbankKeeper.Proxy) reflectionSvc, err := runtimeservices.NewReflectionService() if err != nil { panic(err) } reflectionv1.RegisterReflectionServiceServer(app.GRPCQueryRouter(), reflectionSvc) // initialize stores app.MountKVStores(app.GetKVStoreKey()) app.MountTransientStores(app.GetTransientStoreKey()) app.MountMemoryStores(app.GetMemoryStoreKey()) wasmConfig, err := wasm.ReadWasmConfig(appOpts) if err != nil { panic("error while reading wasm config: " + err.Error()) } proofExemptContracts := cast.ToStringSlice(appOpts.Get("proof-exempt.contracts")) anteHandler, err := NewAnteHandler( HandlerOptions{ HandlerOptions: ante.HandlerOptions{ AccountKeeper: app.AccountKeeper, BankKeeper: app.BankKeeper, FeegrantKeeper: app.FeeGrantKeeper, SignModeHandler: encodingConfig.TxConfig.SignModeHandler(), SigGasConsumer: ante.DefaultSigVerificationGasConsumer, }, IBCKeeper: app.IBCKeeper, TXCounterStoreKey: app.GetKey(wasmtypes.StoreKey), WasmConfig: &wasmConfig, WasmKeeper: app.WasmKeeper, ProofExemptContracts: proofExemptContracts, }, ) if err != nil { panic(fmt.Errorf("failed to create AnteHandler: %s", err)) } // set ante and post handlers app.SetAnteHandler(anteHandler) app.SetInitChainer(app.InitChainer) app.SetBeginBlocker(app.BeginBlocker) app.SetEndBlocker(app.EndBlocker) // Register snapshot extensions to enable state-sync for wasm and cyber modules if manager := app.SnapshotManager(); manager != nil { err = manager.RegisterExtensions( wasmkeeper.NewWasmSnapshotter(app.CommitMultiStore(), app.WasmKeeper), cyberbankkeeper.NewCyberbankSnapshotter(app.CommitMultiStore(), app.CyberbankKeeper), graphkeeper.NewGraphSnapshotter(app.CommitMultiStore(), app.AppKeepers.GraphKeeper, app.IndexKeeper), bandwidthkeeper.NewBandwidthSnapshotter(app.CommitMultiStore(), app.BandwidthMeter), rankkeeper.NewRankSnapshotter(app.CommitMultiStore(), app.RankKeeper), ) if err != nil { panic("failed to register snapshot extension: " + err.Error()) } } app.setupUpgradeHandlers(app.configurator) app.setupUpgradeStoreLoaders() app.setPostHandler() if loadLatest { if err := app.LoadLatestVersion(); err != nil { tmos.Exit(fmt.Sprintf("failed to load latest version: %s", err)) } ctx := app.BaseApp.NewUncachedContext(true, tmproto.Header{}) // TODO refactor context load flow // NOTE custom implementation app.loadContexts(db, ctx) if err := app.WasmKeeper.InitializePinnedCodes(ctx); err != nil { tmos.Exit(fmt.Sprintf("failed initialize pinned codes %s", err)) } } // create the simulation manager and define the order of the modules for deterministic simulations // // NOTE: this is not required apps that don't use the simulator for fuzz testing // transactions app.sm = module.NewSimulationManager(simulationModules(app, encodingConfig, skipGenesisInvariants)...) app.sm.RegisterStoreDecoders() return app } func (app *App) setPostHandler() { postHandler, err := posthandler.NewPostHandler( posthandler.HandlerOptions{}, ) if err != nil { panic(err) } app.SetPostHandler(postHandler) } // Name returns the name of the App func (app *App) Name() string { return app.BaseApp.Name() } // BeginBlocker application updates every begin block func (app *App) BeginBlocker(ctx sdk.Context, req abci.RequestBeginBlock) abci.ResponseBeginBlock { //BeginBlockForks(ctx, app) return app.ModuleManager.BeginBlock(ctx, req) } // EndBlocker application updates every end block func (app *App) EndBlocker(ctx sdk.Context, req abci.RequestEndBlock) abci.ResponseEndBlock { return app.ModuleManager.EndBlock(ctx, req) } // InitChainer application update at chain initialization func (app *App) InitChainer(ctx sdk.Context, req abci.RequestInitChain) abci.ResponseInitChain { var genesisState GenesisState if err := tmjson.Unmarshal(req.AppStateBytes, &genesisState); err != nil { panic(err) } // custom initialization // var bankGenesisState banktypes.GenesisState // app.appCodec.MustUnmarshalJSON(genesisState["bank"], &bankGenesisState) // app.BandwidthMeter.AddToDesirableBandwidth(ctx, bankGenesisState.Supply.AmountOf(ctypes.VOLT).Uint64()) app.UpgradeKeeper.SetModuleVersionMap(ctx, app.ModuleManager.GetVersionMap()) resp := app.ModuleManager.InitGenesis(ctx, app.appCodec, genesisState) // custom initialization for _, account := range app.AccountKeeper.GetAllAccounts(ctx) { app.CyberbankKeeper.InitializeStakeAmpere( account.GetAccountNumber(), uint64(app.CyberbankKeeper.Proxy.GetAccountStakeAmperPlusRouted(ctx, account.GetAddress())), ) } return resp } // LoadHeight loads a particular height func (app *App) LoadHeight(height int64) error { return app.LoadVersion(height) } // ModuleAccountAddrs returns all the app's module account addresses. func (app *App) ModuleAccountAddrs() map[string]bool { modAccAddrs := make(map[string]bool) for acc := range keepers.GetMaccPerms() { modAccAddrs[authtypes.NewModuleAddress(acc).String()] = true } return modAccAddrs } // LegacyAmino returns SimApp's amino codec. // // NOTE: This is solely to be used for testing purposes as it may be desirable // for modules to register their own custom testing types. func (app *App) LegacyAmino() *codec.LegacyAmino { return app.aminoCodec } // AppCodec returns Juno's app codec. // // NOTE: This is solely to be used for testing purposes as it may be desirable // for modules to register their own custom testing types. func (app *App) AppCodec() codec.Codec { return app.appCodec } // InterfaceRegistry returns Juno's InterfaceRegistry func (app *App) InterfaceRegistry() types.InterfaceRegistry { return app.interfaceRegistry } // GetSubspace returns a param subspace for a given module name. // // NOTE: This is solely to be used for testing purposes. func (app *App) GetSubspace(moduleName string) paramstypes.Subspace { subspace, _ := app.ParamsKeeper.GetSubspace(moduleName) return subspace } // RegisterAPIRoutes registers all application module routes with the provided // API server. func (app *App) RegisterAPIRoutes(apiSvr *api.Server, apiConfig config.APIConfig) { clientCtx := apiSvr.ClientCtx // Register new tx routes from grpc-gateway. authtx.RegisterGRPCGatewayRoutes(clientCtx, apiSvr.GRPCGatewayRouter) // Register new tendermint queries routes from grpc-gateway. tmservice.RegisterGRPCGatewayRoutes(clientCtx, apiSvr.GRPCGatewayRouter) // Register node gRPC service for grpc-gateway. nodeservice.RegisterGRPCGatewayRoutes(clientCtx, apiSvr.GRPCGatewayRouter) // Register grpc-gateway routes for all modules. ModuleBasics.RegisterGRPCGatewayRoutes(clientCtx, apiSvr.GRPCGatewayRouter) // register app's OpenAPI routes. docs.RegisterOpenAPIService(Name, apiSvr.Router) } // RegisterTxService implements the Application.RegisterTxService method. func (app *App) RegisterTxService(clientCtx client.Context) { authtx.RegisterTxService(app.BaseApp.GRPCQueryRouter(), clientCtx, app.BaseApp.Simulate, app.interfaceRegistry) } // RegisterTendermintService implements the Application.RegisterTendermintService method. func (app *App) RegisterTendermintService(clientCtx client.Context) { tmservice.RegisterTendermintService( clientCtx, app.BaseApp.GRPCQueryRouter(), app.interfaceRegistry, app.Query, ) } func (app *App) RegisterNodeService(clientCtx client.Context) { nodeservice.RegisterNodeService(clientCtx, app.GRPCQueryRouter()) } // configure store loader that checks if version == upgradeHeight and applies store upgrades func (app *App) setupUpgradeStoreLoaders() { upgradeInfo, err := app.UpgradeKeeper.ReadUpgradeInfoFromDisk() if err != nil { panic("failed to read upgrade info from disk" + err.Error()) } if app.UpgradeKeeper.IsSkipHeight(upgradeInfo.Height) { return } for _, upgrade := range Upgrades { storeUpgrades := upgrade.StoreUpgrades if upgradeInfo.Name == upgrade.UpgradeName { app.SetStoreLoader( upgradetypes.UpgradeStoreLoader(upgradeInfo.Height, &storeUpgrades), ) } } } func (app *App) setupUpgradeHandlers(cfg module.Configurator) { for _, upgrade := range Upgrades { app.UpgradeKeeper.SetUpgradeHandler( upgrade.UpgradeName, upgrade.CreateUpgradeHandler( app.ModuleManager, cfg, &app.AppKeepers, ), ) } } // SimulationManager implements the SimulationApp interface func (app *App) SimulationManager() *module.SimulationManager { return app.sm } // MakeCodecs constructs the *std.Codec and *codec.LegacyAmino instances used by // Cyber's app. It is useful for tests and clients who do not want to construct the // full Cyber app func MakeCodecs() (codec.Codec, *codec.LegacyAmino) { config := MakeEncodingConfig() return config.Codec, config.Amino } func (app *App) loadContexts(db dbm.DB, ctx sdk.Context) { freshCtx := ctx.WithBlockHeight(int64(app.RankKeeper.GetLatestBlockNumber(ctx))) start := time.Now() app.BaseApp.Logger().Info("Loading the brain state") if app.LastBlockHeight() >= 1 { calculationPeriod := app.RankKeeper.GetParams(freshCtx).CalculationPeriod // TODO remove this after upgrade to v4 because on network upgrade block cannot access rank params if calculationPeriod == 0 { calculationPeriod = int64(5) } rankRoundBlockNumber := (freshCtx.BlockHeight() / calculationPeriod) * calculationPeriod if rankRoundBlockNumber == 0 && freshCtx.BlockHeight() >= 1 { rankRoundBlockNumber = 1 } rankCtx, err := utils.NewContextWithMSVersion(db, rankRoundBlockNumber, app.GetKVStoreKey()) if err != nil { tmos.Exit(err.Error()) } app.CyberbankKeeper.LoadState(rankCtx, freshCtx) // TODO update index state load to one context as we store cyberlink' block now app.IndexKeeper.LoadState(rankCtx, freshCtx) app.BandwidthMeter.LoadState(freshCtx) app.GraphKeeper.LoadNeudeg(rankCtx, freshCtx) app.RankKeeper.LoadState(freshCtx) app.RankKeeper.StartRankCalculation(freshCtx) } else { // genesis case // NOTE this flow when starting from snapshot app.CyberbankKeeper.LoadState(freshCtx, freshCtx) // TODO update index state load to one context as we store cyberlink' block now app.IndexKeeper.LoadState(freshCtx, freshCtx) app.BandwidthMeter.InitState() app.GraphKeeper.LoadNeudeg(freshCtx, freshCtx) app.RankKeeper.LoadState(freshCtx) } app.BaseApp.Logger().Info( "Cyber Consensus Supercomputer is started!", "duration", time.Since(start).String(), ) } // InitOsmosisAppForTestnet is broken down into two sections: // Required Changes: Changes that, if not made, will cause the testnet to halt or panic // Optional Changes: Changes to customize the testnet to one's liking (lower vote times, fund accounts, etc) func InitAppForTestnet(app *App, newValAddr bytes.HexBytes, newValPubKey crypto.PubKey, newOperatorAddress, upgradeToTrigger string) *App { // // Required Changes: // ctx := app.BaseApp.NewUncachedContext(true, tmproto.Header{}) pubkey := &ed25519.PubKey{Key: newValPubKey.Bytes()} pubkeyAny, err := types.NewAnyWithValue(pubkey) if err != nil { tmos.Exit(err.Error()) } // STAKING // // Create Validator struct for our new validator. _, bz, err := bech32.DecodeAndConvert(newOperatorAddress) if err != nil { tmos.Exit(err.Error()) } bech32Addr, err := bech32.ConvertAndEncode("bostromvaloper", bz) if err != nil { tmos.Exit(err.Error()) } newVal := stakingtypes.Validator{ OperatorAddress: bech32Addr, ConsensusPubkey: pubkeyAny, Jailed: false, Status: stakingtypes.Bonded, Tokens: math.NewInt(900000000000000), DelegatorShares: sdk.MustNewDecFromStr("10000000"), Description: stakingtypes.Description{ Moniker: "Testnet Validator", }, Commission: stakingtypes.Commission{ CommissionRates: stakingtypes.CommissionRates{ Rate: sdk.MustNewDecFromStr("0.05"), MaxRate: sdk.MustNewDecFromStr("0.1"), MaxChangeRate: sdk.MustNewDecFromStr("0.05"), }, }, MinSelfDelegation: math.OneInt(), } // Remove all validators from power store stakingKey := app.GetKey(stakingtypes.ModuleName) stakingStore := ctx.KVStore(stakingKey) iterator := app.StakingKeeper.ValidatorsPowerStoreIterator(ctx) for ; iterator.Valid(); iterator.Next() { stakingStore.Delete(iterator.Key()) } iterator.Close() // Remove all valdiators from last validators store iterator = app.StakingKeeper.LastValidatorsIterator(ctx) for ; iterator.Valid(); iterator.Next() { stakingStore.Delete(iterator.Key()) } iterator.Close() // Remove all validators from validators store iterator = storetypes.KVStorePrefixIterator(stakingStore, stakingtypes.ValidatorsKey) for ; iterator.Valid(); iterator.Next() { stakingStore.Delete(iterator.Key()) } iterator.Close() // Remove all validators from unbonding queue iterator = storetypes.KVStorePrefixIterator(stakingStore, stakingtypes.ValidatorQueueKey) for ; iterator.Valid(); iterator.Next() { stakingStore.Delete(iterator.Key()) } iterator.Close() // Add our validator to power and last validators store app.StakingKeeper.SetValidator(ctx, newVal) err = app.StakingKeeper.SetValidatorByConsAddr(ctx, newVal) if err != nil { tmos.Exit(err.Error()) } app.StakingKeeper.SetValidatorByPowerIndex(ctx, newVal) valAddr, err := sdk.ValAddressFromBech32(newVal.GetOperator().String()) if err != nil { tmos.Exit(err.Error()) } app.StakingKeeper.SetLastValidatorPower(ctx, valAddr, 0) if err := app.StakingKeeper.Hooks().AfterValidatorCreated(ctx, valAddr); err != nil { panic(err) } // DISTRIBUTION // // Initialize records for this validator across all distribution stores valAddr, err = sdk.ValAddressFromBech32(newVal.GetOperator().String()) if err != nil { tmos.Exit(err.Error()) } app.DistrKeeper.SetValidatorHistoricalRewards(ctx, valAddr, 0, distrtypes.NewValidatorHistoricalRewards(sdk.DecCoins{}, 1)) app.DistrKeeper.SetValidatorCurrentRewards(ctx, valAddr, distrtypes.NewValidatorCurrentRewards(sdk.DecCoins{}, 1)) app.DistrKeeper.SetValidatorAccumulatedCommission(ctx, valAddr, distrtypes.InitialValidatorAccumulatedCommission()) app.DistrKeeper.SetValidatorOutstandingRewards(ctx, valAddr, distrtypes.ValidatorOutstandingRewards{Rewards: sdk.DecCoins{}}) // SLASHING // // Set validator signing info for our new validator. newConsAddr := sdk.ConsAddress(newValAddr.Bytes()) newValidatorSigningInfo := slashingtypes.ValidatorSigningInfo{ Address: newConsAddr.String(), StartHeight: app.LastBlockHeight() - 1, Tombstoned: false, } app.SlashingKeeper.SetValidatorSigningInfo(ctx, newConsAddr, newValidatorSigningInfo) // // Optional Changes: // // UPGRADE // if upgradeToTrigger != "" { upgradePlan := upgradetypes.Plan{ Name: upgradeToTrigger, //Height: app.LastBlockHeight() + 10, Height: app.LastBlockHeight(), } err = app.UpgradeKeeper.ScheduleUpgrade(ctx, upgradePlan) if err != nil { panic(err) } } return app } ================================================ FILE: app/apptesting/events.go ================================================ package apptesting import sdk "github.com/cosmos/cosmos-sdk/types" // AssertEventEmitted asserts that ctx's event manager has emitted the given number of events // of the given type. func (s *KeeperTestHelper) AssertEventEmitted(ctx sdk.Context, eventTypeExpected string, numEventsExpected int) { allEvents := ctx.EventManager().Events() // filter out other events actualEvents := make([]sdk.Event, 0) for _, event := range allEvents { if event.Type == eventTypeExpected { actualEvents = append(actualEvents, event) } } s.Equal(numEventsExpected, len(actualEvents)) } ================================================ FILE: app/apptesting/test_suite.go ================================================ package apptesting import ( "encoding/json" "fmt" "testing" "time" "github.com/stretchr/testify/require" "github.com/stretchr/testify/suite" dbm "github.com/cometbft/cometbft-db" abci "github.com/cometbft/cometbft/abci/types" "github.com/cometbft/cometbft/crypto/ed25519" "github.com/cometbft/cometbft/libs/log" tmtypes "github.com/cometbft/cometbft/proto/tendermint/types" "cosmossdk.io/math" "github.com/cosmos/cosmos-sdk/baseapp" "github.com/cosmos/cosmos-sdk/client" cdctypes "github.com/cosmos/cosmos-sdk/codec/types" "github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1" "github.com/cosmos/cosmos-sdk/store/rootmulti" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/tx/signing" authsigning "github.com/cosmos/cosmos-sdk/x/auth/signing" "github.com/cosmos/cosmos-sdk/x/authz" authzcodec "github.com/cosmos/cosmos-sdk/x/authz/codec" banktestutil "github.com/cosmos/cosmos-sdk/x/bank/testutil" distrtypes "github.com/cosmos/cosmos-sdk/x/distribution/types" minttypes "github.com/cosmos/cosmos-sdk/x/mint/types" slashingtypes "github.com/cosmos/cosmos-sdk/x/slashing/types" stakinghelper "github.com/cosmos/cosmos-sdk/x/staking/testutil" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" "github.com/cybercongress/go-cyber/v7/app" appparams "github.com/cybercongress/go-cyber/v7/app/params" ) type KeeperTestHelper struct { suite.Suite App *app.App Ctx sdk.Context QueryHelper *baseapp.QueryServiceTestHelper TestAccs []sdk.AccAddress StakingHelper *stakinghelper.Helper } var ( SecondaryDenom = "uion" SecondaryAmount = sdk.NewInt(100000000) ) // Setup sets up basic environment for suite (App, Ctx, and test accounts) func (s *KeeperTestHelper) Setup() { t := s.T() s.App = app.Setup(t) s.Ctx = s.App.BaseApp.NewContext(false, tmtypes.Header{Height: 1, ChainID: "juno-1", Time: time.Now().UTC()}) s.QueryHelper = &baseapp.QueryServiceTestHelper{ GRPCQueryRouter: s.App.GRPCQueryRouter(), Ctx: s.Ctx, } s.TestAccs = CreateRandomAccounts(3) s.StakingHelper = stakinghelper.NewHelper(s.Suite.T(), s.Ctx, s.App.AppKeepers.StakingKeeper) s.StakingHelper.Denom = "ujuno" } func (s *KeeperTestHelper) SetupTestForInitGenesis() { t := s.T() // Setting to True, leads to init genesis not running s.App = app.Setup(t) s.Ctx = s.App.BaseApp.NewContext(true, tmtypes.Header{ ChainID: "testing", }) } // CreateTestContext creates a test context. func (s *KeeperTestHelper) CreateTestContext() sdk.Context { ctx, _ := s.CreateTestContextWithMultiStore() return ctx } // CreateTestContextWithMultiStore creates a test context and returns it together with multi store. func (s *KeeperTestHelper) CreateTestContextWithMultiStore() (sdk.Context, sdk.CommitMultiStore) { db := dbm.NewMemDB() logger := log.NewNopLogger() ms := rootmulti.NewStore(db, logger) return sdk.NewContext(ms, tmtypes.Header{}, false, logger), ms } // CreateTestContext creates a test context. func (s *KeeperTestHelper) Commit() { oldHeight := s.Ctx.BlockHeight() oldHeader := s.Ctx.BlockHeader() s.App.Commit() newHeader := tmtypes.Header{Height: oldHeight + 1, ChainID: "testing", Time: oldHeader.Time.Add(time.Second)} s.App.BeginBlock(abci.RequestBeginBlock{Header: newHeader}) s.Ctx = s.App.NewContext(false, newHeader) } // FundAcc funds target address with specified amount. func (s *KeeperTestHelper) FundAcc(acc sdk.AccAddress, amounts sdk.Coins) { err := banktestutil.FundAccount(s.App.AppKeepers.BankKeeper, s.Ctx, acc, amounts) s.Require().NoError(err) } // FundModuleAcc funds target modules with specified amount. func (s *KeeperTestHelper) FundModuleAcc(moduleName string, amounts sdk.Coins) { err := banktestutil.FundModuleAccount(s.App.AppKeepers.BankKeeper, s.Ctx, moduleName, amounts) s.Require().NoError(err) } func (s *KeeperTestHelper) MintCoins(coins sdk.Coins) { err := s.App.AppKeepers.BankKeeper.MintCoins(s.Ctx, minttypes.ModuleName, coins) s.Require().NoError(err) } // SetupValidator sets up a validator and returns the ValAddress. func (s *KeeperTestHelper) SetupValidator(bondStatus stakingtypes.BondStatus) sdk.ValAddress { valPriv := secp256k1.GenPrivKey() valPub := valPriv.PubKey() valAddr := sdk.ValAddress(valPub.Address()) bondDenom := s.App.AppKeepers.StakingKeeper.GetParams(s.Ctx).BondDenom selfBond := sdk.NewCoins(sdk.Coin{Amount: sdk.NewInt(100), Denom: bondDenom}) s.FundAcc(sdk.AccAddress(valAddr), selfBond) msg := s.StakingHelper.CreateValidatorMsg(valAddr, valPub, selfBond[0].Amount) res, err := s.StakingHelper.CreateValidatorWithMsg(s.Ctx, msg) s.Require().NoError(err) s.Require().NotNil(res) val, found := s.App.AppKeepers.StakingKeeper.GetValidator(s.Ctx, valAddr) s.Require().True(found) val = val.UpdateStatus(bondStatus) s.App.AppKeepers.StakingKeeper.SetValidator(s.Ctx, val) consAddr, err := val.GetConsAddr() s.Suite.Require().NoError(err) signingInfo := slashingtypes.NewValidatorSigningInfo( consAddr, s.Ctx.BlockHeight(), 0, time.Unix(0, 0), false, 0, ) s.App.AppKeepers.SlashingKeeper.SetValidatorSigningInfo(s.Ctx, consAddr, signingInfo) return valAddr } // BeginNewBlock starts a new block. func (s *KeeperTestHelper) BeginNewBlock() { var valAddr []byte validators := s.App.AppKeepers.StakingKeeper.GetAllValidators(s.Ctx) if len(validators) >= 1 { valAddrFancy, err := validators[0].GetConsAddr() s.Require().NoError(err) valAddr = valAddrFancy.Bytes() } else { valAddrFancy := s.SetupValidator(stakingtypes.Bonded) validator, _ := s.App.AppKeepers.StakingKeeper.GetValidator(s.Ctx, valAddrFancy) valAddr2, _ := validator.GetConsAddr() valAddr = valAddr2.Bytes() } s.BeginNewBlockWithProposer(valAddr) } // BeginNewBlockWithProposer begins a new block with a proposer. func (s *KeeperTestHelper) BeginNewBlockWithProposer(proposer sdk.ValAddress) { validator, found := s.App.AppKeepers.StakingKeeper.GetValidator(s.Ctx, proposer) s.Assert().True(found) valConsAddr, err := validator.GetConsAddr() s.Require().NoError(err) valAddr := valConsAddr.Bytes() newBlockTime := s.Ctx.BlockTime().Add(5 * time.Second) header := tmtypes.Header{Height: s.Ctx.BlockHeight() + 1, Time: newBlockTime} newCtx := s.Ctx.WithBlockTime(newBlockTime).WithBlockHeight(s.Ctx.BlockHeight() + 1) s.Ctx = newCtx lastCommitInfo := abci.CommitInfo{ Votes: []abci.VoteInfo{{ Validator: abci.Validator{Address: valAddr, Power: 1000}, SignedLastBlock: true, }}, Round: 0, } reqBeginBlock := abci.RequestBeginBlock{Header: header, LastCommitInfo: lastCommitInfo} fmt.Println("beginning block ", s.Ctx.BlockHeight()) s.App.BeginBlocker(s.Ctx, reqBeginBlock) } // EndBlock ends the block. func (s *KeeperTestHelper) EndBlock() { reqEndBlock := abci.RequestEndBlock{Height: s.Ctx.BlockHeight()} s.App.EndBlocker(s.Ctx, reqEndBlock) } // AllocateRewardsToValidator allocates reward tokens to a distribution module then allocates rewards to the validator address. func (s *KeeperTestHelper) AllocateRewardsToValidator(valAddr sdk.ValAddress, rewardAmt math.Int) { validator, found := s.App.AppKeepers.StakingKeeper.GetValidator(s.Ctx, valAddr) s.Require().True(found) // allocate reward tokens to distribution module coins := sdk.Coins{sdk.NewCoin(appparams.BondDenom, rewardAmt)} err := banktestutil.FundModuleAccount(s.App.AppKeepers.BankKeeper, s.Ctx, distrtypes.ModuleName, coins) s.Require().NoError(err) // allocate rewards to validator s.Ctx = s.Ctx.WithBlockHeight(s.Ctx.BlockHeight() + 1) decTokens := sdk.DecCoins{{Denom: appparams.BondDenom, Amount: sdk.NewDec(20000)}} s.App.AppKeepers.DistrKeeper.AllocateTokensToValidator(s.Ctx, validator, decTokens) } // BuildTx builds a transaction. func (s *KeeperTestHelper) BuildTx( txBuilder client.TxBuilder, msgs []sdk.Msg, sigV2 signing.SignatureV2, memo string, txFee sdk.Coins, gasLimit uint64, ) authsigning.Tx { err := txBuilder.SetMsgs(msgs[0]) s.Require().NoError(err) err = txBuilder.SetSignatures(sigV2) s.Require().NoError(err) txBuilder.SetMemo(memo) txBuilder.SetFeeAmount(txFee) txBuilder.SetGasLimit(gasLimit) return txBuilder.GetTx() } func (s *KeeperTestHelper) ConfirmUpgradeSucceeded(upgradeName string, upgradeHeight int64) { s.Ctx = s.Ctx.WithBlockHeight(upgradeHeight - 1) plan := upgradetypes.Plan{Name: upgradeName, Height: upgradeHeight} err := s.App.AppKeepers.UpgradeKeeper.ScheduleUpgrade(s.Ctx, plan) s.Require().NoError(err) _, exists := s.App.AppKeepers.UpgradeKeeper.GetUpgradePlan(s.Ctx) s.Require().True(exists) s.Ctx = s.Ctx.WithBlockHeight(upgradeHeight) s.Require().NotPanics(func() { beginBlockRequest := abci.RequestBeginBlock{} s.App.BeginBlocker(s.Ctx, beginBlockRequest) }) } // CreateRandomAccounts is a function return a list of randomly generated AccAddresses func CreateRandomAccounts(numAccts int) []sdk.AccAddress { testAddrs := make([]sdk.AccAddress, numAccts) for i := 0; i < numAccts; i++ { pk := ed25519.GenPrivKey().PubKey() testAddrs[i] = sdk.AccAddress(pk.Address()) } return testAddrs } func TestMessageAuthzSerialization(t *testing.T, msg sdk.Msg) { someDate := time.Date(1, 1, 1, 1, 1, 1, 1, time.UTC) const ( mockGranter string = "cosmos1abc" mockGrantee string = "cosmos1xyz" ) var ( mockMsgGrant authz.MsgGrant mockMsgRevoke authz.MsgRevoke mockMsgExec authz.MsgExec ) // Authz: Grant Msg typeURL := sdk.MsgTypeURL(msg) later := someDate.Add(time.Hour) grant, err := authz.NewGrant(someDate, authz.NewGenericAuthorization(typeURL), &later) require.NoError(t, err) msgGrant := authz.MsgGrant{Granter: mockGranter, Grantee: mockGrantee, Grant: grant} msgGrantBytes := json.RawMessage(sdk.MustSortJSON(authzcodec.ModuleCdc.MustMarshalJSON(&msgGrant))) err = authzcodec.ModuleCdc.UnmarshalJSON(msgGrantBytes, &mockMsgGrant) require.NoError(t, err) // Authz: Revoke Msg msgRevoke := authz.MsgRevoke{Granter: mockGranter, Grantee: mockGrantee, MsgTypeUrl: typeURL} msgRevokeByte := json.RawMessage(sdk.MustSortJSON(authzcodec.ModuleCdc.MustMarshalJSON(&msgRevoke))) err = authzcodec.ModuleCdc.UnmarshalJSON(msgRevokeByte, &mockMsgRevoke) require.NoError(t, err) // Authz: Exec Msg msgAny, err := cdctypes.NewAnyWithValue(msg) require.NoError(t, err) msgExec := authz.MsgExec{Grantee: mockGrantee, Msgs: []*cdctypes.Any{msgAny}} execMsgByte := json.RawMessage(sdk.MustSortJSON(authzcodec.ModuleCdc.MustMarshalJSON(&msgExec))) err = authzcodec.ModuleCdc.UnmarshalJSON(execMsgByte, &mockMsgExec) require.NoError(t, err) require.Equal(t, msgExec.Msgs[0].Value, mockMsgExec.Msgs[0].Value) } func GenerateTestAddrs() (string, string) { pk1 := ed25519.GenPrivKey().PubKey() validAddr := sdk.AccAddress(pk1.Address()).String() invalidAddr := sdk.AccAddress("invalid").String() return validAddr, invalidAddr } ================================================ FILE: app/encoding.go ================================================ package app import ( simappparams "cosmossdk.io/simapp/params" "github.com/cosmos/cosmos-sdk/std" "github.com/cybercongress/go-cyber/v7/app/params" ) func MakeEncodingConfig() simappparams.EncodingConfig { encodingConfig := params.MakeEncodingConfig() std.RegisterLegacyAminoCodec(encodingConfig.Amino) std.RegisterInterfaces(encodingConfig.InterfaceRegistry) ModuleBasics.RegisterLegacyAminoCodec(encodingConfig.Amino) ModuleBasics.RegisterInterfaces(encodingConfig.InterfaceRegistry) return encodingConfig } ================================================ FILE: app/export.go ================================================ package app import ( "encoding/json" "fmt" tmproto "github.com/cometbft/cometbft/proto/tendermint/types" servertypes "github.com/cosmos/cosmos-sdk/server/types" "github.com/cosmos/cosmos-sdk/x/staking" ) // ExportAppStateAndValidators exports the state of the application for a genesis // file. func (app *App) ExportAppStateAndValidators(forZeroHeight bool, jailAllowedAddrs []string, modulesToExport []string) (servertypes.ExportedApp, error) { // as if they could withdraw from the start of the next block ctx := app.NewContext(true, tmproto.Header{Height: app.LastBlockHeight()}) // We export at last height + 1, because that's the height at which // Tendermint will start InitChain. height := app.LastBlockHeight() + 1 if forZeroHeight { return servertypes.ExportedApp{}, fmt.Errorf("forZeroHeight not supported") } genState := app.ModuleManager.ExportGenesisForModules(ctx, app.appCodec, modulesToExport) appState, err := json.MarshalIndent(genState, "", " ") if err != nil { return servertypes.ExportedApp{}, err } validators, err := staking.WriteValidators(ctx, app.AppKeepers.StakingKeeper) return servertypes.ExportedApp{ AppState: appState, Validators: validators, Height: height, ConsensusParams: app.BaseApp.GetConsensusParams(ctx), }, err } ================================================ FILE: app/forks.go ================================================ package app import ( sdk "github.com/cosmos/cosmos-sdk/types" ) // BeginBlockForks is intended to be ran in a chain upgrade. func BeginBlockForks(ctx sdk.Context, app *App) { for _, fork := range Forks { if ctx.BlockHeight() == fork.UpgradeHeight { fork.BeginForkLogic(ctx, &app.AppKeepers) return } } } ================================================ FILE: app/genesis.go ================================================ package app import ( "encoding/json" "github.com/cosmos/cosmos-sdk/codec" ) // The genesis state of the blockchain is represented here as a map of raw json // messages key'd by a identifier string. // The identifier is used to determine which module genesis information belongs // to so it may be appropriately routed during init chain. // Within this application default genesis information is retrieved from // the ModuleBasicManager which populates json from each BasicModule // object provided to it during init. type GenesisState map[string]json.RawMessage // NewDefaultGenesisState generates the default state for the application. func NewDefaultGenesisState(cdc codec.JSONCodec) GenesisState { return ModuleBasics.DefaultGenesis(cdc) } ================================================ FILE: app/helpers/contracts.go ================================================ package helpers import ( wasmtypes "github.com/CosmWasm/wasmd/x/wasm/types" storetypes "github.com/cosmos/cosmos-sdk/store/types" sdk "github.com/cosmos/cosmos-sdk/types" ) // Execute contract, recover from panic func ExecuteContract(k wasmtypes.ContractOpsKeeper, childCtx sdk.Context, contractAddr sdk.AccAddress, msgBz []byte, err *error) { // Recover from panic, return error defer func() { if recoveryError := recover(); recoveryError != nil { // Determine error associated with panic if isOutofGas, msg := IsOutOfGasError(recoveryError); isOutofGas { *err = ErrOutOfGas.Wrapf("%s", msg) } else { *err = ErrContractExecutionPanic.Wrapf("%s", recoveryError) } } }() // Execute contract with sudo _, *err = k.Sudo(childCtx, contractAddr, msgBz) } // Check if error is out of gas error func IsOutOfGasError(err any) (bool, string) { switch e := err.(type) { case storetypes.ErrorOutOfGas: return true, e.Descriptor case storetypes.ErrorGasOverflow: return true, e.Descriptor default: return false, "" } } ================================================ FILE: app/helpers/global_errors.go ================================================ package helpers import ( errorsmod "cosmossdk.io/errors" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" ) const codespace = "cyber-global" var ( ErrInvalidAddress = sdkerrors.ErrInvalidAddress ErrContractNotRegistered = errorsmod.Register(codespace, 1, "contract not registered") ErrContractAlreadyRegistered = errorsmod.Register(codespace, 2, "contract already registered") ErrContractNotAdmin = errorsmod.Register(codespace, 3, "sender is not the contract admin") ErrContractNotCreator = errorsmod.Register(codespace, 4, "sender is not the contract creator") ErrInvalidCWContract = errorsmod.Register(codespace, 5, "invalid CosmWasm contract") ErrOutOfGas = errorsmod.Register(codespace, 6, "contract execution ran out of gas") ErrContractExecutionPanic = errorsmod.Register(codespace, 7, "contract execution panicked") ) ================================================ FILE: app/helpers/mock.go ================================================ package helpers import ( "github.com/cometbft/cometbft/crypto" tmproto "github.com/cometbft/cometbft/proto/tendermint/types" tmtypes "github.com/cometbft/cometbft/types" cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" "github.com/cosmos/cosmos-sdk/crypto/keys/ed25519" cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" ) var _ tmtypes.PrivValidator = PV{} // PV implements PrivValidator without any safety or persistence. // Only use it for testing. type PV struct { PrivKey cryptotypes.PrivKey } func NewPV() PV { return PV{ed25519.GenPrivKey()} } // GetPubKey implements PrivValidator interface func (pv PV) GetPubKey() (crypto.PubKey, error) { return cryptocodec.ToTmPubKeyInterface(pv.PrivKey.PubKey()) } // SignVote implements PrivValidator interface func (pv PV) SignVote(chainID string, vote *tmproto.Vote) error { signBytes := tmtypes.VoteSignBytes(chainID, vote) sig, err := pv.PrivKey.Sign(signBytes) if err != nil { return err } vote.Signature = sig return nil } // SignProposal implements PrivValidator interface func (pv PV) SignProposal(chainID string, proposal *tmproto.Proposal) error { signBytes := tmtypes.ProposalSignBytes(chainID, proposal) sig, err := pv.PrivKey.Sign(signBytes) if err != nil { return err } proposal.Signature = sig return nil } ================================================ FILE: app/keepers/keepers.go ================================================ package keepers import ( "fmt" "github.com/cosmos/cosmos-sdk/store/streaming" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/x/nft" nftkeeper "github.com/cosmos/cosmos-sdk/x/nft/keeper" "github.com/cosmos/ibc-apps/middleware/packet-forward-middleware/v7/packetforward" packetforwardtypes "github.com/cosmos/ibc-apps/middleware/packet-forward-middleware/v7/packetforward/types" icq "github.com/cosmos/ibc-apps/modules/async-icq/v7" icqkeeper "github.com/cosmos/ibc-apps/modules/async-icq/v7/keeper" icqtypes "github.com/cosmos/ibc-apps/modules/async-icq/v7/types" icacontroller "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller" icacontrollertypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller/types" icahost "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/host" icahosttypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/host/types" icatypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/types" clocktypes "github.com/cybercongress/go-cyber/v7/x/clock/types" tokenfactorykeeper "github.com/cybercongress/go-cyber/v7/x/tokenfactory/keeper" tokenfactorytypes "github.com/cybercongress/go-cyber/v7/x/tokenfactory/types" "os" "path/filepath" "github.com/CosmWasm/wasmd/x/wasm" wasmkeeper "github.com/CosmWasm/wasmd/x/wasm/keeper" wasmtypes "github.com/CosmWasm/wasmd/x/wasm/types" "github.com/cosmos/cosmos-sdk/baseapp" "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/server" servertypes "github.com/cosmos/cosmos-sdk/server/types" storetypes "github.com/cosmos/cosmos-sdk/store/types" authkeeper "github.com/cosmos/cosmos-sdk/x/auth/keeper" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" authzkeeper "github.com/cosmos/cosmos-sdk/x/authz/keeper" bankkeeper "github.com/cosmos/cosmos-sdk/x/bank/keeper" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" capabilitykeeper "github.com/cosmos/cosmos-sdk/x/capability/keeper" capabilitytypes "github.com/cosmos/cosmos-sdk/x/capability/types" crisiskeeper "github.com/cosmos/cosmos-sdk/x/crisis/keeper" crisistypes "github.com/cosmos/cosmos-sdk/x/crisis/types" distrkeeper "github.com/cosmos/cosmos-sdk/x/distribution/keeper" distrtypes "github.com/cosmos/cosmos-sdk/x/distribution/types" evidencekeeper "github.com/cosmos/cosmos-sdk/x/evidence/keeper" evidencetypes "github.com/cosmos/cosmos-sdk/x/evidence/types" "github.com/cosmos/cosmos-sdk/x/feegrant" feegrantkeeper "github.com/cosmos/cosmos-sdk/x/feegrant/keeper" govkeeper "github.com/cosmos/cosmos-sdk/x/gov/keeper" govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" mintkeeper "github.com/cosmos/cosmos-sdk/x/mint/keeper" minttypes "github.com/cosmos/cosmos-sdk/x/mint/types" sdkparams "github.com/cosmos/cosmos-sdk/x/params" paramskeeper "github.com/cosmos/cosmos-sdk/x/params/keeper" paramstypes "github.com/cosmos/cosmos-sdk/x/params/types" paramproposal "github.com/cosmos/cosmos-sdk/x/params/types/proposal" slashingkeeper "github.com/cosmos/cosmos-sdk/x/slashing/keeper" slashingtypes "github.com/cosmos/cosmos-sdk/x/slashing/types" stakingkeeper "github.com/cosmos/cosmos-sdk/x/staking/keeper" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" "github.com/cosmos/cosmos-sdk/x/upgrade" upgradekeeper "github.com/cosmos/cosmos-sdk/x/upgrade/keeper" upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" ibcfee "github.com/cosmos/ibc-go/v7/modules/apps/29-fee" ibcfeekeeper "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/keeper" ibcfeetypes "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/types" "github.com/cosmos/ibc-go/v7/modules/apps/transfer" ibctransferkeeper "github.com/cosmos/ibc-go/v7/modules/apps/transfer/keeper" ibctransfertypes "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" ibcclient "github.com/cosmos/ibc-go/v7/modules/core/02-client" ibcclienttypes "github.com/cosmos/ibc-go/v7/modules/core/02-client/types" porttypes "github.com/cosmos/ibc-go/v7/modules/core/05-port/types" ibcexported "github.com/cosmos/ibc-go/v7/modules/core/exported" ibckeeper "github.com/cosmos/ibc-go/v7/modules/core/keeper" //"github.com/cybercongress/go-cyber/v4/app" "github.com/spf13/cast" liquiditykeeper "github.com/cybercongress/go-cyber/v7/x/liquidity/keeper" liquiditytypes "github.com/cybercongress/go-cyber/v7/x/liquidity/types" wasmplugins "github.com/cybercongress/go-cyber/v7/plugins" bandwidthkeeper "github.com/cybercongress/go-cyber/v7/x/bandwidth/keeper" bandwidthtypes "github.com/cybercongress/go-cyber/v7/x/bandwidth/types" cyberbankkeeper "github.com/cybercongress/go-cyber/v7/x/cyberbank/keeper" dmnkeeper "github.com/cybercongress/go-cyber/v7/x/dmn/keeper" dmntypes "github.com/cybercongress/go-cyber/v7/x/dmn/types" graphkeeper "github.com/cybercongress/go-cyber/v7/x/graph/keeper" graphtypes "github.com/cybercongress/go-cyber/v7/x/graph/types" gridkeeper "github.com/cybercongress/go-cyber/v7/x/grid/keeper" gridtypes "github.com/cybercongress/go-cyber/v7/x/grid/types" "github.com/cybercongress/go-cyber/v7/x/rank" rankkeeper "github.com/cybercongress/go-cyber/v7/x/rank/keeper" ranktypes "github.com/cybercongress/go-cyber/v7/x/rank/types" resourceskeeper "github.com/cybercongress/go-cyber/v7/x/resources/keeper" resourcestypes "github.com/cybercongress/go-cyber/v7/x/resources/types" consensusparamkeeper "github.com/cosmos/cosmos-sdk/x/consensus/keeper" consensusparamtypes "github.com/cosmos/cosmos-sdk/x/consensus/types" govv1beta "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1" clockkeeper "github.com/cybercongress/go-cyber/v7/x/clock/keeper" "github.com/cometbft/cometbft/libs/log" icacontrollerkeeper "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller/keeper" icahostkeeper "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/host/keeper" packetforwardkeeper "github.com/cosmos/ibc-apps/middleware/packet-forward-middleware/v7/packetforward/keeper" ibchooks "github.com/cosmos/ibc-apps/modules/ibc-hooks/v7" ibchookskeeper "github.com/cosmos/ibc-apps/modules/ibc-hooks/v7/keeper" ibchookstypes "github.com/cosmos/ibc-apps/modules/ibc-hooks/v7/types" ) var ( wasmCapabilities = "iterator,staking,stargate,cyber,cosmwasm_1_1,cosmwasm_1_2,cosmwasm_1_3" tokenFactoryCapabilities = []string{ tokenfactorytypes.EnableBurnFrom, tokenfactorytypes.EnableForceTransfer, tokenfactorytypes.EnableSetMetadata, } ) // module account permissions var maccPerms = map[string][]string{ authtypes.FeeCollectorName: nil, distrtypes.ModuleName: nil, minttypes.ModuleName: {authtypes.Minter}, stakingtypes.BondedPoolName: {authtypes.Burner, authtypes.Staking}, stakingtypes.NotBondedPoolName: {authtypes.Burner, authtypes.Staking}, govtypes.ModuleName: {authtypes.Burner}, nft.ModuleName: nil, ibctransfertypes.ModuleName: {authtypes.Minter, authtypes.Burner}, ibcfeetypes.ModuleName: nil, wasmtypes.ModuleName: {authtypes.Burner}, liquiditytypes.ModuleName: {authtypes.Minter, authtypes.Burner}, gridtypes.GridPoolName: nil, resourcestypes.ResourcesName: {authtypes.Minter, authtypes.Burner}, tokenfactorytypes.ModuleName: {authtypes.Minter, authtypes.Burner}, icatypes.ModuleName: nil, icqtypes.ModuleName: nil, bandwidthtypes.ModuleName: {authtypes.Burner}, } type AppKeepers struct { // keys to access the substores keys map[string]*storetypes.KVStoreKey tkeys map[string]*storetypes.TransientStoreKey memKeys map[string]*storetypes.MemoryStoreKey // keepers AccountKeeper authkeeper.AccountKeeper BankKeeper bankkeeper.Keeper CapabilityKeeper *capabilitykeeper.Keeper StakingKeeper *stakingkeeper.Keeper SlashingKeeper slashingkeeper.Keeper MintKeeper mintkeeper.Keeper DistrKeeper distrkeeper.Keeper GovKeeper govkeeper.Keeper CrisisKeeper *crisiskeeper.Keeper UpgradeKeeper *upgradekeeper.Keeper ParamsKeeper paramskeeper.Keeper EvidenceKeeper evidencekeeper.Keeper FeeGrantKeeper feegrantkeeper.Keeper NFTKeeper nftkeeper.Keeper AuthzKeeper authzkeeper.Keeper ConsensusParamsKeeper consensusparamkeeper.Keeper IBCKeeper *ibckeeper.Keeper // IBC Keeper must be a pointer in the app, so we can SetRouter on it correctly ICQKeeper *icqkeeper.Keeper ICAHostKeeper *icahostkeeper.Keeper ICAControllerKeeper *icacontrollerkeeper.Keeper IBCFeeKeeper ibcfeekeeper.Keeper IBCHooksKeeper *ibchookskeeper.Keeper TransferKeeper *ibctransferkeeper.Keeper TokenFactoryKeeper tokenfactorykeeper.Keeper WasmKeeper *wasmkeeper.Keeper LiquidityKeeper liquiditykeeper.Keeper BandwidthMeter *bandwidthkeeper.BandwidthMeter CyberbankKeeper *cyberbankkeeper.IndexedKeeper GraphKeeper *graphkeeper.GraphKeeper IndexKeeper *graphkeeper.IndexKeeper RankKeeper *rankkeeper.StateKeeper GridKeeper gridkeeper.Keeper DmnKeeper *dmnkeeper.Keeper ResourcesKeeper resourceskeeper.Keeper ContractKeeper wasmtypes.ContractOpsKeeper ClockKeeper clockkeeper.Keeper ScopedIBCKeeper capabilitykeeper.ScopedKeeper ScopedICQKeeper capabilitykeeper.ScopedKeeper ScopedTransferKeeper capabilitykeeper.ScopedKeeper ScopedICAHostKeeper capabilitykeeper.ScopedKeeper ScopedICAControllerKeeper capabilitykeeper.ScopedKeeper ScopedWasmKeeper capabilitykeeper.ScopedKeeper // IBC modules // transfer module // Middleware wrapper Ics20WasmHooks *ibchooks.WasmHooks HooksICS4Wrapper ibchooks.ICS4Middleware PacketForwardKeeper *packetforwardkeeper.Keeper } func NewAppKeepers( appCodec codec.Codec, bApp *baseapp.BaseApp, cdc *codec.LegacyAmino, maccPerms map[string][]string, invCheckPeriod uint, logger log.Logger, appOpts servertypes.AppOptions, wasmOpts []wasmkeeper.Option, ) AppKeepers { appKeepers := AppKeepers{} // Set keys KVStoreKey, TransientStoreKey, MemoryStoreKey appKeepers.GenerateKeys() keys := appKeepers.GetKVStoreKey() tkeys := appKeepers.GetTransientStoreKey() // load state streaming if enabled if _, _, err := streaming.LoadStreamingServices(bApp, appOpts, appCodec, logger, appKeepers.GetKVStoreKey()); err != nil { logger.Error("failed to load state streaming", "err", err) os.Exit(1) } appKeepers.ParamsKeeper = initParamsKeeper( appCodec, cdc, keys[paramstypes.StoreKey], tkeys[paramstypes.TStoreKey], ) govModAddress := authtypes.NewModuleAddress(govtypes.ModuleName).String() // set the BaseApp's parameter store appKeepers.ConsensusParamsKeeper = consensusparamkeeper.NewKeeper( appCodec, keys[consensusparamtypes.StoreKey], govModAddress, ) bApp.SetParamStore(&appKeepers.ConsensusParamsKeeper) // add capability keeper and ScopeToModule for ibc module appKeepers.CapabilityKeeper = capabilitykeeper.NewKeeper( appCodec, keys[capabilitytypes.StoreKey], appKeepers.memKeys[capabilitytypes.MemStoreKey], ) scopedIBCKeeper := appKeepers.CapabilityKeeper.ScopeToModule(ibcexported.ModuleName) scopedICAHostKeeper := appKeepers.CapabilityKeeper.ScopeToModule(icahosttypes.SubModuleName) scopedICAControllerKeeper := appKeepers.CapabilityKeeper.ScopeToModule(icacontrollertypes.SubModuleName) scopedICQKeeper := appKeepers.CapabilityKeeper.ScopeToModule(icqtypes.ModuleName) scopedTransferKeeper := appKeepers.CapabilityKeeper.ScopeToModule(ibctransfertypes.ModuleName) scopedWasmKeeper := appKeepers.CapabilityKeeper.ScopeToModule(wasmtypes.ModuleName) appKeepers.CapabilityKeeper.Seal() // add keepers Bech32Prefix := "bostrom" appKeepers.AccountKeeper = authkeeper.NewAccountKeeper( appCodec, keys[authtypes.StoreKey], authtypes.ProtoBaseAccount, maccPerms, Bech32Prefix, govModAddress, ) appKeepers.BankKeeper = bankkeeper.NewBaseKeeper( appCodec, keys[banktypes.StoreKey], appKeepers.AccountKeeper, BlockedAddresses(), govModAddress, ) // Cyber uses custom bank module wrapped around SDK's bank module appKeepers.CyberbankKeeper = cyberbankkeeper.NewIndexedKeeper( appCodec, keys[authtypes.StoreKey], cyberbankkeeper.Wrap(appKeepers.BankKeeper), appKeepers.AccountKeeper, ) stakingKeeper := stakingkeeper.NewKeeper( appCodec, keys[stakingtypes.StoreKey], appKeepers.AccountKeeper, appKeepers.CyberbankKeeper.Proxy, govModAddress, ) appKeepers.MintKeeper = mintkeeper.NewKeeper( appCodec, keys[minttypes.StoreKey], stakingKeeper, appKeepers.AccountKeeper, appKeepers.CyberbankKeeper.Proxy, authtypes.FeeCollectorName, govModAddress, ) appKeepers.DistrKeeper = distrkeeper.NewKeeper( appCodec, keys[distrtypes.StoreKey], appKeepers.AccountKeeper, appKeepers.CyberbankKeeper.Proxy, stakingKeeper, authtypes.FeeCollectorName, govModAddress, ) appKeepers.SlashingKeeper = slashingkeeper.NewKeeper( appCodec, cdc, keys[slashingtypes.StoreKey], stakingKeeper, govModAddress, ) appKeepers.CrisisKeeper = crisiskeeper.NewKeeper( appCodec, keys[crisistypes.StoreKey], invCheckPeriod, appKeepers.CyberbankKeeper.Proxy, authtypes.FeeCollectorName, govModAddress, ) skipUpgradeHeights := map[int64]bool{} for _, h := range cast.ToIntSlice(appOpts.Get(server.FlagUnsafeSkipUpgrades)) { skipUpgradeHeights[int64(h)] = true } homePath := cast.ToString(appOpts.Get(flags.FlagHome)) appKeepers.UpgradeKeeper = upgradekeeper.NewKeeper( skipUpgradeHeights, keys[upgradetypes.StoreKey], appCodec, homePath, bApp, govModAddress, ) // register the staking hooks // NOTE: stakingKeeper above is passed by reference, so that it will contain these hooks stakingKeeper.SetHooks( stakingtypes.NewMultiStakingHooks( appKeepers.DistrKeeper.Hooks(), appKeepers.SlashingKeeper.Hooks(), ), ) appKeepers.StakingKeeper = stakingKeeper // Start cyber's keepers configuration appKeepers.BandwidthMeter = bandwidthkeeper.NewBandwidthMeter( appCodec, keys[bandwidthtypes.StoreKey], tkeys[bandwidthtypes.TStoreKey], appKeepers.CyberbankKeeper.Proxy, govModAddress, ) appKeepers.GraphKeeper = graphkeeper.NewKeeper( appCodec, keys[graphtypes.ModuleName], // TODO fixed appKeepers.tkeys[paramstypes.TStoreKey], need test tkeys[graphtypes.TStoreKey], ) appKeepers.IndexKeeper = graphkeeper.NewIndexKeeper( *appKeepers.GraphKeeper, // TODO fixed appKeepers.tkeys[paramstypes.TStoreKey], need test tkeys[graphtypes.TStoreKey], ) computeUnit := ranktypes.ComputeUnit(cast.ToInt(appOpts.Get(rank.FlagComputeGPU))) computeMock := cast.ToBool(appOpts.Get(rank.FlagComputeMock)) searchAPI := cast.ToBool(appOpts.Get(rank.FlagSearchAPI)) appKeepers.RankKeeper = rankkeeper.NewKeeper( appCodec, keys[ranktypes.ModuleName], searchAPI, appKeepers.CyberbankKeeper, appKeepers.IndexKeeper, appKeepers.GraphKeeper, appKeepers.AccountKeeper, computeUnit, computeMock, govModAddress, ) appKeepers.GridKeeper = gridkeeper.NewKeeper( appCodec, keys[gridtypes.ModuleName], appKeepers.CyberbankKeeper.Proxy, appKeepers.AccountKeeper, govModAddress, ) appKeepers.CyberbankKeeper.SetGridKeeper(&appKeepers.GridKeeper) appKeepers.CyberbankKeeper.SetAccountKeeper(appKeepers.AccountKeeper) appKeepers.CyberbankKeeper.SetGraphKeeper(appKeepers.GraphKeeper) appKeepers.ResourcesKeeper = resourceskeeper.NewKeeper( appCodec, keys[gridtypes.ModuleName], appKeepers.AccountKeeper, appKeepers.CyberbankKeeper.Proxy, appKeepers.BandwidthMeter, appKeepers.GraphKeeper, govModAddress, ) appKeepers.DmnKeeper = dmnkeeper.NewKeeper( appCodec, keys[dmntypes.StoreKey], appKeepers.CyberbankKeeper.Proxy, appKeepers.AccountKeeper, govModAddress, ) appKeepers.LiquidityKeeper = liquiditykeeper.NewKeeper( appCodec, keys[liquiditytypes.StoreKey], appKeepers.CyberbankKeeper.Proxy, appKeepers.AccountKeeper, appKeepers.DistrKeeper, govModAddress, ) // End cyber's keepers configuration // Create IBC Keeper appKeepers.IBCKeeper = ibckeeper.NewKeeper( appCodec, keys[ibcexported.StoreKey], appKeepers.GetSubspace(ibcexported.ModuleName), stakingKeeper, appKeepers.UpgradeKeeper, scopedIBCKeeper, ) appKeepers.FeeGrantKeeper = feegrantkeeper.NewKeeper( appCodec, keys[feegrant.StoreKey], appKeepers.AccountKeeper, ) appKeepers.AuthzKeeper = authzkeeper.NewKeeper( keys[authzkeeper.StoreKey], appCodec, bApp.MsgServiceRouter(), appKeepers.AccountKeeper, ) // register the proposal types govRouter := govv1beta.NewRouter() govRouter. AddRoute(govtypes.RouterKey, govv1beta.ProposalHandler). AddRoute(paramproposal.RouterKey, sdkparams.NewParamChangeProposalHandler(appKeepers.ParamsKeeper)). AddRoute(upgradetypes.RouterKey, upgrade.NewSoftwareUpgradeProposalHandler(appKeepers.UpgradeKeeper)). AddRoute(ibcclienttypes.RouterKey, ibcclient.NewClientProposalHandler(appKeepers.IBCKeeper.ClientKeeper)) govConfig := govtypes.DefaultConfig() govConfig.MaxMetadataLen = 10200 govKeeper := govkeeper.NewKeeper( appCodec, keys[govtypes.StoreKey], appKeepers.AccountKeeper, appKeepers.CyberbankKeeper.Proxy, appKeepers.StakingKeeper, bApp.MsgServiceRouter(), govtypes.DefaultConfig(), govModAddress, ) appKeepers.GovKeeper = *govKeeper.SetHooks( govtypes.NewMultiGovHooks( // register governance hooks ), ) appKeepers.NFTKeeper = nftkeeper.NewKeeper(keys[nftkeeper.StoreKey], appCodec, appKeepers.AccountKeeper, appKeepers.CyberbankKeeper.Proxy) // Configure the hooks keeper hooksKeeper := ibchookskeeper.NewKeeper( appKeepers.keys[ibchookstypes.StoreKey], ) appKeepers.IBCHooksKeeper = &hooksKeeper cyberPrefix := sdk.GetConfig().GetBech32AccountAddrPrefix() wasmHooks := ibchooks.NewWasmHooks(appKeepers.IBCHooksKeeper, appKeepers.WasmKeeper, cyberPrefix) // The contract keeper needs to be set later appKeepers.Ics20WasmHooks = &wasmHooks appKeepers.HooksICS4Wrapper = ibchooks.NewICS4Middleware( appKeepers.IBCKeeper.ChannelKeeper, appKeepers.Ics20WasmHooks, ) // Do not use this middleware for anything except x/wasm requirement. // The spec currently requires new channels to be created, to use it. // We need to wait for Channel Upgradability before we can use this for any other middleware. appKeepers.IBCFeeKeeper = ibcfeekeeper.NewKeeper( appCodec, keys[ibcfeetypes.StoreKey], appKeepers.HooksICS4Wrapper, // replaced with IBC middleware appKeepers.IBCKeeper.ChannelKeeper, &appKeepers.IBCKeeper.PortKeeper, appKeepers.AccountKeeper, appKeepers.CyberbankKeeper.Proxy, ) // PacketForwardKeeper must be created before TransferKeeper appKeepers.PacketForwardKeeper = packetforwardkeeper.NewKeeper( appCodec, appKeepers.keys[packetforwardtypes.StoreKey], nil, // Will be zero-value here. Reference is set later on with SetTransferKeeper. appKeepers.IBCKeeper.ChannelKeeper, appKeepers.CyberbankKeeper.Proxy, appKeepers.HooksICS4Wrapper, govModAddress, ) // Create Transfer Keepers transferKeeper := ibctransferkeeper.NewKeeper( appCodec, keys[ibctransfertypes.StoreKey], appKeepers.GetSubspace(ibctransfertypes.ModuleName), // The ICS4Wrapper is replaced by the PacketForwardKeeper instead of the channel so that sending can be overridden by the middleware appKeepers.PacketForwardKeeper, appKeepers.IBCKeeper.ChannelKeeper, &appKeepers.IBCKeeper.PortKeeper, appKeepers.AccountKeeper, appKeepers.CyberbankKeeper.Proxy, scopedTransferKeeper, ) appKeepers.TransferKeeper = &transferKeeper // Must be called on PFMRouter AFTER TransferKeeper initialized appKeepers.PacketForwardKeeper.SetTransferKeeper(appKeepers.TransferKeeper) // ICQ Keeper icqKeeper := icqkeeper.NewKeeper( appCodec, appKeepers.keys[icqtypes.StoreKey], appKeepers.IBCKeeper.ChannelKeeper, // may be replaced with middleware appKeepers.IBCKeeper.ChannelKeeper, &appKeepers.IBCKeeper.PortKeeper, scopedICQKeeper, bApp.GRPCQueryRouter(), govModAddress, ) appKeepers.ICQKeeper = &icqKeeper icaHostKeeper := icahostkeeper.NewKeeper( appCodec, keys[icahosttypes.StoreKey], appKeepers.GetSubspace(icahosttypes.SubModuleName), appKeepers.HooksICS4Wrapper, appKeepers.IBCKeeper.ChannelKeeper, &appKeepers.IBCKeeper.PortKeeper, appKeepers.AccountKeeper, scopedICAHostKeeper, bApp.MsgServiceRouter(), ) appKeepers.ICAHostKeeper = &icaHostKeeper // required since ibc-go v7.5.0 appKeepers.ICAHostKeeper.WithQueryRouter(bApp.GRPCQueryRouter()) icaControllerKeeper := icacontrollerkeeper.NewKeeper( appCodec, keys[icacontrollertypes.StoreKey], appKeepers.GetSubspace(icacontrollertypes.SubModuleName), appKeepers.IBCFeeKeeper, // use ics29 fee as ics4Wrapper in middleware stack appKeepers.IBCKeeper.ChannelKeeper, &appKeepers.IBCKeeper.PortKeeper, scopedICAControllerKeeper, bApp.MsgServiceRouter(), ) appKeepers.ICAControllerKeeper = &icaControllerKeeper // Create evidence Keeper for to register the IBC light client misbehaviour evidence route evidenceKeeper := evidencekeeper.NewKeeper( appCodec, keys[evidencetypes.StoreKey], stakingKeeper, appKeepers.SlashingKeeper, ) // If evidence needs to be handled for the app, set routes in router here and seal appKeepers.EvidenceKeeper = *evidenceKeeper appKeepers.TokenFactoryKeeper = tokenfactorykeeper.NewKeeper( appCodec, appKeepers.keys[tokenfactorytypes.StoreKey], maccPerms, appKeepers.AccountKeeper, appKeepers.CyberbankKeeper.Proxy, appKeepers.DistrKeeper, tokenFactoryCapabilities, govModAddress, ) // TODO update later to data (move wasm dir inside data directory) wasmDir := filepath.Join(homePath, "wasm") wasmConfig, err := wasm.ReadWasmConfig(appOpts) if err != nil { panic(fmt.Sprintf("error while reading wasm config: %s", err)) } cyberOpts := wasmplugins.RegisterCustomPlugins( appKeepers.RankKeeper, appKeepers.GraphKeeper, appKeepers.DmnKeeper, &appKeepers.GridKeeper, appKeepers.BandwidthMeter, &appKeepers.ResourcesKeeper, appKeepers.IndexKeeper, &appKeepers.AccountKeeper, appKeepers.CyberbankKeeper, &appKeepers.BankKeeper, &appKeepers.TokenFactoryKeeper, ) wasmOpts = append(wasmOpts, cyberOpts...) wasmOpts = append(wasmplugins.RegisterStargateQueries(*bApp.GRPCQueryRouter(), appCodec), wasmOpts...) wasmKeeper := wasmkeeper.NewKeeper( appCodec, keys[wasmtypes.StoreKey], appKeepers.AccountKeeper, appKeepers.CyberbankKeeper.Proxy, stakingKeeper, distrkeeper.NewQuerier(appKeepers.DistrKeeper), appKeepers.IBCFeeKeeper, // ISC4 Wrapper: fee IBC middleware appKeepers.IBCKeeper.ChannelKeeper, &appKeepers.IBCKeeper.PortKeeper, scopedWasmKeeper, appKeepers.TransferKeeper, bApp.MsgServiceRouter(), bApp.GRPCQueryRouter(), wasmDir, wasmConfig, wasmCapabilities, govModAddress, wasmOpts..., ) appKeepers.WasmKeeper = &wasmKeeper // set the contract keeper for the Ics20WasmHooks appKeepers.ContractKeeper = wasmkeeper.NewDefaultPermissionKeeper(appKeepers.WasmKeeper) appKeepers.Ics20WasmHooks.ContractKeeper = appKeepers.WasmKeeper //appKeepers.IBCHooksKeeper.ContractKeeper = appKeepers.ContractKeeper appKeepers.ClockKeeper = clockkeeper.NewKeeper( appKeepers.keys[clocktypes.StoreKey], appCodec, *appKeepers.WasmKeeper, appKeepers.ContractKeeper, govModAddress, ) appKeepers.DmnKeeper.SetWasmKeeper(*appKeepers.WasmKeeper) // register wasm gov proposal types // The gov proposal types can be individually enabled govRouter.AddRoute(wasm.RouterKey, wasmkeeper.NewLegacyWasmProposalHandler(appKeepers.WasmKeeper, wasmtypes.EnableAllProposals)) // Set legacy router for backwards compatibility with gov v1beta1 appKeepers.GovKeeper.SetLegacyRouter(govRouter) // Create Transfer Stack var transferStack porttypes.IBCModule transferStack = transfer.NewIBCModule(*appKeepers.TransferKeeper) transferStack = ibchooks.NewIBCMiddleware(transferStack, &appKeepers.HooksICS4Wrapper) transferStack = packetforward.NewIBCMiddleware( transferStack, appKeepers.PacketForwardKeeper, 0, packetforwardkeeper.DefaultForwardTransferPacketTimeoutTimestamp, packetforwardkeeper.DefaultRefundTransferPacketTimeoutTimestamp, ) // ibcfee must come after PFM since PFM does not understand IncentivizedAcknowlegements (ICS29) transferStack = ibcfee.NewIBCMiddleware(transferStack, appKeepers.IBCFeeKeeper) // Create Interchain Accounts Stack // SendPacket, since it is originating from the application to core IBC: // icaAuthModuleKeeper.SendTx -> icaController.SendPacket -> fee.SendPacket -> channel.SendPacket var icaControllerStack porttypes.IBCModule // integration point for custom authentication modules // see https://medium.com/the-interchain-foundation/ibc-go-v6-changes-to-interchain-accounts-and-how-it-impacts-your-chain-806c185300d7 var noAuthzModule porttypes.IBCModule icaControllerStack = icacontroller.NewIBCMiddleware(noAuthzModule, *appKeepers.ICAControllerKeeper) icaControllerStack = ibcfee.NewIBCMiddleware(icaControllerStack, appKeepers.IBCFeeKeeper) // RecvPacket, message that originates from core IBC and goes down to app, the flow is: // channel.RecvPacket -> fee.OnRecvPacket -> icaHost.OnRecvPacket var icaHostStack porttypes.IBCModule icaHostStack = icahost.NewIBCModule(*appKeepers.ICAHostKeeper) icaHostStack = ibcfee.NewIBCMiddleware(icaHostStack, appKeepers.IBCFeeKeeper) // Create fee enabled wasm ibc Stack var wasmStack porttypes.IBCModule wasmStack = wasm.NewIBCHandler(appKeepers.WasmKeeper, appKeepers.IBCKeeper.ChannelKeeper, appKeepers.IBCFeeKeeper) wasmStack = ibcfee.NewIBCMiddleware(wasmStack, appKeepers.IBCFeeKeeper) // Create Async ICQ module icqModule := icq.NewIBCModule(*appKeepers.ICQKeeper) ibcRouter := porttypes.NewRouter(). AddRoute(ibctransfertypes.ModuleName, transferStack). AddRoute(wasmtypes.ModuleName, wasmStack). AddRoute(icacontrollertypes.SubModuleName, icaControllerStack). AddRoute(icahosttypes.SubModuleName, icaHostStack). AddRoute(icqtypes.ModuleName, icqModule) appKeepers.IBCKeeper.SetRouter(ibcRouter) appKeepers.ScopedWasmKeeper = scopedWasmKeeper appKeepers.ScopedIBCKeeper = scopedIBCKeeper appKeepers.ScopedTransferKeeper = scopedTransferKeeper appKeepers.ScopedICQKeeper = scopedICQKeeper appKeepers.ScopedICAHostKeeper = scopedICAHostKeeper appKeepers.ScopedICAControllerKeeper = scopedICAControllerKeeper return appKeepers } func initParamsKeeper(appCodec codec.BinaryCodec, legacyAmino *codec.LegacyAmino, key, tkey storetypes.StoreKey) paramskeeper.Keeper { paramsKeeper := paramskeeper.NewKeeper(appCodec, legacyAmino, key, tkey) // https://github.com/cosmos/ibc-go/issues/2010 // Will remove all of these in the future. For now we keep for legacy proposals to work properly. paramsKeeper.Subspace(authtypes.ModuleName) paramsKeeper.Subspace(banktypes.ModuleName) paramsKeeper.Subspace(distrtypes.ModuleName) paramsKeeper.Subspace(slashingtypes.ModuleName) paramsKeeper.Subspace(govtypes.ModuleName) paramsKeeper.Subspace(crisistypes.ModuleName) paramsKeeper.Subspace(stakingtypes.ModuleName) paramsKeeper.Subspace(minttypes.ModuleName) // custom paramsKeeper.Subspace(ibctransfertypes.ModuleName) paramsKeeper.Subspace(ibcexported.ModuleName) paramsKeeper.Subspace(icahosttypes.SubModuleName) paramsKeeper.Subspace(icacontrollertypes.SubModuleName) paramsKeeper.Subspace(icqtypes.ModuleName) // commented out because there are no more ParamKeyTable in packer forward module //paramsKeeper.Subspace(packetforwardtypes.ModuleName).WithKeyTable(packetforwardtypes.ParamKeyTable()) paramsKeeper.Subspace(wasmtypes.ModuleName) paramsKeeper.Subspace(bandwidthtypes.ModuleName) paramsKeeper.Subspace(ranktypes.ModuleName) paramsKeeper.Subspace(gridtypes.ModuleName) paramsKeeper.Subspace(dmntypes.ModuleName) paramsKeeper.Subspace(resourcestypes.ModuleName) paramsKeeper.Subspace(liquiditytypes.ModuleName) paramsKeeper.Subspace(tokenfactorytypes.ModuleName) return paramsKeeper } // GetSubspace returns a param subspace for a given module name. func (appKeepers *AppKeepers) GetSubspace(moduleName string) paramstypes.Subspace { subspace, _ := appKeepers.ParamsKeeper.GetSubspace(moduleName) return subspace } // BlockedAddresses returns all the app's blocked account addresses. func BlockedAddresses() map[string]bool { modAccAddrs := make(map[string]bool) for acc := range GetMaccPerms() { modAccAddrs[authtypes.NewModuleAddress(acc).String()] = true } // allow the following addresses to receive funds delete(modAccAddrs, authtypes.NewModuleAddress(govtypes.ModuleName).String()) return modAccAddrs } // GetMaccPerms returns a copy of the module account permissions func GetMaccPerms() map[string][]string { dupMaccPerms := make(map[string][]string) for k, v := range maccPerms { dupMaccPerms[k] = v } return dupMaccPerms } ================================================ FILE: app/keepers/keys.go ================================================ package keepers import ( wasmtypes "github.com/CosmWasm/wasmd/x/wasm/types" storetypes "github.com/cosmos/cosmos-sdk/store/types" sdk "github.com/cosmos/cosmos-sdk/types" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" authzkeeper "github.com/cosmos/cosmos-sdk/x/authz/keeper" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" capabilitytypes "github.com/cosmos/cosmos-sdk/x/capability/types" consensusparamtypes "github.com/cosmos/cosmos-sdk/x/consensus/types" crisistypes "github.com/cosmos/cosmos-sdk/x/crisis/types" distrtypes "github.com/cosmos/cosmos-sdk/x/distribution/types" evidencetypes "github.com/cosmos/cosmos-sdk/x/evidence/types" "github.com/cosmos/cosmos-sdk/x/feegrant" govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" minttypes "github.com/cosmos/cosmos-sdk/x/mint/types" nftkeeper "github.com/cosmos/cosmos-sdk/x/nft/keeper" paramstypes "github.com/cosmos/cosmos-sdk/x/params/types" slashingtypes "github.com/cosmos/cosmos-sdk/x/slashing/types" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" packetforwardtypes "github.com/cosmos/ibc-apps/middleware/packet-forward-middleware/v7/packetforward/types" icqtypes "github.com/cosmos/ibc-apps/modules/async-icq/v7/types" ibchookstypes "github.com/cosmos/ibc-apps/modules/ibc-hooks/v7/types" icacontrollertypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller/types" icahosttypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/host/types" ibcfeetypes "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/types" ibctransfertypes "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" ibcexported "github.com/cosmos/ibc-go/v7/modules/core/exported" clocktypes "github.com/cybercongress/go-cyber/v7/x/clock/types" tokenfactorytypes "github.com/cybercongress/go-cyber/v7/x/tokenfactory/types" liquiditytypes "github.com/cybercongress/go-cyber/v7/x/liquidity/types" bandwidthtypes "github.com/cybercongress/go-cyber/v7/x/bandwidth/types" dmntypes "github.com/cybercongress/go-cyber/v7/x/dmn/types" graphtypes "github.com/cybercongress/go-cyber/v7/x/graph/types" gridtypes "github.com/cybercongress/go-cyber/v7/x/grid/types" ranktypes "github.com/cybercongress/go-cyber/v7/x/rank/types" resourcestypes "github.com/cybercongress/go-cyber/v7/x/resources/types" ) func (appKeepers *AppKeepers) GenerateKeys() { appKeepers.keys = sdk.NewKVStoreKeys( // defaults authtypes.StoreKey, banktypes.StoreKey, stakingtypes.StoreKey, minttypes.StoreKey, distrtypes.StoreKey, slashingtypes.StoreKey, govtypes.StoreKey, paramstypes.StoreKey, upgradetypes.StoreKey, evidencetypes.StoreKey, capabilitytypes.StoreKey, authzkeeper.StoreKey, feegrant.StoreKey, nftkeeper.StoreKey, consensusparamtypes.StoreKey, crisistypes.StoreKey, // non sdk store keys icahosttypes.StoreKey, icacontrollertypes.StoreKey, ibcexported.StoreKey, ibctransfertypes.StoreKey, ibcfeetypes.StoreKey, wasmtypes.StoreKey, packetforwardtypes.StoreKey, ibchookstypes.StoreKey, icqtypes.StoreKey, // our additions clocktypes.StoreKey, liquiditytypes.StoreKey, bandwidthtypes.StoreKey, graphtypes.StoreKey, ranktypes.StoreKey, gridtypes.StoreKey, dmntypes.StoreKey, resourcestypes.StoreKey, tokenfactorytypes.StoreKey, ) appKeepers.tkeys = sdk.NewTransientStoreKeys( paramstypes.TStoreKey, graphtypes.TStoreKey, bandwidthtypes.TStoreKey, ) appKeepers.memKeys = sdk.NewMemoryStoreKeys(capabilitytypes.MemStoreKey) } func (appKeepers *AppKeepers) GetKVStoreKey() map[string]*storetypes.KVStoreKey { return appKeepers.keys } func (appKeepers *AppKeepers) GetTransientStoreKey() map[string]*storetypes.TransientStoreKey { return appKeepers.tkeys } func (appKeepers *AppKeepers) GetMemoryStoreKey() map[string]*storetypes.MemoryStoreKey { return appKeepers.memKeys } // GetKey returns the KVStoreKey for the provided store key. // // NOTE: This is solely to be used for testing purposes. func (appKeepers *AppKeepers) GetKey(storeKey string) *storetypes.KVStoreKey { return appKeepers.keys[storeKey] } // GetTKey returns the TransientStoreKey for the provided store key. // // NOTE: This is solely to be used for testing purposes. func (appKeepers *AppKeepers) GetTKey(storeKey string) *storetypes.TransientStoreKey { return appKeepers.tkeys[storeKey] } // GetMemKey returns the MemStoreKey for the provided mem key. // // NOTE: This is solely used for testing purposes. func (appKeepers *AppKeepers) GetMemKey(storeKey string) *storetypes.MemoryStoreKey { return appKeepers.memKeys[storeKey] } ================================================ FILE: app/modules.go ================================================ package app import ( simappparams "cosmossdk.io/simapp/params" "github.com/CosmWasm/wasmd/x/wasm" wasmtypes "github.com/CosmWasm/wasmd/x/wasm/types" "github.com/cosmos/cosmos-sdk/types/module" "github.com/cosmos/cosmos-sdk/x/auth" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" "github.com/cosmos/cosmos-sdk/x/auth/vesting" vestingtypes "github.com/cosmos/cosmos-sdk/x/auth/vesting/types" "github.com/cosmos/cosmos-sdk/x/authz" authzmodule "github.com/cosmos/cosmos-sdk/x/authz/module" "github.com/cosmos/cosmos-sdk/x/bank" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" "github.com/cosmos/cosmos-sdk/x/capability" capabilitytypes "github.com/cosmos/cosmos-sdk/x/capability/types" "github.com/cosmos/cosmos-sdk/x/consensus" consensusparamtypes "github.com/cosmos/cosmos-sdk/x/consensus/types" "github.com/cosmos/cosmos-sdk/x/crisis" crisistypes "github.com/cosmos/cosmos-sdk/x/crisis/types" distr "github.com/cosmos/cosmos-sdk/x/distribution" distrtypes "github.com/cosmos/cosmos-sdk/x/distribution/types" "github.com/cosmos/cosmos-sdk/x/evidence" evidencetypes "github.com/cosmos/cosmos-sdk/x/evidence/types" "github.com/cosmos/cosmos-sdk/x/feegrant" feegrantmodule "github.com/cosmos/cosmos-sdk/x/feegrant/module" "github.com/cosmos/cosmos-sdk/x/genutil" genutiltypes "github.com/cosmos/cosmos-sdk/x/genutil/types" "github.com/cosmos/cosmos-sdk/x/gov" govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" "github.com/cosmos/cosmos-sdk/x/mint" minttypes "github.com/cosmos/cosmos-sdk/x/mint/types" "github.com/cosmos/cosmos-sdk/x/nft" nftmodule "github.com/cosmos/cosmos-sdk/x/nft/module" sdkparams "github.com/cosmos/cosmos-sdk/x/params" paramstypes "github.com/cosmos/cosmos-sdk/x/params/types" "github.com/cosmos/cosmos-sdk/x/slashing" slashingtypes "github.com/cosmos/cosmos-sdk/x/slashing/types" "github.com/cosmos/cosmos-sdk/x/staking" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" "github.com/cosmos/cosmos-sdk/x/upgrade" upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" packetforward "github.com/cosmos/ibc-apps/middleware/packet-forward-middleware/v7/packetforward" packetforwardtypes "github.com/cosmos/ibc-apps/middleware/packet-forward-middleware/v7/packetforward/types" ibchooks "github.com/cosmos/ibc-apps/modules/ibc-hooks/v7" ibchookstypes "github.com/cosmos/ibc-apps/modules/ibc-hooks/v7/types" ica "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts" ibcfee "github.com/cosmos/ibc-go/v7/modules/apps/29-fee" ibcfeetypes "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/types" "github.com/cosmos/ibc-go/v7/modules/apps/transfer" ibctransfertypes "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" ibc "github.com/cosmos/ibc-go/v7/modules/core" ibcexported "github.com/cosmos/ibc-go/v7/modules/core/exported" solomachine "github.com/cosmos/ibc-go/v7/modules/light-clients/06-solomachine" ibctm "github.com/cosmos/ibc-go/v7/modules/light-clients/07-tendermint" "github.com/cybercongress/go-cyber/v7/x/clock" "github.com/cybercongress/go-cyber/v7/x/tokenfactory" tokenfactorytypes "github.com/cybercongress/go-cyber/v7/x/tokenfactory/types" "github.com/cybercongress/go-cyber/v7/x/liquidity" liquiditytypes "github.com/cybercongress/go-cyber/v7/x/liquidity/types" "github.com/cybercongress/go-cyber/v7/x/bandwidth" bandwidthtypes "github.com/cybercongress/go-cyber/v7/x/bandwidth/types" "github.com/cybercongress/go-cyber/v7/x/cyberbank" cyberbanktypes "github.com/cybercongress/go-cyber/v7/x/cyberbank/types" "github.com/cybercongress/go-cyber/v7/x/dmn" dmntypes "github.com/cybercongress/go-cyber/v7/x/dmn/types" "github.com/cybercongress/go-cyber/v7/x/graph" graphtypes "github.com/cybercongress/go-cyber/v7/x/graph/types" grid "github.com/cybercongress/go-cyber/v7/x/grid" gridtypes "github.com/cybercongress/go-cyber/v7/x/grid/types" "github.com/cybercongress/go-cyber/v7/x/rank" ranktypes "github.com/cybercongress/go-cyber/v7/x/rank/types" "github.com/cybercongress/go-cyber/v7/x/resources" resourcestypes "github.com/cybercongress/go-cyber/v7/x/resources/types" stakingwrap "github.com/cybercongress/go-cyber/v7/x/staking" authsims "github.com/cosmos/cosmos-sdk/x/auth/simulation" icatypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/types" clocktypes "github.com/cybercongress/go-cyber/v7/x/clock/types" icq "github.com/cosmos/ibc-apps/modules/async-icq/v7" icqtypes "github.com/cosmos/ibc-apps/modules/async-icq/v7/types" ) // ModuleBasics TODO add notes which modules have functional blockers // ModuleBasics defines the module BasicManager is in charge of setting up basic, // non-dependant module elements, such as codec registration // and genesis verification. var ModuleBasics = module.NewBasicManager( auth.AppModuleBasic{}, genutil.NewAppModuleBasic(genutiltypes.DefaultMessageValidator), bank.AppModuleBasic{}, capability.AppModuleBasic{}, staking.AppModuleBasic{}, mint.AppModuleBasic{}, distr.AppModuleBasic{}, gov.NewAppModuleBasic(getGovProposalHandlers()), sdkparams.AppModuleBasic{}, crisis.AppModuleBasic{}, slashing.AppModuleBasic{}, upgrade.AppModuleBasic{}, evidence.AppModuleBasic{}, authzmodule.AppModuleBasic{}, feegrantmodule.AppModuleBasic{}, vesting.AppModuleBasic{}, nftmodule.AppModuleBasic{}, transfer.AppModuleBasic{}, consensus.AppModuleBasic{}, liquidity.AppModuleBasic{}, wasm.AppModuleBasic{}, bandwidth.AppModuleBasic{}, cyberbank.AppModuleBasic{}, graph.AppModuleBasic{}, rank.AppModuleBasic{}, grid.AppModuleBasic{}, dmn.AppModuleBasic{}, resources.AppModuleBasic{}, tokenfactory.AppModuleBasic{}, clock.AppModuleBasic{}, ibctm.AppModuleBasic{}, ibc.AppModuleBasic{}, ica.AppModuleBasic{}, ibcfee.AppModuleBasic{}, icq.AppModuleBasic{}, ibchooks.AppModuleBasic{}, packetforward.AppModuleBasic{}, solomachine.AppModuleBasic{}, ) func appModules( app *App, encodingConfig simappparams.EncodingConfig, skipGenesisInvariants bool, ) []module.AppModule { appCodec := encodingConfig.Codec return []module.AppModule{ genutil.NewAppModule( app.AccountKeeper, app.StakingKeeper, app.BaseApp.DeliverTx, encodingConfig.TxConfig, ), auth.NewAppModule(appCodec, app.AccountKeeper, nil, app.GetSubspace(authtypes.ModuleName)), vesting.NewAppModule(app.AccountKeeper, app.CyberbankKeeper.Proxy), bank.NewAppModule(appCodec, app.BankKeeper, app.AccountKeeper, app.GetSubspace(banktypes.ModuleName)), capability.NewAppModule(appCodec, *app.CapabilityKeeper, false), feegrantmodule.NewAppModule(appCodec, app.AccountKeeper, app.CyberbankKeeper.Proxy, app.FeeGrantKeeper, app.interfaceRegistry), gov.NewAppModule(appCodec, &app.GovKeeper, app.AccountKeeper, app.CyberbankKeeper.Proxy, app.GetSubspace(govtypes.ModuleName)), mint.NewAppModule(appCodec, app.MintKeeper, app.AccountKeeper, nil, app.GetSubspace(minttypes.ModuleName)), slashing.NewAppModule(appCodec, app.SlashingKeeper, app.AccountKeeper, app.CyberbankKeeper.Proxy, app.StakingKeeper, app.GetSubspace(slashingtypes.ModuleName)), distr.NewAppModule(appCodec, app.DistrKeeper, app.AccountKeeper, app.CyberbankKeeper.Proxy, app.StakingKeeper, app.GetSubspace(distrtypes.ModuleName)), upgrade.NewAppModule(app.UpgradeKeeper), evidence.NewAppModule(app.EvidenceKeeper), sdkparams.NewAppModule(app.ParamsKeeper), authzmodule.NewAppModule(appCodec, app.AuthzKeeper, app.AccountKeeper, app.CyberbankKeeper.Proxy, app.interfaceRegistry), nftmodule.NewAppModule(appCodec, app.AppKeepers.NFTKeeper, app.AppKeepers.AccountKeeper, app.CyberbankKeeper.Proxy, app.interfaceRegistry), crisis.NewAppModule(app.AppKeepers.CrisisKeeper, skipGenesisInvariants, app.GetSubspace(crisistypes.ModuleName)), consensus.NewAppModule(appCodec, app.AppKeepers.ConsensusParamsKeeper), wasm.NewAppModule(appCodec, app.WasmKeeper, app.StakingKeeper, app.AccountKeeper, app.CyberbankKeeper.Proxy, app.MsgServiceRouter(), app.GetSubspace(wasmtypes.ModuleName)), liquidity.NewAppModule(appCodec, app.LiquidityKeeper, app.AccountKeeper, app.CyberbankKeeper.Proxy, app.DistrKeeper, app.GetSubspace(liquiditytypes.ModuleName)), cyberbank.NewAppModule(appCodec, app.CyberbankKeeper), bandwidth.NewAppModule(appCodec, app.AccountKeeper, app.BandwidthMeter, app.GetSubspace(bandwidthtypes.ModuleName)), graph.NewAppModule( appCodec, app.GraphKeeper, app.IndexKeeper, app.AccountKeeper, app.CyberbankKeeper, app.BandwidthMeter, ), rank.NewAppModule(appCodec, app.RankKeeper, app.GetSubspace(ranktypes.ModuleName)), grid.NewAppModule(appCodec, app.GridKeeper, app.GetSubspace(gridtypes.ModuleName)), dmn.NewAppModule(appCodec, *app.DmnKeeper, app.GetSubspace(dmntypes.ModuleName)), resources.NewAppModule(appCodec, app.ResourcesKeeper, app.GetSubspace(resourcestypes.ModuleName)), stakingwrap.NewAppModule(appCodec, app.StakingKeeper, app.AccountKeeper, app.CyberbankKeeper.Proxy, app.GetSubspace(stakingtypes.ModuleName)), // NOTE add Bank Proxy here to resolve issue when new neuron is created during token-factory token transfer // TODO add storage listener to update neurons memory index out of cyberbank proxy tokenfactory.NewAppModule(app.AppKeepers.TokenFactoryKeeper, app.AppKeepers.AccountKeeper, app.CyberbankKeeper.Proxy, app.GetSubspace(tokenfactorytypes.ModuleName)), clock.NewAppModule(appCodec, app.AppKeepers.ClockKeeper), ibc.NewAppModule(app.IBCKeeper), transfer.NewAppModule(*app.TransferKeeper), ibcfee.NewAppModule(app.IBCFeeKeeper), ica.NewAppModule(app.ICAControllerKeeper, app.ICAHostKeeper), ibchooks.NewAppModule(app.AppKeepers.AccountKeeper), packetforward.NewAppModule(app.PacketForwardKeeper, app.GetSubspace(packetforwardtypes.ModuleName)), icq.NewAppModule(*app.AppKeepers.ICQKeeper, app.GetSubspace(icqtypes.ModuleName)), } } // simulationModules returns modules for simulation manager // define the order of the modules for deterministic simulationss func simulationModules( app *App, encodingConfig simappparams.EncodingConfig, _ bool, ) []module.AppModuleSimulation { appCodec := encodingConfig.Codec return []module.AppModuleSimulation{ auth.NewAppModule(appCodec, app.AppKeepers.AccountKeeper, authsims.RandomGenesisAccounts, app.GetSubspace(authtypes.ModuleName)), bank.NewAppModule(appCodec, app.AppKeepers.BankKeeper, app.AppKeepers.AccountKeeper, app.GetSubspace(banktypes.ModuleName)), capability.NewAppModule(appCodec, *app.AppKeepers.CapabilityKeeper, false), feegrantmodule.NewAppModule(appCodec, app.AppKeepers.AccountKeeper, app.AppKeepers.BankKeeper, app.AppKeepers.FeeGrantKeeper, app.interfaceRegistry), authzmodule.NewAppModule(appCodec, app.AppKeepers.AuthzKeeper, app.AppKeepers.AccountKeeper, app.AppKeepers.BankKeeper, app.interfaceRegistry), gov.NewAppModule(appCodec, &app.AppKeepers.GovKeeper, app.AppKeepers.AccountKeeper, app.AppKeepers.BankKeeper, app.GetSubspace(govtypes.ModuleName)), mint.NewAppModule(appCodec, app.AppKeepers.MintKeeper, app.AppKeepers.AccountKeeper, nil, app.GetSubspace(minttypes.ModuleName)), stakingwrap.NewAppModule(appCodec, app.AppKeepers.StakingKeeper, app.AppKeepers.AccountKeeper, app.AppKeepers.BankKeeper, app.GetSubspace(stakingtypes.ModuleName)), distr.NewAppModule(appCodec, app.AppKeepers.DistrKeeper, app.AppKeepers.AccountKeeper, app.AppKeepers.BankKeeper, app.AppKeepers.StakingKeeper, app.GetSubspace(distrtypes.ModuleName)), slashing.NewAppModule(appCodec, app.AppKeepers.SlashingKeeper, app.AppKeepers.AccountKeeper, app.AppKeepers.BankKeeper, app.AppKeepers.StakingKeeper, app.GetSubspace(stakingtypes.ModuleName)), sdkparams.NewAppModule(app.AppKeepers.ParamsKeeper), evidence.NewAppModule(app.AppKeepers.EvidenceKeeper), wasm.NewAppModule(appCodec, app.AppKeepers.WasmKeeper, app.AppKeepers.StakingKeeper, app.AppKeepers.AccountKeeper, app.AppKeepers.BankKeeper, app.MsgServiceRouter(), app.GetSubspace(wasmtypes.ModuleName)), ibc.NewAppModule(app.AppKeepers.IBCKeeper), transfer.NewAppModule(*app.AppKeepers.TransferKeeper), ibcfee.NewAppModule(app.IBCFeeKeeper), ica.NewAppModule(app.ICAControllerKeeper, app.ICAHostKeeper), } } // orderBeginBlockers tell the app's module manager how to set the order of // BeginBlockers, which are run at the beginning of every block. // NOTE: capability module's beginblocker must come before any modules using capabilities (e.g. IBC) func orderBeginBlockers() []string { return []string{ // upgrades should be run first upgradetypes.ModuleName, capabilitytypes.ModuleName, minttypes.ModuleName, distrtypes.ModuleName, slashingtypes.ModuleName, evidencetypes.ModuleName, stakingtypes.ModuleName, authtypes.ModuleName, banktypes.ModuleName, govtypes.ModuleName, crisistypes.ModuleName, ibcexported.ModuleName, ibctransfertypes.ModuleName, icatypes.ModuleName, packetforwardtypes.ModuleName, ibcfeetypes.ModuleName, genutiltypes.ModuleName, authz.ModuleName, feegrant.ModuleName, paramstypes.ModuleName, vestingtypes.ModuleName, consensusparamtypes.ModuleName, nft.ModuleName, icqtypes.ModuleName, ibchookstypes.ModuleName, // additional modules liquiditytypes.ModuleName, dmntypes.ModuleName, clocktypes.ModuleName, bandwidthtypes.ModuleName, cyberbanktypes.ModuleName, graphtypes.ModuleName, gridtypes.ModuleName, ranktypes.ModuleName, resourcestypes.ModuleName, tokenfactorytypes.ModuleName, wasm.ModuleName, } } func orderEndBlockers() []string { return []string{ crisistypes.ModuleName, govtypes.ModuleName, stakingtypes.ModuleName, ibcexported.ModuleName, ibctransfertypes.ModuleName, icatypes.ModuleName, packetforwardtypes.ModuleName, capabilitytypes.ModuleName, ibcfeetypes.ModuleName, authtypes.ModuleName, banktypes.ModuleName, distrtypes.ModuleName, slashingtypes.ModuleName, minttypes.ModuleName, genutiltypes.ModuleName, evidencetypes.ModuleName, authz.ModuleName, feegrant.ModuleName, paramstypes.ModuleName, upgradetypes.ModuleName, vestingtypes.ModuleName, consensusparamtypes.ModuleName, nft.ModuleName, icqtypes.ModuleName, ibchookstypes.ModuleName, // additional modules clocktypes.ModuleName, tokenfactorytypes.ModuleName, dmntypes.ModuleName, gridtypes.ModuleName, resourcestypes.ModuleName, liquiditytypes.ModuleName, wasm.ModuleName, // TODO check end blocks cyberbanktypes.ModuleName, bandwidthtypes.ModuleName, graphtypes.ModuleName, ranktypes.ModuleName, } } // NOTE: The genutils module must occur after staking so that pools are // properly initialized with tokens from genesis accounts. // NOTE: The genutils module must also occur after auth so that it can access the params from auth. // NOTE: Capability module must occur first so that it can initialize any capabilities // so that other modules that want to create or claim capabilities afterwards in InitChain // can do so safely. // NOTE: wasm module should be at the end as it can call other module functionality direct or via message dispatching during // genesis phase. For example bank transfer, auth account check, staking, ... func orderInitBlockers() []string { return []string{ capabilitytypes.ModuleName, authtypes.ModuleName, banktypes.ModuleName, distrtypes.ModuleName, govtypes.ModuleName, stakingtypes.ModuleName, slashingtypes.ModuleName, minttypes.ModuleName, crisistypes.ModuleName, genutiltypes.ModuleName, ibctransfertypes.ModuleName, ibcexported.ModuleName, icatypes.ModuleName, evidencetypes.ModuleName, authz.ModuleName, feegrant.ModuleName, packetforwardtypes.ModuleName, paramstypes.ModuleName, upgradetypes.ModuleName, vestingtypes.ModuleName, nft.ModuleName, consensusparamtypes.ModuleName, icqtypes.ModuleName, ibchookstypes.ModuleName, // additional modules liquiditytypes.ModuleName, ibcfeetypes.ModuleName, clocktypes.ModuleName, tokenfactorytypes.ModuleName, bandwidthtypes.ModuleName, ranktypes.ModuleName, gridtypes.ModuleName, resourcestypes.ModuleName, dmntypes.ModuleName, graphtypes.ModuleName, // NOTE: cyberbank will be initialized directly in InitChainer cyberbanktypes.ModuleName, wasm.ModuleName, } } ================================================ FILE: app/params/const.go ================================================ package params const ( DefaultDenom = "boot" BondDenom = "boot" ) ================================================ FILE: app/params/encoding.go ================================================ package params import ( simappparams "cosmossdk.io/simapp/params" "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/codec/types" "github.com/cosmos/cosmos-sdk/x/auth/tx" ) // MakeEncodingConfig creates an EncodingConfig for an amino based test configuration. func MakeEncodingConfig() simappparams.EncodingConfig { amino := codec.NewLegacyAmino() interfaceRegistry := types.NewInterfaceRegistry() marshaler := codec.NewProtoCodec(interfaceRegistry) txCfg := tx.NewTxConfig(marshaler, tx.DefaultSignModes) return simappparams.EncodingConfig{ InterfaceRegistry: interfaceRegistry, Codec: marshaler, TxConfig: txCfg, Amino: amino, } } ================================================ FILE: app/params/weights.go ================================================ package params // Simulation parameter constants const ( StakePerAccount = "stake_per_account" InitiallyBondedValidators = "initially_bonded_validators" DefaultWeightMsgCreateDenom int = 100 DefaultWeightMsgMint int = 100 DefaultWeightMsgBurn int = 100 DefaultWeightMsgChangeAdmin int = 100 DefaultWeightMsgSetDenomMetadata int = 100 DefaultWeightMsgForceTransfer int = 100 ) ================================================ FILE: app/prefix.go ================================================ package app import ( wasmtypes "github.com/CosmWasm/wasmd/x/wasm/types" sdk "github.com/cosmos/cosmos-sdk/types" ) var ( AccountAddressPrefix = Bech32Prefix AccountPubKeyPrefix = AccountAddressPrefix + "pub" ValidatorAddressPrefix = AccountAddressPrefix + "valoper" ValidatorPubKeyPrefix = AccountAddressPrefix + "valoperpub" ConsNodeAddressPrefix = AccountAddressPrefix + "valcons" ConsNodePubKeyPrefix = AccountAddressPrefix + "valconspub" CoinType = 118 ) // SetConfig sets the configuration for the network using mainnet or testnet func SetConfig() { config := sdk.GetConfig() config.SetCoinType(uint32(CoinType)) config.SetBech32PrefixForAccount(AccountAddressPrefix, AccountPubKeyPrefix) config.SetBech32PrefixForValidator(ValidatorAddressPrefix, ValidatorPubKeyPrefix) config.SetBech32PrefixForConsensusNode(ConsNodeAddressPrefix, ConsNodePubKeyPrefix) config.SetAddressVerifier(wasmtypes.VerifyAddressLen()) config.Seal() } ================================================ FILE: app/proof_exempt.go ================================================ package app import ( "encoding/json" wasmtypes "github.com/CosmWasm/wasmd/x/wasm/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/x/auth/ante" ) // ProofExemptDecorator conditionally skips fee deduction for // PoW mining proof submissions to whitelisted contracts. // // When a transaction contains ONLY MsgExecuteContract calls // targeting an exempt contract with a "submit_proof" message, // the decorator bypasses DeductFeeDecorator entirely. // This allows miners to submit proofs without holding any tokens // for gas — the mining contract deducts gas cost from rewards. // // For all other transactions, normal fee deduction applies. type ProofExemptDecorator struct { inner ante.DeductFeeDecorator exemptContracts map[string]struct{} } func NewProofExemptDecorator( opts ante.HandlerOptions, exemptContracts []string, ) ProofExemptDecorator { contracts := make(map[string]struct{}, len(exemptContracts)) for _, c := range exemptContracts { if c != "" { contracts[c] = struct{}{} } } return ProofExemptDecorator{ inner: ante.NewDeductFeeDecorator(opts.AccountKeeper, opts.BankKeeper, opts.FeegrantKeeper, opts.TxFeeChecker), exemptContracts: contracts, } } func (d ProofExemptDecorator) AnteHandle( ctx sdk.Context, tx sdk.Tx, simulate bool, next sdk.AnteHandler, ) (sdk.Context, error) { if d.isProofSubmission(tx) { // Skip fee deduction — gas cost is handled inside the contract. // Still call next to continue the ante chain (sig verification, etc.). return next(ctx, tx, simulate) } return d.inner.AnteHandle(ctx, tx, simulate, next) } // isProofSubmission returns true when ALL messages in the tx are // MsgExecuteContract targeting an exempt contract with "submit_proof". func (d ProofExemptDecorator) isProofSubmission(tx sdk.Tx) bool { if len(d.exemptContracts) == 0 { return false } msgs := tx.GetMsgs() if len(msgs) == 0 { return false } for _, msg := range msgs { execMsg, ok := msg.(*wasmtypes.MsgExecuteContract) if !ok { return false } if _, exempt := d.exemptContracts[execMsg.Contract]; !exempt { return false } // Parse just the top-level keys to check for "submit_proof" var payload map[string]json.RawMessage if err := json.Unmarshal(execMsg.Msg, &payload); err != nil { return false } if _, ok := payload["submit_proof"]; !ok { return false } } return true } ================================================ FILE: app/proof_exempt_test.go ================================================ package app import ( "testing" wasmtypes "github.com/CosmWasm/wasmd/x/wasm/types" sdk "github.com/cosmos/cosmos-sdk/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" ) // mockTx implements sdk.Tx for testing isProofSubmission. type mockTx struct { msgs []sdk.Msg } func (m mockTx) GetMsgs() []sdk.Msg { return m.msgs } func (m mockTx) ValidateBasic() error { return nil } func newExecMsg(contract string, msgJSON string) *wasmtypes.MsgExecuteContract { return &wasmtypes.MsgExecuteContract{ Sender: "bostrom1sender", Contract: contract, Msg: wasmtypes.RawContractMessage(msgJSON), } } const mineContract = "bostrom123mine" func makeDecorator(contracts ...string) ProofExemptDecorator { m := make(map[string]struct{}, len(contracts)) for _, c := range contracts { m[c] = struct{}{} } return ProofExemptDecorator{exemptContracts: m} } // --- isProofSubmission tests --- func TestIsProofSubmission_ValidSingle(t *testing.T) { d := makeDecorator(mineContract) tx := mockTx{msgs: []sdk.Msg{ newExecMsg(mineContract, `{"submit_proof":{"hash":"abc","nonce":1,"miner_address":"bostrom1m","challenge":"def","difficulty":8,"timestamp":1700000000}}`), }} if !d.isProofSubmission(tx) { t.Fatal("expected valid single submit_proof to be recognized") } } func TestIsProofSubmission_ValidBatch(t *testing.T) { d := makeDecorator(mineContract) tx := mockTx{msgs: []sdk.Msg{ newExecMsg(mineContract, `{"submit_proof":{"hash":"a1","nonce":1,"miner_address":"m1","challenge":"c1","difficulty":8,"timestamp":1}}`), newExecMsg(mineContract, `{"submit_proof":{"hash":"a2","nonce":2,"miner_address":"m1","challenge":"c2","difficulty":8,"timestamp":2}}`), }} if !d.isProofSubmission(tx) { t.Fatal("expected batch of submit_proof to be recognized") } } func TestIsProofSubmission_WrongContract(t *testing.T) { d := makeDecorator(mineContract) tx := mockTx{msgs: []sdk.Msg{ newExecMsg("bostrom1other", `{"submit_proof":{"hash":"abc"}}`), }} if d.isProofSubmission(tx) { t.Fatal("should reject non-exempt contract") } } func TestIsProofSubmission_WrongMessage(t *testing.T) { d := makeDecorator(mineContract) tx := mockTx{msgs: []sdk.Msg{ newExecMsg(mineContract, `{"update_config":{"paused":true}}`), }} if d.isProofSubmission(tx) { t.Fatal("should reject non-submit_proof message") } } func TestIsProofSubmission_MixedMessages(t *testing.T) { d := makeDecorator(mineContract) tx := mockTx{msgs: []sdk.Msg{ newExecMsg(mineContract, `{"submit_proof":{"hash":"abc"}}`), newExecMsg(mineContract, `{"update_config":{"paused":true}}`), }} if d.isProofSubmission(tx) { t.Fatal("should reject tx with mixed message types") } } func TestIsProofSubmission_NonWasmMessage(t *testing.T) { d := makeDecorator(mineContract) tx := mockTx{msgs: []sdk.Msg{ &banktypes.MsgSend{FromAddress: "a", ToAddress: "b"}, }} if d.isProofSubmission(tx) { t.Fatal("should reject non-wasm messages") } } func TestIsProofSubmission_ProofPlusNonWasm(t *testing.T) { d := makeDecorator(mineContract) tx := mockTx{msgs: []sdk.Msg{ newExecMsg(mineContract, `{"submit_proof":{"hash":"abc"}}`), &banktypes.MsgSend{FromAddress: "a", ToAddress: "b"}, }} if d.isProofSubmission(tx) { t.Fatal("should reject proof bundled with non-wasm message") } } func TestIsProofSubmission_EmptyTx(t *testing.T) { d := makeDecorator(mineContract) tx := mockTx{msgs: []sdk.Msg{}} if d.isProofSubmission(tx) { t.Fatal("should reject empty tx") } } func TestIsProofSubmission_NoExemptContracts(t *testing.T) { d := makeDecorator() // empty list tx := mockTx{msgs: []sdk.Msg{ newExecMsg(mineContract, `{"submit_proof":{"hash":"abc"}}`), }} if d.isProofSubmission(tx) { t.Fatal("should reject when no contracts are exempt") } } func TestIsProofSubmission_InvalidJSON(t *testing.T) { d := makeDecorator(mineContract) tx := mockTx{msgs: []sdk.Msg{ newExecMsg(mineContract, `not json`), }} if d.isProofSubmission(tx) { t.Fatal("should reject invalid JSON") } } func TestIsProofSubmission_MultipleExemptContracts(t *testing.T) { other := "bostrom456mine" d := makeDecorator(mineContract, other) tx1 := mockTx{msgs: []sdk.Msg{ newExecMsg(mineContract, `{"submit_proof":{"hash":"abc"}}`), }} tx2 := mockTx{msgs: []sdk.Msg{ newExecMsg(other, `{"submit_proof":{"hash":"def"}}`), }} if !d.isProofSubmission(tx1) { t.Fatal("should accept first exempt contract") } if !d.isProofSubmission(tx2) { t.Fatal("should accept second exempt contract") } } ================================================ FILE: app/test_helpers.go ================================================ package app import ( "encoding/json" "path/filepath" "testing" "time" wasmkeeper "github.com/CosmWasm/wasmd/x/wasm/keeper" "github.com/stretchr/testify/require" dbm "github.com/cometbft/cometbft-db" abci "github.com/cometbft/cometbft/abci/types" "github.com/cometbft/cometbft/crypto" "github.com/cometbft/cometbft/crypto/ed25519" "github.com/cometbft/cometbft/libs/log" tmproto "github.com/cometbft/cometbft/proto/tendermint/types" tmtypes "github.com/cometbft/cometbft/types" "cosmossdk.io/math" bam "github.com/cosmos/cosmos-sdk/baseapp" "github.com/cosmos/cosmos-sdk/client/flags" codectypes "github.com/cosmos/cosmos-sdk/codec/types" cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" "github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1" "github.com/cosmos/cosmos-sdk/snapshots" snapshottypes "github.com/cosmos/cosmos-sdk/snapshots/types" simtestutil "github.com/cosmos/cosmos-sdk/testutil/sims" sdk "github.com/cosmos/cosmos-sdk/types" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" apphelpers "github.com/cybercongress/go-cyber/v7/app/helpers" appparams "github.com/cybercongress/go-cyber/v7/app/params" ) // SimAppChainID hardcoded chainID for simulation const ( SimAppChainID = "testing" ) // EmptyBaseAppOptions is a stub implementing AppOptions type EmptyBaseAppOptions struct{} // Get implements AppOptions func (ao EmptyBaseAppOptions) Get(_ string) interface{} { return nil } // DefaultConsensusParams defines the default Tendermint consensus params used // in junoApp testing. var DefaultConsensusParams = &tmproto.ConsensusParams{ Block: &tmproto.BlockParams{ MaxBytes: 200000, MaxGas: 2000000, }, Evidence: &tmproto.EvidenceParams{ MaxAgeNumBlocks: 302400, MaxAgeDuration: 504 * time.Hour, // 3 weeks is the max duration MaxBytes: 10000, }, Validator: &tmproto.ValidatorParams{ PubKeyTypes: []string{ tmtypes.ABCIPubKeyTypeEd25519, }, }, } type EmptyAppOptions struct{} func (EmptyAppOptions) Get(_ string) interface{} { return nil } func Setup(t *testing.T) *App { t.Helper() privVal := apphelpers.NewPV() pubKey, err := privVal.GetPubKey() require.NoError(t, err) // create validator set with single validator validator := tmtypes.NewValidator(pubKey, 1) valSet := tmtypes.NewValidatorSet([]*tmtypes.Validator{validator}) // generate genesis account senderPrivKey := secp256k1.GenPrivKey() acc := authtypes.NewBaseAccount(senderPrivKey.PubKey().Address().Bytes(), senderPrivKey.PubKey(), 0, 0) balance := banktypes.Balance{ Address: acc.GetAddress().String(), Coins: sdk.NewCoins(sdk.NewCoin(appparams.BondDenom, sdk.NewInt(100000000000000))), } app := SetupWithGenesisValSet(t, valSet, []authtypes.GenesisAccount{acc}, balance) return app } // SetupWithGenesisValSet initializes a new junoApp with a validator set and genesis accounts // that also act as delegators. For simplicity, each validator is bonded with a delegation // of one consensus engine unit in the default token of the JunoApp from first genesis // account. A Nop logger is set in JunoApp. func SetupWithGenesisValSet(t *testing.T, valSet *tmtypes.ValidatorSet, genAccs []authtypes.GenesisAccount, balances ...banktypes.Balance) *App { t.Helper() junoApp, genesisState := setup(t, true) genesisState = genesisStateWithValSet(t, junoApp, genesisState, valSet, genAccs, balances...) stateBytes, err := json.MarshalIndent(genesisState, "", " ") require.NoError(t, err) // init chain will set the validator set and initialize the genesis accounts junoApp.InitChain( abci.RequestInitChain{ Validators: []abci.ValidatorUpdate{}, ConsensusParams: DefaultConsensusParams, AppStateBytes: stateBytes, ChainId: "testing", Time: time.Now().UTC(), InitialHeight: 1, }, ) // commit genesis changes junoApp.Commit() junoApp.BeginBlock(abci.RequestBeginBlock{Header: tmproto.Header{ ChainID: "testing", Height: junoApp.LastBlockHeight() + 1, AppHash: junoApp.LastCommitID().Hash, ValidatorsHash: valSet.Hash(), NextValidatorsHash: valSet.Hash(), Time: time.Now().UTC(), }}) return junoApp } func setup(t *testing.T, withGenesis bool, opts ...wasmkeeper.Option) (*App, GenesisState) { db := dbm.NewMemDB() nodeHome := t.TempDir() snapshotDir := filepath.Join(nodeHome, "data", "snapshots") snapshotDB, err := dbm.NewDB("metadata", dbm.GoLevelDBBackend, snapshotDir) require.NoError(t, err) t.Cleanup(func() { snapshotDB.Close() }) snapshotStore, err := snapshots.NewStore(snapshotDB, snapshotDir) require.NoError(t, err) // var emptyWasmOpts []wasm.Option appOptions := make(simtestutil.AppOptionsMap, 0) appOptions[flags.FlagHome] = nodeHome // ensure unique folder app := NewBostromApp( log.NewNopLogger(), db, nil, true, EmptyAppOptions{}, opts, bam.SetChainID("testing"), bam.SetSnapshot(snapshotStore, snapshottypes.SnapshotOptions{KeepRecent: 2}), ) if withGenesis { return app, NewDefaultGenesisState(app.AppCodec()) } return app, GenesisState{} } func genesisStateWithValSet(t *testing.T, app *App, genesisState GenesisState, valSet *tmtypes.ValidatorSet, genAccs []authtypes.GenesisAccount, balances ...banktypes.Balance, ) GenesisState { codec := app.AppCodec() // set genesis accounts authGenesis := authtypes.NewGenesisState(authtypes.DefaultParams(), genAccs) genesisState[authtypes.ModuleName] = codec.MustMarshalJSON(authGenesis) validators := make([]stakingtypes.Validator, 0, len(valSet.Validators)) delegations := make([]stakingtypes.Delegation, 0, len(valSet.Validators)) bondAmt := sdk.DefaultPowerReduction for _, val := range valSet.Validators { pk, err := cryptocodec.FromTmPubKeyInterface(val.PubKey) require.NoError(t, err) pkAny, err := codectypes.NewAnyWithValue(pk) require.NoError(t, err) validator := stakingtypes.Validator{ OperatorAddress: sdk.ValAddress(val.Address).String(), ConsensusPubkey: pkAny, Jailed: false, Status: stakingtypes.Bonded, Tokens: bondAmt, DelegatorShares: math.LegacyOneDec(), Description: stakingtypes.Description{}, UnbondingHeight: int64(0), UnbondingTime: time.Unix(0, 0).UTC(), Commission: stakingtypes.NewCommission(math.LegacyZeroDec(), math.LegacyZeroDec(), math.LegacyZeroDec()), MinSelfDelegation: math.ZeroInt(), } validators = append(validators, validator) delegations = append(delegations, stakingtypes.NewDelegation(genAccs[0].GetAddress(), val.Address.Bytes(), math.LegacyOneDec())) } defaultStParams := stakingtypes.DefaultParams() stParams := stakingtypes.NewParams( defaultStParams.UnbondingTime, defaultStParams.MaxValidators, defaultStParams.MaxEntries, defaultStParams.HistoricalEntries, appparams.BondDenom, defaultStParams.MinCommissionRate, // 5% ) // set validators and delegations stakingGenesis := stakingtypes.NewGenesisState(stParams, validators, delegations) genesisState[stakingtypes.ModuleName] = codec.MustMarshalJSON(stakingGenesis) // add bonded amount to bonded pool module account balances = append(balances, banktypes.Balance{ Address: authtypes.NewModuleAddress(stakingtypes.BondedPoolName).String(), Coins: sdk.Coins{sdk.NewCoin(appparams.BondDenom, bondAmt.MulRaw(int64(len(valSet.Validators))))}, }) totalSupply := sdk.NewCoins() for _, b := range balances { // add genesis acc tokens to total supply totalSupply = totalSupply.Add(b.Coins...) } // update total supply bankGenesis := banktypes.NewGenesisState(banktypes.DefaultGenesisState().Params, balances, totalSupply, []banktypes.Metadata{}, []banktypes.SendEnabled{}) genesisState[banktypes.ModuleName] = codec.MustMarshalJSON(bankGenesis) // println("genesisStateWithValSet bankState:", string(genesisState[banktypes.ModuleName])) return genesisState } func keyPubAddr() (crypto.PrivKey, crypto.PubKey, sdk.AccAddress) { key := ed25519.GenPrivKey() pub := key.PubKey() addr := sdk.AccAddress(pub.Address()) return key, pub, addr } func RandomAccountAddress() sdk.AccAddress { _, _, addr := keyPubAddr() return addr } func ExecuteRawCustom(t *testing.T, ctx sdk.Context, app *App, contract sdk.AccAddress, sender sdk.AccAddress, msg json.RawMessage, funds sdk.Coin) error { t.Helper() oracleBz, err := json.Marshal(msg) require.NoError(t, err) // no funds sent if amount is 0 var coins sdk.Coins if !funds.Amount.IsNil() { coins = sdk.Coins{funds} } contractKeeper := wasmkeeper.NewDefaultPermissionKeeper(app.AppKeepers.WasmKeeper) _, err = contractKeeper.Execute(ctx, contract, sender, oracleBz, coins) return err } ================================================ FILE: app/upgrades/types.go ================================================ package upgrades import ( tmproto "github.com/cometbft/cometbft/proto/tendermint/types" store "github.com/cosmos/cosmos-sdk/store/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" "github.com/cybercongress/go-cyber/v7/app/keepers" ) // BaseAppParamManager defines an interrace that BaseApp is expected to fullfil // that allows upgrade handlers to modify BaseApp parameters. type BaseAppParamManager interface { GetConsensusParams(ctx sdk.Context) *tmproto.ConsensusParams StoreConsensusParams(ctx sdk.Context, cp *tmproto.ConsensusParams) } // Upgrade defines a struct containing necessary fields that a SoftwareUpgradeProposal // must have written, in order for the state migration to go smoothly. // An upgrade must implement this struct, and then set it in the app.go. // The app.go will then define the handler. type Upgrade struct { // Upgrade version name, for the upgrade handler, e.g. `v7` UpgradeName string // CreateUpgradeHandler defines the function that creates an upgrade handler CreateUpgradeHandler func( *module.Manager, module.Configurator, *keepers.AppKeepers, ) upgradetypes.UpgradeHandler // Store upgrades, should be used for any new modules introduced, new modules deleted, or store names renamed. StoreUpgrades store.StoreUpgrades } // Fork defines a struct containing the requisite fields for a non-software upgrade proposal // Hard Fork at a given height to implement. // There is one time code that can be added for the start of the Fork, in `BeginForkLogic`. // Any other change in the code should be height-gated, if the goal is to have old and new binaries // to be compatible prior to the upgrade height. type Fork struct { // Upgrade version name, for the upgrade handler, e.g. `v7` UpgradeName string // height the upgrade occurs at UpgradeHeight int64 // Function that runs some custom state transition code at the beginning of a fork. BeginForkLogic func(ctx sdk.Context, keepers *keepers.AppKeepers) } ================================================ FILE: app/upgrades/v2/constants.go ================================================ package v2 import ( store "github.com/cosmos/cosmos-sdk/store/types" "github.com/cybercongress/go-cyber/v7/app/upgrades" ) const UpgradeName = "cyberfrey" var Upgrade = upgrades.Upgrade{ UpgradeName: UpgradeName, CreateUpgradeHandler: CreateV2UpgradeHandler, StoreUpgrades: store.StoreUpgrades{ Added: []string{}, }, } ================================================ FILE: app/upgrades/v2/upgrades.go ================================================ package v2 import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" "github.com/cybercongress/go-cyber/v7/app/keepers" ) func CreateV2UpgradeHandler( _ *module.Manager, _ module.Configurator, _ *keepers.AppKeepers, ) upgradetypes.UpgradeHandler { return func(ctx sdk.Context, _ upgradetypes.Plan, vm module.VersionMap) (module.VersionMap, error) { return vm, nil } } ================================================ FILE: app/upgrades/v3/constants.go ================================================ package v3 import ( store "github.com/cosmos/cosmos-sdk/store/types" ibcfeetypes "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/types" "github.com/cybercongress/go-cyber/v7/app/upgrades" ) const UpgradeName = "v3" var Upgrade = upgrades.Upgrade{ UpgradeName: UpgradeName, CreateUpgradeHandler: CreateV3UpgradeHandler, StoreUpgrades: store.StoreUpgrades{ Added: []string{ ibcfeetypes.ModuleName, }, }, } ================================================ FILE: app/upgrades/v3/upgrades.go ================================================ package v3 import ( "fmt" "time" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" ibcfeetypes "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/types" "github.com/cybercongress/go-cyber/v7/app/keepers" ) func CreateV3UpgradeHandler( mm *module.Manager, cfg module.Configurator, _ *keepers.AppKeepers, ) upgradetypes.UpgradeHandler { return func(ctx sdk.Context, _ upgradetypes.Plan, fromVM module.VersionMap) (module.VersionMap, error) { before := time.Now() logger := ctx.Logger().With("upgrade", UpgradeName) // fromVM[ibcfeetypes.ModuleName] = mm.Modules[ibcfeetypes.ModuleName].ConsensusVersion() logger.Info(fmt.Sprintf("ibcfee module version %s set", fmt.Sprint(fromVM[ibcfeetypes.ModuleName]))) // Run migrations versionMap, err := mm.RunMigrations(ctx, cfg, fromVM) after := time.Now() ctx.Logger().Info("migration time", "duration_ms", after.Sub(before).Milliseconds()) return versionMap, err } } ================================================ FILE: app/upgrades/v4/constants.go ================================================ package v4 import ( store "github.com/cosmos/cosmos-sdk/store/types" consensustypes "github.com/cosmos/cosmos-sdk/x/consensus/types" crisistypes "github.com/cosmos/cosmos-sdk/x/crisis/types" "github.com/cosmos/cosmos-sdk/x/nft" packetforwardtypes "github.com/cosmos/ibc-apps/middleware/packet-forward-middleware/v7/packetforward/types" icqtypes "github.com/cosmos/ibc-apps/modules/async-icq/v7/types" ibchookstypes "github.com/cosmos/ibc-apps/modules/ibc-hooks/v7/types" icacontrollertypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller/types" icahosttypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/host/types" clocktypes "github.com/cybercongress/go-cyber/v7/x/clock/types" tokenfactorytypes "github.com/cybercongress/go-cyber/v7/x/tokenfactory/types" resourcestypes "github.com/cybercongress/go-cyber/v7/x/resources/types" "github.com/cybercongress/go-cyber/v7/app/upgrades" ) const UpgradeName = "v4" var Upgrade = upgrades.Upgrade{ UpgradeName: UpgradeName, CreateUpgradeHandler: CreateV4UpgradeHandler, StoreUpgrades: store.StoreUpgrades{ Added: []string{ crisistypes.ModuleName, consensustypes.ModuleName, resourcestypes.ModuleName, tokenfactorytypes.ModuleName, nft.ModuleName, clocktypes.ModuleName, icacontrollertypes.StoreKey, icahosttypes.StoreKey, ibchookstypes.StoreKey, icqtypes.ModuleName, packetforwardtypes.StoreKey, }, }, } ================================================ FILE: app/upgrades/v4/upgrades.go ================================================ package v4 import ( "fmt" icqtypes "github.com/cosmos/ibc-apps/modules/async-icq/v7/types" icacontrollertypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller/types" icahosttypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/host/types" "github.com/cosmos/ibc-go/v7/modules/core/exported" generaltypes "github.com/cybercongress/go-cyber/v7/types" clocktypes "github.com/cybercongress/go-cyber/v7/x/clock/types" tokenfactorytypes "github.com/cybercongress/go-cyber/v7/x/tokenfactory/types" "time" liquiditytypes "github.com/cybercongress/go-cyber/v7/x/liquidity/types" "github.com/cosmos/cosmos-sdk/baseapp" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" crisistypes "github.com/cosmos/cosmos-sdk/x/crisis/types" distrtypes "github.com/cosmos/cosmos-sdk/x/distribution/types" govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" govtypesv1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1" minttypes "github.com/cosmos/cosmos-sdk/x/mint/types" paramstypes "github.com/cosmos/cosmos-sdk/x/params/types" slashingtypes "github.com/cosmos/cosmos-sdk/x/slashing/types" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" ibctransfertypes "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" bandwidthtypes "github.com/cybercongress/go-cyber/v7/x/bandwidth/types" dmntypes "github.com/cybercongress/go-cyber/v7/x/dmn/types" gridtypes "github.com/cybercongress/go-cyber/v7/x/grid/types" ranktypes "github.com/cybercongress/go-cyber/v7/x/rank/types" resourcestypes "github.com/cybercongress/go-cyber/v7/x/resources/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" "github.com/cybercongress/go-cyber/v7/app/keepers" ) const NewDenomCreationGasConsume uint64 = 2_000_000 func CreateV4UpgradeHandler( mm *module.Manager, cfg module.Configurator, keepers *keepers.AppKeepers, ) upgradetypes.UpgradeHandler { return func(ctx sdk.Context, _ upgradetypes.Plan, vm module.VersionMap) (module.VersionMap, error) { before := time.Now() logger := ctx.Logger().With("upgrade", UpgradeName) for _, subspace := range keepers.ParamsKeeper.GetSubspaces() { subspace := subspace var keyTable paramstypes.KeyTable switch subspace.Name() { case authtypes.ModuleName: keyTable = authtypes.ParamKeyTable() //nolint:staticcheck case banktypes.ModuleName: keyTable = banktypes.ParamKeyTable() //nolint:staticcheck case stakingtypes.ModuleName: keyTable = stakingtypes.ParamKeyTable() //nolint:staticcheck case minttypes.ModuleName: keyTable = minttypes.ParamKeyTable() //nolint:staticcheck case distrtypes.ModuleName: keyTable = distrtypes.ParamKeyTable() //nolint:staticcheck case slashingtypes.ModuleName: keyTable = slashingtypes.ParamKeyTable() //nolint:staticcheck case govtypes.ModuleName: keyTable = govtypesv1.ParamKeyTable() //nolint:staticcheck case crisistypes.ModuleName: keyTable = crisistypes.ParamKeyTable() //nolint:staticcheck // ibc types case ibctransfertypes.ModuleName: keyTable = ibctransfertypes.ParamKeyTable() case icahosttypes.SubModuleName: keyTable = icahosttypes.ParamKeyTable() case icacontrollertypes.SubModuleName: keyTable = icacontrollertypes.ParamKeyTable() // wasm // commented out because in current version of wasmd there are not ParamKeyTable //case wasmtypes.ModuleName: // keyTable = wasmtypes.ParamKeyTable() //nolint:staticcheck // cyber modules case bandwidthtypes.ModuleName: keyTable = bandwidthtypes.ParamKeyTable() //nolint:staticcheck case dmntypes.ModuleName: keyTable = dmntypes.ParamKeyTable() //nolint:staticcheck case gridtypes.ModuleName: keyTable = gridtypes.ParamKeyTable() //nolint:staticcheck case ranktypes.ModuleName: keyTable = ranktypes.ParamKeyTable() //nolint:staticcheck case resourcestypes.ModuleName: keyTable = resourcestypes.ParamKeyTable() //nolint:staticcheck case liquiditytypes.ModuleName: keyTable = liquiditytypes.ParamKeyTable() //nolint:staticcheck case tokenfactorytypes.ModuleName: keyTable = tokenfactorytypes.ParamKeyTable() //nolint:staticcheck case icqtypes.ModuleName: keyTable = icqtypes.ParamKeyTable() } if !subspace.HasKeyTable() { logger.Info(fmt.Sprintf("set key table for subspace %s", subspace.Name())) subspace.WithKeyTable(keyTable) } } // Migrate Tendermint consensus parameters from x/params module to a deprecated x/consensus module. // The old params module is required to still be imported in your app.go in order to handle this migration. baseAppLegacySS := keepers.ParamsKeeper.Subspace(baseapp.Paramspace).WithKeyTable(paramstypes.ConsensusParamsKeyTable()) baseapp.MigrateParams(ctx, baseAppLegacySS, &keepers.ConsensusParamsKeeper) // Run migrations logger.Info(fmt.Sprintf("pre migrate version map: %v", vm)) versionMap, err := mm.RunMigrations(ctx, cfg, vm) if err != nil { return nil, err } logger.Info(fmt.Sprintf("post migrate version map: %v", versionMap)) after := time.Now() ctx.Logger().Info("migration time", "duration ms", after.Sub(before).Milliseconds()) // TODO check ibc-go state after migration // https://github.com/cosmos/ibc-go/blob/v7.1.0/docs/migrations/v7-to-v7_1.md // explicitly update the IBC 02-client params, adding the localhost client type params := keepers.IBCKeeper.ClientKeeper.GetParams(ctx) params.AllowedClients = append(params.AllowedClients, exported.Localhost) keepers.IBCKeeper.ClientKeeper.SetParams(ctx, params) logger.Info("set ibc client params with localhost") newTokenFactoryParams := tokenfactorytypes.Params{ DenomCreationFee: sdk.NewCoins(sdk.NewCoin(generaltypes.CYB, sdk.NewInt(10*generaltypes.Giga))), DenomCreationGasConsume: NewDenomCreationGasConsume, } if err := keepers.TokenFactoryKeeper.SetParams(ctx, newTokenFactoryParams); err != nil { return nil, err } logger.Info("set tokenfactory params") // x/clock if err := keepers.ClockKeeper.SetParams(ctx, clocktypes.Params{ ContractGasLimit: 20_000_000, }); err != nil { return nil, err } logger.Info("set clock params") keepers.ICAControllerKeeper.SetParams(ctx, icacontrollertypes.DefaultParams()) hostParams := icahosttypes.Params{ HostEnabled: true, AllowMessages: []string{icahosttypes.AllowAllHostMsgs}, } keepers.ICAHostKeeper.SetParams(ctx, hostParams) logger.Info("set interchain accounts host and controller params") // commented out because there are no more SetParams for packet forward module //if err := keepers.PacketForwardKeeper.SetParams(ctx, packetforwardtypes.DefaultParams()); err != nil { // return nil, err //} //logger.Info("set ibc packets forward params") icqParams := icqtypes.DefaultParams() // TODO Fix this, because if enable than all nodes will go to consensus failure on next block //icqParams.AllowQueries = types.GetStargateWhitelistedPaths() if err := keepers.ICQKeeper.SetParams(ctx, icqParams); err != nil { return nil, err } logger.Info("set interchain queries params") bootDenom, exist := keepers.BankKeeper.GetDenomMetaData(ctx, "boot") if exist { bootDenom.DenomUnits = append(bootDenom.DenomUnits, &banktypes.DenomUnit{ Denom: "root", Exponent: 9, Aliases: []string{"ROOT"}, }) keepers.BankKeeper.SetDenomMetaData(ctx, bootDenom) logger.Info("update boot denom metadata with root denom") } after = time.Now() ctx.Logger().Info("upgrade time", "duration ms", after.Sub(before).Milliseconds()) return versionMap, err } } ================================================ FILE: app/upgrades/v5/constants.go ================================================ package v5 import ( "github.com/cybercongress/go-cyber/v7/app/upgrades" ) const ( UpgradeName = "v5" UpgradeHeight = 15_700_805 ) var Fork = upgrades.Fork{ UpgradeName: UpgradeName, UpgradeHeight: UpgradeHeight, BeginForkLogic: RunForkLogic, } ================================================ FILE: app/upgrades/v5/forks.go ================================================ package v5 import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/app/keepers" ) func RunForkLogic(ctx sdk.Context, keepers *keepers.AppKeepers) { logger := ctx.Logger().With("upgrade", UpgradeName) logger.Info("Applying emergency hard fork for v5") liquidityParams := keepers.LiquidityKeeper.GetParams(ctx) liquidityParams.CircuitBreakerEnabled = true err := keepers.LiquidityKeeper.SetParams(ctx, liquidityParams) if err != nil { panic(err) } logger.Info("set liquidity circuit breaker enabled, disable dex") keepers.BankKeeper.SetSendEnabled(ctx, "millivolt", false) keepers.BankKeeper.SetSendEnabled(ctx, "milliampere", false) logger.Info("set bank send disabled for millivolt and amperes") } ================================================ FILE: app/upgrades/v6/burn.go ================================================ package v6 type burnEntry struct { addr string denom string amount string } var hfrBurnEntries = []burnEntry{ {addr: "bostrom1fvh29xlzzatu390p3lpe7uhdsl7dpffcnlxdsq", denom: "milliampere", amount: "26932298723"}, {addr: "bostrom1fvh29xlzzatu390p3lpe7uhdsl7dpffcnlxdsq", denom: "millivolt", amount: "2602715242"}, {addr: "bostrom1vt38jz5g2hrszegvs929y6zp59tgkwlsgjkprq", denom: "milliampere", amount: "2882337639"}, {addr: "bostrom1k09afxhedzgrkn60rrnpa0u66yv3vz7yxj7ja9", denom: "milliampere", amount: "519384871"}, {addr: "bostrom1srklpacfmq889tedn9gpxmlxulcxp3vc6dfxdd", denom: "milliampere", amount: "279939249"}, {addr: "bostrom1nmr4flrrzrka3lanfwxklunsapr92fqq5rfrd3", denom: "milliampere", amount: "1400231678"}, {addr: "bostrom1qkw8dtdansmvayk2jxfkpel9q4d20rvfhwcf4k", denom: "millivolt", amount: "801420796"}, {addr: "bostrom1qkw8dtdansmvayk2jxfkpel9q4d20rvfhwcf4k", denom: "milliampere", amount: "3701530803"}, {addr: "bostrom1fj8d32l98legw3l23ag5gl6ulc64akfrpp8jzw", denom: "milliampere", amount: "1819889604"}, {addr: "bostrom1latgea9pkd8qspxag6am6568h6sgcsywjxskr9", denom: "millivolt", amount: "2262900956"}, {addr: "bostrom1latgea9pkd8qspxag6am6568h6sgcsywjxskr9", denom: "milliampere", amount: "26039233057"}, {addr: "bostrom1f88q956xu3k6lvt8d60u3kj8gkk45nmqzt4h7y", denom: "millivolt", amount: "263762923"}, {addr: "bostrom1qqays2hpyw2zy3qhvvvhp8w953hqc8la9w4u7n", denom: "milliampere", amount: "351433460"}, {addr: "bostrom1qe0mlgcumms5qsvervcpsvwgltc8vl4r234lc5", denom: "millivolt", amount: "919947132573"}, {addr: "bostrom1qkw8dtdansmvayk2jxfkpel9q4d20rvfhwcf4k", denom: "millivolt", amount: "810823925"}, {addr: "bostrom1qkw8dtdansmvayk2jxfkpel9q4d20rvfhwcf4k", denom: "milliampere", amount: "3607499517"}, {addr: "bostrom1ymprf45c44rp9k0g2r84w2tjhsq7kalv98rgpt", denom: "milliampere", amount: "23309976454"}, {addr: "bostrom1ymprf45c44rp9k0g2r84w2tjhsq7kalv98rgpt", denom: "millivolt", amount: "1945783863"}, {addr: "bostrom125uwvkh0je7ug5dsv0pgrquef89k33v0rywexu", denom: "milliampere", amount: "7803967398"}, {addr: "bostrom1k09afxhedzgrkn60rrnpa0u66yv3vz7yxj7ja9", denom: "milliampere", amount: "551211514"}, {addr: "bostrom1k09afxhedzgrkn60rrnpa0u66yv3vz7yxj7ja9", denom: "milliampere", amount: "2726353018"}, {addr: "bostrom1k09afxhedzgrkn60rrnpa0u66yv3vz7yxj7ja9", denom: "millivolt", amount: "508210244"}, {addr: "bostrom1v2rqwg7zvj5rrllgp6wu5h3q8ertfetsngznvy", denom: "milliampere", amount: "10523379733"}, {addr: "bostrom1k09afxhedzgrkn60rrnpa0u66yv3vz7yxj7ja9", denom: "milliampere", amount: "3980209389"}, {addr: "bostrom1zswrrnduv7w3vqqxll2vr2u7u67677egl46k8z", denom: "millivolt", amount: "343855512"}, {addr: "bostrom1qqays2hpyw2zy3qhvvvhp8w953hqc8la9w4u7n", denom: "millivolt", amount: "5341580419"}, {addr: "bostrom1f5warat4vc0q98k7ygys4saka8u04rfxpmthvl", denom: "milliampere", amount: "59911163882"}, {addr: "bostrom1f5warat4vc0q98k7ygys4saka8u04rfxpmthvl", denom: "millivolt", amount: "5121347544"}, {addr: "bostrom1vt38jz5g2hrszegvs929y6zp59tgkwlsgjkprq", denom: "milliampere", amount: "413761980"}, {addr: "bostrom1v2rqwg7zvj5rrllgp6wu5h3q8ertfetsngznvy", denom: "milliampere", amount: "351922703"}, {addr: "bostrom1k09afxhedzgrkn60rrnpa0u66yv3vz7yxj7ja9", denom: "milliampere", amount: "4553479199"}, {addr: "bostrom1jpkh0h7npgp3cq3cy2xt25tus7k7kfey7s8cl0", denom: "milliampere", amount: "275137941"}, {addr: "bostrom1qkw8dtdansmvayk2jxfkpel9q4d20rvfhwcf4k", denom: "millivolt", amount: "788685037"}, {addr: "bostrom1qkw8dtdansmvayk2jxfkpel9q4d20rvfhwcf4k", denom: "milliampere", amount: "3828888401"}, {addr: "bostrom1v2rqwg7zvj5rrllgp6wu5h3q8ertfetsngznvy", denom: "milliampere", amount: "455964649"}, {addr: "bostrom1k09afxhedzgrkn60rrnpa0u66yv3vz7yxj7ja9", denom: "millivolt", amount: "712020894"}, {addr: "bostrom1k09afxhedzgrkn60rrnpa0u66yv3vz7yxj7ja9", denom: "millivolt", amount: "393178603"}, {addr: "bostrom1k09afxhedzgrkn60rrnpa0u66yv3vz7yxj7ja9", denom: "milliampere", amount: "9613298490"}, {addr: "bostrom1v2rqwg7zvj5rrllgp6wu5h3q8ertfetsngznvy", denom: "milliampere", amount: "494072354"}, {addr: "bostrom1vt38jz5g2hrszegvs929y6zp59tgkwlsgjkprq", denom: "millivolt", amount: "288237732"}, {addr: "bostrom1vt38jz5g2hrszegvs929y6zp59tgkwlsgjkprq", denom: "millivolt", amount: "303654781"}, {addr: "bostrom1v2rqwg7zvj5rrllgp6wu5h3q8ertfetsngznvy", denom: "millivolt", amount: "260954257"}, {addr: "bostrom1k09afxhedzgrkn60rrnpa0u66yv3vz7yxj7ja9", denom: "millivolt", amount: "1286096483"}, {addr: "bostrom15dme26c0jv6gcxzed4yc4q8d7rlypev0t0vt5c", denom: "millivolt", amount: "261126476"}, {addr: "bostrom1k09afxhedzgrkn60rrnpa0u66yv3vz7yxj7ja9", denom: "millivolt", amount: "302091183"}, {addr: "bostrom1pxgpxr2xty0r77sfgah9zc3vtatrw56y329n2l", denom: "millivolt", amount: "327958125"}, {addr: "bostrom1vt38jz5g2hrszegvs929y6zp59tgkwlsgjkprq", denom: "milliampere", amount: "413761980"}, {addr: "bostrom15dme26c0jv6gcxzed4yc4q8d7rlypev0t0vt5c", denom: "milliampere", amount: "315286008"}, {addr: "bostrom1k09afxhedzgrkn60rrnpa0u66yv3vz7yxj7ja9", denom: "millivolt", amount: "614199696"}, {addr: "bostrom1vt38jz5g2hrszegvs929y6zp59tgkwlsgjkprq", denom: "millivolt", amount: "303654781"}, {addr: "bostrom1vt38jz5g2hrszegvs929y6zp59tgkwlsgjkprq", denom: "milliampere", amount: "2188331236"}, {addr: "bostrom1v2rqwg7zvj5rrllgp6wu5h3q8ertfetsngznvy", denom: "milliampere", amount: "265056074"}, {addr: "bostrom1k09afxhedzgrkn60rrnpa0u66yv3vz7yxj7ja9", denom: "milliampere", amount: "3076363293"}, {addr: "bostrom15dme26c0jv6gcxzed4yc4q8d7rlypev0t0vt5c", denom: "milliampere", amount: "2601393556"}, {addr: "bostrom15dme26c0jv6gcxzed4yc4q8d7rlypev0t0vt5c", denom: "milliampere", amount: "1509398189"}, {addr: "bostrom1vt38jz5g2hrszegvs929y6zp59tgkwlsgjkprq", denom: "millivolt", amount: "537330942"}, {addr: "bostrom1k09afxhedzgrkn60rrnpa0u66yv3vz7yxj7ja9", denom: "millivolt", amount: "469031783"}, {addr: "bostrom1v2rqwg7zvj5rrllgp6wu5h3q8ertfetsngznvy", denom: "millivolt", amount: "353620879"}, {addr: "bostrom1vt38jz5g2hrszegvs929y6zp59tgkwlsgjkprq", denom: "millivolt", amount: "390355260"}, {addr: "bostrom18zrtny9ghuyy9qhpvgtd0jjped9eujzpcc3lzk", denom: "millivolt", amount: "388804500"}, {addr: "bostrom1v2rqwg7zvj5rrllgp6wu5h3q8ertfetsngznvy", denom: "milliampere", amount: "354330221"}, {addr: "bostrom15dme26c0jv6gcxzed4yc4q8d7rlypev0t0vt5c", denom: "milliampere", amount: "14594313658"}, {addr: "bostrom1qe0mlgcumms5qsvervcpsvwgltc8vl4r234lc5", denom: "milliampere", amount: "152062237261"}, {addr: "bostrom1k09afxhedzgrkn60rrnpa0u66yv3vz7yxj7ja9", denom: "milliampere", amount: "12738135126"}, {addr: "bostrom1k09afxhedzgrkn60rrnpa0u66yv3vz7yxj7ja9", denom: "millivolt", amount: "2231730860"}, {addr: "bostrom1vt38jz5g2hrszegvs929y6zp59tgkwlsgjkprq", denom: "milliampere", amount: "5409149881"}, {addr: "bostrom1vt38jz5g2hrszegvs929y6zp59tgkwlsgjkprq", denom: "millivolt", amount: "545310484"}, {addr: "bostrom1vt38jz5g2hrszegvs929y6zp59tgkwlsgjkprq", denom: "milliampere", amount: "288735209"}, {addr: "bostrom15dme26c0jv6gcxzed4yc4q8d7rlypev0t0vt5c", denom: "milliampere", amount: "771149592"}, {addr: "bostrom14qtapaem0rcj2h9gp5r7q32mq9sh5cs3wlvsn7", denom: "millivolt", amount: "2429029471"}, {addr: "bostrom1qe0mlgcumms5qsvervcpsvwgltc8vl4r234lc5", denom: "millivolt", amount: "818108814658"}, {addr: "bostrom1qe0mlgcumms5qsvervcpsvwgltc8vl4r234lc5", denom: "millivolt", amount: "7128428104"}, {addr: "bostrom1fty3ql39e7m4gy98z0jv68vdst0wksy932vxku", denom: "millivolt", amount: "2085965578"}, {addr: "bostrom1ngymhfhty76w8r6e8dlyvj68g5zfm09qjmejts", denom: "millivolt", amount: "2370208604"}, {addr: "bostrom1ngymhfhty76w8r6e8dlyvj68g5zfm09qjmejts", denom: "milliampere", amount: "24649814272"}, {addr: "bostrom1a3nm66sw7ejp454azqem2d88g5m7lc6dwf9tsa", denom: "millivolt", amount: "1511899342"}, {addr: "bostrom1a3nm66sw7ejp454azqem2d88g5m7lc6dwf9tsa", denom: "millivolt", amount: "726616669"}, {addr: "bostrom1a3nm66sw7ejp454azqem2d88g5m7lc6dwf9tsa", denom: "millivolt", amount: "596926589"}, {addr: "bostrom1a3nm66sw7ejp454azqem2d88g5m7lc6dwf9tsa", denom: "millivolt", amount: "524364059"}, {addr: "bostrom1a3nm66sw7ejp454azqem2d88g5m7lc6dwf9tsa", denom: "milliampere", amount: "3387538353"}, {addr: "bostrom1a3nm66sw7ejp454azqem2d88g5m7lc6dwf9tsa", denom: "milliampere", amount: "2539415149"}, {addr: "bostrom1a3nm66sw7ejp454azqem2d88g5m7lc6dwf9tsa", denom: "milliampere", amount: "2877122095"}, {addr: "bostrom1vt38jz5g2hrszegvs929y6zp59tgkwlsgjkprq", denom: "millivolt", amount: "6823201994"}, {addr: "bostrom15dme26c0jv6gcxzed4yc4q8d7rlypev0t0vt5c", denom: "milliampere", amount: "18783348485"}, {addr: "bostrom1gvy4vk6v2rzpd9my487l358uajec8n0vn5c9us", denom: "milliampere", amount: "55387606103"}, {addr: "bostrom1gvy4vk6v2rzpd9my487l358uajec8n0vn5c9us", denom: "millivolt", amount: "8690051483"}, {addr: "bostrom10r6r8crpu0c8t4cumlpcp6uzc8ngut3j09flpy", denom: "milliampere", amount: "43311697895"}, {addr: "bostrom10r6r8crpu0c8t4cumlpcp6uzc8ngut3j09flpy", denom: "millivolt", amount: "7033800128"}, {addr: "bostrom10r6r8crpu0c8t4cumlpcp6uzc8ngut3j09flpy", denom: "milliampere", amount: "8821722561"}, {addr: "bostrom1tkz3uvmgglns04c524quqx26aunj3h0k00q68f", denom: "milliampere", amount: "267406320"}, {addr: "bostrom1k09afxhedzgrkn60rrnpa0u66yv3vz7yxj7ja9", denom: "millivolt", amount: "2774293087"}, {addr: "bostrom1vt38jz5g2hrszegvs929y6zp59tgkwlsgjkprq", denom: "milliampere", amount: "5400859561"}, {addr: "bostrom1c5g8xw3dfcxypw65j7aa4j29hetr4wy48acpcx", denom: "milliampere", amount: "12662635612"}, {addr: "bostrom15dme26c0jv6gcxzed4yc4q8d7rlypev0t0vt5c", denom: "milliampere", amount: "18797239514"}, {addr: "bostrom15dme26c0jv6gcxzed4yc4q8d7rlypev0t0vt5c", denom: "milliampere", amount: "11070841292"}, {addr: "bostrom1ggda2n35v7zkwucufzp25mp34p0adp0x0w7wgc", denom: "millivolt", amount: "432000000"}, {addr: "bostrom1ggda2n35v7zkwucufzp25mp34p0adp0x0w7wgc", denom: "milliampere", amount: "4320000000"}, {addr: "bostrom1k09afxhedzgrkn60rrnpa0u66yv3vz7yxj7ja9", denom: "millivolt", amount: "1397957106"}, {addr: "bostrom1ay267fakkrgfy9lf2m7wsj8uez2dgylhtkdf9k", denom: "milliampere", amount: "11162598095"}, {addr: "bostrom1qqays2hpyw2zy3qhvvvhp8w953hqc8la9w4u7n", denom: "milliampere", amount: "18749017000"}, {addr: "bostrom135ca8hdpy9sk0ntwqzpzsvatyl48ptx5j359lz", denom: "millivolt", amount: "229080000000"}, {addr: "bostrom12k2pyuylm9t7ugdvz67h9pg4gmmvhn5vu43p0n", denom: "millivolt", amount: "5146755828"}, {addr: "bostrom15dme26c0jv6gcxzed4yc4q8d7rlypev0t0vt5c", denom: "millivolt", amount: "2132585268"}, {addr: "bostrom12k2pyuylm9t7ugdvz67h9pg4gmmvhn5vu43p0n", denom: "milliampere", amount: "33988579640"}, } var dexBurnEntries = []burnEntry{ {addr: "bostrom10xu73c3nkcdcf6j6u4j2kzq0cjftfj2nv7xz9y", denom: "milliampere", amount: "37724907920"}, {addr: "bostrom1u3u628ue3c5hn7ya4x4cjlk5t2d0unnarrq34k", denom: "millivolt", amount: "3431620200"}, {addr: "bostrom1y7au5el59mf8mlak53gfvmr75gr2m2jz6lra0s", denom: "milliampere", amount: "7756244360"}, {addr: "bostrom1rfyjzaqpt2aywpnvs456la6c9323nqyysaf7zg", denom: "millivolt", amount: "520683170"}, //{addr: "bostrom1jphne3xq7335qvvepkupwcda8yyfp79ggfx7hy", denom: "milliampere", amount: "2120351490"}, //{addr: "bostrom1jphne3xq7335qvvepkupwcda8yyfp79ggfx7hy", denom: "millivolt", amount: "144935100"}, } ================================================ FILE: app/upgrades/v6/constants.go ================================================ package v6 import ( store "github.com/cosmos/cosmos-sdk/store/types" "github.com/cybercongress/go-cyber/v7/app/upgrades" ) const UpgradeName = "v6" var Upgrade = upgrades.Upgrade{ UpgradeName: UpgradeName, CreateUpgradeHandler: CreateV6UpgradeHandler, StoreUpgrades: store.StoreUpgrades{ Added: []string{}, }, } ================================================ FILE: app/upgrades/v6/upgrades.go ================================================ package v6 import ( "fmt" "time" sdkmath "cosmossdk.io/math" liquiditytypes "github.com/cybercongress/go-cyber/v7/x/liquidity/types" bandwidthtypes "github.com/cybercongress/go-cyber/v7/x/bandwidth/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" vestingtypes "github.com/cosmos/cosmos-sdk/x/auth/vesting/types" upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" "github.com/cybercongress/go-cyber/v7/app/keepers" resourcestypes "github.com/cybercongress/go-cyber/v7/x/resources/types" ) func CreateV6UpgradeHandler( mm *module.Manager, cfg module.Configurator, keepers *keepers.AppKeepers, ) upgradetypes.UpgradeHandler { return func(ctx sdk.Context, _ upgradetypes.Plan, vm module.VersionMap) (module.VersionMap, error) { before := time.Now() logger := ctx.Logger().With("upgrade", UpgradeName) liquidityParams := keepers.LiquidityKeeper.GetParams(ctx) liquidityParams.CircuitBreakerEnabled = false err := keepers.LiquidityKeeper.SetParams(ctx, liquidityParams) if err != nil { panic(err) } logger.Info("set liquidity circuit breaker disabled, enable dex") keepers.BankKeeper.SetSendEnabled(ctx, "millivolt", true) keepers.BankKeeper.SetSendEnabled(ctx, "milliampere", true) logger.Info("set bank send enabled for millivolt and amperes") logger.Info(fmt.Sprintf("pre migrate version map: %v", vm)) versionMap, err := mm.RunMigrations(ctx, cfg, vm) if err != nil { return nil, err } logger.Info(fmt.Sprintf("post migrate version map: %v", versionMap)) after := time.Now() ctx.Logger().Info("upgrade time", "duration ms", after.Sub(before).Milliseconds()) voltSupply := keepers.BankKeeper.GetSupply(ctx, "millivolt") ampereSupply := keepers.BankKeeper.GetSupply(ctx, "milliampere") resourcesSupplyBefore := sdk.NewCoins(voltSupply, ampereSupply) bootSupply := keepers.BankKeeper.GetSupply(ctx, "boot") hydrogenSupply := keepers.BankKeeper.GetSupply(ctx, "hydrogen") tocybSupply := keepers.BankKeeper.GetSupply(ctx, "tocyb") baseSupplyBefore := sdk.NewCoins(bootSupply, hydrogenSupply, tocybSupply) before = time.Now() // -- burn unvested coins for accounts with periodic vesting accounts // -- delete unvested future vesting periods, set end time to current block time updatedVestingAccounts := 0 totalUnvestedBurned := sdk.NewCoins() for _, acc := range keepers.AccountKeeper.GetAllAccounts(ctx) { switch v := acc.(type) { case *vestingtypes.PeriodicVestingAccount: // compute unvested (still vesting) coins at upgrade time before any conversion unvested := v.GetVestingCoins(ctx.BlockTime()) // Trim all not-yet-finished periods so remaining schedule contains only fully completed periods. // Also set EndTime to current block time and align OriginalVesting with kept periods. if unvested.IsAllPositive() { elapsed := ctx.BlockTime().Unix() - v.StartTime if elapsed < 0 { elapsed = 0 } cumLength := int64(0) keptPeriods := vestingtypes.Periods{} keptOriginal := sdk.NewCoins() for _, p := range v.VestingPeriods { cumLength += p.Length if cumLength <= elapsed { keptPeriods = append(keptPeriods, p) keptOriginal = keptOriginal.Add(p.Amount...) } else { break } } v.VestingPeriods = keptPeriods v.OriginalVesting = keptOriginal v.EndTime = v.StartTime + cumLength // or ctx.BlockTime().Unix() keepers.AccountKeeper.SetAccount(ctx, v) updatedVestingAccounts++ // After unlocking, burn the unvested resources, limited by available balances. addr := acc.GetAddress() balances := keepers.BankKeeper.GetAllBalances(ctx, addr) coinsToBurn := sdk.NewCoins() for _, c := range unvested { if c.Denom == "millivolt" || c.Denom == "milliampere" { balAmt := balances.AmountOf(c.Denom) if balAmt.IsPositive() { amt := sdk.MinInt(c.Amount, balAmt) if amt.IsPositive() { coinsToBurn = coinsToBurn.Add(sdk.NewCoin(c.Denom, amt)) } } } } if coinsToBurn.IsAllPositive() { if err := keepers.BankKeeper.SendCoinsFromAccountToModule(ctx, addr, resourcestypes.ResourcesName, coinsToBurn); err != nil { logger.Error("failed to move coins for burning", "addr", addr.String(), "coins", coinsToBurn.String(), "err", err) } else { if err := keepers.BankKeeper.BurnCoins(ctx, resourcestypes.ResourcesName, coinsToBurn); err != nil { logger.Error("failed to burn coins", "addr", addr.String(), "coins", coinsToBurn.String(), "err", err) } else { totalUnvestedBurned = totalUnvestedBurned.Add(coinsToBurn...) //logger.Info("unvested and burned coins", "addr", addr.String(), "coins", coinsToBurn) } } } } } } logger.Info("vesting cleanup completed", "accounts updated", updatedVestingAccounts, "total unvested burned", totalUnvestedBurned.String()) // manually burn minted coins for accounts which made investmints during HFR break explosionBurned := sdk.NewCoins() processedHFREntries := 0 for _, e := range hfrBurnEntries { addr, err := sdk.AccAddressFromBech32(e.addr) if err != nil { logger.Error("invalid address", "addr", e.addr, "err", err) continue } amt, ok := sdk.NewIntFromString(e.amount) if !ok || !amt.IsPositive() { continue } balanceAmt := keepers.BankKeeper.GetBalance(ctx, addr, e.denom).Amount toBurnAmt := sdk.MinInt(balanceAmt, amt) if !toBurnAmt.IsPositive() { processedHFREntries++ logger.Info("nothing to burn", "addr", addr.String(), "denom", e.denom, "amount", e.amount, "balance", balanceAmt.String()) continue } coin := sdk.NewCoin(e.denom, toBurnAmt) if err := keepers.BankKeeper.SendCoinsFromAccountToModule(ctx, addr, resourcestypes.ResourcesName, sdk.NewCoins(coin)); err != nil { logger.Error("failed to move coins for burning", "addr", addr.String(), "coin", coin.String(), "err", err) continue } if err := keepers.BankKeeper.BurnCoins(ctx, resourcestypes.ResourcesName, sdk.NewCoins(coin)); err != nil { logger.Error("failed to burn coins", "addr", addr.String(), "coin", coin.String(), "err", err) continue } explosionBurned = explosionBurned.Add(coin) processedHFREntries++ } logger.Info("exploded HFR recovery completed", "entries processed", processedHFREntries, "total explosion burned", explosionBurned.String()) // manually burn coins from dex pool accounts during HFR break dexBurned := sdk.NewCoins() processedDEXEntries := 0 for _, e := range dexBurnEntries { addr, err := sdk.AccAddressFromBech32(e.addr) if err != nil { logger.Error("invalid address", "addr", e.addr, "err", err) continue } toBurnAmt, ok := sdk.NewIntFromString(e.amount) if !ok || !toBurnAmt.IsPositive() { continue } coin := sdk.NewCoin(e.denom, toBurnAmt) if err := keepers.BankKeeper.SendCoinsFromAccountToModule(ctx, addr, resourcestypes.ResourcesName, sdk.NewCoins(coin)); err != nil { logger.Error("failed to move coins for burning", "addr", addr.String(), "coin", coin.String(), "err", err) continue } if err := keepers.BankKeeper.BurnCoins(ctx, resourcestypes.ResourcesName, sdk.NewCoins(coin)); err != nil { logger.Error("failed to burn coins", "addr", addr.String(), "coin", coin.String(), "err", err) continue } dexBurned = dexBurned.Add(coin) processedDEXEntries++ } logger.Info("exploited DEX recovery completed", "entries processed", processedDEXEntries, "total dex burned", dexBurned.String()) after = time.Now() logger.Info("balances fixed", "duration ms", after.Sub(before).Milliseconds()) totalBurned := totalUnvestedBurned.Add(explosionBurned...).Add(dexBurned...) voltSupply = keepers.BankKeeper.GetSupply(ctx, "millivolt") ampereSupply = keepers.BankKeeper.GetSupply(ctx, "milliampere") resourcesSupplyAfter := sdk.NewCoins(voltSupply, ampereSupply) logger.Info("resources supply", "before", resourcesSupplyBefore.String(), "after", resourcesSupplyAfter.String(), "total burned", totalBurned.String()) before = time.Now() for _, acc := range keepers.AccountKeeper.GetAllAccounts(ctx) { keepers.BandwidthMeter.SetZeroAccountBandwidth(ctx, acc.GetAddress()) } logger.Info("set zero bandwidth for all accounts", "duration ms", after.Sub(before).Milliseconds()) params := keepers.BandwidthMeter.GetParams(ctx) err = keepers.BandwidthMeter.SetParams(ctx, bandwidthtypes.Params{ BasePrice: sdk.OneDec(), RecoveryPeriod: params.RecoveryPeriod, AdjustPricePeriod: params.AdjustPricePeriod, BaseLoad: params.BaseLoad, MaxBlockBandwidth: params.MaxBlockBandwidth, }) if err != nil { return nil, err } after = time.Now() millivoltSupply := keepers.BankKeeper.GetSupply(ctx, "millivolt") keepers.BandwidthMeter.SetDesirableBandwidth(ctx, millivoltSupply.Amount.Uint64()) giftBoots := sdk.NewCoin("boot", sdkmath.NewInt(603000000000000)) giftTocybs := sdk.NewCoin("tocyb", sdkmath.NewInt(603000000000000)) giftCoins := sdk.NewCoins(giftBoots, giftTocybs) giftMSAddress, _ := sdk.AccAddressFromBech32("bostrom1qs9w7ry45axfxjgxa4jmuhjthzfvj78sxh5p6e") if err := keepers.BankKeeper.SendCoinsFromAccountToModule(ctx, giftMSAddress, liquiditytypes.ModuleName, giftCoins); err != nil { logger.Error("failed to move gift coins for burning", "addr", giftMSAddress.String(), "coin", giftCoins.String(), "err", err) } if err := keepers.BankKeeper.BurnCoins(ctx, liquiditytypes.ModuleName, giftCoins); err != nil { logger.Error("failed to burn gift coins", "addr", giftMSAddress.String(), "coin", giftCoins.String(), "err", err) } ctx.Logger().Info("burned gift tokens from multisig", "amount", giftCoins.String()) // Adjust congress boots burn amount to available balance (burn all existing if less than target) congressBootsTarget := sdk.NewCoin("boot", sdkmath.NewInt(136963281024834)) congressTocybs := sdk.NewCoin("tocyb", sdkmath.NewInt(115594467532355)) congressMSAddress, _ := sdk.AccAddressFromBech32("bostrom1xszmhkfjs3s00z2nvtn7evqxw3dtus6yr8e4pw") congressBootBalance := keepers.BankKeeper.GetBalance(ctx, congressMSAddress, "boot").Amount congressBootBurnAmt := sdk.MinInt(congressBootsTarget.Amount, congressBootBalance) congressCoinsToBurn := sdk.NewCoins(congressTocybs) if congressBootBurnAmt.IsPositive() { congressCoinsToBurn = congressCoinsToBurn.Add(sdk.NewCoin("boot", congressBootBurnAmt)) } if congressCoinsToBurn.IsAllPositive() { if err := keepers.BankKeeper.SendCoinsFromAccountToModule(ctx, congressMSAddress, liquiditytypes.ModuleName, congressCoinsToBurn); err != nil { logger.Error("failed to move congress coins for burning", "addr", congressMSAddress.String(), "coin", congressCoinsToBurn.String(), "err", err) } else { if err := keepers.BankKeeper.BurnCoins(ctx, liquiditytypes.ModuleName, congressCoinsToBurn); err != nil { logger.Error("failed to burn congress coins", "addr", congressMSAddress.String(), "coin", congressCoinsToBurn.String(), "err", err) } else { ctx.Logger().Info("burned congress tokens from multisig", "amount", congressCoinsToBurn.String()) } } } else { logger.Info("nothing to burn for congress multisig", "addr", congressMSAddress.String()) } // Adjust gift treasury boots burn amount to available balance (burn all existing if less than target) giftTreasuryBootTarget := sdk.NewInt(58648526573806) giftTreasuryAddress, _ := sdk.AccAddressFromBech32("bostrom182jzjwdyl5fw43yujnlljddgtrkr04dpd30ywp2yn724u7qhtaqstjzlcu") giftTreasuryBootBalance := keepers.BankKeeper.GetBalance(ctx, giftTreasuryAddress, "boot").Amount giftTreasuryBootBurnAmt := sdk.MinInt(giftTreasuryBootTarget, giftTreasuryBootBalance) if giftTreasuryBootBurnAmt.IsPositive() { giftTreasuryBurnCoin := sdk.NewCoin("boot", giftTreasuryBootBurnAmt) if err := keepers.BankKeeper.SendCoinsFromAccountToModule(ctx, giftTreasuryAddress, liquiditytypes.ModuleName, sdk.NewCoins(giftTreasuryBurnCoin)); err != nil { logger.Error("failed to move gift treasury coins for burning", "addr", giftTreasuryAddress.String(), "coin", giftTreasuryBurnCoin.String(), "err", err) } else { if err := keepers.BankKeeper.BurnCoins(ctx, liquiditytypes.ModuleName, sdk.NewCoins(giftTreasuryBurnCoin)); err != nil { logger.Error("failed to burn gift treasury coins", "addr", giftTreasuryAddress.String(), "coin", giftTreasuryBurnCoin.String(), "err", err) } else { ctx.Logger().Info("burned gift tokens from treasury", "amount", giftTreasuryBurnCoin.String()) } } } else { logger.Info("nothing to burn for gift treasury", "addr", giftTreasuryAddress.String()) } bootSupply = keepers.BankKeeper.GetSupply(ctx, "boot") hydrogenSupply = keepers.BankKeeper.GetSupply(ctx, "hydrogen") tocybSupply = keepers.BankKeeper.GetSupply(ctx, "tocyb") baseSupplyAfter := sdk.NewCoins(bootSupply, hydrogenSupply, tocybSupply) logger.Info("base supply", "before", baseSupplyBefore.String(), "after", baseSupplyAfter.String()) return versionMap, err } } ================================================ FILE: app/upgrades/v7/constants.go ================================================ package v7 import ( store "github.com/cosmos/cosmos-sdk/store/types" "github.com/cybercongress/go-cyber/v7/app/upgrades" ) const UpgradeName = "v7" var Upgrade = upgrades.Upgrade{ UpgradeName: UpgradeName, CreateUpgradeHandler: CreateV7UpgradeHandler, StoreUpgrades: store.StoreUpgrades{ Added: []string{}, }, } ================================================ FILE: app/upgrades/v7/upgrades.go ================================================ package v7 import ( "fmt" "time" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" "github.com/cybercongress/go-cyber/v7/app/keepers" ) func CreateV7UpgradeHandler( mm *module.Manager, cfg module.Configurator, keepers *keepers.AppKeepers, ) upgradetypes.UpgradeHandler { return func(ctx sdk.Context, _ upgradetypes.Plan, vm module.VersionMap) (module.VersionMap, error) { before := time.Now() logger := ctx.Logger().With("upgrade", UpgradeName) logger.Info(fmt.Sprintf("pre migrate version map: %v", vm)) versionMap, err := mm.RunMigrations(ctx, cfg, vm) if err != nil { return nil, err } logger.Info(fmt.Sprintf("post migrate version map: %v", versionMap)) rankParams := keepers.RankKeeper.GetParams(ctx) rankParams.CalculationPeriod = 10 err = keepers.RankKeeper.SetParams(ctx, rankParams) if err != nil { return nil, err } cidCount := keepers.GraphKeeper.GetCidsCount(ctx) keepers.RankKeeper.SetDebugMerkleTrees(ctx, cidCount) after := time.Now() ctx.Logger().Info("upgrade time", "duration ms", after.Sub(before).Milliseconds()) return versionMap, err } } ================================================ FILE: buf.work.yaml ================================================ # Generated by "buf config migrate-v1beta1". Edit as necessary, and # remove this comment when you're finished. # # This workspace file points to the roots found in your # previous "buf.yaml" configuration. version: v1 directories: - proto ================================================ FILE: client/docs/docs.go ================================================ package docs import ( "embed" httptemplate "html/template" "net/http" "github.com/gorilla/mux" ) const ( apiFile = "/static/openapi.yml" indexFile = "template/index.tpl" ) //go:embed static var Static embed.FS //go:embed template var template embed.FS func RegisterOpenAPIService(appName string, rtr *mux.Router) { rtr.Handle(apiFile, http.FileServer(http.FS(Static))) rtr.HandleFunc("/", handler(appName)) } // handler returns an http handler that servers OpenAPI console for an OpenAPI spec at specURL. func handler(title string) http.HandlerFunc { t, _ := httptemplate.ParseFS(template, indexFile) return func(w http.ResponseWriter, req *http.Request) { t.Execute(w, struct { Title string URL string }{ title, apiFile, }) } } ================================================ FILE: client/docs/static/openapi.yml ================================================ openapi: 3.0.0 info: title: Bostrom network version: v4 paths: /cosmos/consensus/v1/params: get: summary: Params queries the parameters of x/consensus_param module. operationId: Params_TZPQY responses: "200": description: A successful response. content: application/json: schema: type: object properties: params: description: >- params are the tendermint consensus params stored in the consensus module. Please note that `params.version` is not populated in this response, it is tracked separately in the x/upgrade module. type: object properties: block: type: object properties: max_bytes: type: string format: int64 title: |- Max block size, in bytes. Note: must be greater than 0 max_gas: type: string format: int64 title: |- Max gas per block. Note: must be greater or equal to -1 description: BlockParams contains limits on the block size. evidence: type: object properties: max_age_num_blocks: type: string format: int64 description: >- Max age of evidence, in blocks. The basic formula for calculating this is: MaxAgeDuration / {average block time}. max_age_duration: type: string description: >- Max age of evidence, in time. It should correspond with an app's "unbonding period" or other similar mechanism for handling [Nothing-At-Stake attacks](https://github.com/ethereum/wiki/wiki/Proof-of-Stake-FAQ#what-is-the-nothing-at-stake-problem-and-how-can-it-be-fixed). max_bytes: type: string format: int64 title: >- This sets the maximum size of total evidence in bytes that can be committed in a single block. and should fall comfortably under the max block bytes. Default is 1048576 or 1MB description: EvidenceParams determine how we handle evidence of malfeasance. validator: type: object properties: pub_key_types: type: array items: type: string description: >- ValidatorParams restrict the public key types validators can use. NOTE: uses ABCI pubkey naming, not Amino names. version: type: object properties: app: type: string format: uint64 description: VersionParams contains the ABCI application version. description: QueryParamsResponse defines the response type for querying x/consensus parameters. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API "/cosmos/feegrant/v1beta1/allowance/{granter}/{grantee}": get: summary: Allowance returns fee granted to the grantee by the granter. operationId: Allowance_WUEKP responses: "200": description: A successful response. content: application/json: schema: type: object properties: allowance: description: allowance is a allowance granted for grantee by granter. type: object properties: granter: type: string description: granter is the address of the user granting an allowance of their funds. grantee: type: string description: grantee is the address of the user being granted an allowance of another user's funds. allowance: type: object properties: type_url: type: string value: type: string format: byte description: allowance can be any of basic, periodic, allowed fee allowance. title: Grant is stored in the KVStore to record a grant with full context description: QueryAllowanceResponse is the response type for the Query/Allowance RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: granter description: granter is the address of the user granting an allowance of their funds. in: path required: true schema: type: string - name: grantee description: grantee is the address of the user being granted an allowance of another user's funds. in: path required: true schema: type: string tags: - gRPC Gateway API "/cosmos/feegrant/v1beta1/allowances/{grantee}": get: summary: Allowances returns all the grants for address. operationId: Allowances_2SCGA responses: "200": description: A successful response. content: application/json: schema: type: object properties: allowances: type: array items: type: object properties: granter: type: string description: granter is the address of the user granting an allowance of their funds. grantee: type: string description: grantee is the address of the user being granted an allowance of another user's funds. allowance: type: object properties: type_url: type: string value: type: string format: byte description: allowance can be any of basic, periodic, allowed fee allowance. title: Grant is stored in the KVStore to record a grant with full context description: allowances are allowance's granted for grantee by granter. pagination: description: pagination defines an pagination for the response. type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: QueryAllowancesResponse is the response type for the Query/Allowances RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: grantee in: path required: true schema: type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/cosmos/feegrant/v1beta1/issued/{granter}": get: summary: AllowancesByGranter returns all the grants given by an address description: "Since: cosmos-sdk 0.46" operationId: AllowancesByGranter_H5OXI responses: "200": description: A successful response. content: application/json: schema: type: object properties: allowances: type: array items: type: object properties: granter: type: string description: granter is the address of the user granting an allowance of their funds. grantee: type: string description: grantee is the address of the user being granted an allowance of another user's funds. allowance: type: object properties: type_url: type: string value: type: string format: byte description: allowance can be any of basic, periodic, allowed fee allowance. title: Grant is stored in the KVStore to record a grant with full context description: allowances that have been issued by the granter. pagination: description: pagination defines an pagination for the response. type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- QueryAllowancesByGranterResponse is the response type for the Query/AllowancesByGranter RPC method. Since: cosmos-sdk 0.46 default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: granter in: path required: true schema: type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/cosmos/gov/v1/params/{params_type}": get: summary: Params queries all parameters of the gov module. operationId: Params_RTRPI responses: "200": description: A successful response. content: application/json: schema: type: object properties: voting_params: description: |- Deprecated: Prefer to use `params` instead. voting_params defines the parameters related to voting. type: object properties: voting_period: type: string description: Duration of the voting period. deposit_params: description: |- Deprecated: Prefer to use `params` instead. deposit_params defines the parameters related to deposit. type: object properties: min_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: Minimum deposit for a proposal to enter voting period. max_deposit_period: type: string description: >- Maximum period for Atom holders to deposit on a proposal. Initial value: 2 months. tally_params: description: |- Deprecated: Prefer to use `params` instead. tally_params defines the parameters related to tally. type: object properties: quorum: type: string description: >- Minimum percentage of total stake needed to vote for a result to be considered valid. threshold: type: string description: "Minimum proportion of Yes votes for proposal to pass. Default value: 0.5." veto_threshold: type: string description: >- Minimum value of Veto votes to Total votes ratio for proposal to be vetoed. Default value: 1/3. params: description: |- params defines all the paramaters of x/gov module. Since: cosmos-sdk 0.47 type: object properties: min_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: Minimum deposit for a proposal to enter voting period. max_deposit_period: type: string description: >- Maximum period for Atom holders to deposit on a proposal. Initial value: 2 months. voting_period: type: string description: Duration of the voting period. quorum: type: string description: >- Minimum percentage of total stake needed to vote for a result to be considered valid. threshold: type: string description: "Minimum proportion of Yes votes for proposal to pass. Default value: 0.5." veto_threshold: type: string description: >- Minimum value of Veto votes to Total votes ratio for proposal to be vetoed. Default value: 1/3. min_initial_deposit_ratio: type: string description: The ratio representing the proportion of the deposit value that must be paid at proposal submission. burn_vote_quorum: type: boolean title: burn deposits if a proposal does not meet quorum burn_proposal_deposit_prevote: type: boolean title: burn deposits if the proposal does not enter voting period burn_vote_veto: type: boolean title: burn deposits if quorum with vote type no_veto is met description: QueryParamsResponse is the response type for the Query/Params RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: params_type description: >- params_type defines which parameters to query for, can be one of "voting", "tallying" or "deposit". in: path required: true schema: type: string tags: - gRPC Gateway API /cosmos/gov/v1/proposals: get: summary: Proposals queries all proposals based on given status. operationId: Proposals_MNCBG responses: "200": description: A successful response. content: application/json: schema: type: object properties: proposals: type: array items: type: object properties: id: type: string format: uint64 description: id defines the unique id of the proposal. messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: messages are the arbitrary messages to be executed if the proposal passes. status: description: status defines the proposal status. type: string enum: - PROPOSAL_STATUS_UNSPECIFIED - PROPOSAL_STATUS_DEPOSIT_PERIOD - PROPOSAL_STATUS_VOTING_PERIOD - PROPOSAL_STATUS_PASSED - PROPOSAL_STATUS_REJECTED - PROPOSAL_STATUS_FAILED default: PROPOSAL_STATUS_UNSPECIFIED final_tally_result: description: >- final_tally_result is the final tally result of the proposal. When querying a proposal via gRPC, this field is not populated until the proposal's voting period has ended. type: object properties: yes_count: type: string description: yes_count is the number of yes votes on a proposal. abstain_count: type: string description: abstain_count is the number of abstain votes on a proposal. no_count: type: string description: no_count is the number of no votes on a proposal. no_with_veto_count: type: string description: no_with_veto_count is the number of no with veto votes on a proposal. submit_time: type: string format: date-time description: submit_time is the time of proposal submission. deposit_end_time: type: string format: date-time description: deposit_end_time is the end time for deposition. total_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: total_deposit is the total deposit on the proposal. voting_start_time: type: string format: date-time description: voting_start_time is the starting time to vote on a proposal. voting_end_time: type: string format: date-time description: voting_end_time is the end time of voting on a proposal. metadata: type: string description: metadata is any arbitrary metadata attached to the proposal. title: type: string description: "Since: cosmos-sdk 0.47" title: title is the title of the proposal summary: type: string description: "Since: cosmos-sdk 0.47" title: summary is a short summary of the proposal proposer: type: string description: "Since: cosmos-sdk 0.47" title: Proposer is the address of the proposal sumbitter description: Proposal defines the core field members of a governance proposal. description: proposals defines all the requested governance proposals. pagination: description: pagination defines the pagination in the response. type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- QueryProposalsResponse is the response type for the Query/Proposals RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: proposal_status description: >- proposal_status defines the status of the proposals. - PROPOSAL_STATUS_UNSPECIFIED: PROPOSAL_STATUS_UNSPECIFIED defines the default proposal status. - PROPOSAL_STATUS_DEPOSIT_PERIOD: PROPOSAL_STATUS_DEPOSIT_PERIOD defines a proposal status during the deposit period. - PROPOSAL_STATUS_VOTING_PERIOD: PROPOSAL_STATUS_VOTING_PERIOD defines a proposal status during the voting period. - PROPOSAL_STATUS_PASSED: PROPOSAL_STATUS_PASSED defines a proposal status of a proposal that has passed. - PROPOSAL_STATUS_REJECTED: PROPOSAL_STATUS_REJECTED defines a proposal status of a proposal that has been rejected. - PROPOSAL_STATUS_FAILED: PROPOSAL_STATUS_FAILED defines a proposal status of a proposal that has failed. in: query required: false schema: type: string enum: - PROPOSAL_STATUS_UNSPECIFIED - PROPOSAL_STATUS_DEPOSIT_PERIOD - PROPOSAL_STATUS_VOTING_PERIOD - PROPOSAL_STATUS_PASSED - PROPOSAL_STATUS_REJECTED - PROPOSAL_STATUS_FAILED default: PROPOSAL_STATUS_UNSPECIFIED - name: voter description: voter defines the voter address for the proposals. in: query required: false schema: type: string - name: depositor description: depositor defines the deposit addresses from the proposals. in: query required: false schema: type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/cosmos/gov/v1/proposals/{proposal_id}": get: summary: Proposal queries proposal details based on ProposalID. operationId: Proposal_M3ACP responses: "200": description: A successful response. content: application/json: schema: type: object properties: proposal: type: object properties: id: type: string format: uint64 description: id defines the unique id of the proposal. messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: messages are the arbitrary messages to be executed if the proposal passes. status: description: status defines the proposal status. type: string enum: - PROPOSAL_STATUS_UNSPECIFIED - PROPOSAL_STATUS_DEPOSIT_PERIOD - PROPOSAL_STATUS_VOTING_PERIOD - PROPOSAL_STATUS_PASSED - PROPOSAL_STATUS_REJECTED - PROPOSAL_STATUS_FAILED default: PROPOSAL_STATUS_UNSPECIFIED final_tally_result: description: >- final_tally_result is the final tally result of the proposal. When querying a proposal via gRPC, this field is not populated until the proposal's voting period has ended. type: object properties: yes_count: type: string description: yes_count is the number of yes votes on a proposal. abstain_count: type: string description: abstain_count is the number of abstain votes on a proposal. no_count: type: string description: no_count is the number of no votes on a proposal. no_with_veto_count: type: string description: no_with_veto_count is the number of no with veto votes on a proposal. submit_time: type: string format: date-time description: submit_time is the time of proposal submission. deposit_end_time: type: string format: date-time description: deposit_end_time is the end time for deposition. total_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: total_deposit is the total deposit on the proposal. voting_start_time: type: string format: date-time description: voting_start_time is the starting time to vote on a proposal. voting_end_time: type: string format: date-time description: voting_end_time is the end time of voting on a proposal. metadata: type: string description: metadata is any arbitrary metadata attached to the proposal. title: type: string description: "Since: cosmos-sdk 0.47" title: title is the title of the proposal summary: type: string description: "Since: cosmos-sdk 0.47" title: summary is a short summary of the proposal proposer: type: string description: "Since: cosmos-sdk 0.47" title: Proposer is the address of the proposal sumbitter description: Proposal defines the core field members of a governance proposal. description: QueryProposalResponse is the response type for the Query/Proposal RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: proposal_id description: proposal_id defines the unique id of the proposal. in: path required: true schema: type: string format: uint64 tags: - gRPC Gateway API "/cosmos/gov/v1/proposals/{proposal_id}/deposits": get: summary: Deposits queries all deposits of a single proposal. operationId: Deposits_1TZ1V responses: "200": description: A successful response. content: application/json: schema: type: object properties: deposits: type: array items: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. depositor: type: string description: depositor defines the deposit addresses from the proposals. amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: amount to be deposited by depositor. description: >- Deposit defines an amount deposited by an account address to an active proposal. description: deposits defines the requested deposits. pagination: description: pagination defines the pagination in the response. type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: QueryDepositsResponse is the response type for the Query/Deposits RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: proposal_id description: proposal_id defines the unique id of the proposal. in: path required: true schema: type: string format: uint64 - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/cosmos/gov/v1/proposals/{proposal_id}/deposits/{depositor}": get: summary: Deposit queries single deposit information based proposalID, depositAddr. operationId: Deposit_2YBCE responses: "200": description: A successful response. content: application/json: schema: type: object properties: deposit: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. depositor: type: string description: depositor defines the deposit addresses from the proposals. amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: amount to be deposited by depositor. description: >- Deposit defines an amount deposited by an account address to an active proposal. description: QueryDepositResponse is the response type for the Query/Deposit RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: proposal_id description: proposal_id defines the unique id of the proposal. in: path required: true schema: type: string format: uint64 - name: depositor description: depositor defines the deposit addresses from the proposals. in: path required: true schema: type: string tags: - gRPC Gateway API "/cosmos/gov/v1/proposals/{proposal_id}/tally": get: summary: TallyResult queries the tally of a proposal vote. operationId: TallyResult_HD9CX responses: "200": description: A successful response. content: application/json: schema: type: object properties: tally: description: tally defines the requested tally. type: object properties: yes_count: type: string description: yes_count is the number of yes votes on a proposal. abstain_count: type: string description: abstain_count is the number of abstain votes on a proposal. no_count: type: string description: no_count is the number of no votes on a proposal. no_with_veto_count: type: string description: no_with_veto_count is the number of no with veto votes on a proposal. description: QueryTallyResultResponse is the response type for the Query/Tally RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: proposal_id description: proposal_id defines the unique id of the proposal. in: path required: true schema: type: string format: uint64 tags: - gRPC Gateway API "/cosmos/gov/v1/proposals/{proposal_id}/votes": get: summary: Votes queries votes of a given proposal. operationId: Votes_AG3U7 responses: "200": description: A successful response. content: application/json: schema: type: object properties: votes: type: array items: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. voter: type: string description: voter is the voter address of the proposal. options: type: array items: type: object properties: option: description: option defines the valid vote options, it must not contain duplicate vote options. type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED weight: type: string description: weight is the vote weight associated with the vote option. description: WeightedVoteOption defines a unit of vote for vote split. description: options is the weighted vote options. metadata: type: string description: metadata is any arbitrary metadata to attached to the vote. description: >- Vote defines a vote on a governance proposal. A Vote consists of a proposal ID, the voter, and the vote option. description: votes defines the queried votes. pagination: description: pagination defines the pagination in the response. type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: QueryVotesResponse is the response type for the Query/Votes RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: proposal_id description: proposal_id defines the unique id of the proposal. in: path required: true schema: type: string format: uint64 - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/cosmos/gov/v1/proposals/{proposal_id}/votes/{voter}": get: summary: Vote queries voted information based on proposalID, voterAddr. operationId: Vote_CJIO5 responses: "200": description: A successful response. content: application/json: schema: type: object properties: vote: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. voter: type: string description: voter is the voter address of the proposal. options: type: array items: type: object properties: option: description: option defines the valid vote options, it must not contain duplicate vote options. type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED weight: type: string description: weight is the vote weight associated with the vote option. description: WeightedVoteOption defines a unit of vote for vote split. description: options is the weighted vote options. metadata: type: string description: metadata is any arbitrary metadata to attached to the vote. description: >- Vote defines a vote on a governance proposal. A Vote consists of a proposal ID, the voter, and the vote option. description: QueryVoteResponse is the response type for the Query/Vote RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: proposal_id description: proposal_id defines the unique id of the proposal. in: path required: true schema: type: string format: uint64 - name: voter description: voter defines the voter address for the proposals. in: path required: true schema: type: string tags: - gRPC Gateway API /cyber/graph/v1beta1/graph_stats: get: operationId: GraphStats_EIHOL responses: "200": description: A successful response. content: application/json: schema: type: object properties: cyberlinks: type: string format: uint64 particles: type: string format: uint64 default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cyber/resources/v1beta1/resources/investmint: get: operationId: Investmint_GWKUV responses: "200": description: A successful response. content: application/json: schema: type: object properties: amount: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: amount.denom in: query required: false schema: type: string - name: amount.amount in: query required: false schema: type: string - name: resource in: query required: false schema: type: string - name: length in: query required: false schema: type: string format: uint64 tags: - gRPC Gateway API /cyber/resources/v1beta1/resources/params: get: operationId: Params_KCXBY responses: "200": description: A successful response. content: application/json: schema: type: object properties: params: type: object properties: max_slots: type: integer format: int64 halving_period_volt_blocks: type: integer format: int64 halving_period_ampere_blocks: type: integer format: int64 base_investmint_period_volt: type: integer format: int64 base_investmint_period_ampere: type: integer format: int64 min_investmint_period: type: integer format: int64 base_investmint_amount_volt: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. base_investmint_amount_ampere: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/base/node/v1beta1/config: get: summary: Config queries for the operator configuration. operationId: Config_CWIZ3 responses: "200": description: A successful response. content: application/json: schema: type: object properties: minimum_gas_price: type: string description: ConfigResponse defines the response structure for the Config gRPC query. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API "/cosmos/upgrade/v1beta1/applied_plan/{name}": get: summary: AppliedPlan queries a previously applied upgrade plan by its name. operationId: AppliedPlan_UVH49 responses: "200": description: A successful response. content: application/json: schema: type: object properties: height: type: string format: int64 description: height is the block height at which the plan was applied. description: >- QueryAppliedPlanResponse is the response type for the Query/AppliedPlan RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: name description: name is the name of the applied plan to query for. in: path required: true schema: type: string tags: - gRPC Gateway API /cosmos/upgrade/v1beta1/authority: get: summary: Returns the account with authority to conduct upgrades description: "Since: cosmos-sdk 0.46" operationId: Authority_2NU82 responses: "200": description: A successful response. content: application/json: schema: type: object properties: address: type: string description: "Since: cosmos-sdk 0.46" title: QueryAuthorityResponse is the response type for Query/Authority default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/upgrade/v1beta1/current_plan: get: summary: CurrentPlan queries the current upgrade plan. operationId: CurrentPlan_YGRDZ responses: "200": description: A successful response. content: application/json: schema: type: object properties: plan: description: plan is the current upgrade plan. type: object properties: name: type: string description: >- Sets the name for the upgrade. This name will be used by the upgraded version of the software to apply any special "on-upgrade" commands during the first BeginBlock method after the upgrade is applied. It is also used to detect whether a software version can handle a given upgrade. If no upgrade handler with this name has been set in the software, it will be assumed that the software is out-of-date when the upgrade Time or Height is reached and the software will exit. time: type: string format: date-time description: >- Deprecated: Time based upgrades have been deprecated. Time based upgrade logic has been removed from the SDK. If this field is not empty, an error will be thrown. height: type: string format: int64 description: The height at which the upgrade must be performed. info: type: string title: >- Any application specific upgrade info to be included on-chain such as a git commit that validators could automatically upgrade to upgraded_client_state: type: object properties: type_url: type: string value: type: string format: byte description: >- Deprecated: UpgradedClientState field has been deprecated. IBC upgrade logic has been moved to the IBC module in the sub module 02-client. If this field is not empty, an error will be thrown. description: >- QueryCurrentPlanResponse is the response type for the Query/CurrentPlan RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/upgrade/v1beta1/module_versions: get: summary: ModuleVersions queries the list of module versions from state. description: "Since: cosmos-sdk 0.43" operationId: ModuleVersions_7VRES responses: "200": description: A successful response. content: application/json: schema: type: object properties: module_versions: type: array items: type: object properties: name: type: string title: name of the app module version: type: string format: uint64 title: consensus version of the app module description: >- ModuleVersion specifies a module and its consensus version. Since: cosmos-sdk 0.43 description: module_versions is a list of module names with their consensus versions. description: >- QueryModuleVersionsResponse is the response type for the Query/ModuleVersions RPC method. Since: cosmos-sdk 0.43 default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: module_name description: |- module_name is a field to query a specific module consensus version from state. Leaving this empty will fetch the full list of module versions from state. in: query required: false schema: type: string tags: - gRPC Gateway API "/cosmos/upgrade/v1beta1/upgraded_consensus_state/{last_height}": get: summary: >- UpgradedConsensusState queries the consensus state that will serve as a trusted kernel for the next version of this chain. It will only be stored at the last height of this chain. UpgradedConsensusState RPC not supported with legacy querier This rpc is deprecated now that IBC has its own replacement (https://github.com/cosmos/ibc-go/blob/2c880a22e9f9cc75f62b527ca94aa75ce1106001/proto/ibc/core/client/v1/query.proto#L54) operationId: UpgradedConsensusState_DG71K responses: "200": description: A successful response. content: application/json: schema: type: object properties: upgraded_consensus_state: type: string format: byte title: "Since: cosmos-sdk 0.43" description: >- QueryUpgradedConsensusStateResponse is the response type for the Query/UpgradedConsensusState RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: last_height description: |- last height of the current chain must be sent in request as this is the height under which next consensus state is stored in: path required: true schema: type: string format: int64 tags: - gRPC Gateway API "/ibc/apps/fee/v1/channels/{channel_id}/ports/{port_id}/fee_enabled": get: summary: FeeEnabledChannel returns true if the provided port and channel identifiers belong to a fee enabled channel operationId: FeeEnabledChannel_840O1 responses: "200": description: A successful response. content: application/json: schema: type: object properties: fee_enabled: type: boolean title: boolean flag representing the fee enabled channel status title: QueryFeeEnabledChannelResponse defines the response type for the FeeEnabledChannel rpc default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: channel_id description: unique channel identifier in: path required: true schema: type: string - name: port_id description: unique port identifier in: path required: true schema: type: string tags: - gRPC Gateway API "/ibc/apps/fee/v1/channels/{channel_id}/ports/{port_id}/incentivized_packets": get: summary: Gets all incentivized packets for a specific channel operationId: IncentivizedPacketsForChannel_YZC9B responses: "200": description: A successful response. content: application/json: schema: type: object properties: incentivized_packets: type: array items: type: object properties: packet_id: title: unique packet identifier comprised of the channel ID, port ID and sequence type: object properties: port_id: type: string title: channel port identifier channel_id: type: string title: channel unique identifier sequence: type: string format: uint64 title: packet sequence packet_fees: type: array items: type: object properties: fee: title: fee encapsulates the recv, ack and timeout fees associated with an IBC packet type: object properties: recv_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet receive fee ack_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet acknowledgement fee timeout_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet timeout fee refund_address: type: string title: the refund address for unspent fees relayers: type: array items: type: string title: optional list of relayers permitted to receive fees title: PacketFee contains ICS29 relayer fees, refund address and optional list of permitted relayers title: list of packet fees title: IdentifiedPacketFees contains a list of type PacketFee and associated PacketId title: Map of all incentivized_packets title: QueryIncentivizedPacketsResponse defines the response type for the incentivized packets RPC default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: channel_id in: path required: true schema: type: string - name: port_id in: path required: true schema: type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean - name: query_height description: Height to query at. in: query required: false schema: type: string format: uint64 tags: - gRPC Gateway API "/ibc/apps/fee/v1/channels/{channel_id}/relayers/{relayer}/counterparty_payee": get: summary: CounterpartyPayee returns the registered counterparty payee for forward relaying operationId: CounterpartyPayee_OX3D8 responses: "200": description: A successful response. content: application/json: schema: type: object properties: counterparty_payee: type: string title: the counterparty payee address used to compensate forward relaying title: QueryCounterpartyPayeeResponse defines the response type for the CounterpartyPayee rpc default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: channel_id description: unique channel identifier in: path required: true schema: type: string - name: relayer description: the relayer address to which the counterparty is registered in: path required: true schema: type: string tags: - gRPC Gateway API "/ibc/apps/fee/v1/channels/{channel_id}/relayers/{relayer}/payee": get: summary: Payee returns the registered payee address for a specific channel given the relayer address operationId: Payee_Y340V responses: "200": description: A successful response. content: application/json: schema: type: object properties: payee_address: type: string title: the payee address to which packet fees are paid out title: QueryPayeeResponse defines the response type for the Payee rpc default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: channel_id description: unique channel identifier in: path required: true schema: type: string - name: relayer description: the relayer address to which the distribution address is registered in: path required: true schema: type: string tags: - gRPC Gateway API "/ibc/apps/fee/v1/channels/{packet_id.channel_id}/ports/{packet_id.port_id}/sequences/{packet_id.sequence}/incentivized_packet": get: summary: IncentivizedPacket returns all packet fees for a packet given its identifier operationId: IncentivizedPacket_FYWES responses: "200": description: A successful response. content: application/json: schema: type: object properties: incentivized_packet: type: object properties: packet_id: title: unique packet identifier comprised of the channel ID, port ID and sequence type: object properties: port_id: type: string title: channel port identifier channel_id: type: string title: channel unique identifier sequence: type: string format: uint64 title: packet sequence packet_fees: type: array items: type: object properties: fee: title: fee encapsulates the recv, ack and timeout fees associated with an IBC packet type: object properties: recv_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet receive fee ack_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet acknowledgement fee timeout_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet timeout fee refund_address: type: string title: the refund address for unspent fees relayers: type: array items: type: string title: optional list of relayers permitted to receive fees title: PacketFee contains ICS29 relayer fees, refund address and optional list of permitted relayers title: list of packet fees title: IdentifiedPacketFees contains a list of type PacketFee and associated PacketId title: QueryIncentivizedPacketsResponse defines the response type for the IncentivizedPacket rpc default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: packet_id.channel_id description: channel unique identifier in: path required: true schema: type: string - name: packet_id.port_id description: channel port identifier in: path required: true schema: type: string - name: packet_id.sequence description: packet sequence in: path required: true schema: type: string format: uint64 - name: query_height description: block height at which to query. in: query required: false schema: type: string format: uint64 tags: - gRPC Gateway API "/ibc/apps/fee/v1/channels/{packet_id.channel_id}/ports/{packet_id.port_id}/sequences/{packet_id.sequence}/total_ack_fees": get: summary: TotalAckFees returns the total acknowledgement fees for a packet given its identifier operationId: TotalAckFees_SFS3U responses: "200": description: A successful response. content: application/json: schema: type: object properties: ack_fees: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the total packet acknowledgement fees title: QueryTotalAckFeesResponse defines the response type for the TotalAckFees rpc default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: packet_id.channel_id description: channel unique identifier in: path required: true schema: type: string - name: packet_id.port_id description: channel port identifier in: path required: true schema: type: string - name: packet_id.sequence description: packet sequence in: path required: true schema: type: string format: uint64 tags: - gRPC Gateway API "/ibc/apps/fee/v1/channels/{packet_id.channel_id}/ports/{packet_id.port_id}/sequences/{packet_id.sequence}/total_recv_fees": get: summary: TotalRecvFees returns the total receive fees for a packet given its identifier operationId: TotalRecvFees_8W02H responses: "200": description: A successful response. content: application/json: schema: type: object properties: recv_fees: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the total packet receive fees title: QueryTotalRecvFeesResponse defines the response type for the TotalRecvFees rpc default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: packet_id.channel_id description: channel unique identifier in: path required: true schema: type: string - name: packet_id.port_id description: channel port identifier in: path required: true schema: type: string - name: packet_id.sequence description: packet sequence in: path required: true schema: type: string format: uint64 tags: - gRPC Gateway API "/ibc/apps/fee/v1/channels/{packet_id.channel_id}/ports/{packet_id.port_id}/sequences/{packet_id.sequence}/total_timeout_fees": get: summary: TotalTimeoutFees returns the total timeout fees for a packet given its identifier operationId: TotalTimeoutFees_FQFYL responses: "200": description: A successful response. content: application/json: schema: type: object properties: timeout_fees: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the total packet timeout fees title: QueryTotalTimeoutFeesResponse defines the response type for the TotalTimeoutFees rpc default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: packet_id.channel_id description: channel unique identifier in: path required: true schema: type: string - name: packet_id.port_id description: channel port identifier in: path required: true schema: type: string - name: packet_id.sequence description: packet sequence in: path required: true schema: type: string format: uint64 tags: - gRPC Gateway API /ibc/apps/fee/v1/fee_enabled: get: summary: FeeEnabledChannels returns a list of all fee enabled channels operationId: FeeEnabledChannels_00UHI responses: "200": description: A successful response. content: application/json: schema: type: object properties: fee_enabled_channels: type: array items: type: object properties: port_id: type: string title: unique port identifier channel_id: type: string title: unique channel identifier title: FeeEnabledChannel contains the PortID & ChannelID for a fee enabled channel title: list of fee enabled channels title: QueryFeeEnabledChannelsResponse defines the response type for the FeeEnabledChannels rpc default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean - name: query_height description: block height at which to query. in: query required: false schema: type: string format: uint64 tags: - gRPC Gateway API /ibc/apps/fee/v1/incentivized_packets: get: summary: IncentivizedPackets returns all incentivized packets and their associated fees operationId: IncentivizedPackets_0KHDP responses: "200": description: A successful response. content: application/json: schema: type: object properties: incentivized_packets: type: array items: type: object properties: packet_id: title: unique packet identifier comprised of the channel ID, port ID and sequence type: object properties: port_id: type: string title: channel port identifier channel_id: type: string title: channel unique identifier sequence: type: string format: uint64 title: packet sequence packet_fees: type: array items: type: object properties: fee: title: fee encapsulates the recv, ack and timeout fees associated with an IBC packet type: object properties: recv_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet receive fee ack_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet acknowledgement fee timeout_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet timeout fee refund_address: type: string title: the refund address for unspent fees relayers: type: array items: type: string title: optional list of relayers permitted to receive fees title: PacketFee contains ICS29 relayer fees, refund address and optional list of permitted relayers title: list of packet fees title: IdentifiedPacketFees contains a list of type PacketFee and associated PacketId title: list of identified fees for incentivized packets title: QueryIncentivizedPacketsResponse defines the response type for the IncentivizedPackets rpc default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean - name: query_height description: block height at which to query. in: query required: false schema: type: string format: uint64 tags: - gRPC Gateway API /cosmos/params/v1beta1/params: get: summary: |- Params queries a specific parameter of a module, given its subspace and key. operationId: Params_VQK7H responses: "200": description: A successful response. content: application/json: schema: type: object properties: param: description: param defines the queried parameter. type: object properties: subspace: type: string key: type: string value: type: string description: QueryParamsResponse is response type for the Query/Params RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: subspace description: subspace defines the module to query the parameter for. in: query required: false schema: type: string - name: key description: key defines the key of the parameter in the subspace. in: query required: false schema: type: string tags: - gRPC Gateway API /cosmos/params/v1beta1/subspaces: get: summary: Subspaces queries for all registered subspaces and all keys for a subspace. description: "Since: cosmos-sdk 0.46" operationId: Subspaces_7GKEQ responses: "200": description: A successful response. content: application/json: schema: type: object properties: subspaces: type: array items: type: object properties: subspace: type: string keys: type: array items: type: string description: >- Subspace defines a parameter subspace name and all the keys that exist for the subspace. Since: cosmos-sdk 0.46 description: >- QuerySubspacesResponse defines the response types for querying for all registered subspaces and all keys for a subspace. Since: cosmos-sdk 0.46 default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cyber/rank/v1beta1/is_any_link_exist: get: operationId: IsAnyLinkExist_2JCAZ responses: "200": description: A successful response. content: application/json: schema: type: object properties: exist: type: boolean default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: from in: query required: false schema: type: string - name: to in: query required: false schema: type: string tags: - gRPC Gateway API /cyber/rank/v1beta1/is_link_exist: get: operationId: IsLinkExist_T429K responses: "200": description: A successful response. content: application/json: schema: type: object properties: exist: type: boolean default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: from in: query required: false schema: type: string - name: to in: query required: false schema: type: string - name: address in: query required: false schema: type: string tags: - gRPC Gateway API "/cyber/rank/v1beta1/karma/{neuron}": get: operationId: Karma_OCY17 responses: "200": description: A successful response. content: application/json: schema: type: object properties: karma: type: string format: uint64 default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: neuron in: path required: true schema: type: string tags: - gRPC Gateway API /cyber/rank/v1beta1/negentropy: get: operationId: Negentropy_I4QNT responses: "200": description: A successful response. content: application/json: schema: type: object properties: negentropy: type: string format: uint64 default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API "/cyber/rank/v1beta1/negentropy/{particle}": get: operationId: ParticleNegentropy_9E5ES responses: "200": description: A successful response. content: application/json: schema: type: object properties: entropy: type: string format: uint64 default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: particle in: path required: true schema: type: string tags: - gRPC Gateway API "/cyber/rank/v1beta1/rank/backlinks/{particle}": get: operationId: Backlinks_00QZQ responses: "200": description: A successful response. content: application/json: schema: type: object properties: result: type: array items: type: object properties: particle: type: string rank: type: string format: uint64 pagination: type: object properties: total: type: integer format: int64 default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: particle in: path required: true schema: type: string - name: pagination.page in: query required: false schema: type: integer format: int64 - name: pagination.per_page in: query required: false schema: type: integer format: int64 tags: - gRPC Gateway API /cyber/rank/v1beta1/rank/params: get: operationId: Params_L259G responses: "200": description: A successful response. content: application/json: schema: type: object properties: params: type: object properties: calculation_period: type: string format: int64 damping_factor: type: string tolerance: type: string default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API "/cyber/rank/v1beta1/rank/rank/{particle}": get: operationId: Rank_U75Y2 responses: "200": description: A successful response. content: application/json: schema: type: object properties: rank: type: string format: uint64 default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: particle in: path required: true schema: type: string tags: - gRPC Gateway API "/cyber/rank/v1beta1/rank/search/{particle}": get: operationId: Search_W3CZ3 responses: "200": description: A successful response. content: application/json: schema: type: object properties: result: type: array items: type: object properties: particle: type: string rank: type: string format: uint64 pagination: type: object properties: total: type: integer format: int64 default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: particle in: path required: true schema: type: string - name: pagination.page in: query required: false schema: type: integer format: int64 - name: pagination.per_page in: query required: false schema: type: integer format: int64 tags: - gRPC Gateway API /cyber/rank/v1beta1/rank/top: get: operationId: Top_M5Z8S responses: "200": description: A successful response. content: application/json: schema: type: object properties: result: type: array items: type: object properties: particle: type: string rank: type: string format: uint64 pagination: type: object properties: total: type: integer format: int64 default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pagination.page in: query required: false schema: type: integer format: int64 - name: pagination.per_page in: query required: false schema: type: integer format: int64 tags: - gRPC Gateway API /cosmos/distribution/v1beta1/community_pool: get: summary: CommunityPool queries the community pool coins. operationId: CommunityPool_0US6E responses: "200": description: A successful response. content: application/json: schema: type: object properties: pool: type: array items: type: object properties: denom: type: string amount: type: string description: >- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. description: pool defines community pool's coins. description: >- QueryCommunityPoolResponse is the response type for the Query/CommunityPool RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API "/cosmos/distribution/v1beta1/delegators/{delegator_address}/rewards": get: summary: |- DelegationTotalRewards queries the total rewards accrued by a each validator. operationId: DelegationTotalRewards_WYSIY responses: "200": description: A successful response. content: application/json: schema: type: object properties: rewards: type: array items: type: object properties: validator_address: type: string reward: type: array items: type: object properties: denom: type: string amount: type: string description: >- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. description: |- DelegationDelegatorReward represents the properties of a delegator's delegation reward. description: rewards defines all the rewards accrued by a delegator. total: type: array items: type: object properties: denom: type: string amount: type: string description: >- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. description: total defines the sum of all the rewards. description: >- QueryDelegationTotalRewardsResponse is the response type for the Query/DelegationTotalRewards RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: delegator_address description: delegator_address defines the delegator address to query for. in: path required: true schema: type: string tags: - gRPC Gateway API "/cosmos/distribution/v1beta1/delegators/{delegator_address}/rewards/{validator_address}": get: summary: DelegationRewards queries the total rewards accrued by a delegation. operationId: DelegationRewards_AZKQ1 responses: "200": description: A successful response. content: application/json: schema: type: object properties: rewards: type: array items: type: object properties: denom: type: string amount: type: string description: >- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. description: rewards defines the rewards accrued by a delegation. description: |- QueryDelegationRewardsResponse is the response type for the Query/DelegationRewards RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: delegator_address description: delegator_address defines the delegator address to query for. in: path required: true schema: type: string - name: validator_address description: validator_address defines the validator address to query for. in: path required: true schema: type: string tags: - gRPC Gateway API "/cosmos/distribution/v1beta1/delegators/{delegator_address}/validators": get: summary: DelegatorValidators queries the validators of a delegator. operationId: DelegatorValidators_86WPX responses: "200": description: A successful response. content: application/json: schema: type: object properties: validators: type: array items: type: string description: validators defines the validators a delegator is delegating for. description: |- QueryDelegatorValidatorsResponse is the response type for the Query/DelegatorValidators RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: delegator_address description: delegator_address defines the delegator address to query for. in: path required: true schema: type: string tags: - gRPC Gateway API "/cosmos/distribution/v1beta1/delegators/{delegator_address}/withdraw_address": get: summary: DelegatorWithdrawAddress queries withdraw address of a delegator. operationId: DelegatorWithdrawAddress_YB7EI responses: "200": description: A successful response. content: application/json: schema: type: object properties: withdraw_address: type: string description: withdraw_address defines the delegator address to query for. description: >- QueryDelegatorWithdrawAddressResponse is the response type for the Query/DelegatorWithdrawAddress RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: delegator_address description: delegator_address defines the delegator address to query for. in: path required: true schema: type: string tags: - gRPC Gateway API /cosmos/distribution/v1beta1/params: get: summary: Params queries params of the distribution module. operationId: Params_T3DPP responses: "200": description: A successful response. content: application/json: schema: type: object properties: params: description: params defines the parameters of the module. type: object properties: community_tax: type: string base_proposer_reward: type: string description: >- Deprecated: The base_proposer_reward field is deprecated and is no longer used in the x/distribution module's reward mechanism. bonus_proposer_reward: type: string description: >- Deprecated: The bonus_proposer_reward field is deprecated and is no longer used in the x/distribution module's reward mechanism. withdraw_addr_enabled: type: boolean description: QueryParamsResponse is the response type for the Query/Params RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API "/cosmos/distribution/v1beta1/validators/{validator_address}": get: summary: ValidatorDistributionInfo queries validator commission and self-delegation rewards for validator operationId: ValidatorDistributionInfo_FWO9U responses: "200": description: A successful response. content: application/json: schema: type: object properties: operator_address: type: string description: operator_address defines the validator operator address. self_bond_rewards: type: array items: type: object properties: denom: type: string amount: type: string description: >- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. description: self_bond_rewards defines the self delegations rewards. commission: type: array items: type: object properties: denom: type: string amount: type: string description: >- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. description: commission defines the commission the validator received. description: QueryValidatorDistributionInfoResponse is the response type for the Query/ValidatorDistributionInfo RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: validator_address description: validator_address defines the validator address to query for. in: path required: true schema: type: string tags: - gRPC Gateway API "/cosmos/distribution/v1beta1/validators/{validator_address}/commission": get: summary: ValidatorCommission queries accumulated commission for a validator. operationId: ValidatorCommission_BK3UA responses: "200": description: A successful response. content: application/json: schema: type: object properties: commission: description: commission defines the commission the validator received. type: object properties: commission: type: array items: type: object properties: denom: type: string amount: type: string description: >- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. title: |- QueryValidatorCommissionResponse is the response type for the Query/ValidatorCommission RPC method default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: validator_address description: validator_address defines the validator address to query for. in: path required: true schema: type: string tags: - gRPC Gateway API "/cosmos/distribution/v1beta1/validators/{validator_address}/outstanding_rewards": get: summary: ValidatorOutstandingRewards queries rewards of a validator address. operationId: ValidatorOutstandingRewards_GBZ1A responses: "200": description: A successful response. content: application/json: schema: type: object properties: rewards: type: object properties: rewards: type: array items: type: object properties: denom: type: string amount: type: string description: >- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. description: >- ValidatorOutstandingRewards represents outstanding (un-withdrawn) rewards for a validator inexpensive to track, allows simple sanity checks. description: >- QueryValidatorOutstandingRewardsResponse is the response type for the Query/ValidatorOutstandingRewards RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: validator_address description: validator_address defines the validator address to query for. in: path required: true schema: type: string tags: - gRPC Gateway API "/cosmos/distribution/v1beta1/validators/{validator_address}/slashes": get: summary: ValidatorSlashes queries slash events of a validator. operationId: ValidatorSlashes_ZIX0V responses: "200": description: A successful response. content: application/json: schema: type: object properties: slashes: type: array items: type: object properties: validator_period: type: string format: uint64 fraction: type: string description: >- ValidatorSlashEvent represents a validator slash event. Height is implicit within the store key. This is needed to calculate appropriate amount of staking tokens for delegations which are withdrawn after a slash has occurred. description: slashes defines the slashes the validator received. pagination: description: pagination defines the pagination in the response. type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- QueryValidatorSlashesResponse is the response type for the Query/ValidatorSlashes RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: validator_address description: validator_address defines the validator address to query for. in: path required: true schema: type: string - name: starting_height description: starting_height defines the optional starting height to query the slashes. in: query required: false schema: type: string format: uint64 - name: ending_height description: starting_height defines the optional ending height to query the slashes. in: query required: false schema: type: string format: uint64 - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/cosmos/bank/v1beta1/balances/{address}": get: summary: AllBalances queries the balance of all coins for a single account. description: >- When called from another module, this query might consume a high amount of gas if the pagination field is incorrectly set. operationId: AllBalances_SB2JJ responses: "200": description: A successful response. content: application/json: schema: type: object properties: balances: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: balances is the balances of all the coins. pagination: description: pagination defines the pagination in the response. type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- QueryAllBalancesResponse is the response type for the Query/AllBalances RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: address description: address is the address to query balances for. in: path required: true schema: type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/cosmos/bank/v1beta1/balances/{address}/by_denom": get: summary: Balance queries the balance of a single coin for a single account. operationId: Balance_3DIWH responses: "200": description: A successful response. content: application/json: schema: type: object properties: balance: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: QueryBalanceResponse is the response type for the Query/Balance RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: address description: address is the address to query balances for. in: path required: true schema: type: string - name: denom description: denom is the coin denom to query balances for. in: query required: false schema: type: string tags: - gRPC Gateway API "/cosmos/bank/v1beta1/denom_owners/{denom}": get: summary: >- DenomOwners queries for all account addresses that own a particular token denomination. description: >- When called from another module, this query might consume a high amount of gas if the pagination field is incorrectly set. Since: cosmos-sdk 0.46 operationId: DenomOwners_MVQ6C responses: "200": description: A successful response. content: application/json: schema: type: object properties: denom_owners: type: array items: type: object properties: address: type: string description: address defines the address that owns a particular denomination. balance: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- DenomOwner defines structure representing an account that owns or holds a particular denominated token. It contains the account address and account balance of the denominated token. Since: cosmos-sdk 0.46 pagination: description: pagination defines the pagination in the response. type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- QueryDenomOwnersResponse defines the RPC response of a DenomOwners RPC query. Since: cosmos-sdk 0.46 default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: denom description: denom defines the coin denomination to query all account holders for. in: path required: true schema: type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API /cosmos/bank/v1beta1/denoms_metadata: get: summary: |- DenomsMetadata queries the client metadata for all registered coin denominations. operationId: DenomsMetadata_1QGQ2 responses: "200": description: A successful response. content: application/json: schema: type: object properties: metadatas: type: array items: type: object properties: description: type: string denom_units: type: array items: type: object properties: denom: type: string description: denom represents the string name of the given denom unit (e.g uatom). exponent: type: integer format: int64 description: >- exponent represents power of 10 exponent that one must raise the base_denom to in order to equal the given DenomUnit's denom 1 denom = 10^exponent base_denom (e.g. with a base_denom of uatom, one can create a DenomUnit of 'atom' with exponent = 6, thus: 1 atom = 10^6 uatom). aliases: type: array items: type: string title: aliases is a list of string aliases for the given denom description: >- DenomUnit represents a struct that describes a given denomination unit of the basic token. title: denom_units represents the list of DenomUnit's for a given coin base: type: string description: base represents the base denom (should be the DenomUnit with exponent = 0). display: type: string description: |- display indicates the suggested denom that should be displayed in clients. name: type: string description: "Since: cosmos-sdk 0.43" title: "name defines the name of the token (eg: Cosmos Atom)" symbol: type: string description: >- symbol is the token symbol usually shown on exchanges (eg: ATOM). This can be the same as the display. Since: cosmos-sdk 0.43 uri: type: string description: >- URI to a document (on or off-chain) that contains additional information. Optional. Since: cosmos-sdk 0.46 uri_hash: type: string description: >- URIHash is a sha256 hash of a document pointed by URI. It's used to verify that the document didn't change. Optional. Since: cosmos-sdk 0.46 description: |- Metadata represents a struct that describes a basic token. description: metadata provides the client information for all the registered tokens. pagination: description: pagination defines the pagination in the response. type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- QueryDenomsMetadataResponse is the response type for the Query/DenomsMetadata RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/cosmos/bank/v1beta1/denoms_metadata/{denom}": get: summary: DenomsMetadata queries the client metadata of a given coin denomination. operationId: DenomMetadata_IWNXK responses: "200": description: A successful response. content: application/json: schema: type: object properties: metadata: type: object properties: description: type: string denom_units: type: array items: type: object properties: denom: type: string description: denom represents the string name of the given denom unit (e.g uatom). exponent: type: integer format: int64 description: >- exponent represents power of 10 exponent that one must raise the base_denom to in order to equal the given DenomUnit's denom 1 denom = 10^exponent base_denom (e.g. with a base_denom of uatom, one can create a DenomUnit of 'atom' with exponent = 6, thus: 1 atom = 10^6 uatom). aliases: type: array items: type: string title: aliases is a list of string aliases for the given denom description: |- DenomUnit represents a struct that describes a given denomination unit of the basic token. title: denom_units represents the list of DenomUnit's for a given coin base: type: string description: base represents the base denom (should be the DenomUnit with exponent = 0). display: type: string description: |- display indicates the suggested denom that should be displayed in clients. name: type: string description: "Since: cosmos-sdk 0.43" title: "name defines the name of the token (eg: Cosmos Atom)" symbol: type: string description: >- symbol is the token symbol usually shown on exchanges (eg: ATOM). This can be the same as the display. Since: cosmos-sdk 0.43 uri: type: string description: >- URI to a document (on or off-chain) that contains additional information. Optional. Since: cosmos-sdk 0.46 uri_hash: type: string description: >- URIHash is a sha256 hash of a document pointed by URI. It's used to verify that the document didn't change. Optional. Since: cosmos-sdk 0.46 description: |- Metadata represents a struct that describes a basic token. description: >- QueryDenomMetadataResponse is the response type for the Query/DenomMetadata RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: denom description: denom is the coin denom to query the metadata for. in: path required: true schema: type: string tags: - gRPC Gateway API /cosmos/bank/v1beta1/params: get: summary: Params queries the parameters of x/bank module. operationId: Params_UPITY responses: "200": description: A successful response. content: application/json: schema: type: object properties: params: type: object properties: send_enabled: type: array items: type: object properties: denom: type: string enabled: type: boolean description: >- SendEnabled maps coin denom to a send_enabled status (whether a denom is sendable). description: >- Deprecated: Use of SendEnabled in params is deprecated. For genesis, use the newly added send_enabled field in the genesis object. Storage, lookup, and manipulation of this information is now in the keeper. As of cosmos-sdk 0.47, this only exists for backwards compatibility of genesis files. default_send_enabled: type: boolean description: Params defines the parameters for the bank module. description: QueryParamsResponse defines the response type for querying x/bank parameters. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/bank/v1beta1/send_enabled: get: summary: SendEnabled queries for SendEnabled entries. description: >- This query only returns denominations that have specific SendEnabled settings. Any denomination that does not have a specific setting will use the default params.default_send_enabled, and will not be returned by this query. Since: cosmos-sdk 0.47 operationId: SendEnabled_V2SG0 responses: "200": description: A successful response. content: application/json: schema: type: object properties: send_enabled: type: array items: type: object properties: denom: type: string enabled: type: boolean description: >- SendEnabled maps coin denom to a send_enabled status (whether a denom is sendable). pagination: description: >- pagination defines the pagination in the response. This field is only populated if the denoms field in the request is empty. type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- QuerySendEnabledResponse defines the RPC response of a SendEnable query. Since: cosmos-sdk 0.47 default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: denoms description: denoms is the specific denoms you want look up. Leave empty to get all entries. in: query required: false explode: true schema: type: array items: type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/cosmos/bank/v1beta1/spendable_balances/{address}": get: summary: >- SpendableBalances queries the spendable balance of all coins for a single account. description: >- When called from another module, this query might consume a high amount of gas if the pagination field is incorrectly set. Since: cosmos-sdk 0.46 operationId: SpendableBalances_NOU7D responses: "200": description: A successful response. content: application/json: schema: type: object properties: balances: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: balances is the spendable balances of all the coins. pagination: description: pagination defines the pagination in the response. type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- QuerySpendableBalancesResponse defines the gRPC response structure for querying an account's spendable balances. Since: cosmos-sdk 0.46 default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: address description: address is the address to query spendable balances for. in: path required: true schema: type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/cosmos/bank/v1beta1/spendable_balances/{address}/by_denom": get: summary: >- SpendableBalanceByDenom queries the spendable balance of a single denom for a single account. description: >- When called from another module, this query might consume a high amount of gas if the pagination field is incorrectly set. Since: cosmos-sdk 0.47 operationId: SpendableBalanceByDenom_IY25V responses: "200": description: A successful response. content: application/json: schema: type: object properties: balance: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- QuerySpendableBalanceByDenomResponse defines the gRPC response structure for querying an account's spendable balance for a specific denom. Since: cosmos-sdk 0.47 default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: address description: address is the address to query balances for. in: path required: true schema: type: string - name: denom description: denom is the coin denom to query balances for. in: query required: false schema: type: string tags: - gRPC Gateway API /cosmos/bank/v1beta1/supply: get: summary: TotalSupply queries the total supply of all coins. description: >- When called from another module, this query might consume a high amount of gas if the pagination field is incorrectly set. operationId: TotalSupply_LCA37 responses: "200": description: A successful response. content: application/json: schema: type: object properties: supply: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: supply is the supply of the coins pagination: description: |- pagination defines the pagination in the response. Since: cosmos-sdk 0.43 type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise title: >- QueryTotalSupplyResponse is the response type for the Query/TotalSupply RPC method default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API /cosmos/bank/v1beta1/supply/by_denom: get: summary: SupplyOf queries the supply of a single coin. description: >- When called from another module, this query might consume a high amount of gas if the pagination field is incorrectly set. operationId: SupplyOf_PD96O responses: "200": description: A successful response. content: application/json: schema: type: object properties: amount: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: QuerySupplyOfResponse is the response type for the Query/SupplyOf RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: denom description: denom is the coin denom to query balances for. in: query required: false schema: type: string tags: - gRPC Gateway API "/ibc/core/connection/v1/client_connections/{client_id}": get: summary: |- ClientConnections queries the connection paths associated with a client state. operationId: ClientConnections_ULSVA responses: "200": description: A successful response. content: application/json: schema: type: object properties: connection_paths: type: array items: type: string description: slice of all the connection paths associated with a client. proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was generated type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryClientConnectionsResponse is the response type for the Query/ClientConnections RPC method default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: client_id description: client identifier associated with a connection in: path required: true schema: type: string tags: - gRPC Gateway API /ibc/core/connection/v1/connections: get: summary: Connections queries all the IBC connections of a chain. operationId: Connections_KUGQB responses: "200": description: A successful response. content: application/json: schema: type: object properties: connections: type: array items: type: object properties: id: type: string description: connection identifier. client_id: type: string description: client associated with this connection. versions: type: array items: type: object properties: identifier: type: string title: unique version identifier features: type: array items: type: string title: list of features compatible with the specified identifier description: >- Version defines the versioning scheme used to negotiate the IBC verison in the connection handshake. title: >- IBC version which can be utilised to determine encodings or protocols for channels or packets utilising this connection state: description: current state of the connection end. type: string enum: - STATE_UNINITIALIZED_UNSPECIFIED - STATE_INIT - STATE_TRYOPEN - STATE_OPEN default: STATE_UNINITIALIZED_UNSPECIFIED counterparty: description: counterparty chain associated with this connection. type: object properties: client_id: type: string description: >- identifies the client on the counterparty chain associated with a given connection. connection_id: type: string description: >- identifies the connection end on the counterparty chain associated with a given connection. prefix: description: commitment merkle prefix of the counterparty chain. type: object properties: key_prefix: type: string format: byte title: >- MerklePrefix is merkle path prefixed to the key. The constructed key from the Path and the key will be append(Path.KeyPath, append(Path.KeyPrefix, key...)) delay_period: type: string format: uint64 description: delay period associated with this connection. description: >- IdentifiedConnection defines a connection with additional connection identifier field. description: list of stored connections of the chain. pagination: title: pagination response type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } height: title: query block height type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset description: >- QueryConnectionsResponse is the response type for the Query/Connections RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/ibc/core/connection/v1/connections/{connection_id}": get: summary: Connection queries an IBC connection end. operationId: Connection_OOALY responses: "200": description: A successful response. content: application/json: schema: type: object properties: connection: title: connection associated with the request identifier type: object properties: client_id: type: string description: client associated with this connection. versions: type: array items: type: object properties: identifier: type: string title: unique version identifier features: type: array items: type: string title: list of features compatible with the specified identifier description: >- Version defines the versioning scheme used to negotiate the IBC verison in the connection handshake. description: >- IBC version which can be utilised to determine encodings or protocols for channels or packets utilising this connection. state: description: current state of the connection end. type: string enum: - STATE_UNINITIALIZED_UNSPECIFIED - STATE_INIT - STATE_TRYOPEN - STATE_OPEN default: STATE_UNINITIALIZED_UNSPECIFIED counterparty: description: counterparty chain associated with this connection. type: object properties: client_id: type: string description: >- identifies the client on the counterparty chain associated with a given connection. connection_id: type: string description: >- identifies the connection end on the counterparty chain associated with a given connection. prefix: description: commitment merkle prefix of the counterparty chain. type: object properties: key_prefix: type: string format: byte title: >- MerklePrefix is merkle path prefixed to the key. The constructed key from the Path and the key will be append(Path.KeyPath, append(Path.KeyPrefix, key...)) delay_period: type: string format: uint64 description: >- delay period that must pass before a consensus state can be used for packet-verification NOTE: delay period logic is only implemented by some clients. description: >- ConnectionEnd defines a stateful object on a chain connected to another separate one. NOTE: there must only be 2 defined ConnectionEnds to establish a connection between two chains. proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset description: >- QueryConnectionResponse is the response type for the Query/Connection RPC method. Besides the connection end, it includes a proof and the height from which the proof was retrieved. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: connection_id description: connection unique identifier in: path required: true schema: type: string tags: - gRPC Gateway API "/ibc/core/connection/v1/connections/{connection_id}/client_state": get: summary: |- ConnectionClientState queries the client state associated with the connection. operationId: ConnectionClientState_E50ZS responses: "200": description: A successful response. content: application/json: schema: type: object properties: identified_client_state: title: client state associated with the channel type: object properties: client_id: type: string title: client identifier client_state: type: object properties: type_url: type: string value: type: string format: byte title: client state description: >- IdentifiedClientState defines a client state with an additional client identifier field. proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: >- QueryConnectionClientStateResponse is the response type for the Query/ConnectionClientState RPC method default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: connection_id description: connection identifier in: path required: true schema: type: string tags: - gRPC Gateway API "/ibc/core/connection/v1/connections/{connection_id}/consensus_state/revision/{revision_number}/height/{revision_height}": get: summary: |- ConnectionConsensusState queries the consensus state associated with the connection. operationId: ConnectionConsensusState_R48NV responses: "200": description: A successful response. content: application/json: schema: type: object properties: consensus_state: type: object properties: type_url: type: string value: type: string format: byte title: consensus state associated with the channel client_id: type: string title: client ID associated with the consensus state proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: >- QueryConnectionConsensusStateResponse is the response type for the Query/ConnectionConsensusState RPC method default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: connection_id description: connection identifier in: path required: true schema: type: string - name: revision_number in: path required: true schema: type: string format: uint64 - name: revision_height in: path required: true schema: type: string format: uint64 tags: - gRPC Gateway API /ibc/core/connection/v1/params: get: summary: ConnectionParams queries all parameters of the ibc connection submodule. operationId: ConnectionParams_FN616 responses: "200": description: A successful response. content: application/json: schema: type: object properties: params: description: params defines the parameters of the module. type: object properties: max_expected_time_per_block: type: string format: uint64 description: >- maximum expected time per block (in nanoseconds), used to enforce block delay. This parameter should reflect the largest amount of time that the chain might reasonably take to produce the next block under normal operating conditions. A safe choice is 3-5x the expected time per block. description: QueryConnectionParamsResponse is the response type for the Query/ConnectionParams RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cyber/grid/v1beta1/grid/destination_routed_energy: get: operationId: DestinationRoutedEnergy_1UWZP responses: "200": description: A successful response. content: application/json: schema: type: object properties: value: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: destination in: query required: false schema: type: string tags: - gRPC Gateway API /cyber/grid/v1beta1/grid/destination_routes: get: operationId: DestinationRoutes_DSHVX responses: "200": description: A successful response. content: application/json: schema: type: object properties: routes: type: array items: type: object properties: source: type: string destination: type: string name: type: string value: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: destination in: query required: false schema: type: string tags: - gRPC Gateway API /cyber/grid/v1beta1/grid/params: get: operationId: Params_JC8T4 responses: "200": description: A successful response. content: application/json: schema: type: object properties: params: type: object properties: max_routes: type: integer format: int64 default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cyber/grid/v1beta1/grid/route: get: operationId: Route_DJV9M responses: "200": description: A successful response. content: application/json: schema: type: object properties: route: type: object properties: source: type: string destination: type: string name: type: string value: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: source in: query required: false schema: type: string - name: destination in: query required: false schema: type: string tags: - gRPC Gateway API /cyber/grid/v1beta1/grid/routes: get: operationId: Routes_NX6XT responses: "200": description: A successful response. content: application/json: schema: type: object properties: routes: type: array items: type: object properties: source: type: string destination: type: string name: type: string value: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API /cyber/grid/v1beta1/grid/source_routed_energy: get: operationId: SourceRoutedEnergy_15BGT responses: "200": description: A successful response. content: application/json: schema: type: object properties: value: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: source in: query required: false schema: type: string tags: - gRPC Gateway API /cyber/grid/v1beta1/grid/source_routes: get: operationId: SourceRoutes_0YJSZ responses: "200": description: A successful response. content: application/json: schema: type: object properties: routes: type: array items: type: object properties: source: type: string destination: type: string name: type: string value: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: source in: query required: false schema: type: string tags: - gRPC Gateway API /cyber/dmn/v1beta1/dmn/params: get: operationId: Params_KSBWO responses: "200": description: A successful response. content: application/json: schema: type: object properties: params: type: object properties: max_slots: type: integer format: int64 max_gas: type: integer format: int64 fee_ttl: type: integer format: int64 default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cyber/dmn/v1beta1/dmn/thought: get: operationId: Thought_N9WGE responses: "200": description: A successful response. content: application/json: schema: type: object properties: thought: type: object properties: program: type: string trigger: type: object properties: period: type: string format: uint64 block: type: string format: uint64 load: type: object properties: input: type: string gas_price: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. name: type: string particle: type: string default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: program in: query required: false schema: type: string - name: name in: query required: false schema: type: string tags: - gRPC Gateway API /cyber/dmn/v1beta1/dmn/thought_stats: get: operationId: ThoughtStats_N3IA1 responses: "200": description: A successful response. content: application/json: schema: type: object properties: thought_stats: type: object properties: program: type: string name: type: string calls: type: string format: uint64 fees: type: string format: uint64 gas: type: string format: uint64 last_block: type: string format: uint64 default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: program in: query required: false schema: type: string - name: name in: query required: false schema: type: string tags: - gRPC Gateway API /cyber/dmn/v1beta1/dmn/thoughts: get: operationId: Thoughts_U2UB0 responses: "200": description: A successful response. content: application/json: schema: type: object properties: thoughts: type: array items: type: object properties: program: type: string trigger: type: object properties: period: type: string format: uint64 block: type: string format: uint64 load: type: object properties: input: type: string gas_price: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. name: type: string particle: type: string default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cyber/dmn/v1beta1/dmn/thoughts_fees: get: operationId: ThoughtsFees_WJZMQ responses: "200": description: A successful response. content: application/json: schema: type: object properties: fees: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cyber/dmn/v1beta1/dmn/thoughts_stats: get: operationId: ThoughtsStats_FOF22 responses: "200": description: A successful response. content: application/json: schema: type: object properties: thoughts_stats: type: array items: type: object properties: program: type: string name: type: string calls: type: string format: uint64 fees: type: string format: uint64 gas: type: string format: uint64 last_block: type: string format: uint64 default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API "/cosmos/staking/v1beta1/delegations/{delegator_addr}": get: summary: DelegatorDelegations queries all delegations of a given delegator address. description: >- When called from another module, this query might consume a high amount of gas if the pagination field is incorrectly set. operationId: DelegatorDelegations_5SDKK responses: "200": description: A successful response. content: application/json: schema: type: object properties: delegation_responses: type: array items: type: object properties: delegation: type: object properties: delegator_address: type: string description: delegator_address is the bech32-encoded address of the delegator. validator_address: type: string description: validator_address is the bech32-encoded address of the validator. shares: type: string description: shares define the delegation shares received. description: >- Delegation represents the bond with tokens held by an account. It is owned by one delegator, and is associated with the voting power of one validator. balance: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- DelegationResponse is equivalent to Delegation except that it contains a balance in addition to shares which is more suitable for client responses. description: delegation_responses defines all the delegations' info of a delegator. pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: |- QueryDelegatorDelegationsResponse is response type for the Query/DelegatorDelegations RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: delegator_addr description: delegator_addr defines the delegator address to query for. in: path required: true schema: type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/cosmos/staking/v1beta1/delegators/{delegator_addr}/redelegations": get: summary: Redelegations queries redelegations of given address. description: >- When called from another module, this query might consume a high amount of gas if the pagination field is incorrectly set. operationId: Redelegations_V11SE responses: "200": description: A successful response. content: application/json: schema: type: object properties: redelegation_responses: type: array items: type: object properties: redelegation: type: object properties: delegator_address: type: string description: delegator_address is the bech32-encoded address of the delegator. validator_src_address: type: string description: validator_src_address is the validator redelegation source operator address. validator_dst_address: type: string description: validator_dst_address is the validator redelegation destination operator address. entries: type: array items: type: object properties: creation_height: type: string format: int64 description: creation_height defines the height which the redelegation took place. completion_time: type: string format: date-time description: completion_time defines the unix time for redelegation completion. initial_balance: type: string description: initial_balance defines the initial balance when redelegation started. shares_dst: type: string description: shares_dst is the amount of destination-validator shares created by redelegation. unbonding_id: type: string format: uint64 title: Incrementing id that uniquely identifies this entry unbonding_on_hold_ref_count: type: string format: int64 title: Strictly positive if this entry's unbonding has been stopped by external modules description: RedelegationEntry defines a redelegation object with relevant metadata. description: entries are the redelegation entries. description: >- Redelegation contains the list of a particular delegator's redelegating bonds from a particular source validator to a particular destination validator. entries: type: array items: type: object properties: redelegation_entry: type: object properties: creation_height: type: string format: int64 description: creation_height defines the height which the redelegation took place. completion_time: type: string format: date-time description: completion_time defines the unix time for redelegation completion. initial_balance: type: string description: initial_balance defines the initial balance when redelegation started. shares_dst: type: string description: shares_dst is the amount of destination-validator shares created by redelegation. unbonding_id: type: string format: uint64 title: Incrementing id that uniquely identifies this entry unbonding_on_hold_ref_count: type: string format: int64 title: Strictly positive if this entry's unbonding has been stopped by external modules description: RedelegationEntry defines a redelegation object with relevant metadata. balance: type: string description: >- RedelegationEntryResponse is equivalent to a RedelegationEntry except that it contains a balance in addition to shares which is more suitable for client responses. description: >- RedelegationResponse is equivalent to a Redelegation except that its entries contain a balance in addition to shares which is more suitable for client responses. pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- QueryRedelegationsResponse is response type for the Query/Redelegations RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: delegator_addr description: delegator_addr defines the delegator address to query for. in: path required: true schema: type: string - name: src_validator_addr description: src_validator_addr defines the validator address to redelegate from. in: query required: false schema: type: string - name: dst_validator_addr description: dst_validator_addr defines the validator address to redelegate to. in: query required: false schema: type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/cosmos/staking/v1beta1/delegators/{delegator_addr}/unbonding_delegations": get: summary: >- DelegatorUnbondingDelegations queries all unbonding delegations of a given delegator address. description: >- When called from another module, this query might consume a high amount of gas if the pagination field is incorrectly set. operationId: DelegatorUnbondingDelegations_PWG9M responses: "200": description: A successful response. content: application/json: schema: type: object properties: unbonding_responses: type: array items: type: object properties: delegator_address: type: string description: delegator_address is the bech32-encoded address of the delegator. validator_address: type: string description: validator_address is the bech32-encoded address of the validator. entries: type: array items: type: object properties: creation_height: type: string format: int64 description: creation_height is the height which the unbonding took place. completion_time: type: string format: date-time description: completion_time is the unix time for unbonding completion. initial_balance: type: string description: initial_balance defines the tokens initially scheduled to receive at completion. balance: type: string description: balance defines the tokens to receive at completion. unbonding_id: type: string format: uint64 title: Incrementing id that uniquely identifies this entry unbonding_on_hold_ref_count: type: string format: int64 title: Strictly positive if this entry's unbonding has been stopped by external modules description: UnbondingDelegationEntry defines an unbonding object with relevant metadata. description: entries are the unbonding delegation entries. description: >- UnbondingDelegation stores all of a single delegator's unbonding bonds for a single validator in an time-ordered list. pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- QueryUnbondingDelegatorDelegationsResponse is response type for the Query/UnbondingDelegatorDelegations RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: delegator_addr description: delegator_addr defines the delegator address to query for. in: path required: true schema: type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/cosmos/staking/v1beta1/delegators/{delegator_addr}/validators": get: summary: |- DelegatorValidators queries all validators info for given delegator address. description: >- When called from another module, this query might consume a high amount of gas if the pagination field is incorrectly set. operationId: DelegatorValidators_ODLEN responses: "200": description: A successful response. content: application/json: schema: type: object properties: validators: type: array items: type: object properties: operator_address: type: string description: operator_address defines the address of the validator's operator; bech encoded in JSON. consensus_pubkey: type: object properties: type_url: type: string value: type: string format: byte description: consensus_pubkey is the consensus public key of the validator, as a Protobuf Any. jailed: type: boolean description: jailed defined whether the validator has been jailed from bonded status or not. status: description: status is the validator status (bonded/unbonding/unbonded). type: string enum: - BOND_STATUS_UNSPECIFIED - BOND_STATUS_UNBONDED - BOND_STATUS_UNBONDING - BOND_STATUS_BONDED default: BOND_STATUS_UNSPECIFIED tokens: type: string description: tokens define the delegated tokens (incl. self-delegation). delegator_shares: type: string description: delegator_shares defines total shares issued to a validator's delegators. description: description: description defines the description terms for the validator. type: object properties: moniker: type: string description: moniker defines a human-readable name for the validator. identity: type: string description: identity defines an optional identity signature (ex. UPort or Keybase). website: type: string description: website defines an optional website link. security_contact: type: string description: security_contact defines an optional email for security contact. details: type: string description: details define other optional details. unbonding_height: type: string format: int64 description: unbonding_height defines, if unbonding, the height at which this validator has begun unbonding. unbonding_time: type: string format: date-time description: unbonding_time defines, if unbonding, the min time for the validator to complete unbonding. commission: description: commission defines the commission parameters. type: object properties: commission_rates: description: commission_rates defines the initial commission rates to be used for creating a validator. type: object properties: rate: type: string description: rate is the commission rate charged to delegators, as a fraction. max_rate: type: string description: max_rate defines the maximum commission rate which validator can ever charge, as a fraction. max_change_rate: type: string description: max_change_rate defines the maximum daily increase of the validator commission, as a fraction. update_time: type: string format: date-time description: update_time is the last time the commission rate was changed. min_self_delegation: type: string description: >- min_self_delegation is the validator's self declared minimum self delegation. Since: cosmos-sdk 0.46 unbonding_on_hold_ref_count: type: string format: int64 title: strictly positive if this validator's unbonding has been stopped by external modules unbonding_ids: type: array items: type: string format: uint64 title: list of unbonding ids, each uniquely identifing an unbonding of this validator description: >- Validator defines a validator, together with the total amount of the Validator's bond shares and their exchange rate to coins. Slashing results in a decrease in the exchange rate, allowing correct calculation of future undelegations without iterating over delegators. When coins are delegated to this validator, the validator is credited with a delegation whose number of bond shares is based on the amount of coins delegated divided by the current exchange rate. Voting power can be calculated as total bonded shares multiplied by exchange rate. description: validators defines the validators' info of a delegator. pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: |- QueryDelegatorValidatorsResponse is response type for the Query/DelegatorValidators RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: delegator_addr description: delegator_addr defines the delegator address to query for. in: path required: true schema: type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/cosmos/staking/v1beta1/delegators/{delegator_addr}/validators/{validator_addr}": get: summary: |- DelegatorValidator queries validator info for given delegator validator pair. operationId: DelegatorValidator_4VGVV responses: "200": description: A successful response. content: application/json: schema: type: object properties: validator: type: object properties: operator_address: type: string description: operator_address defines the address of the validator's operator; bech encoded in JSON. consensus_pubkey: type: object properties: type_url: type: string value: type: string format: byte description: consensus_pubkey is the consensus public key of the validator, as a Protobuf Any. jailed: type: boolean description: jailed defined whether the validator has been jailed from bonded status or not. status: description: status is the validator status (bonded/unbonding/unbonded). type: string enum: - BOND_STATUS_UNSPECIFIED - BOND_STATUS_UNBONDED - BOND_STATUS_UNBONDING - BOND_STATUS_BONDED default: BOND_STATUS_UNSPECIFIED tokens: type: string description: tokens define the delegated tokens (incl. self-delegation). delegator_shares: type: string description: delegator_shares defines total shares issued to a validator's delegators. description: description: description defines the description terms for the validator. type: object properties: moniker: type: string description: moniker defines a human-readable name for the validator. identity: type: string description: identity defines an optional identity signature (ex. UPort or Keybase). website: type: string description: website defines an optional website link. security_contact: type: string description: security_contact defines an optional email for security contact. details: type: string description: details define other optional details. unbonding_height: type: string format: int64 description: unbonding_height defines, if unbonding, the height at which this validator has begun unbonding. unbonding_time: type: string format: date-time description: unbonding_time defines, if unbonding, the min time for the validator to complete unbonding. commission: description: commission defines the commission parameters. type: object properties: commission_rates: description: commission_rates defines the initial commission rates to be used for creating a validator. type: object properties: rate: type: string description: rate is the commission rate charged to delegators, as a fraction. max_rate: type: string description: max_rate defines the maximum commission rate which validator can ever charge, as a fraction. max_change_rate: type: string description: max_change_rate defines the maximum daily increase of the validator commission, as a fraction. update_time: type: string format: date-time description: update_time is the last time the commission rate was changed. min_self_delegation: type: string description: >- min_self_delegation is the validator's self declared minimum self delegation. Since: cosmos-sdk 0.46 unbonding_on_hold_ref_count: type: string format: int64 title: strictly positive if this validator's unbonding has been stopped by external modules unbonding_ids: type: array items: type: string format: uint64 title: list of unbonding ids, each uniquely identifing an unbonding of this validator description: >- Validator defines a validator, together with the total amount of the Validator's bond shares and their exchange rate to coins. Slashing results in a decrease in the exchange rate, allowing correct calculation of future undelegations without iterating over delegators. When coins are delegated to this validator, the validator is credited with a delegation whose number of bond shares is based on the amount of coins delegated divided by the current exchange rate. Voting power can be calculated as total bonded shares multiplied by exchange rate. description: |- QueryDelegatorValidatorResponse response type for the Query/DelegatorValidator RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: delegator_addr description: delegator_addr defines the delegator address to query for. in: path required: true schema: type: string - name: validator_addr description: validator_addr defines the validator address to query for. in: path required: true schema: type: string tags: - gRPC Gateway API "/cosmos/staking/v1beta1/historical_info/{height}": get: summary: HistoricalInfo queries the historical info for given height. operationId: HistoricalInfo_5WZCR responses: "200": description: A successful response. content: application/json: schema: type: object properties: hist: description: hist defines the historical info at the given height. type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. valset: type: array items: type: object properties: operator_address: type: string description: operator_address defines the address of the validator's operator; bech encoded in JSON. consensus_pubkey: type: object properties: type_url: type: string value: type: string format: byte description: consensus_pubkey is the consensus public key of the validator, as a Protobuf Any. jailed: type: boolean description: jailed defined whether the validator has been jailed from bonded status or not. status: description: status is the validator status (bonded/unbonding/unbonded). type: string enum: - BOND_STATUS_UNSPECIFIED - BOND_STATUS_UNBONDED - BOND_STATUS_UNBONDING - BOND_STATUS_BONDED default: BOND_STATUS_UNSPECIFIED tokens: type: string description: tokens define the delegated tokens (incl. self-delegation). delegator_shares: type: string description: delegator_shares defines total shares issued to a validator's delegators. description: description: description defines the description terms for the validator. type: object properties: moniker: type: string description: moniker defines a human-readable name for the validator. identity: type: string description: identity defines an optional identity signature (ex. UPort or Keybase). website: type: string description: website defines an optional website link. security_contact: type: string description: security_contact defines an optional email for security contact. details: type: string description: details define other optional details. unbonding_height: type: string format: int64 description: unbonding_height defines, if unbonding, the height at which this validator has begun unbonding. unbonding_time: type: string format: date-time description: unbonding_time defines, if unbonding, the min time for the validator to complete unbonding. commission: description: commission defines the commission parameters. type: object properties: commission_rates: description: commission_rates defines the initial commission rates to be used for creating a validator. type: object properties: rate: type: string description: rate is the commission rate charged to delegators, as a fraction. max_rate: type: string description: max_rate defines the maximum commission rate which validator can ever charge, as a fraction. max_change_rate: type: string description: max_change_rate defines the maximum daily increase of the validator commission, as a fraction. update_time: type: string format: date-time description: update_time is the last time the commission rate was changed. min_self_delegation: type: string description: >- min_self_delegation is the validator's self declared minimum self delegation. Since: cosmos-sdk 0.46 unbonding_on_hold_ref_count: type: string format: int64 title: strictly positive if this validator's unbonding has been stopped by external modules unbonding_ids: type: array items: type: string format: uint64 title: list of unbonding ids, each uniquely identifing an unbonding of this validator description: >- Validator defines a validator, together with the total amount of the Validator's bond shares and their exchange rate to coins. Slashing results in a decrease in the exchange rate, allowing correct calculation of future undelegations without iterating over delegators. When coins are delegated to this validator, the validator is credited with a delegation whose number of bond shares is based on the amount of coins delegated divided by the current exchange rate. Voting power can be calculated as total bonded shares multiplied by exchange rate. description: >- QueryHistoricalInfoResponse is response type for the Query/HistoricalInfo RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: height description: height defines at which height to query the historical info. in: path required: true schema: type: string format: int64 tags: - gRPC Gateway API /cosmos/staking/v1beta1/params: get: summary: Parameters queries the staking parameters. operationId: Params_2OHI6 responses: "200": description: A successful response. content: application/json: schema: type: object properties: params: description: params holds all the parameters of this module. type: object properties: unbonding_time: type: string description: unbonding_time is the time duration of unbonding. max_validators: type: integer format: int64 description: max_validators is the maximum number of validators. max_entries: type: integer format: int64 description: max_entries is the max entries for either unbonding delegation or redelegation (per pair/trio). historical_entries: type: integer format: int64 description: historical_entries is the number of historical entries to persist. bond_denom: type: string description: bond_denom defines the bondable coin denomination. min_commission_rate: type: string title: min_commission_rate is the chain-wide minimum commission rate that a validator can charge their delegators description: QueryParamsResponse is response type for the Query/Params RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/staking/v1beta1/pool: get: summary: Pool queries the pool info. operationId: Pool_YT1XX responses: "200": description: A successful response. content: application/json: schema: type: object properties: pool: description: pool defines the pool info. type: object properties: not_bonded_tokens: type: string bonded_tokens: type: string description: QueryPoolResponse is response type for the Query/Pool RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/staking/v1beta1/validators: get: summary: Validators queries all validators that match the given status. description: >- When called from another module, this query might consume a high amount of gas if the pagination field is incorrectly set. operationId: Validators_8C5VK responses: "200": description: A successful response. content: application/json: schema: type: object properties: validators: type: array items: type: object properties: operator_address: type: string description: operator_address defines the address of the validator's operator; bech encoded in JSON. consensus_pubkey: type: object properties: type_url: type: string value: type: string format: byte description: consensus_pubkey is the consensus public key of the validator, as a Protobuf Any. jailed: type: boolean description: jailed defined whether the validator has been jailed from bonded status or not. status: description: status is the validator status (bonded/unbonding/unbonded). type: string enum: - BOND_STATUS_UNSPECIFIED - BOND_STATUS_UNBONDED - BOND_STATUS_UNBONDING - BOND_STATUS_BONDED default: BOND_STATUS_UNSPECIFIED tokens: type: string description: tokens define the delegated tokens (incl. self-delegation). delegator_shares: type: string description: delegator_shares defines total shares issued to a validator's delegators. description: description: description defines the description terms for the validator. type: object properties: moniker: type: string description: moniker defines a human-readable name for the validator. identity: type: string description: identity defines an optional identity signature (ex. UPort or Keybase). website: type: string description: website defines an optional website link. security_contact: type: string description: security_contact defines an optional email for security contact. details: type: string description: details define other optional details. unbonding_height: type: string format: int64 description: unbonding_height defines, if unbonding, the height at which this validator has begun unbonding. unbonding_time: type: string format: date-time description: unbonding_time defines, if unbonding, the min time for the validator to complete unbonding. commission: description: commission defines the commission parameters. type: object properties: commission_rates: description: commission_rates defines the initial commission rates to be used for creating a validator. type: object properties: rate: type: string description: rate is the commission rate charged to delegators, as a fraction. max_rate: type: string description: max_rate defines the maximum commission rate which validator can ever charge, as a fraction. max_change_rate: type: string description: max_change_rate defines the maximum daily increase of the validator commission, as a fraction. update_time: type: string format: date-time description: update_time is the last time the commission rate was changed. min_self_delegation: type: string description: >- min_self_delegation is the validator's self declared minimum self delegation. Since: cosmos-sdk 0.46 unbonding_on_hold_ref_count: type: string format: int64 title: strictly positive if this validator's unbonding has been stopped by external modules unbonding_ids: type: array items: type: string format: uint64 title: list of unbonding ids, each uniquely identifing an unbonding of this validator description: >- Validator defines a validator, together with the total amount of the Validator's bond shares and their exchange rate to coins. Slashing results in a decrease in the exchange rate, allowing correct calculation of future undelegations without iterating over delegators. When coins are delegated to this validator, the validator is credited with a delegation whose number of bond shares is based on the amount of coins delegated divided by the current exchange rate. Voting power can be calculated as total bonded shares multiplied by exchange rate. description: validators contains all the queried validators. pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: QueryValidatorsResponse is response type for the Query/Validators RPC method default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: status description: status enables to query for validators matching a given status. in: query required: false schema: type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/cosmos/staking/v1beta1/validators/{validator_addr}": get: summary: Validator queries validator info for given validator address. operationId: Validator_50V8E responses: "200": description: A successful response. content: application/json: schema: type: object properties: validator: type: object properties: operator_address: type: string description: operator_address defines the address of the validator's operator; bech encoded in JSON. consensus_pubkey: type: object properties: type_url: type: string value: type: string format: byte description: consensus_pubkey is the consensus public key of the validator, as a Protobuf Any. jailed: type: boolean description: jailed defined whether the validator has been jailed from bonded status or not. status: description: status is the validator status (bonded/unbonding/unbonded). type: string enum: - BOND_STATUS_UNSPECIFIED - BOND_STATUS_UNBONDED - BOND_STATUS_UNBONDING - BOND_STATUS_BONDED default: BOND_STATUS_UNSPECIFIED tokens: type: string description: tokens define the delegated tokens (incl. self-delegation). delegator_shares: type: string description: delegator_shares defines total shares issued to a validator's delegators. description: description: description defines the description terms for the validator. type: object properties: moniker: type: string description: moniker defines a human-readable name for the validator. identity: type: string description: identity defines an optional identity signature (ex. UPort or Keybase). website: type: string description: website defines an optional website link. security_contact: type: string description: security_contact defines an optional email for security contact. details: type: string description: details define other optional details. unbonding_height: type: string format: int64 description: unbonding_height defines, if unbonding, the height at which this validator has begun unbonding. unbonding_time: type: string format: date-time description: unbonding_time defines, if unbonding, the min time for the validator to complete unbonding. commission: description: commission defines the commission parameters. type: object properties: commission_rates: description: commission_rates defines the initial commission rates to be used for creating a validator. type: object properties: rate: type: string description: rate is the commission rate charged to delegators, as a fraction. max_rate: type: string description: max_rate defines the maximum commission rate which validator can ever charge, as a fraction. max_change_rate: type: string description: max_change_rate defines the maximum daily increase of the validator commission, as a fraction. update_time: type: string format: date-time description: update_time is the last time the commission rate was changed. min_self_delegation: type: string description: >- min_self_delegation is the validator's self declared minimum self delegation. Since: cosmos-sdk 0.46 unbonding_on_hold_ref_count: type: string format: int64 title: strictly positive if this validator's unbonding has been stopped by external modules unbonding_ids: type: array items: type: string format: uint64 title: list of unbonding ids, each uniquely identifing an unbonding of this validator description: >- Validator defines a validator, together with the total amount of the Validator's bond shares and their exchange rate to coins. Slashing results in a decrease in the exchange rate, allowing correct calculation of future undelegations without iterating over delegators. When coins are delegated to this validator, the validator is credited with a delegation whose number of bond shares is based on the amount of coins delegated divided by the current exchange rate. Voting power can be calculated as total bonded shares multiplied by exchange rate. title: QueryValidatorResponse is response type for the Query/Validator RPC method default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: validator_addr description: validator_addr defines the validator address to query for. in: path required: true schema: type: string tags: - gRPC Gateway API "/cosmos/staking/v1beta1/validators/{validator_addr}/delegations": get: summary: ValidatorDelegations queries delegate info for given validator. description: >- When called from another module, this query might consume a high amount of gas if the pagination field is incorrectly set. operationId: ValidatorDelegations_WQPT6 responses: "200": description: A successful response. content: application/json: schema: type: object properties: delegation_responses: type: array items: type: object properties: delegation: type: object properties: delegator_address: type: string description: delegator_address is the bech32-encoded address of the delegator. validator_address: type: string description: validator_address is the bech32-encoded address of the validator. shares: type: string description: shares define the delegation shares received. description: >- Delegation represents the bond with tokens held by an account. It is owned by one delegator, and is associated with the voting power of one validator. balance: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- DelegationResponse is equivalent to Delegation except that it contains a balance in addition to shares which is more suitable for client responses. pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: |- QueryValidatorDelegationsResponse is response type for the Query/ValidatorDelegations RPC method default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: validator_addr description: validator_addr defines the validator address to query for. in: path required: true schema: type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/cosmos/staking/v1beta1/validators/{validator_addr}/delegations/{delegator_addr}": get: summary: Delegation queries delegate info for given validator delegator pair. operationId: Delegation_KEKGD responses: "200": description: A successful response. content: application/json: schema: type: object properties: delegation_response: type: object properties: delegation: type: object properties: delegator_address: type: string description: delegator_address is the bech32-encoded address of the delegator. validator_address: type: string description: validator_address is the bech32-encoded address of the validator. shares: type: string description: shares define the delegation shares received. description: >- Delegation represents the bond with tokens held by an account. It is owned by one delegator, and is associated with the voting power of one validator. balance: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- DelegationResponse is equivalent to Delegation except that it contains a balance in addition to shares which is more suitable for client responses. description: QueryDelegationResponse is response type for the Query/Delegation RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: validator_addr description: validator_addr defines the validator address to query for. in: path required: true schema: type: string - name: delegator_addr description: delegator_addr defines the delegator address to query for. in: path required: true schema: type: string tags: - gRPC Gateway API "/cosmos/staking/v1beta1/validators/{validator_addr}/delegations/{delegator_addr}/unbonding_delegation": get: summary: |- UnbondingDelegation queries unbonding info for given validator delegator pair. operationId: UnbondingDelegation_ZYWZV responses: "200": description: A successful response. content: application/json: schema: type: object properties: unbond: type: object properties: delegator_address: type: string description: delegator_address is the bech32-encoded address of the delegator. validator_address: type: string description: validator_address is the bech32-encoded address of the validator. entries: type: array items: type: object properties: creation_height: type: string format: int64 description: creation_height is the height which the unbonding took place. completion_time: type: string format: date-time description: completion_time is the unix time for unbonding completion. initial_balance: type: string description: initial_balance defines the tokens initially scheduled to receive at completion. balance: type: string description: balance defines the tokens to receive at completion. unbonding_id: type: string format: uint64 title: Incrementing id that uniquely identifies this entry unbonding_on_hold_ref_count: type: string format: int64 title: Strictly positive if this entry's unbonding has been stopped by external modules description: UnbondingDelegationEntry defines an unbonding object with relevant metadata. description: entries are the unbonding delegation entries. description: >- UnbondingDelegation stores all of a single delegator's unbonding bonds for a single validator in an time-ordered list. description: >- QueryDelegationResponse is response type for the Query/UnbondingDelegation RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: validator_addr description: validator_addr defines the validator address to query for. in: path required: true schema: type: string - name: delegator_addr description: delegator_addr defines the delegator address to query for. in: path required: true schema: type: string tags: - gRPC Gateway API "/cosmos/staking/v1beta1/validators/{validator_addr}/unbonding_delegations": get: summary: ValidatorUnbondingDelegations queries unbonding delegations of a validator. description: >- When called from another module, this query might consume a high amount of gas if the pagination field is incorrectly set. operationId: ValidatorUnbondingDelegations_2MTRI responses: "200": description: A successful response. content: application/json: schema: type: object properties: unbonding_responses: type: array items: type: object properties: delegator_address: type: string description: delegator_address is the bech32-encoded address of the delegator. validator_address: type: string description: validator_address is the bech32-encoded address of the validator. entries: type: array items: type: object properties: creation_height: type: string format: int64 description: creation_height is the height which the unbonding took place. completion_time: type: string format: date-time description: completion_time is the unix time for unbonding completion. initial_balance: type: string description: initial_balance defines the tokens initially scheduled to receive at completion. balance: type: string description: balance defines the tokens to receive at completion. unbonding_id: type: string format: uint64 title: Incrementing id that uniquely identifies this entry unbonding_on_hold_ref_count: type: string format: int64 title: Strictly positive if this entry's unbonding has been stopped by external modules description: UnbondingDelegationEntry defines an unbonding object with relevant metadata. description: entries are the unbonding delegation entries. description: >- UnbondingDelegation stores all of a single delegator's unbonding bonds for a single validator in an time-ordered list. pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- QueryValidatorUnbondingDelegationsResponse is response type for the Query/ValidatorUnbondingDelegations RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: validator_addr description: validator_addr defines the validator address to query for. in: path required: true schema: type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/ibc/apps/transfer/v1/channels/{channel_id}/ports/{port_id}/escrow_address": get: summary: EscrowAddress returns the escrow address for a particular port and channel id. operationId: EscrowAddress_H4ZU3 responses: "200": description: A successful response. content: application/json: schema: type: object properties: escrow_address: type: string title: the escrow account address description: QueryEscrowAddressResponse is the response type of the EscrowAddress RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: channel_id description: unique channel identifier in: path required: true schema: type: string - name: port_id description: unique port identifier in: path required: true schema: type: string tags: - gRPC Gateway API "/ibc/apps/transfer/v1/denom_hashes/{trace}": get: summary: DenomHash queries a denomination hash information. operationId: DenomHash_BMCJ0 responses: "200": description: A successful response. content: application/json: schema: type: object properties: hash: type: string description: hash (in hex format) of the denomination trace information. description: >- QueryDenomHashResponse is the response type for the Query/DenomHash RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: trace description: The denomination trace ([port_id]/[channel_id])+/[denom] in: path required: true schema: type: string tags: - gRPC Gateway API /ibc/apps/transfer/v1/denom_traces: get: summary: DenomTraces queries all denomination traces. operationId: DenomTraces_UYI2F responses: "200": description: A successful response. content: application/json: schema: type: object properties: denom_traces: type: array items: type: object properties: path: type: string description: >- path defines the chain of port/channel identifiers used for tracing the source of the fungible token. base_denom: type: string description: base denomination of the relayed fungible token. description: >- DenomTrace contains the base denomination for ICS20 fungible tokens and the source tracing information path. description: denom_traces returns all denominations trace information. pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- QueryConnectionsResponse is the response type for the Query/DenomTraces RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/ibc/apps/transfer/v1/denom_traces/{hash}": get: summary: DenomTrace queries a denomination trace information. operationId: DenomTrace_3PQDP responses: "200": description: A successful response. content: application/json: schema: type: object properties: denom_trace: type: object properties: path: type: string description: >- path defines the chain of port/channel identifiers used for tracing the source of the fungible token. base_denom: type: string description: base denomination of the relayed fungible token. description: >- DenomTrace contains the base denomination for ICS20 fungible tokens and the source tracing information path. description: >- QueryDenomTraceResponse is the response type for the Query/DenomTrace RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: hash description: hash (in hex format) or denom (full denom with ibc prefix) of the denomination trace information. in: path required: true schema: type: string tags: - gRPC Gateway API "/ibc/apps/transfer/v1/denoms/{denom}/total_escrow": get: summary: TotalEscrowForDenom returns the total amount of tokens in escrow based on the denom. operationId: TotalEscrowForDenom_GBGAA responses: "200": description: A successful response. content: application/json: schema: type: object properties: amount: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: QueryTotalEscrowForDenomResponse is the response type for TotalEscrowForDenom RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: denom in: path required: true schema: type: string tags: - gRPC Gateway API /ibc/apps/transfer/v1/params: get: summary: Params queries all parameters of the ibc-transfer module. operationId: Params_4CJ8D responses: "200": description: A successful response. content: application/json: schema: type: object properties: params: description: params defines the parameters of the module. type: object properties: send_enabled: type: boolean description: >- send_enabled enables or disables all cross-chain token transfers from this chain. receive_enabled: type: boolean description: >- receive_enabled enables or disables all cross-chain token transfers to this chain. description: QueryParamsResponse is the response type for the Query/Params RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/tx/v1beta1/decode: post: summary: TxDecode decodes the transaction. description: "Since: cosmos-sdk 0.47" operationId: TxDecode_08PMV responses: "200": description: A successful response. content: application/json: schema: type: object properties: tx: description: tx is the decoded transaction. type: object properties: body: title: body is the processable content of the transaction type: object properties: messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- messages is a list of messages to be executed. The required signers of those messages define the number and order of elements in AuthInfo's signer_infos and Tx's signatures. Each required signer address is added to the list only the first time it occurs. By convention, the first required signer (usually from the first message) is referred to as the primary signer and pays the fee for the whole transaction. memo: type: string description: >- memo is any arbitrary note/comment to be added to the transaction. WARNING: in clients, any publicly exposed text should not be called memo, but should be called `note` instead (see https://github.com/cosmos/cosmos-sdk/issues/9122). timeout_height: type: string format: uint64 title: >- timeout is the block height after which this transaction will not be processed by the chain extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, the transaction will be rejected non_critical_extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, they will be ignored description: TxBody is the body of a transaction that all signers sign over. auth_info: title: >- auth_info is the authorization related content of the transaction, specifically signers, signer modes and fee type: object properties: signer_infos: type: array items: type: object properties: public_key: type: object properties: type_url: type: string value: type: string format: byte description: >- public_key is the public key of the signer. It is optional for accounts that already exist in state. If unset, the verifier can use the required \ signer address for this position and lookup the public key. mode_info: title: >- mode_info describes the signing mode of the signer and is a nested structure to support nested multisig pubkey's type: object properties: single: title: single represents a single signer type: object properties: mode: title: mode is the signing mode of the single signer type: string enum: - SIGN_MODE_UNSPECIFIED - SIGN_MODE_DIRECT - SIGN_MODE_TEXTUAL - SIGN_MODE_DIRECT_AUX - SIGN_MODE_LEGACY_AMINO_JSON - SIGN_MODE_EIP_191 default: SIGN_MODE_UNSPECIFIED description: >- SignMode represents a signing mode with its own security guarantees. This enum should be considered a registry of all known sign modes in the Cosmos ecosystem. Apps are not expected to support all known sign modes. Apps that would like to support custom sign modes are encouraged to open a small PR against this file to add a new case to this SignMode enum describing their sign mode so that different apps have a consistent version of this enum. - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be rejected. - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is verified with raw bytes from Tx. - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some human-readable textual representation on top of the binary representation from SIGN_MODE_DIRECT. It is currently not supported. - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses SignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not require signers signing over other signers' `signer_info`. It also allows for adding Tips in transactions. Since: cosmos-sdk 0.46 - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses Amino JSON and will be removed in the future. - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos SDK. Ref: https://eips.ethereum.org/EIPS/eip-191 Currently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant, but is not implemented on the SDK by default. To enable EIP-191, you need to pass a custom `TxConfig` that has an implementation of `SignModeHandler` for EIP-191. The SDK may decide to fully support EIP-191 in the future. Since: cosmos-sdk 0.45.2 multi: title: multi represents a nested multisig signer type: object properties: bitarray: title: bitarray specifies which keys within the multisig are signing type: object properties: extra_bits_stored: type: integer format: int64 elems: type: string format: byte description: >- CompactBitArray is an implementation of a space efficient bit array. This is used to ensure that the encoded data takes up a minimal amount of space after proto encoding. This is not thread safe, and is not intended for concurrent usage. mode_infos: type: array items: {} title: >- mode_infos is the corresponding modes of the signers of the multisig which could include nested multisig public keys description: ModeInfo describes the signing mode of a single or nested multisig signer. sequence: type: string format: uint64 description: >- sequence is the sequence of the account, which describes the number of committed transactions signed by a given address. It is used to prevent replay attacks. description: >- SignerInfo describes the public key and signing mode of a single top-level signer. description: >- signer_infos defines the signing modes for the required signers. The number and order of elements must match the required signers from TxBody's messages. The first element is the primary signer and the one which pays the fee. fee: description: >- Fee is the fee and gas limit for the transaction. The first signer is the primary signer and the one which pays the fee. The fee can be calculated based on the cost of evaluating the body and doing signature verification of the signers. This can be estimated via simulation. type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of coins to be paid as a fee gas_limit: type: string format: uint64 title: >- gas_limit is the maximum gas that can be used in transaction processing before an out of gas error occurs payer: type: string description: >- if unset, the first signer is responsible for paying the fees. If set, the specified account must pay the fees. the payer must be a tx signer (and thus have signed this field in AuthInfo). setting this field does *not* change the ordering of required signers for the transaction. granter: type: string title: >- if set, the fee payer (either the first signer or the value of the payer field) requests that a fee grant be used to pay fees instead of the fee payer's own balance. If an appropriate fee grant does not exist or the chain does not support fee grants, this will fail tip: description: >- Tip is the optional tip used for transactions fees paid in another denom. This field is ignored if the chain didn't enable tips, i.e. didn't add the `TipDecorator` in its posthandler. Since: cosmos-sdk 0.46 type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of the tip tipper: type: string title: tipper is the address of the account paying for the tip description: >- AuthInfo describes the fee and signer modes that are used to sign a transaction. signatures: type: array items: type: string format: byte description: >- signatures is a list of signatures that matches the length and order of AuthInfo's signer_infos to allow connecting signature meta information like public key and signing mode by position. description: |- TxDecodeResponse is the response type for the Service.TxDecode method. Since: cosmos-sdk 0.47 default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte requestBody: content: application/json: schema: type: object properties: tx_bytes: type: string format: byte description: tx_bytes is the raw transaction. description: |- TxDecodeRequest is the request type for the Service.TxDecode RPC method. Since: cosmos-sdk 0.47 required: true tags: - gRPC Gateway API /cosmos/tx/v1beta1/decode/amino: post: summary: TxDecodeAmino decodes an Amino transaction from encoded bytes to JSON. description: "Since: cosmos-sdk 0.47" operationId: TxDecodeAmino_AUUEJ responses: "200": description: A successful response. content: application/json: schema: type: object properties: amino_json: type: string description: >- TxDecodeAminoResponse is the response type for the Service.TxDecodeAmino RPC method. Since: cosmos-sdk 0.47 default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte requestBody: content: application/json: schema: type: object properties: amino_binary: type: string format: byte description: >- TxDecodeAminoRequest is the request type for the Service.TxDecodeAmino RPC method. Since: cosmos-sdk 0.47 required: true tags: - gRPC Gateway API /cosmos/tx/v1beta1/encode: post: summary: TxEncode encodes the transaction. description: "Since: cosmos-sdk 0.47" operationId: TxEncode_SOL4O responses: "200": description: A successful response. content: application/json: schema: type: object properties: tx_bytes: type: string format: byte description: tx_bytes is the encoded transaction bytes. description: |- TxEncodeResponse is the response type for the Service.TxEncode method. Since: cosmos-sdk 0.47 default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte requestBody: content: application/json: schema: type: object properties: tx: description: tx is the transaction to encode. type: object properties: body: title: body is the processable content of the transaction type: object properties: messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- messages is a list of messages to be executed. The required signers of those messages define the number and order of elements in AuthInfo's signer_infos and Tx's signatures. Each required signer address is added to the list only the first time it occurs. By convention, the first required signer (usually from the first message) is referred to as the primary signer and pays the fee for the whole transaction. memo: type: string description: >- memo is any arbitrary note/comment to be added to the transaction. WARNING: in clients, any publicly exposed text should not be called memo, but should be called `note` instead (see https://github.com/cosmos/cosmos-sdk/issues/9122). timeout_height: type: string format: uint64 title: >- timeout is the block height after which this transaction will not be processed by the chain extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, the transaction will be rejected non_critical_extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, they will be ignored description: TxBody is the body of a transaction that all signers sign over. auth_info: title: >- auth_info is the authorization related content of the transaction, specifically signers, signer modes and fee type: object properties: signer_infos: type: array items: type: object properties: public_key: type: object properties: type_url: type: string value: type: string format: byte description: >- public_key is the public key of the signer. It is optional for accounts that already exist in state. If unset, the verifier can use the required \ signer address for this position and lookup the public key. mode_info: title: >- mode_info describes the signing mode of the signer and is a nested structure to support nested multisig pubkey's type: object properties: single: title: single represents a single signer type: object properties: mode: title: mode is the signing mode of the single signer type: string enum: - SIGN_MODE_UNSPECIFIED - SIGN_MODE_DIRECT - SIGN_MODE_TEXTUAL - SIGN_MODE_DIRECT_AUX - SIGN_MODE_LEGACY_AMINO_JSON - SIGN_MODE_EIP_191 default: SIGN_MODE_UNSPECIFIED description: >- SignMode represents a signing mode with its own security guarantees. This enum should be considered a registry of all known sign modes in the Cosmos ecosystem. Apps are not expected to support all known sign modes. Apps that would like to support custom sign modes are encouraged to open a small PR against this file to add a new case to this SignMode enum describing their sign mode so that different apps have a consistent version of this enum. - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be rejected. - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is verified with raw bytes from Tx. - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some human-readable textual representation on top of the binary representation from SIGN_MODE_DIRECT. It is currently not supported. - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses SignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not require signers signing over other signers' `signer_info`. It also allows for adding Tips in transactions. Since: cosmos-sdk 0.46 - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses Amino JSON and will be removed in the future. - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos SDK. Ref: https://eips.ethereum.org/EIPS/eip-191 Currently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant, but is not implemented on the SDK by default. To enable EIP-191, you need to pass a custom `TxConfig` that has an implementation of `SignModeHandler` for EIP-191. The SDK may decide to fully support EIP-191 in the future. Since: cosmos-sdk 0.45.2 multi: title: multi represents a nested multisig signer type: object properties: bitarray: title: bitarray specifies which keys within the multisig are signing type: object properties: extra_bits_stored: type: integer format: int64 elems: type: string format: byte description: >- CompactBitArray is an implementation of a space efficient bit array. This is used to ensure that the encoded data takes up a minimal amount of space after proto encoding. This is not thread safe, and is not intended for concurrent usage. mode_infos: type: array items: {} title: >- mode_infos is the corresponding modes of the signers of the multisig which could include nested multisig public keys description: ModeInfo describes the signing mode of a single or nested multisig signer. sequence: type: string format: uint64 description: >- sequence is the sequence of the account, which describes the number of committed transactions signed by a given address. It is used to prevent replay attacks. description: >- SignerInfo describes the public key and signing mode of a single top-level signer. description: >- signer_infos defines the signing modes for the required signers. The number and order of elements must match the required signers from TxBody's messages. The first element is the primary signer and the one which pays the fee. fee: description: >- Fee is the fee and gas limit for the transaction. The first signer is the primary signer and the one which pays the fee. The fee can be calculated based on the cost of evaluating the body and doing signature verification of the signers. This can be estimated via simulation. type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of coins to be paid as a fee gas_limit: type: string format: uint64 title: >- gas_limit is the maximum gas that can be used in transaction processing before an out of gas error occurs payer: type: string description: >- if unset, the first signer is responsible for paying the fees. If set, the specified account must pay the fees. the payer must be a tx signer (and thus have signed this field in AuthInfo). setting this field does *not* change the ordering of required signers for the transaction. granter: type: string title: >- if set, the fee payer (either the first signer or the value of the payer field) requests that a fee grant be used to pay fees instead of the fee payer's own balance. If an appropriate fee grant does not exist or the chain does not support fee grants, this will fail tip: description: >- Tip is the optional tip used for transactions fees paid in another denom. This field is ignored if the chain didn't enable tips, i.e. didn't add the `TipDecorator` in its posthandler. Since: cosmos-sdk 0.46 type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of the tip tipper: type: string title: tipper is the address of the account paying for the tip description: >- AuthInfo describes the fee and signer modes that are used to sign a transaction. signatures: type: array items: type: string format: byte description: >- signatures is a list of signatures that matches the length and order of AuthInfo's signer_infos to allow connecting signature meta information like public key and signing mode by position. description: |- TxEncodeRequest is the request type for the Service.TxEncode RPC method. Since: cosmos-sdk 0.47 required: true tags: - gRPC Gateway API /cosmos/tx/v1beta1/encode/amino: post: summary: TxEncodeAmino encodes an Amino transaction from JSON to encoded bytes. description: "Since: cosmos-sdk 0.47" operationId: TxEncodeAmino_4NFNG responses: "200": description: A successful response. content: application/json: schema: type: object properties: amino_binary: type: string format: byte description: >- TxEncodeAminoResponse is the response type for the Service.TxEncodeAmino RPC method. Since: cosmos-sdk 0.47 default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte requestBody: content: application/json: schema: type: object properties: amino_json: type: string description: >- TxEncodeAminoRequest is the request type for the Service.TxEncodeAmino RPC method. Since: cosmos-sdk 0.47 required: true tags: - gRPC Gateway API /cosmos/tx/v1beta1/simulate: post: summary: Simulate simulates executing a transaction for estimating gas usage. operationId: Simulate_UY2GZ responses: "200": description: A successful response. content: application/json: schema: type: object properties: gas_info: description: gas_info is the information about gas used in the simulation. type: object properties: gas_wanted: type: string format: uint64 description: GasWanted is the maximum units of work we allow this tx to perform. gas_used: type: string format: uint64 description: GasUsed is the amount of gas actually consumed. result: description: result is the result of the simulation. type: object properties: data: type: string format: byte description: >- Data is any data returned from message or handler execution. It MUST be length prefixed in order to separate data from multiple message executions. Deprecated. This field is still populated, but prefer msg_response instead because it also contains the Msg response typeURL. log: type: string description: Log contains the log information from message or handler execution. events: type: array items: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string index: type: boolean description: EventAttribute is a single key-value pair, associated with an event. description: >- Event allows application developers to attach additional information to ResponseBeginBlock, ResponseEndBlock, ResponseCheckTx and ResponseDeliverTx. Later, transactions may be queried using these events. description: >- Events contains a slice of Event objects that were emitted during message or handler execution. msg_responses: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- msg_responses contains the Msg handler responses type packed in Anys. Since: cosmos-sdk 0.46 description: |- SimulateResponse is the response type for the Service.SimulateRPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte requestBody: content: application/json: schema: type: object properties: tx: description: |- tx is the transaction to simulate. Deprecated. Send raw tx bytes instead. type: object properties: body: title: body is the processable content of the transaction type: object properties: messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- messages is a list of messages to be executed. The required signers of those messages define the number and order of elements in AuthInfo's signer_infos and Tx's signatures. Each required signer address is added to the list only the first time it occurs. By convention, the first required signer (usually from the first message) is referred to as the primary signer and pays the fee for the whole transaction. memo: type: string description: >- memo is any arbitrary note/comment to be added to the transaction. WARNING: in clients, any publicly exposed text should not be called memo, but should be called `note` instead (see https://github.com/cosmos/cosmos-sdk/issues/9122). timeout_height: type: string format: uint64 title: >- timeout is the block height after which this transaction will not be processed by the chain extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, the transaction will be rejected non_critical_extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, they will be ignored description: TxBody is the body of a transaction that all signers sign over. auth_info: title: >- auth_info is the authorization related content of the transaction, specifically signers, signer modes and fee type: object properties: signer_infos: type: array items: type: object properties: public_key: type: object properties: type_url: type: string value: type: string format: byte description: >- public_key is the public key of the signer. It is optional for accounts that already exist in state. If unset, the verifier can use the required \ signer address for this position and lookup the public key. mode_info: title: >- mode_info describes the signing mode of the signer and is a nested structure to support nested multisig pubkey's type: object properties: single: title: single represents a single signer type: object properties: mode: title: mode is the signing mode of the single signer type: string enum: - SIGN_MODE_UNSPECIFIED - SIGN_MODE_DIRECT - SIGN_MODE_TEXTUAL - SIGN_MODE_DIRECT_AUX - SIGN_MODE_LEGACY_AMINO_JSON - SIGN_MODE_EIP_191 default: SIGN_MODE_UNSPECIFIED description: >- SignMode represents a signing mode with its own security guarantees. This enum should be considered a registry of all known sign modes in the Cosmos ecosystem. Apps are not expected to support all known sign modes. Apps that would like to support custom sign modes are encouraged to open a small PR against this file to add a new case to this SignMode enum describing their sign mode so that different apps have a consistent version of this enum. - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be rejected. - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is verified with raw bytes from Tx. - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some human-readable textual representation on top of the binary representation from SIGN_MODE_DIRECT. It is currently not supported. - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses SignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not require signers signing over other signers' `signer_info`. It also allows for adding Tips in transactions. Since: cosmos-sdk 0.46 - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses Amino JSON and will be removed in the future. - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos SDK. Ref: https://eips.ethereum.org/EIPS/eip-191 Currently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant, but is not implemented on the SDK by default. To enable EIP-191, you need to pass a custom `TxConfig` that has an implementation of `SignModeHandler` for EIP-191. The SDK may decide to fully support EIP-191 in the future. Since: cosmos-sdk 0.45.2 multi: title: multi represents a nested multisig signer type: object properties: bitarray: title: bitarray specifies which keys within the multisig are signing type: object properties: extra_bits_stored: type: integer format: int64 elems: type: string format: byte description: >- CompactBitArray is an implementation of a space efficient bit array. This is used to ensure that the encoded data takes up a minimal amount of space after proto encoding. This is not thread safe, and is not intended for concurrent usage. mode_infos: type: array items: {} title: >- mode_infos is the corresponding modes of the signers of the multisig which could include nested multisig public keys description: ModeInfo describes the signing mode of a single or nested multisig signer. sequence: type: string format: uint64 description: >- sequence is the sequence of the account, which describes the number of committed transactions signed by a given address. It is used to prevent replay attacks. description: >- SignerInfo describes the public key and signing mode of a single top-level signer. description: >- signer_infos defines the signing modes for the required signers. The number and order of elements must match the required signers from TxBody's messages. The first element is the primary signer and the one which pays the fee. fee: description: >- Fee is the fee and gas limit for the transaction. The first signer is the primary signer and the one which pays the fee. The fee can be calculated based on the cost of evaluating the body and doing signature verification of the signers. This can be estimated via simulation. type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of coins to be paid as a fee gas_limit: type: string format: uint64 title: >- gas_limit is the maximum gas that can be used in transaction processing before an out of gas error occurs payer: type: string description: >- if unset, the first signer is responsible for paying the fees. If set, the specified account must pay the fees. the payer must be a tx signer (and thus have signed this field in AuthInfo). setting this field does *not* change the ordering of required signers for the transaction. granter: type: string title: >- if set, the fee payer (either the first signer or the value of the payer field) requests that a fee grant be used to pay fees instead of the fee payer's own balance. If an appropriate fee grant does not exist or the chain does not support fee grants, this will fail tip: description: >- Tip is the optional tip used for transactions fees paid in another denom. This field is ignored if the chain didn't enable tips, i.e. didn't add the `TipDecorator` in its posthandler. Since: cosmos-sdk 0.46 type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of the tip tipper: type: string title: tipper is the address of the account paying for the tip description: >- AuthInfo describes the fee and signer modes that are used to sign a transaction. signatures: type: array items: type: string format: byte description: >- signatures is a list of signatures that matches the length and order of AuthInfo's signer_infos to allow connecting signature meta information like public key and signing mode by position. tx_bytes: type: string format: byte description: |- tx_bytes is the raw transaction. Since: cosmos-sdk 0.43 description: |- SimulateRequest is the request type for the Service.Simulate RPC method. required: true tags: - gRPC Gateway API /cosmos/tx/v1beta1/txs: get: summary: GetTxsEvent fetches txs by event. operationId: GetTxsEvent_KWYMH responses: "200": description: A successful response. content: application/json: schema: type: object properties: txs: type: array items: type: object properties: body: title: body is the processable content of the transaction type: object properties: messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- messages is a list of messages to be executed. The required signers of those messages define the number and order of elements in AuthInfo's signer_infos and Tx's signatures. Each required signer address is added to the list only the first time it occurs. By convention, the first required signer (usually from the first message) is referred to as the primary signer and pays the fee for the whole transaction. memo: type: string description: >- memo is any arbitrary note/comment to be added to the transaction. WARNING: in clients, any publicly exposed text should not be called memo, but should be called `note` instead (see https://github.com/cosmos/cosmos-sdk/issues/9122). timeout_height: type: string format: uint64 title: >- timeout is the block height after which this transaction will not be processed by the chain extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, the transaction will be rejected non_critical_extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, they will be ignored description: TxBody is the body of a transaction that all signers sign over. auth_info: title: >- auth_info is the authorization related content of the transaction, specifically signers, signer modes and fee type: object properties: signer_infos: type: array items: type: object properties: public_key: type: object properties: type_url: type: string value: type: string format: byte description: >- public_key is the public key of the signer. It is optional for accounts that already exist in state. If unset, the verifier can use the required \ signer address for this position and lookup the public key. mode_info: title: >- mode_info describes the signing mode of the signer and is a nested structure to support nested multisig pubkey's type: object properties: single: title: single represents a single signer type: object properties: mode: title: mode is the signing mode of the single signer type: string enum: - SIGN_MODE_UNSPECIFIED - SIGN_MODE_DIRECT - SIGN_MODE_TEXTUAL - SIGN_MODE_DIRECT_AUX - SIGN_MODE_LEGACY_AMINO_JSON - SIGN_MODE_EIP_191 default: SIGN_MODE_UNSPECIFIED description: >- SignMode represents a signing mode with its own security guarantees. This enum should be considered a registry of all known sign modes in the Cosmos ecosystem. Apps are not expected to support all known sign modes. Apps that would like to support custom sign modes are encouraged to open a small PR against this file to add a new case to this SignMode enum describing their sign mode so that different apps have a consistent version of this enum. - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be rejected. - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is verified with raw bytes from Tx. - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some human-readable textual representation on top of the binary representation from SIGN_MODE_DIRECT. It is currently not supported. - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses SignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not require signers signing over other signers' `signer_info`. It also allows for adding Tips in transactions. Since: cosmos-sdk 0.46 - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses Amino JSON and will be removed in the future. - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos SDK. Ref: https://eips.ethereum.org/EIPS/eip-191 Currently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant, but is not implemented on the SDK by default. To enable EIP-191, you need to pass a custom `TxConfig` that has an implementation of `SignModeHandler` for EIP-191. The SDK may decide to fully support EIP-191 in the future. Since: cosmos-sdk 0.45.2 multi: title: multi represents a nested multisig signer type: object properties: bitarray: title: bitarray specifies which keys within the multisig are signing type: object properties: extra_bits_stored: type: integer format: int64 elems: type: string format: byte description: >- CompactBitArray is an implementation of a space efficient bit array. This is used to ensure that the encoded data takes up a minimal amount of space after proto encoding. This is not thread safe, and is not intended for concurrent usage. mode_infos: type: array items: {} title: >- mode_infos is the corresponding modes of the signers of the multisig which could include nested multisig public keys description: ModeInfo describes the signing mode of a single or nested multisig signer. sequence: type: string format: uint64 description: >- sequence is the sequence of the account, which describes the number of committed transactions signed by a given address. It is used to prevent replay attacks. description: >- SignerInfo describes the public key and signing mode of a single top-level signer. description: >- signer_infos defines the signing modes for the required signers. The number and order of elements must match the required signers from TxBody's messages. The first element is the primary signer and the one which pays the fee. fee: description: >- Fee is the fee and gas limit for the transaction. The first signer is the primary signer and the one which pays the fee. The fee can be calculated based on the cost of evaluating the body and doing signature verification of the signers. This can be estimated via simulation. type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of coins to be paid as a fee gas_limit: type: string format: uint64 title: >- gas_limit is the maximum gas that can be used in transaction processing before an out of gas error occurs payer: type: string description: >- if unset, the first signer is responsible for paying the fees. If set, the specified account must pay the fees. the payer must be a tx signer (and thus have signed this field in AuthInfo). setting this field does *not* change the ordering of required signers for the transaction. granter: type: string title: >- if set, the fee payer (either the first signer or the value of the payer field) requests that a fee grant be used to pay fees instead of the fee payer's own balance. If an appropriate fee grant does not exist or the chain does not support fee grants, this will fail tip: description: >- Tip is the optional tip used for transactions fees paid in another denom. This field is ignored if the chain didn't enable tips, i.e. didn't add the `TipDecorator` in its posthandler. Since: cosmos-sdk 0.46 type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of the tip tipper: type: string title: tipper is the address of the account paying for the tip description: >- AuthInfo describes the fee and signer modes that are used to sign a transaction. signatures: type: array items: type: string format: byte description: >- signatures is a list of signatures that matches the length and order of AuthInfo's signer_infos to allow connecting signature meta information like public key and signing mode by position. description: Tx is the standard type used for broadcasting transactions. description: txs is the list of queried transactions. tx_responses: type: array items: type: object properties: height: type: string format: int64 title: The block height txhash: type: string description: The transaction hash. codespace: type: string title: Namespace for the Code code: type: integer format: int64 description: Response code. data: type: string description: Result bytes, if any. raw_log: type: string description: >- The output of the application's logger (raw string). May be non-deterministic. logs: type: array items: type: object properties: msg_index: type: integer format: int64 log: type: string events: type: array items: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string description: >- Attribute defines an attribute wrapper where the key and value are strings instead of raw bytes. description: >- StringEvent defines en Event object wrapper where all the attributes contain key/value pairs that are strings instead of raw bytes. description: >- Events contains a slice of Event objects that were emitted during some execution. description: ABCIMessageLog defines a structure containing an indexed tx ABCI message log. description: The output of the application's logger (typed). May be non-deterministic. info: type: string description: Additional information. May be non-deterministic. gas_wanted: type: string format: int64 description: Amount of gas requested for transaction. gas_used: type: string format: int64 description: Amount of gas consumed by transaction. tx: type: object properties: type_url: type: string value: type: string format: byte description: The request transaction bytes. timestamp: type: string description: >- Time of the previous block. For heights > 1, it's the weighted median of the timestamps of the valid votes in the block.LastCommit. For height == 1, it's genesis time. events: type: array items: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string index: type: boolean description: EventAttribute is a single key-value pair, associated with an event. description: >- Event allows application developers to attach additional information to ResponseBeginBlock, ResponseEndBlock, ResponseCheckTx and ResponseDeliverTx. Later, transactions may be queried using these events. description: >- Events defines all the events emitted by processing a transaction. Note, these events include those emitted by processing all the messages and those emitted from the ante. Whereas Logs contains the events, with additional metadata, emitted only by processing the messages. Since: cosmos-sdk 0.42.11, 0.44.5, 0.45 description: >- TxResponse defines a structure containing relevant tx data and metadata. The tags are stringified and the log is JSON decoded. description: tx_responses is the list of queried TxResponses. pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } total: type: string format: uint64 title: total is total number of results available description: >- GetTxsEventResponse is the response type for the Service.TxsByEvents RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: events description: events is the list of transaction event type. in: query required: false explode: true schema: type: array items: type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean - name: order_by description: >-2 - ORDER_BY_UNSPECIFIED: ORDER_BY_UNSPECIFIED specifies an unknown sorting order. OrderBy defaults to ASC in this case. - ORDER_BY_ASC: ORDER_BY_ASC defines ascending order - ORDER_BY_DESC: ORDER_BY_DESC defines descending order in: query required: false schema: type: string enum: - ORDER_BY_UNSPECIFIED - ORDER_BY_ASC - ORDER_BY_DESC default: ORDER_BY_UNSPECIFIED - name: page description: page is the page number to query, starts at 1. If not provided, will default to first page. in: query required: false schema: type: string format: uint64 - name: limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 tags: - gRPC Gateway API post: summary: BroadcastTx broadcast transaction. operationId: BroadcastTx_N4T1X responses: "200": description: A successful response. content: application/json: schema: type: object properties: tx_response: type: object properties: height: type: string format: int64 title: The block height txhash: type: string description: The transaction hash. codespace: type: string title: Namespace for the Code code: type: integer format: int64 description: Response code. data: type: string description: Result bytes, if any. raw_log: type: string description: >- The output of the application's logger (raw string). May be non-deterministic. logs: type: array items: type: object properties: msg_index: type: integer format: int64 log: type: string events: type: array items: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string description: >- Attribute defines an attribute wrapper where the key and value are strings instead of raw bytes. description: >- StringEvent defines en Event object wrapper where all the attributes contain key/value pairs that are strings instead of raw bytes. description: >- Events contains a slice of Event objects that were emitted during some execution. description: ABCIMessageLog defines a structure containing an indexed tx ABCI message log. description: The output of the application's logger (typed). May be non-deterministic. info: type: string description: Additional information. May be non-deterministic. gas_wanted: type: string format: int64 description: Amount of gas requested for transaction. gas_used: type: string format: int64 description: Amount of gas consumed by transaction. tx: type: object properties: type_url: type: string value: type: string format: byte description: The request transaction bytes. timestamp: type: string description: >- Time of the previous block. For heights > 1, it's the weighted median of the timestamps of the valid votes in the block.LastCommit. For height == 1, it's genesis time. events: type: array items: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string index: type: boolean description: EventAttribute is a single key-value pair, associated with an event. description: >- Event allows application developers to attach additional information to ResponseBeginBlock, ResponseEndBlock, ResponseCheckTx and ResponseDeliverTx. Later, transactions may be queried using these events. description: >- Events defines all the events emitted by processing a transaction. Note, these events include those emitted by processing all the messages and those emitted from the ante. Whereas Logs contains the events, with additional metadata, emitted only by processing the messages. Since: cosmos-sdk 0.42.11, 0.44.5, 0.45 description: >- TxResponse defines a structure containing relevant tx data and metadata. The tags are stringified and the log is JSON decoded. description: |- BroadcastTxResponse is the response type for the Service.BroadcastTx method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte requestBody: content: application/json: schema: type: object properties: tx_bytes: type: string format: byte description: tx_bytes is the raw transaction. mode: type: string enum: - BROADCAST_MODE_UNSPECIFIED - BROADCAST_MODE_BLOCK - BROADCAST_MODE_SYNC - BROADCAST_MODE_ASYNC default: BROADCAST_MODE_UNSPECIFIED description: >- BroadcastMode specifies the broadcast mode for the TxService.Broadcast RPC method. - BROADCAST_MODE_UNSPECIFIED: zero-value for mode ordering - BROADCAST_MODE_BLOCK: DEPRECATED: use BROADCAST_MODE_SYNC instead, BROADCAST_MODE_BLOCK is not supported by the SDK from v0.47.x onwards. - BROADCAST_MODE_SYNC: BROADCAST_MODE_SYNC defines a tx broadcasting mode where the client waits for a CheckTx execution response only. - BROADCAST_MODE_ASYNC: BROADCAST_MODE_ASYNC defines a tx broadcasting mode where the client returns immediately. description: >- BroadcastTxRequest is the request type for the Service.BroadcastTxRequest RPC method. required: true tags: - gRPC Gateway API "/cosmos/tx/v1beta1/txs/block/{height}": get: summary: GetBlockWithTxs fetches a block with decoded txs. description: "Since: cosmos-sdk 0.45.2" operationId: GetBlockWithTxs_1EZ44 responses: "200": description: A successful response. content: application/json: schema: type: object properties: txs: type: array items: type: object properties: body: title: body is the processable content of the transaction type: object properties: messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- messages is a list of messages to be executed. The required signers of those messages define the number and order of elements in AuthInfo's signer_infos and Tx's signatures. Each required signer address is added to the list only the first time it occurs. By convention, the first required signer (usually from the first message) is referred to as the primary signer and pays the fee for the whole transaction. memo: type: string description: >- memo is any arbitrary note/comment to be added to the transaction. WARNING: in clients, any publicly exposed text should not be called memo, but should be called `note` instead (see https://github.com/cosmos/cosmos-sdk/issues/9122). timeout_height: type: string format: uint64 title: >- timeout is the block height after which this transaction will not be processed by the chain extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, the transaction will be rejected non_critical_extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, they will be ignored description: TxBody is the body of a transaction that all signers sign over. auth_info: title: >- auth_info is the authorization related content of the transaction, specifically signers, signer modes and fee type: object properties: signer_infos: type: array items: type: object properties: public_key: type: object properties: type_url: type: string value: type: string format: byte description: >- public_key is the public key of the signer. It is optional for accounts that already exist in state. If unset, the verifier can use the required \ signer address for this position and lookup the public key. mode_info: title: >- mode_info describes the signing mode of the signer and is a nested structure to support nested multisig pubkey's type: object properties: single: title: single represents a single signer type: object properties: mode: title: mode is the signing mode of the single signer type: string enum: - SIGN_MODE_UNSPECIFIED - SIGN_MODE_DIRECT - SIGN_MODE_TEXTUAL - SIGN_MODE_DIRECT_AUX - SIGN_MODE_LEGACY_AMINO_JSON - SIGN_MODE_EIP_191 default: SIGN_MODE_UNSPECIFIED description: >- SignMode represents a signing mode with its own security guarantees. This enum should be considered a registry of all known sign modes in the Cosmos ecosystem. Apps are not expected to support all known sign modes. Apps that would like to support custom sign modes are encouraged to open a small PR against this file to add a new case to this SignMode enum describing their sign mode so that different apps have a consistent version of this enum. - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be rejected. - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is verified with raw bytes from Tx. - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some human-readable textual representation on top of the binary representation from SIGN_MODE_DIRECT. It is currently not supported. - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses SignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not require signers signing over other signers' `signer_info`. It also allows for adding Tips in transactions. Since: cosmos-sdk 0.46 - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses Amino JSON and will be removed in the future. - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos SDK. Ref: https://eips.ethereum.org/EIPS/eip-191 Currently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant, but is not implemented on the SDK by default. To enable EIP-191, you need to pass a custom `TxConfig` that has an implementation of `SignModeHandler` for EIP-191. The SDK may decide to fully support EIP-191 in the future. Since: cosmos-sdk 0.45.2 multi: title: multi represents a nested multisig signer type: object properties: bitarray: title: bitarray specifies which keys within the multisig are signing type: object properties: extra_bits_stored: type: integer format: int64 elems: type: string format: byte description: >- CompactBitArray is an implementation of a space efficient bit array. This is used to ensure that the encoded data takes up a minimal amount of space after proto encoding. This is not thread safe, and is not intended for concurrent usage. mode_infos: type: array items: {} title: >- mode_infos is the corresponding modes of the signers of the multisig which could include nested multisig public keys description: ModeInfo describes the signing mode of a single or nested multisig signer. sequence: type: string format: uint64 description: >- sequence is the sequence of the account, which describes the number of committed transactions signed by a given address. It is used to prevent replay attacks. description: >- SignerInfo describes the public key and signing mode of a single top-level signer. description: >- signer_infos defines the signing modes for the required signers. The number and order of elements must match the required signers from TxBody's messages. The first element is the primary signer and the one which pays the fee. fee: description: >- Fee is the fee and gas limit for the transaction. The first signer is the primary signer and the one which pays the fee. The fee can be calculated based on the cost of evaluating the body and doing signature verification of the signers. This can be estimated via simulation. type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of coins to be paid as a fee gas_limit: type: string format: uint64 title: >- gas_limit is the maximum gas that can be used in transaction processing before an out of gas error occurs payer: type: string description: >- if unset, the first signer is responsible for paying the fees. If set, the specified account must pay the fees. the payer must be a tx signer (and thus have signed this field in AuthInfo). setting this field does *not* change the ordering of required signers for the transaction. granter: type: string title: >- if set, the fee payer (either the first signer or the value of the payer field) requests that a fee grant be used to pay fees instead of the fee payer's own balance. If an appropriate fee grant does not exist or the chain does not support fee grants, this will fail tip: description: >- Tip is the optional tip used for transactions fees paid in another denom. This field is ignored if the chain didn't enable tips, i.e. didn't add the `TipDecorator` in its posthandler. Since: cosmos-sdk 0.46 type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of the tip tipper: type: string title: tipper is the address of the account paying for the tip description: >- AuthInfo describes the fee and signer modes that are used to sign a transaction. signatures: type: array items: type: string format: byte description: >- signatures is a list of signatures that matches the length and order of AuthInfo's signer_infos to allow connecting signature meta information like public key and signing mode by position. description: Tx is the standard type used for broadcasting transactions. description: txs are the transactions in the block. block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID block: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. data: type: object properties: txs: type: array items: type: string format: byte description: >- Txs that will be applied by state @ block.Height+1. NOTE: not all txs here are valid. We're just agreeing on the order first. This means that block.AppHash does not include these txs. title: Data contains the set of transactions included in the block evidence: type: object properties: evidence: type: array items: type: object properties: duplicate_vote_evidence: type: object properties: vote_a: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. vote_b: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. total_voting_power: type: string format: int64 validator_power: type: string format: int64 timestamp: type: string format: date-time description: DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes. light_client_attack_evidence: type: object properties: conflicting_block: type: object properties: signed_header: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: Commit contains the evidence that a block was committed by a set of validators. validator_set: type: object properties: validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 proposer: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 common_height: type: string format: int64 byzantine_validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 timestamp: type: string format: date-time description: LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client. last_commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: Commit contains the evidence that a block was committed by a set of validators. pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- GetBlockWithTxsResponse is the response type for the Service.GetBlockWithTxs method. Since: cosmos-sdk 0.45.2 default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: height description: height is the height of the block to query. in: path required: true schema: type: string format: int64 - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/cosmos/tx/v1beta1/txs/{hash}": get: summary: GetTx fetches a tx by hash. operationId: GetTx_71CB4 responses: "200": description: A successful response. content: application/json: schema: type: object properties: tx: type: object properties: body: title: body is the processable content of the transaction type: object properties: messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- messages is a list of messages to be executed. The required signers of those messages define the number and order of elements in AuthInfo's signer_infos and Tx's signatures. Each required signer address is added to the list only the first time it occurs. By convention, the first required signer (usually from the first message) is referred to as the primary signer and pays the fee for the whole transaction. memo: type: string description: >- memo is any arbitrary note/comment to be added to the transaction. WARNING: in clients, any publicly exposed text should not be called memo, but should be called `note` instead (see https://github.com/cosmos/cosmos-sdk/issues/9122). timeout_height: type: string format: uint64 title: >- timeout is the block height after which this transaction will not be processed by the chain extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, the transaction will be rejected non_critical_extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, they will be ignored description: TxBody is the body of a transaction that all signers sign over. auth_info: title: >- auth_info is the authorization related content of the transaction, specifically signers, signer modes and fee type: object properties: signer_infos: type: array items: type: object properties: public_key: type: object properties: type_url: type: string value: type: string format: byte description: >- public_key is the public key of the signer. It is optional for accounts that already exist in state. If unset, the verifier can use the required \ signer address for this position and lookup the public key. mode_info: title: >- mode_info describes the signing mode of the signer and is a nested structure to support nested multisig pubkey's type: object properties: single: title: single represents a single signer type: object properties: mode: title: mode is the signing mode of the single signer type: string enum: - SIGN_MODE_UNSPECIFIED - SIGN_MODE_DIRECT - SIGN_MODE_TEXTUAL - SIGN_MODE_DIRECT_AUX - SIGN_MODE_LEGACY_AMINO_JSON - SIGN_MODE_EIP_191 default: SIGN_MODE_UNSPECIFIED description: >- SignMode represents a signing mode with its own security guarantees. This enum should be considered a registry of all known sign modes in the Cosmos ecosystem. Apps are not expected to support all known sign modes. Apps that would like to support custom sign modes are encouraged to open a small PR against this file to add a new case to this SignMode enum describing their sign mode so that different apps have a consistent version of this enum. - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be rejected. - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is verified with raw bytes from Tx. - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some human-readable textual representation on top of the binary representation from SIGN_MODE_DIRECT. It is currently not supported. - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses SignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not require signers signing over other signers' `signer_info`. It also allows for adding Tips in transactions. Since: cosmos-sdk 0.46 - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses Amino JSON and will be removed in the future. - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos SDK. Ref: https://eips.ethereum.org/EIPS/eip-191 Currently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant, but is not implemented on the SDK by default. To enable EIP-191, you need to pass a custom `TxConfig` that has an implementation of `SignModeHandler` for EIP-191. The SDK may decide to fully support EIP-191 in the future. Since: cosmos-sdk 0.45.2 multi: title: multi represents a nested multisig signer type: object properties: bitarray: title: bitarray specifies which keys within the multisig are signing type: object properties: extra_bits_stored: type: integer format: int64 elems: type: string format: byte description: >- CompactBitArray is an implementation of a space efficient bit array. This is used to ensure that the encoded data takes up a minimal amount of space after proto encoding. This is not thread safe, and is not intended for concurrent usage. mode_infos: type: array items: {} title: >- mode_infos is the corresponding modes of the signers of the multisig which could include nested multisig public keys description: ModeInfo describes the signing mode of a single or nested multisig signer. sequence: type: string format: uint64 description: >- sequence is the sequence of the account, which describes the number of committed transactions signed by a given address. It is used to prevent replay attacks. description: >- SignerInfo describes the public key and signing mode of a single top-level signer. description: >- signer_infos defines the signing modes for the required signers. The number and order of elements must match the required signers from TxBody's messages. The first element is the primary signer and the one which pays the fee. fee: description: >- Fee is the fee and gas limit for the transaction. The first signer is the primary signer and the one which pays the fee. The fee can be calculated based on the cost of evaluating the body and doing signature verification of the signers. This can be estimated via simulation. type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of coins to be paid as a fee gas_limit: type: string format: uint64 title: >- gas_limit is the maximum gas that can be used in transaction processing before an out of gas error occurs payer: type: string description: >- if unset, the first signer is responsible for paying the fees. If set, the specified account must pay the fees. the payer must be a tx signer (and thus have signed this field in AuthInfo). setting this field does *not* change the ordering of required signers for the transaction. granter: type: string title: >- if set, the fee payer (either the first signer or the value of the payer field) requests that a fee grant be used to pay fees instead of the fee payer's own balance. If an appropriate fee grant does not exist or the chain does not support fee grants, this will fail tip: description: >- Tip is the optional tip used for transactions fees paid in another denom. This field is ignored if the chain didn't enable tips, i.e. didn't add the `TipDecorator` in its posthandler. Since: cosmos-sdk 0.46 type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of the tip tipper: type: string title: tipper is the address of the account paying for the tip description: >- AuthInfo describes the fee and signer modes that are used to sign a transaction. signatures: type: array items: type: string format: byte description: >- signatures is a list of signatures that matches the length and order of AuthInfo's signer_infos to allow connecting signature meta information like public key and signing mode by position. description: Tx is the standard type used for broadcasting transactions. tx_response: type: object properties: height: type: string format: int64 title: The block height txhash: type: string description: The transaction hash. codespace: type: string title: Namespace for the Code code: type: integer format: int64 description: Response code. data: type: string description: Result bytes, if any. raw_log: type: string description: >- The output of the application's logger (raw string). May be non-deterministic. logs: type: array items: type: object properties: msg_index: type: integer format: int64 log: type: string events: type: array items: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string description: >- Attribute defines an attribute wrapper where the key and value are strings instead of raw bytes. description: >- StringEvent defines en Event object wrapper where all the attributes contain key/value pairs that are strings instead of raw bytes. description: >- Events contains a slice of Event objects that were emitted during some execution. description: ABCIMessageLog defines a structure containing an indexed tx ABCI message log. description: The output of the application's logger (typed). May be non-deterministic. info: type: string description: Additional information. May be non-deterministic. gas_wanted: type: string format: int64 description: Amount of gas requested for transaction. gas_used: type: string format: int64 description: Amount of gas consumed by transaction. tx: type: object properties: type_url: type: string value: type: string format: byte description: The request transaction bytes. timestamp: type: string description: >- Time of the previous block. For heights > 1, it's the weighted median of the timestamps of the valid votes in the block.LastCommit. For height == 1, it's genesis time. events: type: array items: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string index: type: boolean description: EventAttribute is a single key-value pair, associated with an event. description: >- Event allows application developers to attach additional information to ResponseBeginBlock, ResponseEndBlock, ResponseCheckTx and ResponseDeliverTx. Later, transactions may be queried using these events. description: >- Events defines all the events emitted by processing a transaction. Note, these events include those emitted by processing all the messages and those emitted from the ante. Whereas Logs contains the events, with additional metadata, emitted only by processing the messages. Since: cosmos-sdk 0.42.11, 0.44.5, 0.45 description: >- TxResponse defines a structure containing relevant tx data and metadata. The tags are stringified and the log is JSON decoded. description: GetTxResponse is the response type for the Service.GetTx method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: hash description: hash is the tx hash to query, encoded as a hex string. in: path required: true schema: type: string tags: - gRPC Gateway API /cyber/clock/v1/contracts: get: summary: ClockContracts operationId: ClockContracts_R3OXP responses: "200": description: A successful response. content: application/json: schema: type: object properties: clock_contracts: type: array items: type: object properties: contract_address: type: string description: The address of the contract. is_jailed: type: boolean description: The jail status of the contract. description: >- This object is used to store the contract address and the jail status of the contract. description: clock_contracts are the clock contracts. pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- QueryClockContractsResponse is the response type for the Query/ClockContracts RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/cyber/clock/v1/contracts/{contract_address}": get: summary: ClockContract operationId: ClockContract_U8RUX responses: "200": description: A successful response. content: application/json: schema: type: object properties: clock_contract: type: object properties: contract_address: type: string description: The address of the contract. is_jailed: type: boolean description: The jail status of the contract. description: |- This object is used to store the contract address and the jail status of the contract. description: >- QueryClockContractResponse is the response type for the Query/ClockContract RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: contract_address description: contract_address is the address of the contract to query. in: path required: true schema: type: string tags: - gRPC Gateway API /cyber/clock/v1/params: get: summary: Params operationId: Params_7NU4D responses: "200": description: A successful response. content: application/json: schema: type: object properties: params: type: object properties: contract_gas_limit: type: string format: uint64 description: >- contract_gas_limit defines the maximum amount of gas that can be used by a contract. description: Params defines the set of module parameters. description: >- QueryClockContractsResponse is the response type for the Query/ClockContracts RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /ibc/core/channel/v1/channels: get: summary: Channels queries all the IBC channels of a chain. operationId: Channels_XUUVY responses: "200": description: A successful response. content: application/json: schema: type: object properties: channels: type: array items: type: object properties: state: title: current state of the channel end type: string enum: - STATE_UNINITIALIZED_UNSPECIFIED - STATE_INIT - STATE_TRYOPEN - STATE_OPEN - STATE_CLOSED default: STATE_UNINITIALIZED_UNSPECIFIED description: >- State defines if a channel is in one of the following states: CLOSED, INIT, TRYOPEN, OPEN or UNINITIALIZED. - STATE_UNINITIALIZED_UNSPECIFIED: Default State - STATE_INIT: A channel has just started the opening handshake. - STATE_TRYOPEN: A channel has acknowledged the handshake step on the counterparty chain. - STATE_OPEN: A channel has completed the handshake. Open channels are ready to send and receive packets. - STATE_CLOSED: A channel has been closed and can no longer be used to send or receive packets. ordering: title: whether the channel is ordered or unordered type: string enum: - ORDER_NONE_UNSPECIFIED - ORDER_UNORDERED - ORDER_ORDERED default: ORDER_NONE_UNSPECIFIED description: >- - ORDER_NONE_UNSPECIFIED: zero-value for channel ordering - ORDER_UNORDERED: packets can be delivered in any order, which may differ from the order in which they were sent. - ORDER_ORDERED: packets are delivered exactly in the order which they were sent counterparty: title: counterparty channel end type: object properties: port_id: type: string description: port on the counterparty chain which owns the other end of the channel. channel_id: type: string title: channel end on the counterparty chain connection_hops: type: array items: type: string title: >- list of connection identifiers, in order, along which packets sent on this channel will travel version: type: string title: opaque channel version, which is agreed upon during the handshake port_id: type: string title: port identifier channel_id: type: string title: channel identifier description: >- IdentifiedChannel defines a channel with additional port and channel identifier fields. description: list of stored channels of the chain. pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: pagination response height: title: query block height type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset description: QueryChannelsResponse is the response type for the Query/Channels RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/ibc/core/channel/v1/channels/{channel_id}/ports/{port_id}": get: summary: Channel queries an IBC Channel. operationId: Channel_ENVYK responses: "200": description: A successful response. content: application/json: schema: type: object properties: channel: title: channel associated with the request identifiers type: object properties: state: title: current state of the channel end type: string enum: - STATE_UNINITIALIZED_UNSPECIFIED - STATE_INIT - STATE_TRYOPEN - STATE_OPEN - STATE_CLOSED default: STATE_UNINITIALIZED_UNSPECIFIED description: >- State defines if a channel is in one of the following states: CLOSED, INIT, TRYOPEN, OPEN or UNINITIALIZED. - STATE_UNINITIALIZED_UNSPECIFIED: Default State - STATE_INIT: A channel has just started the opening handshake. - STATE_TRYOPEN: A channel has acknowledged the handshake step on the counterparty chain. - STATE_OPEN: A channel has completed the handshake. Open channels are ready to send and receive packets. - STATE_CLOSED: A channel has been closed and can no longer be used to send or receive packets. ordering: title: whether the channel is ordered or unordered type: string enum: - ORDER_NONE_UNSPECIFIED - ORDER_UNORDERED - ORDER_ORDERED default: ORDER_NONE_UNSPECIFIED description: >- - ORDER_NONE_UNSPECIFIED: zero-value for channel ordering - ORDER_UNORDERED: packets can be delivered in any order, which may differ from the order in which they were sent. - ORDER_ORDERED: packets are delivered exactly in the order which they were sent counterparty: title: counterparty channel end type: object properties: port_id: type: string description: port on the counterparty chain which owns the other end of the channel. channel_id: type: string title: channel end on the counterparty chain connection_hops: type: array items: type: string title: >- list of connection identifiers, in order, along which packets sent on this channel will travel version: type: string title: opaque channel version, which is agreed upon during the handshake description: >- Channel defines pipeline for exactly-once packet delivery between specific modules on separate blockchains, which has at least one end capable of sending packets and one end capable of receiving packets. proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset description: >- QueryChannelResponse is the response type for the Query/Channel RPC method. Besides the Channel end, it includes a proof and the height from which the proof was retrieved. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: channel_id description: channel unique identifier in: path required: true schema: type: string - name: port_id description: port unique identifier in: path required: true schema: type: string tags: - gRPC Gateway API "/ibc/core/channel/v1/channels/{channel_id}/ports/{port_id}/client_state": get: summary: >- ChannelClientState queries for the client state for the channel associated with the provided channel identifiers. operationId: ChannelClientState_928AQ responses: "200": description: A successful response. content: application/json: schema: type: object properties: identified_client_state: title: client state associated with the channel type: object properties: client_id: type: string title: client identifier client_state: type: object properties: type_url: type: string value: type: string format: byte title: client state description: >- IdentifiedClientState defines a client state with an additional client identifier field. proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryChannelClientStateResponse is the Response type for the Query/QueryChannelClientState RPC method default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: channel_id description: channel unique identifier in: path required: true schema: type: string - name: port_id description: port unique identifier in: path required: true schema: type: string tags: - gRPC Gateway API "/ibc/core/channel/v1/channels/{channel_id}/ports/{port_id}/consensus_state/revision/{revision_number}/height/{revision_height}": get: summary: |- ChannelConsensusState queries for the consensus state for the channel associated with the provided channel identifiers. operationId: ChannelConsensusState_TYNC0 responses: "200": description: A successful response. content: application/json: schema: type: object properties: consensus_state: type: object properties: type_url: type: string value: type: string format: byte title: consensus state associated with the channel client_id: type: string title: client ID associated with the consensus state proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryChannelClientStateResponse is the Response type for the Query/QueryChannelClientState RPC method default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: channel_id description: channel unique identifier in: path required: true schema: type: string - name: port_id description: port unique identifier in: path required: true schema: type: string - name: revision_number description: revision number of the consensus state in: path required: true schema: type: string format: uint64 - name: revision_height description: revision height of the consensus state in: path required: true schema: type: string format: uint64 tags: - gRPC Gateway API "/ibc/core/channel/v1/channels/{channel_id}/ports/{port_id}/next_sequence": get: summary: NextSequenceReceive returns the next receive sequence for a given channel. operationId: NextSequenceReceive_GMBZC responses: "200": description: A successful response. content: application/json: schema: type: object properties: next_sequence_receive: type: string format: uint64 title: next sequence receive number proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QuerySequenceResponse is the request type for the Query/QueryNextSequenceReceiveResponse RPC method default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: channel_id description: channel unique identifier in: path required: true schema: type: string - name: port_id description: port unique identifier in: path required: true schema: type: string tags: - gRPC Gateway API "/ibc/core/channel/v1/channels/{channel_id}/ports/{port_id}/packet_acknowledgements": get: summary: >- PacketAcknowledgements returns all the packet acknowledgements associated with a channel. operationId: PacketAcknowledgements_L275E responses: "200": description: A successful response. content: application/json: schema: type: object properties: acknowledgements: type: array items: type: object properties: port_id: type: string description: channel port identifier. channel_id: type: string description: channel unique identifier. sequence: type: string format: uint64 description: packet sequence. data: type: string format: byte description: embedded data that represents packet state. description: >- PacketState defines the generic type necessary to retrieve and store packet commitments, acknowledgements, and receipts. Caller is responsible for knowing the context necessary to interpret this state as a commitment, acknowledgement, or a receipt. pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: pagination response height: title: query block height type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryPacketAcknowledgemetsResponse is the request type for the Query/QueryPacketAcknowledgements RPC method default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: channel_id description: channel unique identifier in: path required: true schema: type: string - name: port_id description: port unique identifier in: path required: true schema: type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean - name: packet_commitment_sequences description: list of packet sequences. in: query required: false explode: true schema: type: array items: type: string format: uint64 tags: - gRPC Gateway API "/ibc/core/channel/v1/channels/{channel_id}/ports/{port_id}/packet_acks/{sequence}": get: summary: PacketAcknowledgement queries a stored packet acknowledgement hash. operationId: PacketAcknowledgement_ZZJJ8 responses: "200": description: A successful response. content: application/json: schema: type: object properties: acknowledgement: type: string format: byte title: packet associated with the request fields proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: >- QueryPacketAcknowledgementResponse defines the client query response for a packet which also includes a proof and the height from which the proof was retrieved default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: channel_id description: channel unique identifier in: path required: true schema: type: string - name: port_id description: port unique identifier in: path required: true schema: type: string - name: sequence description: packet sequence in: path required: true schema: type: string format: uint64 tags: - gRPC Gateway API "/ibc/core/channel/v1/channels/{channel_id}/ports/{port_id}/packet_commitments": get: summary: |- PacketCommitments returns all the packet commitments hashes associated with a channel. operationId: PacketCommitments_LZDD2 responses: "200": description: A successful response. content: application/json: schema: type: object properties: commitments: type: array items: type: object properties: port_id: type: string description: channel port identifier. channel_id: type: string description: channel unique identifier. sequence: type: string format: uint64 description: packet sequence. data: type: string format: byte description: embedded data that represents packet state. description: >- PacketState defines the generic type necessary to retrieve and store packet commitments, acknowledgements, and receipts. Caller is responsible for knowing the context necessary to interpret this state as a commitment, acknowledgement, or a receipt. pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: pagination response height: title: query block height type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryPacketCommitmentsResponse is the request type for the Query/QueryPacketCommitments RPC method default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: channel_id description: channel unique identifier in: path required: true schema: type: string - name: port_id description: port unique identifier in: path required: true schema: type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/ibc/core/channel/v1/channels/{channel_id}/ports/{port_id}/packet_commitments/{packet_ack_sequences}/unreceived_acks": get: summary: >- UnreceivedAcks returns all the unreceived IBC acknowledgements associated with a channel and sequences. operationId: UnreceivedAcks_GU76R responses: "200": description: A successful response. content: application/json: schema: type: object properties: sequences: type: array items: type: string format: uint64 title: list of unreceived acknowledgement sequences height: title: query block height type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryUnreceivedAcksResponse is the response type for the Query/UnreceivedAcks RPC method default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: channel_id description: channel unique identifier in: path required: true schema: type: string - name: port_id description: port unique identifier in: path required: true schema: type: string - name: packet_ack_sequences description: list of acknowledgement sequences in: path required: true style: simple schema: type: array items: type: string format: uint64 minItems: 1 tags: - gRPC Gateway API "/ibc/core/channel/v1/channels/{channel_id}/ports/{port_id}/packet_commitments/{packet_commitment_sequences}/unreceived_packets": get: summary: >- UnreceivedPackets returns all the unreceived IBC packets associated with a channel and sequences. operationId: UnreceivedPackets_13T8R responses: "200": description: A successful response. content: application/json: schema: type: object properties: sequences: type: array items: type: string format: uint64 title: list of unreceived packet sequences height: title: query block height type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryUnreceivedPacketsResponse is the response type for the Query/UnreceivedPacketCommitments RPC method default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: channel_id description: channel unique identifier in: path required: true schema: type: string - name: port_id description: port unique identifier in: path required: true schema: type: string - name: packet_commitment_sequences description: list of packet sequences in: path required: true style: simple schema: type: array items: type: string format: uint64 minItems: 1 tags: - gRPC Gateway API "/ibc/core/channel/v1/channels/{channel_id}/ports/{port_id}/packet_commitments/{sequence}": get: summary: PacketCommitment queries a stored packet commitment hash. operationId: PacketCommitment_4UP5U responses: "200": description: A successful response. content: application/json: schema: type: object properties: commitment: type: string format: byte title: packet associated with the request fields proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: >- QueryPacketCommitmentResponse defines the client query response for a packet which also includes a proof and the height from which the proof was retrieved default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: channel_id description: channel unique identifier in: path required: true schema: type: string - name: port_id description: port unique identifier in: path required: true schema: type: string - name: sequence description: packet sequence in: path required: true schema: type: string format: uint64 tags: - gRPC Gateway API "/ibc/core/channel/v1/channels/{channel_id}/ports/{port_id}/packet_receipts/{sequence}": get: summary: >- PacketReceipt queries if a given packet sequence has been received on the queried chain operationId: PacketReceipt_907ZV responses: "200": description: A successful response. content: application/json: schema: type: object properties: received: type: boolean title: success flag for if receipt exists proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: >- QueryPacketReceiptResponse defines the client query response for a packet receipt which also includes a proof, and the height from which the proof was retrieved default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: channel_id description: channel unique identifier in: path required: true schema: type: string - name: port_id description: port unique identifier in: path required: true schema: type: string - name: sequence description: packet sequence in: path required: true schema: type: string format: uint64 tags: - gRPC Gateway API "/ibc/core/channel/v1/connections/{connection}/channels": get: summary: |- ConnectionChannels queries all the channels associated with a connection end. operationId: ConnectionChannels_DKEMY responses: "200": description: A successful response. content: application/json: schema: type: object properties: channels: type: array items: type: object properties: state: title: current state of the channel end type: string enum: - STATE_UNINITIALIZED_UNSPECIFIED - STATE_INIT - STATE_TRYOPEN - STATE_OPEN - STATE_CLOSED default: STATE_UNINITIALIZED_UNSPECIFIED description: >- State defines if a channel is in one of the following states: CLOSED, INIT, TRYOPEN, OPEN or UNINITIALIZED. - STATE_UNINITIALIZED_UNSPECIFIED: Default State - STATE_INIT: A channel has just started the opening handshake. - STATE_TRYOPEN: A channel has acknowledged the handshake step on the counterparty chain. - STATE_OPEN: A channel has completed the handshake. Open channels are ready to send and receive packets. - STATE_CLOSED: A channel has been closed and can no longer be used to send or receive packets. ordering: title: whether the channel is ordered or unordered type: string enum: - ORDER_NONE_UNSPECIFIED - ORDER_UNORDERED - ORDER_ORDERED default: ORDER_NONE_UNSPECIFIED description: >- - ORDER_NONE_UNSPECIFIED: zero-value for channel ordering - ORDER_UNORDERED: packets can be delivered in any order, which may differ from the order in which they were sent. - ORDER_ORDERED: packets are delivered exactly in the order which they were sent counterparty: title: counterparty channel end type: object properties: port_id: type: string description: port on the counterparty chain which owns the other end of the channel. channel_id: type: string title: channel end on the counterparty chain connection_hops: type: array items: type: string title: >- list of connection identifiers, in order, along which packets sent on this channel will travel version: type: string title: opaque channel version, which is agreed upon during the handshake port_id: type: string title: port identifier channel_id: type: string title: channel identifier description: >- IdentifiedChannel defines a channel with additional port and channel identifier fields. description: list of channels associated with a connection. pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: pagination response height: title: query block height type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryConnectionChannelsResponse is the Response type for the Query/QueryConnectionChannels RPC method default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: connection description: connection unique identifier in: path required: true schema: type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/cosmos/auth/v1beta1/account_info/{address}": get: summary: AccountInfo queries account info which is common to all account types. description: "Since: cosmos-sdk 0.47" operationId: AccountInfo_J8GK9 responses: "200": description: A successful response. content: application/json: schema: type: object properties: info: description: info is the account info which is represented by BaseAccount. type: object properties: address: type: string pub_key: type: object properties: type_url: type: string value: type: string format: byte account_number: type: string format: uint64 sequence: type: string format: uint64 description: >- QueryAccountInfoResponse is the Query/AccountInfo response type. Since: cosmos-sdk 0.47 default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: address description: address is the account address string. in: path required: true schema: type: string tags: - gRPC Gateway API /cosmos/auth/v1beta1/accounts: get: summary: Accounts returns all the existing accounts. description: >- When called from another module, this query might consume a high amount of gas if the pagination field is incorrectly set. Since: cosmos-sdk 0.43 operationId: Accounts_EI4FZ responses: "200": description: A successful response. content: application/json: schema: type: object properties: accounts: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: accounts are the existing accounts pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- QueryAccountsResponse is the response type for the Query/Accounts RPC method. Since: cosmos-sdk 0.43 default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/cosmos/auth/v1beta1/accounts/{address}": get: summary: Account returns account details based on address. operationId: Account_GVO8V responses: "200": description: A successful response. content: application/json: schema: type: object properties: account: type: object properties: type_url: type: string value: type: string format: byte description: account defines the account of the corresponding address. description: QueryAccountResponse is the response type for the Query/Account RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: address description: address defines the address to query for. in: path required: true schema: type: string tags: - gRPC Gateway API "/cosmos/auth/v1beta1/address_by_id/{id}": get: summary: AccountAddressByID returns account address based on account number. description: "Since: cosmos-sdk 0.46.2" operationId: AccountAddressByID_OE1HP responses: "200": description: A successful response. content: application/json: schema: type: object properties: account_address: type: string description: "Since: cosmos-sdk 0.46.2" title: QueryAccountAddressByIDResponse is the response type for AccountAddressByID rpc method default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: id description: |- Deprecated, use account_id instead id is the account number of the address to be queried. This field should have been an uint64 (like all account numbers), and will be updated to uint64 in a future version of the auth query. in: path required: true schema: type: string format: int64 - name: account_id description: |- account_id is the account number of the address to be queried. Since: cosmos-sdk 0.47 in: query required: false schema: type: string format: uint64 tags: - gRPC Gateway API /cosmos/auth/v1beta1/bech32: get: summary: Bech32Prefix queries bech32Prefix description: "Since: cosmos-sdk 0.46" operationId: Bech32Prefix_1OIJM responses: "200": description: A successful response. content: application/json: schema: type: object properties: bech32_prefix: type: string description: >- Bech32PrefixResponse is the response type for Bech32Prefix rpc method. Since: cosmos-sdk 0.46 default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API "/cosmos/auth/v1beta1/bech32/{address_bytes}": get: summary: AddressBytesToString converts Account Address bytes to string description: "Since: cosmos-sdk 0.46" operationId: AddressBytesToString_P2TYK responses: "200": description: A successful response. content: application/json: schema: type: object properties: address_string: type: string description: >- AddressBytesToStringResponse is the response type for AddressString rpc method. Since: cosmos-sdk 0.46 default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: address_bytes in: path required: true schema: type: string format: byte tags: - gRPC Gateway API "/cosmos/auth/v1beta1/bech32/{address_string}": get: summary: AddressStringToBytes converts Address string to bytes description: "Since: cosmos-sdk 0.46" operationId: AddressStringToBytes_2ADP0 responses: "200": description: A successful response. content: application/json: schema: type: object properties: address_bytes: type: string format: byte description: >- AddressStringToBytesResponse is the response type for AddressBytes rpc method. Since: cosmos-sdk 0.46 default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: address_string in: path required: true schema: type: string tags: - gRPC Gateway API /cosmos/auth/v1beta1/module_accounts: get: summary: ModuleAccounts returns all the existing module accounts. description: "Since: cosmos-sdk 0.46" operationId: ModuleAccounts_A46V7 responses: "200": description: A successful response. content: application/json: schema: type: object properties: accounts: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- QueryModuleAccountsResponse is the response type for the Query/ModuleAccounts RPC method. Since: cosmos-sdk 0.46 default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API "/cosmos/auth/v1beta1/module_accounts/{name}": get: summary: ModuleAccountByName returns the module account info by module name operationId: ModuleAccountByName_R830P responses: "200": description: A successful response. content: application/json: schema: type: object properties: account: type: object properties: type_url: type: string value: type: string format: byte description: QueryModuleAccountByNameResponse is the response type for the Query/ModuleAccountByName RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: name in: path required: true schema: type: string tags: - gRPC Gateway API /cosmos/auth/v1beta1/params: get: summary: Params queries all parameters. operationId: Params_NV54V responses: "200": description: A successful response. content: application/json: schema: type: object properties: params: description: params defines the parameters of the module. type: object properties: max_memo_characters: type: string format: uint64 tx_sig_limit: type: string format: uint64 tx_size_cost_per_byte: type: string format: uint64 sig_verify_cost_ed25519: type: string format: uint64 sig_verify_cost_secp256k1: type: string format: uint64 description: QueryParamsResponse is the response type for the Query/Params RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/evidence/v1beta1/evidence: get: summary: AllEvidence queries all evidence. operationId: AllEvidence_WTNNZ responses: "200": description: A successful response. content: application/json: schema: type: object properties: evidence: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: evidence returns all evidences. pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- QueryAllEvidenceResponse is the response type for the Query/AllEvidence RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/cosmos/evidence/v1beta1/evidence/{hash}": get: summary: Evidence queries evidence based on evidence hash. operationId: Evidence_VCI4U responses: "200": description: A successful response. content: application/json: schema: type: object properties: evidence: type: object properties: type_url: type: string value: type: string format: byte description: evidence returns the requested evidence. description: QueryEvidenceResponse is the response type for the Query/Evidence RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: hash description: |- hash defines the evidence hash of the requested evidence. Since: cosmos-sdk 0.47 in: path required: true schema: type: string - name: evidence_hash description: |- evidence_hash defines the hash of the requested evidence. Deprecated: Use hash, a HEX encoded string, instead. in: query required: false schema: type: string format: byte tags: - gRPC Gateway API /ibc/core/client/v1/client_states: get: summary: ClientStates queries all the IBC light clients of a chain. operationId: ClientStates_G5T1X responses: "200": description: A successful response. content: application/json: schema: type: object properties: client_states: type: array items: type: object properties: client_id: type: string title: client identifier client_state: type: object properties: type_url: type: string value: type: string format: byte title: client state description: >- IdentifiedClientState defines a client state with an additional client identifier field. description: list of stored ClientStates of the chain. pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: pagination response description: >- QueryClientStatesResponse is the response type for the Query/ClientStates RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/ibc/core/client/v1/client_states/{client_id}": get: summary: ClientState queries an IBC light client. operationId: ClientState_ET75Z responses: "200": description: A successful response. content: application/json: schema: type: object properties: client_state: type: object properties: type_url: type: string value: type: string format: byte title: client state associated with the request identifier proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset description: >- QueryClientStateResponse is the response type for the Query/ClientState RPC method. Besides the client state, it includes a proof and the height from which the proof was retrieved. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: client_id description: client state unique identifier in: path required: true schema: type: string tags: - gRPC Gateway API "/ibc/core/client/v1/client_status/{client_id}": get: summary: Status queries the status of an IBC client. operationId: ClientStatus_I48L1 responses: "200": description: A successful response. content: application/json: schema: type: object properties: status: type: string description: >- QueryClientStatusResponse is the response type for the Query/ClientStatus RPC method. It returns the current status of the IBC client. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: client_id description: client unique identifier in: path required: true schema: type: string tags: - gRPC Gateway API "/ibc/core/client/v1/consensus_states/{client_id}": get: summary: |- ConsensusStates queries all the consensus state associated with a given client. operationId: ConsensusStates_OEIZR responses: "200": description: A successful response. content: application/json: schema: type: object properties: consensus_states: type: array items: type: object properties: height: title: consensus state height type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset consensus_state: type: object properties: type_url: type: string value: type: string format: byte title: consensus state description: >- ConsensusStateWithHeight defines a consensus state with an additional height field. title: consensus states associated with the identifier pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: pagination response title: |- QueryConsensusStatesResponse is the response type for the Query/ConsensusStates RPC method default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: client_id description: client identifier in: path required: true schema: type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/ibc/core/client/v1/consensus_states/{client_id}/heights": get: summary: ConsensusStateHeights queries the height of every consensus states associated with a given client. operationId: ConsensusStateHeights_03B71 responses: "200": description: A successful response. content: application/json: schema: type: object properties: consensus_state_heights: type: array items: type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: >- Height is a monotonically increasing data type that can be compared against another Height for the purposes of updating and freezing clients title: consensus state heights pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: pagination response title: >- QueryConsensusStateHeightsResponse is the response type for the Query/ConsensusStateHeights RPC method default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: client_id description: client identifier in: path required: true schema: type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/ibc/core/client/v1/consensus_states/{client_id}/revision/{revision_number}/height/{revision_height}": get: summary: >- ConsensusState queries a consensus state associated with a client state at a given height. operationId: ConsensusState_AYG3G responses: "200": description: A successful response. content: application/json: schema: type: object properties: consensus_state: type: object properties: type_url: type: string value: type: string format: byte title: consensus state associated with the client identifier at the given height proof: type: string format: byte title: merkle proof of existence proof_height: type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: >- Height is a monotonically increasing data type that can be compared against another Height for the purposes of updating and freezing clients title: >- QueryConsensusStateResponse is the response type for the Query/ConsensusState RPC method default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: client_id description: client identifier in: path required: true schema: type: string - name: revision_number description: consensus state revision number in: path required: true schema: type: string format: uint64 - name: revision_height description: consensus state revision height in: path required: true schema: type: string format: uint64 - name: latest_height description: >- latest_height overrrides the height field and queries the latest stored ConsensusState. in: query required: false schema: type: boolean tags: - gRPC Gateway API /ibc/core/client/v1/params: get: summary: ClientParams queries all parameters of the ibc client submodule. operationId: ClientParams_XMXO9 responses: "200": description: A successful response. content: application/json: schema: type: object properties: params: description: params defines the parameters of the module. type: object properties: allowed_clients: type: array items: type: string description: >- allowed_clients defines the list of allowed client state types which can be created and interacted with. If a client type is removed from the allowed clients list, usage of this client will be disabled until it is added again to the list. description: >- QueryClientParamsResponse is the response type for the Query/ClientParams RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /ibc/core/client/v1/upgraded_client_states: get: summary: UpgradedClientState queries an Upgraded IBC light client. operationId: UpgradedClientState_0T6RN responses: "200": description: A successful response. content: application/json: schema: type: object properties: upgraded_client_state: type: object properties: type_url: type: string value: type: string format: byte title: client state associated with the request identifier description: |- QueryUpgradedClientStateResponse is the response type for the Query/UpgradedClientState RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /ibc/core/client/v1/upgraded_consensus_states: get: summary: UpgradedConsensusState queries an Upgraded IBC consensus state. operationId: UpgradedConsensusState_T13SE responses: "200": description: A successful response. content: application/json: schema: type: object properties: upgraded_consensus_state: type: object properties: type_url: type: string value: type: string format: byte title: Consensus state associated with the request identifier description: >- QueryUpgradedConsensusStateResponse is the response type for the Query/UpgradedConsensusState RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/authz/v1beta1/grants: get: summary: Returns list of `Authorization`, granted to the grantee by the granter. operationId: Grants_OHMNO responses: "200": description: A successful response. content: application/json: schema: type: object properties: grants: type: array items: type: object properties: authorization: type: object properties: type_url: type: string value: type: string format: byte expiration: type: string format: date-time title: >- time when the grant will expire and will be pruned. If null, then the grant doesn't have a time expiration (other conditions in `authorization` may apply to invalidate the grant) description: |- Grant gives permissions to execute the provide method with expiration time. description: authorizations is a list of grants granted for grantee by granter. pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: QueryGrantsResponse is the response type for the Query/Authorizations RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: granter in: query required: false schema: type: string - name: grantee in: query required: false schema: type: string - name: msg_type_url description: Optional, msg_type_url, when set, will query only grants matching given msg type. in: query required: false schema: type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/cosmos/authz/v1beta1/grants/grantee/{grantee}": get: summary: GranteeGrants returns a list of `GrantAuthorization` by grantee. description: "Since: cosmos-sdk 0.46" operationId: GranteeGrants_2HZ2F responses: "200": description: A successful response. content: application/json: schema: type: object properties: grants: type: array items: type: object properties: granter: type: string grantee: type: string authorization: type: object properties: type_url: type: string value: type: string format: byte expiration: type: string format: date-time title: >- GrantAuthorization extends a grant with both the addresses of the grantee and granter. It is used in genesis.proto and query.proto description: grants is a list of grants granted to the grantee. pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: QueryGranteeGrantsResponse is the response type for the Query/GranteeGrants RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: grantee in: path required: true schema: type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/cosmos/authz/v1beta1/grants/granter/{granter}": get: summary: GranterGrants returns list of `GrantAuthorization`, granted by granter. description: "Since: cosmos-sdk 0.46" operationId: GranterGrants_5J801 responses: "200": description: A successful response. content: application/json: schema: type: object properties: grants: type: array items: type: object properties: granter: type: string grantee: type: string authorization: type: object properties: type_url: type: string value: type: string format: byte expiration: type: string format: date-time title: >- GrantAuthorization extends a grant with both the addresses of the grantee and granter. It is used in genesis.proto and query.proto description: grants is a list of grants granted by the granter. pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: QueryGranterGrantsResponse is the response type for the Query/GranterGrants RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: granter in: path required: true schema: type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API /cosmos/liquidity/v1beta1/params: get: summary: Get all parameters of the liquidity module. operationId: Params_PSZ1M responses: "200": description: A successful response. content: application/json: schema: type: object properties: params: description: params holds all the parameters of this module. type: object properties: pool_types: type: array items: type: object properties: id: type: integer format: int64 title: >- This is the id of the pool_type that is used as pool_type_id for pool creation. In this version, only pool-type-id 1 is supported. {"id":1,"name":"ConstantProductLiquidityPool","min_reserve_coin_num":2,"max_reserve_coin_num":2,"description":""} name: type: string description: name of the pool type. min_reserve_coin_num: type: integer format: int64 description: >- minimum number of reserveCoins for LiquidityPoolType, only 2 reserve coins are supported. max_reserve_coin_num: type: integer format: int64 description: >- maximum number of reserveCoins for LiquidityPoolType, only 2 reserve coins are supported. description: type: string description: description of the pool type. description: >- Structure for the pool type to distinguish the characteristics of the reserve pools. title: list of available pool types min_init_deposit_amount: type: string description: >- Minimum number of coins to be deposited to the liquidity pool on pool creation. init_pool_coin_mint_amount: type: string description: Initial mint amount of pool coins upon pool creation. max_reserve_coin_amount: type: string description: >- Limit the size of each liquidity pool to minimize risk. In development, set to 0 for no limit. In production, set a limit. pool_creation_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: Fee paid to create a Liquidity Pool. Set a fee to prevent spamming. swap_fee_rate: type: string description: Swap fee rate for every executed swap. withdraw_fee_rate: type: string description: Reserve coin withdrawal with less proportion by withdrawFeeRate. max_order_amount_ratio: type: string description: Maximum ratio of reserve coins that can be ordered at a swap order. unit_batch_height: type: integer format: int64 description: The smallest unit batch height for every liquidity pool. circuit_breaker_enabled: type: boolean description: >- Circuit breaker enables or disables transaction messages in liquidity module. description: >- the response type for the QueryParamsResponse RPC method. This includes current parameter of the liquidity module. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/liquidity/v1beta1/pools: get: summary: Get existing liquidity pools. operationId: LiquidityPools_W7CWM responses: "200": description: A successful response. content: application/json: schema: type: object properties: pools: type: array items: type: object properties: id: type: string format: uint64 title: id of the pool type_id: type: integer format: int64 title: id of the pool_type reserve_coin_denoms: type: array items: type: string title: denoms of reserve coin pair of the pool reserve_account_address: type: string title: reserve account address of the pool pool_coin_denom: type: string title: denom of pool coin of the pool description: Pool defines the liquidity pool that contains pool information. pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- the response type for the QueryLiquidityPoolsResponse RPC method. This includes a list of all existing liquidity pools and paging results that contain next_key and total count. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/cosmos/liquidity/v1beta1/pools/pool_coin_denom/{pool_coin_denom}": get: summary: Get specific liquidity pool corresponding to the pool_coin_denom. operationId: LiquidityPoolByPoolCoinDenom_90R2T responses: "200": description: A successful response. content: application/json: schema: type: object properties: pool: type: object properties: id: type: string format: uint64 title: id of the pool type_id: type: integer format: int64 title: id of the pool_type reserve_coin_denoms: type: array items: type: string title: denoms of reserve coin pair of the pool reserve_account_address: type: string title: reserve account address of the pool pool_coin_denom: type: string title: denom of pool coin of the pool description: Pool defines the liquidity pool that contains pool information. description: >- the response type for the QueryLiquidityPoolResponse RPC method. Returns the liquidity pool that corresponds to the requested pool_id. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pool_coin_denom in: path required: true schema: type: string tags: - gRPC Gateway API "/cosmos/liquidity/v1beta1/pools/reserve_acc/{reserve_acc}": get: summary: Get specific liquidity pool corresponding to the reserve account. operationId: LiquidityPoolByReserveAcc_824YS responses: "200": description: A successful response. content: application/json: schema: type: object properties: pool: type: object properties: id: type: string format: uint64 title: id of the pool type_id: type: integer format: int64 title: id of the pool_type reserve_coin_denoms: type: array items: type: string title: denoms of reserve coin pair of the pool reserve_account_address: type: string title: reserve account address of the pool pool_coin_denom: type: string title: denom of pool coin of the pool description: Pool defines the liquidity pool that contains pool information. description: >- the response type for the QueryLiquidityPoolResponse RPC method. Returns the liquidity pool that corresponds to the requested pool_id. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: reserve_acc in: path required: true schema: type: string tags: - gRPC Gateway API "/cosmos/liquidity/v1beta1/pools/{pool_id}": get: summary: Get specific liquidity pool. operationId: LiquidityPool_GVMM2 responses: "200": description: A successful response. content: application/json: schema: type: object properties: pool: type: object properties: id: type: string format: uint64 title: id of the pool type_id: type: integer format: int64 title: id of the pool_type reserve_coin_denoms: type: array items: type: string title: denoms of reserve coin pair of the pool reserve_account_address: type: string title: reserve account address of the pool pool_coin_denom: type: string title: denom of pool coin of the pool description: Pool defines the liquidity pool that contains pool information. description: >- the response type for the QueryLiquidityPoolResponse RPC method. Returns the liquidity pool that corresponds to the requested pool_id. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pool_id in: path required: true schema: type: string format: uint64 tags: - gRPC Gateway API "/cosmos/liquidity/v1beta1/pools/{pool_id}/batch": get: summary: Get the pool's current batch. operationId: LiquidityPoolBatch_80103 responses: "200": description: A successful response. content: application/json: schema: type: object properties: batch: type: object properties: pool_id: type: string format: uint64 title: id of the pool index: type: string format: uint64 title: index of this batch begin_height: type: string format: int64 title: height where this batch is started deposit_msg_index: type: string format: uint64 title: last index of DepositMsgStates withdraw_msg_index: type: string format: uint64 title: last index of WithdrawMsgStates swap_msg_index: type: string format: uint64 title: last index of SwapMsgStates executed: type: boolean title: true if executed, false if not executed description: >- PoolBatch defines the batch or batches of a given liquidity pool that contains indexes of deposit, withdraw, and swap messages. Index param increments by 1 if the pool id is same. description: >- the response type for the QueryLiquidityPoolBatchResponse RPC method. Returns the liquidity pool batch that corresponds to the requested pool_id. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pool_id description: id of the target pool for query in: path required: true schema: type: string format: uint64 tags: - gRPC Gateway API "/cosmos/liquidity/v1beta1/pools/{pool_id}/batch/deposits": get: summary: Get all deposit messages in the pool's current batch. operationId: PoolBatchDepositMsgs_POD1A responses: "200": description: A successful response. content: application/json: schema: type: object properties: deposits: type: array items: type: object properties: msg_height: type: string format: int64 title: height where this message is appended to the batch msg_index: type: string format: uint64 title: index of this deposit message in this liquidity pool executed: type: boolean title: true if executed on this batch, false if not executed succeeded: type: boolean title: true if executed successfully on this batch, false if failed to_be_deleted: type: boolean title: true if ready to be deleted on kvstore, false if not ready to be deleted msg: title: MsgDepositWithinBatch type: object properties: depositor_address: type: string pool_id: type: string format: uint64 title: id of the target pool deposit_coins: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: reserve coin pair of the pool to deposit description: >- `MsgDepositWithinBatch defines` an `sdk.Msg` type that supports submitting a deposit request to the batch of the liquidity pool. Deposit is submitted to the batch of the Liquidity pool with the specified `pool_id`, `deposit_coins` for reserve. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. See: https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md description: >- DepositMsgState defines the state of deposit message that contains state information as it is processed in the next batch or batches. pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- the response type for the QueryPoolBatchDeposit RPC method. This includes a list of all currently existing deposit messages of the batch and paging results that contain next_key and total count. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pool_id description: id of the target pool for query in: path required: true schema: type: string format: uint64 - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/cosmos/liquidity/v1beta1/pools/{pool_id}/batch/deposits/{msg_index}": get: summary: Get a specific deposit message in the pool's current batch. operationId: PoolBatchDepositMsg_DLP6J responses: "200": description: A successful response. content: application/json: schema: type: object properties: deposit: type: object properties: msg_height: type: string format: int64 title: height where this message is appended to the batch msg_index: type: string format: uint64 title: index of this deposit message in this liquidity pool executed: type: boolean title: true if executed on this batch, false if not executed succeeded: type: boolean title: true if executed successfully on this batch, false if failed to_be_deleted: type: boolean title: true if ready to be deleted on kvstore, false if not ready to be deleted msg: title: MsgDepositWithinBatch type: object properties: depositor_address: type: string pool_id: type: string format: uint64 title: id of the target pool deposit_coins: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: reserve coin pair of the pool to deposit description: >- `MsgDepositWithinBatch defines` an `sdk.Msg` type that supports submitting a deposit request to the batch of the liquidity pool. Deposit is submitted to the batch of the Liquidity pool with the specified `pool_id`, `deposit_coins` for reserve. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. See: https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md description: >- DepositMsgState defines the state of deposit message that contains state information as it is processed in the next batch or batches. description: >- the response type for the QueryPoolBatchDepositMsg RPC method. This includes a batch swap message of the batch. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pool_id description: id of the target pool for query in: path required: true schema: type: string format: uint64 - name: msg_index description: target msg_index of the pool in: path required: true schema: type: string format: uint64 tags: - gRPC Gateway API "/cosmos/liquidity/v1beta1/pools/{pool_id}/batch/swaps": get: summary: Get all swap messages in the pool's current batch. operationId: PoolBatchSwapMsgs_YUF1Y responses: "200": description: A successful response. content: application/json: schema: type: object properties: swaps: type: array items: type: object properties: msg_height: type: string format: int64 title: height where this message is appended to the batch msg_index: type: string format: uint64 title: index of this swap message in this liquidity pool executed: type: boolean title: true if executed on this batch, false if not executed succeeded: type: boolean title: true if executed successfully on this batch, false if failed to_be_deleted: type: boolean title: true if ready to be deleted on kvstore, false if not ready to be deleted order_expiry_height: type: string format: int64 title: >- swap orders are cancelled when current height is equal to or higher than ExpiryHeight exchanged_offer_coin: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: offer coin exchanged until now remaining_offer_coin: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: offer coin currently remaining to be exchanged reserved_offer_coin_fee: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: reserve fee for pays fee in half offer coin msg: title: MsgSwapWithinBatch type: object properties: swap_requester_address: type: string title: address of swap requester pool_id: type: string format: uint64 description: >- id of swap type, must match the value in the pool. Only `swap_type_id` 1 is supported. swap_type_id: type: integer format: int64 description: id of swap type. Must match the value in the pool. offer_coin: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. demand_coin_denom: type: string description: >- denom of demand coin to be exchanged on the swap request, must match the denom in the pool. offer_coin_fee: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. order_price: type: string description: >- limit order price for the order, the price is the exchange ratio of X/Y where X is the amount of the first coin and Y is the amount of the second coin when their denoms are sorted alphabetically. description: >- `MsgSwapWithinBatch` defines an sdk.Msg type that supports submitting a swap offer request to the batch of the liquidity pool. Submit swap offer to the liquidity pool batch with the specified the `pool_id`, `swap_type_id`, `demand_coin_denom` with the coin and the price you're offering and `offer_coin_fee` must be half of offer coin amount * current `params.swap_fee_rate` and ceil for reservation to pay fees. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. You must request the same fields as the pool. Only the default `swap_type_id` 1 is supported. See: https://github.com/gravity-devs/liquidity/tree/develop/doc https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md description: >- SwapMsgState defines the state of the swap message that contains state information as the message is processed in the next batch or batches. pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- the response type for the QueryPoolBatchSwapMsgs RPC method. This includes list of all currently existing swap messages of the batch and paging results that contain next_key and total count. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pool_id description: id of the target pool for query in: path required: true schema: type: string format: uint64 - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/cosmos/liquidity/v1beta1/pools/{pool_id}/batch/swaps/{msg_index}": get: summary: Get a specific swap message in the pool's current batch. operationId: PoolBatchSwapMsg_X08QJ responses: "200": description: A successful response. content: application/json: schema: type: object properties: swap: type: object properties: msg_height: type: string format: int64 title: height where this message is appended to the batch msg_index: type: string format: uint64 title: index of this swap message in this liquidity pool executed: type: boolean title: true if executed on this batch, false if not executed succeeded: type: boolean title: true if executed successfully on this batch, false if failed to_be_deleted: type: boolean title: true if ready to be deleted on kvstore, false if not ready to be deleted order_expiry_height: type: string format: int64 title: >- swap orders are cancelled when current height is equal to or higher than ExpiryHeight exchanged_offer_coin: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: offer coin exchanged until now remaining_offer_coin: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: offer coin currently remaining to be exchanged reserved_offer_coin_fee: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: reserve fee for pays fee in half offer coin msg: title: MsgSwapWithinBatch type: object properties: swap_requester_address: type: string title: address of swap requester pool_id: type: string format: uint64 description: >- id of swap type, must match the value in the pool. Only `swap_type_id` 1 is supported. swap_type_id: type: integer format: int64 description: id of swap type. Must match the value in the pool. offer_coin: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. demand_coin_denom: type: string description: >- denom of demand coin to be exchanged on the swap request, must match the denom in the pool. offer_coin_fee: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. order_price: type: string description: >- limit order price for the order, the price is the exchange ratio of X/Y where X is the amount of the first coin and Y is the amount of the second coin when their denoms are sorted alphabetically. description: >- `MsgSwapWithinBatch` defines an sdk.Msg type that supports submitting a swap offer request to the batch of the liquidity pool. Submit swap offer to the liquidity pool batch with the specified the `pool_id`, `swap_type_id`, `demand_coin_denom` with the coin and the price you're offering and `offer_coin_fee` must be half of offer coin amount * current `params.swap_fee_rate` and ceil for reservation to pay fees. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. You must request the same fields as the pool. Only the default `swap_type_id` 1 is supported. See: https://github.com/gravity-devs/liquidity/tree/develop/doc https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md description: >- SwapMsgState defines the state of the swap message that contains state information as the message is processed in the next batch or batches. description: >- the response type for the QueryPoolBatchSwapMsg RPC method. This includes a batch swap message of the batch. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pool_id description: id of the target pool for query in: path required: true schema: type: string format: uint64 - name: msg_index description: target msg_index of the pool in: path required: true schema: type: string format: uint64 tags: - gRPC Gateway API "/cosmos/liquidity/v1beta1/pools/{pool_id}/batch/withdraws": get: summary: Get all withdraw messages in the pool's current batch. operationId: PoolBatchWithdrawMsgs_605RT responses: "200": description: A successful response. content: application/json: schema: type: object properties: withdraws: type: array items: type: object properties: msg_height: type: string format: int64 title: height where this message is appended to the batch msg_index: type: string format: uint64 title: index of this withdraw message in this liquidity pool executed: type: boolean title: true if executed on this batch, false if not executed succeeded: type: boolean title: true if executed successfully on this batch, false if failed to_be_deleted: type: boolean title: true if ready to be deleted on kvstore, false if not ready to be deleted msg: title: MsgWithdrawWithinBatch type: object properties: withdrawer_address: type: string pool_id: type: string format: uint64 title: id of the target pool pool_coin: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- `MsgWithdrawWithinBatch` defines an `sdk.Msg` type that supports submitting a withdraw request to the batch of the liquidity pool. Withdraw is submitted to the batch from the Liquidity pool with the specified `pool_id`, `pool_coin` of the pool. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. See: https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md description: >- WithdrawMsgState defines the state of the withdraw message that contains state information as the message is processed in the next batch or batches. pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- the response type for the QueryPoolBatchWithdraw RPC method. This includes a list of all currently existing withdraw messages of the batch and paging results that contain next_key and total count. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pool_id description: id of the target pool for query in: path required: true schema: type: string format: uint64 - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/cosmos/liquidity/v1beta1/pools/{pool_id}/batch/withdraws/{msg_index}": get: summary: Get a specific withdraw message in the pool's current batch. operationId: PoolBatchWithdrawMsg_84SDG responses: "200": description: A successful response. content: application/json: schema: type: object properties: withdraw: type: object properties: msg_height: type: string format: int64 title: height where this message is appended to the batch msg_index: type: string format: uint64 title: index of this withdraw message in this liquidity pool executed: type: boolean title: true if executed on this batch, false if not executed succeeded: type: boolean title: true if executed successfully on this batch, false if failed to_be_deleted: type: boolean title: true if ready to be deleted on kvstore, false if not ready to be deleted msg: title: MsgWithdrawWithinBatch type: object properties: withdrawer_address: type: string pool_id: type: string format: uint64 title: id of the target pool pool_coin: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- `MsgWithdrawWithinBatch` defines an `sdk.Msg` type that supports submitting a withdraw request to the batch of the liquidity pool. Withdraw is submitted to the batch from the Liquidity pool with the specified `pool_id`, `pool_coin` of the pool. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. See: https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md description: >- WithdrawMsgState defines the state of the withdraw message that contains state information as the message is processed in the next batch or batches. description: >- the response type for the QueryPoolBatchWithdrawMsg RPC method. This includes a batch swap message of the batch. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pool_id description: id of the target pool for query in: path required: true schema: type: string format: uint64 - name: msg_index description: target msg_index of the pool in: path required: true schema: type: string format: uint64 tags: - gRPC Gateway API /cosmwasm/wasm/v1/code: get: summary: Codes gets the metadata for all stored wasm codes operationId: Codes_7UDV9 responses: "200": description: A successful response. content: application/json: schema: type: object properties: code_infos: type: array items: type: object properties: code_id: type: string format: uint64 creator: type: string data_hash: type: string format: byte instantiate_permission: type: object properties: permission: type: string enum: - ACCESS_TYPE_UNSPECIFIED - ACCESS_TYPE_NOBODY - ACCESS_TYPE_EVERYBODY - ACCESS_TYPE_ANY_OF_ADDRESSES default: ACCESS_TYPE_UNSPECIFIED description: >- - ACCESS_TYPE_UNSPECIFIED: AccessTypeUnspecified placeholder for empty value - ACCESS_TYPE_NOBODY: AccessTypeNobody forbidden - ACCESS_TYPE_EVERYBODY: AccessTypeEverybody unrestricted - ACCESS_TYPE_ANY_OF_ADDRESSES: AccessTypeAnyOfAddresses allow any of the addresses title: AccessType permission types addresses: type: array items: type: string description: AccessConfig access control type. title: CodeInfoResponse contains code meta data from CodeInfo pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: QueryCodesResponse is the response type for the Query/Codes RPC method default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/cosmwasm/wasm/v1/code/{code_id}": get: summary: Code gets the binary code and metadata for a singe wasm code operationId: Code_2D1PE responses: "200": description: A successful response. content: application/json: schema: type: object properties: code_info: type: object properties: code_id: type: string format: uint64 creator: type: string data_hash: type: string format: byte instantiate_permission: type: object properties: permission: type: string enum: - ACCESS_TYPE_UNSPECIFIED - ACCESS_TYPE_NOBODY - ACCESS_TYPE_EVERYBODY - ACCESS_TYPE_ANY_OF_ADDRESSES default: ACCESS_TYPE_UNSPECIFIED description: >- - ACCESS_TYPE_UNSPECIFIED: AccessTypeUnspecified placeholder for empty value - ACCESS_TYPE_NOBODY: AccessTypeNobody forbidden - ACCESS_TYPE_EVERYBODY: AccessTypeEverybody unrestricted - ACCESS_TYPE_ANY_OF_ADDRESSES: AccessTypeAnyOfAddresses allow any of the addresses title: AccessType permission types addresses: type: array items: type: string description: AccessConfig access control type. title: CodeInfoResponse contains code meta data from CodeInfo data: type: string format: byte title: QueryCodeResponse is the response type for the Query/Code RPC method default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: code_id in: path required: true schema: type: string format: uint64 tags: - gRPC Gateway API "/cosmwasm/wasm/v1/code/{code_id}/contracts": get: summary: ContractsByCode lists all smart contracts for a code id operationId: ContractsByCode_DCS9B responses: "200": description: A successful response. content: application/json: schema: type: object properties: contracts: type: array items: type: string title: contracts are a set of contract addresses pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: |- QueryContractsByCodeResponse is the response type for the Query/ContractsByCode RPC method default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: code_id in: path required: true schema: type: string format: uint64 - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API /cosmwasm/wasm/v1/codes/params: get: summary: Params gets the module params operationId: Params_0NI93 responses: "200": description: A successful response. content: application/json: schema: type: object properties: params: description: params defines the parameters of the module. type: object properties: code_upload_access: type: object properties: permission: type: string enum: - ACCESS_TYPE_UNSPECIFIED - ACCESS_TYPE_NOBODY - ACCESS_TYPE_EVERYBODY - ACCESS_TYPE_ANY_OF_ADDRESSES default: ACCESS_TYPE_UNSPECIFIED description: >- - ACCESS_TYPE_UNSPECIFIED: AccessTypeUnspecified placeholder for empty value - ACCESS_TYPE_NOBODY: AccessTypeNobody forbidden - ACCESS_TYPE_EVERYBODY: AccessTypeEverybody unrestricted - ACCESS_TYPE_ANY_OF_ADDRESSES: AccessTypeAnyOfAddresses allow any of the addresses title: AccessType permission types addresses: type: array items: type: string description: AccessConfig access control type. instantiate_default_permission: type: string enum: - ACCESS_TYPE_UNSPECIFIED - ACCESS_TYPE_NOBODY - ACCESS_TYPE_EVERYBODY - ACCESS_TYPE_ANY_OF_ADDRESSES default: ACCESS_TYPE_UNSPECIFIED description: >- - ACCESS_TYPE_UNSPECIFIED: AccessTypeUnspecified placeholder for empty value - ACCESS_TYPE_NOBODY: AccessTypeNobody forbidden - ACCESS_TYPE_EVERYBODY: AccessTypeEverybody unrestricted - ACCESS_TYPE_ANY_OF_ADDRESSES: AccessTypeAnyOfAddresses allow any of the addresses title: AccessType permission types description: QueryParamsResponse is the response type for the Query/Params RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmwasm/wasm/v1/codes/pinned: get: summary: PinnedCodes gets the pinned code ids operationId: PinnedCodes_W6G74 responses: "200": description: A successful response. content: application/json: schema: type: object properties: code_ids: type: array items: type: string format: uint64 pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: |- QueryPinnedCodesResponse is the response type for the Query/PinnedCodes RPC method default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/cosmwasm/wasm/v1/contract/{address}": get: summary: ContractInfo gets the contract meta data operationId: ContractInfo_6MJBN responses: "200": description: A successful response. content: application/json: schema: type: object properties: address: type: string title: address is the address of the contract contract_info: type: object properties: code_id: type: string format: uint64 title: CodeID is the reference to the stored Wasm code creator: type: string title: Creator address who initially instantiated the contract admin: type: string title: Admin is an optional address that can execute migrations label: type: string description: Label is optional metadata to be stored with a contract instance. created: description: Created Tx position when the contract was instantiated. type: object properties: block_height: type: string format: uint64 title: BlockHeight is the block the contract was created at tx_index: type: string format: uint64 title: >- TxIndex is a monotonic counter within the block (actual transaction index, or gas consumed) ibc_port_id: type: string extension: type: object properties: type_url: type: string value: type: string format: byte description: >- Extension is an extension point to store custom metadata within the persistence model. title: ContractInfo stores a WASM contract instance title: >- QueryContractInfoResponse is the response type for the Query/ContractInfo RPC method default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: address description: address is the address of the contract to query in: path required: true schema: type: string tags: - gRPC Gateway API "/cosmwasm/wasm/v1/contract/{address}/history": get: summary: ContractHistory gets the contract code history operationId: ContractHistory_5CXKC responses: "200": description: A successful response. content: application/json: schema: type: object properties: entries: type: array items: type: object properties: operation: type: string enum: - CONTRACT_CODE_HISTORY_OPERATION_TYPE_UNSPECIFIED - CONTRACT_CODE_HISTORY_OPERATION_TYPE_INIT - CONTRACT_CODE_HISTORY_OPERATION_TYPE_MIGRATE - CONTRACT_CODE_HISTORY_OPERATION_TYPE_GENESIS default: CONTRACT_CODE_HISTORY_OPERATION_TYPE_UNSPECIFIED description: >- - CONTRACT_CODE_HISTORY_OPERATION_TYPE_UNSPECIFIED: ContractCodeHistoryOperationTypeUnspecified placeholder for empty value - CONTRACT_CODE_HISTORY_OPERATION_TYPE_INIT: ContractCodeHistoryOperationTypeInit on chain contract instantiation - CONTRACT_CODE_HISTORY_OPERATION_TYPE_MIGRATE: ContractCodeHistoryOperationTypeMigrate code migration - CONTRACT_CODE_HISTORY_OPERATION_TYPE_GENESIS: ContractCodeHistoryOperationTypeGenesis based on genesis data title: ContractCodeHistoryOperationType actions that caused a code change code_id: type: string format: uint64 title: CodeID is the reference to the stored WASM code updated: description: Updated Tx position when the operation was executed. type: object properties: block_height: type: string format: uint64 title: BlockHeight is the block the contract was created at tx_index: type: string format: uint64 title: >- TxIndex is a monotonic counter within the block (actual transaction index, or gas consumed) msg: type: string format: byte description: ContractCodeHistoryEntry metadata to a contract. pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: |- QueryContractHistoryResponse is the response type for the Query/ContractHistory RPC method default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: address description: address is the address of the contract to query in: path required: true schema: type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/cosmwasm/wasm/v1/contract/{address}/raw/{query_data}": get: summary: RawContractState gets single key from the raw store data of a contract operationId: RawContractState_HN7KQ responses: "200": description: A successful response. content: application/json: schema: type: object properties: data: type: string format: byte title: Data contains the raw store data title: |- QueryRawContractStateResponse is the response type for the Query/RawContractState RPC method default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: address description: address is the address of the contract in: path required: true schema: type: string - name: query_data in: path required: true schema: type: string format: byte tags: - gRPC Gateway API "/cosmwasm/wasm/v1/contract/{address}/smart/{query_data}": get: summary: SmartContractState get smart query result from the contract operationId: SmartContractState_7RZK1 responses: "200": description: A successful response. content: application/json: schema: type: object properties: data: type: string format: byte title: Data contains the json data returned from the smart contract title: |- QuerySmartContractStateResponse is the response type for the Query/SmartContractState RPC method default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: address description: address is the address of the contract in: path required: true schema: type: string - name: query_data description: QueryData contains the query data passed to the contract in: path required: true schema: type: string format: byte tags: - gRPC Gateway API "/cosmwasm/wasm/v1/contract/{address}/state": get: summary: AllContractState gets all raw store data for a single contract operationId: AllContractState_8F65W responses: "200": description: A successful response. content: application/json: schema: type: object properties: models: type: array items: type: object properties: key: type: string format: byte title: hex-encode key to read it better (this is often ascii) value: type: string format: byte title: base64-encode raw value title: Model is a struct that holds a KV pair pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: |- QueryAllContractStateResponse is the response type for the Query/AllContractState RPC method default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: address description: address is the address of the contract in: path required: true schema: type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/cosmwasm/wasm/v1/contracts/creator/{creator_address}": get: summary: ContractsByCreator gets the contracts by creator operationId: ContractsByCreator_Y148N responses: "200": description: A successful response. content: application/json: schema: type: object properties: contract_addresses: type: array items: type: string title: ContractAddresses result set pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: |- QueryContractsByCreatorResponse is the response type for the Query/ContractsByCreator RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: creator_address description: CreatorAddress is the address of contract creator in: path required: true schema: type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API /cyber/bandwidth/v1beta1/bandwidth/load: get: operationId: Load_3QI57 responses: "200": description: A successful response. content: application/json: schema: type: object properties: load: type: string default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API "/cyber/bandwidth/v1beta1/bandwidth/neuron/{neuron}": get: operationId: NeuronBandwidth_1DGP1 responses: "200": description: A successful response. content: application/json: schema: type: object properties: neuron_bandwidth: type: object properties: neuron: type: string remained_value: type: string format: uint64 last_updated_block: type: string format: uint64 max_value: type: string format: uint64 default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: neuron in: path required: true schema: type: string tags: - gRPC Gateway API /cyber/bandwidth/v1beta1/bandwidth/params: get: operationId: Params_B8C0X responses: "200": description: A successful response. content: application/json: schema: type: object properties: params: type: object properties: recovery_period: type: string format: uint64 adjust_price_period: type: string format: uint64 base_price: type: string base_load: type: string max_block_bandwidth: type: string format: uint64 default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cyber/bandwidth/v1beta1/bandwidth/price: get: operationId: Price_LCDUB responses: "200": description: A successful response. content: application/json: schema: type: object properties: price: type: string default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cyber/bandwidth/v1beta1/bandwidth/total: get: operationId: TotalBandwidth_7HIK3 responses: "200": description: A successful response. content: application/json: schema: type: object properties: total_bandwidth: type: string format: uint64 default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/base/tendermint/v1beta1/abci_query: get: summary: >- ABCIQuery defines a query handler that supports ABCI queries directly to the application, bypassing Tendermint completely. The ABCI query must contain a valid and supported path, including app, custom, p2p, and store. description: "Since: cosmos-sdk 0.46" operationId: ABCIQuery_5ACTN responses: "200": description: A successful response. content: application/json: schema: type: object properties: code: type: integer format: int64 log: type: string info: type: string index: type: string format: int64 key: type: string format: byte value: type: string format: byte proof_ops: type: object properties: ops: type: array items: type: object properties: type: type: string key: type: string format: byte data: type: string format: byte description: >- ProofOp defines an operation used for calculating Merkle root. The data could be arbitrary format, providing necessary data for example neighbouring node hash. Note: This type is a duplicate of the ProofOp proto type defined in Tendermint. description: >- ProofOps is Merkle proof defined by the list of ProofOps. Note: This type is a duplicate of the ProofOps proto type defined in Tendermint. height: type: string format: int64 codespace: type: string description: >- ABCIQueryResponse defines the response structure for the ABCIQuery gRPC query. Note: This type is a duplicate of the ResponseQuery proto type defined in Tendermint. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: data in: query required: false schema: type: string format: byte - name: path in: query required: false schema: type: string - name: height in: query required: false schema: type: string format: int64 - name: prove in: query required: false schema: type: boolean tags: - gRPC Gateway API /cosmos/base/tendermint/v1beta1/blocks/latest: get: summary: GetLatestBlock returns the latest block. operationId: GetLatestBlock_QLNC7 responses: "200": description: A successful response. content: application/json: schema: type: object properties: block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID block: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. data: type: object properties: txs: type: array items: type: string format: byte description: >- Txs that will be applied by state @ block.Height+1. NOTE: not all txs here are valid. We're just agreeing on the order first. This means that block.AppHash does not include these txs. title: Data contains the set of transactions included in the block evidence: type: object properties: evidence: type: array items: type: object properties: duplicate_vote_evidence: type: object properties: vote_a: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. vote_b: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. total_voting_power: type: string format: int64 validator_power: type: string format: int64 timestamp: type: string format: date-time description: DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes. light_client_attack_evidence: type: object properties: conflicting_block: type: object properties: signed_header: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: Commit contains the evidence that a block was committed by a set of validators. validator_set: type: object properties: validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 proposer: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 common_height: type: string format: int64 byzantine_validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 timestamp: type: string format: date-time description: LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client. last_commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: Commit contains the evidence that a block was committed by a set of validators. title: "Deprecated: please use `sdk_block` instead" sdk_block: title: "Since: cosmos-sdk 0.47" type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string description: >- proposer_address is the original block proposer address, formatted as a Bech32 string. In Tendermint, this type is `bytes`, but in the SDK, we convert it to a Bech32 string for better UX. description: Header defines the structure of a Tendermint block header. data: type: object properties: txs: type: array items: type: string format: byte description: >- Txs that will be applied by state @ block.Height+1. NOTE: not all txs here are valid. We're just agreeing on the order first. This means that block.AppHash does not include these txs. title: Data contains the set of transactions included in the block evidence: type: object properties: evidence: type: array items: type: object properties: duplicate_vote_evidence: type: object properties: vote_a: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. vote_b: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. total_voting_power: type: string format: int64 validator_power: type: string format: int64 timestamp: type: string format: date-time description: DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes. light_client_attack_evidence: type: object properties: conflicting_block: type: object properties: signed_header: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: Commit contains the evidence that a block was committed by a set of validators. validator_set: type: object properties: validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 proposer: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 common_height: type: string format: int64 byzantine_validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 timestamp: type: string format: date-time description: LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client. last_commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: Commit contains the evidence that a block was committed by a set of validators. description: >- Block is tendermint type Block, with the Header proposer address field converted to bech32 string. description: GetLatestBlockResponse is the response type for the Query/GetLatestBlock RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API "/cosmos/base/tendermint/v1beta1/blocks/{height}": get: summary: GetBlockByHeight queries block for given height. operationId: GetBlockByHeight_FSKO8 responses: "200": description: A successful response. content: application/json: schema: type: object properties: block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID block: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. data: type: object properties: txs: type: array items: type: string format: byte description: >- Txs that will be applied by state @ block.Height+1. NOTE: not all txs here are valid. We're just agreeing on the order first. This means that block.AppHash does not include these txs. title: Data contains the set of transactions included in the block evidence: type: object properties: evidence: type: array items: type: object properties: duplicate_vote_evidence: type: object properties: vote_a: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. vote_b: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. total_voting_power: type: string format: int64 validator_power: type: string format: int64 timestamp: type: string format: date-time description: DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes. light_client_attack_evidence: type: object properties: conflicting_block: type: object properties: signed_header: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: Commit contains the evidence that a block was committed by a set of validators. validator_set: type: object properties: validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 proposer: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 common_height: type: string format: int64 byzantine_validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 timestamp: type: string format: date-time description: LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client. last_commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: Commit contains the evidence that a block was committed by a set of validators. title: "Deprecated: please use `sdk_block` instead" sdk_block: title: "Since: cosmos-sdk 0.47" type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string description: >- proposer_address is the original block proposer address, formatted as a Bech32 string. In Tendermint, this type is `bytes`, but in the SDK, we convert it to a Bech32 string for better UX. description: Header defines the structure of a Tendermint block header. data: type: object properties: txs: type: array items: type: string format: byte description: >- Txs that will be applied by state @ block.Height+1. NOTE: not all txs here are valid. We're just agreeing on the order first. This means that block.AppHash does not include these txs. title: Data contains the set of transactions included in the block evidence: type: object properties: evidence: type: array items: type: object properties: duplicate_vote_evidence: type: object properties: vote_a: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. vote_b: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. total_voting_power: type: string format: int64 validator_power: type: string format: int64 timestamp: type: string format: date-time description: DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes. light_client_attack_evidence: type: object properties: conflicting_block: type: object properties: signed_header: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: Commit contains the evidence that a block was committed by a set of validators. validator_set: type: object properties: validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 proposer: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 common_height: type: string format: int64 byzantine_validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 timestamp: type: string format: date-time description: LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client. last_commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: Commit contains the evidence that a block was committed by a set of validators. description: >- Block is tendermint type Block, with the Header proposer address field converted to bech32 string. description: GetBlockByHeightResponse is the response type for the Query/GetBlockByHeight RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: height in: path required: true schema: type: string format: int64 tags: - gRPC Gateway API /cosmos/base/tendermint/v1beta1/node_info: get: summary: GetNodeInfo queries the current node info. operationId: GetNodeInfo_IVP7S responses: "200": description: A successful response. content: application/json: schema: type: object properties: default_node_info: type: object properties: protocol_version: type: object properties: p2p: type: string format: uint64 block: type: string format: uint64 app: type: string format: uint64 default_node_id: type: string listen_addr: type: string network: type: string version: type: string channels: type: string format: byte moniker: type: string other: type: object properties: tx_index: type: string rpc_address: type: string application_version: type: object properties: name: type: string app_name: type: string version: type: string git_commit: type: string build_tags: type: string go_version: type: string build_deps: type: array items: type: object properties: path: type: string title: module path version: type: string title: module version sum: type: string title: checksum title: Module is the type for VersionInfo cosmos_sdk_version: type: string title: "Since: cosmos-sdk 0.43" description: VersionInfo is the type for the GetNodeInfoResponse message. description: GetNodeInfoResponse is the response type for the Query/GetNodeInfo RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/base/tendermint/v1beta1/syncing: get: summary: GetSyncing queries node syncing. operationId: GetSyncing_9SHWP responses: "200": description: A successful response. content: application/json: schema: type: object properties: syncing: type: boolean description: GetSyncingResponse is the response type for the Query/GetSyncing RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/base/tendermint/v1beta1/validatorsets/latest: get: summary: GetLatestValidatorSet queries latest validator-set. operationId: GetLatestValidatorSet_Y0S55 responses: "200": description: A successful response. content: application/json: schema: type: object properties: block_height: type: string format: int64 validators: type: array items: type: object properties: address: type: string pub_key: type: object properties: type_url: type: string value: type: string format: byte voting_power: type: string format: int64 proposer_priority: type: string format: int64 description: Validator is the type for the validator-set. pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: GetLatestValidatorSetResponse is the response type for the Query/GetValidatorSetByHeight RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/cosmos/base/tendermint/v1beta1/validatorsets/{height}": get: summary: GetValidatorSetByHeight queries validator-set at a given height. operationId: GetValidatorSetByHeight_WR03D responses: "200": description: A successful response. content: application/json: schema: type: object properties: block_height: type: string format: int64 validators: type: array items: type: object properties: address: type: string pub_key: type: object properties: type_url: type: string value: type: string format: byte voting_power: type: string format: int64 proposer_priority: type: string format: int64 description: Validator is the type for the validator-set. pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: GetValidatorSetByHeightResponse is the response type for the Query/GetValidatorSetByHeight RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: height in: path required: true schema: type: string format: int64 - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API /cosmos/slashing/v1beta1/params: get: summary: Params queries the parameters of slashing module operationId: Params_MFGZ0 responses: "200": description: A successful response. content: application/json: schema: type: object properties: params: type: object properties: signed_blocks_window: type: string format: int64 min_signed_per_window: type: string format: byte downtime_jail_duration: type: string slash_fraction_double_sign: type: string format: byte slash_fraction_downtime: type: string format: byte description: Params represents the parameters used for by the slashing module. title: QueryParamsResponse is the response type for the Query/Params RPC method default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/slashing/v1beta1/signing_infos: get: summary: SigningInfos queries signing info of all validators operationId: SigningInfos_SD3H8 responses: "200": description: A successful response. content: application/json: schema: type: object properties: info: type: array items: type: object properties: address: type: string start_height: type: string format: int64 title: Height at which validator was first a candidate OR was unjailed index_offset: type: string format: int64 description: >- Index which is incremented each time the validator was a bonded in a block and may have signed a precommit or not. This in conjunction with the `SignedBlocksWindow` param determines the index in the `MissedBlocksBitArray`. jailed_until: type: string format: date-time description: Timestamp until which the validator is jailed due to liveness downtime. tombstoned: type: boolean description: >- Whether or not a validator has been tombstoned (killed out of validator set). It is set once the validator commits an equivocation or for any other configured misbehiavor. missed_blocks_counter: type: string format: int64 description: >- A counter kept to avoid unnecessary array reads. Note that `Sum(MissedBlocksBitArray)` always equals `MissedBlocksCounter`. description: >- ValidatorSigningInfo defines a validator's signing info for monitoring their liveness activity. title: info is the signing info of all validators pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: >- QuerySigningInfosResponse is the response type for the Query/SigningInfos RPC method default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/cosmos/slashing/v1beta1/signing_infos/{cons_address}": get: summary: SigningInfo queries the signing info of given cons address operationId: SigningInfo_2HQ8N responses: "200": description: A successful response. content: application/json: schema: type: object properties: val_signing_info: type: object properties: address: type: string start_height: type: string format: int64 title: Height at which validator was first a candidate OR was unjailed index_offset: type: string format: int64 description: >- Index which is incremented each time the validator was a bonded in a block and may have signed a precommit or not. This in conjunction with the `SignedBlocksWindow` param determines the index in the `MissedBlocksBitArray`. jailed_until: type: string format: date-time description: Timestamp until which the validator is jailed due to liveness downtime. tombstoned: type: boolean description: >- Whether or not a validator has been tombstoned (killed out of validator set). It is set once the validator commits an equivocation or for any other configured misbehiavor. missed_blocks_counter: type: string format: int64 description: >- A counter kept to avoid unnecessary array reads. Note that `Sum(MissedBlocksBitArray)` always equals `MissedBlocksCounter`. description: >- ValidatorSigningInfo defines a validator's signing info for monitoring their liveness activity. title: val_signing_info is the signing info of requested val cons address title: >- QuerySigningInfoResponse is the response type for the Query/SigningInfo RPC method default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: cons_address description: cons_address is the address to query signing info of in: path required: true schema: type: string tags: - gRPC Gateway API "/cosmos/gov/v1beta1/params/{params_type}": get: summary: Params queries all parameters of the gov module. operationId: Params_PJJN8 responses: "200": description: A successful response. content: application/json: schema: type: object properties: voting_params: description: voting_params defines the parameters related to voting. type: object properties: voting_period: type: string description: Duration of the voting period. deposit_params: description: deposit_params defines the parameters related to deposit. type: object properties: min_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: Minimum deposit for a proposal to enter voting period. max_deposit_period: type: string description: >- Maximum period for Atom holders to deposit on a proposal. Initial value: 2 months. tally_params: description: tally_params defines the parameters related to tally. type: object properties: quorum: type: string format: byte description: >- Minimum percentage of total stake needed to vote for a result to be considered valid. threshold: type: string format: byte description: "Minimum proportion of Yes votes for proposal to pass. Default value: 0.5." veto_threshold: type: string format: byte description: >- Minimum value of Veto votes to Total votes ratio for proposal to be vetoed. Default value: 1/3. description: QueryParamsResponse is the response type for the Query/Params RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: params_type description: >- params_type defines which parameters to query for, can be one of "voting", "tallying" or "deposit". in: path required: true schema: type: string tags: - gRPC Gateway API /cosmos/gov/v1beta1/proposals: get: summary: Proposals queries all proposals based on given status. operationId: Proposals_XD66Y responses: "200": description: A successful response. content: application/json: schema: type: object properties: proposals: type: array items: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. content: type: object properties: type_url: type: string value: type: string format: byte description: content is the proposal's content. status: description: status defines the proposal status. type: string enum: - PROPOSAL_STATUS_UNSPECIFIED - PROPOSAL_STATUS_DEPOSIT_PERIOD - PROPOSAL_STATUS_VOTING_PERIOD - PROPOSAL_STATUS_PASSED - PROPOSAL_STATUS_REJECTED - PROPOSAL_STATUS_FAILED default: PROPOSAL_STATUS_UNSPECIFIED final_tally_result: description: >- final_tally_result is the final tally result of the proposal. When querying a proposal via gRPC, this field is not populated until the proposal's voting period has ended. type: object properties: yes: type: string description: yes is the number of yes votes on a proposal. abstain: type: string description: abstain is the number of abstain votes on a proposal. no: type: string description: no is the number of no votes on a proposal. no_with_veto: type: string description: no_with_veto is the number of no with veto votes on a proposal. submit_time: type: string format: date-time description: submit_time is the time of proposal submission. deposit_end_time: type: string format: date-time description: deposit_end_time is the end time for deposition. total_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: total_deposit is the total deposit on the proposal. voting_start_time: type: string format: date-time description: voting_start_time is the starting time to vote on a proposal. voting_end_time: type: string format: date-time description: voting_end_time is the end time of voting on a proposal. description: Proposal defines the core field members of a governance proposal. description: proposals defines all the requested governance proposals. pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- QueryProposalsResponse is the response type for the Query/Proposals RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: proposal_status description: >- proposal_status defines the status of the proposals. - PROPOSAL_STATUS_UNSPECIFIED: PROPOSAL_STATUS_UNSPECIFIED defines the default proposal status. - PROPOSAL_STATUS_DEPOSIT_PERIOD: PROPOSAL_STATUS_DEPOSIT_PERIOD defines a proposal status during the deposit period. - PROPOSAL_STATUS_VOTING_PERIOD: PROPOSAL_STATUS_VOTING_PERIOD defines a proposal status during the voting period. - PROPOSAL_STATUS_PASSED: PROPOSAL_STATUS_PASSED defines a proposal status of a proposal that has passed. - PROPOSAL_STATUS_REJECTED: PROPOSAL_STATUS_REJECTED defines a proposal status of a proposal that has been rejected. - PROPOSAL_STATUS_FAILED: PROPOSAL_STATUS_FAILED defines a proposal status of a proposal that has failed. in: query required: false schema: type: string enum: - PROPOSAL_STATUS_UNSPECIFIED - PROPOSAL_STATUS_DEPOSIT_PERIOD - PROPOSAL_STATUS_VOTING_PERIOD - PROPOSAL_STATUS_PASSED - PROPOSAL_STATUS_REJECTED - PROPOSAL_STATUS_FAILED default: PROPOSAL_STATUS_UNSPECIFIED - name: voter description: voter defines the voter address for the proposals. in: query required: false schema: type: string - name: depositor description: depositor defines the deposit addresses from the proposals. in: query required: false schema: type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/cosmos/gov/v1beta1/proposals/{proposal_id}": get: summary: Proposal queries proposal details based on ProposalID. operationId: Proposal_Q4TVD responses: "200": description: A successful response. content: application/json: schema: type: object properties: proposal: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. content: type: object properties: type_url: type: string value: type: string format: byte description: content is the proposal's content. status: description: status defines the proposal status. type: string enum: - PROPOSAL_STATUS_UNSPECIFIED - PROPOSAL_STATUS_DEPOSIT_PERIOD - PROPOSAL_STATUS_VOTING_PERIOD - PROPOSAL_STATUS_PASSED - PROPOSAL_STATUS_REJECTED - PROPOSAL_STATUS_FAILED default: PROPOSAL_STATUS_UNSPECIFIED final_tally_result: description: >- final_tally_result is the final tally result of the proposal. When querying a proposal via gRPC, this field is not populated until the proposal's voting period has ended. type: object properties: yes: type: string description: yes is the number of yes votes on a proposal. abstain: type: string description: abstain is the number of abstain votes on a proposal. no: type: string description: no is the number of no votes on a proposal. no_with_veto: type: string description: no_with_veto is the number of no with veto votes on a proposal. submit_time: type: string format: date-time description: submit_time is the time of proposal submission. deposit_end_time: type: string format: date-time description: deposit_end_time is the end time for deposition. total_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: total_deposit is the total deposit on the proposal. voting_start_time: type: string format: date-time description: voting_start_time is the starting time to vote on a proposal. voting_end_time: type: string format: date-time description: voting_end_time is the end time of voting on a proposal. description: Proposal defines the core field members of a governance proposal. description: QueryProposalResponse is the response type for the Query/Proposal RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: proposal_id description: proposal_id defines the unique id of the proposal. in: path required: true schema: type: string format: uint64 tags: - gRPC Gateway API "/cosmos/gov/v1beta1/proposals/{proposal_id}/deposits": get: summary: Deposits queries all deposits of a single proposal. operationId: Deposits_1L75C responses: "200": description: A successful response. content: application/json: schema: type: object properties: deposits: type: array items: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. depositor: type: string description: depositor defines the deposit addresses from the proposals. amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: amount to be deposited by depositor. description: >- Deposit defines an amount deposited by an account address to an active proposal. description: deposits defines the requested deposits. pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: QueryDepositsResponse is the response type for the Query/Deposits RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: proposal_id description: proposal_id defines the unique id of the proposal. in: path required: true schema: type: string format: uint64 - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/cosmos/gov/v1beta1/proposals/{proposal_id}/deposits/{depositor}": get: summary: Deposit queries single deposit information based proposalID, depositAddr. operationId: Deposit_VE3QO responses: "200": description: A successful response. content: application/json: schema: type: object properties: deposit: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. depositor: type: string description: depositor defines the deposit addresses from the proposals. amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: amount to be deposited by depositor. description: >- Deposit defines an amount deposited by an account address to an active proposal. description: QueryDepositResponse is the response type for the Query/Deposit RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: proposal_id description: proposal_id defines the unique id of the proposal. in: path required: true schema: type: string format: uint64 - name: depositor description: depositor defines the deposit addresses from the proposals. in: path required: true schema: type: string tags: - gRPC Gateway API "/cosmos/gov/v1beta1/proposals/{proposal_id}/tally": get: summary: TallyResult queries the tally of a proposal vote. operationId: TallyResult_WW72B responses: "200": description: A successful response. content: application/json: schema: type: object properties: tally: description: tally defines the requested tally. type: object properties: yes: type: string description: yes is the number of yes votes on a proposal. abstain: type: string description: abstain is the number of abstain votes on a proposal. no: type: string description: no is the number of no votes on a proposal. no_with_veto: type: string description: no_with_veto is the number of no with veto votes on a proposal. description: QueryTallyResultResponse is the response type for the Query/Tally RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: proposal_id description: proposal_id defines the unique id of the proposal. in: path required: true schema: type: string format: uint64 tags: - gRPC Gateway API "/cosmos/gov/v1beta1/proposals/{proposal_id}/votes": get: summary: Votes queries votes of a given proposal. operationId: Votes_M6ZAN responses: "200": description: A successful response. content: application/json: schema: type: object properties: votes: type: array items: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. voter: type: string description: voter is the voter address of the proposal. option: description: >- Deprecated: Prefer to use `options` instead. This field is set in queries if and only if `len(options) == 1` and that option has weight 1. In all other cases, this field will default to VOTE_OPTION_UNSPECIFIED. type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED options: type: array items: type: object properties: option: description: option defines the valid vote options, it must not contain duplicate vote options. type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED weight: type: string description: weight is the vote weight associated with the vote option. description: >- WeightedVoteOption defines a unit of vote for vote split. Since: cosmos-sdk 0.43 description: |- options is the weighted vote options. Since: cosmos-sdk 0.43 description: >- Vote defines a vote on a governance proposal. A Vote consists of a proposal ID, the voter, and the vote option. description: votes defines the queried votes. pagination: type: object properties: next_key: type: string format: byte description: >- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: QueryVotesResponse is the response type for the Query/Votes RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: proposal_id description: proposal_id defines the unique id of the proposal. in: path required: true schema: type: string format: uint64 - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false schema: type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false schema: type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false schema: type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false schema: type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false schema: type: boolean tags: - gRPC Gateway API "/cosmos/gov/v1beta1/proposals/{proposal_id}/votes/{voter}": get: summary: Vote queries voted information based on proposalID, voterAddr. operationId: Vote_4I9SV responses: "200": description: A successful response. content: application/json: schema: type: object properties: vote: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. voter: type: string description: voter is the voter address of the proposal. option: description: >- Deprecated: Prefer to use `options` instead. This field is set in queries if and only if `len(options) == 1` and that option has weight 1. In all other cases, this field will default to VOTE_OPTION_UNSPECIFIED. type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED options: type: array items: type: object properties: option: description: option defines the valid vote options, it must not contain duplicate vote options. type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED weight: type: string description: weight is the vote weight associated with the vote option. description: >- WeightedVoteOption defines a unit of vote for vote split. Since: cosmos-sdk 0.43 description: |- options is the weighted vote options. Since: cosmos-sdk 0.43 description: >- Vote defines a vote on a governance proposal. A Vote consists of a proposal ID, the voter, and the vote option. description: QueryVoteResponse is the response type for the Query/Vote RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: proposal_id description: proposal_id defines the unique id of the proposal. in: path required: true schema: type: string format: uint64 - name: voter description: voter defines the voter address for the proposals. in: path required: true schema: type: string tags: - gRPC Gateway API /cosmos/mint/v1beta1/annual_provisions: get: summary: AnnualProvisions current minting annual provisions value. operationId: AnnualProvisions_JHHBU responses: "200": description: A successful response. content: application/json: schema: type: object properties: annual_provisions: type: string format: byte description: annual_provisions is the current minting annual provisions value. description: |- QueryAnnualProvisionsResponse is the response type for the Query/AnnualProvisions RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/mint/v1beta1/inflation: get: summary: Inflation returns the current minting inflation value. operationId: Inflation_RXNBT responses: "200": description: A successful response. content: application/json: schema: type: object properties: inflation: type: string format: byte description: inflation is the current minting inflation value. description: >- QueryInflationResponse is the response type for the Query/Inflation RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/mint/v1beta1/params: get: summary: Params returns the total set of minting parameters. operationId: Params_3M1PF responses: "200": description: A successful response. content: application/json: schema: type: object properties: params: description: params defines the parameters of the module. type: object properties: mint_denom: type: string title: type of coin to mint inflation_rate_change: type: string title: maximum annual change in inflation rate inflation_max: type: string title: maximum inflation rate inflation_min: type: string title: minimum inflation rate goal_bonded: type: string title: goal of percent bonded atoms blocks_per_year: type: string format: uint64 title: expected blocks per year description: QueryParamsResponse is the response type for the Query/Params RPC method. default: description: An unexpected error response. content: application/json: schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API components: schemas: cosmos.consensus.v1.QueryParamsResponse: type: object properties: params: description: >- params are the tendermint consensus params stored in the consensus module. Please note that `params.version` is not populated in this response, it is tracked separately in the x/upgrade module. type: object properties: block: type: object properties: max_bytes: type: string format: int64 title: |- Max block size, in bytes. Note: must be greater than 0 max_gas: type: string format: int64 title: |- Max gas per block. Note: must be greater or equal to -1 description: BlockParams contains limits on the block size. evidence: type: object properties: max_age_num_blocks: type: string format: int64 description: >- Max age of evidence, in blocks. The basic formula for calculating this is: MaxAgeDuration / {average block time}. max_age_duration: type: string description: >- Max age of evidence, in time. It should correspond with an app's "unbonding period" or other similar mechanism for handling [Nothing-At-Stake attacks](https://github.com/ethereum/wiki/wiki/Proof-of-Stake-FAQ#what-is-the-nothing-at-stake-problem-and-how-can-it-be-fixed). max_bytes: type: string format: int64 title: >- This sets the maximum size of total evidence in bytes that can be committed in a single block. and should fall comfortably under the max block bytes. Default is 1048576 or 1MB description: EvidenceParams determine how we handle evidence of malfeasance. validator: type: object properties: pub_key_types: type: array items: type: string description: >- ValidatorParams restrict the public key types validators can use. NOTE: uses ABCI pubkey naming, not Amino names. version: type: object properties: app: type: string format: uint64 description: VersionParams contains the ABCI application version. description: QueryParamsResponse defines the response type for querying x/consensus parameters. google.protobuf.Any: type: object properties: type_url: type: string value: type: string format: byte grpc.gateway.runtime.Error: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tendermint.types.BlockParams: type: object properties: max_bytes: type: string format: int64 title: |- Max block size, in bytes. Note: must be greater than 0 max_gas: type: string format: int64 title: |- Max gas per block. Note: must be greater or equal to -1 description: BlockParams contains limits on the block size. tendermint.types.ConsensusParams: type: object properties: block: type: object properties: max_bytes: type: string format: int64 title: |- Max block size, in bytes. Note: must be greater than 0 max_gas: type: string format: int64 title: |- Max gas per block. Note: must be greater or equal to -1 description: BlockParams contains limits on the block size. evidence: type: object properties: max_age_num_blocks: type: string format: int64 description: >- Max age of evidence, in blocks. The basic formula for calculating this is: MaxAgeDuration / {average block time}. max_age_duration: type: string description: >- Max age of evidence, in time. It should correspond with an app's "unbonding period" or other similar mechanism for handling [Nothing-At-Stake attacks](https://github.com/ethereum/wiki/wiki/Proof-of-Stake-FAQ#what-is-the-nothing-at-stake-problem-and-how-can-it-be-fixed). max_bytes: type: string format: int64 title: >- This sets the maximum size of total evidence in bytes that can be committed in a single block. and should fall comfortably under the max block bytes. Default is 1048576 or 1MB description: EvidenceParams determine how we handle evidence of malfeasance. validator: type: object properties: pub_key_types: type: array items: type: string description: |- ValidatorParams restrict the public key types validators can use. NOTE: uses ABCI pubkey naming, not Amino names. version: type: object properties: app: type: string format: uint64 description: VersionParams contains the ABCI application version. description: >- ConsensusParams contains consensus critical parameters that determine the validity of blocks. tendermint.types.EvidenceParams: type: object properties: max_age_num_blocks: type: string format: int64 description: >- Max age of evidence, in blocks. The basic formula for calculating this is: MaxAgeDuration / {average block time}. max_age_duration: type: string description: >- Max age of evidence, in time. It should correspond with an app's "unbonding period" or other similar mechanism for handling [Nothing-At-Stake attacks](https://github.com/ethereum/wiki/wiki/Proof-of-Stake-FAQ#what-is-the-nothing-at-stake-problem-and-how-can-it-be-fixed). max_bytes: type: string format: int64 title: >- This sets the maximum size of total evidence in bytes that can be committed in a single block. and should fall comfortably under the max block bytes. Default is 1048576 or 1MB description: EvidenceParams determine how we handle evidence of malfeasance. tendermint.types.ValidatorParams: type: object properties: pub_key_types: type: array items: type: string description: |- ValidatorParams restrict the public key types validators can use. NOTE: uses ABCI pubkey naming, not Amino names. tendermint.types.VersionParams: type: object properties: app: type: string format: uint64 description: VersionParams contains the ABCI application version. cosmos.base.query.v1beta1.PageRequest: type: object properties: key: type: string format: byte description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. offset: type: string format: uint64 description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. limit: type: string format: uint64 description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. count_total: type: boolean description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. reverse: type: boolean description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 description: |- message SomeRequest { Foo some_parameter = 1; PageRequest pagination = 2; } title: |- PageRequest is to be embedded in gRPC request messages for efficient pagination. Ex: cosmos.base.query.v1beta1.PageResponse: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } cosmos.feegrant.v1beta1.Grant: type: object properties: granter: type: string description: granter is the address of the user granting an allowance of their funds. grantee: type: string description: grantee is the address of the user being granted an allowance of another user's funds. allowance: type: object properties: type_url: type: string value: type: string format: byte description: allowance can be any of basic, periodic, allowed fee allowance. title: Grant is stored in the KVStore to record a grant with full context cosmos.feegrant.v1beta1.QueryAllowanceResponse: type: object properties: allowance: description: allowance is a allowance granted for grantee by granter. type: object properties: granter: type: string description: granter is the address of the user granting an allowance of their funds. grantee: type: string description: grantee is the address of the user being granted an allowance of another user's funds. allowance: type: object properties: type_url: type: string value: type: string format: byte description: allowance can be any of basic, periodic, allowed fee allowance. title: Grant is stored in the KVStore to record a grant with full context description: QueryAllowanceResponse is the response type for the Query/Allowance RPC method. cosmos.feegrant.v1beta1.QueryAllowancesByGranterResponse: type: object properties: allowances: type: array items: type: object properties: granter: type: string description: granter is the address of the user granting an allowance of their funds. grantee: type: string description: grantee is the address of the user being granted an allowance of another user's funds. allowance: type: object properties: type_url: type: string value: type: string format: byte description: allowance can be any of basic, periodic, allowed fee allowance. title: Grant is stored in the KVStore to record a grant with full context description: allowances that have been issued by the granter. pagination: description: pagination defines an pagination for the response. type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- QueryAllowancesByGranterResponse is the response type for the Query/AllowancesByGranter RPC method. Since: cosmos-sdk 0.46 cosmos.feegrant.v1beta1.QueryAllowancesResponse: type: object properties: allowances: type: array items: type: object properties: granter: type: string description: granter is the address of the user granting an allowance of their funds. grantee: type: string description: grantee is the address of the user being granted an allowance of another user's funds. allowance: type: object properties: type_url: type: string value: type: string format: byte description: allowance can be any of basic, periodic, allowed fee allowance. title: Grant is stored in the KVStore to record a grant with full context description: allowances are allowance's granted for grantee by granter. pagination: description: pagination defines an pagination for the response. type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: QueryAllowancesResponse is the response type for the Query/Allowances RPC method. cosmos.base.v1beta1.Coin: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. cosmos.gov.v1.Deposit: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. depositor: type: string description: depositor defines the deposit addresses from the proposals. amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: amount to be deposited by depositor. description: |- Deposit defines an amount deposited by an account address to an active proposal. cosmos.gov.v1.DepositParams: type: object properties: min_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: Minimum deposit for a proposal to enter voting period. max_deposit_period: type: string description: >- Maximum period for Atom holders to deposit on a proposal. Initial value: 2 months. description: DepositParams defines the params for deposits on governance proposals. cosmos.gov.v1.Params: type: object properties: min_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: Minimum deposit for a proposal to enter voting period. max_deposit_period: type: string description: >- Maximum period for Atom holders to deposit on a proposal. Initial value: 2 months. voting_period: type: string description: Duration of the voting period. quorum: type: string description: |- Minimum percentage of total stake needed to vote for a result to be considered valid. threshold: type: string description: "Minimum proportion of Yes votes for proposal to pass. Default value: 0.5." veto_threshold: type: string description: |- Minimum value of Veto votes to Total votes ratio for proposal to be vetoed. Default value: 1/3. min_initial_deposit_ratio: type: string description: The ratio representing the proportion of the deposit value that must be paid at proposal submission. burn_vote_quorum: type: boolean title: burn deposits if a proposal does not meet quorum burn_proposal_deposit_prevote: type: boolean title: burn deposits if the proposal does not enter voting period burn_vote_veto: type: boolean title: burn deposits if quorum with vote type no_veto is met description: |- Params defines the parameters for the x/gov module. Since: cosmos-sdk 0.47 cosmos.gov.v1.Proposal: type: object properties: id: type: string format: uint64 description: id defines the unique id of the proposal. messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: messages are the arbitrary messages to be executed if the proposal passes. status: description: status defines the proposal status. type: string enum: - PROPOSAL_STATUS_UNSPECIFIED - PROPOSAL_STATUS_DEPOSIT_PERIOD - PROPOSAL_STATUS_VOTING_PERIOD - PROPOSAL_STATUS_PASSED - PROPOSAL_STATUS_REJECTED - PROPOSAL_STATUS_FAILED default: PROPOSAL_STATUS_UNSPECIFIED final_tally_result: description: |- final_tally_result is the final tally result of the proposal. When querying a proposal via gRPC, this field is not populated until the proposal's voting period has ended. type: object properties: yes_count: type: string description: yes_count is the number of yes votes on a proposal. abstain_count: type: string description: abstain_count is the number of abstain votes on a proposal. no_count: type: string description: no_count is the number of no votes on a proposal. no_with_veto_count: type: string description: no_with_veto_count is the number of no with veto votes on a proposal. submit_time: type: string format: date-time description: submit_time is the time of proposal submission. deposit_end_time: type: string format: date-time description: deposit_end_time is the end time for deposition. total_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: total_deposit is the total deposit on the proposal. voting_start_time: type: string format: date-time description: voting_start_time is the starting time to vote on a proposal. voting_end_time: type: string format: date-time description: voting_end_time is the end time of voting on a proposal. metadata: type: string description: metadata is any arbitrary metadata attached to the proposal. title: type: string description: "Since: cosmos-sdk 0.47" title: title is the title of the proposal summary: type: string description: "Since: cosmos-sdk 0.47" title: summary is a short summary of the proposal proposer: type: string description: "Since: cosmos-sdk 0.47" title: Proposer is the address of the proposal sumbitter description: Proposal defines the core field members of a governance proposal. cosmos.gov.v1.ProposalStatus: type: string enum: - PROPOSAL_STATUS_UNSPECIFIED - PROPOSAL_STATUS_DEPOSIT_PERIOD - PROPOSAL_STATUS_VOTING_PERIOD - PROPOSAL_STATUS_PASSED - PROPOSAL_STATUS_REJECTED - PROPOSAL_STATUS_FAILED default: PROPOSAL_STATUS_UNSPECIFIED description: >- ProposalStatus enumerates the valid statuses of a proposal. - PROPOSAL_STATUS_UNSPECIFIED: PROPOSAL_STATUS_UNSPECIFIED defines the default proposal status. - PROPOSAL_STATUS_DEPOSIT_PERIOD: PROPOSAL_STATUS_DEPOSIT_PERIOD defines a proposal status during the deposit period. - PROPOSAL_STATUS_VOTING_PERIOD: PROPOSAL_STATUS_VOTING_PERIOD defines a proposal status during the voting period. - PROPOSAL_STATUS_PASSED: PROPOSAL_STATUS_PASSED defines a proposal status of a proposal that has passed. - PROPOSAL_STATUS_REJECTED: PROPOSAL_STATUS_REJECTED defines a proposal status of a proposal that has been rejected. - PROPOSAL_STATUS_FAILED: PROPOSAL_STATUS_FAILED defines a proposal status of a proposal that has failed. cosmos.gov.v1.QueryDepositResponse: type: object properties: deposit: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. depositor: type: string description: depositor defines the deposit addresses from the proposals. amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: amount to be deposited by depositor. description: >- Deposit defines an amount deposited by an account address to an active proposal. description: QueryDepositResponse is the response type for the Query/Deposit RPC method. cosmos.gov.v1.QueryDepositsResponse: type: object properties: deposits: type: array items: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. depositor: type: string description: depositor defines the deposit addresses from the proposals. amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: amount to be deposited by depositor. description: >- Deposit defines an amount deposited by an account address to an active proposal. description: deposits defines the requested deposits. pagination: description: pagination defines the pagination in the response. type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: QueryDepositsResponse is the response type for the Query/Deposits RPC method. cosmos.gov.v1.QueryParamsResponse: type: object properties: voting_params: description: |- Deprecated: Prefer to use `params` instead. voting_params defines the parameters related to voting. type: object properties: voting_period: type: string description: Duration of the voting period. deposit_params: description: |- Deprecated: Prefer to use `params` instead. deposit_params defines the parameters related to deposit. type: object properties: min_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: Minimum deposit for a proposal to enter voting period. max_deposit_period: type: string description: >- Maximum period for Atom holders to deposit on a proposal. Initial value: 2 months. tally_params: description: |- Deprecated: Prefer to use `params` instead. tally_params defines the parameters related to tally. type: object properties: quorum: type: string description: >- Minimum percentage of total stake needed to vote for a result to be considered valid. threshold: type: string description: "Minimum proportion of Yes votes for proposal to pass. Default value: 0.5." veto_threshold: type: string description: >- Minimum value of Veto votes to Total votes ratio for proposal to be vetoed. Default value: 1/3. params: description: |- params defines all the paramaters of x/gov module. Since: cosmos-sdk 0.47 type: object properties: min_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: Minimum deposit for a proposal to enter voting period. max_deposit_period: type: string description: >- Maximum period for Atom holders to deposit on a proposal. Initial value: 2 months. voting_period: type: string description: Duration of the voting period. quorum: type: string description: >- Minimum percentage of total stake needed to vote for a result to be considered valid. threshold: type: string description: "Minimum proportion of Yes votes for proposal to pass. Default value: 0.5." veto_threshold: type: string description: >- Minimum value of Veto votes to Total votes ratio for proposal to be vetoed. Default value: 1/3. min_initial_deposit_ratio: type: string description: The ratio representing the proportion of the deposit value that must be paid at proposal submission. burn_vote_quorum: type: boolean title: burn deposits if a proposal does not meet quorum burn_proposal_deposit_prevote: type: boolean title: burn deposits if the proposal does not enter voting period burn_vote_veto: type: boolean title: burn deposits if quorum with vote type no_veto is met description: QueryParamsResponse is the response type for the Query/Params RPC method. cosmos.gov.v1.QueryProposalResponse: type: object properties: proposal: type: object properties: id: type: string format: uint64 description: id defines the unique id of the proposal. messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: messages are the arbitrary messages to be executed if the proposal passes. status: description: status defines the proposal status. type: string enum: - PROPOSAL_STATUS_UNSPECIFIED - PROPOSAL_STATUS_DEPOSIT_PERIOD - PROPOSAL_STATUS_VOTING_PERIOD - PROPOSAL_STATUS_PASSED - PROPOSAL_STATUS_REJECTED - PROPOSAL_STATUS_FAILED default: PROPOSAL_STATUS_UNSPECIFIED final_tally_result: description: >- final_tally_result is the final tally result of the proposal. When querying a proposal via gRPC, this field is not populated until the proposal's voting period has ended. type: object properties: yes_count: type: string description: yes_count is the number of yes votes on a proposal. abstain_count: type: string description: abstain_count is the number of abstain votes on a proposal. no_count: type: string description: no_count is the number of no votes on a proposal. no_with_veto_count: type: string description: no_with_veto_count is the number of no with veto votes on a proposal. submit_time: type: string format: date-time description: submit_time is the time of proposal submission. deposit_end_time: type: string format: date-time description: deposit_end_time is the end time for deposition. total_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: total_deposit is the total deposit on the proposal. voting_start_time: type: string format: date-time description: voting_start_time is the starting time to vote on a proposal. voting_end_time: type: string format: date-time description: voting_end_time is the end time of voting on a proposal. metadata: type: string description: metadata is any arbitrary metadata attached to the proposal. title: type: string description: "Since: cosmos-sdk 0.47" title: title is the title of the proposal summary: type: string description: "Since: cosmos-sdk 0.47" title: summary is a short summary of the proposal proposer: type: string description: "Since: cosmos-sdk 0.47" title: Proposer is the address of the proposal sumbitter description: Proposal defines the core field members of a governance proposal. description: QueryProposalResponse is the response type for the Query/Proposal RPC method. cosmos.gov.v1.QueryProposalsResponse: type: object properties: proposals: type: array items: type: object properties: id: type: string format: uint64 description: id defines the unique id of the proposal. messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: messages are the arbitrary messages to be executed if the proposal passes. status: description: status defines the proposal status. type: string enum: - PROPOSAL_STATUS_UNSPECIFIED - PROPOSAL_STATUS_DEPOSIT_PERIOD - PROPOSAL_STATUS_VOTING_PERIOD - PROPOSAL_STATUS_PASSED - PROPOSAL_STATUS_REJECTED - PROPOSAL_STATUS_FAILED default: PROPOSAL_STATUS_UNSPECIFIED final_tally_result: description: >- final_tally_result is the final tally result of the proposal. When querying a proposal via gRPC, this field is not populated until the proposal's voting period has ended. type: object properties: yes_count: type: string description: yes_count is the number of yes votes on a proposal. abstain_count: type: string description: abstain_count is the number of abstain votes on a proposal. no_count: type: string description: no_count is the number of no votes on a proposal. no_with_veto_count: type: string description: no_with_veto_count is the number of no with veto votes on a proposal. submit_time: type: string format: date-time description: submit_time is the time of proposal submission. deposit_end_time: type: string format: date-time description: deposit_end_time is the end time for deposition. total_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: total_deposit is the total deposit on the proposal. voting_start_time: type: string format: date-time description: voting_start_time is the starting time to vote on a proposal. voting_end_time: type: string format: date-time description: voting_end_time is the end time of voting on a proposal. metadata: type: string description: metadata is any arbitrary metadata attached to the proposal. title: type: string description: "Since: cosmos-sdk 0.47" title: title is the title of the proposal summary: type: string description: "Since: cosmos-sdk 0.47" title: summary is a short summary of the proposal proposer: type: string description: "Since: cosmos-sdk 0.47" title: Proposer is the address of the proposal sumbitter description: Proposal defines the core field members of a governance proposal. description: proposals defines all the requested governance proposals. pagination: description: pagination defines the pagination in the response. type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- QueryProposalsResponse is the response type for the Query/Proposals RPC method. cosmos.gov.v1.QueryTallyResultResponse: type: object properties: tally: description: tally defines the requested tally. type: object properties: yes_count: type: string description: yes_count is the number of yes votes on a proposal. abstain_count: type: string description: abstain_count is the number of abstain votes on a proposal. no_count: type: string description: no_count is the number of no votes on a proposal. no_with_veto_count: type: string description: no_with_veto_count is the number of no with veto votes on a proposal. description: QueryTallyResultResponse is the response type for the Query/Tally RPC method. cosmos.gov.v1.QueryVoteResponse: type: object properties: vote: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. voter: type: string description: voter is the voter address of the proposal. options: type: array items: type: object properties: option: description: option defines the valid vote options, it must not contain duplicate vote options. type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED weight: type: string description: weight is the vote weight associated with the vote option. description: WeightedVoteOption defines a unit of vote for vote split. description: options is the weighted vote options. metadata: type: string description: metadata is any arbitrary metadata to attached to the vote. description: |- Vote defines a vote on a governance proposal. A Vote consists of a proposal ID, the voter, and the vote option. description: QueryVoteResponse is the response type for the Query/Vote RPC method. cosmos.gov.v1.QueryVotesResponse: type: object properties: votes: type: array items: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. voter: type: string description: voter is the voter address of the proposal. options: type: array items: type: object properties: option: description: option defines the valid vote options, it must not contain duplicate vote options. type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED weight: type: string description: weight is the vote weight associated with the vote option. description: WeightedVoteOption defines a unit of vote for vote split. description: options is the weighted vote options. metadata: type: string description: metadata is any arbitrary metadata to attached to the vote. description: |- Vote defines a vote on a governance proposal. A Vote consists of a proposal ID, the voter, and the vote option. description: votes defines the queried votes. pagination: description: pagination defines the pagination in the response. type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: QueryVotesResponse is the response type for the Query/Votes RPC method. cosmos.gov.v1.TallyParams: type: object properties: quorum: type: string description: |- Minimum percentage of total stake needed to vote for a result to be considered valid. threshold: type: string description: "Minimum proportion of Yes votes for proposal to pass. Default value: 0.5." veto_threshold: type: string description: |- Minimum value of Veto votes to Total votes ratio for proposal to be vetoed. Default value: 1/3. description: TallyParams defines the params for tallying votes on governance proposals. cosmos.gov.v1.TallyResult: type: object properties: yes_count: type: string description: yes_count is the number of yes votes on a proposal. abstain_count: type: string description: abstain_count is the number of abstain votes on a proposal. no_count: type: string description: no_count is the number of no votes on a proposal. no_with_veto_count: type: string description: no_with_veto_count is the number of no with veto votes on a proposal. description: TallyResult defines a standard tally for a governance proposal. cosmos.gov.v1.Vote: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. voter: type: string description: voter is the voter address of the proposal. options: type: array items: type: object properties: option: description: option defines the valid vote options, it must not contain duplicate vote options. type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED weight: type: string description: weight is the vote weight associated with the vote option. description: WeightedVoteOption defines a unit of vote for vote split. description: options is the weighted vote options. metadata: type: string description: metadata is any arbitrary metadata to attached to the vote. description: |- Vote defines a vote on a governance proposal. A Vote consists of a proposal ID, the voter, and the vote option. cosmos.gov.v1.VoteOption: type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED description: >- VoteOption enumerates the valid vote options for a given governance proposal. - VOTE_OPTION_UNSPECIFIED: VOTE_OPTION_UNSPECIFIED defines a no-op vote option. - VOTE_OPTION_YES: VOTE_OPTION_YES defines a yes vote option. - VOTE_OPTION_ABSTAIN: VOTE_OPTION_ABSTAIN defines an abstain vote option. - VOTE_OPTION_NO: VOTE_OPTION_NO defines a no vote option. - VOTE_OPTION_NO_WITH_VETO: VOTE_OPTION_NO_WITH_VETO defines a no with veto vote option. cosmos.gov.v1.VotingParams: type: object properties: voting_period: type: string description: Duration of the voting period. description: VotingParams defines the params for voting on governance proposals. cosmos.gov.v1.WeightedVoteOption: type: object properties: option: description: option defines the valid vote options, it must not contain duplicate vote options. type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED weight: type: string description: weight is the vote weight associated with the vote option. description: WeightedVoteOption defines a unit of vote for vote split. cyber.graph.v1beta1.QueryGraphStatsResponse: type: object properties: cyberlinks: type: string format: uint64 particles: type: string format: uint64 cyber.resources.v1beta1.Params: type: object properties: max_slots: type: integer format: int64 halving_period_volt_blocks: type: integer format: int64 halving_period_ampere_blocks: type: integer format: int64 base_investmint_period_volt: type: integer format: int64 base_investmint_period_ampere: type: integer format: int64 min_investmint_period: type: integer format: int64 base_investmint_amount_volt: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. base_investmint_amount_ampere: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. cyber.resources.v1beta1.QueryInvestmintResponse: type: object properties: amount: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. cyber.resources.v1beta1.QueryParamsResponse: type: object properties: params: type: object properties: max_slots: type: integer format: int64 halving_period_volt_blocks: type: integer format: int64 halving_period_ampere_blocks: type: integer format: int64 base_investmint_period_volt: type: integer format: int64 base_investmint_period_ampere: type: integer format: int64 min_investmint_period: type: integer format: int64 base_investmint_amount_volt: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. base_investmint_amount_ampere: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. cosmos.base.node.v1beta1.ConfigResponse: type: object properties: minimum_gas_price: type: string description: ConfigResponse defines the response structure for the Config gRPC query. cosmos.upgrade.v1beta1.ModuleVersion: type: object properties: name: type: string title: name of the app module version: type: string format: uint64 title: consensus version of the app module description: |- ModuleVersion specifies a module and its consensus version. Since: cosmos-sdk 0.43 cosmos.upgrade.v1beta1.Plan: type: object properties: name: type: string description: >- Sets the name for the upgrade. This name will be used by the upgraded version of the software to apply any special "on-upgrade" commands during the first BeginBlock method after the upgrade is applied. It is also used to detect whether a software version can handle a given upgrade. If no upgrade handler with this name has been set in the software, it will be assumed that the software is out-of-date when the upgrade Time or Height is reached and the software will exit. time: type: string format: date-time description: >- Deprecated: Time based upgrades have been deprecated. Time based upgrade logic has been removed from the SDK. If this field is not empty, an error will be thrown. height: type: string format: int64 description: The height at which the upgrade must be performed. info: type: string title: |- Any application specific upgrade info to be included on-chain such as a git commit that validators could automatically upgrade to upgraded_client_state: type: object properties: type_url: type: string value: type: string format: byte description: >- Deprecated: UpgradedClientState field has been deprecated. IBC upgrade logic has been moved to the IBC module in the sub module 02-client. If this field is not empty, an error will be thrown. description: Plan specifies information about a planned upgrade and when it should occur. cosmos.upgrade.v1beta1.QueryAppliedPlanResponse: type: object properties: height: type: string format: int64 description: height is the block height at which the plan was applied. description: >- QueryAppliedPlanResponse is the response type for the Query/AppliedPlan RPC method. cosmos.upgrade.v1beta1.QueryAuthorityResponse: type: object properties: address: type: string description: "Since: cosmos-sdk 0.46" title: QueryAuthorityResponse is the response type for Query/Authority cosmos.upgrade.v1beta1.QueryCurrentPlanResponse: type: object properties: plan: description: plan is the current upgrade plan. type: object properties: name: type: string description: >- Sets the name for the upgrade. This name will be used by the upgraded version of the software to apply any special "on-upgrade" commands during the first BeginBlock method after the upgrade is applied. It is also used to detect whether a software version can handle a given upgrade. If no upgrade handler with this name has been set in the software, it will be assumed that the software is out-of-date when the upgrade Time or Height is reached and the software will exit. time: type: string format: date-time description: >- Deprecated: Time based upgrades have been deprecated. Time based upgrade logic has been removed from the SDK. If this field is not empty, an error will be thrown. height: type: string format: int64 description: The height at which the upgrade must be performed. info: type: string title: >- Any application specific upgrade info to be included on-chain such as a git commit that validators could automatically upgrade to upgraded_client_state: type: object properties: type_url: type: string value: type: string format: byte description: >- Deprecated: UpgradedClientState field has been deprecated. IBC upgrade logic has been moved to the IBC module in the sub module 02-client. If this field is not empty, an error will be thrown. description: >- QueryCurrentPlanResponse is the response type for the Query/CurrentPlan RPC method. cosmos.upgrade.v1beta1.QueryModuleVersionsResponse: type: object properties: module_versions: type: array items: type: object properties: name: type: string title: name of the app module version: type: string format: uint64 title: consensus version of the app module description: |- ModuleVersion specifies a module and its consensus version. Since: cosmos-sdk 0.43 description: module_versions is a list of module names with their consensus versions. description: >- QueryModuleVersionsResponse is the response type for the Query/ModuleVersions RPC method. Since: cosmos-sdk 0.43 cosmos.upgrade.v1beta1.QueryUpgradedConsensusStateResponse: type: object properties: upgraded_consensus_state: type: string format: byte title: "Since: cosmos-sdk 0.43" description: >- QueryUpgradedConsensusStateResponse is the response type for the Query/UpgradedConsensusState RPC method. ibc.applications.fee.v1.Fee: type: object properties: recv_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet receive fee ack_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet acknowledgement fee timeout_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet timeout fee title: Fee defines the ICS29 receive, acknowledgement and timeout fees ibc.applications.fee.v1.FeeEnabledChannel: type: object properties: port_id: type: string title: unique port identifier channel_id: type: string title: unique channel identifier title: FeeEnabledChannel contains the PortID & ChannelID for a fee enabled channel ibc.applications.fee.v1.IdentifiedPacketFees: type: object properties: packet_id: title: unique packet identifier comprised of the channel ID, port ID and sequence type: object properties: port_id: type: string title: channel port identifier channel_id: type: string title: channel unique identifier sequence: type: string format: uint64 title: packet sequence packet_fees: type: array items: type: object properties: fee: title: fee encapsulates the recv, ack and timeout fees associated with an IBC packet type: object properties: recv_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet receive fee ack_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet acknowledgement fee timeout_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet timeout fee refund_address: type: string title: the refund address for unspent fees relayers: type: array items: type: string title: optional list of relayers permitted to receive fees title: PacketFee contains ICS29 relayer fees, refund address and optional list of permitted relayers title: list of packet fees title: IdentifiedPacketFees contains a list of type PacketFee and associated PacketId ibc.applications.fee.v1.PacketFee: type: object properties: fee: title: fee encapsulates the recv, ack and timeout fees associated with an IBC packet type: object properties: recv_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet receive fee ack_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet acknowledgement fee timeout_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet timeout fee refund_address: type: string title: the refund address for unspent fees relayers: type: array items: type: string title: optional list of relayers permitted to receive fees title: PacketFee contains ICS29 relayer fees, refund address and optional list of permitted relayers ibc.applications.fee.v1.QueryCounterpartyPayeeResponse: type: object properties: counterparty_payee: type: string title: the counterparty payee address used to compensate forward relaying title: QueryCounterpartyPayeeResponse defines the response type for the CounterpartyPayee rpc ibc.applications.fee.v1.QueryFeeEnabledChannelResponse: type: object properties: fee_enabled: type: boolean title: boolean flag representing the fee enabled channel status title: QueryFeeEnabledChannelResponse defines the response type for the FeeEnabledChannel rpc ibc.applications.fee.v1.QueryFeeEnabledChannelsResponse: type: object properties: fee_enabled_channels: type: array items: type: object properties: port_id: type: string title: unique port identifier channel_id: type: string title: unique channel identifier title: FeeEnabledChannel contains the PortID & ChannelID for a fee enabled channel title: list of fee enabled channels title: QueryFeeEnabledChannelsResponse defines the response type for the FeeEnabledChannels rpc ibc.applications.fee.v1.QueryIncentivizedPacketResponse: type: object properties: incentivized_packet: type: object properties: packet_id: title: unique packet identifier comprised of the channel ID, port ID and sequence type: object properties: port_id: type: string title: channel port identifier channel_id: type: string title: channel unique identifier sequence: type: string format: uint64 title: packet sequence packet_fees: type: array items: type: object properties: fee: title: fee encapsulates the recv, ack and timeout fees associated with an IBC packet type: object properties: recv_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet receive fee ack_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet acknowledgement fee timeout_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet timeout fee refund_address: type: string title: the refund address for unspent fees relayers: type: array items: type: string title: optional list of relayers permitted to receive fees title: PacketFee contains ICS29 relayer fees, refund address and optional list of permitted relayers title: list of packet fees title: IdentifiedPacketFees contains a list of type PacketFee and associated PacketId title: QueryIncentivizedPacketsResponse defines the response type for the IncentivizedPacket rpc ibc.applications.fee.v1.QueryIncentivizedPacketsForChannelResponse: type: object properties: incentivized_packets: type: array items: type: object properties: packet_id: title: unique packet identifier comprised of the channel ID, port ID and sequence type: object properties: port_id: type: string title: channel port identifier channel_id: type: string title: channel unique identifier sequence: type: string format: uint64 title: packet sequence packet_fees: type: array items: type: object properties: fee: title: fee encapsulates the recv, ack and timeout fees associated with an IBC packet type: object properties: recv_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet receive fee ack_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet acknowledgement fee timeout_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet timeout fee refund_address: type: string title: the refund address for unspent fees relayers: type: array items: type: string title: optional list of relayers permitted to receive fees title: PacketFee contains ICS29 relayer fees, refund address and optional list of permitted relayers title: list of packet fees title: IdentifiedPacketFees contains a list of type PacketFee and associated PacketId title: Map of all incentivized_packets title: QueryIncentivizedPacketsResponse defines the response type for the incentivized packets RPC ibc.applications.fee.v1.QueryIncentivizedPacketsResponse: type: object properties: incentivized_packets: type: array items: type: object properties: packet_id: title: unique packet identifier comprised of the channel ID, port ID and sequence type: object properties: port_id: type: string title: channel port identifier channel_id: type: string title: channel unique identifier sequence: type: string format: uint64 title: packet sequence packet_fees: type: array items: type: object properties: fee: title: fee encapsulates the recv, ack and timeout fees associated with an IBC packet type: object properties: recv_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet receive fee ack_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet acknowledgement fee timeout_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet timeout fee refund_address: type: string title: the refund address for unspent fees relayers: type: array items: type: string title: optional list of relayers permitted to receive fees title: PacketFee contains ICS29 relayer fees, refund address and optional list of permitted relayers title: list of packet fees title: IdentifiedPacketFees contains a list of type PacketFee and associated PacketId title: list of identified fees for incentivized packets title: QueryIncentivizedPacketsResponse defines the response type for the IncentivizedPackets rpc ibc.applications.fee.v1.QueryPayeeResponse: type: object properties: payee_address: type: string title: the payee address to which packet fees are paid out title: QueryPayeeResponse defines the response type for the Payee rpc ibc.applications.fee.v1.QueryTotalAckFeesResponse: type: object properties: ack_fees: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the total packet acknowledgement fees title: QueryTotalAckFeesResponse defines the response type for the TotalAckFees rpc ibc.applications.fee.v1.QueryTotalRecvFeesResponse: type: object properties: recv_fees: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the total packet receive fees title: QueryTotalRecvFeesResponse defines the response type for the TotalRecvFees rpc ibc.applications.fee.v1.QueryTotalTimeoutFeesResponse: type: object properties: timeout_fees: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the total packet timeout fees title: QueryTotalTimeoutFeesResponse defines the response type for the TotalTimeoutFees rpc ibc.core.channel.v1.PacketId: type: object properties: port_id: type: string title: channel port identifier channel_id: type: string title: channel unique identifier sequence: type: string format: uint64 title: packet sequence title: |- PacketId is an identifer for a unique Packet Source chains refer to packets by source port/channel Destination chains refer to packets by destination port/channel cosmos.params.v1beta1.ParamChange: type: object properties: subspace: type: string key: type: string value: type: string description: |- ParamChange defines an individual parameter change, for use in ParameterChangeProposal. cosmos.params.v1beta1.QueryParamsResponse: type: object properties: param: description: param defines the queried parameter. type: object properties: subspace: type: string key: type: string value: type: string description: QueryParamsResponse is response type for the Query/Params RPC method. cosmos.params.v1beta1.QuerySubspacesResponse: type: object properties: subspaces: type: array items: type: object properties: subspace: type: string keys: type: array items: type: string description: >- Subspace defines a parameter subspace name and all the keys that exist for the subspace. Since: cosmos-sdk 0.46 description: |- QuerySubspacesResponse defines the response types for querying for all registered subspaces and all keys for a subspace. Since: cosmos-sdk 0.46 cosmos.params.v1beta1.Subspace: type: object properties: subspace: type: string keys: type: array items: type: string description: >- Subspace defines a parameter subspace name and all the keys that exist for the subspace. Since: cosmos-sdk 0.46 cyber.rank.v1beta1.PageRequest: type: object properties: page: type: integer format: int64 per_page: type: integer format: int64 cyber.rank.v1beta1.PageResponse: type: object properties: total: type: integer format: int64 cyber.rank.v1beta1.Params: type: object properties: calculation_period: type: string format: int64 damping_factor: type: string tolerance: type: string cyber.rank.v1beta1.QueryKarmaResponse: type: object properties: karma: type: string format: uint64 cyber.rank.v1beta1.QueryLinkExistResponse: type: object properties: exist: type: boolean cyber.rank.v1beta1.QueryNegentropyParticleResponse: type: object properties: entropy: type: string format: uint64 cyber.rank.v1beta1.QueryNegentropyResponse: type: object properties: negentropy: type: string format: uint64 cyber.rank.v1beta1.QueryParamsResponse: type: object properties: params: type: object properties: calculation_period: type: string format: int64 damping_factor: type: string tolerance: type: string cyber.rank.v1beta1.QueryRankResponse: type: object properties: rank: type: string format: uint64 cyber.rank.v1beta1.QuerySearchResponse: type: object properties: result: type: array items: type: object properties: particle: type: string rank: type: string format: uint64 pagination: type: object properties: total: type: integer format: int64 cyber.rank.v1beta1.RankedParticle: type: object properties: particle: type: string rank: type: string format: uint64 cosmos.base.v1beta1.DecCoin: type: object properties: denom: type: string amount: type: string description: |- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. cosmos.distribution.v1beta1.DelegationDelegatorReward: type: object properties: validator_address: type: string reward: type: array items: type: object properties: denom: type: string amount: type: string description: >- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. description: |- DelegationDelegatorReward represents the properties of a delegator's delegation reward. cosmos.distribution.v1beta1.Params: type: object properties: community_tax: type: string base_proposer_reward: type: string description: >- Deprecated: The base_proposer_reward field is deprecated and is no longer used in the x/distribution module's reward mechanism. bonus_proposer_reward: type: string description: >- Deprecated: The bonus_proposer_reward field is deprecated and is no longer used in the x/distribution module's reward mechanism. withdraw_addr_enabled: type: boolean description: Params defines the set of params for the distribution module. cosmos.distribution.v1beta1.QueryCommunityPoolResponse: type: object properties: pool: type: array items: type: object properties: denom: type: string amount: type: string description: >- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. description: pool defines community pool's coins. description: >- QueryCommunityPoolResponse is the response type for the Query/CommunityPool RPC method. cosmos.distribution.v1beta1.QueryDelegationRewardsResponse: type: object properties: rewards: type: array items: type: object properties: denom: type: string amount: type: string description: >- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. description: rewards defines the rewards accrued by a delegation. description: |- QueryDelegationRewardsResponse is the response type for the Query/DelegationRewards RPC method. cosmos.distribution.v1beta1.QueryDelegationTotalRewardsResponse: type: object properties: rewards: type: array items: type: object properties: validator_address: type: string reward: type: array items: type: object properties: denom: type: string amount: type: string description: >- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. description: |- DelegationDelegatorReward represents the properties of a delegator's delegation reward. description: rewards defines all the rewards accrued by a delegator. total: type: array items: type: object properties: denom: type: string amount: type: string description: >- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. description: total defines the sum of all the rewards. description: |- QueryDelegationTotalRewardsResponse is the response type for the Query/DelegationTotalRewards RPC method. cosmos.distribution.v1beta1.QueryDelegatorValidatorsResponse: type: object properties: validators: type: array items: type: string description: validators defines the validators a delegator is delegating for. description: |- QueryDelegatorValidatorsResponse is the response type for the Query/DelegatorValidators RPC method. cosmos.distribution.v1beta1.QueryDelegatorWithdrawAddressResponse: type: object properties: withdraw_address: type: string description: withdraw_address defines the delegator address to query for. description: |- QueryDelegatorWithdrawAddressResponse is the response type for the Query/DelegatorWithdrawAddress RPC method. cosmos.distribution.v1beta1.QueryParamsResponse: type: object properties: params: description: params defines the parameters of the module. type: object properties: community_tax: type: string base_proposer_reward: type: string description: >- Deprecated: The base_proposer_reward field is deprecated and is no longer used in the x/distribution module's reward mechanism. bonus_proposer_reward: type: string description: >- Deprecated: The bonus_proposer_reward field is deprecated and is no longer used in the x/distribution module's reward mechanism. withdraw_addr_enabled: type: boolean description: QueryParamsResponse is the response type for the Query/Params RPC method. cosmos.distribution.v1beta1.QueryValidatorCommissionResponse: type: object properties: commission: description: commission defines the commission the validator received. type: object properties: commission: type: array items: type: object properties: denom: type: string amount: type: string description: >- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. title: |- QueryValidatorCommissionResponse is the response type for the Query/ValidatorCommission RPC method cosmos.distribution.v1beta1.QueryValidatorDistributionInfoResponse: type: object properties: operator_address: type: string description: operator_address defines the validator operator address. self_bond_rewards: type: array items: type: object properties: denom: type: string amount: type: string description: >- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. description: self_bond_rewards defines the self delegations rewards. commission: type: array items: type: object properties: denom: type: string amount: type: string description: >- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. description: commission defines the commission the validator received. description: QueryValidatorDistributionInfoResponse is the response type for the Query/ValidatorDistributionInfo RPC method. cosmos.distribution.v1beta1.QueryValidatorOutstandingRewardsResponse: type: object properties: rewards: type: object properties: rewards: type: array items: type: object properties: denom: type: string amount: type: string description: >- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. description: >- ValidatorOutstandingRewards represents outstanding (un-withdrawn) rewards for a validator inexpensive to track, allows simple sanity checks. description: |- QueryValidatorOutstandingRewardsResponse is the response type for the Query/ValidatorOutstandingRewards RPC method. cosmos.distribution.v1beta1.QueryValidatorSlashesResponse: type: object properties: slashes: type: array items: type: object properties: validator_period: type: string format: uint64 fraction: type: string description: |- ValidatorSlashEvent represents a validator slash event. Height is implicit within the store key. This is needed to calculate appropriate amount of staking tokens for delegations which are withdrawn after a slash has occurred. description: slashes defines the slashes the validator received. pagination: description: pagination defines the pagination in the response. type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- QueryValidatorSlashesResponse is the response type for the Query/ValidatorSlashes RPC method. cosmos.distribution.v1beta1.ValidatorAccumulatedCommission: type: object properties: commission: type: array items: type: object properties: denom: type: string amount: type: string description: >- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. description: |- ValidatorAccumulatedCommission represents accumulated commission for a validator kept as a running counter, can be withdrawn at any time. cosmos.distribution.v1beta1.ValidatorOutstandingRewards: type: object properties: rewards: type: array items: type: object properties: denom: type: string amount: type: string description: >- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. description: >- ValidatorOutstandingRewards represents outstanding (un-withdrawn) rewards for a validator inexpensive to track, allows simple sanity checks. cosmos.distribution.v1beta1.ValidatorSlashEvent: type: object properties: validator_period: type: string format: uint64 fraction: type: string description: |- ValidatorSlashEvent represents a validator slash event. Height is implicit within the store key. This is needed to calculate appropriate amount of staking tokens for delegations which are withdrawn after a slash has occurred. cosmos.bank.v1beta1.DenomOwner: type: object properties: address: type: string description: address defines the address that owns a particular denomination. balance: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- DenomOwner defines structure representing an account that owns or holds a particular denominated token. It contains the account address and account balance of the denominated token. Since: cosmos-sdk 0.46 cosmos.bank.v1beta1.DenomUnit: type: object properties: denom: type: string description: denom represents the string name of the given denom unit (e.g uatom). exponent: type: integer format: int64 description: >- exponent represents power of 10 exponent that one must raise the base_denom to in order to equal the given DenomUnit's denom 1 denom = 10^exponent base_denom (e.g. with a base_denom of uatom, one can create a DenomUnit of 'atom' with exponent = 6, thus: 1 atom = 10^6 uatom). aliases: type: array items: type: string title: aliases is a list of string aliases for the given denom description: |- DenomUnit represents a struct that describes a given denomination unit of the basic token. cosmos.bank.v1beta1.Metadata: type: object properties: description: type: string denom_units: type: array items: type: object properties: denom: type: string description: denom represents the string name of the given denom unit (e.g uatom). exponent: type: integer format: int64 description: >- exponent represents power of 10 exponent that one must raise the base_denom to in order to equal the given DenomUnit's denom 1 denom = 10^exponent base_denom (e.g. with a base_denom of uatom, one can create a DenomUnit of 'atom' with exponent = 6, thus: 1 atom = 10^6 uatom). aliases: type: array items: type: string title: aliases is a list of string aliases for the given denom description: |- DenomUnit represents a struct that describes a given denomination unit of the basic token. title: denom_units represents the list of DenomUnit's for a given coin base: type: string description: base represents the base denom (should be the DenomUnit with exponent = 0). display: type: string description: |- display indicates the suggested denom that should be displayed in clients. name: type: string description: "Since: cosmos-sdk 0.43" title: "name defines the name of the token (eg: Cosmos Atom)" symbol: type: string description: >- symbol is the token symbol usually shown on exchanges (eg: ATOM). This can be the same as the display. Since: cosmos-sdk 0.43 uri: type: string description: >- URI to a document (on or off-chain) that contains additional information. Optional. Since: cosmos-sdk 0.46 uri_hash: type: string description: >- URIHash is a sha256 hash of a document pointed by URI. It's used to verify that the document didn't change. Optional. Since: cosmos-sdk 0.46 description: |- Metadata represents a struct that describes a basic token. cosmos.bank.v1beta1.Params: type: object properties: send_enabled: type: array items: type: object properties: denom: type: string enabled: type: boolean description: >- SendEnabled maps coin denom to a send_enabled status (whether a denom is sendable). description: >- Deprecated: Use of SendEnabled in params is deprecated. For genesis, use the newly added send_enabled field in the genesis object. Storage, lookup, and manipulation of this information is now in the keeper. As of cosmos-sdk 0.47, this only exists for backwards compatibility of genesis files. default_send_enabled: type: boolean description: Params defines the parameters for the bank module. cosmos.bank.v1beta1.QueryAllBalancesResponse: type: object properties: balances: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: balances is the balances of all the coins. pagination: description: pagination defines the pagination in the response. type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- QueryAllBalancesResponse is the response type for the Query/AllBalances RPC method. cosmos.bank.v1beta1.QueryBalanceResponse: type: object properties: balance: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: QueryBalanceResponse is the response type for the Query/Balance RPC method. cosmos.bank.v1beta1.QueryDenomMetadataResponse: type: object properties: metadata: type: object properties: description: type: string denom_units: type: array items: type: object properties: denom: type: string description: denom represents the string name of the given denom unit (e.g uatom). exponent: type: integer format: int64 description: >- exponent represents power of 10 exponent that one must raise the base_denom to in order to equal the given DenomUnit's denom 1 denom = 10^exponent base_denom (e.g. with a base_denom of uatom, one can create a DenomUnit of 'atom' with exponent = 6, thus: 1 atom = 10^6 uatom). aliases: type: array items: type: string title: aliases is a list of string aliases for the given denom description: |- DenomUnit represents a struct that describes a given denomination unit of the basic token. title: denom_units represents the list of DenomUnit's for a given coin base: type: string description: base represents the base denom (should be the DenomUnit with exponent = 0). display: type: string description: |- display indicates the suggested denom that should be displayed in clients. name: type: string description: "Since: cosmos-sdk 0.43" title: "name defines the name of the token (eg: Cosmos Atom)" symbol: type: string description: >- symbol is the token symbol usually shown on exchanges (eg: ATOM). This can be the same as the display. Since: cosmos-sdk 0.43 uri: type: string description: >- URI to a document (on or off-chain) that contains additional information. Optional. Since: cosmos-sdk 0.46 uri_hash: type: string description: >- URIHash is a sha256 hash of a document pointed by URI. It's used to verify that the document didn't change. Optional. Since: cosmos-sdk 0.46 description: |- Metadata represents a struct that describes a basic token. description: >- QueryDenomMetadataResponse is the response type for the Query/DenomMetadata RPC method. cosmos.bank.v1beta1.QueryDenomOwnersResponse: type: object properties: denom_owners: type: array items: type: object properties: address: type: string description: address defines the address that owns a particular denomination. balance: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- DenomOwner defines structure representing an account that owns or holds a particular denominated token. It contains the account address and account balance of the denominated token. Since: cosmos-sdk 0.46 pagination: description: pagination defines the pagination in the response. type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- QueryDenomOwnersResponse defines the RPC response of a DenomOwners RPC query. Since: cosmos-sdk 0.46 cosmos.bank.v1beta1.QueryDenomsMetadataResponse: type: object properties: metadatas: type: array items: type: object properties: description: type: string denom_units: type: array items: type: object properties: denom: type: string description: denom represents the string name of the given denom unit (e.g uatom). exponent: type: integer format: int64 description: >- exponent represents power of 10 exponent that one must raise the base_denom to in order to equal the given DenomUnit's denom 1 denom = 10^exponent base_denom (e.g. with a base_denom of uatom, one can create a DenomUnit of 'atom' with exponent = 6, thus: 1 atom = 10^6 uatom). aliases: type: array items: type: string title: aliases is a list of string aliases for the given denom description: |- DenomUnit represents a struct that describes a given denomination unit of the basic token. title: denom_units represents the list of DenomUnit's for a given coin base: type: string description: base represents the base denom (should be the DenomUnit with exponent = 0). display: type: string description: |- display indicates the suggested denom that should be displayed in clients. name: type: string description: "Since: cosmos-sdk 0.43" title: "name defines the name of the token (eg: Cosmos Atom)" symbol: type: string description: >- symbol is the token symbol usually shown on exchanges (eg: ATOM). This can be the same as the display. Since: cosmos-sdk 0.43 uri: type: string description: >- URI to a document (on or off-chain) that contains additional information. Optional. Since: cosmos-sdk 0.46 uri_hash: type: string description: >- URIHash is a sha256 hash of a document pointed by URI. It's used to verify that the document didn't change. Optional. Since: cosmos-sdk 0.46 description: |- Metadata represents a struct that describes a basic token. description: metadata provides the client information for all the registered tokens. pagination: description: pagination defines the pagination in the response. type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- QueryDenomsMetadataResponse is the response type for the Query/DenomsMetadata RPC method. cosmos.bank.v1beta1.QueryParamsResponse: type: object properties: params: type: object properties: send_enabled: type: array items: type: object properties: denom: type: string enabled: type: boolean description: >- SendEnabled maps coin denom to a send_enabled status (whether a denom is sendable). description: >- Deprecated: Use of SendEnabled in params is deprecated. For genesis, use the newly added send_enabled field in the genesis object. Storage, lookup, and manipulation of this information is now in the keeper. As of cosmos-sdk 0.47, this only exists for backwards compatibility of genesis files. default_send_enabled: type: boolean description: Params defines the parameters for the bank module. description: QueryParamsResponse defines the response type for querying x/bank parameters. cosmos.bank.v1beta1.QuerySendEnabledResponse: type: object properties: send_enabled: type: array items: type: object properties: denom: type: string enabled: type: boolean description: >- SendEnabled maps coin denom to a send_enabled status (whether a denom is sendable). pagination: description: >- pagination defines the pagination in the response. This field is only populated if the denoms field in the request is empty. type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- QuerySendEnabledResponse defines the RPC response of a SendEnable query. Since: cosmos-sdk 0.47 cosmos.bank.v1beta1.QuerySpendableBalanceByDenomResponse: type: object properties: balance: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- QuerySpendableBalanceByDenomResponse defines the gRPC response structure for querying an account's spendable balance for a specific denom. Since: cosmos-sdk 0.47 cosmos.bank.v1beta1.QuerySpendableBalancesResponse: type: object properties: balances: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: balances is the spendable balances of all the coins. pagination: description: pagination defines the pagination in the response. type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- QuerySpendableBalancesResponse defines the gRPC response structure for querying an account's spendable balances. Since: cosmos-sdk 0.46 cosmos.bank.v1beta1.QuerySupplyOfResponse: type: object properties: amount: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: QuerySupplyOfResponse is the response type for the Query/SupplyOf RPC method. cosmos.bank.v1beta1.QueryTotalSupplyResponse: type: object properties: supply: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: supply is the supply of the coins pagination: description: |- pagination defines the pagination in the response. Since: cosmos-sdk 0.43 type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise title: >- QueryTotalSupplyResponse is the response type for the Query/TotalSupply RPC method cosmos.bank.v1beta1.SendEnabled: type: object properties: denom: type: string enabled: type: boolean description: |- SendEnabled maps coin denom to a send_enabled status (whether a denom is sendable). ibc.core.client.v1.Height: type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: >- Height is a monotonically increasing data type that can be compared against another Height for the purposes of updating and freezing clients ibc.core.client.v1.IdentifiedClientState: type: object properties: client_id: type: string title: client identifier client_state: type: object properties: type_url: type: string value: type: string format: byte title: client state description: |- IdentifiedClientState defines a client state with an additional client identifier field. ibc.core.commitment.v1.MerklePrefix: type: object properties: key_prefix: type: string format: byte title: >- MerklePrefix is merkle path prefixed to the key. The constructed key from the Path and the key will be append(Path.KeyPath, append(Path.KeyPrefix, key...)) ibc.core.connection.v1.ConnectionEnd: type: object properties: client_id: type: string description: client associated with this connection. versions: type: array items: type: object properties: identifier: type: string title: unique version identifier features: type: array items: type: string title: list of features compatible with the specified identifier description: >- Version defines the versioning scheme used to negotiate the IBC verison in the connection handshake. description: >- IBC version which can be utilised to determine encodings or protocols for channels or packets utilising this connection. state: description: current state of the connection end. type: string enum: - STATE_UNINITIALIZED_UNSPECIFIED - STATE_INIT - STATE_TRYOPEN - STATE_OPEN default: STATE_UNINITIALIZED_UNSPECIFIED counterparty: description: counterparty chain associated with this connection. type: object properties: client_id: type: string description: >- identifies the client on the counterparty chain associated with a given connection. connection_id: type: string description: >- identifies the connection end on the counterparty chain associated with a given connection. prefix: description: commitment merkle prefix of the counterparty chain. type: object properties: key_prefix: type: string format: byte title: >- MerklePrefix is merkle path prefixed to the key. The constructed key from the Path and the key will be append(Path.KeyPath, append(Path.KeyPrefix, key...)) delay_period: type: string format: uint64 description: >- delay period that must pass before a consensus state can be used for packet-verification NOTE: delay period logic is only implemented by some clients. description: |- ConnectionEnd defines a stateful object on a chain connected to another separate one. NOTE: there must only be 2 defined ConnectionEnds to establish a connection between two chains. ibc.core.connection.v1.Counterparty: type: object properties: client_id: type: string description: >- identifies the client on the counterparty chain associated with a given connection. connection_id: type: string description: >- identifies the connection end on the counterparty chain associated with a given connection. prefix: description: commitment merkle prefix of the counterparty chain. type: object properties: key_prefix: type: string format: byte title: >- MerklePrefix is merkle path prefixed to the key. The constructed key from the Path and the key will be append(Path.KeyPath, append(Path.KeyPrefix, key...)) description: Counterparty defines the counterparty chain associated with a connection end. ibc.core.connection.v1.IdentifiedConnection: type: object properties: id: type: string description: connection identifier. client_id: type: string description: client associated with this connection. versions: type: array items: type: object properties: identifier: type: string title: unique version identifier features: type: array items: type: string title: list of features compatible with the specified identifier description: >- Version defines the versioning scheme used to negotiate the IBC verison in the connection handshake. title: >- IBC version which can be utilised to determine encodings or protocols for channels or packets utilising this connection state: description: current state of the connection end. type: string enum: - STATE_UNINITIALIZED_UNSPECIFIED - STATE_INIT - STATE_TRYOPEN - STATE_OPEN default: STATE_UNINITIALIZED_UNSPECIFIED counterparty: description: counterparty chain associated with this connection. type: object properties: client_id: type: string description: >- identifies the client on the counterparty chain associated with a given connection. connection_id: type: string description: >- identifies the connection end on the counterparty chain associated with a given connection. prefix: description: commitment merkle prefix of the counterparty chain. type: object properties: key_prefix: type: string format: byte title: >- MerklePrefix is merkle path prefixed to the key. The constructed key from the Path and the key will be append(Path.KeyPath, append(Path.KeyPrefix, key...)) delay_period: type: string format: uint64 description: delay period associated with this connection. description: |- IdentifiedConnection defines a connection with additional connection identifier field. ibc.core.connection.v1.Params: type: object properties: max_expected_time_per_block: type: string format: uint64 description: >- maximum expected time per block (in nanoseconds), used to enforce block delay. This parameter should reflect the largest amount of time that the chain might reasonably take to produce the next block under normal operating conditions. A safe choice is 3-5x the expected time per block. description: Params defines the set of Connection parameters. ibc.core.connection.v1.QueryClientConnectionsResponse: type: object properties: connection_paths: type: array items: type: string description: slice of all the connection paths associated with a client. proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was generated type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryClientConnectionsResponse is the response type for the Query/ClientConnections RPC method ibc.core.connection.v1.QueryConnectionClientStateResponse: type: object properties: identified_client_state: title: client state associated with the channel type: object properties: client_id: type: string title: client identifier client_state: type: object properties: type_url: type: string value: type: string format: byte title: client state description: >- IdentifiedClientState defines a client state with an additional client identifier field. proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryConnectionClientStateResponse is the response type for the Query/ConnectionClientState RPC method ibc.core.connection.v1.QueryConnectionConsensusStateResponse: type: object properties: consensus_state: type: object properties: type_url: type: string value: type: string format: byte title: consensus state associated with the channel client_id: type: string title: client ID associated with the consensus state proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryConnectionConsensusStateResponse is the response type for the Query/ConnectionConsensusState RPC method ibc.core.connection.v1.QueryConnectionParamsResponse: type: object properties: params: description: params defines the parameters of the module. type: object properties: max_expected_time_per_block: type: string format: uint64 description: >- maximum expected time per block (in nanoseconds), used to enforce block delay. This parameter should reflect the largest amount of time that the chain might reasonably take to produce the next block under normal operating conditions. A safe choice is 3-5x the expected time per block. description: QueryConnectionParamsResponse is the response type for the Query/ConnectionParams RPC method. ibc.core.connection.v1.QueryConnectionResponse: type: object properties: connection: title: connection associated with the request identifier type: object properties: client_id: type: string description: client associated with this connection. versions: type: array items: type: object properties: identifier: type: string title: unique version identifier features: type: array items: type: string title: list of features compatible with the specified identifier description: >- Version defines the versioning scheme used to negotiate the IBC verison in the connection handshake. description: >- IBC version which can be utilised to determine encodings or protocols for channels or packets utilising this connection. state: description: current state of the connection end. type: string enum: - STATE_UNINITIALIZED_UNSPECIFIED - STATE_INIT - STATE_TRYOPEN - STATE_OPEN default: STATE_UNINITIALIZED_UNSPECIFIED counterparty: description: counterparty chain associated with this connection. type: object properties: client_id: type: string description: >- identifies the client on the counterparty chain associated with a given connection. connection_id: type: string description: >- identifies the connection end on the counterparty chain associated with a given connection. prefix: description: commitment merkle prefix of the counterparty chain. type: object properties: key_prefix: type: string format: byte title: >- MerklePrefix is merkle path prefixed to the key. The constructed key from the Path and the key will be append(Path.KeyPath, append(Path.KeyPrefix, key...)) delay_period: type: string format: uint64 description: >- delay period that must pass before a consensus state can be used for packet-verification NOTE: delay period logic is only implemented by some clients. description: >- ConnectionEnd defines a stateful object on a chain connected to another separate one. NOTE: there must only be 2 defined ConnectionEnds to establish a connection between two chains. proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset description: >- QueryConnectionResponse is the response type for the Query/Connection RPC method. Besides the connection end, it includes a proof and the height from which the proof was retrieved. ibc.core.connection.v1.QueryConnectionsResponse: type: object properties: connections: type: array items: type: object properties: id: type: string description: connection identifier. client_id: type: string description: client associated with this connection. versions: type: array items: type: object properties: identifier: type: string title: unique version identifier features: type: array items: type: string title: list of features compatible with the specified identifier description: >- Version defines the versioning scheme used to negotiate the IBC verison in the connection handshake. title: >- IBC version which can be utilised to determine encodings or protocols for channels or packets utilising this connection state: description: current state of the connection end. type: string enum: - STATE_UNINITIALIZED_UNSPECIFIED - STATE_INIT - STATE_TRYOPEN - STATE_OPEN default: STATE_UNINITIALIZED_UNSPECIFIED counterparty: description: counterparty chain associated with this connection. type: object properties: client_id: type: string description: >- identifies the client on the counterparty chain associated with a given connection. connection_id: type: string description: >- identifies the connection end on the counterparty chain associated with a given connection. prefix: description: commitment merkle prefix of the counterparty chain. type: object properties: key_prefix: type: string format: byte title: >- MerklePrefix is merkle path prefixed to the key. The constructed key from the Path and the key will be append(Path.KeyPath, append(Path.KeyPrefix, key...)) delay_period: type: string format: uint64 description: delay period associated with this connection. description: >- IdentifiedConnection defines a connection with additional connection identifier field. description: list of stored connections of the chain. pagination: title: pagination response type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } height: title: query block height type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset description: >- QueryConnectionsResponse is the response type for the Query/Connections RPC method. ibc.core.connection.v1.State: type: string enum: - STATE_UNINITIALIZED_UNSPECIFIED - STATE_INIT - STATE_TRYOPEN - STATE_OPEN default: STATE_UNINITIALIZED_UNSPECIFIED description: >- State defines if a connection is in one of the following states: INIT, TRYOPEN, OPEN or UNINITIALIZED. - STATE_UNINITIALIZED_UNSPECIFIED: Default State - STATE_INIT: A connection end has just started the opening handshake. - STATE_TRYOPEN: A connection end has acknowledged the handshake step on the counterparty chain. - STATE_OPEN: A connection end has completed the handshake. ibc.core.connection.v1.Version: type: object properties: identifier: type: string title: unique version identifier features: type: array items: type: string title: list of features compatible with the specified identifier description: >- Version defines the versioning scheme used to negotiate the IBC verison in the connection handshake. cyber.grid.v1beta1.Params: type: object properties: max_routes: type: integer format: int64 cyber.grid.v1beta1.QueryParamsResponse: type: object properties: params: type: object properties: max_routes: type: integer format: int64 cyber.grid.v1beta1.QueryRouteResponse: type: object properties: route: type: object properties: source: type: string destination: type: string name: type: string value: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. cyber.grid.v1beta1.QueryRoutedEnergyResponse: type: object properties: value: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. cyber.grid.v1beta1.QueryRoutesResponse: type: object properties: routes: type: array items: type: object properties: source: type: string destination: type: string name: type: string value: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } cyber.grid.v1beta1.Route: type: object properties: source: type: string destination: type: string name: type: string value: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. cyber.dmn.v1beta1.Load: type: object properties: input: type: string gas_price: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. cyber.dmn.v1beta1.Params: type: object properties: max_slots: type: integer format: int64 max_gas: type: integer format: int64 fee_ttl: type: integer format: int64 cyber.dmn.v1beta1.QueryParamsResponse: type: object properties: params: type: object properties: max_slots: type: integer format: int64 max_gas: type: integer format: int64 fee_ttl: type: integer format: int64 cyber.dmn.v1beta1.QueryThoughtResponse: type: object properties: thought: type: object properties: program: type: string trigger: type: object properties: period: type: string format: uint64 block: type: string format: uint64 load: type: object properties: input: type: string gas_price: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. name: type: string particle: type: string cyber.dmn.v1beta1.QueryThoughtStatsResponse: type: object properties: thought_stats: type: object properties: program: type: string name: type: string calls: type: string format: uint64 fees: type: string format: uint64 gas: type: string format: uint64 last_block: type: string format: uint64 cyber.dmn.v1beta1.QueryThoughtsFeesResponse: type: object properties: fees: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. cyber.dmn.v1beta1.QueryThoughtsResponse: type: object properties: thoughts: type: array items: type: object properties: program: type: string trigger: type: object properties: period: type: string format: uint64 block: type: string format: uint64 load: type: object properties: input: type: string gas_price: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. name: type: string particle: type: string cyber.dmn.v1beta1.QueryThoughtsStatsResponse: type: object properties: thoughts_stats: type: array items: type: object properties: program: type: string name: type: string calls: type: string format: uint64 fees: type: string format: uint64 gas: type: string format: uint64 last_block: type: string format: uint64 cyber.dmn.v1beta1.Thought: type: object properties: program: type: string trigger: type: object properties: period: type: string format: uint64 block: type: string format: uint64 load: type: object properties: input: type: string gas_price: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. name: type: string particle: type: string cyber.dmn.v1beta1.ThoughtStats: type: object properties: program: type: string name: type: string calls: type: string format: uint64 fees: type: string format: uint64 gas: type: string format: uint64 last_block: type: string format: uint64 cyber.dmn.v1beta1.Trigger: type: object properties: period: type: string format: uint64 block: type: string format: uint64 cosmos.staking.v1beta1.BondStatus: type: string enum: - BOND_STATUS_UNSPECIFIED - BOND_STATUS_UNBONDED - BOND_STATUS_UNBONDING - BOND_STATUS_BONDED default: BOND_STATUS_UNSPECIFIED description: >- BondStatus is the status of a validator. - BOND_STATUS_UNSPECIFIED: UNSPECIFIED defines an invalid validator status. - BOND_STATUS_UNBONDED: UNBONDED defines a validator that is not bonded. - BOND_STATUS_UNBONDING: UNBONDING defines a validator that is unbonding. - BOND_STATUS_BONDED: BONDED defines a validator that is bonded. cosmos.staking.v1beta1.Commission: type: object properties: commission_rates: description: commission_rates defines the initial commission rates to be used for creating a validator. type: object properties: rate: type: string description: rate is the commission rate charged to delegators, as a fraction. max_rate: type: string description: max_rate defines the maximum commission rate which validator can ever charge, as a fraction. max_change_rate: type: string description: max_change_rate defines the maximum daily increase of the validator commission, as a fraction. update_time: type: string format: date-time description: update_time is the last time the commission rate was changed. description: Commission defines commission parameters for a given validator. cosmos.staking.v1beta1.CommissionRates: type: object properties: rate: type: string description: rate is the commission rate charged to delegators, as a fraction. max_rate: type: string description: max_rate defines the maximum commission rate which validator can ever charge, as a fraction. max_change_rate: type: string description: max_change_rate defines the maximum daily increase of the validator commission, as a fraction. description: >- CommissionRates defines the initial commission rates to be used for creating a validator. cosmos.staking.v1beta1.Delegation: type: object properties: delegator_address: type: string description: delegator_address is the bech32-encoded address of the delegator. validator_address: type: string description: validator_address is the bech32-encoded address of the validator. shares: type: string description: shares define the delegation shares received. description: |- Delegation represents the bond with tokens held by an account. It is owned by one delegator, and is associated with the voting power of one validator. cosmos.staking.v1beta1.DelegationResponse: type: object properties: delegation: type: object properties: delegator_address: type: string description: delegator_address is the bech32-encoded address of the delegator. validator_address: type: string description: validator_address is the bech32-encoded address of the validator. shares: type: string description: shares define the delegation shares received. description: >- Delegation represents the bond with tokens held by an account. It is owned by one delegator, and is associated with the voting power of one validator. balance: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- DelegationResponse is equivalent to Delegation except that it contains a balance in addition to shares which is more suitable for client responses. cosmos.staking.v1beta1.Description: type: object properties: moniker: type: string description: moniker defines a human-readable name for the validator. identity: type: string description: identity defines an optional identity signature (ex. UPort or Keybase). website: type: string description: website defines an optional website link. security_contact: type: string description: security_contact defines an optional email for security contact. details: type: string description: details define other optional details. description: Description defines a validator description. cosmos.staking.v1beta1.HistoricalInfo: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. valset: type: array items: type: object properties: operator_address: type: string description: operator_address defines the address of the validator's operator; bech encoded in JSON. consensus_pubkey: type: object properties: type_url: type: string value: type: string format: byte description: consensus_pubkey is the consensus public key of the validator, as a Protobuf Any. jailed: type: boolean description: jailed defined whether the validator has been jailed from bonded status or not. status: description: status is the validator status (bonded/unbonding/unbonded). type: string enum: - BOND_STATUS_UNSPECIFIED - BOND_STATUS_UNBONDED - BOND_STATUS_UNBONDING - BOND_STATUS_BONDED default: BOND_STATUS_UNSPECIFIED tokens: type: string description: tokens define the delegated tokens (incl. self-delegation). delegator_shares: type: string description: delegator_shares defines total shares issued to a validator's delegators. description: description: description defines the description terms for the validator. type: object properties: moniker: type: string description: moniker defines a human-readable name for the validator. identity: type: string description: identity defines an optional identity signature (ex. UPort or Keybase). website: type: string description: website defines an optional website link. security_contact: type: string description: security_contact defines an optional email for security contact. details: type: string description: details define other optional details. unbonding_height: type: string format: int64 description: unbonding_height defines, if unbonding, the height at which this validator has begun unbonding. unbonding_time: type: string format: date-time description: unbonding_time defines, if unbonding, the min time for the validator to complete unbonding. commission: description: commission defines the commission parameters. type: object properties: commission_rates: description: commission_rates defines the initial commission rates to be used for creating a validator. type: object properties: rate: type: string description: rate is the commission rate charged to delegators, as a fraction. max_rate: type: string description: max_rate defines the maximum commission rate which validator can ever charge, as a fraction. max_change_rate: type: string description: max_change_rate defines the maximum daily increase of the validator commission, as a fraction. update_time: type: string format: date-time description: update_time is the last time the commission rate was changed. min_self_delegation: type: string description: >- min_self_delegation is the validator's self declared minimum self delegation. Since: cosmos-sdk 0.46 unbonding_on_hold_ref_count: type: string format: int64 title: strictly positive if this validator's unbonding has been stopped by external modules unbonding_ids: type: array items: type: string format: uint64 title: list of unbonding ids, each uniquely identifing an unbonding of this validator description: >- Validator defines a validator, together with the total amount of the Validator's bond shares and their exchange rate to coins. Slashing results in a decrease in the exchange rate, allowing correct calculation of future undelegations without iterating over delegators. When coins are delegated to this validator, the validator is credited with a delegation whose number of bond shares is based on the amount of coins delegated divided by the current exchange rate. Voting power can be calculated as total bonded shares multiplied by exchange rate. description: >- HistoricalInfo contains header and validator information for a given block. It is stored as part of staking module's state, which persists the `n` most recent HistoricalInfo (`n` is set by the staking module's `historical_entries` parameter). cosmos.staking.v1beta1.Params: type: object properties: unbonding_time: type: string description: unbonding_time is the time duration of unbonding. max_validators: type: integer format: int64 description: max_validators is the maximum number of validators. max_entries: type: integer format: int64 description: max_entries is the max entries for either unbonding delegation or redelegation (per pair/trio). historical_entries: type: integer format: int64 description: historical_entries is the number of historical entries to persist. bond_denom: type: string description: bond_denom defines the bondable coin denomination. min_commission_rate: type: string title: min_commission_rate is the chain-wide minimum commission rate that a validator can charge their delegators description: Params defines the parameters for the x/staking module. cosmos.staking.v1beta1.Pool: type: object properties: not_bonded_tokens: type: string bonded_tokens: type: string description: |- Pool is used for tracking bonded and not-bonded token supply of the bond denomination. cosmos.staking.v1beta1.QueryDelegationResponse: type: object properties: delegation_response: type: object properties: delegation: type: object properties: delegator_address: type: string description: delegator_address is the bech32-encoded address of the delegator. validator_address: type: string description: validator_address is the bech32-encoded address of the validator. shares: type: string description: shares define the delegation shares received. description: >- Delegation represents the bond with tokens held by an account. It is owned by one delegator, and is associated with the voting power of one validator. balance: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- DelegationResponse is equivalent to Delegation except that it contains a balance in addition to shares which is more suitable for client responses. description: QueryDelegationResponse is response type for the Query/Delegation RPC method. cosmos.staking.v1beta1.QueryDelegatorDelegationsResponse: type: object properties: delegation_responses: type: array items: type: object properties: delegation: type: object properties: delegator_address: type: string description: delegator_address is the bech32-encoded address of the delegator. validator_address: type: string description: validator_address is the bech32-encoded address of the validator. shares: type: string description: shares define the delegation shares received. description: >- Delegation represents the bond with tokens held by an account. It is owned by one delegator, and is associated with the voting power of one validator. balance: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- DelegationResponse is equivalent to Delegation except that it contains a balance in addition to shares which is more suitable for client responses. description: delegation_responses defines all the delegations' info of a delegator. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: |- QueryDelegatorDelegationsResponse is response type for the Query/DelegatorDelegations RPC method. cosmos.staking.v1beta1.QueryDelegatorUnbondingDelegationsResponse: type: object properties: unbonding_responses: type: array items: type: object properties: delegator_address: type: string description: delegator_address is the bech32-encoded address of the delegator. validator_address: type: string description: validator_address is the bech32-encoded address of the validator. entries: type: array items: type: object properties: creation_height: type: string format: int64 description: creation_height is the height which the unbonding took place. completion_time: type: string format: date-time description: completion_time is the unix time for unbonding completion. initial_balance: type: string description: initial_balance defines the tokens initially scheduled to receive at completion. balance: type: string description: balance defines the tokens to receive at completion. unbonding_id: type: string format: uint64 title: Incrementing id that uniquely identifies this entry unbonding_on_hold_ref_count: type: string format: int64 title: Strictly positive if this entry's unbonding has been stopped by external modules description: UnbondingDelegationEntry defines an unbonding object with relevant metadata. description: entries are the unbonding delegation entries. description: >- UnbondingDelegation stores all of a single delegator's unbonding bonds for a single validator in an time-ordered list. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: |- QueryUnbondingDelegatorDelegationsResponse is response type for the Query/UnbondingDelegatorDelegations RPC method. cosmos.staking.v1beta1.QueryDelegatorValidatorResponse: type: object properties: validator: type: object properties: operator_address: type: string description: operator_address defines the address of the validator's operator; bech encoded in JSON. consensus_pubkey: type: object properties: type_url: type: string value: type: string format: byte description: consensus_pubkey is the consensus public key of the validator, as a Protobuf Any. jailed: type: boolean description: jailed defined whether the validator has been jailed from bonded status or not. status: description: status is the validator status (bonded/unbonding/unbonded). type: string enum: - BOND_STATUS_UNSPECIFIED - BOND_STATUS_UNBONDED - BOND_STATUS_UNBONDING - BOND_STATUS_BONDED default: BOND_STATUS_UNSPECIFIED tokens: type: string description: tokens define the delegated tokens (incl. self-delegation). delegator_shares: type: string description: delegator_shares defines total shares issued to a validator's delegators. description: description: description defines the description terms for the validator. type: object properties: moniker: type: string description: moniker defines a human-readable name for the validator. identity: type: string description: identity defines an optional identity signature (ex. UPort or Keybase). website: type: string description: website defines an optional website link. security_contact: type: string description: security_contact defines an optional email for security contact. details: type: string description: details define other optional details. unbonding_height: type: string format: int64 description: unbonding_height defines, if unbonding, the height at which this validator has begun unbonding. unbonding_time: type: string format: date-time description: unbonding_time defines, if unbonding, the min time for the validator to complete unbonding. commission: description: commission defines the commission parameters. type: object properties: commission_rates: description: commission_rates defines the initial commission rates to be used for creating a validator. type: object properties: rate: type: string description: rate is the commission rate charged to delegators, as a fraction. max_rate: type: string description: max_rate defines the maximum commission rate which validator can ever charge, as a fraction. max_change_rate: type: string description: max_change_rate defines the maximum daily increase of the validator commission, as a fraction. update_time: type: string format: date-time description: update_time is the last time the commission rate was changed. min_self_delegation: type: string description: >- min_self_delegation is the validator's self declared minimum self delegation. Since: cosmos-sdk 0.46 unbonding_on_hold_ref_count: type: string format: int64 title: strictly positive if this validator's unbonding has been stopped by external modules unbonding_ids: type: array items: type: string format: uint64 title: list of unbonding ids, each uniquely identifing an unbonding of this validator description: >- Validator defines a validator, together with the total amount of the Validator's bond shares and their exchange rate to coins. Slashing results in a decrease in the exchange rate, allowing correct calculation of future undelegations without iterating over delegators. When coins are delegated to this validator, the validator is credited with a delegation whose number of bond shares is based on the amount of coins delegated divided by the current exchange rate. Voting power can be calculated as total bonded shares multiplied by exchange rate. description: |- QueryDelegatorValidatorResponse response type for the Query/DelegatorValidator RPC method. cosmos.staking.v1beta1.QueryDelegatorValidatorsResponse: type: object properties: validators: type: array items: type: object properties: operator_address: type: string description: operator_address defines the address of the validator's operator; bech encoded in JSON. consensus_pubkey: type: object properties: type_url: type: string value: type: string format: byte description: consensus_pubkey is the consensus public key of the validator, as a Protobuf Any. jailed: type: boolean description: jailed defined whether the validator has been jailed from bonded status or not. status: description: status is the validator status (bonded/unbonding/unbonded). type: string enum: - BOND_STATUS_UNSPECIFIED - BOND_STATUS_UNBONDED - BOND_STATUS_UNBONDING - BOND_STATUS_BONDED default: BOND_STATUS_UNSPECIFIED tokens: type: string description: tokens define the delegated tokens (incl. self-delegation). delegator_shares: type: string description: delegator_shares defines total shares issued to a validator's delegators. description: description: description defines the description terms for the validator. type: object properties: moniker: type: string description: moniker defines a human-readable name for the validator. identity: type: string description: identity defines an optional identity signature (ex. UPort or Keybase). website: type: string description: website defines an optional website link. security_contact: type: string description: security_contact defines an optional email for security contact. details: type: string description: details define other optional details. unbonding_height: type: string format: int64 description: unbonding_height defines, if unbonding, the height at which this validator has begun unbonding. unbonding_time: type: string format: date-time description: unbonding_time defines, if unbonding, the min time for the validator to complete unbonding. commission: description: commission defines the commission parameters. type: object properties: commission_rates: description: commission_rates defines the initial commission rates to be used for creating a validator. type: object properties: rate: type: string description: rate is the commission rate charged to delegators, as a fraction. max_rate: type: string description: max_rate defines the maximum commission rate which validator can ever charge, as a fraction. max_change_rate: type: string description: max_change_rate defines the maximum daily increase of the validator commission, as a fraction. update_time: type: string format: date-time description: update_time is the last time the commission rate was changed. min_self_delegation: type: string description: >- min_self_delegation is the validator's self declared minimum self delegation. Since: cosmos-sdk 0.46 unbonding_on_hold_ref_count: type: string format: int64 title: strictly positive if this validator's unbonding has been stopped by external modules unbonding_ids: type: array items: type: string format: uint64 title: list of unbonding ids, each uniquely identifing an unbonding of this validator description: >- Validator defines a validator, together with the total amount of the Validator's bond shares and their exchange rate to coins. Slashing results in a decrease in the exchange rate, allowing correct calculation of future undelegations without iterating over delegators. When coins are delegated to this validator, the validator is credited with a delegation whose number of bond shares is based on the amount of coins delegated divided by the current exchange rate. Voting power can be calculated as total bonded shares multiplied by exchange rate. description: validators defines the validators' info of a delegator. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: |- QueryDelegatorValidatorsResponse is response type for the Query/DelegatorValidators RPC method. cosmos.staking.v1beta1.QueryHistoricalInfoResponse: type: object properties: hist: description: hist defines the historical info at the given height. type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. valset: type: array items: type: object properties: operator_address: type: string description: operator_address defines the address of the validator's operator; bech encoded in JSON. consensus_pubkey: type: object properties: type_url: type: string value: type: string format: byte description: consensus_pubkey is the consensus public key of the validator, as a Protobuf Any. jailed: type: boolean description: jailed defined whether the validator has been jailed from bonded status or not. status: description: status is the validator status (bonded/unbonding/unbonded). type: string enum: - BOND_STATUS_UNSPECIFIED - BOND_STATUS_UNBONDED - BOND_STATUS_UNBONDING - BOND_STATUS_BONDED default: BOND_STATUS_UNSPECIFIED tokens: type: string description: tokens define the delegated tokens (incl. self-delegation). delegator_shares: type: string description: delegator_shares defines total shares issued to a validator's delegators. description: description: description defines the description terms for the validator. type: object properties: moniker: type: string description: moniker defines a human-readable name for the validator. identity: type: string description: identity defines an optional identity signature (ex. UPort or Keybase). website: type: string description: website defines an optional website link. security_contact: type: string description: security_contact defines an optional email for security contact. details: type: string description: details define other optional details. unbonding_height: type: string format: int64 description: unbonding_height defines, if unbonding, the height at which this validator has begun unbonding. unbonding_time: type: string format: date-time description: unbonding_time defines, if unbonding, the min time for the validator to complete unbonding. commission: description: commission defines the commission parameters. type: object properties: commission_rates: description: commission_rates defines the initial commission rates to be used for creating a validator. type: object properties: rate: type: string description: rate is the commission rate charged to delegators, as a fraction. max_rate: type: string description: max_rate defines the maximum commission rate which validator can ever charge, as a fraction. max_change_rate: type: string description: max_change_rate defines the maximum daily increase of the validator commission, as a fraction. update_time: type: string format: date-time description: update_time is the last time the commission rate was changed. min_self_delegation: type: string description: >- min_self_delegation is the validator's self declared minimum self delegation. Since: cosmos-sdk 0.46 unbonding_on_hold_ref_count: type: string format: int64 title: strictly positive if this validator's unbonding has been stopped by external modules unbonding_ids: type: array items: type: string format: uint64 title: list of unbonding ids, each uniquely identifing an unbonding of this validator description: >- Validator defines a validator, together with the total amount of the Validator's bond shares and their exchange rate to coins. Slashing results in a decrease in the exchange rate, allowing correct calculation of future undelegations without iterating over delegators. When coins are delegated to this validator, the validator is credited with a delegation whose number of bond shares is based on the amount of coins delegated divided by the current exchange rate. Voting power can be calculated as total bonded shares multiplied by exchange rate. description: >- QueryHistoricalInfoResponse is response type for the Query/HistoricalInfo RPC method. cosmos.staking.v1beta1.QueryParamsResponse: type: object properties: params: description: params holds all the parameters of this module. type: object properties: unbonding_time: type: string description: unbonding_time is the time duration of unbonding. max_validators: type: integer format: int64 description: max_validators is the maximum number of validators. max_entries: type: integer format: int64 description: max_entries is the max entries for either unbonding delegation or redelegation (per pair/trio). historical_entries: type: integer format: int64 description: historical_entries is the number of historical entries to persist. bond_denom: type: string description: bond_denom defines the bondable coin denomination. min_commission_rate: type: string title: min_commission_rate is the chain-wide minimum commission rate that a validator can charge their delegators description: QueryParamsResponse is response type for the Query/Params RPC method. cosmos.staking.v1beta1.QueryPoolResponse: type: object properties: pool: description: pool defines the pool info. type: object properties: not_bonded_tokens: type: string bonded_tokens: type: string description: QueryPoolResponse is response type for the Query/Pool RPC method. cosmos.staking.v1beta1.QueryRedelegationsResponse: type: object properties: redelegation_responses: type: array items: type: object properties: redelegation: type: object properties: delegator_address: type: string description: delegator_address is the bech32-encoded address of the delegator. validator_src_address: type: string description: validator_src_address is the validator redelegation source operator address. validator_dst_address: type: string description: validator_dst_address is the validator redelegation destination operator address. entries: type: array items: type: object properties: creation_height: type: string format: int64 description: creation_height defines the height which the redelegation took place. completion_time: type: string format: date-time description: completion_time defines the unix time for redelegation completion. initial_balance: type: string description: initial_balance defines the initial balance when redelegation started. shares_dst: type: string description: shares_dst is the amount of destination-validator shares created by redelegation. unbonding_id: type: string format: uint64 title: Incrementing id that uniquely identifies this entry unbonding_on_hold_ref_count: type: string format: int64 title: Strictly positive if this entry's unbonding has been stopped by external modules description: RedelegationEntry defines a redelegation object with relevant metadata. description: entries are the redelegation entries. description: >- Redelegation contains the list of a particular delegator's redelegating bonds from a particular source validator to a particular destination validator. entries: type: array items: type: object properties: redelegation_entry: type: object properties: creation_height: type: string format: int64 description: creation_height defines the height which the redelegation took place. completion_time: type: string format: date-time description: completion_time defines the unix time for redelegation completion. initial_balance: type: string description: initial_balance defines the initial balance when redelegation started. shares_dst: type: string description: shares_dst is the amount of destination-validator shares created by redelegation. unbonding_id: type: string format: uint64 title: Incrementing id that uniquely identifies this entry unbonding_on_hold_ref_count: type: string format: int64 title: Strictly positive if this entry's unbonding has been stopped by external modules description: RedelegationEntry defines a redelegation object with relevant metadata. balance: type: string description: >- RedelegationEntryResponse is equivalent to a RedelegationEntry except that it contains a balance in addition to shares which is more suitable for client responses. description: >- RedelegationResponse is equivalent to a Redelegation except that its entries contain a balance in addition to shares which is more suitable for client responses. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- QueryRedelegationsResponse is response type for the Query/Redelegations RPC method. cosmos.staking.v1beta1.QueryUnbondingDelegationResponse: type: object properties: unbond: type: object properties: delegator_address: type: string description: delegator_address is the bech32-encoded address of the delegator. validator_address: type: string description: validator_address is the bech32-encoded address of the validator. entries: type: array items: type: object properties: creation_height: type: string format: int64 description: creation_height is the height which the unbonding took place. completion_time: type: string format: date-time description: completion_time is the unix time for unbonding completion. initial_balance: type: string description: initial_balance defines the tokens initially scheduled to receive at completion. balance: type: string description: balance defines the tokens to receive at completion. unbonding_id: type: string format: uint64 title: Incrementing id that uniquely identifies this entry unbonding_on_hold_ref_count: type: string format: int64 title: Strictly positive if this entry's unbonding has been stopped by external modules description: UnbondingDelegationEntry defines an unbonding object with relevant metadata. description: entries are the unbonding delegation entries. description: >- UnbondingDelegation stores all of a single delegator's unbonding bonds for a single validator in an time-ordered list. description: >- QueryDelegationResponse is response type for the Query/UnbondingDelegation RPC method. cosmos.staking.v1beta1.QueryValidatorDelegationsResponse: type: object properties: delegation_responses: type: array items: type: object properties: delegation: type: object properties: delegator_address: type: string description: delegator_address is the bech32-encoded address of the delegator. validator_address: type: string description: validator_address is the bech32-encoded address of the validator. shares: type: string description: shares define the delegation shares received. description: >- Delegation represents the bond with tokens held by an account. It is owned by one delegator, and is associated with the voting power of one validator. balance: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- DelegationResponse is equivalent to Delegation except that it contains a balance in addition to shares which is more suitable for client responses. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: |- QueryValidatorDelegationsResponse is response type for the Query/ValidatorDelegations RPC method cosmos.staking.v1beta1.QueryValidatorResponse: type: object properties: validator: type: object properties: operator_address: type: string description: operator_address defines the address of the validator's operator; bech encoded in JSON. consensus_pubkey: type: object properties: type_url: type: string value: type: string format: byte description: consensus_pubkey is the consensus public key of the validator, as a Protobuf Any. jailed: type: boolean description: jailed defined whether the validator has been jailed from bonded status or not. status: description: status is the validator status (bonded/unbonding/unbonded). type: string enum: - BOND_STATUS_UNSPECIFIED - BOND_STATUS_UNBONDED - BOND_STATUS_UNBONDING - BOND_STATUS_BONDED default: BOND_STATUS_UNSPECIFIED tokens: type: string description: tokens define the delegated tokens (incl. self-delegation). delegator_shares: type: string description: delegator_shares defines total shares issued to a validator's delegators. description: description: description defines the description terms for the validator. type: object properties: moniker: type: string description: moniker defines a human-readable name for the validator. identity: type: string description: identity defines an optional identity signature (ex. UPort or Keybase). website: type: string description: website defines an optional website link. security_contact: type: string description: security_contact defines an optional email for security contact. details: type: string description: details define other optional details. unbonding_height: type: string format: int64 description: unbonding_height defines, if unbonding, the height at which this validator has begun unbonding. unbonding_time: type: string format: date-time description: unbonding_time defines, if unbonding, the min time for the validator to complete unbonding. commission: description: commission defines the commission parameters. type: object properties: commission_rates: description: commission_rates defines the initial commission rates to be used for creating a validator. type: object properties: rate: type: string description: rate is the commission rate charged to delegators, as a fraction. max_rate: type: string description: max_rate defines the maximum commission rate which validator can ever charge, as a fraction. max_change_rate: type: string description: max_change_rate defines the maximum daily increase of the validator commission, as a fraction. update_time: type: string format: date-time description: update_time is the last time the commission rate was changed. min_self_delegation: type: string description: >- min_self_delegation is the validator's self declared minimum self delegation. Since: cosmos-sdk 0.46 unbonding_on_hold_ref_count: type: string format: int64 title: strictly positive if this validator's unbonding has been stopped by external modules unbonding_ids: type: array items: type: string format: uint64 title: list of unbonding ids, each uniquely identifing an unbonding of this validator description: >- Validator defines a validator, together with the total amount of the Validator's bond shares and their exchange rate to coins. Slashing results in a decrease in the exchange rate, allowing correct calculation of future undelegations without iterating over delegators. When coins are delegated to this validator, the validator is credited with a delegation whose number of bond shares is based on the amount of coins delegated divided by the current exchange rate. Voting power can be calculated as total bonded shares multiplied by exchange rate. title: QueryValidatorResponse is response type for the Query/Validator RPC method cosmos.staking.v1beta1.QueryValidatorUnbondingDelegationsResponse: type: object properties: unbonding_responses: type: array items: type: object properties: delegator_address: type: string description: delegator_address is the bech32-encoded address of the delegator. validator_address: type: string description: validator_address is the bech32-encoded address of the validator. entries: type: array items: type: object properties: creation_height: type: string format: int64 description: creation_height is the height which the unbonding took place. completion_time: type: string format: date-time description: completion_time is the unix time for unbonding completion. initial_balance: type: string description: initial_balance defines the tokens initially scheduled to receive at completion. balance: type: string description: balance defines the tokens to receive at completion. unbonding_id: type: string format: uint64 title: Incrementing id that uniquely identifies this entry unbonding_on_hold_ref_count: type: string format: int64 title: Strictly positive if this entry's unbonding has been stopped by external modules description: UnbondingDelegationEntry defines an unbonding object with relevant metadata. description: entries are the unbonding delegation entries. description: >- UnbondingDelegation stores all of a single delegator's unbonding bonds for a single validator in an time-ordered list. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: |- QueryValidatorUnbondingDelegationsResponse is response type for the Query/ValidatorUnbondingDelegations RPC method. cosmos.staking.v1beta1.QueryValidatorsResponse: type: object properties: validators: type: array items: type: object properties: operator_address: type: string description: operator_address defines the address of the validator's operator; bech encoded in JSON. consensus_pubkey: type: object properties: type_url: type: string value: type: string format: byte description: consensus_pubkey is the consensus public key of the validator, as a Protobuf Any. jailed: type: boolean description: jailed defined whether the validator has been jailed from bonded status or not. status: description: status is the validator status (bonded/unbonding/unbonded). type: string enum: - BOND_STATUS_UNSPECIFIED - BOND_STATUS_UNBONDED - BOND_STATUS_UNBONDING - BOND_STATUS_BONDED default: BOND_STATUS_UNSPECIFIED tokens: type: string description: tokens define the delegated tokens (incl. self-delegation). delegator_shares: type: string description: delegator_shares defines total shares issued to a validator's delegators. description: description: description defines the description terms for the validator. type: object properties: moniker: type: string description: moniker defines a human-readable name for the validator. identity: type: string description: identity defines an optional identity signature (ex. UPort or Keybase). website: type: string description: website defines an optional website link. security_contact: type: string description: security_contact defines an optional email for security contact. details: type: string description: details define other optional details. unbonding_height: type: string format: int64 description: unbonding_height defines, if unbonding, the height at which this validator has begun unbonding. unbonding_time: type: string format: date-time description: unbonding_time defines, if unbonding, the min time for the validator to complete unbonding. commission: description: commission defines the commission parameters. type: object properties: commission_rates: description: commission_rates defines the initial commission rates to be used for creating a validator. type: object properties: rate: type: string description: rate is the commission rate charged to delegators, as a fraction. max_rate: type: string description: max_rate defines the maximum commission rate which validator can ever charge, as a fraction. max_change_rate: type: string description: max_change_rate defines the maximum daily increase of the validator commission, as a fraction. update_time: type: string format: date-time description: update_time is the last time the commission rate was changed. min_self_delegation: type: string description: >- min_self_delegation is the validator's self declared minimum self delegation. Since: cosmos-sdk 0.46 unbonding_on_hold_ref_count: type: string format: int64 title: strictly positive if this validator's unbonding has been stopped by external modules unbonding_ids: type: array items: type: string format: uint64 title: list of unbonding ids, each uniquely identifing an unbonding of this validator description: >- Validator defines a validator, together with the total amount of the Validator's bond shares and their exchange rate to coins. Slashing results in a decrease in the exchange rate, allowing correct calculation of future undelegations without iterating over delegators. When coins are delegated to this validator, the validator is credited with a delegation whose number of bond shares is based on the amount of coins delegated divided by the current exchange rate. Voting power can be calculated as total bonded shares multiplied by exchange rate. description: validators contains all the queried validators. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: QueryValidatorsResponse is response type for the Query/Validators RPC method cosmos.staking.v1beta1.Redelegation: type: object properties: delegator_address: type: string description: delegator_address is the bech32-encoded address of the delegator. validator_src_address: type: string description: validator_src_address is the validator redelegation source operator address. validator_dst_address: type: string description: validator_dst_address is the validator redelegation destination operator address. entries: type: array items: type: object properties: creation_height: type: string format: int64 description: creation_height defines the height which the redelegation took place. completion_time: type: string format: date-time description: completion_time defines the unix time for redelegation completion. initial_balance: type: string description: initial_balance defines the initial balance when redelegation started. shares_dst: type: string description: shares_dst is the amount of destination-validator shares created by redelegation. unbonding_id: type: string format: uint64 title: Incrementing id that uniquely identifies this entry unbonding_on_hold_ref_count: type: string format: int64 title: Strictly positive if this entry's unbonding has been stopped by external modules description: RedelegationEntry defines a redelegation object with relevant metadata. description: entries are the redelegation entries. description: >- Redelegation contains the list of a particular delegator's redelegating bonds from a particular source validator to a particular destination validator. cosmos.staking.v1beta1.RedelegationEntry: type: object properties: creation_height: type: string format: int64 description: creation_height defines the height which the redelegation took place. completion_time: type: string format: date-time description: completion_time defines the unix time for redelegation completion. initial_balance: type: string description: initial_balance defines the initial balance when redelegation started. shares_dst: type: string description: shares_dst is the amount of destination-validator shares created by redelegation. unbonding_id: type: string format: uint64 title: Incrementing id that uniquely identifies this entry unbonding_on_hold_ref_count: type: string format: int64 title: Strictly positive if this entry's unbonding has been stopped by external modules description: RedelegationEntry defines a redelegation object with relevant metadata. cosmos.staking.v1beta1.RedelegationEntryResponse: type: object properties: redelegation_entry: type: object properties: creation_height: type: string format: int64 description: creation_height defines the height which the redelegation took place. completion_time: type: string format: date-time description: completion_time defines the unix time for redelegation completion. initial_balance: type: string description: initial_balance defines the initial balance when redelegation started. shares_dst: type: string description: shares_dst is the amount of destination-validator shares created by redelegation. unbonding_id: type: string format: uint64 title: Incrementing id that uniquely identifies this entry unbonding_on_hold_ref_count: type: string format: int64 title: Strictly positive if this entry's unbonding has been stopped by external modules description: RedelegationEntry defines a redelegation object with relevant metadata. balance: type: string description: >- RedelegationEntryResponse is equivalent to a RedelegationEntry except that it contains a balance in addition to shares which is more suitable for client responses. cosmos.staking.v1beta1.RedelegationResponse: type: object properties: redelegation: type: object properties: delegator_address: type: string description: delegator_address is the bech32-encoded address of the delegator. validator_src_address: type: string description: validator_src_address is the validator redelegation source operator address. validator_dst_address: type: string description: validator_dst_address is the validator redelegation destination operator address. entries: type: array items: type: object properties: creation_height: type: string format: int64 description: creation_height defines the height which the redelegation took place. completion_time: type: string format: date-time description: completion_time defines the unix time for redelegation completion. initial_balance: type: string description: initial_balance defines the initial balance when redelegation started. shares_dst: type: string description: shares_dst is the amount of destination-validator shares created by redelegation. unbonding_id: type: string format: uint64 title: Incrementing id that uniquely identifies this entry unbonding_on_hold_ref_count: type: string format: int64 title: Strictly positive if this entry's unbonding has been stopped by external modules description: RedelegationEntry defines a redelegation object with relevant metadata. description: entries are the redelegation entries. description: >- Redelegation contains the list of a particular delegator's redelegating bonds from a particular source validator to a particular destination validator. entries: type: array items: type: object properties: redelegation_entry: type: object properties: creation_height: type: string format: int64 description: creation_height defines the height which the redelegation took place. completion_time: type: string format: date-time description: completion_time defines the unix time for redelegation completion. initial_balance: type: string description: initial_balance defines the initial balance when redelegation started. shares_dst: type: string description: shares_dst is the amount of destination-validator shares created by redelegation. unbonding_id: type: string format: uint64 title: Incrementing id that uniquely identifies this entry unbonding_on_hold_ref_count: type: string format: int64 title: Strictly positive if this entry's unbonding has been stopped by external modules description: RedelegationEntry defines a redelegation object with relevant metadata. balance: type: string description: >- RedelegationEntryResponse is equivalent to a RedelegationEntry except that it contains a balance in addition to shares which is more suitable for client responses. description: >- RedelegationResponse is equivalent to a Redelegation except that its entries contain a balance in addition to shares which is more suitable for client responses. cosmos.staking.v1beta1.UnbondingDelegation: type: object properties: delegator_address: type: string description: delegator_address is the bech32-encoded address of the delegator. validator_address: type: string description: validator_address is the bech32-encoded address of the validator. entries: type: array items: type: object properties: creation_height: type: string format: int64 description: creation_height is the height which the unbonding took place. completion_time: type: string format: date-time description: completion_time is the unix time for unbonding completion. initial_balance: type: string description: initial_balance defines the tokens initially scheduled to receive at completion. balance: type: string description: balance defines the tokens to receive at completion. unbonding_id: type: string format: uint64 title: Incrementing id that uniquely identifies this entry unbonding_on_hold_ref_count: type: string format: int64 title: Strictly positive if this entry's unbonding has been stopped by external modules description: UnbondingDelegationEntry defines an unbonding object with relevant metadata. description: entries are the unbonding delegation entries. description: |- UnbondingDelegation stores all of a single delegator's unbonding bonds for a single validator in an time-ordered list. cosmos.staking.v1beta1.UnbondingDelegationEntry: type: object properties: creation_height: type: string format: int64 description: creation_height is the height which the unbonding took place. completion_time: type: string format: date-time description: completion_time is the unix time for unbonding completion. initial_balance: type: string description: initial_balance defines the tokens initially scheduled to receive at completion. balance: type: string description: balance defines the tokens to receive at completion. unbonding_id: type: string format: uint64 title: Incrementing id that uniquely identifies this entry unbonding_on_hold_ref_count: type: string format: int64 title: Strictly positive if this entry's unbonding has been stopped by external modules description: UnbondingDelegationEntry defines an unbonding object with relevant metadata. cosmos.staking.v1beta1.Validator: type: object properties: operator_address: type: string description: operator_address defines the address of the validator's operator; bech encoded in JSON. consensus_pubkey: type: object properties: type_url: type: string value: type: string format: byte description: consensus_pubkey is the consensus public key of the validator, as a Protobuf Any. jailed: type: boolean description: jailed defined whether the validator has been jailed from bonded status or not. status: description: status is the validator status (bonded/unbonding/unbonded). type: string enum: - BOND_STATUS_UNSPECIFIED - BOND_STATUS_UNBONDED - BOND_STATUS_UNBONDING - BOND_STATUS_BONDED default: BOND_STATUS_UNSPECIFIED tokens: type: string description: tokens define the delegated tokens (incl. self-delegation). delegator_shares: type: string description: delegator_shares defines total shares issued to a validator's delegators. description: description: description defines the description terms for the validator. type: object properties: moniker: type: string description: moniker defines a human-readable name for the validator. identity: type: string description: identity defines an optional identity signature (ex. UPort or Keybase). website: type: string description: website defines an optional website link. security_contact: type: string description: security_contact defines an optional email for security contact. details: type: string description: details define other optional details. unbonding_height: type: string format: int64 description: unbonding_height defines, if unbonding, the height at which this validator has begun unbonding. unbonding_time: type: string format: date-time description: unbonding_time defines, if unbonding, the min time for the validator to complete unbonding. commission: description: commission defines the commission parameters. type: object properties: commission_rates: description: commission_rates defines the initial commission rates to be used for creating a validator. type: object properties: rate: type: string description: rate is the commission rate charged to delegators, as a fraction. max_rate: type: string description: max_rate defines the maximum commission rate which validator can ever charge, as a fraction. max_change_rate: type: string description: max_change_rate defines the maximum daily increase of the validator commission, as a fraction. update_time: type: string format: date-time description: update_time is the last time the commission rate was changed. min_self_delegation: type: string description: >- min_self_delegation is the validator's self declared minimum self delegation. Since: cosmos-sdk 0.46 unbonding_on_hold_ref_count: type: string format: int64 title: strictly positive if this validator's unbonding has been stopped by external modules unbonding_ids: type: array items: type: string format: uint64 title: list of unbonding ids, each uniquely identifing an unbonding of this validator description: >- Validator defines a validator, together with the total amount of the Validator's bond shares and their exchange rate to coins. Slashing results in a decrease in the exchange rate, allowing correct calculation of future undelegations without iterating over delegators. When coins are delegated to this validator, the validator is credited with a delegation whose number of bond shares is based on the amount of coins delegated divided by the current exchange rate. Voting power can be calculated as total bonded shares multiplied by exchange rate. tendermint.types.BlockID: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID tendermint.types.Header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. tendermint.types.PartSetHeader: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader tendermint.version.Consensus: type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. ibc.applications.transfer.v1.DenomTrace: type: object properties: path: type: string description: >- path defines the chain of port/channel identifiers used for tracing the source of the fungible token. base_denom: type: string description: base denomination of the relayed fungible token. description: >- DenomTrace contains the base denomination for ICS20 fungible tokens and the source tracing information path. ibc.applications.transfer.v1.Params: type: object properties: send_enabled: type: boolean description: >- send_enabled enables or disables all cross-chain token transfers from this chain. receive_enabled: type: boolean description: >- receive_enabled enables or disables all cross-chain token transfers to this chain. description: >- Params defines the set of IBC transfer parameters. NOTE: To prevent a single token from being transferred, set the TransfersEnabled parameter to true and then set the bank module's SendEnabled parameter for the denomination to false. ibc.applications.transfer.v1.QueryDenomHashResponse: type: object properties: hash: type: string description: hash (in hex format) of the denomination trace information. description: |- QueryDenomHashResponse is the response type for the Query/DenomHash RPC method. ibc.applications.transfer.v1.QueryDenomTraceResponse: type: object properties: denom_trace: type: object properties: path: type: string description: >- path defines the chain of port/channel identifiers used for tracing the source of the fungible token. base_denom: type: string description: base denomination of the relayed fungible token. description: >- DenomTrace contains the base denomination for ICS20 fungible tokens and the source tracing information path. description: >- QueryDenomTraceResponse is the response type for the Query/DenomTrace RPC method. ibc.applications.transfer.v1.QueryDenomTracesResponse: type: object properties: denom_traces: type: array items: type: object properties: path: type: string description: >- path defines the chain of port/channel identifiers used for tracing the source of the fungible token. base_denom: type: string description: base denomination of the relayed fungible token. description: >- DenomTrace contains the base denomination for ICS20 fungible tokens and the source tracing information path. description: denom_traces returns all denominations trace information. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- QueryConnectionsResponse is the response type for the Query/DenomTraces RPC method. ibc.applications.transfer.v1.QueryEscrowAddressResponse: type: object properties: escrow_address: type: string title: the escrow account address description: QueryEscrowAddressResponse is the response type of the EscrowAddress RPC method. ibc.applications.transfer.v1.QueryParamsResponse: type: object properties: params: description: params defines the parameters of the module. type: object properties: send_enabled: type: boolean description: >- send_enabled enables or disables all cross-chain token transfers from this chain. receive_enabled: type: boolean description: >- receive_enabled enables or disables all cross-chain token transfers to this chain. description: QueryParamsResponse is the response type for the Query/Params RPC method. ibc.applications.transfer.v1.QueryTotalEscrowForDenomResponse: type: object properties: amount: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: QueryTotalEscrowForDenomResponse is the response type for TotalEscrowForDenom RPC method. cosmos.base.abci.v1beta1.ABCIMessageLog: type: object properties: msg_index: type: integer format: int64 log: type: string events: type: array items: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string description: >- Attribute defines an attribute wrapper where the key and value are strings instead of raw bytes. description: >- StringEvent defines en Event object wrapper where all the attributes contain key/value pairs that are strings instead of raw bytes. description: >- Events contains a slice of Event objects that were emitted during some execution. description: ABCIMessageLog defines a structure containing an indexed tx ABCI message log. cosmos.base.abci.v1beta1.Attribute: type: object properties: key: type: string value: type: string description: |- Attribute defines an attribute wrapper where the key and value are strings instead of raw bytes. cosmos.base.abci.v1beta1.GasInfo: type: object properties: gas_wanted: type: string format: uint64 description: GasWanted is the maximum units of work we allow this tx to perform. gas_used: type: string format: uint64 description: GasUsed is the amount of gas actually consumed. description: GasInfo defines tx execution gas context. cosmos.base.abci.v1beta1.Result: type: object properties: data: type: string format: byte description: >- Data is any data returned from message or handler execution. It MUST be length prefixed in order to separate data from multiple message executions. Deprecated. This field is still populated, but prefer msg_response instead because it also contains the Msg response typeURL. log: type: string description: Log contains the log information from message or handler execution. events: type: array items: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string index: type: boolean description: EventAttribute is a single key-value pair, associated with an event. description: >- Event allows application developers to attach additional information to ResponseBeginBlock, ResponseEndBlock, ResponseCheckTx and ResponseDeliverTx. Later, transactions may be queried using these events. description: >- Events contains a slice of Event objects that were emitted during message or handler execution. msg_responses: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- msg_responses contains the Msg handler responses type packed in Anys. Since: cosmos-sdk 0.46 description: Result is the union of ResponseFormat and ResponseCheckTx. cosmos.base.abci.v1beta1.StringEvent: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string description: |- Attribute defines an attribute wrapper where the key and value are strings instead of raw bytes. description: |- StringEvent defines en Event object wrapper where all the attributes contain key/value pairs that are strings instead of raw bytes. cosmos.base.abci.v1beta1.TxResponse: type: object properties: height: type: string format: int64 title: The block height txhash: type: string description: The transaction hash. codespace: type: string title: Namespace for the Code code: type: integer format: int64 description: Response code. data: type: string description: Result bytes, if any. raw_log: type: string description: |- The output of the application's logger (raw string). May be non-deterministic. logs: type: array items: type: object properties: msg_index: type: integer format: int64 log: type: string events: type: array items: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string description: >- Attribute defines an attribute wrapper where the key and value are strings instead of raw bytes. description: >- StringEvent defines en Event object wrapper where all the attributes contain key/value pairs that are strings instead of raw bytes. description: >- Events contains a slice of Event objects that were emitted during some execution. description: ABCIMessageLog defines a structure containing an indexed tx ABCI message log. description: The output of the application's logger (typed). May be non-deterministic. info: type: string description: Additional information. May be non-deterministic. gas_wanted: type: string format: int64 description: Amount of gas requested for transaction. gas_used: type: string format: int64 description: Amount of gas consumed by transaction. tx: type: object properties: type_url: type: string value: type: string format: byte description: The request transaction bytes. timestamp: type: string description: >- Time of the previous block. For heights > 1, it's the weighted median of the timestamps of the valid votes in the block.LastCommit. For height == 1, it's genesis time. events: type: array items: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string index: type: boolean description: EventAttribute is a single key-value pair, associated with an event. description: >- Event allows application developers to attach additional information to ResponseBeginBlock, ResponseEndBlock, ResponseCheckTx and ResponseDeliverTx. Later, transactions may be queried using these events. description: >- Events defines all the events emitted by processing a transaction. Note, these events include those emitted by processing all the messages and those emitted from the ante. Whereas Logs contains the events, with additional metadata, emitted only by processing the messages. Since: cosmos-sdk 0.42.11, 0.44.5, 0.45 description: >- TxResponse defines a structure containing relevant tx data and metadata. The tags are stringified and the log is JSON decoded. cosmos.crypto.multisig.v1beta1.CompactBitArray: type: object properties: extra_bits_stored: type: integer format: int64 elems: type: string format: byte description: >- CompactBitArray is an implementation of a space efficient bit array. This is used to ensure that the encoded data takes up a minimal amount of space after proto encoding. This is not thread safe, and is not intended for concurrent usage. cosmos.tx.signing.v1beta1.SignMode: type: string enum: - SIGN_MODE_UNSPECIFIED - SIGN_MODE_DIRECT - SIGN_MODE_TEXTUAL - SIGN_MODE_DIRECT_AUX - SIGN_MODE_LEGACY_AMINO_JSON - SIGN_MODE_EIP_191 default: SIGN_MODE_UNSPECIFIED description: >- SignMode represents a signing mode with its own security guarantees. This enum should be considered a registry of all known sign modes in the Cosmos ecosystem. Apps are not expected to support all known sign modes. Apps that would like to support custom sign modes are encouraged to open a small PR against this file to add a new case to this SignMode enum describing their sign mode so that different apps have a consistent version of this enum. - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be rejected. - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is verified with raw bytes from Tx. - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some human-readable textual representation on top of the binary representation from SIGN_MODE_DIRECT. It is currently not supported. - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses SignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not require signers signing over other signers' `signer_info`. It also allows for adding Tips in transactions. Since: cosmos-sdk 0.46 - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses Amino JSON and will be removed in the future. - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos SDK. Ref: https://eips.ethereum.org/EIPS/eip-191 Currently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant, but is not implemented on the SDK by default. To enable EIP-191, you need to pass a custom `TxConfig` that has an implementation of `SignModeHandler` for EIP-191. The SDK may decide to fully support EIP-191 in the future. Since: cosmos-sdk 0.45.2 cosmos.tx.v1beta1.AuthInfo: type: object properties: signer_infos: type: array items: type: object properties: public_key: type: object properties: type_url: type: string value: type: string format: byte description: >- public_key is the public key of the signer. It is optional for accounts that already exist in state. If unset, the verifier can use the required \ signer address for this position and lookup the public key. mode_info: title: >- mode_info describes the signing mode of the signer and is a nested structure to support nested multisig pubkey's type: object properties: single: title: single represents a single signer type: object properties: mode: title: mode is the signing mode of the single signer type: string enum: - SIGN_MODE_UNSPECIFIED - SIGN_MODE_DIRECT - SIGN_MODE_TEXTUAL - SIGN_MODE_DIRECT_AUX - SIGN_MODE_LEGACY_AMINO_JSON - SIGN_MODE_EIP_191 default: SIGN_MODE_UNSPECIFIED description: >- SignMode represents a signing mode with its own security guarantees. This enum should be considered a registry of all known sign modes in the Cosmos ecosystem. Apps are not expected to support all known sign modes. Apps that would like to support custom sign modes are encouraged to open a small PR against this file to add a new case to this SignMode enum describing their sign mode so that different apps have a consistent version of this enum. - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be rejected. - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is verified with raw bytes from Tx. - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some human-readable textual representation on top of the binary representation from SIGN_MODE_DIRECT. It is currently not supported. - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses SignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not require signers signing over other signers' `signer_info`. It also allows for adding Tips in transactions. Since: cosmos-sdk 0.46 - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses Amino JSON and will be removed in the future. - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos SDK. Ref: https://eips.ethereum.org/EIPS/eip-191 Currently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant, but is not implemented on the SDK by default. To enable EIP-191, you need to pass a custom `TxConfig` that has an implementation of `SignModeHandler` for EIP-191. The SDK may decide to fully support EIP-191 in the future. Since: cosmos-sdk 0.45.2 multi: title: multi represents a nested multisig signer type: object properties: bitarray: title: bitarray specifies which keys within the multisig are signing type: object properties: extra_bits_stored: type: integer format: int64 elems: type: string format: byte description: >- CompactBitArray is an implementation of a space efficient bit array. This is used to ensure that the encoded data takes up a minimal amount of space after proto encoding. This is not thread safe, and is not intended for concurrent usage. mode_infos: type: array items: {} title: >- mode_infos is the corresponding modes of the signers of the multisig which could include nested multisig public keys description: ModeInfo describes the signing mode of a single or nested multisig signer. sequence: type: string format: uint64 description: >- sequence is the sequence of the account, which describes the number of committed transactions signed by a given address. It is used to prevent replay attacks. description: >- SignerInfo describes the public key and signing mode of a single top-level signer. description: >- signer_infos defines the signing modes for the required signers. The number and order of elements must match the required signers from TxBody's messages. The first element is the primary signer and the one which pays the fee. fee: description: >- Fee is the fee and gas limit for the transaction. The first signer is the primary signer and the one which pays the fee. The fee can be calculated based on the cost of evaluating the body and doing signature verification of the signers. This can be estimated via simulation. type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of coins to be paid as a fee gas_limit: type: string format: uint64 title: >- gas_limit is the maximum gas that can be used in transaction processing before an out of gas error occurs payer: type: string description: >- if unset, the first signer is responsible for paying the fees. If set, the specified account must pay the fees. the payer must be a tx signer (and thus have signed this field in AuthInfo). setting this field does *not* change the ordering of required signers for the transaction. granter: type: string title: >- if set, the fee payer (either the first signer or the value of the payer field) requests that a fee grant be used to pay fees instead of the fee payer's own balance. If an appropriate fee grant does not exist or the chain does not support fee grants, this will fail tip: description: >- Tip is the optional tip used for transactions fees paid in another denom. This field is ignored if the chain didn't enable tips, i.e. didn't add the `TipDecorator` in its posthandler. Since: cosmos-sdk 0.46 type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of the tip tipper: type: string title: tipper is the address of the account paying for the tip description: |- AuthInfo describes the fee and signer modes that are used to sign a transaction. cosmos.tx.v1beta1.BroadcastMode: type: string enum: - BROADCAST_MODE_UNSPECIFIED - BROADCAST_MODE_BLOCK - BROADCAST_MODE_SYNC - BROADCAST_MODE_ASYNC default: BROADCAST_MODE_UNSPECIFIED description: >- BroadcastMode specifies the broadcast mode for the TxService.Broadcast RPC method. - BROADCAST_MODE_UNSPECIFIED: zero-value for mode ordering - BROADCAST_MODE_BLOCK: DEPRECATED: use BROADCAST_MODE_SYNC instead, BROADCAST_MODE_BLOCK is not supported by the SDK from v0.47.x onwards. - BROADCAST_MODE_SYNC: BROADCAST_MODE_SYNC defines a tx broadcasting mode where the client waits for a CheckTx execution response only. - BROADCAST_MODE_ASYNC: BROADCAST_MODE_ASYNC defines a tx broadcasting mode where the client returns immediately. cosmos.tx.v1beta1.BroadcastTxRequest: type: object properties: tx_bytes: type: string format: byte description: tx_bytes is the raw transaction. mode: type: string enum: - BROADCAST_MODE_UNSPECIFIED - BROADCAST_MODE_BLOCK - BROADCAST_MODE_SYNC - BROADCAST_MODE_ASYNC default: BROADCAST_MODE_UNSPECIFIED description: >- BroadcastMode specifies the broadcast mode for the TxService.Broadcast RPC method. - BROADCAST_MODE_UNSPECIFIED: zero-value for mode ordering - BROADCAST_MODE_BLOCK: DEPRECATED: use BROADCAST_MODE_SYNC instead, BROADCAST_MODE_BLOCK is not supported by the SDK from v0.47.x onwards. - BROADCAST_MODE_SYNC: BROADCAST_MODE_SYNC defines a tx broadcasting mode where the client waits for a CheckTx execution response only. - BROADCAST_MODE_ASYNC: BROADCAST_MODE_ASYNC defines a tx broadcasting mode where the client returns immediately. description: >- BroadcastTxRequest is the request type for the Service.BroadcastTxRequest RPC method. cosmos.tx.v1beta1.BroadcastTxResponse: type: object properties: tx_response: type: object properties: height: type: string format: int64 title: The block height txhash: type: string description: The transaction hash. codespace: type: string title: Namespace for the Code code: type: integer format: int64 description: Response code. data: type: string description: Result bytes, if any. raw_log: type: string description: |- The output of the application's logger (raw string). May be non-deterministic. logs: type: array items: type: object properties: msg_index: type: integer format: int64 log: type: string events: type: array items: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string description: >- Attribute defines an attribute wrapper where the key and value are strings instead of raw bytes. description: >- StringEvent defines en Event object wrapper where all the attributes contain key/value pairs that are strings instead of raw bytes. description: >- Events contains a slice of Event objects that were emitted during some execution. description: ABCIMessageLog defines a structure containing an indexed tx ABCI message log. description: The output of the application's logger (typed). May be non-deterministic. info: type: string description: Additional information. May be non-deterministic. gas_wanted: type: string format: int64 description: Amount of gas requested for transaction. gas_used: type: string format: int64 description: Amount of gas consumed by transaction. tx: type: object properties: type_url: type: string value: type: string format: byte description: The request transaction bytes. timestamp: type: string description: >- Time of the previous block. For heights > 1, it's the weighted median of the timestamps of the valid votes in the block.LastCommit. For height == 1, it's genesis time. events: type: array items: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string index: type: boolean description: EventAttribute is a single key-value pair, associated with an event. description: >- Event allows application developers to attach additional information to ResponseBeginBlock, ResponseEndBlock, ResponseCheckTx and ResponseDeliverTx. Later, transactions may be queried using these events. description: >- Events defines all the events emitted by processing a transaction. Note, these events include those emitted by processing all the messages and those emitted from the ante. Whereas Logs contains the events, with additional metadata, emitted only by processing the messages. Since: cosmos-sdk 0.42.11, 0.44.5, 0.45 description: >- TxResponse defines a structure containing relevant tx data and metadata. The tags are stringified and the log is JSON decoded. description: |- BroadcastTxResponse is the response type for the Service.BroadcastTx method. cosmos.tx.v1beta1.Fee: type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of coins to be paid as a fee gas_limit: type: string format: uint64 title: >- gas_limit is the maximum gas that can be used in transaction processing before an out of gas error occurs payer: type: string description: >- if unset, the first signer is responsible for paying the fees. If set, the specified account must pay the fees. the payer must be a tx signer (and thus have signed this field in AuthInfo). setting this field does *not* change the ordering of required signers for the transaction. granter: type: string title: >- if set, the fee payer (either the first signer or the value of the payer field) requests that a fee grant be used to pay fees instead of the fee payer's own balance. If an appropriate fee grant does not exist or the chain does not support fee grants, this will fail description: >- Fee includes the amount of coins paid in fees and the maximum gas to be used by the transaction. The ratio yields an effective "gasprice", which must be above some miminum to be accepted into the mempool. cosmos.tx.v1beta1.GetBlockWithTxsResponse: type: object properties: txs: type: array items: type: object properties: body: title: body is the processable content of the transaction type: object properties: messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- messages is a list of messages to be executed. The required signers of those messages define the number and order of elements in AuthInfo's signer_infos and Tx's signatures. Each required signer address is added to the list only the first time it occurs. By convention, the first required signer (usually from the first message) is referred to as the primary signer and pays the fee for the whole transaction. memo: type: string description: >- memo is any arbitrary note/comment to be added to the transaction. WARNING: in clients, any publicly exposed text should not be called memo, but should be called `note` instead (see https://github.com/cosmos/cosmos-sdk/issues/9122). timeout_height: type: string format: uint64 title: >- timeout is the block height after which this transaction will not be processed by the chain extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, the transaction will be rejected non_critical_extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, they will be ignored description: TxBody is the body of a transaction that all signers sign over. auth_info: title: >- auth_info is the authorization related content of the transaction, specifically signers, signer modes and fee type: object properties: signer_infos: type: array items: type: object properties: public_key: type: object properties: type_url: type: string value: type: string format: byte description: >- public_key is the public key of the signer. It is optional for accounts that already exist in state. If unset, the verifier can use the required \ signer address for this position and lookup the public key. mode_info: title: >- mode_info describes the signing mode of the signer and is a nested structure to support nested multisig pubkey's type: object properties: single: title: single represents a single signer type: object properties: mode: title: mode is the signing mode of the single signer type: string enum: - SIGN_MODE_UNSPECIFIED - SIGN_MODE_DIRECT - SIGN_MODE_TEXTUAL - SIGN_MODE_DIRECT_AUX - SIGN_MODE_LEGACY_AMINO_JSON - SIGN_MODE_EIP_191 default: SIGN_MODE_UNSPECIFIED description: >- SignMode represents a signing mode with its own security guarantees. This enum should be considered a registry of all known sign modes in the Cosmos ecosystem. Apps are not expected to support all known sign modes. Apps that would like to support custom sign modes are encouraged to open a small PR against this file to add a new case to this SignMode enum describing their sign mode so that different apps have a consistent version of this enum. - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be rejected. - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is verified with raw bytes from Tx. - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some human-readable textual representation on top of the binary representation from SIGN_MODE_DIRECT. It is currently not supported. - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses SignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not require signers signing over other signers' `signer_info`. It also allows for adding Tips in transactions. Since: cosmos-sdk 0.46 - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses Amino JSON and will be removed in the future. - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos SDK. Ref: https://eips.ethereum.org/EIPS/eip-191 Currently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant, but is not implemented on the SDK by default. To enable EIP-191, you need to pass a custom `TxConfig` that has an implementation of `SignModeHandler` for EIP-191. The SDK may decide to fully support EIP-191 in the future. Since: cosmos-sdk 0.45.2 multi: title: multi represents a nested multisig signer type: object properties: bitarray: title: bitarray specifies which keys within the multisig are signing type: object properties: extra_bits_stored: type: integer format: int64 elems: type: string format: byte description: >- CompactBitArray is an implementation of a space efficient bit array. This is used to ensure that the encoded data takes up a minimal amount of space after proto encoding. This is not thread safe, and is not intended for concurrent usage. mode_infos: type: array items: {} title: >- mode_infos is the corresponding modes of the signers of the multisig which could include nested multisig public keys description: ModeInfo describes the signing mode of a single or nested multisig signer. sequence: type: string format: uint64 description: >- sequence is the sequence of the account, which describes the number of committed transactions signed by a given address. It is used to prevent replay attacks. description: >- SignerInfo describes the public key and signing mode of a single top-level signer. description: >- signer_infos defines the signing modes for the required signers. The number and order of elements must match the required signers from TxBody's messages. The first element is the primary signer and the one which pays the fee. fee: description: >- Fee is the fee and gas limit for the transaction. The first signer is the primary signer and the one which pays the fee. The fee can be calculated based on the cost of evaluating the body and doing signature verification of the signers. This can be estimated via simulation. type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of coins to be paid as a fee gas_limit: type: string format: uint64 title: >- gas_limit is the maximum gas that can be used in transaction processing before an out of gas error occurs payer: type: string description: >- if unset, the first signer is responsible for paying the fees. If set, the specified account must pay the fees. the payer must be a tx signer (and thus have signed this field in AuthInfo). setting this field does *not* change the ordering of required signers for the transaction. granter: type: string title: >- if set, the fee payer (either the first signer or the value of the payer field) requests that a fee grant be used to pay fees instead of the fee payer's own balance. If an appropriate fee grant does not exist or the chain does not support fee grants, this will fail tip: description: >- Tip is the optional tip used for transactions fees paid in another denom. This field is ignored if the chain didn't enable tips, i.e. didn't add the `TipDecorator` in its posthandler. Since: cosmos-sdk 0.46 type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of the tip tipper: type: string title: tipper is the address of the account paying for the tip description: >- AuthInfo describes the fee and signer modes that are used to sign a transaction. signatures: type: array items: type: string format: byte description: >- signatures is a list of signatures that matches the length and order of AuthInfo's signer_infos to allow connecting signature meta information like public key and signing mode by position. description: Tx is the standard type used for broadcasting transactions. description: txs are the transactions in the block. block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID block: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. data: type: object properties: txs: type: array items: type: string format: byte description: >- Txs that will be applied by state @ block.Height+1. NOTE: not all txs here are valid. We're just agreeing on the order first. This means that block.AppHash does not include these txs. title: Data contains the set of transactions included in the block evidence: type: object properties: evidence: type: array items: type: object properties: duplicate_vote_evidence: type: object properties: vote_a: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. vote_b: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. total_voting_power: type: string format: int64 validator_power: type: string format: int64 timestamp: type: string format: date-time description: DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes. light_client_attack_evidence: type: object properties: conflicting_block: type: object properties: signed_header: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: Commit contains the evidence that a block was committed by a set of validators. validator_set: type: object properties: validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 proposer: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 common_height: type: string format: int64 byzantine_validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 timestamp: type: string format: date-time description: LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client. last_commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: Commit contains the evidence that a block was committed by a set of validators. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- GetBlockWithTxsResponse is the response type for the Service.GetBlockWithTxs method. Since: cosmos-sdk 0.45.2 cosmos.tx.v1beta1.GetTxResponse: type: object properties: tx: type: object properties: body: title: body is the processable content of the transaction type: object properties: messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- messages is a list of messages to be executed. The required signers of those messages define the number and order of elements in AuthInfo's signer_infos and Tx's signatures. Each required signer address is added to the list only the first time it occurs. By convention, the first required signer (usually from the first message) is referred to as the primary signer and pays the fee for the whole transaction. memo: type: string description: >- memo is any arbitrary note/comment to be added to the transaction. WARNING: in clients, any publicly exposed text should not be called memo, but should be called `note` instead (see https://github.com/cosmos/cosmos-sdk/issues/9122). timeout_height: type: string format: uint64 title: >- timeout is the block height after which this transaction will not be processed by the chain extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, the transaction will be rejected non_critical_extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, they will be ignored description: TxBody is the body of a transaction that all signers sign over. auth_info: title: >- auth_info is the authorization related content of the transaction, specifically signers, signer modes and fee type: object properties: signer_infos: type: array items: type: object properties: public_key: type: object properties: type_url: type: string value: type: string format: byte description: >- public_key is the public key of the signer. It is optional for accounts that already exist in state. If unset, the verifier can use the required \ signer address for this position and lookup the public key. mode_info: title: >- mode_info describes the signing mode of the signer and is a nested structure to support nested multisig pubkey's type: object properties: single: title: single represents a single signer type: object properties: mode: title: mode is the signing mode of the single signer type: string enum: - SIGN_MODE_UNSPECIFIED - SIGN_MODE_DIRECT - SIGN_MODE_TEXTUAL - SIGN_MODE_DIRECT_AUX - SIGN_MODE_LEGACY_AMINO_JSON - SIGN_MODE_EIP_191 default: SIGN_MODE_UNSPECIFIED description: >- SignMode represents a signing mode with its own security guarantees. This enum should be considered a registry of all known sign modes in the Cosmos ecosystem. Apps are not expected to support all known sign modes. Apps that would like to support custom sign modes are encouraged to open a small PR against this file to add a new case to this SignMode enum describing their sign mode so that different apps have a consistent version of this enum. - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be rejected. - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is verified with raw bytes from Tx. - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some human-readable textual representation on top of the binary representation from SIGN_MODE_DIRECT. It is currently not supported. - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses SignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not require signers signing over other signers' `signer_info`. It also allows for adding Tips in transactions. Since: cosmos-sdk 0.46 - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses Amino JSON and will be removed in the future. - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos SDK. Ref: https://eips.ethereum.org/EIPS/eip-191 Currently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant, but is not implemented on the SDK by default. To enable EIP-191, you need to pass a custom `TxConfig` that has an implementation of `SignModeHandler` for EIP-191. The SDK may decide to fully support EIP-191 in the future. Since: cosmos-sdk 0.45.2 multi: title: multi represents a nested multisig signer type: object properties: bitarray: title: bitarray specifies which keys within the multisig are signing type: object properties: extra_bits_stored: type: integer format: int64 elems: type: string format: byte description: >- CompactBitArray is an implementation of a space efficient bit array. This is used to ensure that the encoded data takes up a minimal amount of space after proto encoding. This is not thread safe, and is not intended for concurrent usage. mode_infos: type: array items: {} title: >- mode_infos is the corresponding modes of the signers of the multisig which could include nested multisig public keys description: ModeInfo describes the signing mode of a single or nested multisig signer. sequence: type: string format: uint64 description: >- sequence is the sequence of the account, which describes the number of committed transactions signed by a given address. It is used to prevent replay attacks. description: >- SignerInfo describes the public key and signing mode of a single top-level signer. description: >- signer_infos defines the signing modes for the required signers. The number and order of elements must match the required signers from TxBody's messages. The first element is the primary signer and the one which pays the fee. fee: description: >- Fee is the fee and gas limit for the transaction. The first signer is the primary signer and the one which pays the fee. The fee can be calculated based on the cost of evaluating the body and doing signature verification of the signers. This can be estimated via simulation. type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of coins to be paid as a fee gas_limit: type: string format: uint64 title: >- gas_limit is the maximum gas that can be used in transaction processing before an out of gas error occurs payer: type: string description: >- if unset, the first signer is responsible for paying the fees. If set, the specified account must pay the fees. the payer must be a tx signer (and thus have signed this field in AuthInfo). setting this field does *not* change the ordering of required signers for the transaction. granter: type: string title: >- if set, the fee payer (either the first signer or the value of the payer field) requests that a fee grant be used to pay fees instead of the fee payer's own balance. If an appropriate fee grant does not exist or the chain does not support fee grants, this will fail tip: description: >- Tip is the optional tip used for transactions fees paid in another denom. This field is ignored if the chain didn't enable tips, i.e. didn't add the `TipDecorator` in its posthandler. Since: cosmos-sdk 0.46 type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of the tip tipper: type: string title: tipper is the address of the account paying for the tip description: >- AuthInfo describes the fee and signer modes that are used to sign a transaction. signatures: type: array items: type: string format: byte description: >- signatures is a list of signatures that matches the length and order of AuthInfo's signer_infos to allow connecting signature meta information like public key and signing mode by position. description: Tx is the standard type used for broadcasting transactions. tx_response: type: object properties: height: type: string format: int64 title: The block height txhash: type: string description: The transaction hash. codespace: type: string title: Namespace for the Code code: type: integer format: int64 description: Response code. data: type: string description: Result bytes, if any. raw_log: type: string description: |- The output of the application's logger (raw string). May be non-deterministic. logs: type: array items: type: object properties: msg_index: type: integer format: int64 log: type: string events: type: array items: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string description: >- Attribute defines an attribute wrapper where the key and value are strings instead of raw bytes. description: >- StringEvent defines en Event object wrapper where all the attributes contain key/value pairs that are strings instead of raw bytes. description: >- Events contains a slice of Event objects that were emitted during some execution. description: ABCIMessageLog defines a structure containing an indexed tx ABCI message log. description: The output of the application's logger (typed). May be non-deterministic. info: type: string description: Additional information. May be non-deterministic. gas_wanted: type: string format: int64 description: Amount of gas requested for transaction. gas_used: type: string format: int64 description: Amount of gas consumed by transaction. tx: type: object properties: type_url: type: string value: type: string format: byte description: The request transaction bytes. timestamp: type: string description: >- Time of the previous block. For heights > 1, it's the weighted median of the timestamps of the valid votes in the block.LastCommit. For height == 1, it's genesis time. events: type: array items: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string index: type: boolean description: EventAttribute is a single key-value pair, associated with an event. description: >- Event allows application developers to attach additional information to ResponseBeginBlock, ResponseEndBlock, ResponseCheckTx and ResponseDeliverTx. Later, transactions may be queried using these events. description: >- Events defines all the events emitted by processing a transaction. Note, these events include those emitted by processing all the messages and those emitted from the ante. Whereas Logs contains the events, with additional metadata, emitted only by processing the messages. Since: cosmos-sdk 0.42.11, 0.44.5, 0.45 description: >- TxResponse defines a structure containing relevant tx data and metadata. The tags are stringified and the log is JSON decoded. description: GetTxResponse is the response type for the Service.GetTx method. cosmos.tx.v1beta1.GetTxsEventResponse: type: object properties: txs: type: array items: type: object properties: body: title: body is the processable content of the transaction type: object properties: messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- messages is a list of messages to be executed. The required signers of those messages define the number and order of elements in AuthInfo's signer_infos and Tx's signatures. Each required signer address is added to the list only the first time it occurs. By convention, the first required signer (usually from the first message) is referred to as the primary signer and pays the fee for the whole transaction. memo: type: string description: >- memo is any arbitrary note/comment to be added to the transaction. WARNING: in clients, any publicly exposed text should not be called memo, but should be called `note` instead (see https://github.com/cosmos/cosmos-sdk/issues/9122). timeout_height: type: string format: uint64 title: >- timeout is the block height after which this transaction will not be processed by the chain extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, the transaction will be rejected non_critical_extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, they will be ignored description: TxBody is the body of a transaction that all signers sign over. auth_info: title: >- auth_info is the authorization related content of the transaction, specifically signers, signer modes and fee type: object properties: signer_infos: type: array items: type: object properties: public_key: type: object properties: type_url: type: string value: type: string format: byte description: >- public_key is the public key of the signer. It is optional for accounts that already exist in state. If unset, the verifier can use the required \ signer address for this position and lookup the public key. mode_info: title: >- mode_info describes the signing mode of the signer and is a nested structure to support nested multisig pubkey's type: object properties: single: title: single represents a single signer type: object properties: mode: title: mode is the signing mode of the single signer type: string enum: - SIGN_MODE_UNSPECIFIED - SIGN_MODE_DIRECT - SIGN_MODE_TEXTUAL - SIGN_MODE_DIRECT_AUX - SIGN_MODE_LEGACY_AMINO_JSON - SIGN_MODE_EIP_191 default: SIGN_MODE_UNSPECIFIED description: >- SignMode represents a signing mode with its own security guarantees. This enum should be considered a registry of all known sign modes in the Cosmos ecosystem. Apps are not expected to support all known sign modes. Apps that would like to support custom sign modes are encouraged to open a small PR against this file to add a new case to this SignMode enum describing their sign mode so that different apps have a consistent version of this enum. - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be rejected. - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is verified with raw bytes from Tx. - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some human-readable textual representation on top of the binary representation from SIGN_MODE_DIRECT. It is currently not supported. - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses SignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not require signers signing over other signers' `signer_info`. It also allows for adding Tips in transactions. Since: cosmos-sdk 0.46 - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses Amino JSON and will be removed in the future. - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos SDK. Ref: https://eips.ethereum.org/EIPS/eip-191 Currently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant, but is not implemented on the SDK by default. To enable EIP-191, you need to pass a custom `TxConfig` that has an implementation of `SignModeHandler` for EIP-191. The SDK may decide to fully support EIP-191 in the future. Since: cosmos-sdk 0.45.2 multi: title: multi represents a nested multisig signer type: object properties: bitarray: title: bitarray specifies which keys within the multisig are signing type: object properties: extra_bits_stored: type: integer format: int64 elems: type: string format: byte description: >- CompactBitArray is an implementation of a space efficient bit array. This is used to ensure that the encoded data takes up a minimal amount of space after proto encoding. This is not thread safe, and is not intended for concurrent usage. mode_infos: type: array items: {} title: >- mode_infos is the corresponding modes of the signers of the multisig which could include nested multisig public keys description: ModeInfo describes the signing mode of a single or nested multisig signer. sequence: type: string format: uint64 description: >- sequence is the sequence of the account, which describes the number of committed transactions signed by a given address. It is used to prevent replay attacks. description: >- SignerInfo describes the public key and signing mode of a single top-level signer. description: >- signer_infos defines the signing modes for the required signers. The number and order of elements must match the required signers from TxBody's messages. The first element is the primary signer and the one which pays the fee. fee: description: >- Fee is the fee and gas limit for the transaction. The first signer is the primary signer and the one which pays the fee. The fee can be calculated based on the cost of evaluating the body and doing signature verification of the signers. This can be estimated via simulation. type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of coins to be paid as a fee gas_limit: type: string format: uint64 title: >- gas_limit is the maximum gas that can be used in transaction processing before an out of gas error occurs payer: type: string description: >- if unset, the first signer is responsible for paying the fees. If set, the specified account must pay the fees. the payer must be a tx signer (and thus have signed this field in AuthInfo). setting this field does *not* change the ordering of required signers for the transaction. granter: type: string title: >- if set, the fee payer (either the first signer or the value of the payer field) requests that a fee grant be used to pay fees instead of the fee payer's own balance. If an appropriate fee grant does not exist or the chain does not support fee grants, this will fail tip: description: >- Tip is the optional tip used for transactions fees paid in another denom. This field is ignored if the chain didn't enable tips, i.e. didn't add the `TipDecorator` in its posthandler. Since: cosmos-sdk 0.46 type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of the tip tipper: type: string title: tipper is the address of the account paying for the tip description: >- AuthInfo describes the fee and signer modes that are used to sign a transaction. signatures: type: array items: type: string format: byte description: >- signatures is a list of signatures that matches the length and order of AuthInfo's signer_infos to allow connecting signature meta information like public key and signing mode by position. description: Tx is the standard type used for broadcasting transactions. description: txs is the list of queried transactions. tx_responses: type: array items: type: object properties: height: type: string format: int64 title: The block height txhash: type: string description: The transaction hash. codespace: type: string title: Namespace for the Code code: type: integer format: int64 description: Response code. data: type: string description: Result bytes, if any. raw_log: type: string description: |- The output of the application's logger (raw string). May be non-deterministic. logs: type: array items: type: object properties: msg_index: type: integer format: int64 log: type: string events: type: array items: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string description: >- Attribute defines an attribute wrapper where the key and value are strings instead of raw bytes. description: >- StringEvent defines en Event object wrapper where all the attributes contain key/value pairs that are strings instead of raw bytes. description: >- Events contains a slice of Event objects that were emitted during some execution. description: ABCIMessageLog defines a structure containing an indexed tx ABCI message log. description: The output of the application's logger (typed). May be non-deterministic. info: type: string description: Additional information. May be non-deterministic. gas_wanted: type: string format: int64 description: Amount of gas requested for transaction. gas_used: type: string format: int64 description: Amount of gas consumed by transaction. tx: type: object properties: type_url: type: string value: type: string format: byte description: The request transaction bytes. timestamp: type: string description: >- Time of the previous block. For heights > 1, it's the weighted median of the timestamps of the valid votes in the block.LastCommit. For height == 1, it's genesis time. events: type: array items: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string index: type: boolean description: EventAttribute is a single key-value pair, associated with an event. description: >- Event allows application developers to attach additional information to ResponseBeginBlock, ResponseEndBlock, ResponseCheckTx and ResponseDeliverTx. Later, transactions may be queried using these events. description: >- Events defines all the events emitted by processing a transaction. Note, these events include those emitted by processing all the messages and those emitted from the ante. Whereas Logs contains the events, with additional metadata, emitted only by processing the messages. Since: cosmos-sdk 0.42.11, 0.44.5, 0.45 description: >- TxResponse defines a structure containing relevant tx data and metadata. The tags are stringified and the log is JSON decoded. description: tx_responses is the list of queried TxResponses. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } total: type: string format: uint64 title: total is total number of results available description: |- GetTxsEventResponse is the response type for the Service.TxsByEvents RPC method. cosmos.tx.v1beta1.ModeInfo: type: object properties: single: title: single represents a single signer type: object properties: mode: title: mode is the signing mode of the single signer type: string enum: - SIGN_MODE_UNSPECIFIED - SIGN_MODE_DIRECT - SIGN_MODE_TEXTUAL - SIGN_MODE_DIRECT_AUX - SIGN_MODE_LEGACY_AMINO_JSON - SIGN_MODE_EIP_191 default: SIGN_MODE_UNSPECIFIED description: >- SignMode represents a signing mode with its own security guarantees. This enum should be considered a registry of all known sign modes in the Cosmos ecosystem. Apps are not expected to support all known sign modes. Apps that would like to support custom sign modes are encouraged to open a small PR against this file to add a new case to this SignMode enum describing their sign mode so that different apps have a consistent version of this enum. - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be rejected. - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is verified with raw bytes from Tx. - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some human-readable textual representation on top of the binary representation from SIGN_MODE_DIRECT. It is currently not supported. - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses SignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not require signers signing over other signers' `signer_info`. It also allows for adding Tips in transactions. Since: cosmos-sdk 0.46 - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses Amino JSON and will be removed in the future. - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos SDK. Ref: https://eips.ethereum.org/EIPS/eip-191 Currently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant, but is not implemented on the SDK by default. To enable EIP-191, you need to pass a custom `TxConfig` that has an implementation of `SignModeHandler` for EIP-191. The SDK may decide to fully support EIP-191 in the future. Since: cosmos-sdk 0.45.2 multi: title: multi represents a nested multisig signer type: object properties: bitarray: title: bitarray specifies which keys within the multisig are signing type: object properties: extra_bits_stored: type: integer format: int64 elems: type: string format: byte description: >- CompactBitArray is an implementation of a space efficient bit array. This is used to ensure that the encoded data takes up a minimal amount of space after proto encoding. This is not thread safe, and is not intended for concurrent usage. mode_infos: type: array items: {} title: >- mode_infos is the corresponding modes of the signers of the multisig which could include nested multisig public keys description: ModeInfo describes the signing mode of a single or nested multisig signer. cosmos.tx.v1beta1.ModeInfo.Multi: type: object properties: bitarray: title: bitarray specifies which keys within the multisig are signing type: object properties: extra_bits_stored: type: integer format: int64 elems: type: string format: byte description: >- CompactBitArray is an implementation of a space efficient bit array. This is used to ensure that the encoded data takes up a minimal amount of space after proto encoding. This is not thread safe, and is not intended for concurrent usage. mode_infos: type: array items: {} title: |- mode_infos is the corresponding modes of the signers of the multisig which could include nested multisig public keys title: Multi is the mode info for a multisig public key cosmos.tx.v1beta1.ModeInfo.Single: type: object properties: mode: title: mode is the signing mode of the single signer type: string enum: - SIGN_MODE_UNSPECIFIED - SIGN_MODE_DIRECT - SIGN_MODE_TEXTUAL - SIGN_MODE_DIRECT_AUX - SIGN_MODE_LEGACY_AMINO_JSON - SIGN_MODE_EIP_191 default: SIGN_MODE_UNSPECIFIED description: >- SignMode represents a signing mode with its own security guarantees. This enum should be considered a registry of all known sign modes in the Cosmos ecosystem. Apps are not expected to support all known sign modes. Apps that would like to support custom sign modes are encouraged to open a small PR against this file to add a new case to this SignMode enum describing their sign mode so that different apps have a consistent version of this enum. - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be rejected. - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is verified with raw bytes from Tx. - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some human-readable textual representation on top of the binary representation from SIGN_MODE_DIRECT. It is currently not supported. - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses SignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not require signers signing over other signers' `signer_info`. It also allows for adding Tips in transactions. Since: cosmos-sdk 0.46 - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses Amino JSON and will be removed in the future. - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos SDK. Ref: https://eips.ethereum.org/EIPS/eip-191 Currently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant, but is not implemented on the SDK by default. To enable EIP-191, you need to pass a custom `TxConfig` that has an implementation of `SignModeHandler` for EIP-191. The SDK may decide to fully support EIP-191 in the future. Since: cosmos-sdk 0.45.2 title: >- Single is the mode info for a single signer. It is structured as a message to allow for additional fields such as locale for SIGN_MODE_TEXTUAL in the future cosmos.tx.v1beta1.OrderBy: type: string enum: - ORDER_BY_UNSPECIFIED - ORDER_BY_ASC - ORDER_BY_DESC default: ORDER_BY_UNSPECIFIED description: >- - ORDER_BY_UNSPECIFIED: ORDER_BY_UNSPECIFIED specifies an unknown sorting order. OrderBy defaults to ASC in this case. - ORDER_BY_ASC: ORDER_BY_ASC defines ascending order - ORDER_BY_DESC: ORDER_BY_DESC defines descending order title: OrderBy defines the sorting order cosmos.tx.v1beta1.SignerInfo: type: object properties: public_key: type: object properties: type_url: type: string value: type: string format: byte description: >- public_key is the public key of the signer. It is optional for accounts that already exist in state. If unset, the verifier can use the required \ signer address for this position and lookup the public key. mode_info: title: |- mode_info describes the signing mode of the signer and is a nested structure to support nested multisig pubkey's type: object properties: single: title: single represents a single signer type: object properties: mode: title: mode is the signing mode of the single signer type: string enum: - SIGN_MODE_UNSPECIFIED - SIGN_MODE_DIRECT - SIGN_MODE_TEXTUAL - SIGN_MODE_DIRECT_AUX - SIGN_MODE_LEGACY_AMINO_JSON - SIGN_MODE_EIP_191 default: SIGN_MODE_UNSPECIFIED description: >- SignMode represents a signing mode with its own security guarantees. This enum should be considered a registry of all known sign modes in the Cosmos ecosystem. Apps are not expected to support all known sign modes. Apps that would like to support custom sign modes are encouraged to open a small PR against this file to add a new case to this SignMode enum describing their sign mode so that different apps have a consistent version of this enum. - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be rejected. - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is verified with raw bytes from Tx. - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some human-readable textual representation on top of the binary representation from SIGN_MODE_DIRECT. It is currently not supported. - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses SignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not require signers signing over other signers' `signer_info`. It also allows for adding Tips in transactions. Since: cosmos-sdk 0.46 - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses Amino JSON and will be removed in the future. - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos SDK. Ref: https://eips.ethereum.org/EIPS/eip-191 Currently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant, but is not implemented on the SDK by default. To enable EIP-191, you need to pass a custom `TxConfig` that has an implementation of `SignModeHandler` for EIP-191. The SDK may decide to fully support EIP-191 in the future. Since: cosmos-sdk 0.45.2 multi: title: multi represents a nested multisig signer type: object properties: bitarray: title: bitarray specifies which keys within the multisig are signing type: object properties: extra_bits_stored: type: integer format: int64 elems: type: string format: byte description: >- CompactBitArray is an implementation of a space efficient bit array. This is used to ensure that the encoded data takes up a minimal amount of space after proto encoding. This is not thread safe, and is not intended for concurrent usage. mode_infos: type: array items: {} title: >- mode_infos is the corresponding modes of the signers of the multisig which could include nested multisig public keys description: ModeInfo describes the signing mode of a single or nested multisig signer. sequence: type: string format: uint64 description: >- sequence is the sequence of the account, which describes the number of committed transactions signed by a given address. It is used to prevent replay attacks. description: >- SignerInfo describes the public key and signing mode of a single top-level signer. cosmos.tx.v1beta1.SimulateRequest: type: object properties: tx: description: |- tx is the transaction to simulate. Deprecated. Send raw tx bytes instead. type: object properties: body: title: body is the processable content of the transaction type: object properties: messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- messages is a list of messages to be executed. The required signers of those messages define the number and order of elements in AuthInfo's signer_infos and Tx's signatures. Each required signer address is added to the list only the first time it occurs. By convention, the first required signer (usually from the first message) is referred to as the primary signer and pays the fee for the whole transaction. memo: type: string description: >- memo is any arbitrary note/comment to be added to the transaction. WARNING: in clients, any publicly exposed text should not be called memo, but should be called `note` instead (see https://github.com/cosmos/cosmos-sdk/issues/9122). timeout_height: type: string format: uint64 title: >- timeout is the block height after which this transaction will not be processed by the chain extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, the transaction will be rejected non_critical_extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, they will be ignored description: TxBody is the body of a transaction that all signers sign over. auth_info: title: >- auth_info is the authorization related content of the transaction, specifically signers, signer modes and fee type: object properties: signer_infos: type: array items: type: object properties: public_key: type: object properties: type_url: type: string value: type: string format: byte description: >- public_key is the public key of the signer. It is optional for accounts that already exist in state. If unset, the verifier can use the required \ signer address for this position and lookup the public key. mode_info: title: >- mode_info describes the signing mode of the signer and is a nested structure to support nested multisig pubkey's type: object properties: single: title: single represents a single signer type: object properties: mode: title: mode is the signing mode of the single signer type: string enum: - SIGN_MODE_UNSPECIFIED - SIGN_MODE_DIRECT - SIGN_MODE_TEXTUAL - SIGN_MODE_DIRECT_AUX - SIGN_MODE_LEGACY_AMINO_JSON - SIGN_MODE_EIP_191 default: SIGN_MODE_UNSPECIFIED description: >- SignMode represents a signing mode with its own security guarantees. This enum should be considered a registry of all known sign modes in the Cosmos ecosystem. Apps are not expected to support all known sign modes. Apps that would like to support custom sign modes are encouraged to open a small PR against this file to add a new case to this SignMode enum describing their sign mode so that different apps have a consistent version of this enum. - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be rejected. - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is verified with raw bytes from Tx. - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some human-readable textual representation on top of the binary representation from SIGN_MODE_DIRECT. It is currently not supported. - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses SignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not require signers signing over other signers' `signer_info`. It also allows for adding Tips in transactions. Since: cosmos-sdk 0.46 - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses Amino JSON and will be removed in the future. - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos SDK. Ref: https://eips.ethereum.org/EIPS/eip-191 Currently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant, but is not implemented on the SDK by default. To enable EIP-191, you need to pass a custom `TxConfig` that has an implementation of `SignModeHandler` for EIP-191. The SDK may decide to fully support EIP-191 in the future. Since: cosmos-sdk 0.45.2 multi: title: multi represents a nested multisig signer type: object properties: bitarray: title: bitarray specifies which keys within the multisig are signing type: object properties: extra_bits_stored: type: integer format: int64 elems: type: string format: byte description: >- CompactBitArray is an implementation of a space efficient bit array. This is used to ensure that the encoded data takes up a minimal amount of space after proto encoding. This is not thread safe, and is not intended for concurrent usage. mode_infos: type: array items: {} title: >- mode_infos is the corresponding modes of the signers of the multisig which could include nested multisig public keys description: ModeInfo describes the signing mode of a single or nested multisig signer. sequence: type: string format: uint64 description: >- sequence is the sequence of the account, which describes the number of committed transactions signed by a given address. It is used to prevent replay attacks. description: >- SignerInfo describes the public key and signing mode of a single top-level signer. description: >- signer_infos defines the signing modes for the required signers. The number and order of elements must match the required signers from TxBody's messages. The first element is the primary signer and the one which pays the fee. fee: description: >- Fee is the fee and gas limit for the transaction. The first signer is the primary signer and the one which pays the fee. The fee can be calculated based on the cost of evaluating the body and doing signature verification of the signers. This can be estimated via simulation. type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of coins to be paid as a fee gas_limit: type: string format: uint64 title: >- gas_limit is the maximum gas that can be used in transaction processing before an out of gas error occurs payer: type: string description: >- if unset, the first signer is responsible for paying the fees. If set, the specified account must pay the fees. the payer must be a tx signer (and thus have signed this field in AuthInfo). setting this field does *not* change the ordering of required signers for the transaction. granter: type: string title: >- if set, the fee payer (either the first signer or the value of the payer field) requests that a fee grant be used to pay fees instead of the fee payer's own balance. If an appropriate fee grant does not exist or the chain does not support fee grants, this will fail tip: description: >- Tip is the optional tip used for transactions fees paid in another denom. This field is ignored if the chain didn't enable tips, i.e. didn't add the `TipDecorator` in its posthandler. Since: cosmos-sdk 0.46 type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of the tip tipper: type: string title: tipper is the address of the account paying for the tip description: >- AuthInfo describes the fee and signer modes that are used to sign a transaction. signatures: type: array items: type: string format: byte description: >- signatures is a list of signatures that matches the length and order of AuthInfo's signer_infos to allow connecting signature meta information like public key and signing mode by position. tx_bytes: type: string format: byte description: |- tx_bytes is the raw transaction. Since: cosmos-sdk 0.43 description: |- SimulateRequest is the request type for the Service.Simulate RPC method. cosmos.tx.v1beta1.SimulateResponse: type: object properties: gas_info: description: gas_info is the information about gas used in the simulation. type: object properties: gas_wanted: type: string format: uint64 description: GasWanted is the maximum units of work we allow this tx to perform. gas_used: type: string format: uint64 description: GasUsed is the amount of gas actually consumed. result: description: result is the result of the simulation. type: object properties: data: type: string format: byte description: >- Data is any data returned from message or handler execution. It MUST be length prefixed in order to separate data from multiple message executions. Deprecated. This field is still populated, but prefer msg_response instead because it also contains the Msg response typeURL. log: type: string description: Log contains the log information from message or handler execution. events: type: array items: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string index: type: boolean description: EventAttribute is a single key-value pair, associated with an event. description: >- Event allows application developers to attach additional information to ResponseBeginBlock, ResponseEndBlock, ResponseCheckTx and ResponseDeliverTx. Later, transactions may be queried using these events. description: >- Events contains a slice of Event objects that were emitted during message or handler execution. msg_responses: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- msg_responses contains the Msg handler responses type packed in Anys. Since: cosmos-sdk 0.46 description: |- SimulateResponse is the response type for the Service.SimulateRPC method. cosmos.tx.v1beta1.Tip: type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of the tip tipper: type: string title: tipper is the address of the account paying for the tip description: |- Tip is the tip used for meta-transactions. Since: cosmos-sdk 0.46 cosmos.tx.v1beta1.Tx: type: object properties: body: title: body is the processable content of the transaction type: object properties: messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- messages is a list of messages to be executed. The required signers of those messages define the number and order of elements in AuthInfo's signer_infos and Tx's signatures. Each required signer address is added to the list only the first time it occurs. By convention, the first required signer (usually from the first message) is referred to as the primary signer and pays the fee for the whole transaction. memo: type: string description: >- memo is any arbitrary note/comment to be added to the transaction. WARNING: in clients, any publicly exposed text should not be called memo, but should be called `note` instead (see https://github.com/cosmos/cosmos-sdk/issues/9122). timeout_height: type: string format: uint64 title: >- timeout is the block height after which this transaction will not be processed by the chain extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, the transaction will be rejected non_critical_extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, they will be ignored description: TxBody is the body of a transaction that all signers sign over. auth_info: title: |- auth_info is the authorization related content of the transaction, specifically signers, signer modes and fee type: object properties: signer_infos: type: array items: type: object properties: public_key: type: object properties: type_url: type: string value: type: string format: byte description: >- public_key is the public key of the signer. It is optional for accounts that already exist in state. If unset, the verifier can use the required \ signer address for this position and lookup the public key. mode_info: title: >- mode_info describes the signing mode of the signer and is a nested structure to support nested multisig pubkey's type: object properties: single: title: single represents a single signer type: object properties: mode: title: mode is the signing mode of the single signer type: string enum: - SIGN_MODE_UNSPECIFIED - SIGN_MODE_DIRECT - SIGN_MODE_TEXTUAL - SIGN_MODE_DIRECT_AUX - SIGN_MODE_LEGACY_AMINO_JSON - SIGN_MODE_EIP_191 default: SIGN_MODE_UNSPECIFIED description: >- SignMode represents a signing mode with its own security guarantees. This enum should be considered a registry of all known sign modes in the Cosmos ecosystem. Apps are not expected to support all known sign modes. Apps that would like to support custom sign modes are encouraged to open a small PR against this file to add a new case to this SignMode enum describing their sign mode so that different apps have a consistent version of this enum. - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be rejected. - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is verified with raw bytes from Tx. - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some human-readable textual representation on top of the binary representation from SIGN_MODE_DIRECT. It is currently not supported. - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses SignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not require signers signing over other signers' `signer_info`. It also allows for adding Tips in transactions. Since: cosmos-sdk 0.46 - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses Amino JSON and will be removed in the future. - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos SDK. Ref: https://eips.ethereum.org/EIPS/eip-191 Currently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant, but is not implemented on the SDK by default. To enable EIP-191, you need to pass a custom `TxConfig` that has an implementation of `SignModeHandler` for EIP-191. The SDK may decide to fully support EIP-191 in the future. Since: cosmos-sdk 0.45.2 multi: title: multi represents a nested multisig signer type: object properties: bitarray: title: bitarray specifies which keys within the multisig are signing type: object properties: extra_bits_stored: type: integer format: int64 elems: type: string format: byte description: >- CompactBitArray is an implementation of a space efficient bit array. This is used to ensure that the encoded data takes up a minimal amount of space after proto encoding. This is not thread safe, and is not intended for concurrent usage. mode_infos: type: array items: {} title: >- mode_infos is the corresponding modes of the signers of the multisig which could include nested multisig public keys description: ModeInfo describes the signing mode of a single or nested multisig signer. sequence: type: string format: uint64 description: >- sequence is the sequence of the account, which describes the number of committed transactions signed by a given address. It is used to prevent replay attacks. description: >- SignerInfo describes the public key and signing mode of a single top-level signer. description: >- signer_infos defines the signing modes for the required signers. The number and order of elements must match the required signers from TxBody's messages. The first element is the primary signer and the one which pays the fee. fee: description: >- Fee is the fee and gas limit for the transaction. The first signer is the primary signer and the one which pays the fee. The fee can be calculated based on the cost of evaluating the body and doing signature verification of the signers. This can be estimated via simulation. type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of coins to be paid as a fee gas_limit: type: string format: uint64 title: >- gas_limit is the maximum gas that can be used in transaction processing before an out of gas error occurs payer: type: string description: >- if unset, the first signer is responsible for paying the fees. If set, the specified account must pay the fees. the payer must be a tx signer (and thus have signed this field in AuthInfo). setting this field does *not* change the ordering of required signers for the transaction. granter: type: string title: >- if set, the fee payer (either the first signer or the value of the payer field) requests that a fee grant be used to pay fees instead of the fee payer's own balance. If an appropriate fee grant does not exist or the chain does not support fee grants, this will fail tip: description: >- Tip is the optional tip used for transactions fees paid in another denom. This field is ignored if the chain didn't enable tips, i.e. didn't add the `TipDecorator` in its posthandler. Since: cosmos-sdk 0.46 type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of the tip tipper: type: string title: tipper is the address of the account paying for the tip description: |- AuthInfo describes the fee and signer modes that are used to sign a transaction. signatures: type: array items: type: string format: byte description: >- signatures is a list of signatures that matches the length and order of AuthInfo's signer_infos to allow connecting signature meta information like public key and signing mode by position. description: Tx is the standard type used for broadcasting transactions. cosmos.tx.v1beta1.TxBody: type: object properties: messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- messages is a list of messages to be executed. The required signers of those messages define the number and order of elements in AuthInfo's signer_infos and Tx's signatures. Each required signer address is added to the list only the first time it occurs. By convention, the first required signer (usually from the first message) is referred to as the primary signer and pays the fee for the whole transaction. memo: type: string description: >- memo is any arbitrary note/comment to be added to the transaction. WARNING: in clients, any publicly exposed text should not be called memo, but should be called `note` instead (see https://github.com/cosmos/cosmos-sdk/issues/9122). timeout_height: type: string format: uint64 title: |- timeout is the block height after which this transaction will not be processed by the chain extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, the transaction will be rejected non_critical_extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, they will be ignored description: TxBody is the body of a transaction that all signers sign over. cosmos.tx.v1beta1.TxDecodeAminoRequest: type: object properties: amino_binary: type: string format: byte description: |- TxDecodeAminoRequest is the request type for the Service.TxDecodeAmino RPC method. Since: cosmos-sdk 0.47 cosmos.tx.v1beta1.TxDecodeAminoResponse: type: object properties: amino_json: type: string description: |- TxDecodeAminoResponse is the response type for the Service.TxDecodeAmino RPC method. Since: cosmos-sdk 0.47 cosmos.tx.v1beta1.TxDecodeRequest: type: object properties: tx_bytes: type: string format: byte description: tx_bytes is the raw transaction. description: |- TxDecodeRequest is the request type for the Service.TxDecode RPC method. Since: cosmos-sdk 0.47 cosmos.tx.v1beta1.TxDecodeResponse: type: object properties: tx: description: tx is the decoded transaction. type: object properties: body: title: body is the processable content of the transaction type: object properties: messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- messages is a list of messages to be executed. The required signers of those messages define the number and order of elements in AuthInfo's signer_infos and Tx's signatures. Each required signer address is added to the list only the first time it occurs. By convention, the first required signer (usually from the first message) is referred to as the primary signer and pays the fee for the whole transaction. memo: type: string description: >- memo is any arbitrary note/comment to be added to the transaction. WARNING: in clients, any publicly exposed text should not be called memo, but should be called `note` instead (see https://github.com/cosmos/cosmos-sdk/issues/9122). timeout_height: type: string format: uint64 title: >- timeout is the block height after which this transaction will not be processed by the chain extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, the transaction will be rejected non_critical_extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, they will be ignored description: TxBody is the body of a transaction that all signers sign over. auth_info: title: >- auth_info is the authorization related content of the transaction, specifically signers, signer modes and fee type: object properties: signer_infos: type: array items: type: object properties: public_key: type: object properties: type_url: type: string value: type: string format: byte description: >- public_key is the public key of the signer. It is optional for accounts that already exist in state. If unset, the verifier can use the required \ signer address for this position and lookup the public key. mode_info: title: >- mode_info describes the signing mode of the signer and is a nested structure to support nested multisig pubkey's type: object properties: single: title: single represents a single signer type: object properties: mode: title: mode is the signing mode of the single signer type: string enum: - SIGN_MODE_UNSPECIFIED - SIGN_MODE_DIRECT - SIGN_MODE_TEXTUAL - SIGN_MODE_DIRECT_AUX - SIGN_MODE_LEGACY_AMINO_JSON - SIGN_MODE_EIP_191 default: SIGN_MODE_UNSPECIFIED description: >- SignMode represents a signing mode with its own security guarantees. This enum should be considered a registry of all known sign modes in the Cosmos ecosystem. Apps are not expected to support all known sign modes. Apps that would like to support custom sign modes are encouraged to open a small PR against this file to add a new case to this SignMode enum describing their sign mode so that different apps have a consistent version of this enum. - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be rejected. - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is verified with raw bytes from Tx. - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some human-readable textual representation on top of the binary representation from SIGN_MODE_DIRECT. It is currently not supported. - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses SignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not require signers signing over other signers' `signer_info`. It also allows for adding Tips in transactions. Since: cosmos-sdk 0.46 - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses Amino JSON and will be removed in the future. - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos SDK. Ref: https://eips.ethereum.org/EIPS/eip-191 Currently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant, but is not implemented on the SDK by default. To enable EIP-191, you need to pass a custom `TxConfig` that has an implementation of `SignModeHandler` for EIP-191. The SDK may decide to fully support EIP-191 in the future. Since: cosmos-sdk 0.45.2 multi: title: multi represents a nested multisig signer type: object properties: bitarray: title: bitarray specifies which keys within the multisig are signing type: object properties: extra_bits_stored: type: integer format: int64 elems: type: string format: byte description: >- CompactBitArray is an implementation of a space efficient bit array. This is used to ensure that the encoded data takes up a minimal amount of space after proto encoding. This is not thread safe, and is not intended for concurrent usage. mode_infos: type: array items: {} title: >- mode_infos is the corresponding modes of the signers of the multisig which could include nested multisig public keys description: ModeInfo describes the signing mode of a single or nested multisig signer. sequence: type: string format: uint64 description: >- sequence is the sequence of the account, which describes the number of committed transactions signed by a given address. It is used to prevent replay attacks. description: >- SignerInfo describes the public key and signing mode of a single top-level signer. description: >- signer_infos defines the signing modes for the required signers. The number and order of elements must match the required signers from TxBody's messages. The first element is the primary signer and the one which pays the fee. fee: description: >- Fee is the fee and gas limit for the transaction. The first signer is the primary signer and the one which pays the fee. The fee can be calculated based on the cost of evaluating the body and doing signature verification of the signers. This can be estimated via simulation. type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of coins to be paid as a fee gas_limit: type: string format: uint64 title: >- gas_limit is the maximum gas that can be used in transaction processing before an out of gas error occurs payer: type: string description: >- if unset, the first signer is responsible for paying the fees. If set, the specified account must pay the fees. the payer must be a tx signer (and thus have signed this field in AuthInfo). setting this field does *not* change the ordering of required signers for the transaction. granter: type: string title: >- if set, the fee payer (either the first signer or the value of the payer field) requests that a fee grant be used to pay fees instead of the fee payer's own balance. If an appropriate fee grant does not exist or the chain does not support fee grants, this will fail tip: description: >- Tip is the optional tip used for transactions fees paid in another denom. This field is ignored if the chain didn't enable tips, i.e. didn't add the `TipDecorator` in its posthandler. Since: cosmos-sdk 0.46 type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of the tip tipper: type: string title: tipper is the address of the account paying for the tip description: >- AuthInfo describes the fee and signer modes that are used to sign a transaction. signatures: type: array items: type: string format: byte description: >- signatures is a list of signatures that matches the length and order of AuthInfo's signer_infos to allow connecting signature meta information like public key and signing mode by position. description: |- TxDecodeResponse is the response type for the Service.TxDecode method. Since: cosmos-sdk 0.47 cosmos.tx.v1beta1.TxEncodeAminoRequest: type: object properties: amino_json: type: string description: |- TxEncodeAminoRequest is the request type for the Service.TxEncodeAmino RPC method. Since: cosmos-sdk 0.47 cosmos.tx.v1beta1.TxEncodeAminoResponse: type: object properties: amino_binary: type: string format: byte description: |- TxEncodeAminoResponse is the response type for the Service.TxEncodeAmino RPC method. Since: cosmos-sdk 0.47 cosmos.tx.v1beta1.TxEncodeRequest: type: object properties: tx: description: tx is the transaction to encode. type: object properties: body: title: body is the processable content of the transaction type: object properties: messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- messages is a list of messages to be executed. The required signers of those messages define the number and order of elements in AuthInfo's signer_infos and Tx's signatures. Each required signer address is added to the list only the first time it occurs. By convention, the first required signer (usually from the first message) is referred to as the primary signer and pays the fee for the whole transaction. memo: type: string description: >- memo is any arbitrary note/comment to be added to the transaction. WARNING: in clients, any publicly exposed text should not be called memo, but should be called `note` instead (see https://github.com/cosmos/cosmos-sdk/issues/9122). timeout_height: type: string format: uint64 title: >- timeout is the block height after which this transaction will not be processed by the chain extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, the transaction will be rejected non_critical_extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, they will be ignored description: TxBody is the body of a transaction that all signers sign over. auth_info: title: >- auth_info is the authorization related content of the transaction, specifically signers, signer modes and fee type: object properties: signer_infos: type: array items: type: object properties: public_key: type: object properties: type_url: type: string value: type: string format: byte description: >- public_key is the public key of the signer. It is optional for accounts that already exist in state. If unset, the verifier can use the required \ signer address for this position and lookup the public key. mode_info: title: >- mode_info describes the signing mode of the signer and is a nested structure to support nested multisig pubkey's type: object properties: single: title: single represents a single signer type: object properties: mode: title: mode is the signing mode of the single signer type: string enum: - SIGN_MODE_UNSPECIFIED - SIGN_MODE_DIRECT - SIGN_MODE_TEXTUAL - SIGN_MODE_DIRECT_AUX - SIGN_MODE_LEGACY_AMINO_JSON - SIGN_MODE_EIP_191 default: SIGN_MODE_UNSPECIFIED description: >- SignMode represents a signing mode with its own security guarantees. This enum should be considered a registry of all known sign modes in the Cosmos ecosystem. Apps are not expected to support all known sign modes. Apps that would like to support custom sign modes are encouraged to open a small PR against this file to add a new case to this SignMode enum describing their sign mode so that different apps have a consistent version of this enum. - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be rejected. - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is verified with raw bytes from Tx. - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some human-readable textual representation on top of the binary representation from SIGN_MODE_DIRECT. It is currently not supported. - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses SignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not require signers signing over other signers' `signer_info`. It also allows for adding Tips in transactions. Since: cosmos-sdk 0.46 - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses Amino JSON and will be removed in the future. - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos SDK. Ref: https://eips.ethereum.org/EIPS/eip-191 Currently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant, but is not implemented on the SDK by default. To enable EIP-191, you need to pass a custom `TxConfig` that has an implementation of `SignModeHandler` for EIP-191. The SDK may decide to fully support EIP-191 in the future. Since: cosmos-sdk 0.45.2 multi: title: multi represents a nested multisig signer type: object properties: bitarray: title: bitarray specifies which keys within the multisig are signing type: object properties: extra_bits_stored: type: integer format: int64 elems: type: string format: byte description: >- CompactBitArray is an implementation of a space efficient bit array. This is used to ensure that the encoded data takes up a minimal amount of space after proto encoding. This is not thread safe, and is not intended for concurrent usage. mode_infos: type: array items: {} title: >- mode_infos is the corresponding modes of the signers of the multisig which could include nested multisig public keys description: ModeInfo describes the signing mode of a single or nested multisig signer. sequence: type: string format: uint64 description: >- sequence is the sequence of the account, which describes the number of committed transactions signed by a given address. It is used to prevent replay attacks. description: >- SignerInfo describes the public key and signing mode of a single top-level signer. description: >- signer_infos defines the signing modes for the required signers. The number and order of elements must match the required signers from TxBody's messages. The first element is the primary signer and the one which pays the fee. fee: description: >- Fee is the fee and gas limit for the transaction. The first signer is the primary signer and the one which pays the fee. The fee can be calculated based on the cost of evaluating the body and doing signature verification of the signers. This can be estimated via simulation. type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of coins to be paid as a fee gas_limit: type: string format: uint64 title: >- gas_limit is the maximum gas that can be used in transaction processing before an out of gas error occurs payer: type: string description: >- if unset, the first signer is responsible for paying the fees. If set, the specified account must pay the fees. the payer must be a tx signer (and thus have signed this field in AuthInfo). setting this field does *not* change the ordering of required signers for the transaction. granter: type: string title: >- if set, the fee payer (either the first signer or the value of the payer field) requests that a fee grant be used to pay fees instead of the fee payer's own balance. If an appropriate fee grant does not exist or the chain does not support fee grants, this will fail tip: description: >- Tip is the optional tip used for transactions fees paid in another denom. This field is ignored if the chain didn't enable tips, i.e. didn't add the `TipDecorator` in its posthandler. Since: cosmos-sdk 0.46 type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of the tip tipper: type: string title: tipper is the address of the account paying for the tip description: >- AuthInfo describes the fee and signer modes that are used to sign a transaction. signatures: type: array items: type: string format: byte description: >- signatures is a list of signatures that matches the length and order of AuthInfo's signer_infos to allow connecting signature meta information like public key and signing mode by position. description: |- TxEncodeRequest is the request type for the Service.TxEncode RPC method. Since: cosmos-sdk 0.47 cosmos.tx.v1beta1.TxEncodeResponse: type: object properties: tx_bytes: type: string format: byte description: tx_bytes is the encoded transaction bytes. description: |- TxEncodeResponse is the response type for the Service.TxEncode method. Since: cosmos-sdk 0.47 tendermint.abci.Event: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string index: type: boolean description: EventAttribute is a single key-value pair, associated with an event. description: >- Event allows application developers to attach additional information to ResponseBeginBlock, ResponseEndBlock, ResponseCheckTx and ResponseDeliverTx. Later, transactions may be queried using these events. tendermint.abci.EventAttribute: type: object properties: key: type: string value: type: string index: type: boolean description: EventAttribute is a single key-value pair, associated with an event. tendermint.crypto.PublicKey: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators tendermint.types.Block: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. data: type: object properties: txs: type: array items: type: string format: byte description: >- Txs that will be applied by state @ block.Height+1. NOTE: not all txs here are valid. We're just agreeing on the order first. This means that block.AppHash does not include these txs. title: Data contains the set of transactions included in the block evidence: type: object properties: evidence: type: array items: type: object properties: duplicate_vote_evidence: type: object properties: vote_a: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. vote_b: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. total_voting_power: type: string format: int64 validator_power: type: string format: int64 timestamp: type: string format: date-time description: DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes. light_client_attack_evidence: type: object properties: conflicting_block: type: object properties: signed_header: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: Commit contains the evidence that a block was committed by a set of validators. validator_set: type: object properties: validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 proposer: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 common_height: type: string format: int64 byzantine_validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 timestamp: type: string format: date-time description: LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client. last_commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: Commit contains the evidence that a block was committed by a set of validators. tendermint.types.BlockIDFlag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for tendermint.types.Commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: Commit contains the evidence that a block was committed by a set of validators. tendermint.types.CommitSig: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. tendermint.types.Data: type: object properties: txs: type: array items: type: string format: byte description: >- Txs that will be applied by state @ block.Height+1. NOTE: not all txs here are valid. We're just agreeing on the order first. This means that block.AppHash does not include these txs. title: Data contains the set of transactions included in the block tendermint.types.DuplicateVoteEvidence: type: object properties: vote_a: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: |- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. vote_b: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: |- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. total_voting_power: type: string format: int64 validator_power: type: string format: int64 timestamp: type: string format: date-time description: DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes. tendermint.types.Evidence: type: object properties: duplicate_vote_evidence: type: object properties: vote_a: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: |- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. vote_b: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: |- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. total_voting_power: type: string format: int64 validator_power: type: string format: int64 timestamp: type: string format: date-time description: DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes. light_client_attack_evidence: type: object properties: conflicting_block: type: object properties: signed_header: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: Commit contains the evidence that a block was committed by a set of validators. validator_set: type: object properties: validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 proposer: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 common_height: type: string format: int64 byzantine_validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 timestamp: type: string format: date-time description: LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client. tendermint.types.EvidenceList: type: object properties: evidence: type: array items: type: object properties: duplicate_vote_evidence: type: object properties: vote_a: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. vote_b: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. total_voting_power: type: string format: int64 validator_power: type: string format: int64 timestamp: type: string format: date-time description: DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes. light_client_attack_evidence: type: object properties: conflicting_block: type: object properties: signed_header: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: Commit contains the evidence that a block was committed by a set of validators. validator_set: type: object properties: validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 proposer: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 common_height: type: string format: int64 byzantine_validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 timestamp: type: string format: date-time description: LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client. tendermint.types.LightBlock: type: object properties: signed_header: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: Commit contains the evidence that a block was committed by a set of validators. validator_set: type: object properties: validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 proposer: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 tendermint.types.LightClientAttackEvidence: type: object properties: conflicting_block: type: object properties: signed_header: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: Commit contains the evidence that a block was committed by a set of validators. validator_set: type: object properties: validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 proposer: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 common_height: type: string format: int64 byzantine_validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 timestamp: type: string format: date-time description: LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client. tendermint.types.SignedHeader: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: Commit contains the evidence that a block was committed by a set of validators. tendermint.types.SignedMsgType: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: |- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals tendermint.types.Validator: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 tendermint.types.ValidatorSet: type: object properties: validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 proposer: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 tendermint.types.Vote: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: |- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: |- Vote represents a prevote, precommit, or commit vote from validators for consensus. cyber.clock.v1.ClockContract: type: object properties: contract_address: type: string description: The address of the contract. is_jailed: type: boolean description: The jail status of the contract. description: |- This object is used to store the contract address and the jail status of the contract. cyber.clock.v1.Params: type: object properties: contract_gas_limit: type: string format: uint64 description: >- contract_gas_limit defines the maximum amount of gas that can be used by a contract. description: Params defines the set of module parameters. cyber.clock.v1.QueryClockContractResponse: type: object properties: clock_contract: type: object properties: contract_address: type: string description: The address of the contract. is_jailed: type: boolean description: The jail status of the contract. description: |- This object is used to store the contract address and the jail status of the contract. description: >- QueryClockContractResponse is the response type for the Query/ClockContract RPC method. cyber.clock.v1.QueryClockContractsResponse: type: object properties: clock_contracts: type: array items: type: object properties: contract_address: type: string description: The address of the contract. is_jailed: type: boolean description: The jail status of the contract. description: |- This object is used to store the contract address and the jail status of the contract. description: clock_contracts are the clock contracts. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- QueryClockContractsResponse is the response type for the Query/ClockContracts RPC method. cyber.clock.v1.QueryParamsResponse: type: object properties: params: type: object properties: contract_gas_limit: type: string format: uint64 description: >- contract_gas_limit defines the maximum amount of gas that can be used by a contract. description: Params defines the set of module parameters. description: >- QueryClockContractsResponse is the response type for the Query/ClockContracts RPC method. ibc.core.channel.v1.Channel: type: object properties: state: title: current state of the channel end type: string enum: - STATE_UNINITIALIZED_UNSPECIFIED - STATE_INIT - STATE_TRYOPEN - STATE_OPEN - STATE_CLOSED default: STATE_UNINITIALIZED_UNSPECIFIED description: >- State defines if a channel is in one of the following states: CLOSED, INIT, TRYOPEN, OPEN or UNINITIALIZED. - STATE_UNINITIALIZED_UNSPECIFIED: Default State - STATE_INIT: A channel has just started the opening handshake. - STATE_TRYOPEN: A channel has acknowledged the handshake step on the counterparty chain. - STATE_OPEN: A channel has completed the handshake. Open channels are ready to send and receive packets. - STATE_CLOSED: A channel has been closed and can no longer be used to send or receive packets. ordering: title: whether the channel is ordered or unordered type: string enum: - ORDER_NONE_UNSPECIFIED - ORDER_UNORDERED - ORDER_ORDERED default: ORDER_NONE_UNSPECIFIED description: >- - ORDER_NONE_UNSPECIFIED: zero-value for channel ordering - ORDER_UNORDERED: packets can be delivered in any order, which may differ from the order in which they were sent. - ORDER_ORDERED: packets are delivered exactly in the order which they were sent counterparty: title: counterparty channel end type: object properties: port_id: type: string description: port on the counterparty chain which owns the other end of the channel. channel_id: type: string title: channel end on the counterparty chain connection_hops: type: array items: type: string title: >- list of connection identifiers, in order, along which packets sent on this channel will travel version: type: string title: opaque channel version, which is agreed upon during the handshake description: >- Channel defines pipeline for exactly-once packet delivery between specific modules on separate blockchains, which has at least one end capable of sending packets and one end capable of receiving packets. ibc.core.channel.v1.Counterparty: type: object properties: port_id: type: string description: port on the counterparty chain which owns the other end of the channel. channel_id: type: string title: channel end on the counterparty chain title: Counterparty defines a channel end counterparty ibc.core.channel.v1.IdentifiedChannel: type: object properties: state: title: current state of the channel end type: string enum: - STATE_UNINITIALIZED_UNSPECIFIED - STATE_INIT - STATE_TRYOPEN - STATE_OPEN - STATE_CLOSED default: STATE_UNINITIALIZED_UNSPECIFIED description: >- State defines if a channel is in one of the following states: CLOSED, INIT, TRYOPEN, OPEN or UNINITIALIZED. - STATE_UNINITIALIZED_UNSPECIFIED: Default State - STATE_INIT: A channel has just started the opening handshake. - STATE_TRYOPEN: A channel has acknowledged the handshake step on the counterparty chain. - STATE_OPEN: A channel has completed the handshake. Open channels are ready to send and receive packets. - STATE_CLOSED: A channel has been closed and can no longer be used to send or receive packets. ordering: title: whether the channel is ordered or unordered type: string enum: - ORDER_NONE_UNSPECIFIED - ORDER_UNORDERED - ORDER_ORDERED default: ORDER_NONE_UNSPECIFIED description: >- - ORDER_NONE_UNSPECIFIED: zero-value for channel ordering - ORDER_UNORDERED: packets can be delivered in any order, which may differ from the order in which they were sent. - ORDER_ORDERED: packets are delivered exactly in the order which they were sent counterparty: title: counterparty channel end type: object properties: port_id: type: string description: port on the counterparty chain which owns the other end of the channel. channel_id: type: string title: channel end on the counterparty chain connection_hops: type: array items: type: string title: >- list of connection identifiers, in order, along which packets sent on this channel will travel version: type: string title: opaque channel version, which is agreed upon during the handshake port_id: type: string title: port identifier channel_id: type: string title: channel identifier description: |- IdentifiedChannel defines a channel with additional port and channel identifier fields. ibc.core.channel.v1.Order: type: string enum: - ORDER_NONE_UNSPECIFIED - ORDER_UNORDERED - ORDER_ORDERED default: ORDER_NONE_UNSPECIFIED description: >- - ORDER_NONE_UNSPECIFIED: zero-value for channel ordering - ORDER_UNORDERED: packets can be delivered in any order, which may differ from the order in which they were sent. - ORDER_ORDERED: packets are delivered exactly in the order which they were sent title: Order defines if a channel is ORDERED or UNORDERED ibc.core.channel.v1.PacketState: type: object properties: port_id: type: string description: channel port identifier. channel_id: type: string description: channel unique identifier. sequence: type: string format: uint64 description: packet sequence. data: type: string format: byte description: embedded data that represents packet state. description: >- PacketState defines the generic type necessary to retrieve and store packet commitments, acknowledgements, and receipts. Caller is responsible for knowing the context necessary to interpret this state as a commitment, acknowledgement, or a receipt. ibc.core.channel.v1.QueryChannelClientStateResponse: type: object properties: identified_client_state: title: client state associated with the channel type: object properties: client_id: type: string title: client identifier client_state: type: object properties: type_url: type: string value: type: string format: byte title: client state description: >- IdentifiedClientState defines a client state with an additional client identifier field. proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryChannelClientStateResponse is the Response type for the Query/QueryChannelClientState RPC method ibc.core.channel.v1.QueryChannelConsensusStateResponse: type: object properties: consensus_state: type: object properties: type_url: type: string value: type: string format: byte title: consensus state associated with the channel client_id: type: string title: client ID associated with the consensus state proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryChannelClientStateResponse is the Response type for the Query/QueryChannelClientState RPC method ibc.core.channel.v1.QueryChannelResponse: type: object properties: channel: title: channel associated with the request identifiers type: object properties: state: title: current state of the channel end type: string enum: - STATE_UNINITIALIZED_UNSPECIFIED - STATE_INIT - STATE_TRYOPEN - STATE_OPEN - STATE_CLOSED default: STATE_UNINITIALIZED_UNSPECIFIED description: >- State defines if a channel is in one of the following states: CLOSED, INIT, TRYOPEN, OPEN or UNINITIALIZED. - STATE_UNINITIALIZED_UNSPECIFIED: Default State - STATE_INIT: A channel has just started the opening handshake. - STATE_TRYOPEN: A channel has acknowledged the handshake step on the counterparty chain. - STATE_OPEN: A channel has completed the handshake. Open channels are ready to send and receive packets. - STATE_CLOSED: A channel has been closed and can no longer be used to send or receive packets. ordering: title: whether the channel is ordered or unordered type: string enum: - ORDER_NONE_UNSPECIFIED - ORDER_UNORDERED - ORDER_ORDERED default: ORDER_NONE_UNSPECIFIED description: >- - ORDER_NONE_UNSPECIFIED: zero-value for channel ordering - ORDER_UNORDERED: packets can be delivered in any order, which may differ from the order in which they were sent. - ORDER_ORDERED: packets are delivered exactly in the order which they were sent counterparty: title: counterparty channel end type: object properties: port_id: type: string description: port on the counterparty chain which owns the other end of the channel. channel_id: type: string title: channel end on the counterparty chain connection_hops: type: array items: type: string title: >- list of connection identifiers, in order, along which packets sent on this channel will travel version: type: string title: opaque channel version, which is agreed upon during the handshake description: >- Channel defines pipeline for exactly-once packet delivery between specific modules on separate blockchains, which has at least one end capable of sending packets and one end capable of receiving packets. proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset description: >- QueryChannelResponse is the response type for the Query/Channel RPC method. Besides the Channel end, it includes a proof and the height from which the proof was retrieved. ibc.core.channel.v1.QueryChannelsResponse: type: object properties: channels: type: array items: type: object properties: state: title: current state of the channel end type: string enum: - STATE_UNINITIALIZED_UNSPECIFIED - STATE_INIT - STATE_TRYOPEN - STATE_OPEN - STATE_CLOSED default: STATE_UNINITIALIZED_UNSPECIFIED description: >- State defines if a channel is in one of the following states: CLOSED, INIT, TRYOPEN, OPEN or UNINITIALIZED. - STATE_UNINITIALIZED_UNSPECIFIED: Default State - STATE_INIT: A channel has just started the opening handshake. - STATE_TRYOPEN: A channel has acknowledged the handshake step on the counterparty chain. - STATE_OPEN: A channel has completed the handshake. Open channels are ready to send and receive packets. - STATE_CLOSED: A channel has been closed and can no longer be used to send or receive packets. ordering: title: whether the channel is ordered or unordered type: string enum: - ORDER_NONE_UNSPECIFIED - ORDER_UNORDERED - ORDER_ORDERED default: ORDER_NONE_UNSPECIFIED description: >- - ORDER_NONE_UNSPECIFIED: zero-value for channel ordering - ORDER_UNORDERED: packets can be delivered in any order, which may differ from the order in which they were sent. - ORDER_ORDERED: packets are delivered exactly in the order which they were sent counterparty: title: counterparty channel end type: object properties: port_id: type: string description: port on the counterparty chain which owns the other end of the channel. channel_id: type: string title: channel end on the counterparty chain connection_hops: type: array items: type: string title: >- list of connection identifiers, in order, along which packets sent on this channel will travel version: type: string title: opaque channel version, which is agreed upon during the handshake port_id: type: string title: port identifier channel_id: type: string title: channel identifier description: >- IdentifiedChannel defines a channel with additional port and channel identifier fields. description: list of stored channels of the chain. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: pagination response height: title: query block height type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset description: QueryChannelsResponse is the response type for the Query/Channels RPC method. ibc.core.channel.v1.QueryConnectionChannelsResponse: type: object properties: channels: type: array items: type: object properties: state: title: current state of the channel end type: string enum: - STATE_UNINITIALIZED_UNSPECIFIED - STATE_INIT - STATE_TRYOPEN - STATE_OPEN - STATE_CLOSED default: STATE_UNINITIALIZED_UNSPECIFIED description: >- State defines if a channel is in one of the following states: CLOSED, INIT, TRYOPEN, OPEN or UNINITIALIZED. - STATE_UNINITIALIZED_UNSPECIFIED: Default State - STATE_INIT: A channel has just started the opening handshake. - STATE_TRYOPEN: A channel has acknowledged the handshake step on the counterparty chain. - STATE_OPEN: A channel has completed the handshake. Open channels are ready to send and receive packets. - STATE_CLOSED: A channel has been closed and can no longer be used to send or receive packets. ordering: title: whether the channel is ordered or unordered type: string enum: - ORDER_NONE_UNSPECIFIED - ORDER_UNORDERED - ORDER_ORDERED default: ORDER_NONE_UNSPECIFIED description: >- - ORDER_NONE_UNSPECIFIED: zero-value for channel ordering - ORDER_UNORDERED: packets can be delivered in any order, which may differ from the order in which they were sent. - ORDER_ORDERED: packets are delivered exactly in the order which they were sent counterparty: title: counterparty channel end type: object properties: port_id: type: string description: port on the counterparty chain which owns the other end of the channel. channel_id: type: string title: channel end on the counterparty chain connection_hops: type: array items: type: string title: >- list of connection identifiers, in order, along which packets sent on this channel will travel version: type: string title: opaque channel version, which is agreed upon during the handshake port_id: type: string title: port identifier channel_id: type: string title: channel identifier description: >- IdentifiedChannel defines a channel with additional port and channel identifier fields. description: list of channels associated with a connection. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: pagination response height: title: query block height type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryConnectionChannelsResponse is the Response type for the Query/QueryConnectionChannels RPC method ibc.core.channel.v1.QueryNextSequenceReceiveResponse: type: object properties: next_sequence_receive: type: string format: uint64 title: next sequence receive number proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QuerySequenceResponse is the request type for the Query/QueryNextSequenceReceiveResponse RPC method ibc.core.channel.v1.QueryPacketAcknowledgementResponse: type: object properties: acknowledgement: type: string format: byte title: packet associated with the request fields proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: >- QueryPacketAcknowledgementResponse defines the client query response for a packet which also includes a proof and the height from which the proof was retrieved ibc.core.channel.v1.QueryPacketAcknowledgementsResponse: type: object properties: acknowledgements: type: array items: type: object properties: port_id: type: string description: channel port identifier. channel_id: type: string description: channel unique identifier. sequence: type: string format: uint64 description: packet sequence. data: type: string format: byte description: embedded data that represents packet state. description: >- PacketState defines the generic type necessary to retrieve and store packet commitments, acknowledgements, and receipts. Caller is responsible for knowing the context necessary to interpret this state as a commitment, acknowledgement, or a receipt. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: pagination response height: title: query block height type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryPacketAcknowledgemetsResponse is the request type for the Query/QueryPacketAcknowledgements RPC method ibc.core.channel.v1.QueryPacketCommitmentResponse: type: object properties: commitment: type: string format: byte title: packet associated with the request fields proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: >- QueryPacketCommitmentResponse defines the client query response for a packet which also includes a proof and the height from which the proof was retrieved ibc.core.channel.v1.QueryPacketCommitmentsResponse: type: object properties: commitments: type: array items: type: object properties: port_id: type: string description: channel port identifier. channel_id: type: string description: channel unique identifier. sequence: type: string format: uint64 description: packet sequence. data: type: string format: byte description: embedded data that represents packet state. description: >- PacketState defines the generic type necessary to retrieve and store packet commitments, acknowledgements, and receipts. Caller is responsible for knowing the context necessary to interpret this state as a commitment, acknowledgement, or a receipt. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: pagination response height: title: query block height type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryPacketCommitmentsResponse is the request type for the Query/QueryPacketCommitments RPC method ibc.core.channel.v1.QueryPacketReceiptResponse: type: object properties: received: type: boolean title: success flag for if receipt exists proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: >- QueryPacketReceiptResponse defines the client query response for a packet receipt which also includes a proof, and the height from which the proof was retrieved ibc.core.channel.v1.QueryUnreceivedAcksResponse: type: object properties: sequences: type: array items: type: string format: uint64 title: list of unreceived acknowledgement sequences height: title: query block height type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryUnreceivedAcksResponse is the response type for the Query/UnreceivedAcks RPC method ibc.core.channel.v1.QueryUnreceivedPacketsResponse: type: object properties: sequences: type: array items: type: string format: uint64 title: list of unreceived packet sequences height: title: query block height type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryUnreceivedPacketsResponse is the response type for the Query/UnreceivedPacketCommitments RPC method ibc.core.channel.v1.State: type: string enum: - STATE_UNINITIALIZED_UNSPECIFIED - STATE_INIT - STATE_TRYOPEN - STATE_OPEN - STATE_CLOSED default: STATE_UNINITIALIZED_UNSPECIFIED description: >- State defines if a channel is in one of the following states: CLOSED, INIT, TRYOPEN, OPEN or UNINITIALIZED. - STATE_UNINITIALIZED_UNSPECIFIED: Default State - STATE_INIT: A channel has just started the opening handshake. - STATE_TRYOPEN: A channel has acknowledged the handshake step on the counterparty chain. - STATE_OPEN: A channel has completed the handshake. Open channels are ready to send and receive packets. - STATE_CLOSED: A channel has been closed and can no longer be used to send or receive packets. cosmos.auth.v1beta1.AddressBytesToStringResponse: type: object properties: address_string: type: string description: >- AddressBytesToStringResponse is the response type for AddressString rpc method. Since: cosmos-sdk 0.46 cosmos.auth.v1beta1.AddressStringToBytesResponse: type: object properties: address_bytes: type: string format: byte description: >- AddressStringToBytesResponse is the response type for AddressBytes rpc method. Since: cosmos-sdk 0.46 cosmos.auth.v1beta1.BaseAccount: type: object properties: address: type: string pub_key: type: object properties: type_url: type: string value: type: string format: byte account_number: type: string format: uint64 sequence: type: string format: uint64 description: >- BaseAccount defines a base account type. It contains all the necessary fields for basic account functionality. Any custom account type should extend this type for additional functionality (e.g. vesting). cosmos.auth.v1beta1.Bech32PrefixResponse: type: object properties: bech32_prefix: type: string description: |- Bech32PrefixResponse is the response type for Bech32Prefix rpc method. Since: cosmos-sdk 0.46 cosmos.auth.v1beta1.Params: type: object properties: max_memo_characters: type: string format: uint64 tx_sig_limit: type: string format: uint64 tx_size_cost_per_byte: type: string format: uint64 sig_verify_cost_ed25519: type: string format: uint64 sig_verify_cost_secp256k1: type: string format: uint64 description: Params defines the parameters for the auth module. cosmos.auth.v1beta1.QueryAccountAddressByIDResponse: type: object properties: account_address: type: string description: "Since: cosmos-sdk 0.46.2" title: QueryAccountAddressByIDResponse is the response type for AccountAddressByID rpc method cosmos.auth.v1beta1.QueryAccountInfoResponse: type: object properties: info: description: info is the account info which is represented by BaseAccount. type: object properties: address: type: string pub_key: type: object properties: type_url: type: string value: type: string format: byte account_number: type: string format: uint64 sequence: type: string format: uint64 description: |- QueryAccountInfoResponse is the Query/AccountInfo response type. Since: cosmos-sdk 0.47 cosmos.auth.v1beta1.QueryAccountResponse: type: object properties: account: type: object properties: type_url: type: string value: type: string format: byte description: account defines the account of the corresponding address. description: QueryAccountResponse is the response type for the Query/Account RPC method. cosmos.auth.v1beta1.QueryAccountsResponse: type: object properties: accounts: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: accounts are the existing accounts pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- QueryAccountsResponse is the response type for the Query/Accounts RPC method. Since: cosmos-sdk 0.43 cosmos.auth.v1beta1.QueryModuleAccountByNameResponse: type: object properties: account: type: object properties: type_url: type: string value: type: string format: byte description: QueryModuleAccountByNameResponse is the response type for the Query/ModuleAccountByName RPC method. cosmos.auth.v1beta1.QueryModuleAccountsResponse: type: object properties: accounts: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- QueryModuleAccountsResponse is the response type for the Query/ModuleAccounts RPC method. Since: cosmos-sdk 0.46 cosmos.auth.v1beta1.QueryParamsResponse: type: object properties: params: description: params defines the parameters of the module. type: object properties: max_memo_characters: type: string format: uint64 tx_sig_limit: type: string format: uint64 tx_size_cost_per_byte: type: string format: uint64 sig_verify_cost_ed25519: type: string format: uint64 sig_verify_cost_secp256k1: type: string format: uint64 description: QueryParamsResponse is the response type for the Query/Params RPC method. cosmos.evidence.v1beta1.QueryAllEvidenceResponse: type: object properties: evidence: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: evidence returns all evidences. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- QueryAllEvidenceResponse is the response type for the Query/AllEvidence RPC method. cosmos.evidence.v1beta1.QueryEvidenceResponse: type: object properties: evidence: type: object properties: type_url: type: string value: type: string format: byte description: evidence returns the requested evidence. description: QueryEvidenceResponse is the response type for the Query/Evidence RPC method. ibc.core.client.v1.ConsensusStateWithHeight: type: object properties: height: title: consensus state height type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset consensus_state: type: object properties: type_url: type: string value: type: string format: byte title: consensus state description: >- ConsensusStateWithHeight defines a consensus state with an additional height field. ibc.core.client.v1.Params: type: object properties: allowed_clients: type: array items: type: string description: >- allowed_clients defines the list of allowed client state types which can be created and interacted with. If a client type is removed from the allowed clients list, usage of this client will be disabled until it is added again to the list. description: Params defines the set of IBC light client parameters. ibc.core.client.v1.QueryClientParamsResponse: type: object properties: params: description: params defines the parameters of the module. type: object properties: allowed_clients: type: array items: type: string description: >- allowed_clients defines the list of allowed client state types which can be created and interacted with. If a client type is removed from the allowed clients list, usage of this client will be disabled until it is added again to the list. description: >- QueryClientParamsResponse is the response type for the Query/ClientParams RPC method. ibc.core.client.v1.QueryClientStateResponse: type: object properties: client_state: type: object properties: type_url: type: string value: type: string format: byte title: client state associated with the request identifier proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset description: >- QueryClientStateResponse is the response type for the Query/ClientState RPC method. Besides the client state, it includes a proof and the height from which the proof was retrieved. ibc.core.client.v1.QueryClientStatesResponse: type: object properties: client_states: type: array items: type: object properties: client_id: type: string title: client identifier client_state: type: object properties: type_url: type: string value: type: string format: byte title: client state description: >- IdentifiedClientState defines a client state with an additional client identifier field. description: list of stored ClientStates of the chain. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: pagination response description: >- QueryClientStatesResponse is the response type for the Query/ClientStates RPC method. ibc.core.client.v1.QueryClientStatusResponse: type: object properties: status: type: string description: >- QueryClientStatusResponse is the response type for the Query/ClientStatus RPC method. It returns the current status of the IBC client. ibc.core.client.v1.QueryConsensusStateHeightsResponse: type: object properties: consensus_state_heights: type: array items: type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: >- Height is a monotonically increasing data type that can be compared against another Height for the purposes of updating and freezing clients title: consensus state heights pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: pagination response title: |- QueryConsensusStateHeightsResponse is the response type for the Query/ConsensusStateHeights RPC method ibc.core.client.v1.QueryConsensusStateResponse: type: object properties: consensus_state: type: object properties: type_url: type: string value: type: string format: byte title: consensus state associated with the client identifier at the given height proof: type: string format: byte title: merkle proof of existence proof_height: type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: >- Height is a monotonically increasing data type that can be compared against another Height for the purposes of updating and freezing clients title: >- QueryConsensusStateResponse is the response type for the Query/ConsensusState RPC method ibc.core.client.v1.QueryConsensusStatesResponse: type: object properties: consensus_states: type: array items: type: object properties: height: title: consensus state height type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset consensus_state: type: object properties: type_url: type: string value: type: string format: byte title: consensus state description: >- ConsensusStateWithHeight defines a consensus state with an additional height field. title: consensus states associated with the identifier pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: pagination response title: |- QueryConsensusStatesResponse is the response type for the Query/ConsensusStates RPC method ibc.core.client.v1.QueryUpgradedClientStateResponse: type: object properties: upgraded_client_state: type: object properties: type_url: type: string value: type: string format: byte title: client state associated with the request identifier description: |- QueryUpgradedClientStateResponse is the response type for the Query/UpgradedClientState RPC method. ibc.core.client.v1.QueryUpgradedConsensusStateResponse: type: object properties: upgraded_consensus_state: type: object properties: type_url: type: string value: type: string format: byte title: Consensus state associated with the request identifier description: |- QueryUpgradedConsensusStateResponse is the response type for the Query/UpgradedConsensusState RPC method. cosmos.authz.v1beta1.Grant: type: object properties: authorization: type: object properties: type_url: type: string value: type: string format: byte expiration: type: string format: date-time title: >- time when the grant will expire and will be pruned. If null, then the grant doesn't have a time expiration (other conditions in `authorization` may apply to invalidate the grant) description: |- Grant gives permissions to execute the provide method with expiration time. cosmos.authz.v1beta1.GrantAuthorization: type: object properties: granter: type: string grantee: type: string authorization: type: object properties: type_url: type: string value: type: string format: byte expiration: type: string format: date-time title: >- GrantAuthorization extends a grant with both the addresses of the grantee and granter. It is used in genesis.proto and query.proto cosmos.authz.v1beta1.QueryGranteeGrantsResponse: type: object properties: grants: type: array items: type: object properties: granter: type: string grantee: type: string authorization: type: object properties: type_url: type: string value: type: string format: byte expiration: type: string format: date-time title: >- GrantAuthorization extends a grant with both the addresses of the grantee and granter. It is used in genesis.proto and query.proto description: grants is a list of grants granted to the grantee. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: QueryGranteeGrantsResponse is the response type for the Query/GranteeGrants RPC method. cosmos.authz.v1beta1.QueryGranterGrantsResponse: type: object properties: grants: type: array items: type: object properties: granter: type: string grantee: type: string authorization: type: object properties: type_url: type: string value: type: string format: byte expiration: type: string format: date-time title: >- GrantAuthorization extends a grant with both the addresses of the grantee and granter. It is used in genesis.proto and query.proto description: grants is a list of grants granted by the granter. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: QueryGranterGrantsResponse is the response type for the Query/GranterGrants RPC method. cosmos.authz.v1beta1.QueryGrantsResponse: type: object properties: grants: type: array items: type: object properties: authorization: type: object properties: type_url: type: string value: type: string format: byte expiration: type: string format: date-time title: >- time when the grant will expire and will be pruned. If null, then the grant doesn't have a time expiration (other conditions in `authorization` may apply to invalidate the grant) description: |- Grant gives permissions to execute the provide method with expiration time. description: authorizations is a list of grants granted for grantee by granter. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: QueryGrantsResponse is the response type for the Query/Authorizations RPC method. cyber.liquidity.v1beta1.DepositMsgState: type: object properties: msg_height: type: string format: int64 title: height where this message is appended to the batch msg_index: type: string format: uint64 title: index of this deposit message in this liquidity pool executed: type: boolean title: true if executed on this batch, false if not executed succeeded: type: boolean title: true if executed successfully on this batch, false if failed to_be_deleted: type: boolean title: true if ready to be deleted on kvstore, false if not ready to be deleted msg: title: MsgDepositWithinBatch type: object properties: depositor_address: type: string pool_id: type: string format: uint64 title: id of the target pool deposit_coins: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: reserve coin pair of the pool to deposit description: >- `MsgDepositWithinBatch defines` an `sdk.Msg` type that supports submitting a deposit request to the batch of the liquidity pool. Deposit is submitted to the batch of the Liquidity pool with the specified `pool_id`, `deposit_coins` for reserve. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. See: https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md description: |- DepositMsgState defines the state of deposit message that contains state information as it is processed in the next batch or batches. cyber.liquidity.v1beta1.MsgDepositWithinBatch: type: object properties: depositor_address: type: string pool_id: type: string format: uint64 title: id of the target pool deposit_coins: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: reserve coin pair of the pool to deposit description: >- `MsgDepositWithinBatch defines` an `sdk.Msg` type that supports submitting a deposit request to the batch of the liquidity pool. Deposit is submitted to the batch of the Liquidity pool with the specified `pool_id`, `deposit_coins` for reserve. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. See: https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md cyber.liquidity.v1beta1.MsgSwapWithinBatch: type: object properties: swap_requester_address: type: string title: address of swap requester pool_id: type: string format: uint64 description: >- id of swap type, must match the value in the pool. Only `swap_type_id` 1 is supported. swap_type_id: type: integer format: int64 description: id of swap type. Must match the value in the pool. offer_coin: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. demand_coin_denom: type: string description: >- denom of demand coin to be exchanged on the swap request, must match the denom in the pool. offer_coin_fee: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. order_price: type: string description: >- limit order price for the order, the price is the exchange ratio of X/Y where X is the amount of the first coin and Y is the amount of the second coin when their denoms are sorted alphabetically. description: >- `MsgSwapWithinBatch` defines an sdk.Msg type that supports submitting a swap offer request to the batch of the liquidity pool. Submit swap offer to the liquidity pool batch with the specified the `pool_id`, `swap_type_id`, `demand_coin_denom` with the coin and the price you're offering and `offer_coin_fee` must be half of offer coin amount * current `params.swap_fee_rate` and ceil for reservation to pay fees. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. You must request the same fields as the pool. Only the default `swap_type_id` 1 is supported. See: https://github.com/gravity-devs/liquidity/tree/develop/doc https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md cyber.liquidity.v1beta1.MsgWithdrawWithinBatch: type: object properties: withdrawer_address: type: string pool_id: type: string format: uint64 title: id of the target pool pool_coin: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- `MsgWithdrawWithinBatch` defines an `sdk.Msg` type that supports submitting a withdraw request to the batch of the liquidity pool. Withdraw is submitted to the batch from the Liquidity pool with the specified `pool_id`, `pool_coin` of the pool. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. See: https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md cyber.liquidity.v1beta1.Params: type: object properties: pool_types: type: array items: type: object properties: id: type: integer format: int64 title: >- This is the id of the pool_type that is used as pool_type_id for pool creation. In this version, only pool-type-id 1 is supported. {"id":1,"name":"ConstantProductLiquidityPool","min_reserve_coin_num":2,"max_reserve_coin_num":2,"description":""} name: type: string description: name of the pool type. min_reserve_coin_num: type: integer format: int64 description: >- minimum number of reserveCoins for LiquidityPoolType, only 2 reserve coins are supported. max_reserve_coin_num: type: integer format: int64 description: >- maximum number of reserveCoins for LiquidityPoolType, only 2 reserve coins are supported. description: type: string description: description of the pool type. description: >- Structure for the pool type to distinguish the characteristics of the reserve pools. title: list of available pool types min_init_deposit_amount: type: string description: >- Minimum number of coins to be deposited to the liquidity pool on pool creation. init_pool_coin_mint_amount: type: string description: Initial mint amount of pool coins upon pool creation. max_reserve_coin_amount: type: string description: >- Limit the size of each liquidity pool to minimize risk. In development, set to 0 for no limit. In production, set a limit. pool_creation_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: Fee paid to create a Liquidity Pool. Set a fee to prevent spamming. swap_fee_rate: type: string description: Swap fee rate for every executed swap. withdraw_fee_rate: type: string description: Reserve coin withdrawal with less proportion by withdrawFeeRate. max_order_amount_ratio: type: string description: Maximum ratio of reserve coins that can be ordered at a swap order. unit_batch_height: type: integer format: int64 description: The smallest unit batch height for every liquidity pool. circuit_breaker_enabled: type: boolean description: >- Circuit breaker enables or disables transaction messages in liquidity module. description: Params defines the parameters for the liquidity module. cyber.liquidity.v1beta1.Pool: type: object properties: id: type: string format: uint64 title: id of the pool type_id: type: integer format: int64 title: id of the pool_type reserve_coin_denoms: type: array items: type: string title: denoms of reserve coin pair of the pool reserve_account_address: type: string title: reserve account address of the pool pool_coin_denom: type: string title: denom of pool coin of the pool description: Pool defines the liquidity pool that contains pool information. cyber.liquidity.v1beta1.PoolBatch: type: object properties: pool_id: type: string format: uint64 title: id of the pool index: type: string format: uint64 title: index of this batch begin_height: type: string format: int64 title: height where this batch is started deposit_msg_index: type: string format: uint64 title: last index of DepositMsgStates withdraw_msg_index: type: string format: uint64 title: last index of WithdrawMsgStates swap_msg_index: type: string format: uint64 title: last index of SwapMsgStates executed: type: boolean title: true if executed, false if not executed description: |- PoolBatch defines the batch or batches of a given liquidity pool that contains indexes of deposit, withdraw, and swap messages. Index param increments by 1 if the pool id is same. cyber.liquidity.v1beta1.PoolType: type: object properties: id: type: integer format: int64 title: >- This is the id of the pool_type that is used as pool_type_id for pool creation. In this version, only pool-type-id 1 is supported. {"id":1,"name":"ConstantProductLiquidityPool","min_reserve_coin_num":2,"max_reserve_coin_num":2,"description":""} name: type: string description: name of the pool type. min_reserve_coin_num: type: integer format: int64 description: >- minimum number of reserveCoins for LiquidityPoolType, only 2 reserve coins are supported. max_reserve_coin_num: type: integer format: int64 description: >- maximum number of reserveCoins for LiquidityPoolType, only 2 reserve coins are supported. description: type: string description: description of the pool type. description: >- Structure for the pool type to distinguish the characteristics of the reserve pools. cyber.liquidity.v1beta1.QueryLiquidityPoolBatchResponse: type: object properties: batch: type: object properties: pool_id: type: string format: uint64 title: id of the pool index: type: string format: uint64 title: index of this batch begin_height: type: string format: int64 title: height where this batch is started deposit_msg_index: type: string format: uint64 title: last index of DepositMsgStates withdraw_msg_index: type: string format: uint64 title: last index of WithdrawMsgStates swap_msg_index: type: string format: uint64 title: last index of SwapMsgStates executed: type: boolean title: true if executed, false if not executed description: >- PoolBatch defines the batch or batches of a given liquidity pool that contains indexes of deposit, withdraw, and swap messages. Index param increments by 1 if the pool id is same. description: >- the response type for the QueryLiquidityPoolBatchResponse RPC method. Returns the liquidity pool batch that corresponds to the requested pool_id. cyber.liquidity.v1beta1.QueryLiquidityPoolResponse: type: object properties: pool: type: object properties: id: type: string format: uint64 title: id of the pool type_id: type: integer format: int64 title: id of the pool_type reserve_coin_denoms: type: array items: type: string title: denoms of reserve coin pair of the pool reserve_account_address: type: string title: reserve account address of the pool pool_coin_denom: type: string title: denom of pool coin of the pool description: Pool defines the liquidity pool that contains pool information. description: >- the response type for the QueryLiquidityPoolResponse RPC method. Returns the liquidity pool that corresponds to the requested pool_id. cyber.liquidity.v1beta1.QueryLiquidityPoolsResponse: type: object properties: pools: type: array items: type: object properties: id: type: string format: uint64 title: id of the pool type_id: type: integer format: int64 title: id of the pool_type reserve_coin_denoms: type: array items: type: string title: denoms of reserve coin pair of the pool reserve_account_address: type: string title: reserve account address of the pool pool_coin_denom: type: string title: denom of pool coin of the pool description: Pool defines the liquidity pool that contains pool information. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: |- the response type for the QueryLiquidityPoolsResponse RPC method. This includes a list of all existing liquidity pools and paging results that contain next_key and total count. cyber.liquidity.v1beta1.QueryParamsResponse: type: object properties: params: description: params holds all the parameters of this module. type: object properties: pool_types: type: array items: type: object properties: id: type: integer format: int64 title: >- This is the id of the pool_type that is used as pool_type_id for pool creation. In this version, only pool-type-id 1 is supported. {"id":1,"name":"ConstantProductLiquidityPool","min_reserve_coin_num":2,"max_reserve_coin_num":2,"description":""} name: type: string description: name of the pool type. min_reserve_coin_num: type: integer format: int64 description: >- minimum number of reserveCoins for LiquidityPoolType, only 2 reserve coins are supported. max_reserve_coin_num: type: integer format: int64 description: >- maximum number of reserveCoins for LiquidityPoolType, only 2 reserve coins are supported. description: type: string description: description of the pool type. description: >- Structure for the pool type to distinguish the characteristics of the reserve pools. title: list of available pool types min_init_deposit_amount: type: string description: >- Minimum number of coins to be deposited to the liquidity pool on pool creation. init_pool_coin_mint_amount: type: string description: Initial mint amount of pool coins upon pool creation. max_reserve_coin_amount: type: string description: >- Limit the size of each liquidity pool to minimize risk. In development, set to 0 for no limit. In production, set a limit. pool_creation_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: Fee paid to create a Liquidity Pool. Set a fee to prevent spamming. swap_fee_rate: type: string description: Swap fee rate for every executed swap. withdraw_fee_rate: type: string description: Reserve coin withdrawal with less proportion by withdrawFeeRate. max_order_amount_ratio: type: string description: Maximum ratio of reserve coins that can be ordered at a swap order. unit_batch_height: type: integer format: int64 description: The smallest unit batch height for every liquidity pool. circuit_breaker_enabled: type: boolean description: >- Circuit breaker enables or disables transaction messages in liquidity module. description: |- the response type for the QueryParamsResponse RPC method. This includes current parameter of the liquidity module. cyber.liquidity.v1beta1.QueryPoolBatchDepositMsgResponse: type: object properties: deposit: type: object properties: msg_height: type: string format: int64 title: height where this message is appended to the batch msg_index: type: string format: uint64 title: index of this deposit message in this liquidity pool executed: type: boolean title: true if executed on this batch, false if not executed succeeded: type: boolean title: true if executed successfully on this batch, false if failed to_be_deleted: type: boolean title: true if ready to be deleted on kvstore, false if not ready to be deleted msg: title: MsgDepositWithinBatch type: object properties: depositor_address: type: string pool_id: type: string format: uint64 title: id of the target pool deposit_coins: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: reserve coin pair of the pool to deposit description: >- `MsgDepositWithinBatch defines` an `sdk.Msg` type that supports submitting a deposit request to the batch of the liquidity pool. Deposit is submitted to the batch of the Liquidity pool with the specified `pool_id`, `deposit_coins` for reserve. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. See: https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md description: >- DepositMsgState defines the state of deposit message that contains state information as it is processed in the next batch or batches. description: >- the response type for the QueryPoolBatchDepositMsg RPC method. This includes a batch swap message of the batch. cyber.liquidity.v1beta1.QueryPoolBatchDepositMsgsResponse: type: object properties: deposits: type: array items: type: object properties: msg_height: type: string format: int64 title: height where this message is appended to the batch msg_index: type: string format: uint64 title: index of this deposit message in this liquidity pool executed: type: boolean title: true if executed on this batch, false if not executed succeeded: type: boolean title: true if executed successfully on this batch, false if failed to_be_deleted: type: boolean title: true if ready to be deleted on kvstore, false if not ready to be deleted msg: title: MsgDepositWithinBatch type: object properties: depositor_address: type: string pool_id: type: string format: uint64 title: id of the target pool deposit_coins: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: reserve coin pair of the pool to deposit description: >- `MsgDepositWithinBatch defines` an `sdk.Msg` type that supports submitting a deposit request to the batch of the liquidity pool. Deposit is submitted to the batch of the Liquidity pool with the specified `pool_id`, `deposit_coins` for reserve. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. See: https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md description: >- DepositMsgState defines the state of deposit message that contains state information as it is processed in the next batch or batches. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- the response type for the QueryPoolBatchDeposit RPC method. This includes a list of all currently existing deposit messages of the batch and paging results that contain next_key and total count. cyber.liquidity.v1beta1.QueryPoolBatchSwapMsgResponse: type: object properties: swap: type: object properties: msg_height: type: string format: int64 title: height where this message is appended to the batch msg_index: type: string format: uint64 title: index of this swap message in this liquidity pool executed: type: boolean title: true if executed on this batch, false if not executed succeeded: type: boolean title: true if executed successfully on this batch, false if failed to_be_deleted: type: boolean title: true if ready to be deleted on kvstore, false if not ready to be deleted order_expiry_height: type: string format: int64 title: >- swap orders are cancelled when current height is equal to or higher than ExpiryHeight exchanged_offer_coin: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: offer coin exchanged until now remaining_offer_coin: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: offer coin currently remaining to be exchanged reserved_offer_coin_fee: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: reserve fee for pays fee in half offer coin msg: title: MsgSwapWithinBatch type: object properties: swap_requester_address: type: string title: address of swap requester pool_id: type: string format: uint64 description: >- id of swap type, must match the value in the pool. Only `swap_type_id` 1 is supported. swap_type_id: type: integer format: int64 description: id of swap type. Must match the value in the pool. offer_coin: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. demand_coin_denom: type: string description: >- denom of demand coin to be exchanged on the swap request, must match the denom in the pool. offer_coin_fee: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. order_price: type: string description: >- limit order price for the order, the price is the exchange ratio of X/Y where X is the amount of the first coin and Y is the amount of the second coin when their denoms are sorted alphabetically. description: >- `MsgSwapWithinBatch` defines an sdk.Msg type that supports submitting a swap offer request to the batch of the liquidity pool. Submit swap offer to the liquidity pool batch with the specified the `pool_id`, `swap_type_id`, `demand_coin_denom` with the coin and the price you're offering and `offer_coin_fee` must be half of offer coin amount * current `params.swap_fee_rate` and ceil for reservation to pay fees. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. You must request the same fields as the pool. Only the default `swap_type_id` 1 is supported. See: https://github.com/gravity-devs/liquidity/tree/develop/doc https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md description: >- SwapMsgState defines the state of the swap message that contains state information as the message is processed in the next batch or batches. description: >- the response type for the QueryPoolBatchSwapMsg RPC method. This includes a batch swap message of the batch. cyber.liquidity.v1beta1.QueryPoolBatchSwapMsgsResponse: type: object properties: swaps: type: array items: type: object properties: msg_height: type: string format: int64 title: height where this message is appended to the batch msg_index: type: string format: uint64 title: index of this swap message in this liquidity pool executed: type: boolean title: true if executed on this batch, false if not executed succeeded: type: boolean title: true if executed successfully on this batch, false if failed to_be_deleted: type: boolean title: true if ready to be deleted on kvstore, false if not ready to be deleted order_expiry_height: type: string format: int64 title: >- swap orders are cancelled when current height is equal to or higher than ExpiryHeight exchanged_offer_coin: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: offer coin exchanged until now remaining_offer_coin: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: offer coin currently remaining to be exchanged reserved_offer_coin_fee: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: reserve fee for pays fee in half offer coin msg: title: MsgSwapWithinBatch type: object properties: swap_requester_address: type: string title: address of swap requester pool_id: type: string format: uint64 description: >- id of swap type, must match the value in the pool. Only `swap_type_id` 1 is supported. swap_type_id: type: integer format: int64 description: id of swap type. Must match the value in the pool. offer_coin: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. demand_coin_denom: type: string description: >- denom of demand coin to be exchanged on the swap request, must match the denom in the pool. offer_coin_fee: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. order_price: type: string description: >- limit order price for the order, the price is the exchange ratio of X/Y where X is the amount of the first coin and Y is the amount of the second coin when their denoms are sorted alphabetically. description: >- `MsgSwapWithinBatch` defines an sdk.Msg type that supports submitting a swap offer request to the batch of the liquidity pool. Submit swap offer to the liquidity pool batch with the specified the `pool_id`, `swap_type_id`, `demand_coin_denom` with the coin and the price you're offering and `offer_coin_fee` must be half of offer coin amount * current `params.swap_fee_rate` and ceil for reservation to pay fees. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. You must request the same fields as the pool. Only the default `swap_type_id` 1 is supported. See: https://github.com/gravity-devs/liquidity/tree/develop/doc https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md description: >- SwapMsgState defines the state of the swap message that contains state information as the message is processed in the next batch or batches. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- the response type for the QueryPoolBatchSwapMsgs RPC method. This includes list of all currently existing swap messages of the batch and paging results that contain next_key and total count. cyber.liquidity.v1beta1.QueryPoolBatchWithdrawMsgResponse: type: object properties: withdraw: type: object properties: msg_height: type: string format: int64 title: height where this message is appended to the batch msg_index: type: string format: uint64 title: index of this withdraw message in this liquidity pool executed: type: boolean title: true if executed on this batch, false if not executed succeeded: type: boolean title: true if executed successfully on this batch, false if failed to_be_deleted: type: boolean title: true if ready to be deleted on kvstore, false if not ready to be deleted msg: title: MsgWithdrawWithinBatch type: object properties: withdrawer_address: type: string pool_id: type: string format: uint64 title: id of the target pool pool_coin: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- `MsgWithdrawWithinBatch` defines an `sdk.Msg` type that supports submitting a withdraw request to the batch of the liquidity pool. Withdraw is submitted to the batch from the Liquidity pool with the specified `pool_id`, `pool_coin` of the pool. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. See: https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md description: >- WithdrawMsgState defines the state of the withdraw message that contains state information as the message is processed in the next batch or batches. description: >- the response type for the QueryPoolBatchWithdrawMsg RPC method. This includes a batch swap message of the batch. cyber.liquidity.v1beta1.QueryPoolBatchWithdrawMsgsResponse: type: object properties: withdraws: type: array items: type: object properties: msg_height: type: string format: int64 title: height where this message is appended to the batch msg_index: type: string format: uint64 title: index of this withdraw message in this liquidity pool executed: type: boolean title: true if executed on this batch, false if not executed succeeded: type: boolean title: true if executed successfully on this batch, false if failed to_be_deleted: type: boolean title: true if ready to be deleted on kvstore, false if not ready to be deleted msg: title: MsgWithdrawWithinBatch type: object properties: withdrawer_address: type: string pool_id: type: string format: uint64 title: id of the target pool pool_coin: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- `MsgWithdrawWithinBatch` defines an `sdk.Msg` type that supports submitting a withdraw request to the batch of the liquidity pool. Withdraw is submitted to the batch from the Liquidity pool with the specified `pool_id`, `pool_coin` of the pool. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. See: https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md description: >- WithdrawMsgState defines the state of the withdraw message that contains state information as the message is processed in the next batch or batches. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- the response type for the QueryPoolBatchWithdraw RPC method. This includes a list of all currently existing withdraw messages of the batch and paging results that contain next_key and total count. cyber.liquidity.v1beta1.SwapMsgState: type: object properties: msg_height: type: string format: int64 title: height where this message is appended to the batch msg_index: type: string format: uint64 title: index of this swap message in this liquidity pool executed: type: boolean title: true if executed on this batch, false if not executed succeeded: type: boolean title: true if executed successfully on this batch, false if failed to_be_deleted: type: boolean title: true if ready to be deleted on kvstore, false if not ready to be deleted order_expiry_height: type: string format: int64 title: >- swap orders are cancelled when current height is equal to or higher than ExpiryHeight exchanged_offer_coin: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: offer coin exchanged until now remaining_offer_coin: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: offer coin currently remaining to be exchanged reserved_offer_coin_fee: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: reserve fee for pays fee in half offer coin msg: title: MsgSwapWithinBatch type: object properties: swap_requester_address: type: string title: address of swap requester pool_id: type: string format: uint64 description: >- id of swap type, must match the value in the pool. Only `swap_type_id` 1 is supported. swap_type_id: type: integer format: int64 description: id of swap type. Must match the value in the pool. offer_coin: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. demand_coin_denom: type: string description: >- denom of demand coin to be exchanged on the swap request, must match the denom in the pool. offer_coin_fee: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. order_price: type: string description: >- limit order price for the order, the price is the exchange ratio of X/Y where X is the amount of the first coin and Y is the amount of the second coin when their denoms are sorted alphabetically. description: >- `MsgSwapWithinBatch` defines an sdk.Msg type that supports submitting a swap offer request to the batch of the liquidity pool. Submit swap offer to the liquidity pool batch with the specified the `pool_id`, `swap_type_id`, `demand_coin_denom` with the coin and the price you're offering and `offer_coin_fee` must be half of offer coin amount * current `params.swap_fee_rate` and ceil for reservation to pay fees. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. You must request the same fields as the pool. Only the default `swap_type_id` 1 is supported. See: https://github.com/gravity-devs/liquidity/tree/develop/doc https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md description: |- SwapMsgState defines the state of the swap message that contains state information as the message is processed in the next batch or batches. cyber.liquidity.v1beta1.WithdrawMsgState: type: object properties: msg_height: type: string format: int64 title: height where this message is appended to the batch msg_index: type: string format: uint64 title: index of this withdraw message in this liquidity pool executed: type: boolean title: true if executed on this batch, false if not executed succeeded: type: boolean title: true if executed successfully on this batch, false if failed to_be_deleted: type: boolean title: true if ready to be deleted on kvstore, false if not ready to be deleted msg: title: MsgWithdrawWithinBatch type: object properties: withdrawer_address: type: string pool_id: type: string format: uint64 title: id of the target pool pool_coin: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- `MsgWithdrawWithinBatch` defines an `sdk.Msg` type that supports submitting a withdraw request to the batch of the liquidity pool. Withdraw is submitted to the batch from the Liquidity pool with the specified `pool_id`, `pool_coin` of the pool. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. See: https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md description: >- WithdrawMsgState defines the state of the withdraw message that contains state information as the message is processed in the next batch or batches. cosmos.app.v1alpha1.Config: type: object properties: modules: type: array items: type: object properties: name: type: string description: >- name is the unique name of the module within the app. It should be a name that persists between different versions of a module so that modules can be smoothly upgraded to new versions. For example, for the module cosmos.bank.module.v1.Module, we may chose to simply name the module "bank" in the app. When we upgrade to cosmos.bank.module.v2.Module, the app-specific name "bank" stays the same and the framework knows that the v2 module should receive all the same state that the v1 module had. Note: modules should provide info on which versions they can migrate from in the ModuleDescriptor.can_migration_from field. config: type: object properties: type_url: type: string value: type: string format: byte description: >- config is the config object for the module. Module config messages should define a ModuleDescriptor using the cosmos.app.v1alpha1.is_module extension. golang_bindings: type: array items: type: object properties: interface_type: type: string title: interface_type is the interface type which will be bound to a specific implementation type implementation: type: string title: implementation is the implementing type which will be supplied when an input of type interface is requested description: GolangBinding is an explicit interface type to implementing type binding for dependency injection. description: >- golang_bindings specifies explicit interface to implementation type bindings which depinject uses to resolve interface inputs to provider functions. The scope of this field's configuration is module specific. description: ModuleConfig is a module configuration for an app. description: modules are the module configurations for the app. golang_bindings: type: array items: type: object properties: interface_type: type: string title: interface_type is the interface type which will be bound to a specific implementation type implementation: type: string title: implementation is the implementing type which will be supplied when an input of type interface is requested description: GolangBinding is an explicit interface type to implementing type binding for dependency injection. description: >- golang_bindings specifies explicit interface to implementation type bindings which depinject uses to resolve interface inputs to provider functions. The scope of this field's configuration is global (not module specific). description: >- Config represents the configuration for a Cosmos SDK ABCI app. It is intended that all state machine logic including the version of baseapp and tx handlers (and possibly even Tendermint) that an app needs can be described in a config object. For compatibility, the framework should allow a mixture of declarative and imperative app wiring, however, apps that strive for the maximum ease of maintainability should be able to describe their state machine with a config object alone. cosmos.app.v1alpha1.GolangBinding: type: object properties: interface_type: type: string title: interface_type is the interface type which will be bound to a specific implementation type implementation: type: string title: implementation is the implementing type which will be supplied when an input of type interface is requested description: GolangBinding is an explicit interface type to implementing type binding for dependency injection. cosmos.app.v1alpha1.ModuleConfig: type: object properties: name: type: string description: >- name is the unique name of the module within the app. It should be a name that persists between different versions of a module so that modules can be smoothly upgraded to new versions. For example, for the module cosmos.bank.module.v1.Module, we may chose to simply name the module "bank" in the app. When we upgrade to cosmos.bank.module.v2.Module, the app-specific name "bank" stays the same and the framework knows that the v2 module should receive all the same state that the v1 module had. Note: modules should provide info on which versions they can migrate from in the ModuleDescriptor.can_migration_from field. config: type: object properties: type_url: type: string value: type: string format: byte description: >- config is the config object for the module. Module config messages should define a ModuleDescriptor using the cosmos.app.v1alpha1.is_module extension. golang_bindings: type: array items: type: object properties: interface_type: type: string title: interface_type is the interface type which will be bound to a specific implementation type implementation: type: string title: implementation is the implementing type which will be supplied when an input of type interface is requested description: GolangBinding is an explicit interface type to implementing type binding for dependency injection. description: >- golang_bindings specifies explicit interface to implementation type bindings which depinject uses to resolve interface inputs to provider functions. The scope of this field's configuration is module specific. description: ModuleConfig is a module configuration for an app. cosmos.app.v1alpha1.QueryConfigResponse: type: object properties: config: description: config is the current app config. type: object properties: modules: type: array items: type: object properties: name: type: string description: >- name is the unique name of the module within the app. It should be a name that persists between different versions of a module so that modules can be smoothly upgraded to new versions. For example, for the module cosmos.bank.module.v1.Module, we may chose to simply name the module "bank" in the app. When we upgrade to cosmos.bank.module.v2.Module, the app-specific name "bank" stays the same and the framework knows that the v2 module should receive all the same state that the v1 module had. Note: modules should provide info on which versions they can migrate from in the ModuleDescriptor.can_migration_from field. config: type: object properties: type_url: type: string value: type: string format: byte description: >- config is the config object for the module. Module config messages should define a ModuleDescriptor using the cosmos.app.v1alpha1.is_module extension. golang_bindings: type: array items: type: object properties: interface_type: type: string title: interface_type is the interface type which will be bound to a specific implementation type implementation: type: string title: implementation is the implementing type which will be supplied when an input of type interface is requested description: GolangBinding is an explicit interface type to implementing type binding for dependency injection. description: >- golang_bindings specifies explicit interface to implementation type bindings which depinject uses to resolve interface inputs to provider functions. The scope of this field's configuration is module specific. description: ModuleConfig is a module configuration for an app. description: modules are the module configurations for the app. golang_bindings: type: array items: type: object properties: interface_type: type: string title: interface_type is the interface type which will be bound to a specific implementation type implementation: type: string title: implementation is the implementing type which will be supplied when an input of type interface is requested description: GolangBinding is an explicit interface type to implementing type binding for dependency injection. description: >- golang_bindings specifies explicit interface to implementation type bindings which depinject uses to resolve interface inputs to provider functions. The scope of this field's configuration is global (not module specific). description: QueryConfigRequest is the Query/Config response type. cosmwasm.wasm.v1.AbsoluteTxPosition: type: object properties: block_height: type: string format: uint64 title: BlockHeight is the block the contract was created at tx_index: type: string format: uint64 title: >- TxIndex is a monotonic counter within the block (actual transaction index, or gas consumed) description: >- AbsoluteTxPosition is a unique transaction position that allows for global ordering of transactions. cosmwasm.wasm.v1.AccessConfig: type: object properties: permission: type: string enum: - ACCESS_TYPE_UNSPECIFIED - ACCESS_TYPE_NOBODY - ACCESS_TYPE_EVERYBODY - ACCESS_TYPE_ANY_OF_ADDRESSES default: ACCESS_TYPE_UNSPECIFIED description: >- - ACCESS_TYPE_UNSPECIFIED: AccessTypeUnspecified placeholder for empty value - ACCESS_TYPE_NOBODY: AccessTypeNobody forbidden - ACCESS_TYPE_EVERYBODY: AccessTypeEverybody unrestricted - ACCESS_TYPE_ANY_OF_ADDRESSES: AccessTypeAnyOfAddresses allow any of the addresses title: AccessType permission types addresses: type: array items: type: string description: AccessConfig access control type. cosmwasm.wasm.v1.AccessType: type: string enum: - ACCESS_TYPE_UNSPECIFIED - ACCESS_TYPE_NOBODY - ACCESS_TYPE_EVERYBODY - ACCESS_TYPE_ANY_OF_ADDRESSES default: ACCESS_TYPE_UNSPECIFIED description: >- - ACCESS_TYPE_UNSPECIFIED: AccessTypeUnspecified placeholder for empty value - ACCESS_TYPE_NOBODY: AccessTypeNobody forbidden - ACCESS_TYPE_EVERYBODY: AccessTypeEverybody unrestricted - ACCESS_TYPE_ANY_OF_ADDRESSES: AccessTypeAnyOfAddresses allow any of the addresses title: AccessType permission types cosmwasm.wasm.v1.CodeInfoResponse: type: object properties: code_id: type: string format: uint64 creator: type: string data_hash: type: string format: byte instantiate_permission: type: object properties: permission: type: string enum: - ACCESS_TYPE_UNSPECIFIED - ACCESS_TYPE_NOBODY - ACCESS_TYPE_EVERYBODY - ACCESS_TYPE_ANY_OF_ADDRESSES default: ACCESS_TYPE_UNSPECIFIED description: >- - ACCESS_TYPE_UNSPECIFIED: AccessTypeUnspecified placeholder for empty value - ACCESS_TYPE_NOBODY: AccessTypeNobody forbidden - ACCESS_TYPE_EVERYBODY: AccessTypeEverybody unrestricted - ACCESS_TYPE_ANY_OF_ADDRESSES: AccessTypeAnyOfAddresses allow any of the addresses title: AccessType permission types addresses: type: array items: type: string description: AccessConfig access control type. title: CodeInfoResponse contains code meta data from CodeInfo cosmwasm.wasm.v1.ContractCodeHistoryEntry: type: object properties: operation: type: string enum: - CONTRACT_CODE_HISTORY_OPERATION_TYPE_UNSPECIFIED - CONTRACT_CODE_HISTORY_OPERATION_TYPE_INIT - CONTRACT_CODE_HISTORY_OPERATION_TYPE_MIGRATE - CONTRACT_CODE_HISTORY_OPERATION_TYPE_GENESIS default: CONTRACT_CODE_HISTORY_OPERATION_TYPE_UNSPECIFIED description: >- - CONTRACT_CODE_HISTORY_OPERATION_TYPE_UNSPECIFIED: ContractCodeHistoryOperationTypeUnspecified placeholder for empty value - CONTRACT_CODE_HISTORY_OPERATION_TYPE_INIT: ContractCodeHistoryOperationTypeInit on chain contract instantiation - CONTRACT_CODE_HISTORY_OPERATION_TYPE_MIGRATE: ContractCodeHistoryOperationTypeMigrate code migration - CONTRACT_CODE_HISTORY_OPERATION_TYPE_GENESIS: ContractCodeHistoryOperationTypeGenesis based on genesis data title: ContractCodeHistoryOperationType actions that caused a code change code_id: type: string format: uint64 title: CodeID is the reference to the stored WASM code updated: description: Updated Tx position when the operation was executed. type: object properties: block_height: type: string format: uint64 title: BlockHeight is the block the contract was created at tx_index: type: string format: uint64 title: >- TxIndex is a monotonic counter within the block (actual transaction index, or gas consumed) msg: type: string format: byte description: ContractCodeHistoryEntry metadata to a contract. cosmwasm.wasm.v1.ContractCodeHistoryOperationType: type: string enum: - CONTRACT_CODE_HISTORY_OPERATION_TYPE_UNSPECIFIED - CONTRACT_CODE_HISTORY_OPERATION_TYPE_INIT - CONTRACT_CODE_HISTORY_OPERATION_TYPE_MIGRATE - CONTRACT_CODE_HISTORY_OPERATION_TYPE_GENESIS default: CONTRACT_CODE_HISTORY_OPERATION_TYPE_UNSPECIFIED description: >- - CONTRACT_CODE_HISTORY_OPERATION_TYPE_UNSPECIFIED: ContractCodeHistoryOperationTypeUnspecified placeholder for empty value - CONTRACT_CODE_HISTORY_OPERATION_TYPE_INIT: ContractCodeHistoryOperationTypeInit on chain contract instantiation - CONTRACT_CODE_HISTORY_OPERATION_TYPE_MIGRATE: ContractCodeHistoryOperationTypeMigrate code migration - CONTRACT_CODE_HISTORY_OPERATION_TYPE_GENESIS: ContractCodeHistoryOperationTypeGenesis based on genesis data title: ContractCodeHistoryOperationType actions that caused a code change cosmwasm.wasm.v1.ContractInfo: type: object properties: code_id: type: string format: uint64 title: CodeID is the reference to the stored Wasm code creator: type: string title: Creator address who initially instantiated the contract admin: type: string title: Admin is an optional address that can execute migrations label: type: string description: Label is optional metadata to be stored with a contract instance. created: description: Created Tx position when the contract was instantiated. type: object properties: block_height: type: string format: uint64 title: BlockHeight is the block the contract was created at tx_index: type: string format: uint64 title: >- TxIndex is a monotonic counter within the block (actual transaction index, or gas consumed) ibc_port_id: type: string extension: type: object properties: type_url: type: string value: type: string format: byte description: |- Extension is an extension point to store custom metadata within the persistence model. title: ContractInfo stores a WASM contract instance cosmwasm.wasm.v1.Model: type: object properties: key: type: string format: byte title: hex-encode key to read it better (this is often ascii) value: type: string format: byte title: base64-encode raw value title: Model is a struct that holds a KV pair cosmwasm.wasm.v1.Params: type: object properties: code_upload_access: type: object properties: permission: type: string enum: - ACCESS_TYPE_UNSPECIFIED - ACCESS_TYPE_NOBODY - ACCESS_TYPE_EVERYBODY - ACCESS_TYPE_ANY_OF_ADDRESSES default: ACCESS_TYPE_UNSPECIFIED description: >- - ACCESS_TYPE_UNSPECIFIED: AccessTypeUnspecified placeholder for empty value - ACCESS_TYPE_NOBODY: AccessTypeNobody forbidden - ACCESS_TYPE_EVERYBODY: AccessTypeEverybody unrestricted - ACCESS_TYPE_ANY_OF_ADDRESSES: AccessTypeAnyOfAddresses allow any of the addresses title: AccessType permission types addresses: type: array items: type: string description: AccessConfig access control type. instantiate_default_permission: type: string enum: - ACCESS_TYPE_UNSPECIFIED - ACCESS_TYPE_NOBODY - ACCESS_TYPE_EVERYBODY - ACCESS_TYPE_ANY_OF_ADDRESSES default: ACCESS_TYPE_UNSPECIFIED description: >- - ACCESS_TYPE_UNSPECIFIED: AccessTypeUnspecified placeholder for empty value - ACCESS_TYPE_NOBODY: AccessTypeNobody forbidden - ACCESS_TYPE_EVERYBODY: AccessTypeEverybody unrestricted - ACCESS_TYPE_ANY_OF_ADDRESSES: AccessTypeAnyOfAddresses allow any of the addresses title: AccessType permission types description: Params defines the set of wasm parameters. cosmwasm.wasm.v1.QueryAllContractStateResponse: type: object properties: models: type: array items: type: object properties: key: type: string format: byte title: hex-encode key to read it better (this is often ascii) value: type: string format: byte title: base64-encode raw value title: Model is a struct that holds a KV pair pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: |- QueryAllContractStateResponse is the response type for the Query/AllContractState RPC method cosmwasm.wasm.v1.QueryCodeResponse: type: object properties: code_info: type: object properties: code_id: type: string format: uint64 creator: type: string data_hash: type: string format: byte instantiate_permission: type: object properties: permission: type: string enum: - ACCESS_TYPE_UNSPECIFIED - ACCESS_TYPE_NOBODY - ACCESS_TYPE_EVERYBODY - ACCESS_TYPE_ANY_OF_ADDRESSES default: ACCESS_TYPE_UNSPECIFIED description: >- - ACCESS_TYPE_UNSPECIFIED: AccessTypeUnspecified placeholder for empty value - ACCESS_TYPE_NOBODY: AccessTypeNobody forbidden - ACCESS_TYPE_EVERYBODY: AccessTypeEverybody unrestricted - ACCESS_TYPE_ANY_OF_ADDRESSES: AccessTypeAnyOfAddresses allow any of the addresses title: AccessType permission types addresses: type: array items: type: string description: AccessConfig access control type. title: CodeInfoResponse contains code meta data from CodeInfo data: type: string format: byte title: QueryCodeResponse is the response type for the Query/Code RPC method cosmwasm.wasm.v1.QueryCodesResponse: type: object properties: code_infos: type: array items: type: object properties: code_id: type: string format: uint64 creator: type: string data_hash: type: string format: byte instantiate_permission: type: object properties: permission: type: string enum: - ACCESS_TYPE_UNSPECIFIED - ACCESS_TYPE_NOBODY - ACCESS_TYPE_EVERYBODY - ACCESS_TYPE_ANY_OF_ADDRESSES default: ACCESS_TYPE_UNSPECIFIED description: >- - ACCESS_TYPE_UNSPECIFIED: AccessTypeUnspecified placeholder for empty value - ACCESS_TYPE_NOBODY: AccessTypeNobody forbidden - ACCESS_TYPE_EVERYBODY: AccessTypeEverybody unrestricted - ACCESS_TYPE_ANY_OF_ADDRESSES: AccessTypeAnyOfAddresses allow any of the addresses title: AccessType permission types addresses: type: array items: type: string description: AccessConfig access control type. title: CodeInfoResponse contains code meta data from CodeInfo pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: QueryCodesResponse is the response type for the Query/Codes RPC method cosmwasm.wasm.v1.QueryContractHistoryResponse: type: object properties: entries: type: array items: type: object properties: operation: type: string enum: - CONTRACT_CODE_HISTORY_OPERATION_TYPE_UNSPECIFIED - CONTRACT_CODE_HISTORY_OPERATION_TYPE_INIT - CONTRACT_CODE_HISTORY_OPERATION_TYPE_MIGRATE - CONTRACT_CODE_HISTORY_OPERATION_TYPE_GENESIS default: CONTRACT_CODE_HISTORY_OPERATION_TYPE_UNSPECIFIED description: >- - CONTRACT_CODE_HISTORY_OPERATION_TYPE_UNSPECIFIED: ContractCodeHistoryOperationTypeUnspecified placeholder for empty value - CONTRACT_CODE_HISTORY_OPERATION_TYPE_INIT: ContractCodeHistoryOperationTypeInit on chain contract instantiation - CONTRACT_CODE_HISTORY_OPERATION_TYPE_MIGRATE: ContractCodeHistoryOperationTypeMigrate code migration - CONTRACT_CODE_HISTORY_OPERATION_TYPE_GENESIS: ContractCodeHistoryOperationTypeGenesis based on genesis data title: ContractCodeHistoryOperationType actions that caused a code change code_id: type: string format: uint64 title: CodeID is the reference to the stored WASM code updated: description: Updated Tx position when the operation was executed. type: object properties: block_height: type: string format: uint64 title: BlockHeight is the block the contract was created at tx_index: type: string format: uint64 title: >- TxIndex is a monotonic counter within the block (actual transaction index, or gas consumed) msg: type: string format: byte description: ContractCodeHistoryEntry metadata to a contract. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: |- QueryContractHistoryResponse is the response type for the Query/ContractHistory RPC method cosmwasm.wasm.v1.QueryContractInfoResponse: type: object properties: address: type: string title: address is the address of the contract contract_info: type: object properties: code_id: type: string format: uint64 title: CodeID is the reference to the stored Wasm code creator: type: string title: Creator address who initially instantiated the contract admin: type: string title: Admin is an optional address that can execute migrations label: type: string description: Label is optional metadata to be stored with a contract instance. created: description: Created Tx position when the contract was instantiated. type: object properties: block_height: type: string format: uint64 title: BlockHeight is the block the contract was created at tx_index: type: string format: uint64 title: >- TxIndex is a monotonic counter within the block (actual transaction index, or gas consumed) ibc_port_id: type: string extension: type: object properties: type_url: type: string value: type: string format: byte description: >- Extension is an extension point to store custom metadata within the persistence model. title: ContractInfo stores a WASM contract instance title: >- QueryContractInfoResponse is the response type for the Query/ContractInfo RPC method cosmwasm.wasm.v1.QueryContractsByCodeResponse: type: object properties: contracts: type: array items: type: string title: contracts are a set of contract addresses pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: |- QueryContractsByCodeResponse is the response type for the Query/ContractsByCode RPC method cosmwasm.wasm.v1.QueryContractsByCreatorResponse: type: object properties: contract_addresses: type: array items: type: string title: ContractAddresses result set pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: |- QueryContractsByCreatorResponse is the response type for the Query/ContractsByCreator RPC method. cosmwasm.wasm.v1.QueryParamsResponse: type: object properties: params: description: params defines the parameters of the module. type: object properties: code_upload_access: type: object properties: permission: type: string enum: - ACCESS_TYPE_UNSPECIFIED - ACCESS_TYPE_NOBODY - ACCESS_TYPE_EVERYBODY - ACCESS_TYPE_ANY_OF_ADDRESSES default: ACCESS_TYPE_UNSPECIFIED description: >- - ACCESS_TYPE_UNSPECIFIED: AccessTypeUnspecified placeholder for empty value - ACCESS_TYPE_NOBODY: AccessTypeNobody forbidden - ACCESS_TYPE_EVERYBODY: AccessTypeEverybody unrestricted - ACCESS_TYPE_ANY_OF_ADDRESSES: AccessTypeAnyOfAddresses allow any of the addresses title: AccessType permission types addresses: type: array items: type: string description: AccessConfig access control type. instantiate_default_permission: type: string enum: - ACCESS_TYPE_UNSPECIFIED - ACCESS_TYPE_NOBODY - ACCESS_TYPE_EVERYBODY - ACCESS_TYPE_ANY_OF_ADDRESSES default: ACCESS_TYPE_UNSPECIFIED description: >- - ACCESS_TYPE_UNSPECIFIED: AccessTypeUnspecified placeholder for empty value - ACCESS_TYPE_NOBODY: AccessTypeNobody forbidden - ACCESS_TYPE_EVERYBODY: AccessTypeEverybody unrestricted - ACCESS_TYPE_ANY_OF_ADDRESSES: AccessTypeAnyOfAddresses allow any of the addresses title: AccessType permission types description: QueryParamsResponse is the response type for the Query/Params RPC method. cosmwasm.wasm.v1.QueryPinnedCodesResponse: type: object properties: code_ids: type: array items: type: string format: uint64 pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: |- QueryPinnedCodesResponse is the response type for the Query/PinnedCodes RPC method cosmwasm.wasm.v1.QueryRawContractStateResponse: type: object properties: data: type: string format: byte title: Data contains the raw store data title: |- QueryRawContractStateResponse is the response type for the Query/RawContractState RPC method cosmwasm.wasm.v1.QuerySmartContractStateResponse: type: object properties: data: type: string format: byte title: Data contains the json data returned from the smart contract title: |- QuerySmartContractStateResponse is the response type for the Query/SmartContractState RPC method cyber.bandwidth.v1beta1.NeuronBandwidth: type: object properties: neuron: type: string remained_value: type: string format: uint64 last_updated_block: type: string format: uint64 max_value: type: string format: uint64 cyber.bandwidth.v1beta1.Params: type: object properties: recovery_period: type: string format: uint64 adjust_price_period: type: string format: uint64 base_price: type: string base_load: type: string max_block_bandwidth: type: string format: uint64 cyber.bandwidth.v1beta1.QueryLoadResponse: type: object properties: load: type: string cyber.bandwidth.v1beta1.QueryNeuronBandwidthResponse: type: object properties: neuron_bandwidth: type: object properties: neuron: type: string remained_value: type: string format: uint64 last_updated_block: type: string format: uint64 max_value: type: string format: uint64 cyber.bandwidth.v1beta1.QueryParamsResponse: type: object properties: params: type: object properties: recovery_period: type: string format: uint64 adjust_price_period: type: string format: uint64 base_price: type: string base_load: type: string max_block_bandwidth: type: string format: uint64 cyber.bandwidth.v1beta1.QueryPriceResponse: type: object properties: price: type: string cyber.bandwidth.v1beta1.QueryTotalBandwidthResponse: type: object properties: total_bandwidth: type: string format: uint64 cosmos.base.tendermint.v1beta1.ABCIQueryResponse: type: object properties: code: type: integer format: int64 log: type: string info: type: string index: type: string format: int64 key: type: string format: byte value: type: string format: byte proof_ops: type: object properties: ops: type: array items: type: object properties: type: type: string key: type: string format: byte data: type: string format: byte description: >- ProofOp defines an operation used for calculating Merkle root. The data could be arbitrary format, providing necessary data for example neighbouring node hash. Note: This type is a duplicate of the ProofOp proto type defined in Tendermint. description: >- ProofOps is Merkle proof defined by the list of ProofOps. Note: This type is a duplicate of the ProofOps proto type defined in Tendermint. height: type: string format: int64 codespace: type: string description: >- ABCIQueryResponse defines the response structure for the ABCIQuery gRPC query. Note: This type is a duplicate of the ResponseQuery proto type defined in Tendermint. cosmos.base.tendermint.v1beta1.Block: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string description: >- proposer_address is the original block proposer address, formatted as a Bech32 string. In Tendermint, this type is `bytes`, but in the SDK, we convert it to a Bech32 string for better UX. description: Header defines the structure of a Tendermint block header. data: type: object properties: txs: type: array items: type: string format: byte description: >- Txs that will be applied by state @ block.Height+1. NOTE: not all txs here are valid. We're just agreeing on the order first. This means that block.AppHash does not include these txs. title: Data contains the set of transactions included in the block evidence: type: object properties: evidence: type: array items: type: object properties: duplicate_vote_evidence: type: object properties: vote_a: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. vote_b: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. total_voting_power: type: string format: int64 validator_power: type: string format: int64 timestamp: type: string format: date-time description: DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes. light_client_attack_evidence: type: object properties: conflicting_block: type: object properties: signed_header: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: Commit contains the evidence that a block was committed by a set of validators. validator_set: type: object properties: validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 proposer: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 common_height: type: string format: int64 byzantine_validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 timestamp: type: string format: date-time description: LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client. last_commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: Commit contains the evidence that a block was committed by a set of validators. description: |- Block is tendermint type Block, with the Header proposer address field converted to bech32 string. cosmos.base.tendermint.v1beta1.GetBlockByHeightResponse: type: object properties: block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID block: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. data: type: object properties: txs: type: array items: type: string format: byte description: >- Txs that will be applied by state @ block.Height+1. NOTE: not all txs here are valid. We're just agreeing on the order first. This means that block.AppHash does not include these txs. title: Data contains the set of transactions included in the block evidence: type: object properties: evidence: type: array items: type: object properties: duplicate_vote_evidence: type: object properties: vote_a: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. vote_b: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. total_voting_power: type: string format: int64 validator_power: type: string format: int64 timestamp: type: string format: date-time description: DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes. light_client_attack_evidence: type: object properties: conflicting_block: type: object properties: signed_header: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: Commit contains the evidence that a block was committed by a set of validators. validator_set: type: object properties: validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 proposer: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 common_height: type: string format: int64 byzantine_validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 timestamp: type: string format: date-time description: LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client. last_commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: Commit contains the evidence that a block was committed by a set of validators. title: "Deprecated: please use `sdk_block` instead" sdk_block: title: "Since: cosmos-sdk 0.47" type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string description: >- proposer_address is the original block proposer address, formatted as a Bech32 string. In Tendermint, this type is `bytes`, but in the SDK, we convert it to a Bech32 string for better UX. description: Header defines the structure of a Tendermint block header. data: type: object properties: txs: type: array items: type: string format: byte description: >- Txs that will be applied by state @ block.Height+1. NOTE: not all txs here are valid. We're just agreeing on the order first. This means that block.AppHash does not include these txs. title: Data contains the set of transactions included in the block evidence: type: object properties: evidence: type: array items: type: object properties: duplicate_vote_evidence: type: object properties: vote_a: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. vote_b: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. total_voting_power: type: string format: int64 validator_power: type: string format: int64 timestamp: type: string format: date-time description: DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes. light_client_attack_evidence: type: object properties: conflicting_block: type: object properties: signed_header: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: Commit contains the evidence that a block was committed by a set of validators. validator_set: type: object properties: validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 proposer: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 common_height: type: string format: int64 byzantine_validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 timestamp: type: string format: date-time description: LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client. last_commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: Commit contains the evidence that a block was committed by a set of validators. description: |- Block is tendermint type Block, with the Header proposer address field converted to bech32 string. description: GetBlockByHeightResponse is the response type for the Query/GetBlockByHeight RPC method. cosmos.base.tendermint.v1beta1.GetLatestBlockResponse: type: object properties: block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID block: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. data: type: object properties: txs: type: array items: type: string format: byte description: >- Txs that will be applied by state @ block.Height+1. NOTE: not all txs here are valid. We're just agreeing on the order first. This means that block.AppHash does not include these txs. title: Data contains the set of transactions included in the block evidence: type: object properties: evidence: type: array items: type: object properties: duplicate_vote_evidence: type: object properties: vote_a: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. vote_b: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. total_voting_power: type: string format: int64 validator_power: type: string format: int64 timestamp: type: string format: date-time description: DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes. light_client_attack_evidence: type: object properties: conflicting_block: type: object properties: signed_header: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: Commit contains the evidence that a block was committed by a set of validators. validator_set: type: object properties: validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 proposer: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 common_height: type: string format: int64 byzantine_validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 timestamp: type: string format: date-time description: LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client. last_commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: Commit contains the evidence that a block was committed by a set of validators. title: "Deprecated: please use `sdk_block` instead" sdk_block: title: "Since: cosmos-sdk 0.47" type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string description: >- proposer_address is the original block proposer address, formatted as a Bech32 string. In Tendermint, this type is `bytes`, but in the SDK, we convert it to a Bech32 string for better UX. description: Header defines the structure of a Tendermint block header. data: type: object properties: txs: type: array items: type: string format: byte description: >- Txs that will be applied by state @ block.Height+1. NOTE: not all txs here are valid. We're just agreeing on the order first. This means that block.AppHash does not include these txs. title: Data contains the set of transactions included in the block evidence: type: object properties: evidence: type: array items: type: object properties: duplicate_vote_evidence: type: object properties: vote_a: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. vote_b: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. total_voting_power: type: string format: int64 validator_power: type: string format: int64 timestamp: type: string format: date-time description: DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes. light_client_attack_evidence: type: object properties: conflicting_block: type: object properties: signed_header: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: Commit contains the evidence that a block was committed by a set of validators. validator_set: type: object properties: validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 proposer: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 common_height: type: string format: int64 byzantine_validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 timestamp: type: string format: date-time description: LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client. last_commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: Commit contains the evidence that a block was committed by a set of validators. description: |- Block is tendermint type Block, with the Header proposer address field converted to bech32 string. description: GetLatestBlockResponse is the response type for the Query/GetLatestBlock RPC method. cosmos.base.tendermint.v1beta1.GetLatestValidatorSetResponse: type: object properties: block_height: type: string format: int64 validators: type: array items: type: object properties: address: type: string pub_key: type: object properties: type_url: type: string value: type: string format: byte voting_power: type: string format: int64 proposer_priority: type: string format: int64 description: Validator is the type for the validator-set. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: GetLatestValidatorSetResponse is the response type for the Query/GetValidatorSetByHeight RPC method. cosmos.base.tendermint.v1beta1.GetNodeInfoResponse: type: object properties: default_node_info: type: object properties: protocol_version: type: object properties: p2p: type: string format: uint64 block: type: string format: uint64 app: type: string format: uint64 default_node_id: type: string listen_addr: type: string network: type: string version: type: string channels: type: string format: byte moniker: type: string other: type: object properties: tx_index: type: string rpc_address: type: string application_version: type: object properties: name: type: string app_name: type: string version: type: string git_commit: type: string build_tags: type: string go_version: type: string build_deps: type: array items: type: object properties: path: type: string title: module path version: type: string title: module version sum: type: string title: checksum title: Module is the type for VersionInfo cosmos_sdk_version: type: string title: "Since: cosmos-sdk 0.43" description: VersionInfo is the type for the GetNodeInfoResponse message. description: GetNodeInfoResponse is the response type for the Query/GetNodeInfo RPC method. cosmos.base.tendermint.v1beta1.GetSyncingResponse: type: object properties: syncing: type: boolean description: GetSyncingResponse is the response type for the Query/GetSyncing RPC method. cosmos.base.tendermint.v1beta1.GetValidatorSetByHeightResponse: type: object properties: block_height: type: string format: int64 validators: type: array items: type: object properties: address: type: string pub_key: type: object properties: type_url: type: string value: type: string format: byte voting_power: type: string format: int64 proposer_priority: type: string format: int64 description: Validator is the type for the validator-set. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: GetValidatorSetByHeightResponse is the response type for the Query/GetValidatorSetByHeight RPC method. cosmos.base.tendermint.v1beta1.Header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string description: >- proposer_address is the original block proposer address, formatted as a Bech32 string. In Tendermint, this type is `bytes`, but in the SDK, we convert it to a Bech32 string for better UX. description: Header defines the structure of a Tendermint block header. cosmos.base.tendermint.v1beta1.Module: type: object properties: path: type: string title: module path version: type: string title: module version sum: type: string title: checksum title: Module is the type for VersionInfo cosmos.base.tendermint.v1beta1.ProofOp: type: object properties: type: type: string key: type: string format: byte data: type: string format: byte description: >- ProofOp defines an operation used for calculating Merkle root. The data could be arbitrary format, providing necessary data for example neighbouring node hash. Note: This type is a duplicate of the ProofOp proto type defined in Tendermint. cosmos.base.tendermint.v1beta1.ProofOps: type: object properties: ops: type: array items: type: object properties: type: type: string key: type: string format: byte data: type: string format: byte description: >- ProofOp defines an operation used for calculating Merkle root. The data could be arbitrary format, providing necessary data for example neighbouring node hash. Note: This type is a duplicate of the ProofOp proto type defined in Tendermint. description: >- ProofOps is Merkle proof defined by the list of ProofOps. Note: This type is a duplicate of the ProofOps proto type defined in Tendermint. cosmos.base.tendermint.v1beta1.Validator: type: object properties: address: type: string pub_key: type: object properties: type_url: type: string value: type: string format: byte voting_power: type: string format: int64 proposer_priority: type: string format: int64 description: Validator is the type for the validator-set. cosmos.base.tendermint.v1beta1.VersionInfo: type: object properties: name: type: string app_name: type: string version: type: string git_commit: type: string build_tags: type: string go_version: type: string build_deps: type: array items: type: object properties: path: type: string title: module path version: type: string title: module version sum: type: string title: checksum title: Module is the type for VersionInfo cosmos_sdk_version: type: string title: "Since: cosmos-sdk 0.43" description: VersionInfo is the type for the GetNodeInfoResponse message. tendermint.p2p.DefaultNodeInfo: type: object properties: protocol_version: type: object properties: p2p: type: string format: uint64 block: type: string format: uint64 app: type: string format: uint64 default_node_id: type: string listen_addr: type: string network: type: string version: type: string channels: type: string format: byte moniker: type: string other: type: object properties: tx_index: type: string rpc_address: type: string tendermint.p2p.DefaultNodeInfoOther: type: object properties: tx_index: type: string rpc_address: type: string tendermint.p2p.ProtocolVersion: type: object properties: p2p: type: string format: uint64 block: type: string format: uint64 app: type: string format: uint64 cosmos.slashing.v1beta1.Params: type: object properties: signed_blocks_window: type: string format: int64 min_signed_per_window: type: string format: byte downtime_jail_duration: type: string slash_fraction_double_sign: type: string format: byte slash_fraction_downtime: type: string format: byte description: Params represents the parameters used for by the slashing module. cosmos.slashing.v1beta1.QueryParamsResponse: type: object properties: params: type: object properties: signed_blocks_window: type: string format: int64 min_signed_per_window: type: string format: byte downtime_jail_duration: type: string slash_fraction_double_sign: type: string format: byte slash_fraction_downtime: type: string format: byte description: Params represents the parameters used for by the slashing module. title: QueryParamsResponse is the response type for the Query/Params RPC method cosmos.slashing.v1beta1.QuerySigningInfoResponse: type: object properties: val_signing_info: type: object properties: address: type: string start_height: type: string format: int64 title: Height at which validator was first a candidate OR was unjailed index_offset: type: string format: int64 description: >- Index which is incremented each time the validator was a bonded in a block and may have signed a precommit or not. This in conjunction with the `SignedBlocksWindow` param determines the index in the `MissedBlocksBitArray`. jailed_until: type: string format: date-time description: Timestamp until which the validator is jailed due to liveness downtime. tombstoned: type: boolean description: >- Whether or not a validator has been tombstoned (killed out of validator set). It is set once the validator commits an equivocation or for any other configured misbehiavor. missed_blocks_counter: type: string format: int64 description: >- A counter kept to avoid unnecessary array reads. Note that `Sum(MissedBlocksBitArray)` always equals `MissedBlocksCounter`. description: >- ValidatorSigningInfo defines a validator's signing info for monitoring their liveness activity. title: val_signing_info is the signing info of requested val cons address title: >- QuerySigningInfoResponse is the response type for the Query/SigningInfo RPC method cosmos.slashing.v1beta1.QuerySigningInfosResponse: type: object properties: info: type: array items: type: object properties: address: type: string start_height: type: string format: int64 title: Height at which validator was first a candidate OR was unjailed index_offset: type: string format: int64 description: >- Index which is incremented each time the validator was a bonded in a block and may have signed a precommit or not. This in conjunction with the `SignedBlocksWindow` param determines the index in the `MissedBlocksBitArray`. jailed_until: type: string format: date-time description: Timestamp until which the validator is jailed due to liveness downtime. tombstoned: type: boolean description: >- Whether or not a validator has been tombstoned (killed out of validator set). It is set once the validator commits an equivocation or for any other configured misbehiavor. missed_blocks_counter: type: string format: int64 description: >- A counter kept to avoid unnecessary array reads. Note that `Sum(MissedBlocksBitArray)` always equals `MissedBlocksCounter`. description: >- ValidatorSigningInfo defines a validator's signing info for monitoring their liveness activity. title: info is the signing info of all validators pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: >- QuerySigningInfosResponse is the response type for the Query/SigningInfos RPC method cosmos.slashing.v1beta1.ValidatorSigningInfo: type: object properties: address: type: string start_height: type: string format: int64 title: Height at which validator was first a candidate OR was unjailed index_offset: type: string format: int64 description: >- Index which is incremented each time the validator was a bonded in a block and may have signed a precommit or not. This in conjunction with the `SignedBlocksWindow` param determines the index in the `MissedBlocksBitArray`. jailed_until: type: string format: date-time description: Timestamp until which the validator is jailed due to liveness downtime. tombstoned: type: boolean description: >- Whether or not a validator has been tombstoned (killed out of validator set). It is set once the validator commits an equivocation or for any other configured misbehiavor. missed_blocks_counter: type: string format: int64 description: >- A counter kept to avoid unnecessary array reads. Note that `Sum(MissedBlocksBitArray)` always equals `MissedBlocksCounter`. description: >- ValidatorSigningInfo defines a validator's signing info for monitoring their liveness activity. cosmos.gov.v1beta1.Deposit: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. depositor: type: string description: depositor defines the deposit addresses from the proposals. amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: amount to be deposited by depositor. description: |- Deposit defines an amount deposited by an account address to an active proposal. cosmos.gov.v1beta1.DepositParams: type: object properties: min_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: Minimum deposit for a proposal to enter voting period. max_deposit_period: type: string description: >- Maximum period for Atom holders to deposit on a proposal. Initial value: 2 months. description: DepositParams defines the params for deposits on governance proposals. cosmos.gov.v1beta1.Proposal: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. content: type: object properties: type_url: type: string value: type: string format: byte description: content is the proposal's content. status: description: status defines the proposal status. type: string enum: - PROPOSAL_STATUS_UNSPECIFIED - PROPOSAL_STATUS_DEPOSIT_PERIOD - PROPOSAL_STATUS_VOTING_PERIOD - PROPOSAL_STATUS_PASSED - PROPOSAL_STATUS_REJECTED - PROPOSAL_STATUS_FAILED default: PROPOSAL_STATUS_UNSPECIFIED final_tally_result: description: |- final_tally_result is the final tally result of the proposal. When querying a proposal via gRPC, this field is not populated until the proposal's voting period has ended. type: object properties: yes: type: string description: yes is the number of yes votes on a proposal. abstain: type: string description: abstain is the number of abstain votes on a proposal. no: type: string description: no is the number of no votes on a proposal. no_with_veto: type: string description: no_with_veto is the number of no with veto votes on a proposal. submit_time: type: string format: date-time description: submit_time is the time of proposal submission. deposit_end_time: type: string format: date-time description: deposit_end_time is the end time for deposition. total_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: total_deposit is the total deposit on the proposal. voting_start_time: type: string format: date-time description: voting_start_time is the starting time to vote on a proposal. voting_end_time: type: string format: date-time description: voting_end_time is the end time of voting on a proposal. description: Proposal defines the core field members of a governance proposal. cosmos.gov.v1beta1.ProposalStatus: type: string enum: - PROPOSAL_STATUS_UNSPECIFIED - PROPOSAL_STATUS_DEPOSIT_PERIOD - PROPOSAL_STATUS_VOTING_PERIOD - PROPOSAL_STATUS_PASSED - PROPOSAL_STATUS_REJECTED - PROPOSAL_STATUS_FAILED default: PROPOSAL_STATUS_UNSPECIFIED description: >- ProposalStatus enumerates the valid statuses of a proposal. - PROPOSAL_STATUS_UNSPECIFIED: PROPOSAL_STATUS_UNSPECIFIED defines the default proposal status. - PROPOSAL_STATUS_DEPOSIT_PERIOD: PROPOSAL_STATUS_DEPOSIT_PERIOD defines a proposal status during the deposit period. - PROPOSAL_STATUS_VOTING_PERIOD: PROPOSAL_STATUS_VOTING_PERIOD defines a proposal status during the voting period. - PROPOSAL_STATUS_PASSED: PROPOSAL_STATUS_PASSED defines a proposal status of a proposal that has passed. - PROPOSAL_STATUS_REJECTED: PROPOSAL_STATUS_REJECTED defines a proposal status of a proposal that has been rejected. - PROPOSAL_STATUS_FAILED: PROPOSAL_STATUS_FAILED defines a proposal status of a proposal that has failed. cosmos.gov.v1beta1.QueryDepositResponse: type: object properties: deposit: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. depositor: type: string description: depositor defines the deposit addresses from the proposals. amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: amount to be deposited by depositor. description: >- Deposit defines an amount deposited by an account address to an active proposal. description: QueryDepositResponse is the response type for the Query/Deposit RPC method. cosmos.gov.v1beta1.QueryDepositsResponse: type: object properties: deposits: type: array items: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. depositor: type: string description: depositor defines the deposit addresses from the proposals. amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: amount to be deposited by depositor. description: >- Deposit defines an amount deposited by an account address to an active proposal. description: deposits defines the requested deposits. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: QueryDepositsResponse is the response type for the Query/Deposits RPC method. cosmos.gov.v1beta1.QueryParamsResponse: type: object properties: voting_params: description: voting_params defines the parameters related to voting. type: object properties: voting_period: type: string description: Duration of the voting period. deposit_params: description: deposit_params defines the parameters related to deposit. type: object properties: min_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: Minimum deposit for a proposal to enter voting period. max_deposit_period: type: string description: >- Maximum period for Atom holders to deposit on a proposal. Initial value: 2 months. tally_params: description: tally_params defines the parameters related to tally. type: object properties: quorum: type: string format: byte description: >- Minimum percentage of total stake needed to vote for a result to be considered valid. threshold: type: string format: byte description: "Minimum proportion of Yes votes for proposal to pass. Default value: 0.5." veto_threshold: type: string format: byte description: >- Minimum value of Veto votes to Total votes ratio for proposal to be vetoed. Default value: 1/3. description: QueryParamsResponse is the response type for the Query/Params RPC method. cosmos.gov.v1beta1.QueryProposalResponse: type: object properties: proposal: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. content: type: object properties: type_url: type: string value: type: string format: byte description: content is the proposal's content. status: description: status defines the proposal status. type: string enum: - PROPOSAL_STATUS_UNSPECIFIED - PROPOSAL_STATUS_DEPOSIT_PERIOD - PROPOSAL_STATUS_VOTING_PERIOD - PROPOSAL_STATUS_PASSED - PROPOSAL_STATUS_REJECTED - PROPOSAL_STATUS_FAILED default: PROPOSAL_STATUS_UNSPECIFIED final_tally_result: description: >- final_tally_result is the final tally result of the proposal. When querying a proposal via gRPC, this field is not populated until the proposal's voting period has ended. type: object properties: yes: type: string description: yes is the number of yes votes on a proposal. abstain: type: string description: abstain is the number of abstain votes on a proposal. no: type: string description: no is the number of no votes on a proposal. no_with_veto: type: string description: no_with_veto is the number of no with veto votes on a proposal. submit_time: type: string format: date-time description: submit_time is the time of proposal submission. deposit_end_time: type: string format: date-time description: deposit_end_time is the end time for deposition. total_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: total_deposit is the total deposit on the proposal. voting_start_time: type: string format: date-time description: voting_start_time is the starting time to vote on a proposal. voting_end_time: type: string format: date-time description: voting_end_time is the end time of voting on a proposal. description: Proposal defines the core field members of a governance proposal. description: QueryProposalResponse is the response type for the Query/Proposal RPC method. cosmos.gov.v1beta1.QueryProposalsResponse: type: object properties: proposals: type: array items: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. content: type: object properties: type_url: type: string value: type: string format: byte description: content is the proposal's content. status: description: status defines the proposal status. type: string enum: - PROPOSAL_STATUS_UNSPECIFIED - PROPOSAL_STATUS_DEPOSIT_PERIOD - PROPOSAL_STATUS_VOTING_PERIOD - PROPOSAL_STATUS_PASSED - PROPOSAL_STATUS_REJECTED - PROPOSAL_STATUS_FAILED default: PROPOSAL_STATUS_UNSPECIFIED final_tally_result: description: >- final_tally_result is the final tally result of the proposal. When querying a proposal via gRPC, this field is not populated until the proposal's voting period has ended. type: object properties: yes: type: string description: yes is the number of yes votes on a proposal. abstain: type: string description: abstain is the number of abstain votes on a proposal. no: type: string description: no is the number of no votes on a proposal. no_with_veto: type: string description: no_with_veto is the number of no with veto votes on a proposal. submit_time: type: string format: date-time description: submit_time is the time of proposal submission. deposit_end_time: type: string format: date-time description: deposit_end_time is the end time for deposition. total_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: total_deposit is the total deposit on the proposal. voting_start_time: type: string format: date-time description: voting_start_time is the starting time to vote on a proposal. voting_end_time: type: string format: date-time description: voting_end_time is the end time of voting on a proposal. description: Proposal defines the core field members of a governance proposal. description: proposals defines all the requested governance proposals. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: |- QueryProposalsResponse is the response type for the Query/Proposals RPC method. cosmos.gov.v1beta1.QueryTallyResultResponse: type: object properties: tally: description: tally defines the requested tally. type: object properties: yes: type: string description: yes is the number of yes votes on a proposal. abstain: type: string description: abstain is the number of abstain votes on a proposal. no: type: string description: no is the number of no votes on a proposal. no_with_veto: type: string description: no_with_veto is the number of no with veto votes on a proposal. description: QueryTallyResultResponse is the response type for the Query/Tally RPC method. cosmos.gov.v1beta1.QueryVoteResponse: type: object properties: vote: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. voter: type: string description: voter is the voter address of the proposal. option: description: >- Deprecated: Prefer to use `options` instead. This field is set in queries if and only if `len(options) == 1` and that option has weight 1. In all other cases, this field will default to VOTE_OPTION_UNSPECIFIED. type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED options: type: array items: type: object properties: option: description: option defines the valid vote options, it must not contain duplicate vote options. type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED weight: type: string description: weight is the vote weight associated with the vote option. description: |- WeightedVoteOption defines a unit of vote for vote split. Since: cosmos-sdk 0.43 description: |- options is the weighted vote options. Since: cosmos-sdk 0.43 description: |- Vote defines a vote on a governance proposal. A Vote consists of a proposal ID, the voter, and the vote option. description: QueryVoteResponse is the response type for the Query/Vote RPC method. cosmos.gov.v1beta1.QueryVotesResponse: type: object properties: votes: type: array items: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. voter: type: string description: voter is the voter address of the proposal. option: description: >- Deprecated: Prefer to use `options` instead. This field is set in queries if and only if `len(options) == 1` and that option has weight 1. In all other cases, this field will default to VOTE_OPTION_UNSPECIFIED. type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED options: type: array items: type: object properties: option: description: option defines the valid vote options, it must not contain duplicate vote options. type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED weight: type: string description: weight is the vote weight associated with the vote option. description: |- WeightedVoteOption defines a unit of vote for vote split. Since: cosmos-sdk 0.43 description: |- options is the weighted vote options. Since: cosmos-sdk 0.43 description: |- Vote defines a vote on a governance proposal. A Vote consists of a proposal ID, the voter, and the vote option. description: votes defines the queried votes. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: QueryVotesResponse is the response type for the Query/Votes RPC method. cosmos.gov.v1beta1.TallyParams: type: object properties: quorum: type: string format: byte description: |- Minimum percentage of total stake needed to vote for a result to be considered valid. threshold: type: string format: byte description: "Minimum proportion of Yes votes for proposal to pass. Default value: 0.5." veto_threshold: type: string format: byte description: |- Minimum value of Veto votes to Total votes ratio for proposal to be vetoed. Default value: 1/3. description: TallyParams defines the params for tallying votes on governance proposals. cosmos.gov.v1beta1.TallyResult: type: object properties: yes: type: string description: yes is the number of yes votes on a proposal. abstain: type: string description: abstain is the number of abstain votes on a proposal. no: type: string description: no is the number of no votes on a proposal. no_with_veto: type: string description: no_with_veto is the number of no with veto votes on a proposal. description: TallyResult defines a standard tally for a governance proposal. cosmos.gov.v1beta1.Vote: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. voter: type: string description: voter is the voter address of the proposal. option: description: >- Deprecated: Prefer to use `options` instead. This field is set in queries if and only if `len(options) == 1` and that option has weight 1. In all other cases, this field will default to VOTE_OPTION_UNSPECIFIED. type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED options: type: array items: type: object properties: option: description: option defines the valid vote options, it must not contain duplicate vote options. type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED weight: type: string description: weight is the vote weight associated with the vote option. description: |- WeightedVoteOption defines a unit of vote for vote split. Since: cosmos-sdk 0.43 description: |- options is the weighted vote options. Since: cosmos-sdk 0.43 description: |- Vote defines a vote on a governance proposal. A Vote consists of a proposal ID, the voter, and the vote option. cosmos.gov.v1beta1.VoteOption: type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED description: >- VoteOption enumerates the valid vote options for a given governance proposal. - VOTE_OPTION_UNSPECIFIED: VOTE_OPTION_UNSPECIFIED defines a no-op vote option. - VOTE_OPTION_YES: VOTE_OPTION_YES defines a yes vote option. - VOTE_OPTION_ABSTAIN: VOTE_OPTION_ABSTAIN defines an abstain vote option. - VOTE_OPTION_NO: VOTE_OPTION_NO defines a no vote option. - VOTE_OPTION_NO_WITH_VETO: VOTE_OPTION_NO_WITH_VETO defines a no with veto vote option. cosmos.gov.v1beta1.VotingParams: type: object properties: voting_period: type: string description: Duration of the voting period. description: VotingParams defines the params for voting on governance proposals. cosmos.gov.v1beta1.WeightedVoteOption: type: object properties: option: description: option defines the valid vote options, it must not contain duplicate vote options. type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED weight: type: string description: weight is the vote weight associated with the vote option. description: |- WeightedVoteOption defines a unit of vote for vote split. Since: cosmos-sdk 0.43 cosmos.mint.v1beta1.Params: type: object properties: mint_denom: type: string title: type of coin to mint inflation_rate_change: type: string title: maximum annual change in inflation rate inflation_max: type: string title: maximum inflation rate inflation_min: type: string title: minimum inflation rate goal_bonded: type: string title: goal of percent bonded atoms blocks_per_year: type: string format: uint64 title: expected blocks per year description: Params defines the parameters for the x/mint module. cosmos.mint.v1beta1.QueryAnnualProvisionsResponse: type: object properties: annual_provisions: type: string format: byte description: annual_provisions is the current minting annual provisions value. description: |- QueryAnnualProvisionsResponse is the response type for the Query/AnnualProvisions RPC method. cosmos.mint.v1beta1.QueryInflationResponse: type: object properties: inflation: type: string format: byte description: inflation is the current minting inflation value. description: |- QueryInflationResponse is the response type for the Query/Inflation RPC method. cosmos.mint.v1beta1.QueryParamsResponse: type: object properties: params: description: params defines the parameters of the module. type: object properties: mint_denom: type: string title: type of coin to mint inflation_rate_change: type: string title: maximum annual change in inflation rate inflation_max: type: string title: maximum inflation rate inflation_min: type: string title: minimum inflation rate goal_bonded: type: string title: goal of percent bonded atoms blocks_per_year: type: string format: uint64 title: expected blocks per year description: QueryParamsResponse is the response type for the Query/Params RPC method. ================================================ FILE: client/docs/swagger.yaml ================================================ swagger: '2.0' info: title: Bostrom network version: v4 consumes: - application/json produces: - application/json paths: /cosmos/consensus/v1/params: get: summary: Params queries the parameters of x/consensus_param module. operationId: Params_TZPQY responses: '200': description: A successful response. schema: type: object properties: params: description: >- params are the tendermint consensus params stored in the consensus module. Please note that `params.version` is not populated in this response, it is tracked separately in the x/upgrade module. type: object properties: block: type: object properties: max_bytes: type: string format: int64 title: |- Max block size, in bytes. Note: must be greater than 0 max_gas: type: string format: int64 title: |- Max gas per block. Note: must be greater or equal to -1 description: BlockParams contains limits on the block size. evidence: type: object properties: max_age_num_blocks: type: string format: int64 description: >- Max age of evidence, in blocks. The basic formula for calculating this is: MaxAgeDuration / {average block time}. max_age_duration: type: string description: >- Max age of evidence, in time. It should correspond with an app's "unbonding period" or other similar mechanism for handling [Nothing-At-Stake attacks](https://github.com/ethereum/wiki/wiki/Proof-of-Stake-FAQ#what-is-the-nothing-at-stake-problem-and-how-can-it-be-fixed). max_bytes: type: string format: int64 title: >- This sets the maximum size of total evidence in bytes that can be committed in a single block. and should fall comfortably under the max block bytes. Default is 1048576 or 1MB description: >- EvidenceParams determine how we handle evidence of malfeasance. validator: type: object properties: pub_key_types: type: array items: type: string description: >- ValidatorParams restrict the public key types validators can use. NOTE: uses ABCI pubkey naming, not Amino names. version: type: object properties: app: type: string format: uint64 description: VersionParams contains the ABCI application version. description: >- QueryParamsResponse defines the response type for querying x/consensus parameters. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/feegrant/v1beta1/allowance/{granter}/{grantee}: get: summary: Allowance returns fee granted to the grantee by the granter. operationId: Allowance_WUEKP responses: '200': description: A successful response. schema: type: object properties: allowance: description: allowance is a allowance granted for grantee by granter. type: object properties: granter: type: string description: >- granter is the address of the user granting an allowance of their funds. grantee: type: string description: >- grantee is the address of the user being granted an allowance of another user's funds. allowance: type: object properties: type_url: type: string value: type: string format: byte description: >- allowance can be any of basic, periodic, allowed fee allowance. title: >- Grant is stored in the KVStore to record a grant with full context description: >- QueryAllowanceResponse is the response type for the Query/Allowance RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: granter description: >- granter is the address of the user granting an allowance of their funds. in: path required: true type: string - name: grantee description: >- grantee is the address of the user being granted an allowance of another user's funds. in: path required: true type: string tags: - gRPC Gateway API /cosmos/feegrant/v1beta1/allowances/{grantee}: get: summary: Allowances returns all the grants for address. operationId: Allowances_2SCGA responses: '200': description: A successful response. schema: type: object properties: allowances: type: array items: type: object properties: granter: type: string description: >- granter is the address of the user granting an allowance of their funds. grantee: type: string description: >- grantee is the address of the user being granted an allowance of another user's funds. allowance: type: object properties: type_url: type: string value: type: string format: byte description: >- allowance can be any of basic, periodic, allowed fee allowance. title: >- Grant is stored in the KVStore to record a grant with full context description: allowances are allowance's granted for grantee by granter. pagination: description: pagination defines an pagination for the response. type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- QueryAllowancesResponse is the response type for the Query/Allowances RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: grantee in: path required: true type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmos/feegrant/v1beta1/issued/{granter}: get: summary: AllowancesByGranter returns all the grants given by an address description: 'Since: cosmos-sdk 0.46' operationId: AllowancesByGranter_H5OXI responses: '200': description: A successful response. schema: type: object properties: allowances: type: array items: type: object properties: granter: type: string description: >- granter is the address of the user granting an allowance of their funds. grantee: type: string description: >- grantee is the address of the user being granted an allowance of another user's funds. allowance: type: object properties: type_url: type: string value: type: string format: byte description: >- allowance can be any of basic, periodic, allowed fee allowance. title: >- Grant is stored in the KVStore to record a grant with full context description: allowances that have been issued by the granter. pagination: description: pagination defines an pagination for the response. type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- QueryAllowancesByGranterResponse is the response type for the Query/AllowancesByGranter RPC method. Since: cosmos-sdk 0.46 default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: granter in: path required: true type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmos/gov/v1/params/{params_type}: get: summary: Params queries all parameters of the gov module. operationId: Params_RTRPI responses: '200': description: A successful response. schema: type: object properties: voting_params: description: |- Deprecated: Prefer to use `params` instead. voting_params defines the parameters related to voting. type: object properties: voting_period: type: string description: Duration of the voting period. deposit_params: description: |- Deprecated: Prefer to use `params` instead. deposit_params defines the parameters related to deposit. type: object properties: min_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: Minimum deposit for a proposal to enter voting period. max_deposit_period: type: string description: >- Maximum period for Atom holders to deposit on a proposal. Initial value: 2 months. tally_params: description: |- Deprecated: Prefer to use `params` instead. tally_params defines the parameters related to tally. type: object properties: quorum: type: string description: >- Minimum percentage of total stake needed to vote for a result to be considered valid. threshold: type: string description: >- Minimum proportion of Yes votes for proposal to pass. Default value: 0.5. veto_threshold: type: string description: >- Minimum value of Veto votes to Total votes ratio for proposal to be vetoed. Default value: 1/3. params: description: |- params defines all the paramaters of x/gov module. Since: cosmos-sdk 0.47 type: object properties: min_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: Minimum deposit for a proposal to enter voting period. max_deposit_period: type: string description: >- Maximum period for Atom holders to deposit on a proposal. Initial value: 2 months. voting_period: type: string description: Duration of the voting period. quorum: type: string description: >- Minimum percentage of total stake needed to vote for a result to be considered valid. threshold: type: string description: >- Minimum proportion of Yes votes for proposal to pass. Default value: 0.5. veto_threshold: type: string description: >- Minimum value of Veto votes to Total votes ratio for proposal to be vetoed. Default value: 1/3. min_initial_deposit_ratio: type: string description: >- The ratio representing the proportion of the deposit value that must be paid at proposal submission. burn_vote_quorum: type: boolean title: burn deposits if a proposal does not meet quorum burn_proposal_deposit_prevote: type: boolean title: burn deposits if the proposal does not enter voting period burn_vote_veto: type: boolean title: burn deposits if quorum with vote type no_veto is met description: >- QueryParamsResponse is the response type for the Query/Params RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: params_type description: >- params_type defines which parameters to query for, can be one of "voting", "tallying" or "deposit". in: path required: true type: string tags: - gRPC Gateway API /cosmos/gov/v1/proposals: get: summary: Proposals queries all proposals based on given status. operationId: Proposals_MNCBG responses: '200': description: A successful response. schema: type: object properties: proposals: type: array items: type: object properties: id: type: string format: uint64 description: id defines the unique id of the proposal. messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- messages are the arbitrary messages to be executed if the proposal passes. status: description: status defines the proposal status. type: string enum: - PROPOSAL_STATUS_UNSPECIFIED - PROPOSAL_STATUS_DEPOSIT_PERIOD - PROPOSAL_STATUS_VOTING_PERIOD - PROPOSAL_STATUS_PASSED - PROPOSAL_STATUS_REJECTED - PROPOSAL_STATUS_FAILED default: PROPOSAL_STATUS_UNSPECIFIED final_tally_result: description: >- final_tally_result is the final tally result of the proposal. When querying a proposal via gRPC, this field is not populated until the proposal's voting period has ended. type: object properties: yes_count: type: string description: yes_count is the number of yes votes on a proposal. abstain_count: type: string description: >- abstain_count is the number of abstain votes on a proposal. no_count: type: string description: no_count is the number of no votes on a proposal. no_with_veto_count: type: string description: >- no_with_veto_count is the number of no with veto votes on a proposal. submit_time: type: string format: date-time description: submit_time is the time of proposal submission. deposit_end_time: type: string format: date-time description: deposit_end_time is the end time for deposition. total_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: total_deposit is the total deposit on the proposal. voting_start_time: type: string format: date-time description: >- voting_start_time is the starting time to vote on a proposal. voting_end_time: type: string format: date-time description: voting_end_time is the end time of voting on a proposal. metadata: type: string description: >- metadata is any arbitrary metadata attached to the proposal. title: type: string description: 'Since: cosmos-sdk 0.47' title: title is the title of the proposal summary: type: string description: 'Since: cosmos-sdk 0.47' title: summary is a short summary of the proposal proposer: type: string description: 'Since: cosmos-sdk 0.47' title: Proposer is the address of the proposal sumbitter description: >- Proposal defines the core field members of a governance proposal. description: proposals defines all the requested governance proposals. pagination: description: pagination defines the pagination in the response. type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- QueryProposalsResponse is the response type for the Query/Proposals RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: proposal_status description: |- proposal_status defines the status of the proposals. - PROPOSAL_STATUS_UNSPECIFIED: PROPOSAL_STATUS_UNSPECIFIED defines the default proposal status. - PROPOSAL_STATUS_DEPOSIT_PERIOD: PROPOSAL_STATUS_DEPOSIT_PERIOD defines a proposal status during the deposit period. - PROPOSAL_STATUS_VOTING_PERIOD: PROPOSAL_STATUS_VOTING_PERIOD defines a proposal status during the voting period. - PROPOSAL_STATUS_PASSED: PROPOSAL_STATUS_PASSED defines a proposal status of a proposal that has passed. - PROPOSAL_STATUS_REJECTED: PROPOSAL_STATUS_REJECTED defines a proposal status of a proposal that has been rejected. - PROPOSAL_STATUS_FAILED: PROPOSAL_STATUS_FAILED defines a proposal status of a proposal that has failed. in: query required: false type: string enum: - PROPOSAL_STATUS_UNSPECIFIED - PROPOSAL_STATUS_DEPOSIT_PERIOD - PROPOSAL_STATUS_VOTING_PERIOD - PROPOSAL_STATUS_PASSED - PROPOSAL_STATUS_REJECTED - PROPOSAL_STATUS_FAILED default: PROPOSAL_STATUS_UNSPECIFIED - name: voter description: voter defines the voter address for the proposals. in: query required: false type: string - name: depositor description: depositor defines the deposit addresses from the proposals. in: query required: false type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmos/gov/v1/proposals/{proposal_id}: get: summary: Proposal queries proposal details based on ProposalID. operationId: Proposal_M3ACP responses: '200': description: A successful response. schema: type: object properties: proposal: type: object properties: id: type: string format: uint64 description: id defines the unique id of the proposal. messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- messages are the arbitrary messages to be executed if the proposal passes. status: description: status defines the proposal status. type: string enum: - PROPOSAL_STATUS_UNSPECIFIED - PROPOSAL_STATUS_DEPOSIT_PERIOD - PROPOSAL_STATUS_VOTING_PERIOD - PROPOSAL_STATUS_PASSED - PROPOSAL_STATUS_REJECTED - PROPOSAL_STATUS_FAILED default: PROPOSAL_STATUS_UNSPECIFIED final_tally_result: description: >- final_tally_result is the final tally result of the proposal. When querying a proposal via gRPC, this field is not populated until the proposal's voting period has ended. type: object properties: yes_count: type: string description: yes_count is the number of yes votes on a proposal. abstain_count: type: string description: >- abstain_count is the number of abstain votes on a proposal. no_count: type: string description: no_count is the number of no votes on a proposal. no_with_veto_count: type: string description: >- no_with_veto_count is the number of no with veto votes on a proposal. submit_time: type: string format: date-time description: submit_time is the time of proposal submission. deposit_end_time: type: string format: date-time description: deposit_end_time is the end time for deposition. total_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: total_deposit is the total deposit on the proposal. voting_start_time: type: string format: date-time description: >- voting_start_time is the starting time to vote on a proposal. voting_end_time: type: string format: date-time description: voting_end_time is the end time of voting on a proposal. metadata: type: string description: >- metadata is any arbitrary metadata attached to the proposal. title: type: string description: 'Since: cosmos-sdk 0.47' title: title is the title of the proposal summary: type: string description: 'Since: cosmos-sdk 0.47' title: summary is a short summary of the proposal proposer: type: string description: 'Since: cosmos-sdk 0.47' title: Proposer is the address of the proposal sumbitter description: >- Proposal defines the core field members of a governance proposal. description: >- QueryProposalResponse is the response type for the Query/Proposal RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: proposal_id description: proposal_id defines the unique id of the proposal. in: path required: true type: string format: uint64 tags: - gRPC Gateway API /cosmos/gov/v1/proposals/{proposal_id}/deposits: get: summary: Deposits queries all deposits of a single proposal. operationId: Deposits_1TZ1V responses: '200': description: A successful response. schema: type: object properties: deposits: type: array items: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. depositor: type: string description: >- depositor defines the deposit addresses from the proposals. amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: amount to be deposited by depositor. description: >- Deposit defines an amount deposited by an account address to an active proposal. description: deposits defines the requested deposits. pagination: description: pagination defines the pagination in the response. type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- QueryDepositsResponse is the response type for the Query/Deposits RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: proposal_id description: proposal_id defines the unique id of the proposal. in: path required: true type: string format: uint64 - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmos/gov/v1/proposals/{proposal_id}/deposits/{depositor}: get: summary: >- Deposit queries single deposit information based proposalID, depositAddr. operationId: Deposit_2YBCE responses: '200': description: A successful response. schema: type: object properties: deposit: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. depositor: type: string description: >- depositor defines the deposit addresses from the proposals. amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: amount to be deposited by depositor. description: >- Deposit defines an amount deposited by an account address to an active proposal. description: >- QueryDepositResponse is the response type for the Query/Deposit RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: proposal_id description: proposal_id defines the unique id of the proposal. in: path required: true type: string format: uint64 - name: depositor description: depositor defines the deposit addresses from the proposals. in: path required: true type: string tags: - gRPC Gateway API /cosmos/gov/v1/proposals/{proposal_id}/tally: get: summary: TallyResult queries the tally of a proposal vote. operationId: TallyResult_HD9CX responses: '200': description: A successful response. schema: type: object properties: tally: description: tally defines the requested tally. type: object properties: yes_count: type: string description: yes_count is the number of yes votes on a proposal. abstain_count: type: string description: >- abstain_count is the number of abstain votes on a proposal. no_count: type: string description: no_count is the number of no votes on a proposal. no_with_veto_count: type: string description: >- no_with_veto_count is the number of no with veto votes on a proposal. description: >- QueryTallyResultResponse is the response type for the Query/Tally RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: proposal_id description: proposal_id defines the unique id of the proposal. in: path required: true type: string format: uint64 tags: - gRPC Gateway API /cosmos/gov/v1/proposals/{proposal_id}/votes: get: summary: Votes queries votes of a given proposal. operationId: Votes_AG3U7 responses: '200': description: A successful response. schema: type: object properties: votes: type: array items: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. voter: type: string description: voter is the voter address of the proposal. options: type: array items: type: object properties: option: description: >- option defines the valid vote options, it must not contain duplicate vote options. type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED weight: type: string description: >- weight is the vote weight associated with the vote option. description: >- WeightedVoteOption defines a unit of vote for vote split. description: options is the weighted vote options. metadata: type: string description: >- metadata is any arbitrary metadata to attached to the vote. description: >- Vote defines a vote on a governance proposal. A Vote consists of a proposal ID, the voter, and the vote option. description: votes defines the queried votes. pagination: description: pagination defines the pagination in the response. type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- QueryVotesResponse is the response type for the Query/Votes RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: proposal_id description: proposal_id defines the unique id of the proposal. in: path required: true type: string format: uint64 - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmos/gov/v1/proposals/{proposal_id}/votes/{voter}: get: summary: Vote queries voted information based on proposalID, voterAddr. operationId: Vote_CJIO5 responses: '200': description: A successful response. schema: type: object properties: vote: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. voter: type: string description: voter is the voter address of the proposal. options: type: array items: type: object properties: option: description: >- option defines the valid vote options, it must not contain duplicate vote options. type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED weight: type: string description: >- weight is the vote weight associated with the vote option. description: >- WeightedVoteOption defines a unit of vote for vote split. description: options is the weighted vote options. metadata: type: string description: >- metadata is any arbitrary metadata to attached to the vote. description: >- Vote defines a vote on a governance proposal. A Vote consists of a proposal ID, the voter, and the vote option. description: >- QueryVoteResponse is the response type for the Query/Vote RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: proposal_id description: proposal_id defines the unique id of the proposal. in: path required: true type: string format: uint64 - name: voter description: voter defines the voter address for the proposals. in: path required: true type: string tags: - gRPC Gateway API /cyber/graph/v1beta1/graph_stats: get: operationId: GraphStats_EIHOL responses: '200': description: A successful response. schema: type: object properties: cyberlinks: type: string format: uint64 particles: type: string format: uint64 default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cyber/resources/v1beta1/resources/investmint: get: operationId: Investmint_GWKUV responses: '200': description: A successful response. schema: type: object properties: amount: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: amount.denom in: query required: false type: string - name: amount.amount in: query required: false type: string - name: resource in: query required: false type: string - name: length in: query required: false type: string format: uint64 tags: - gRPC Gateway API /cyber/resources/v1beta1/resources/params: get: operationId: Params_KCXBY responses: '200': description: A successful response. schema: type: object properties: params: type: object properties: max_slots: type: integer format: int64 halving_period_volt_blocks: type: integer format: int64 halving_period_ampere_blocks: type: integer format: int64 base_investmint_period_volt: type: integer format: int64 base_investmint_period_ampere: type: integer format: int64 min_investmint_period: type: integer format: int64 base_investmint_amount_volt: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. base_investmint_amount_ampere: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/base/node/v1beta1/config: get: summary: Config queries for the operator configuration. operationId: Config_CWIZ3 responses: '200': description: A successful response. schema: type: object properties: minimum_gas_price: type: string description: >- ConfigResponse defines the response structure for the Config gRPC query. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/upgrade/v1beta1/applied_plan/{name}: get: summary: AppliedPlan queries a previously applied upgrade plan by its name. operationId: AppliedPlan_UVH49 responses: '200': description: A successful response. schema: type: object properties: height: type: string format: int64 description: height is the block height at which the plan was applied. description: >- QueryAppliedPlanResponse is the response type for the Query/AppliedPlan RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: name description: name is the name of the applied plan to query for. in: path required: true type: string tags: - gRPC Gateway API /cosmos/upgrade/v1beta1/authority: get: summary: Returns the account with authority to conduct upgrades description: 'Since: cosmos-sdk 0.46' operationId: Authority_2NU82 responses: '200': description: A successful response. schema: type: object properties: address: type: string description: 'Since: cosmos-sdk 0.46' title: QueryAuthorityResponse is the response type for Query/Authority default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/upgrade/v1beta1/current_plan: get: summary: CurrentPlan queries the current upgrade plan. operationId: CurrentPlan_YGRDZ responses: '200': description: A successful response. schema: type: object properties: plan: description: plan is the current upgrade plan. type: object properties: name: type: string description: >- Sets the name for the upgrade. This name will be used by the upgraded version of the software to apply any special "on-upgrade" commands during the first BeginBlock method after the upgrade is applied. It is also used to detect whether a software version can handle a given upgrade. If no upgrade handler with this name has been set in the software, it will be assumed that the software is out-of-date when the upgrade Time or Height is reached and the software will exit. time: type: string format: date-time description: >- Deprecated: Time based upgrades have been deprecated. Time based upgrade logic has been removed from the SDK. If this field is not empty, an error will be thrown. height: type: string format: int64 description: The height at which the upgrade must be performed. info: type: string title: >- Any application specific upgrade info to be included on-chain such as a git commit that validators could automatically upgrade to upgraded_client_state: type: object properties: type_url: type: string value: type: string format: byte description: >- Deprecated: UpgradedClientState field has been deprecated. IBC upgrade logic has been moved to the IBC module in the sub module 02-client. If this field is not empty, an error will be thrown. description: >- QueryCurrentPlanResponse is the response type for the Query/CurrentPlan RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/upgrade/v1beta1/module_versions: get: summary: ModuleVersions queries the list of module versions from state. description: 'Since: cosmos-sdk 0.43' operationId: ModuleVersions_7VRES responses: '200': description: A successful response. schema: type: object properties: module_versions: type: array items: type: object properties: name: type: string title: name of the app module version: type: string format: uint64 title: consensus version of the app module description: |- ModuleVersion specifies a module and its consensus version. Since: cosmos-sdk 0.43 description: >- module_versions is a list of module names with their consensus versions. description: >- QueryModuleVersionsResponse is the response type for the Query/ModuleVersions RPC method. Since: cosmos-sdk 0.43 default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: module_name description: |- module_name is a field to query a specific module consensus version from state. Leaving this empty will fetch the full list of module versions from state. in: query required: false type: string tags: - gRPC Gateway API /cosmos/upgrade/v1beta1/upgraded_consensus_state/{last_height}: get: summary: >- UpgradedConsensusState queries the consensus state that will serve as a trusted kernel for the next version of this chain. It will only be stored at the last height of this chain. UpgradedConsensusState RPC not supported with legacy querier This rpc is deprecated now that IBC has its own replacement (https://github.com/cosmos/ibc-go/blob/2c880a22e9f9cc75f62b527ca94aa75ce1106001/proto/ibc/core/client/v1/query.proto#L54) operationId: UpgradedConsensusState_DG71K responses: '200': description: A successful response. schema: type: object properties: upgraded_consensus_state: type: string format: byte title: 'Since: cosmos-sdk 0.43' description: >- QueryUpgradedConsensusStateResponse is the response type for the Query/UpgradedConsensusState RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: last_height description: |- last height of the current chain must be sent in request as this is the height under which next consensus state is stored in: path required: true type: string format: int64 tags: - gRPC Gateway API /ibc/apps/fee/v1/channels/{channel_id}/ports/{port_id}/fee_enabled: get: summary: >- FeeEnabledChannel returns true if the provided port and channel identifiers belong to a fee enabled channel operationId: FeeEnabledChannel_840O1 responses: '200': description: A successful response. schema: type: object properties: fee_enabled: type: boolean title: boolean flag representing the fee enabled channel status title: >- QueryFeeEnabledChannelResponse defines the response type for the FeeEnabledChannel rpc default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: channel_id description: unique channel identifier in: path required: true type: string - name: port_id description: unique port identifier in: path required: true type: string tags: - gRPC Gateway API /ibc/apps/fee/v1/channels/{channel_id}/ports/{port_id}/incentivized_packets: get: summary: Gets all incentivized packets for a specific channel operationId: IncentivizedPacketsForChannel_YZC9B responses: '200': description: A successful response. schema: type: object properties: incentivized_packets: type: array items: type: object properties: packet_id: title: >- unique packet identifier comprised of the channel ID, port ID and sequence type: object properties: port_id: type: string title: channel port identifier channel_id: type: string title: channel unique identifier sequence: type: string format: uint64 title: packet sequence packet_fees: type: array items: type: object properties: fee: title: >- fee encapsulates the recv, ack and timeout fees associated with an IBC packet type: object properties: recv_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet receive fee ack_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet acknowledgement fee timeout_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet timeout fee refund_address: type: string title: the refund address for unspent fees relayers: type: array items: type: string title: >- optional list of relayers permitted to receive fees title: >- PacketFee contains ICS29 relayer fees, refund address and optional list of permitted relayers title: list of packet fees title: >- IdentifiedPacketFees contains a list of type PacketFee and associated PacketId title: Map of all incentivized_packets title: >- QueryIncentivizedPacketsResponse defines the response type for the incentivized packets RPC default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: channel_id in: path required: true type: string - name: port_id in: path required: true type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean - name: query_height description: Height to query at. in: query required: false type: string format: uint64 tags: - gRPC Gateway API /ibc/apps/fee/v1/channels/{channel_id}/relayers/{relayer}/counterparty_payee: get: summary: >- CounterpartyPayee returns the registered counterparty payee for forward relaying operationId: CounterpartyPayee_OX3D8 responses: '200': description: A successful response. schema: type: object properties: counterparty_payee: type: string title: >- the counterparty payee address used to compensate forward relaying title: >- QueryCounterpartyPayeeResponse defines the response type for the CounterpartyPayee rpc default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: channel_id description: unique channel identifier in: path required: true type: string - name: relayer description: the relayer address to which the counterparty is registered in: path required: true type: string tags: - gRPC Gateway API /ibc/apps/fee/v1/channels/{channel_id}/relayers/{relayer}/payee: get: summary: >- Payee returns the registered payee address for a specific channel given the relayer address operationId: Payee_Y340V responses: '200': description: A successful response. schema: type: object properties: payee_address: type: string title: the payee address to which packet fees are paid out title: QueryPayeeResponse defines the response type for the Payee rpc default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: channel_id description: unique channel identifier in: path required: true type: string - name: relayer description: the relayer address to which the distribution address is registered in: path required: true type: string tags: - gRPC Gateway API /ibc/apps/fee/v1/channels/{packet_id.channel_id}/ports/{packet_id.port_id}/sequences/{packet_id.sequence}/incentivized_packet: get: summary: >- IncentivizedPacket returns all packet fees for a packet given its identifier operationId: IncentivizedPacket_FYWES responses: '200': description: A successful response. schema: type: object properties: incentivized_packet: type: object properties: packet_id: title: >- unique packet identifier comprised of the channel ID, port ID and sequence type: object properties: port_id: type: string title: channel port identifier channel_id: type: string title: channel unique identifier sequence: type: string format: uint64 title: packet sequence packet_fees: type: array items: type: object properties: fee: title: >- fee encapsulates the recv, ack and timeout fees associated with an IBC packet type: object properties: recv_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet receive fee ack_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet acknowledgement fee timeout_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet timeout fee refund_address: type: string title: the refund address for unspent fees relayers: type: array items: type: string title: optional list of relayers permitted to receive fees title: >- PacketFee contains ICS29 relayer fees, refund address and optional list of permitted relayers title: list of packet fees title: >- IdentifiedPacketFees contains a list of type PacketFee and associated PacketId title: >- QueryIncentivizedPacketsResponse defines the response type for the IncentivizedPacket rpc default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: packet_id.channel_id description: channel unique identifier in: path required: true type: string - name: packet_id.port_id description: channel port identifier in: path required: true type: string - name: packet_id.sequence description: packet sequence in: path required: true type: string format: uint64 - name: query_height description: block height at which to query. in: query required: false type: string format: uint64 tags: - gRPC Gateway API /ibc/apps/fee/v1/channels/{packet_id.channel_id}/ports/{packet_id.port_id}/sequences/{packet_id.sequence}/total_ack_fees: get: summary: >- TotalAckFees returns the total acknowledgement fees for a packet given its identifier operationId: TotalAckFees_SFS3U responses: '200': description: A successful response. schema: type: object properties: ack_fees: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the total packet acknowledgement fees title: >- QueryTotalAckFeesResponse defines the response type for the TotalAckFees rpc default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: packet_id.channel_id description: channel unique identifier in: path required: true type: string - name: packet_id.port_id description: channel port identifier in: path required: true type: string - name: packet_id.sequence description: packet sequence in: path required: true type: string format: uint64 tags: - gRPC Gateway API /ibc/apps/fee/v1/channels/{packet_id.channel_id}/ports/{packet_id.port_id}/sequences/{packet_id.sequence}/total_recv_fees: get: summary: >- TotalRecvFees returns the total receive fees for a packet given its identifier operationId: TotalRecvFees_8W02H responses: '200': description: A successful response. schema: type: object properties: recv_fees: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the total packet receive fees title: >- QueryTotalRecvFeesResponse defines the response type for the TotalRecvFees rpc default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: packet_id.channel_id description: channel unique identifier in: path required: true type: string - name: packet_id.port_id description: channel port identifier in: path required: true type: string - name: packet_id.sequence description: packet sequence in: path required: true type: string format: uint64 tags: - gRPC Gateway API /ibc/apps/fee/v1/channels/{packet_id.channel_id}/ports/{packet_id.port_id}/sequences/{packet_id.sequence}/total_timeout_fees: get: summary: >- TotalTimeoutFees returns the total timeout fees for a packet given its identifier operationId: TotalTimeoutFees_FQFYL responses: '200': description: A successful response. schema: type: object properties: timeout_fees: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the total packet timeout fees title: >- QueryTotalTimeoutFeesResponse defines the response type for the TotalTimeoutFees rpc default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: packet_id.channel_id description: channel unique identifier in: path required: true type: string - name: packet_id.port_id description: channel port identifier in: path required: true type: string - name: packet_id.sequence description: packet sequence in: path required: true type: string format: uint64 tags: - gRPC Gateway API /ibc/apps/fee/v1/fee_enabled: get: summary: FeeEnabledChannels returns a list of all fee enabled channels operationId: FeeEnabledChannels_00UHI responses: '200': description: A successful response. schema: type: object properties: fee_enabled_channels: type: array items: type: object properties: port_id: type: string title: unique port identifier channel_id: type: string title: unique channel identifier title: >- FeeEnabledChannel contains the PortID & ChannelID for a fee enabled channel title: list of fee enabled channels title: >- QueryFeeEnabledChannelsResponse defines the response type for the FeeEnabledChannels rpc default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean - name: query_height description: block height at which to query. in: query required: false type: string format: uint64 tags: - gRPC Gateway API /ibc/apps/fee/v1/incentivized_packets: get: summary: >- IncentivizedPackets returns all incentivized packets and their associated fees operationId: IncentivizedPackets_0KHDP responses: '200': description: A successful response. schema: type: object properties: incentivized_packets: type: array items: type: object properties: packet_id: title: >- unique packet identifier comprised of the channel ID, port ID and sequence type: object properties: port_id: type: string title: channel port identifier channel_id: type: string title: channel unique identifier sequence: type: string format: uint64 title: packet sequence packet_fees: type: array items: type: object properties: fee: title: >- fee encapsulates the recv, ack and timeout fees associated with an IBC packet type: object properties: recv_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet receive fee ack_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet acknowledgement fee timeout_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet timeout fee refund_address: type: string title: the refund address for unspent fees relayers: type: array items: type: string title: >- optional list of relayers permitted to receive fees title: >- PacketFee contains ICS29 relayer fees, refund address and optional list of permitted relayers title: list of packet fees title: >- IdentifiedPacketFees contains a list of type PacketFee and associated PacketId title: list of identified fees for incentivized packets title: >- QueryIncentivizedPacketsResponse defines the response type for the IncentivizedPackets rpc default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean - name: query_height description: block height at which to query. in: query required: false type: string format: uint64 tags: - gRPC Gateway API /cosmos/params/v1beta1/params: get: summary: |- Params queries a specific parameter of a module, given its subspace and key. operationId: Params_VQK7H responses: '200': description: A successful response. schema: type: object properties: param: description: param defines the queried parameter. type: object properties: subspace: type: string key: type: string value: type: string description: >- QueryParamsResponse is response type for the Query/Params RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: subspace description: subspace defines the module to query the parameter for. in: query required: false type: string - name: key description: key defines the key of the parameter in the subspace. in: query required: false type: string tags: - gRPC Gateway API /cosmos/params/v1beta1/subspaces: get: summary: >- Subspaces queries for all registered subspaces and all keys for a subspace. description: 'Since: cosmos-sdk 0.46' operationId: Subspaces_7GKEQ responses: '200': description: A successful response. schema: type: object properties: subspaces: type: array items: type: object properties: subspace: type: string keys: type: array items: type: string description: >- Subspace defines a parameter subspace name and all the keys that exist for the subspace. Since: cosmos-sdk 0.46 description: >- QuerySubspacesResponse defines the response types for querying for all registered subspaces and all keys for a subspace. Since: cosmos-sdk 0.46 default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cyber/rank/v1beta1/is_any_link_exist: get: operationId: IsAnyLinkExist_2JCAZ responses: '200': description: A successful response. schema: type: object properties: exist: type: boolean default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: from in: query required: false type: string - name: to in: query required: false type: string tags: - gRPC Gateway API /cyber/rank/v1beta1/is_link_exist: get: operationId: IsLinkExist_T429K responses: '200': description: A successful response. schema: type: object properties: exist: type: boolean default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: from in: query required: false type: string - name: to in: query required: false type: string - name: address in: query required: false type: string tags: - gRPC Gateway API /cyber/rank/v1beta1/karma/{neuron}: get: operationId: Karma_OCY17 responses: '200': description: A successful response. schema: type: object properties: karma: type: string format: uint64 default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: neuron in: path required: true type: string tags: - gRPC Gateway API /cyber/rank/v1beta1/negentropy: get: operationId: Negentropy_I4QNT responses: '200': description: A successful response. schema: type: object properties: negentropy: type: string format: uint64 default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cyber/rank/v1beta1/negentropy/{particle}: get: operationId: ParticleNegentropy_9E5ES responses: '200': description: A successful response. schema: type: object properties: entropy: type: string format: uint64 default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: particle in: path required: true type: string tags: - gRPC Gateway API /cyber/rank/v1beta1/rank/backlinks/{particle}: get: operationId: Backlinks_00QZQ responses: '200': description: A successful response. schema: type: object properties: result: type: array items: type: object properties: particle: type: string rank: type: string format: uint64 pagination: type: object properties: total: type: integer format: int64 default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: particle in: path required: true type: string - name: pagination.page in: query required: false type: integer format: int64 - name: pagination.per_page in: query required: false type: integer format: int64 tags: - gRPC Gateway API /cyber/rank/v1beta1/rank/params: get: operationId: Params_L259G responses: '200': description: A successful response. schema: type: object properties: params: type: object properties: calculation_period: type: string format: int64 damping_factor: type: string tolerance: type: string default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cyber/rank/v1beta1/rank/rank/{particle}: get: operationId: Rank_U75Y2 responses: '200': description: A successful response. schema: type: object properties: rank: type: string format: uint64 default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: particle in: path required: true type: string tags: - gRPC Gateway API /cyber/rank/v1beta1/rank/search/{particle}: get: operationId: Search_W3CZ3 responses: '200': description: A successful response. schema: type: object properties: result: type: array items: type: object properties: particle: type: string rank: type: string format: uint64 pagination: type: object properties: total: type: integer format: int64 default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: particle in: path required: true type: string - name: pagination.page in: query required: false type: integer format: int64 - name: pagination.per_page in: query required: false type: integer format: int64 tags: - gRPC Gateway API /cyber/rank/v1beta1/rank/top: get: operationId: Top_M5Z8S responses: '200': description: A successful response. schema: type: object properties: result: type: array items: type: object properties: particle: type: string rank: type: string format: uint64 pagination: type: object properties: total: type: integer format: int64 default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pagination.page in: query required: false type: integer format: int64 - name: pagination.per_page in: query required: false type: integer format: int64 tags: - gRPC Gateway API /cosmos/distribution/v1beta1/community_pool: get: summary: CommunityPool queries the community pool coins. operationId: CommunityPool_0US6E responses: '200': description: A successful response. schema: type: object properties: pool: type: array items: type: object properties: denom: type: string amount: type: string description: >- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. description: pool defines community pool's coins. description: >- QueryCommunityPoolResponse is the response type for the Query/CommunityPool RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/distribution/v1beta1/delegators/{delegator_address}/rewards: get: summary: |- DelegationTotalRewards queries the total rewards accrued by a each validator. operationId: DelegationTotalRewards_WYSIY responses: '200': description: A successful response. schema: type: object properties: rewards: type: array items: type: object properties: validator_address: type: string reward: type: array items: type: object properties: denom: type: string amount: type: string description: >- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. description: |- DelegationDelegatorReward represents the properties of a delegator's delegation reward. description: rewards defines all the rewards accrued by a delegator. total: type: array items: type: object properties: denom: type: string amount: type: string description: >- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. description: total defines the sum of all the rewards. description: |- QueryDelegationTotalRewardsResponse is the response type for the Query/DelegationTotalRewards RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: delegator_address description: delegator_address defines the delegator address to query for. in: path required: true type: string tags: - gRPC Gateway API /cosmos/distribution/v1beta1/delegators/{delegator_address}/rewards/{validator_address}: get: summary: DelegationRewards queries the total rewards accrued by a delegation. operationId: DelegationRewards_AZKQ1 responses: '200': description: A successful response. schema: type: object properties: rewards: type: array items: type: object properties: denom: type: string amount: type: string description: >- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. description: rewards defines the rewards accrued by a delegation. description: |- QueryDelegationRewardsResponse is the response type for the Query/DelegationRewards RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: delegator_address description: delegator_address defines the delegator address to query for. in: path required: true type: string - name: validator_address description: validator_address defines the validator address to query for. in: path required: true type: string tags: - gRPC Gateway API /cosmos/distribution/v1beta1/delegators/{delegator_address}/validators: get: summary: DelegatorValidators queries the validators of a delegator. operationId: DelegatorValidators_86WPX responses: '200': description: A successful response. schema: type: object properties: validators: type: array items: type: string description: >- validators defines the validators a delegator is delegating for. description: |- QueryDelegatorValidatorsResponse is the response type for the Query/DelegatorValidators RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: delegator_address description: delegator_address defines the delegator address to query for. in: path required: true type: string tags: - gRPC Gateway API /cosmos/distribution/v1beta1/delegators/{delegator_address}/withdraw_address: get: summary: DelegatorWithdrawAddress queries withdraw address of a delegator. operationId: DelegatorWithdrawAddress_YB7EI responses: '200': description: A successful response. schema: type: object properties: withdraw_address: type: string description: withdraw_address defines the delegator address to query for. description: |- QueryDelegatorWithdrawAddressResponse is the response type for the Query/DelegatorWithdrawAddress RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: delegator_address description: delegator_address defines the delegator address to query for. in: path required: true type: string tags: - gRPC Gateway API /cosmos/distribution/v1beta1/params: get: summary: Params queries params of the distribution module. operationId: Params_T3DPP responses: '200': description: A successful response. schema: type: object properties: params: description: params defines the parameters of the module. type: object properties: community_tax: type: string base_proposer_reward: type: string description: >- Deprecated: The base_proposer_reward field is deprecated and is no longer used in the x/distribution module's reward mechanism. bonus_proposer_reward: type: string description: >- Deprecated: The bonus_proposer_reward field is deprecated and is no longer used in the x/distribution module's reward mechanism. withdraw_addr_enabled: type: boolean description: >- QueryParamsResponse is the response type for the Query/Params RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/distribution/v1beta1/validators/{validator_address}: get: summary: >- ValidatorDistributionInfo queries validator commission and self-delegation rewards for validator operationId: ValidatorDistributionInfo_FWO9U responses: '200': description: A successful response. schema: type: object properties: operator_address: type: string description: operator_address defines the validator operator address. self_bond_rewards: type: array items: type: object properties: denom: type: string amount: type: string description: >- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. description: self_bond_rewards defines the self delegations rewards. commission: type: array items: type: object properties: denom: type: string amount: type: string description: >- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. description: commission defines the commission the validator received. description: >- QueryValidatorDistributionInfoResponse is the response type for the Query/ValidatorDistributionInfo RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: validator_address description: validator_address defines the validator address to query for. in: path required: true type: string tags: - gRPC Gateway API /cosmos/distribution/v1beta1/validators/{validator_address}/commission: get: summary: ValidatorCommission queries accumulated commission for a validator. operationId: ValidatorCommission_BK3UA responses: '200': description: A successful response. schema: type: object properties: commission: description: commission defines the commission the validator received. type: object properties: commission: type: array items: type: object properties: denom: type: string amount: type: string description: >- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. title: |- QueryValidatorCommissionResponse is the response type for the Query/ValidatorCommission RPC method default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: validator_address description: validator_address defines the validator address to query for. in: path required: true type: string tags: - gRPC Gateway API /cosmos/distribution/v1beta1/validators/{validator_address}/outstanding_rewards: get: summary: ValidatorOutstandingRewards queries rewards of a validator address. operationId: ValidatorOutstandingRewards_GBZ1A responses: '200': description: A successful response. schema: type: object properties: rewards: type: object properties: rewards: type: array items: type: object properties: denom: type: string amount: type: string description: >- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. description: >- ValidatorOutstandingRewards represents outstanding (un-withdrawn) rewards for a validator inexpensive to track, allows simple sanity checks. description: >- QueryValidatorOutstandingRewardsResponse is the response type for the Query/ValidatorOutstandingRewards RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: validator_address description: validator_address defines the validator address to query for. in: path required: true type: string tags: - gRPC Gateway API /cosmos/distribution/v1beta1/validators/{validator_address}/slashes: get: summary: ValidatorSlashes queries slash events of a validator. operationId: ValidatorSlashes_ZIX0V responses: '200': description: A successful response. schema: type: object properties: slashes: type: array items: type: object properties: validator_period: type: string format: uint64 fraction: type: string description: >- ValidatorSlashEvent represents a validator slash event. Height is implicit within the store key. This is needed to calculate appropriate amount of staking tokens for delegations which are withdrawn after a slash has occurred. description: slashes defines the slashes the validator received. pagination: description: pagination defines the pagination in the response. type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- QueryValidatorSlashesResponse is the response type for the Query/ValidatorSlashes RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: validator_address description: validator_address defines the validator address to query for. in: path required: true type: string - name: starting_height description: >- starting_height defines the optional starting height to query the slashes. in: query required: false type: string format: uint64 - name: ending_height description: >- starting_height defines the optional ending height to query the slashes. in: query required: false type: string format: uint64 - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmos/bank/v1beta1/balances/{address}: get: summary: AllBalances queries the balance of all coins for a single account. description: >- When called from another module, this query might consume a high amount of gas if the pagination field is incorrectly set. operationId: AllBalances_SB2JJ responses: '200': description: A successful response. schema: type: object properties: balances: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: balances is the balances of all the coins. pagination: description: pagination defines the pagination in the response. type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- QueryAllBalancesResponse is the response type for the Query/AllBalances RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: address description: address is the address to query balances for. in: path required: true type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmos/bank/v1beta1/balances/{address}/by_denom: get: summary: Balance queries the balance of a single coin for a single account. operationId: Balance_3DIWH responses: '200': description: A successful response. schema: type: object properties: balance: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- QueryBalanceResponse is the response type for the Query/Balance RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: address description: address is the address to query balances for. in: path required: true type: string - name: denom description: denom is the coin denom to query balances for. in: query required: false type: string tags: - gRPC Gateway API /cosmos/bank/v1beta1/denom_owners/{denom}: get: summary: >- DenomOwners queries for all account addresses that own a particular token denomination. description: >- When called from another module, this query might consume a high amount of gas if the pagination field is incorrectly set. Since: cosmos-sdk 0.46 operationId: DenomOwners_MVQ6C responses: '200': description: A successful response. schema: type: object properties: denom_owners: type: array items: type: object properties: address: type: string description: >- address defines the address that owns a particular denomination. balance: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- DenomOwner defines structure representing an account that owns or holds a particular denominated token. It contains the account address and account balance of the denominated token. Since: cosmos-sdk 0.46 pagination: description: pagination defines the pagination in the response. type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- QueryDenomOwnersResponse defines the RPC response of a DenomOwners RPC query. Since: cosmos-sdk 0.46 default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: denom description: >- denom defines the coin denomination to query all account holders for. in: path required: true type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmos/bank/v1beta1/denoms_metadata: get: summary: |- DenomsMetadata queries the client metadata for all registered coin denominations. operationId: DenomsMetadata_1QGQ2 responses: '200': description: A successful response. schema: type: object properties: metadatas: type: array items: type: object properties: description: type: string denom_units: type: array items: type: object properties: denom: type: string description: >- denom represents the string name of the given denom unit (e.g uatom). exponent: type: integer format: int64 description: >- exponent represents power of 10 exponent that one must raise the base_denom to in order to equal the given DenomUnit's denom 1 denom = 10^exponent base_denom (e.g. with a base_denom of uatom, one can create a DenomUnit of 'atom' with exponent = 6, thus: 1 atom = 10^6 uatom). aliases: type: array items: type: string title: >- aliases is a list of string aliases for the given denom description: |- DenomUnit represents a struct that describes a given denomination unit of the basic token. title: >- denom_units represents the list of DenomUnit's for a given coin base: type: string description: >- base represents the base denom (should be the DenomUnit with exponent = 0). display: type: string description: |- display indicates the suggested denom that should be displayed in clients. name: type: string description: 'Since: cosmos-sdk 0.43' title: 'name defines the name of the token (eg: Cosmos Atom)' symbol: type: string description: >- symbol is the token symbol usually shown on exchanges (eg: ATOM). This can be the same as the display. Since: cosmos-sdk 0.43 uri: type: string description: >- URI to a document (on or off-chain) that contains additional information. Optional. Since: cosmos-sdk 0.46 uri_hash: type: string description: >- URIHash is a sha256 hash of a document pointed by URI. It's used to verify that the document didn't change. Optional. Since: cosmos-sdk 0.46 description: |- Metadata represents a struct that describes a basic token. description: >- metadata provides the client information for all the registered tokens. pagination: description: pagination defines the pagination in the response. type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- QueryDenomsMetadataResponse is the response type for the Query/DenomsMetadata RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmos/bank/v1beta1/denoms_metadata/{denom}: get: summary: DenomsMetadata queries the client metadata of a given coin denomination. operationId: DenomMetadata_IWNXK responses: '200': description: A successful response. schema: type: object properties: metadata: type: object properties: description: type: string denom_units: type: array items: type: object properties: denom: type: string description: >- denom represents the string name of the given denom unit (e.g uatom). exponent: type: integer format: int64 description: >- exponent represents power of 10 exponent that one must raise the base_denom to in order to equal the given DenomUnit's denom 1 denom = 10^exponent base_denom (e.g. with a base_denom of uatom, one can create a DenomUnit of 'atom' with exponent = 6, thus: 1 atom = 10^6 uatom). aliases: type: array items: type: string title: >- aliases is a list of string aliases for the given denom description: |- DenomUnit represents a struct that describes a given denomination unit of the basic token. title: >- denom_units represents the list of DenomUnit's for a given coin base: type: string description: >- base represents the base denom (should be the DenomUnit with exponent = 0). display: type: string description: |- display indicates the suggested denom that should be displayed in clients. name: type: string description: 'Since: cosmos-sdk 0.43' title: 'name defines the name of the token (eg: Cosmos Atom)' symbol: type: string description: >- symbol is the token symbol usually shown on exchanges (eg: ATOM). This can be the same as the display. Since: cosmos-sdk 0.43 uri: type: string description: >- URI to a document (on or off-chain) that contains additional information. Optional. Since: cosmos-sdk 0.46 uri_hash: type: string description: >- URIHash is a sha256 hash of a document pointed by URI. It's used to verify that the document didn't change. Optional. Since: cosmos-sdk 0.46 description: |- Metadata represents a struct that describes a basic token. description: >- QueryDenomMetadataResponse is the response type for the Query/DenomMetadata RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: denom description: denom is the coin denom to query the metadata for. in: path required: true type: string tags: - gRPC Gateway API /cosmos/bank/v1beta1/params: get: summary: Params queries the parameters of x/bank module. operationId: Params_UPITY responses: '200': description: A successful response. schema: type: object properties: params: type: object properties: send_enabled: type: array items: type: object properties: denom: type: string enabled: type: boolean description: >- SendEnabled maps coin denom to a send_enabled status (whether a denom is sendable). description: >- Deprecated: Use of SendEnabled in params is deprecated. For genesis, use the newly added send_enabled field in the genesis object. Storage, lookup, and manipulation of this information is now in the keeper. As of cosmos-sdk 0.47, this only exists for backwards compatibility of genesis files. default_send_enabled: type: boolean description: Params defines the parameters for the bank module. description: >- QueryParamsResponse defines the response type for querying x/bank parameters. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/bank/v1beta1/send_enabled: get: summary: SendEnabled queries for SendEnabled entries. description: >- This query only returns denominations that have specific SendEnabled settings. Any denomination that does not have a specific setting will use the default params.default_send_enabled, and will not be returned by this query. Since: cosmos-sdk 0.47 operationId: SendEnabled_V2SG0 responses: '200': description: A successful response. schema: type: object properties: send_enabled: type: array items: type: object properties: denom: type: string enabled: type: boolean description: >- SendEnabled maps coin denom to a send_enabled status (whether a denom is sendable). pagination: description: >- pagination defines the pagination in the response. This field is only populated if the denoms field in the request is empty. type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- QuerySendEnabledResponse defines the RPC response of a SendEnable query. Since: cosmos-sdk 0.47 default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: denoms description: >- denoms is the specific denoms you want look up. Leave empty to get all entries. in: query required: false type: array items: type: string collectionFormat: multi - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmos/bank/v1beta1/spendable_balances/{address}: get: summary: >- SpendableBalances queries the spendable balance of all coins for a single account. description: >- When called from another module, this query might consume a high amount of gas if the pagination field is incorrectly set. Since: cosmos-sdk 0.46 operationId: SpendableBalances_NOU7D responses: '200': description: A successful response. schema: type: object properties: balances: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: balances is the spendable balances of all the coins. pagination: description: pagination defines the pagination in the response. type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- QuerySpendableBalancesResponse defines the gRPC response structure for querying an account's spendable balances. Since: cosmos-sdk 0.46 default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: address description: address is the address to query spendable balances for. in: path required: true type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmos/bank/v1beta1/spendable_balances/{address}/by_denom: get: summary: >- SpendableBalanceByDenom queries the spendable balance of a single denom for a single account. description: >- When called from another module, this query might consume a high amount of gas if the pagination field is incorrectly set. Since: cosmos-sdk 0.47 operationId: SpendableBalanceByDenom_IY25V responses: '200': description: A successful response. schema: type: object properties: balance: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- QuerySpendableBalanceByDenomResponse defines the gRPC response structure for querying an account's spendable balance for a specific denom. Since: cosmos-sdk 0.47 default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: address description: address is the address to query balances for. in: path required: true type: string - name: denom description: denom is the coin denom to query balances for. in: query required: false type: string tags: - gRPC Gateway API /cosmos/bank/v1beta1/supply: get: summary: TotalSupply queries the total supply of all coins. description: >- When called from another module, this query might consume a high amount of gas if the pagination field is incorrectly set. operationId: TotalSupply_LCA37 responses: '200': description: A successful response. schema: type: object properties: supply: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: supply is the supply of the coins pagination: description: |- pagination defines the pagination in the response. Since: cosmos-sdk 0.43 type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise title: >- QueryTotalSupplyResponse is the response type for the Query/TotalSupply RPC method default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmos/bank/v1beta1/supply/by_denom: get: summary: SupplyOf queries the supply of a single coin. description: >- When called from another module, this query might consume a high amount of gas if the pagination field is incorrectly set. operationId: SupplyOf_PD96O responses: '200': description: A successful response. schema: type: object properties: amount: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- QuerySupplyOfResponse is the response type for the Query/SupplyOf RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: denom description: denom is the coin denom to query balances for. in: query required: false type: string tags: - gRPC Gateway API /ibc/core/connection/v1/client_connections/{client_id}: get: summary: |- ClientConnections queries the connection paths associated with a client state. operationId: ClientConnections_ULSVA responses: '200': description: A successful response. schema: type: object properties: connection_paths: type: array items: type: string description: slice of all the connection paths associated with a client. proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was generated type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryClientConnectionsResponse is the response type for the Query/ClientConnections RPC method default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: client_id description: client identifier associated with a connection in: path required: true type: string tags: - gRPC Gateway API /ibc/core/connection/v1/connections: get: summary: Connections queries all the IBC connections of a chain. operationId: Connections_KUGQB responses: '200': description: A successful response. schema: type: object properties: connections: type: array items: type: object properties: id: type: string description: connection identifier. client_id: type: string description: client associated with this connection. versions: type: array items: type: object properties: identifier: type: string title: unique version identifier features: type: array items: type: string title: >- list of features compatible with the specified identifier description: >- Version defines the versioning scheme used to negotiate the IBC verison in the connection handshake. title: >- IBC version which can be utilised to determine encodings or protocols for channels or packets utilising this connection state: description: current state of the connection end. type: string enum: - STATE_UNINITIALIZED_UNSPECIFIED - STATE_INIT - STATE_TRYOPEN - STATE_OPEN default: STATE_UNINITIALIZED_UNSPECIFIED counterparty: description: counterparty chain associated with this connection. type: object properties: client_id: type: string description: >- identifies the client on the counterparty chain associated with a given connection. connection_id: type: string description: >- identifies the connection end on the counterparty chain associated with a given connection. prefix: description: commitment merkle prefix of the counterparty chain. type: object properties: key_prefix: type: string format: byte title: >- MerklePrefix is merkle path prefixed to the key. The constructed key from the Path and the key will be append(Path.KeyPath, append(Path.KeyPrefix, key...)) delay_period: type: string format: uint64 description: delay period associated with this connection. description: >- IdentifiedConnection defines a connection with additional connection identifier field. description: list of stored connections of the chain. pagination: title: pagination response type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } height: title: query block height type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset description: >- QueryConnectionsResponse is the response type for the Query/Connections RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /ibc/core/connection/v1/connections/{connection_id}: get: summary: Connection queries an IBC connection end. operationId: Connection_OOALY responses: '200': description: A successful response. schema: type: object properties: connection: title: connection associated with the request identifier type: object properties: client_id: type: string description: client associated with this connection. versions: type: array items: type: object properties: identifier: type: string title: unique version identifier features: type: array items: type: string title: >- list of features compatible with the specified identifier description: >- Version defines the versioning scheme used to negotiate the IBC verison in the connection handshake. description: >- IBC version which can be utilised to determine encodings or protocols for channels or packets utilising this connection. state: description: current state of the connection end. type: string enum: - STATE_UNINITIALIZED_UNSPECIFIED - STATE_INIT - STATE_TRYOPEN - STATE_OPEN default: STATE_UNINITIALIZED_UNSPECIFIED counterparty: description: counterparty chain associated with this connection. type: object properties: client_id: type: string description: >- identifies the client on the counterparty chain associated with a given connection. connection_id: type: string description: >- identifies the connection end on the counterparty chain associated with a given connection. prefix: description: commitment merkle prefix of the counterparty chain. type: object properties: key_prefix: type: string format: byte title: >- MerklePrefix is merkle path prefixed to the key. The constructed key from the Path and the key will be append(Path.KeyPath, append(Path.KeyPrefix, key...)) delay_period: type: string format: uint64 description: >- delay period that must pass before a consensus state can be used for packet-verification NOTE: delay period logic is only implemented by some clients. description: >- ConnectionEnd defines a stateful object on a chain connected to another separate one. NOTE: there must only be 2 defined ConnectionEnds to establish a connection between two chains. proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset description: >- QueryConnectionResponse is the response type for the Query/Connection RPC method. Besides the connection end, it includes a proof and the height from which the proof was retrieved. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: connection_id description: connection unique identifier in: path required: true type: string tags: - gRPC Gateway API /ibc/core/connection/v1/connections/{connection_id}/client_state: get: summary: |- ConnectionClientState queries the client state associated with the connection. operationId: ConnectionClientState_E50ZS responses: '200': description: A successful response. schema: type: object properties: identified_client_state: title: client state associated with the channel type: object properties: client_id: type: string title: client identifier client_state: type: object properties: type_url: type: string value: type: string format: byte title: client state description: >- IdentifiedClientState defines a client state with an additional client identifier field. proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryConnectionClientStateResponse is the response type for the Query/ConnectionClientState RPC method default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: connection_id description: connection identifier in: path required: true type: string tags: - gRPC Gateway API /ibc/core/connection/v1/connections/{connection_id}/consensus_state/revision/{revision_number}/height/{revision_height}: get: summary: |- ConnectionConsensusState queries the consensus state associated with the connection. operationId: ConnectionConsensusState_R48NV responses: '200': description: A successful response. schema: type: object properties: consensus_state: type: object properties: type_url: type: string value: type: string format: byte title: consensus state associated with the channel client_id: type: string title: client ID associated with the consensus state proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryConnectionConsensusStateResponse is the response type for the Query/ConnectionConsensusState RPC method default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: connection_id description: connection identifier in: path required: true type: string - name: revision_number in: path required: true type: string format: uint64 - name: revision_height in: path required: true type: string format: uint64 tags: - gRPC Gateway API /ibc/core/connection/v1/params: get: summary: ConnectionParams queries all parameters of the ibc connection submodule. operationId: ConnectionParams_FN616 responses: '200': description: A successful response. schema: type: object properties: params: description: params defines the parameters of the module. type: object properties: max_expected_time_per_block: type: string format: uint64 description: >- maximum expected time per block (in nanoseconds), used to enforce block delay. This parameter should reflect the largest amount of time that the chain might reasonably take to produce the next block under normal operating conditions. A safe choice is 3-5x the expected time per block. description: >- QueryConnectionParamsResponse is the response type for the Query/ConnectionParams RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cyber/grid/v1beta1/grid/destination_routed_energy: get: operationId: DestinationRoutedEnergy_1UWZP responses: '200': description: A successful response. schema: type: object properties: value: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: destination in: query required: false type: string tags: - gRPC Gateway API /cyber/grid/v1beta1/grid/destination_routes: get: operationId: DestinationRoutes_DSHVX responses: '200': description: A successful response. schema: type: object properties: routes: type: array items: type: object properties: source: type: string destination: type: string name: type: string value: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: destination in: query required: false type: string tags: - gRPC Gateway API /cyber/grid/v1beta1/grid/params: get: operationId: Params_JC8T4 responses: '200': description: A successful response. schema: type: object properties: params: type: object properties: max_routes: type: integer format: int64 default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cyber/grid/v1beta1/grid/route: get: operationId: Route_DJV9M responses: '200': description: A successful response. schema: type: object properties: route: type: object properties: source: type: string destination: type: string name: type: string value: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: source in: query required: false type: string - name: destination in: query required: false type: string tags: - gRPC Gateway API /cyber/grid/v1beta1/grid/routes: get: operationId: Routes_NX6XT responses: '200': description: A successful response. schema: type: object properties: routes: type: array items: type: object properties: source: type: string destination: type: string name: type: string value: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cyber/grid/v1beta1/grid/source_routed_energy: get: operationId: SourceRoutedEnergy_15BGT responses: '200': description: A successful response. schema: type: object properties: value: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: source in: query required: false type: string tags: - gRPC Gateway API /cyber/grid/v1beta1/grid/source_routes: get: operationId: SourceRoutes_0YJSZ responses: '200': description: A successful response. schema: type: object properties: routes: type: array items: type: object properties: source: type: string destination: type: string name: type: string value: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: source in: query required: false type: string tags: - gRPC Gateway API /cyber/dmn/v1beta1/dmn/params: get: operationId: Params_KSBWO responses: '200': description: A successful response. schema: type: object properties: params: type: object properties: max_slots: type: integer format: int64 max_gas: type: integer format: int64 fee_ttl: type: integer format: int64 default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cyber/dmn/v1beta1/dmn/thought: get: operationId: Thought_N9WGE responses: '200': description: A successful response. schema: type: object properties: thought: type: object properties: program: type: string trigger: type: object properties: period: type: string format: uint64 block: type: string format: uint64 load: type: object properties: input: type: string gas_price: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. name: type: string particle: type: string default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: program in: query required: false type: string - name: name in: query required: false type: string tags: - gRPC Gateway API /cyber/dmn/v1beta1/dmn/thought_stats: get: operationId: ThoughtStats_N3IA1 responses: '200': description: A successful response. schema: type: object properties: thought_stats: type: object properties: program: type: string name: type: string calls: type: string format: uint64 fees: type: string format: uint64 gas: type: string format: uint64 last_block: type: string format: uint64 default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: program in: query required: false type: string - name: name in: query required: false type: string tags: - gRPC Gateway API /cyber/dmn/v1beta1/dmn/thoughts: get: operationId: Thoughts_U2UB0 responses: '200': description: A successful response. schema: type: object properties: thoughts: type: array items: type: object properties: program: type: string trigger: type: object properties: period: type: string format: uint64 block: type: string format: uint64 load: type: object properties: input: type: string gas_price: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. name: type: string particle: type: string default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cyber/dmn/v1beta1/dmn/thoughts_fees: get: operationId: ThoughtsFees_WJZMQ responses: '200': description: A successful response. schema: type: object properties: fees: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cyber/dmn/v1beta1/dmn/thoughts_stats: get: operationId: ThoughtsStats_FOF22 responses: '200': description: A successful response. schema: type: object properties: thoughts_stats: type: array items: type: object properties: program: type: string name: type: string calls: type: string format: uint64 fees: type: string format: uint64 gas: type: string format: uint64 last_block: type: string format: uint64 default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/staking/v1beta1/delegations/{delegator_addr}: get: summary: >- DelegatorDelegations queries all delegations of a given delegator address. description: >- When called from another module, this query might consume a high amount of gas if the pagination field is incorrectly set. operationId: DelegatorDelegations_5SDKK responses: '200': description: A successful response. schema: type: object properties: delegation_responses: type: array items: type: object properties: delegation: type: object properties: delegator_address: type: string description: >- delegator_address is the bech32-encoded address of the delegator. validator_address: type: string description: >- validator_address is the bech32-encoded address of the validator. shares: type: string description: shares define the delegation shares received. description: >- Delegation represents the bond with tokens held by an account. It is owned by one delegator, and is associated with the voting power of one validator. balance: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- DelegationResponse is equivalent to Delegation except that it contains a balance in addition to shares which is more suitable for client responses. description: >- delegation_responses defines all the delegations' info of a delegator. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: |- QueryDelegatorDelegationsResponse is response type for the Query/DelegatorDelegations RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: delegator_addr description: delegator_addr defines the delegator address to query for. in: path required: true type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmos/staking/v1beta1/delegators/{delegator_addr}/redelegations: get: summary: Redelegations queries redelegations of given address. description: >- When called from another module, this query might consume a high amount of gas if the pagination field is incorrectly set. operationId: Redelegations_V11SE responses: '200': description: A successful response. schema: type: object properties: redelegation_responses: type: array items: type: object properties: redelegation: type: object properties: delegator_address: type: string description: >- delegator_address is the bech32-encoded address of the delegator. validator_src_address: type: string description: >- validator_src_address is the validator redelegation source operator address. validator_dst_address: type: string description: >- validator_dst_address is the validator redelegation destination operator address. entries: type: array items: type: object properties: creation_height: type: string format: int64 description: >- creation_height defines the height which the redelegation took place. completion_time: type: string format: date-time description: >- completion_time defines the unix time for redelegation completion. initial_balance: type: string description: >- initial_balance defines the initial balance when redelegation started. shares_dst: type: string description: >- shares_dst is the amount of destination-validator shares created by redelegation. unbonding_id: type: string format: uint64 title: >- Incrementing id that uniquely identifies this entry unbonding_on_hold_ref_count: type: string format: int64 title: >- Strictly positive if this entry's unbonding has been stopped by external modules description: >- RedelegationEntry defines a redelegation object with relevant metadata. description: entries are the redelegation entries. description: >- Redelegation contains the list of a particular delegator's redelegating bonds from a particular source validator to a particular destination validator. entries: type: array items: type: object properties: redelegation_entry: type: object properties: creation_height: type: string format: int64 description: >- creation_height defines the height which the redelegation took place. completion_time: type: string format: date-time description: >- completion_time defines the unix time for redelegation completion. initial_balance: type: string description: >- initial_balance defines the initial balance when redelegation started. shares_dst: type: string description: >- shares_dst is the amount of destination-validator shares created by redelegation. unbonding_id: type: string format: uint64 title: >- Incrementing id that uniquely identifies this entry unbonding_on_hold_ref_count: type: string format: int64 title: >- Strictly positive if this entry's unbonding has been stopped by external modules description: >- RedelegationEntry defines a redelegation object with relevant metadata. balance: type: string description: >- RedelegationEntryResponse is equivalent to a RedelegationEntry except that it contains a balance in addition to shares which is more suitable for client responses. description: >- RedelegationResponse is equivalent to a Redelegation except that its entries contain a balance in addition to shares which is more suitable for client responses. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- QueryRedelegationsResponse is response type for the Query/Redelegations RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: delegator_addr description: delegator_addr defines the delegator address to query for. in: path required: true type: string - name: src_validator_addr description: src_validator_addr defines the validator address to redelegate from. in: query required: false type: string - name: dst_validator_addr description: dst_validator_addr defines the validator address to redelegate to. in: query required: false type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmos/staking/v1beta1/delegators/{delegator_addr}/unbonding_delegations: get: summary: >- DelegatorUnbondingDelegations queries all unbonding delegations of a given delegator address. description: >- When called from another module, this query might consume a high amount of gas if the pagination field is incorrectly set. operationId: DelegatorUnbondingDelegations_PWG9M responses: '200': description: A successful response. schema: type: object properties: unbonding_responses: type: array items: type: object properties: delegator_address: type: string description: >- delegator_address is the bech32-encoded address of the delegator. validator_address: type: string description: >- validator_address is the bech32-encoded address of the validator. entries: type: array items: type: object properties: creation_height: type: string format: int64 description: >- creation_height is the height which the unbonding took place. completion_time: type: string format: date-time description: >- completion_time is the unix time for unbonding completion. initial_balance: type: string description: >- initial_balance defines the tokens initially scheduled to receive at completion. balance: type: string description: >- balance defines the tokens to receive at completion. unbonding_id: type: string format: uint64 title: >- Incrementing id that uniquely identifies this entry unbonding_on_hold_ref_count: type: string format: int64 title: >- Strictly positive if this entry's unbonding has been stopped by external modules description: >- UnbondingDelegationEntry defines an unbonding object with relevant metadata. description: entries are the unbonding delegation entries. description: >- UnbondingDelegation stores all of a single delegator's unbonding bonds for a single validator in an time-ordered list. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- QueryUnbondingDelegatorDelegationsResponse is response type for the Query/UnbondingDelegatorDelegations RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: delegator_addr description: delegator_addr defines the delegator address to query for. in: path required: true type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmos/staking/v1beta1/delegators/{delegator_addr}/validators: get: summary: |- DelegatorValidators queries all validators info for given delegator address. description: >- When called from another module, this query might consume a high amount of gas if the pagination field is incorrectly set. operationId: DelegatorValidators_ODLEN responses: '200': description: A successful response. schema: type: object properties: validators: type: array items: type: object properties: operator_address: type: string description: >- operator_address defines the address of the validator's operator; bech encoded in JSON. consensus_pubkey: type: object properties: type_url: type: string value: type: string format: byte description: >- consensus_pubkey is the consensus public key of the validator, as a Protobuf Any. jailed: type: boolean description: >- jailed defined whether the validator has been jailed from bonded status or not. status: description: >- status is the validator status (bonded/unbonding/unbonded). type: string enum: - BOND_STATUS_UNSPECIFIED - BOND_STATUS_UNBONDED - BOND_STATUS_UNBONDING - BOND_STATUS_BONDED default: BOND_STATUS_UNSPECIFIED tokens: type: string description: >- tokens define the delegated tokens (incl. self-delegation). delegator_shares: type: string description: >- delegator_shares defines total shares issued to a validator's delegators. description: description: >- description defines the description terms for the validator. type: object properties: moniker: type: string description: >- moniker defines a human-readable name for the validator. identity: type: string description: >- identity defines an optional identity signature (ex. UPort or Keybase). website: type: string description: website defines an optional website link. security_contact: type: string description: >- security_contact defines an optional email for security contact. details: type: string description: details define other optional details. unbonding_height: type: string format: int64 description: >- unbonding_height defines, if unbonding, the height at which this validator has begun unbonding. unbonding_time: type: string format: date-time description: >- unbonding_time defines, if unbonding, the min time for the validator to complete unbonding. commission: description: commission defines the commission parameters. type: object properties: commission_rates: description: >- commission_rates defines the initial commission rates to be used for creating a validator. type: object properties: rate: type: string description: >- rate is the commission rate charged to delegators, as a fraction. max_rate: type: string description: >- max_rate defines the maximum commission rate which validator can ever charge, as a fraction. max_change_rate: type: string description: >- max_change_rate defines the maximum daily increase of the validator commission, as a fraction. update_time: type: string format: date-time description: >- update_time is the last time the commission rate was changed. min_self_delegation: type: string description: >- min_self_delegation is the validator's self declared minimum self delegation. Since: cosmos-sdk 0.46 unbonding_on_hold_ref_count: type: string format: int64 title: >- strictly positive if this validator's unbonding has been stopped by external modules unbonding_ids: type: array items: type: string format: uint64 title: >- list of unbonding ids, each uniquely identifing an unbonding of this validator description: >- Validator defines a validator, together with the total amount of the Validator's bond shares and their exchange rate to coins. Slashing results in a decrease in the exchange rate, allowing correct calculation of future undelegations without iterating over delegators. When coins are delegated to this validator, the validator is credited with a delegation whose number of bond shares is based on the amount of coins delegated divided by the current exchange rate. Voting power can be calculated as total bonded shares multiplied by exchange rate. description: validators defines the validators' info of a delegator. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: |- QueryDelegatorValidatorsResponse is response type for the Query/DelegatorValidators RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: delegator_addr description: delegator_addr defines the delegator address to query for. in: path required: true type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmos/staking/v1beta1/delegators/{delegator_addr}/validators/{validator_addr}: get: summary: |- DelegatorValidator queries validator info for given delegator validator pair. operationId: DelegatorValidator_4VGVV responses: '200': description: A successful response. schema: type: object properties: validator: type: object properties: operator_address: type: string description: >- operator_address defines the address of the validator's operator; bech encoded in JSON. consensus_pubkey: type: object properties: type_url: type: string value: type: string format: byte description: >- consensus_pubkey is the consensus public key of the validator, as a Protobuf Any. jailed: type: boolean description: >- jailed defined whether the validator has been jailed from bonded status or not. status: description: >- status is the validator status (bonded/unbonding/unbonded). type: string enum: - BOND_STATUS_UNSPECIFIED - BOND_STATUS_UNBONDED - BOND_STATUS_UNBONDING - BOND_STATUS_BONDED default: BOND_STATUS_UNSPECIFIED tokens: type: string description: >- tokens define the delegated tokens (incl. self-delegation). delegator_shares: type: string description: >- delegator_shares defines total shares issued to a validator's delegators. description: description: >- description defines the description terms for the validator. type: object properties: moniker: type: string description: >- moniker defines a human-readable name for the validator. identity: type: string description: >- identity defines an optional identity signature (ex. UPort or Keybase). website: type: string description: website defines an optional website link. security_contact: type: string description: >- security_contact defines an optional email for security contact. details: type: string description: details define other optional details. unbonding_height: type: string format: int64 description: >- unbonding_height defines, if unbonding, the height at which this validator has begun unbonding. unbonding_time: type: string format: date-time description: >- unbonding_time defines, if unbonding, the min time for the validator to complete unbonding. commission: description: commission defines the commission parameters. type: object properties: commission_rates: description: >- commission_rates defines the initial commission rates to be used for creating a validator. type: object properties: rate: type: string description: >- rate is the commission rate charged to delegators, as a fraction. max_rate: type: string description: >- max_rate defines the maximum commission rate which validator can ever charge, as a fraction. max_change_rate: type: string description: >- max_change_rate defines the maximum daily increase of the validator commission, as a fraction. update_time: type: string format: date-time description: >- update_time is the last time the commission rate was changed. min_self_delegation: type: string description: >- min_self_delegation is the validator's self declared minimum self delegation. Since: cosmos-sdk 0.46 unbonding_on_hold_ref_count: type: string format: int64 title: >- strictly positive if this validator's unbonding has been stopped by external modules unbonding_ids: type: array items: type: string format: uint64 title: >- list of unbonding ids, each uniquely identifing an unbonding of this validator description: >- Validator defines a validator, together with the total amount of the Validator's bond shares and their exchange rate to coins. Slashing results in a decrease in the exchange rate, allowing correct calculation of future undelegations without iterating over delegators. When coins are delegated to this validator, the validator is credited with a delegation whose number of bond shares is based on the amount of coins delegated divided by the current exchange rate. Voting power can be calculated as total bonded shares multiplied by exchange rate. description: |- QueryDelegatorValidatorResponse response type for the Query/DelegatorValidator RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: delegator_addr description: delegator_addr defines the delegator address to query for. in: path required: true type: string - name: validator_addr description: validator_addr defines the validator address to query for. in: path required: true type: string tags: - gRPC Gateway API /cosmos/staking/v1beta1/historical_info/{height}: get: summary: HistoricalInfo queries the historical info for given height. operationId: HistoricalInfo_5WZCR responses: '200': description: A successful response. schema: type: object properties: hist: description: hist defines the historical info at the given height. type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. valset: type: array items: type: object properties: operator_address: type: string description: >- operator_address defines the address of the validator's operator; bech encoded in JSON. consensus_pubkey: type: object properties: type_url: type: string value: type: string format: byte description: >- consensus_pubkey is the consensus public key of the validator, as a Protobuf Any. jailed: type: boolean description: >- jailed defined whether the validator has been jailed from bonded status or not. status: description: >- status is the validator status (bonded/unbonding/unbonded). type: string enum: - BOND_STATUS_UNSPECIFIED - BOND_STATUS_UNBONDED - BOND_STATUS_UNBONDING - BOND_STATUS_BONDED default: BOND_STATUS_UNSPECIFIED tokens: type: string description: >- tokens define the delegated tokens (incl. self-delegation). delegator_shares: type: string description: >- delegator_shares defines total shares issued to a validator's delegators. description: description: >- description defines the description terms for the validator. type: object properties: moniker: type: string description: >- moniker defines a human-readable name for the validator. identity: type: string description: >- identity defines an optional identity signature (ex. UPort or Keybase). website: type: string description: website defines an optional website link. security_contact: type: string description: >- security_contact defines an optional email for security contact. details: type: string description: details define other optional details. unbonding_height: type: string format: int64 description: >- unbonding_height defines, if unbonding, the height at which this validator has begun unbonding. unbonding_time: type: string format: date-time description: >- unbonding_time defines, if unbonding, the min time for the validator to complete unbonding. commission: description: commission defines the commission parameters. type: object properties: commission_rates: description: >- commission_rates defines the initial commission rates to be used for creating a validator. type: object properties: rate: type: string description: >- rate is the commission rate charged to delegators, as a fraction. max_rate: type: string description: >- max_rate defines the maximum commission rate which validator can ever charge, as a fraction. max_change_rate: type: string description: >- max_change_rate defines the maximum daily increase of the validator commission, as a fraction. update_time: type: string format: date-time description: >- update_time is the last time the commission rate was changed. min_self_delegation: type: string description: >- min_self_delegation is the validator's self declared minimum self delegation. Since: cosmos-sdk 0.46 unbonding_on_hold_ref_count: type: string format: int64 title: >- strictly positive if this validator's unbonding has been stopped by external modules unbonding_ids: type: array items: type: string format: uint64 title: >- list of unbonding ids, each uniquely identifing an unbonding of this validator description: >- Validator defines a validator, together with the total amount of the Validator's bond shares and their exchange rate to coins. Slashing results in a decrease in the exchange rate, allowing correct calculation of future undelegations without iterating over delegators. When coins are delegated to this validator, the validator is credited with a delegation whose number of bond shares is based on the amount of coins delegated divided by the current exchange rate. Voting power can be calculated as total bonded shares multiplied by exchange rate. description: >- QueryHistoricalInfoResponse is response type for the Query/HistoricalInfo RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: height description: height defines at which height to query the historical info. in: path required: true type: string format: int64 tags: - gRPC Gateway API /cosmos/staking/v1beta1/params: get: summary: Parameters queries the staking parameters. operationId: Params_2OHI6 responses: '200': description: A successful response. schema: type: object properties: params: description: params holds all the parameters of this module. type: object properties: unbonding_time: type: string description: unbonding_time is the time duration of unbonding. max_validators: type: integer format: int64 description: max_validators is the maximum number of validators. max_entries: type: integer format: int64 description: >- max_entries is the max entries for either unbonding delegation or redelegation (per pair/trio). historical_entries: type: integer format: int64 description: >- historical_entries is the number of historical entries to persist. bond_denom: type: string description: bond_denom defines the bondable coin denomination. min_commission_rate: type: string title: >- min_commission_rate is the chain-wide minimum commission rate that a validator can charge their delegators description: >- QueryParamsResponse is response type for the Query/Params RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/staking/v1beta1/pool: get: summary: Pool queries the pool info. operationId: Pool_YT1XX responses: '200': description: A successful response. schema: type: object properties: pool: description: pool defines the pool info. type: object properties: not_bonded_tokens: type: string bonded_tokens: type: string description: QueryPoolResponse is response type for the Query/Pool RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/staking/v1beta1/validators: get: summary: Validators queries all validators that match the given status. description: >- When called from another module, this query might consume a high amount of gas if the pagination field is incorrectly set. operationId: Validators_8C5VK responses: '200': description: A successful response. schema: type: object properties: validators: type: array items: type: object properties: operator_address: type: string description: >- operator_address defines the address of the validator's operator; bech encoded in JSON. consensus_pubkey: type: object properties: type_url: type: string value: type: string format: byte description: >- consensus_pubkey is the consensus public key of the validator, as a Protobuf Any. jailed: type: boolean description: >- jailed defined whether the validator has been jailed from bonded status or not. status: description: >- status is the validator status (bonded/unbonding/unbonded). type: string enum: - BOND_STATUS_UNSPECIFIED - BOND_STATUS_UNBONDED - BOND_STATUS_UNBONDING - BOND_STATUS_BONDED default: BOND_STATUS_UNSPECIFIED tokens: type: string description: >- tokens define the delegated tokens (incl. self-delegation). delegator_shares: type: string description: >- delegator_shares defines total shares issued to a validator's delegators. description: description: >- description defines the description terms for the validator. type: object properties: moniker: type: string description: >- moniker defines a human-readable name for the validator. identity: type: string description: >- identity defines an optional identity signature (ex. UPort or Keybase). website: type: string description: website defines an optional website link. security_contact: type: string description: >- security_contact defines an optional email for security contact. details: type: string description: details define other optional details. unbonding_height: type: string format: int64 description: >- unbonding_height defines, if unbonding, the height at which this validator has begun unbonding. unbonding_time: type: string format: date-time description: >- unbonding_time defines, if unbonding, the min time for the validator to complete unbonding. commission: description: commission defines the commission parameters. type: object properties: commission_rates: description: >- commission_rates defines the initial commission rates to be used for creating a validator. type: object properties: rate: type: string description: >- rate is the commission rate charged to delegators, as a fraction. max_rate: type: string description: >- max_rate defines the maximum commission rate which validator can ever charge, as a fraction. max_change_rate: type: string description: >- max_change_rate defines the maximum daily increase of the validator commission, as a fraction. update_time: type: string format: date-time description: >- update_time is the last time the commission rate was changed. min_self_delegation: type: string description: >- min_self_delegation is the validator's self declared minimum self delegation. Since: cosmos-sdk 0.46 unbonding_on_hold_ref_count: type: string format: int64 title: >- strictly positive if this validator's unbonding has been stopped by external modules unbonding_ids: type: array items: type: string format: uint64 title: >- list of unbonding ids, each uniquely identifing an unbonding of this validator description: >- Validator defines a validator, together with the total amount of the Validator's bond shares and their exchange rate to coins. Slashing results in a decrease in the exchange rate, allowing correct calculation of future undelegations without iterating over delegators. When coins are delegated to this validator, the validator is credited with a delegation whose number of bond shares is based on the amount of coins delegated divided by the current exchange rate. Voting power can be calculated as total bonded shares multiplied by exchange rate. description: validators contains all the queried validators. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: >- QueryValidatorsResponse is response type for the Query/Validators RPC method default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: status description: status enables to query for validators matching a given status. in: query required: false type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmos/staking/v1beta1/validators/{validator_addr}: get: summary: Validator queries validator info for given validator address. operationId: Validator_50V8E responses: '200': description: A successful response. schema: type: object properties: validator: type: object properties: operator_address: type: string description: >- operator_address defines the address of the validator's operator; bech encoded in JSON. consensus_pubkey: type: object properties: type_url: type: string value: type: string format: byte description: >- consensus_pubkey is the consensus public key of the validator, as a Protobuf Any. jailed: type: boolean description: >- jailed defined whether the validator has been jailed from bonded status or not. status: description: >- status is the validator status (bonded/unbonding/unbonded). type: string enum: - BOND_STATUS_UNSPECIFIED - BOND_STATUS_UNBONDED - BOND_STATUS_UNBONDING - BOND_STATUS_BONDED default: BOND_STATUS_UNSPECIFIED tokens: type: string description: >- tokens define the delegated tokens (incl. self-delegation). delegator_shares: type: string description: >- delegator_shares defines total shares issued to a validator's delegators. description: description: >- description defines the description terms for the validator. type: object properties: moniker: type: string description: >- moniker defines a human-readable name for the validator. identity: type: string description: >- identity defines an optional identity signature (ex. UPort or Keybase). website: type: string description: website defines an optional website link. security_contact: type: string description: >- security_contact defines an optional email for security contact. details: type: string description: details define other optional details. unbonding_height: type: string format: int64 description: >- unbonding_height defines, if unbonding, the height at which this validator has begun unbonding. unbonding_time: type: string format: date-time description: >- unbonding_time defines, if unbonding, the min time for the validator to complete unbonding. commission: description: commission defines the commission parameters. type: object properties: commission_rates: description: >- commission_rates defines the initial commission rates to be used for creating a validator. type: object properties: rate: type: string description: >- rate is the commission rate charged to delegators, as a fraction. max_rate: type: string description: >- max_rate defines the maximum commission rate which validator can ever charge, as a fraction. max_change_rate: type: string description: >- max_change_rate defines the maximum daily increase of the validator commission, as a fraction. update_time: type: string format: date-time description: >- update_time is the last time the commission rate was changed. min_self_delegation: type: string description: >- min_self_delegation is the validator's self declared minimum self delegation. Since: cosmos-sdk 0.46 unbonding_on_hold_ref_count: type: string format: int64 title: >- strictly positive if this validator's unbonding has been stopped by external modules unbonding_ids: type: array items: type: string format: uint64 title: >- list of unbonding ids, each uniquely identifing an unbonding of this validator description: >- Validator defines a validator, together with the total amount of the Validator's bond shares and their exchange rate to coins. Slashing results in a decrease in the exchange rate, allowing correct calculation of future undelegations without iterating over delegators. When coins are delegated to this validator, the validator is credited with a delegation whose number of bond shares is based on the amount of coins delegated divided by the current exchange rate. Voting power can be calculated as total bonded shares multiplied by exchange rate. title: >- QueryValidatorResponse is response type for the Query/Validator RPC method default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: validator_addr description: validator_addr defines the validator address to query for. in: path required: true type: string tags: - gRPC Gateway API /cosmos/staking/v1beta1/validators/{validator_addr}/delegations: get: summary: ValidatorDelegations queries delegate info for given validator. description: >- When called from another module, this query might consume a high amount of gas if the pagination field is incorrectly set. operationId: ValidatorDelegations_WQPT6 responses: '200': description: A successful response. schema: type: object properties: delegation_responses: type: array items: type: object properties: delegation: type: object properties: delegator_address: type: string description: >- delegator_address is the bech32-encoded address of the delegator. validator_address: type: string description: >- validator_address is the bech32-encoded address of the validator. shares: type: string description: shares define the delegation shares received. description: >- Delegation represents the bond with tokens held by an account. It is owned by one delegator, and is associated with the voting power of one validator. balance: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- DelegationResponse is equivalent to Delegation except that it contains a balance in addition to shares which is more suitable for client responses. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: |- QueryValidatorDelegationsResponse is response type for the Query/ValidatorDelegations RPC method default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: validator_addr description: validator_addr defines the validator address to query for. in: path required: true type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmos/staking/v1beta1/validators/{validator_addr}/delegations/{delegator_addr}: get: summary: Delegation queries delegate info for given validator delegator pair. operationId: Delegation_KEKGD responses: '200': description: A successful response. schema: type: object properties: delegation_response: type: object properties: delegation: type: object properties: delegator_address: type: string description: >- delegator_address is the bech32-encoded address of the delegator. validator_address: type: string description: >- validator_address is the bech32-encoded address of the validator. shares: type: string description: shares define the delegation shares received. description: >- Delegation represents the bond with tokens held by an account. It is owned by one delegator, and is associated with the voting power of one validator. balance: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- DelegationResponse is equivalent to Delegation except that it contains a balance in addition to shares which is more suitable for client responses. description: >- QueryDelegationResponse is response type for the Query/Delegation RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: validator_addr description: validator_addr defines the validator address to query for. in: path required: true type: string - name: delegator_addr description: delegator_addr defines the delegator address to query for. in: path required: true type: string tags: - gRPC Gateway API /cosmos/staking/v1beta1/validators/{validator_addr}/delegations/{delegator_addr}/unbonding_delegation: get: summary: |- UnbondingDelegation queries unbonding info for given validator delegator pair. operationId: UnbondingDelegation_ZYWZV responses: '200': description: A successful response. schema: type: object properties: unbond: type: object properties: delegator_address: type: string description: >- delegator_address is the bech32-encoded address of the delegator. validator_address: type: string description: >- validator_address is the bech32-encoded address of the validator. entries: type: array items: type: object properties: creation_height: type: string format: int64 description: >- creation_height is the height which the unbonding took place. completion_time: type: string format: date-time description: >- completion_time is the unix time for unbonding completion. initial_balance: type: string description: >- initial_balance defines the tokens initially scheduled to receive at completion. balance: type: string description: balance defines the tokens to receive at completion. unbonding_id: type: string format: uint64 title: Incrementing id that uniquely identifies this entry unbonding_on_hold_ref_count: type: string format: int64 title: >- Strictly positive if this entry's unbonding has been stopped by external modules description: >- UnbondingDelegationEntry defines an unbonding object with relevant metadata. description: entries are the unbonding delegation entries. description: >- UnbondingDelegation stores all of a single delegator's unbonding bonds for a single validator in an time-ordered list. description: >- QueryDelegationResponse is response type for the Query/UnbondingDelegation RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: validator_addr description: validator_addr defines the validator address to query for. in: path required: true type: string - name: delegator_addr description: delegator_addr defines the delegator address to query for. in: path required: true type: string tags: - gRPC Gateway API /cosmos/staking/v1beta1/validators/{validator_addr}/unbonding_delegations: get: summary: >- ValidatorUnbondingDelegations queries unbonding delegations of a validator. description: >- When called from another module, this query might consume a high amount of gas if the pagination field is incorrectly set. operationId: ValidatorUnbondingDelegations_2MTRI responses: '200': description: A successful response. schema: type: object properties: unbonding_responses: type: array items: type: object properties: delegator_address: type: string description: >- delegator_address is the bech32-encoded address of the delegator. validator_address: type: string description: >- validator_address is the bech32-encoded address of the validator. entries: type: array items: type: object properties: creation_height: type: string format: int64 description: >- creation_height is the height which the unbonding took place. completion_time: type: string format: date-time description: >- completion_time is the unix time for unbonding completion. initial_balance: type: string description: >- initial_balance defines the tokens initially scheduled to receive at completion. balance: type: string description: >- balance defines the tokens to receive at completion. unbonding_id: type: string format: uint64 title: >- Incrementing id that uniquely identifies this entry unbonding_on_hold_ref_count: type: string format: int64 title: >- Strictly positive if this entry's unbonding has been stopped by external modules description: >- UnbondingDelegationEntry defines an unbonding object with relevant metadata. description: entries are the unbonding delegation entries. description: >- UnbondingDelegation stores all of a single delegator's unbonding bonds for a single validator in an time-ordered list. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- QueryValidatorUnbondingDelegationsResponse is response type for the Query/ValidatorUnbondingDelegations RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: validator_addr description: validator_addr defines the validator address to query for. in: path required: true type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /ibc/apps/transfer/v1/channels/{channel_id}/ports/{port_id}/escrow_address: get: summary: >- EscrowAddress returns the escrow address for a particular port and channel id. operationId: EscrowAddress_H4ZU3 responses: '200': description: A successful response. schema: type: object properties: escrow_address: type: string title: the escrow account address description: >- QueryEscrowAddressResponse is the response type of the EscrowAddress RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: channel_id description: unique channel identifier in: path required: true type: string - name: port_id description: unique port identifier in: path required: true type: string tags: - gRPC Gateway API /ibc/apps/transfer/v1/denom_hashes/{trace}: get: summary: DenomHash queries a denomination hash information. operationId: DenomHash_BMCJ0 responses: '200': description: A successful response. schema: type: object properties: hash: type: string description: hash (in hex format) of the denomination trace information. description: >- QueryDenomHashResponse is the response type for the Query/DenomHash RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: trace description: The denomination trace ([port_id]/[channel_id])+/[denom] in: path required: true type: string tags: - gRPC Gateway API /ibc/apps/transfer/v1/denom_traces: get: summary: DenomTraces queries all denomination traces. operationId: DenomTraces_UYI2F responses: '200': description: A successful response. schema: type: object properties: denom_traces: type: array items: type: object properties: path: type: string description: >- path defines the chain of port/channel identifiers used for tracing the source of the fungible token. base_denom: type: string description: base denomination of the relayed fungible token. description: >- DenomTrace contains the base denomination for ICS20 fungible tokens and the source tracing information path. description: denom_traces returns all denominations trace information. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- QueryConnectionsResponse is the response type for the Query/DenomTraces RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /ibc/apps/transfer/v1/denom_traces/{hash}: get: summary: DenomTrace queries a denomination trace information. operationId: DenomTrace_3PQDP responses: '200': description: A successful response. schema: type: object properties: denom_trace: type: object properties: path: type: string description: >- path defines the chain of port/channel identifiers used for tracing the source of the fungible token. base_denom: type: string description: base denomination of the relayed fungible token. description: >- DenomTrace contains the base denomination for ICS20 fungible tokens and the source tracing information path. description: >- QueryDenomTraceResponse is the response type for the Query/DenomTrace RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: hash description: >- hash (in hex format) or denom (full denom with ibc prefix) of the denomination trace information. in: path required: true type: string tags: - gRPC Gateway API /ibc/apps/transfer/v1/denoms/{denom}/total_escrow: get: summary: >- TotalEscrowForDenom returns the total amount of tokens in escrow based on the denom. operationId: TotalEscrowForDenom_GBGAA responses: '200': description: A successful response. schema: type: object properties: amount: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- QueryTotalEscrowForDenomResponse is the response type for TotalEscrowForDenom RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: denom in: path required: true type: string tags: - gRPC Gateway API /ibc/apps/transfer/v1/params: get: summary: Params queries all parameters of the ibc-transfer module. operationId: Params_4CJ8D responses: '200': description: A successful response. schema: type: object properties: params: description: params defines the parameters of the module. type: object properties: send_enabled: type: boolean description: >- send_enabled enables or disables all cross-chain token transfers from this chain. receive_enabled: type: boolean description: >- receive_enabled enables or disables all cross-chain token transfers to this chain. description: >- QueryParamsResponse is the response type for the Query/Params RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/tx/v1beta1/decode: post: summary: TxDecode decodes the transaction. description: 'Since: cosmos-sdk 0.47' operationId: TxDecode_08PMV responses: '200': description: A successful response. schema: type: object properties: tx: description: tx is the decoded transaction. type: object properties: body: title: body is the processable content of the transaction type: object properties: messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- messages is a list of messages to be executed. The required signers of those messages define the number and order of elements in AuthInfo's signer_infos and Tx's signatures. Each required signer address is added to the list only the first time it occurs. By convention, the first required signer (usually from the first message) is referred to as the primary signer and pays the fee for the whole transaction. memo: type: string description: >- memo is any arbitrary note/comment to be added to the transaction. WARNING: in clients, any publicly exposed text should not be called memo, but should be called `note` instead (see https://github.com/cosmos/cosmos-sdk/issues/9122). timeout_height: type: string format: uint64 title: >- timeout is the block height after which this transaction will not be processed by the chain extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, the transaction will be rejected non_critical_extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, they will be ignored description: >- TxBody is the body of a transaction that all signers sign over. auth_info: title: >- auth_info is the authorization related content of the transaction, specifically signers, signer modes and fee type: object properties: signer_infos: type: array items: type: object properties: public_key: type: object properties: type_url: type: string value: type: string format: byte description: >- public_key is the public key of the signer. It is optional for accounts that already exist in state. If unset, the verifier can use the required \ signer address for this position and lookup the public key. mode_info: title: >- mode_info describes the signing mode of the signer and is a nested structure to support nested multisig pubkey's type: object properties: single: title: single represents a single signer type: object properties: mode: title: >- mode is the signing mode of the single signer type: string enum: - SIGN_MODE_UNSPECIFIED - SIGN_MODE_DIRECT - SIGN_MODE_TEXTUAL - SIGN_MODE_DIRECT_AUX - SIGN_MODE_LEGACY_AMINO_JSON - SIGN_MODE_EIP_191 default: SIGN_MODE_UNSPECIFIED description: >- SignMode represents a signing mode with its own security guarantees. This enum should be considered a registry of all known sign modes in the Cosmos ecosystem. Apps are not expected to support all known sign modes. Apps that would like to support custom sign modes are encouraged to open a small PR against this file to add a new case to this SignMode enum describing their sign mode so that different apps have a consistent version of this enum. - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be rejected. - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is verified with raw bytes from Tx. - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some human-readable textual representation on top of the binary representation from SIGN_MODE_DIRECT. It is currently not supported. - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses SignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not require signers signing over other signers' `signer_info`. It also allows for adding Tips in transactions. Since: cosmos-sdk 0.46 - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses Amino JSON and will be removed in the future. - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos SDK. Ref: https://eips.ethereum.org/EIPS/eip-191 Currently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant, but is not implemented on the SDK by default. To enable EIP-191, you need to pass a custom `TxConfig` that has an implementation of `SignModeHandler` for EIP-191. The SDK may decide to fully support EIP-191 in the future. Since: cosmos-sdk 0.45.2 multi: title: multi represents a nested multisig signer type: object properties: bitarray: title: >- bitarray specifies which keys within the multisig are signing type: object properties: extra_bits_stored: type: integer format: int64 elems: type: string format: byte description: >- CompactBitArray is an implementation of a space efficient bit array. This is used to ensure that the encoded data takes up a minimal amount of space after proto encoding. This is not thread safe, and is not intended for concurrent usage. mode_infos: type: array items: {} title: >- mode_infos is the corresponding modes of the signers of the multisig which could include nested multisig public keys description: >- ModeInfo describes the signing mode of a single or nested multisig signer. sequence: type: string format: uint64 description: >- sequence is the sequence of the account, which describes the number of committed transactions signed by a given address. It is used to prevent replay attacks. description: >- SignerInfo describes the public key and signing mode of a single top-level signer. description: >- signer_infos defines the signing modes for the required signers. The number and order of elements must match the required signers from TxBody's messages. The first element is the primary signer and the one which pays the fee. fee: description: >- Fee is the fee and gas limit for the transaction. The first signer is the primary signer and the one which pays the fee. The fee can be calculated based on the cost of evaluating the body and doing signature verification of the signers. This can be estimated via simulation. type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of coins to be paid as a fee gas_limit: type: string format: uint64 title: >- gas_limit is the maximum gas that can be used in transaction processing before an out of gas error occurs payer: type: string description: >- if unset, the first signer is responsible for paying the fees. If set, the specified account must pay the fees. the payer must be a tx signer (and thus have signed this field in AuthInfo). setting this field does *not* change the ordering of required signers for the transaction. granter: type: string title: >- if set, the fee payer (either the first signer or the value of the payer field) requests that a fee grant be used to pay fees instead of the fee payer's own balance. If an appropriate fee grant does not exist or the chain does not support fee grants, this will fail tip: description: >- Tip is the optional tip used for transactions fees paid in another denom. This field is ignored if the chain didn't enable tips, i.e. didn't add the `TipDecorator` in its posthandler. Since: cosmos-sdk 0.46 type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of the tip tipper: type: string title: >- tipper is the address of the account paying for the tip description: >- AuthInfo describes the fee and signer modes that are used to sign a transaction. signatures: type: array items: type: string format: byte description: >- signatures is a list of signatures that matches the length and order of AuthInfo's signer_infos to allow connecting signature meta information like public key and signing mode by position. description: |- TxDecodeResponse is the response type for the Service.TxDecode method. Since: cosmos-sdk 0.47 default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: body in: body required: true schema: type: object properties: tx_bytes: type: string format: byte description: tx_bytes is the raw transaction. description: |- TxDecodeRequest is the request type for the Service.TxDecode RPC method. Since: cosmos-sdk 0.47 tags: - gRPC Gateway API /cosmos/tx/v1beta1/decode/amino: post: summary: TxDecodeAmino decodes an Amino transaction from encoded bytes to JSON. description: 'Since: cosmos-sdk 0.47' operationId: TxDecodeAmino_AUUEJ responses: '200': description: A successful response. schema: type: object properties: amino_json: type: string description: >- TxDecodeAminoResponse is the response type for the Service.TxDecodeAmino RPC method. Since: cosmos-sdk 0.47 default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: body in: body required: true schema: type: object properties: amino_binary: type: string format: byte description: >- TxDecodeAminoRequest is the request type for the Service.TxDecodeAmino RPC method. Since: cosmos-sdk 0.47 tags: - gRPC Gateway API /cosmos/tx/v1beta1/encode: post: summary: TxEncode encodes the transaction. description: 'Since: cosmos-sdk 0.47' operationId: TxEncode_SOL4O responses: '200': description: A successful response. schema: type: object properties: tx_bytes: type: string format: byte description: tx_bytes is the encoded transaction bytes. description: |- TxEncodeResponse is the response type for the Service.TxEncode method. Since: cosmos-sdk 0.47 default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: body in: body required: true schema: type: object properties: tx: description: tx is the transaction to encode. type: object properties: body: title: body is the processable content of the transaction type: object properties: messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- messages is a list of messages to be executed. The required signers of those messages define the number and order of elements in AuthInfo's signer_infos and Tx's signatures. Each required signer address is added to the list only the first time it occurs. By convention, the first required signer (usually from the first message) is referred to as the primary signer and pays the fee for the whole transaction. memo: type: string description: >- memo is any arbitrary note/comment to be added to the transaction. WARNING: in clients, any publicly exposed text should not be called memo, but should be called `note` instead (see https://github.com/cosmos/cosmos-sdk/issues/9122). timeout_height: type: string format: uint64 title: >- timeout is the block height after which this transaction will not be processed by the chain extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, the transaction will be rejected non_critical_extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, they will be ignored description: >- TxBody is the body of a transaction that all signers sign over. auth_info: title: >- auth_info is the authorization related content of the transaction, specifically signers, signer modes and fee type: object properties: signer_infos: type: array items: type: object properties: public_key: type: object properties: type_url: type: string value: type: string format: byte description: >- public_key is the public key of the signer. It is optional for accounts that already exist in state. If unset, the verifier can use the required \ signer address for this position and lookup the public key. mode_info: title: >- mode_info describes the signing mode of the signer and is a nested structure to support nested multisig pubkey's type: object properties: single: title: single represents a single signer type: object properties: mode: title: >- mode is the signing mode of the single signer type: string enum: - SIGN_MODE_UNSPECIFIED - SIGN_MODE_DIRECT - SIGN_MODE_TEXTUAL - SIGN_MODE_DIRECT_AUX - SIGN_MODE_LEGACY_AMINO_JSON - SIGN_MODE_EIP_191 default: SIGN_MODE_UNSPECIFIED description: >- SignMode represents a signing mode with its own security guarantees. This enum should be considered a registry of all known sign modes in the Cosmos ecosystem. Apps are not expected to support all known sign modes. Apps that would like to support custom sign modes are encouraged to open a small PR against this file to add a new case to this SignMode enum describing their sign mode so that different apps have a consistent version of this enum. - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be rejected. - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is verified with raw bytes from Tx. - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some human-readable textual representation on top of the binary representation from SIGN_MODE_DIRECT. It is currently not supported. - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses SignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not require signers signing over other signers' `signer_info`. It also allows for adding Tips in transactions. Since: cosmos-sdk 0.46 - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses Amino JSON and will be removed in the future. - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos SDK. Ref: https://eips.ethereum.org/EIPS/eip-191 Currently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant, but is not implemented on the SDK by default. To enable EIP-191, you need to pass a custom `TxConfig` that has an implementation of `SignModeHandler` for EIP-191. The SDK may decide to fully support EIP-191 in the future. Since: cosmos-sdk 0.45.2 multi: title: multi represents a nested multisig signer type: object properties: bitarray: title: >- bitarray specifies which keys within the multisig are signing type: object properties: extra_bits_stored: type: integer format: int64 elems: type: string format: byte description: >- CompactBitArray is an implementation of a space efficient bit array. This is used to ensure that the encoded data takes up a minimal amount of space after proto encoding. This is not thread safe, and is not intended for concurrent usage. mode_infos: type: array items: {} title: >- mode_infos is the corresponding modes of the signers of the multisig which could include nested multisig public keys description: >- ModeInfo describes the signing mode of a single or nested multisig signer. sequence: type: string format: uint64 description: >- sequence is the sequence of the account, which describes the number of committed transactions signed by a given address. It is used to prevent replay attacks. description: >- SignerInfo describes the public key and signing mode of a single top-level signer. description: >- signer_infos defines the signing modes for the required signers. The number and order of elements must match the required signers from TxBody's messages. The first element is the primary signer and the one which pays the fee. fee: description: >- Fee is the fee and gas limit for the transaction. The first signer is the primary signer and the one which pays the fee. The fee can be calculated based on the cost of evaluating the body and doing signature verification of the signers. This can be estimated via simulation. type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of coins to be paid as a fee gas_limit: type: string format: uint64 title: >- gas_limit is the maximum gas that can be used in transaction processing before an out of gas error occurs payer: type: string description: >- if unset, the first signer is responsible for paying the fees. If set, the specified account must pay the fees. the payer must be a tx signer (and thus have signed this field in AuthInfo). setting this field does *not* change the ordering of required signers for the transaction. granter: type: string title: >- if set, the fee payer (either the first signer or the value of the payer field) requests that a fee grant be used to pay fees instead of the fee payer's own balance. If an appropriate fee grant does not exist or the chain does not support fee grants, this will fail tip: description: >- Tip is the optional tip used for transactions fees paid in another denom. This field is ignored if the chain didn't enable tips, i.e. didn't add the `TipDecorator` in its posthandler. Since: cosmos-sdk 0.46 type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of the tip tipper: type: string title: >- tipper is the address of the account paying for the tip description: >- AuthInfo describes the fee and signer modes that are used to sign a transaction. signatures: type: array items: type: string format: byte description: >- signatures is a list of signatures that matches the length and order of AuthInfo's signer_infos to allow connecting signature meta information like public key and signing mode by position. description: |- TxEncodeRequest is the request type for the Service.TxEncode RPC method. Since: cosmos-sdk 0.47 tags: - gRPC Gateway API /cosmos/tx/v1beta1/encode/amino: post: summary: TxEncodeAmino encodes an Amino transaction from JSON to encoded bytes. description: 'Since: cosmos-sdk 0.47' operationId: TxEncodeAmino_4NFNG responses: '200': description: A successful response. schema: type: object properties: amino_binary: type: string format: byte description: >- TxEncodeAminoResponse is the response type for the Service.TxEncodeAmino RPC method. Since: cosmos-sdk 0.47 default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: body in: body required: true schema: type: object properties: amino_json: type: string description: >- TxEncodeAminoRequest is the request type for the Service.TxEncodeAmino RPC method. Since: cosmos-sdk 0.47 tags: - gRPC Gateway API /cosmos/tx/v1beta1/simulate: post: summary: Simulate simulates executing a transaction for estimating gas usage. operationId: Simulate_UY2GZ responses: '200': description: A successful response. schema: type: object properties: gas_info: description: gas_info is the information about gas used in the simulation. type: object properties: gas_wanted: type: string format: uint64 description: >- GasWanted is the maximum units of work we allow this tx to perform. gas_used: type: string format: uint64 description: GasUsed is the amount of gas actually consumed. result: description: result is the result of the simulation. type: object properties: data: type: string format: byte description: >- Data is any data returned from message or handler execution. It MUST be length prefixed in order to separate data from multiple message executions. Deprecated. This field is still populated, but prefer msg_response instead because it also contains the Msg response typeURL. log: type: string description: >- Log contains the log information from message or handler execution. events: type: array items: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string index: type: boolean description: >- EventAttribute is a single key-value pair, associated with an event. description: >- Event allows application developers to attach additional information to ResponseBeginBlock, ResponseEndBlock, ResponseCheckTx and ResponseDeliverTx. Later, transactions may be queried using these events. description: >- Events contains a slice of Event objects that were emitted during message or handler execution. msg_responses: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- msg_responses contains the Msg handler responses type packed in Anys. Since: cosmos-sdk 0.46 description: |- SimulateResponse is the response type for the Service.SimulateRPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: body in: body required: true schema: type: object properties: tx: description: |- tx is the transaction to simulate. Deprecated. Send raw tx bytes instead. type: object properties: body: title: body is the processable content of the transaction type: object properties: messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- messages is a list of messages to be executed. The required signers of those messages define the number and order of elements in AuthInfo's signer_infos and Tx's signatures. Each required signer address is added to the list only the first time it occurs. By convention, the first required signer (usually from the first message) is referred to as the primary signer and pays the fee for the whole transaction. memo: type: string description: >- memo is any arbitrary note/comment to be added to the transaction. WARNING: in clients, any publicly exposed text should not be called memo, but should be called `note` instead (see https://github.com/cosmos/cosmos-sdk/issues/9122). timeout_height: type: string format: uint64 title: >- timeout is the block height after which this transaction will not be processed by the chain extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, the transaction will be rejected non_critical_extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, they will be ignored description: >- TxBody is the body of a transaction that all signers sign over. auth_info: title: >- auth_info is the authorization related content of the transaction, specifically signers, signer modes and fee type: object properties: signer_infos: type: array items: type: object properties: public_key: type: object properties: type_url: type: string value: type: string format: byte description: >- public_key is the public key of the signer. It is optional for accounts that already exist in state. If unset, the verifier can use the required \ signer address for this position and lookup the public key. mode_info: title: >- mode_info describes the signing mode of the signer and is a nested structure to support nested multisig pubkey's type: object properties: single: title: single represents a single signer type: object properties: mode: title: >- mode is the signing mode of the single signer type: string enum: - SIGN_MODE_UNSPECIFIED - SIGN_MODE_DIRECT - SIGN_MODE_TEXTUAL - SIGN_MODE_DIRECT_AUX - SIGN_MODE_LEGACY_AMINO_JSON - SIGN_MODE_EIP_191 default: SIGN_MODE_UNSPECIFIED description: >- SignMode represents a signing mode with its own security guarantees. This enum should be considered a registry of all known sign modes in the Cosmos ecosystem. Apps are not expected to support all known sign modes. Apps that would like to support custom sign modes are encouraged to open a small PR against this file to add a new case to this SignMode enum describing their sign mode so that different apps have a consistent version of this enum. - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be rejected. - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is verified with raw bytes from Tx. - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some human-readable textual representation on top of the binary representation from SIGN_MODE_DIRECT. It is currently not supported. - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses SignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not require signers signing over other signers' `signer_info`. It also allows for adding Tips in transactions. Since: cosmos-sdk 0.46 - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses Amino JSON and will be removed in the future. - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos SDK. Ref: https://eips.ethereum.org/EIPS/eip-191 Currently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant, but is not implemented on the SDK by default. To enable EIP-191, you need to pass a custom `TxConfig` that has an implementation of `SignModeHandler` for EIP-191. The SDK may decide to fully support EIP-191 in the future. Since: cosmos-sdk 0.45.2 multi: title: multi represents a nested multisig signer type: object properties: bitarray: title: >- bitarray specifies which keys within the multisig are signing type: object properties: extra_bits_stored: type: integer format: int64 elems: type: string format: byte description: >- CompactBitArray is an implementation of a space efficient bit array. This is used to ensure that the encoded data takes up a minimal amount of space after proto encoding. This is not thread safe, and is not intended for concurrent usage. mode_infos: type: array items: {} title: >- mode_infos is the corresponding modes of the signers of the multisig which could include nested multisig public keys description: >- ModeInfo describes the signing mode of a single or nested multisig signer. sequence: type: string format: uint64 description: >- sequence is the sequence of the account, which describes the number of committed transactions signed by a given address. It is used to prevent replay attacks. description: >- SignerInfo describes the public key and signing mode of a single top-level signer. description: >- signer_infos defines the signing modes for the required signers. The number and order of elements must match the required signers from TxBody's messages. The first element is the primary signer and the one which pays the fee. fee: description: >- Fee is the fee and gas limit for the transaction. The first signer is the primary signer and the one which pays the fee. The fee can be calculated based on the cost of evaluating the body and doing signature verification of the signers. This can be estimated via simulation. type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of coins to be paid as a fee gas_limit: type: string format: uint64 title: >- gas_limit is the maximum gas that can be used in transaction processing before an out of gas error occurs payer: type: string description: >- if unset, the first signer is responsible for paying the fees. If set, the specified account must pay the fees. the payer must be a tx signer (and thus have signed this field in AuthInfo). setting this field does *not* change the ordering of required signers for the transaction. granter: type: string title: >- if set, the fee payer (either the first signer or the value of the payer field) requests that a fee grant be used to pay fees instead of the fee payer's own balance. If an appropriate fee grant does not exist or the chain does not support fee grants, this will fail tip: description: >- Tip is the optional tip used for transactions fees paid in another denom. This field is ignored if the chain didn't enable tips, i.e. didn't add the `TipDecorator` in its posthandler. Since: cosmos-sdk 0.46 type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of the tip tipper: type: string title: >- tipper is the address of the account paying for the tip description: >- AuthInfo describes the fee and signer modes that are used to sign a transaction. signatures: type: array items: type: string format: byte description: >- signatures is a list of signatures that matches the length and order of AuthInfo's signer_infos to allow connecting signature meta information like public key and signing mode by position. tx_bytes: type: string format: byte description: |- tx_bytes is the raw transaction. Since: cosmos-sdk 0.43 description: |- SimulateRequest is the request type for the Service.Simulate RPC method. tags: - gRPC Gateway API /cosmos/tx/v1beta1/txs: get: summary: GetTxsEvent fetches txs by event. operationId: GetTxsEvent_KWYMH responses: '200': description: A successful response. schema: type: object properties: txs: type: array items: type: object properties: body: title: body is the processable content of the transaction type: object properties: messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- messages is a list of messages to be executed. The required signers of those messages define the number and order of elements in AuthInfo's signer_infos and Tx's signatures. Each required signer address is added to the list only the first time it occurs. By convention, the first required signer (usually from the first message) is referred to as the primary signer and pays the fee for the whole transaction. memo: type: string description: >- memo is any arbitrary note/comment to be added to the transaction. WARNING: in clients, any publicly exposed text should not be called memo, but should be called `note` instead (see https://github.com/cosmos/cosmos-sdk/issues/9122). timeout_height: type: string format: uint64 title: >- timeout is the block height after which this transaction will not be processed by the chain extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, the transaction will be rejected non_critical_extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, they will be ignored description: >- TxBody is the body of a transaction that all signers sign over. auth_info: title: >- auth_info is the authorization related content of the transaction, specifically signers, signer modes and fee type: object properties: signer_infos: type: array items: type: object properties: public_key: type: object properties: type_url: type: string value: type: string format: byte description: >- public_key is the public key of the signer. It is optional for accounts that already exist in state. If unset, the verifier can use the required \ signer address for this position and lookup the public key. mode_info: title: >- mode_info describes the signing mode of the signer and is a nested structure to support nested multisig pubkey's type: object properties: single: title: single represents a single signer type: object properties: mode: title: >- mode is the signing mode of the single signer type: string enum: - SIGN_MODE_UNSPECIFIED - SIGN_MODE_DIRECT - SIGN_MODE_TEXTUAL - SIGN_MODE_DIRECT_AUX - SIGN_MODE_LEGACY_AMINO_JSON - SIGN_MODE_EIP_191 default: SIGN_MODE_UNSPECIFIED description: >- SignMode represents a signing mode with its own security guarantees. This enum should be considered a registry of all known sign modes in the Cosmos ecosystem. Apps are not expected to support all known sign modes. Apps that would like to support custom sign modes are encouraged to open a small PR against this file to add a new case to this SignMode enum describing their sign mode so that different apps have a consistent version of this enum. - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be rejected. - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is verified with raw bytes from Tx. - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some human-readable textual representation on top of the binary representation from SIGN_MODE_DIRECT. It is currently not supported. - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses SignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not require signers signing over other signers' `signer_info`. It also allows for adding Tips in transactions. Since: cosmos-sdk 0.46 - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses Amino JSON and will be removed in the future. - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos SDK. Ref: https://eips.ethereum.org/EIPS/eip-191 Currently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant, but is not implemented on the SDK by default. To enable EIP-191, you need to pass a custom `TxConfig` that has an implementation of `SignModeHandler` for EIP-191. The SDK may decide to fully support EIP-191 in the future. Since: cosmos-sdk 0.45.2 multi: title: multi represents a nested multisig signer type: object properties: bitarray: title: >- bitarray specifies which keys within the multisig are signing type: object properties: extra_bits_stored: type: integer format: int64 elems: type: string format: byte description: >- CompactBitArray is an implementation of a space efficient bit array. This is used to ensure that the encoded data takes up a minimal amount of space after proto encoding. This is not thread safe, and is not intended for concurrent usage. mode_infos: type: array items: {} title: >- mode_infos is the corresponding modes of the signers of the multisig which could include nested multisig public keys description: >- ModeInfo describes the signing mode of a single or nested multisig signer. sequence: type: string format: uint64 description: >- sequence is the sequence of the account, which describes the number of committed transactions signed by a given address. It is used to prevent replay attacks. description: >- SignerInfo describes the public key and signing mode of a single top-level signer. description: >- signer_infos defines the signing modes for the required signers. The number and order of elements must match the required signers from TxBody's messages. The first element is the primary signer and the one which pays the fee. fee: description: >- Fee is the fee and gas limit for the transaction. The first signer is the primary signer and the one which pays the fee. The fee can be calculated based on the cost of evaluating the body and doing signature verification of the signers. This can be estimated via simulation. type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: >- amount is the amount of coins to be paid as a fee gas_limit: type: string format: uint64 title: >- gas_limit is the maximum gas that can be used in transaction processing before an out of gas error occurs payer: type: string description: >- if unset, the first signer is responsible for paying the fees. If set, the specified account must pay the fees. the payer must be a tx signer (and thus have signed this field in AuthInfo). setting this field does *not* change the ordering of required signers for the transaction. granter: type: string title: >- if set, the fee payer (either the first signer or the value of the payer field) requests that a fee grant be used to pay fees instead of the fee payer's own balance. If an appropriate fee grant does not exist or the chain does not support fee grants, this will fail tip: description: >- Tip is the optional tip used for transactions fees paid in another denom. This field is ignored if the chain didn't enable tips, i.e. didn't add the `TipDecorator` in its posthandler. Since: cosmos-sdk 0.46 type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of the tip tipper: type: string title: >- tipper is the address of the account paying for the tip description: >- AuthInfo describes the fee and signer modes that are used to sign a transaction. signatures: type: array items: type: string format: byte description: >- signatures is a list of signatures that matches the length and order of AuthInfo's signer_infos to allow connecting signature meta information like public key and signing mode by position. description: Tx is the standard type used for broadcasting transactions. description: txs is the list of queried transactions. tx_responses: type: array items: type: object properties: height: type: string format: int64 title: The block height txhash: type: string description: The transaction hash. codespace: type: string title: Namespace for the Code code: type: integer format: int64 description: Response code. data: type: string description: Result bytes, if any. raw_log: type: string description: >- The output of the application's logger (raw string). May be non-deterministic. logs: type: array items: type: object properties: msg_index: type: integer format: int64 log: type: string events: type: array items: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string description: >- Attribute defines an attribute wrapper where the key and value are strings instead of raw bytes. description: >- StringEvent defines en Event object wrapper where all the attributes contain key/value pairs that are strings instead of raw bytes. description: >- Events contains a slice of Event objects that were emitted during some execution. description: >- ABCIMessageLog defines a structure containing an indexed tx ABCI message log. description: >- The output of the application's logger (typed). May be non-deterministic. info: type: string description: Additional information. May be non-deterministic. gas_wanted: type: string format: int64 description: Amount of gas requested for transaction. gas_used: type: string format: int64 description: Amount of gas consumed by transaction. tx: type: object properties: type_url: type: string value: type: string format: byte description: The request transaction bytes. timestamp: type: string description: >- Time of the previous block. For heights > 1, it's the weighted median of the timestamps of the valid votes in the block.LastCommit. For height == 1, it's genesis time. events: type: array items: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string index: type: boolean description: >- EventAttribute is a single key-value pair, associated with an event. description: >- Event allows application developers to attach additional information to ResponseBeginBlock, ResponseEndBlock, ResponseCheckTx and ResponseDeliverTx. Later, transactions may be queried using these events. description: >- Events defines all the events emitted by processing a transaction. Note, these events include those emitted by processing all the messages and those emitted from the ante. Whereas Logs contains the events, with additional metadata, emitted only by processing the messages. Since: cosmos-sdk 0.42.11, 0.44.5, 0.45 description: >- TxResponse defines a structure containing relevant tx data and metadata. The tags are stringified and the log is JSON decoded. description: tx_responses is the list of queried TxResponses. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } total: type: string format: uint64 title: total is total number of results available description: >- GetTxsEventResponse is the response type for the Service.TxsByEvents RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: events description: events is the list of transaction event type. in: query required: false type: array items: type: string collectionFormat: multi - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean - name: order_by description: |2- - ORDER_BY_UNSPECIFIED: ORDER_BY_UNSPECIFIED specifies an unknown sorting order. OrderBy defaults to ASC in this case. - ORDER_BY_ASC: ORDER_BY_ASC defines ascending order - ORDER_BY_DESC: ORDER_BY_DESC defines descending order in: query required: false type: string enum: - ORDER_BY_UNSPECIFIED - ORDER_BY_ASC - ORDER_BY_DESC default: ORDER_BY_UNSPECIFIED - name: page description: >- page is the page number to query, starts at 1. If not provided, will default to first page. in: query required: false type: string format: uint64 - name: limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 tags: - gRPC Gateway API post: summary: BroadcastTx broadcast transaction. operationId: BroadcastTx_N4T1X responses: '200': description: A successful response. schema: type: object properties: tx_response: type: object properties: height: type: string format: int64 title: The block height txhash: type: string description: The transaction hash. codespace: type: string title: Namespace for the Code code: type: integer format: int64 description: Response code. data: type: string description: Result bytes, if any. raw_log: type: string description: >- The output of the application's logger (raw string). May be non-deterministic. logs: type: array items: type: object properties: msg_index: type: integer format: int64 log: type: string events: type: array items: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string description: >- Attribute defines an attribute wrapper where the key and value are strings instead of raw bytes. description: >- StringEvent defines en Event object wrapper where all the attributes contain key/value pairs that are strings instead of raw bytes. description: >- Events contains a slice of Event objects that were emitted during some execution. description: >- ABCIMessageLog defines a structure containing an indexed tx ABCI message log. description: >- The output of the application's logger (typed). May be non-deterministic. info: type: string description: Additional information. May be non-deterministic. gas_wanted: type: string format: int64 description: Amount of gas requested for transaction. gas_used: type: string format: int64 description: Amount of gas consumed by transaction. tx: type: object properties: type_url: type: string value: type: string format: byte description: The request transaction bytes. timestamp: type: string description: >- Time of the previous block. For heights > 1, it's the weighted median of the timestamps of the valid votes in the block.LastCommit. For height == 1, it's genesis time. events: type: array items: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string index: type: boolean description: >- EventAttribute is a single key-value pair, associated with an event. description: >- Event allows application developers to attach additional information to ResponseBeginBlock, ResponseEndBlock, ResponseCheckTx and ResponseDeliverTx. Later, transactions may be queried using these events. description: >- Events defines all the events emitted by processing a transaction. Note, these events include those emitted by processing all the messages and those emitted from the ante. Whereas Logs contains the events, with additional metadata, emitted only by processing the messages. Since: cosmos-sdk 0.42.11, 0.44.5, 0.45 description: >- TxResponse defines a structure containing relevant tx data and metadata. The tags are stringified and the log is JSON decoded. description: |- BroadcastTxResponse is the response type for the Service.BroadcastTx method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: body in: body required: true schema: type: object properties: tx_bytes: type: string format: byte description: tx_bytes is the raw transaction. mode: type: string enum: - BROADCAST_MODE_UNSPECIFIED - BROADCAST_MODE_BLOCK - BROADCAST_MODE_SYNC - BROADCAST_MODE_ASYNC default: BROADCAST_MODE_UNSPECIFIED description: >- BroadcastMode specifies the broadcast mode for the TxService.Broadcast RPC method. - BROADCAST_MODE_UNSPECIFIED: zero-value for mode ordering - BROADCAST_MODE_BLOCK: DEPRECATED: use BROADCAST_MODE_SYNC instead, BROADCAST_MODE_BLOCK is not supported by the SDK from v0.47.x onwards. - BROADCAST_MODE_SYNC: BROADCAST_MODE_SYNC defines a tx broadcasting mode where the client waits for a CheckTx execution response only. - BROADCAST_MODE_ASYNC: BROADCAST_MODE_ASYNC defines a tx broadcasting mode where the client returns immediately. description: >- BroadcastTxRequest is the request type for the Service.BroadcastTxRequest RPC method. tags: - gRPC Gateway API /cosmos/tx/v1beta1/txs/block/{height}: get: summary: GetBlockWithTxs fetches a block with decoded txs. description: 'Since: cosmos-sdk 0.45.2' operationId: GetBlockWithTxs_1EZ44 responses: '200': description: A successful response. schema: type: object properties: txs: type: array items: type: object properties: body: title: body is the processable content of the transaction type: object properties: messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- messages is a list of messages to be executed. The required signers of those messages define the number and order of elements in AuthInfo's signer_infos and Tx's signatures. Each required signer address is added to the list only the first time it occurs. By convention, the first required signer (usually from the first message) is referred to as the primary signer and pays the fee for the whole transaction. memo: type: string description: >- memo is any arbitrary note/comment to be added to the transaction. WARNING: in clients, any publicly exposed text should not be called memo, but should be called `note` instead (see https://github.com/cosmos/cosmos-sdk/issues/9122). timeout_height: type: string format: uint64 title: >- timeout is the block height after which this transaction will not be processed by the chain extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, the transaction will be rejected non_critical_extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, they will be ignored description: >- TxBody is the body of a transaction that all signers sign over. auth_info: title: >- auth_info is the authorization related content of the transaction, specifically signers, signer modes and fee type: object properties: signer_infos: type: array items: type: object properties: public_key: type: object properties: type_url: type: string value: type: string format: byte description: >- public_key is the public key of the signer. It is optional for accounts that already exist in state. If unset, the verifier can use the required \ signer address for this position and lookup the public key. mode_info: title: >- mode_info describes the signing mode of the signer and is a nested structure to support nested multisig pubkey's type: object properties: single: title: single represents a single signer type: object properties: mode: title: >- mode is the signing mode of the single signer type: string enum: - SIGN_MODE_UNSPECIFIED - SIGN_MODE_DIRECT - SIGN_MODE_TEXTUAL - SIGN_MODE_DIRECT_AUX - SIGN_MODE_LEGACY_AMINO_JSON - SIGN_MODE_EIP_191 default: SIGN_MODE_UNSPECIFIED description: >- SignMode represents a signing mode with its own security guarantees. This enum should be considered a registry of all known sign modes in the Cosmos ecosystem. Apps are not expected to support all known sign modes. Apps that would like to support custom sign modes are encouraged to open a small PR against this file to add a new case to this SignMode enum describing their sign mode so that different apps have a consistent version of this enum. - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be rejected. - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is verified with raw bytes from Tx. - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some human-readable textual representation on top of the binary representation from SIGN_MODE_DIRECT. It is currently not supported. - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses SignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not require signers signing over other signers' `signer_info`. It also allows for adding Tips in transactions. Since: cosmos-sdk 0.46 - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses Amino JSON and will be removed in the future. - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos SDK. Ref: https://eips.ethereum.org/EIPS/eip-191 Currently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant, but is not implemented on the SDK by default. To enable EIP-191, you need to pass a custom `TxConfig` that has an implementation of `SignModeHandler` for EIP-191. The SDK may decide to fully support EIP-191 in the future. Since: cosmos-sdk 0.45.2 multi: title: multi represents a nested multisig signer type: object properties: bitarray: title: >- bitarray specifies which keys within the multisig are signing type: object properties: extra_bits_stored: type: integer format: int64 elems: type: string format: byte description: >- CompactBitArray is an implementation of a space efficient bit array. This is used to ensure that the encoded data takes up a minimal amount of space after proto encoding. This is not thread safe, and is not intended for concurrent usage. mode_infos: type: array items: {} title: >- mode_infos is the corresponding modes of the signers of the multisig which could include nested multisig public keys description: >- ModeInfo describes the signing mode of a single or nested multisig signer. sequence: type: string format: uint64 description: >- sequence is the sequence of the account, which describes the number of committed transactions signed by a given address. It is used to prevent replay attacks. description: >- SignerInfo describes the public key and signing mode of a single top-level signer. description: >- signer_infos defines the signing modes for the required signers. The number and order of elements must match the required signers from TxBody's messages. The first element is the primary signer and the one which pays the fee. fee: description: >- Fee is the fee and gas limit for the transaction. The first signer is the primary signer and the one which pays the fee. The fee can be calculated based on the cost of evaluating the body and doing signature verification of the signers. This can be estimated via simulation. type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: >- amount is the amount of coins to be paid as a fee gas_limit: type: string format: uint64 title: >- gas_limit is the maximum gas that can be used in transaction processing before an out of gas error occurs payer: type: string description: >- if unset, the first signer is responsible for paying the fees. If set, the specified account must pay the fees. the payer must be a tx signer (and thus have signed this field in AuthInfo). setting this field does *not* change the ordering of required signers for the transaction. granter: type: string title: >- if set, the fee payer (either the first signer or the value of the payer field) requests that a fee grant be used to pay fees instead of the fee payer's own balance. If an appropriate fee grant does not exist or the chain does not support fee grants, this will fail tip: description: >- Tip is the optional tip used for transactions fees paid in another denom. This field is ignored if the chain didn't enable tips, i.e. didn't add the `TipDecorator` in its posthandler. Since: cosmos-sdk 0.46 type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of the tip tipper: type: string title: >- tipper is the address of the account paying for the tip description: >- AuthInfo describes the fee and signer modes that are used to sign a transaction. signatures: type: array items: type: string format: byte description: >- signatures is a list of signatures that matches the length and order of AuthInfo's signer_infos to allow connecting signature meta information like public key and signing mode by position. description: Tx is the standard type used for broadcasting transactions. description: txs are the transactions in the block. block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID block: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. data: type: object properties: txs: type: array items: type: string format: byte description: >- Txs that will be applied by state @ block.Height+1. NOTE: not all txs here are valid. We're just agreeing on the order first. This means that block.AppHash does not include these txs. title: >- Data contains the set of transactions included in the block evidence: type: object properties: evidence: type: array items: type: object properties: duplicate_vote_evidence: type: object properties: vote_a: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. vote_b: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. total_voting_power: type: string format: int64 validator_power: type: string format: int64 timestamp: type: string format: date-time description: >- DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes. light_client_attack_evidence: type: object properties: conflicting_block: type: object properties: signed_header: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: >- hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: >- Header defines the structure of a block header. commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: >- BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: >- CommitSig is a part of the Vote included in a Commit. description: >- Commit contains the evidence that a block was committed by a set of validators. validator_set: type: object properties: validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 proposer: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 common_height: type: string format: int64 byzantine_validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 timestamp: type: string format: date-time description: >- LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client. last_commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: >- BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: >- CommitSig is a part of the Vote included in a Commit. description: >- Commit contains the evidence that a block was committed by a set of validators. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- GetBlockWithTxsResponse is the response type for the Service.GetBlockWithTxs method. Since: cosmos-sdk 0.45.2 default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: height description: height is the height of the block to query. in: path required: true type: string format: int64 - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmos/tx/v1beta1/txs/{hash}: get: summary: GetTx fetches a tx by hash. operationId: GetTx_71CB4 responses: '200': description: A successful response. schema: type: object properties: tx: type: object properties: body: title: body is the processable content of the transaction type: object properties: messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- messages is a list of messages to be executed. The required signers of those messages define the number and order of elements in AuthInfo's signer_infos and Tx's signatures. Each required signer address is added to the list only the first time it occurs. By convention, the first required signer (usually from the first message) is referred to as the primary signer and pays the fee for the whole transaction. memo: type: string description: >- memo is any arbitrary note/comment to be added to the transaction. WARNING: in clients, any publicly exposed text should not be called memo, but should be called `note` instead (see https://github.com/cosmos/cosmos-sdk/issues/9122). timeout_height: type: string format: uint64 title: >- timeout is the block height after which this transaction will not be processed by the chain extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, the transaction will be rejected non_critical_extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, they will be ignored description: >- TxBody is the body of a transaction that all signers sign over. auth_info: title: >- auth_info is the authorization related content of the transaction, specifically signers, signer modes and fee type: object properties: signer_infos: type: array items: type: object properties: public_key: type: object properties: type_url: type: string value: type: string format: byte description: >- public_key is the public key of the signer. It is optional for accounts that already exist in state. If unset, the verifier can use the required \ signer address for this position and lookup the public key. mode_info: title: >- mode_info describes the signing mode of the signer and is a nested structure to support nested multisig pubkey's type: object properties: single: title: single represents a single signer type: object properties: mode: title: >- mode is the signing mode of the single signer type: string enum: - SIGN_MODE_UNSPECIFIED - SIGN_MODE_DIRECT - SIGN_MODE_TEXTUAL - SIGN_MODE_DIRECT_AUX - SIGN_MODE_LEGACY_AMINO_JSON - SIGN_MODE_EIP_191 default: SIGN_MODE_UNSPECIFIED description: >- SignMode represents a signing mode with its own security guarantees. This enum should be considered a registry of all known sign modes in the Cosmos ecosystem. Apps are not expected to support all known sign modes. Apps that would like to support custom sign modes are encouraged to open a small PR against this file to add a new case to this SignMode enum describing their sign mode so that different apps have a consistent version of this enum. - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be rejected. - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is verified with raw bytes from Tx. - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some human-readable textual representation on top of the binary representation from SIGN_MODE_DIRECT. It is currently not supported. - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses SignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not require signers signing over other signers' `signer_info`. It also allows for adding Tips in transactions. Since: cosmos-sdk 0.46 - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses Amino JSON and will be removed in the future. - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos SDK. Ref: https://eips.ethereum.org/EIPS/eip-191 Currently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant, but is not implemented on the SDK by default. To enable EIP-191, you need to pass a custom `TxConfig` that has an implementation of `SignModeHandler` for EIP-191. The SDK may decide to fully support EIP-191 in the future. Since: cosmos-sdk 0.45.2 multi: title: multi represents a nested multisig signer type: object properties: bitarray: title: >- bitarray specifies which keys within the multisig are signing type: object properties: extra_bits_stored: type: integer format: int64 elems: type: string format: byte description: >- CompactBitArray is an implementation of a space efficient bit array. This is used to ensure that the encoded data takes up a minimal amount of space after proto encoding. This is not thread safe, and is not intended for concurrent usage. mode_infos: type: array items: {} title: >- mode_infos is the corresponding modes of the signers of the multisig which could include nested multisig public keys description: >- ModeInfo describes the signing mode of a single or nested multisig signer. sequence: type: string format: uint64 description: >- sequence is the sequence of the account, which describes the number of committed transactions signed by a given address. It is used to prevent replay attacks. description: >- SignerInfo describes the public key and signing mode of a single top-level signer. description: >- signer_infos defines the signing modes for the required signers. The number and order of elements must match the required signers from TxBody's messages. The first element is the primary signer and the one which pays the fee. fee: description: >- Fee is the fee and gas limit for the transaction. The first signer is the primary signer and the one which pays the fee. The fee can be calculated based on the cost of evaluating the body and doing signature verification of the signers. This can be estimated via simulation. type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of coins to be paid as a fee gas_limit: type: string format: uint64 title: >- gas_limit is the maximum gas that can be used in transaction processing before an out of gas error occurs payer: type: string description: >- if unset, the first signer is responsible for paying the fees. If set, the specified account must pay the fees. the payer must be a tx signer (and thus have signed this field in AuthInfo). setting this field does *not* change the ordering of required signers for the transaction. granter: type: string title: >- if set, the fee payer (either the first signer or the value of the payer field) requests that a fee grant be used to pay fees instead of the fee payer's own balance. If an appropriate fee grant does not exist or the chain does not support fee grants, this will fail tip: description: >- Tip is the optional tip used for transactions fees paid in another denom. This field is ignored if the chain didn't enable tips, i.e. didn't add the `TipDecorator` in its posthandler. Since: cosmos-sdk 0.46 type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of the tip tipper: type: string title: >- tipper is the address of the account paying for the tip description: >- AuthInfo describes the fee and signer modes that are used to sign a transaction. signatures: type: array items: type: string format: byte description: >- signatures is a list of signatures that matches the length and order of AuthInfo's signer_infos to allow connecting signature meta information like public key and signing mode by position. description: Tx is the standard type used for broadcasting transactions. tx_response: type: object properties: height: type: string format: int64 title: The block height txhash: type: string description: The transaction hash. codespace: type: string title: Namespace for the Code code: type: integer format: int64 description: Response code. data: type: string description: Result bytes, if any. raw_log: type: string description: >- The output of the application's logger (raw string). May be non-deterministic. logs: type: array items: type: object properties: msg_index: type: integer format: int64 log: type: string events: type: array items: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string description: >- Attribute defines an attribute wrapper where the key and value are strings instead of raw bytes. description: >- StringEvent defines en Event object wrapper where all the attributes contain key/value pairs that are strings instead of raw bytes. description: >- Events contains a slice of Event objects that were emitted during some execution. description: >- ABCIMessageLog defines a structure containing an indexed tx ABCI message log. description: >- The output of the application's logger (typed). May be non-deterministic. info: type: string description: Additional information. May be non-deterministic. gas_wanted: type: string format: int64 description: Amount of gas requested for transaction. gas_used: type: string format: int64 description: Amount of gas consumed by transaction. tx: type: object properties: type_url: type: string value: type: string format: byte description: The request transaction bytes. timestamp: type: string description: >- Time of the previous block. For heights > 1, it's the weighted median of the timestamps of the valid votes in the block.LastCommit. For height == 1, it's genesis time. events: type: array items: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string index: type: boolean description: >- EventAttribute is a single key-value pair, associated with an event. description: >- Event allows application developers to attach additional information to ResponseBeginBlock, ResponseEndBlock, ResponseCheckTx and ResponseDeliverTx. Later, transactions may be queried using these events. description: >- Events defines all the events emitted by processing a transaction. Note, these events include those emitted by processing all the messages and those emitted from the ante. Whereas Logs contains the events, with additional metadata, emitted only by processing the messages. Since: cosmos-sdk 0.42.11, 0.44.5, 0.45 description: >- TxResponse defines a structure containing relevant tx data and metadata. The tags are stringified and the log is JSON decoded. description: GetTxResponse is the response type for the Service.GetTx method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: hash description: hash is the tx hash to query, encoded as a hex string. in: path required: true type: string tags: - gRPC Gateway API /cyber/clock/v1/contracts: get: summary: ClockContracts operationId: ClockContracts_R3OXP responses: '200': description: A successful response. schema: type: object properties: clock_contracts: type: array items: type: object properties: contract_address: type: string description: The address of the contract. is_jailed: type: boolean description: The jail status of the contract. description: |- This object is used to store the contract address and the jail status of the contract. description: clock_contracts are the clock contracts. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- QueryClockContractsResponse is the response type for the Query/ClockContracts RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cyber/clock/v1/contracts/{contract_address}: get: summary: ClockContract operationId: ClockContract_U8RUX responses: '200': description: A successful response. schema: type: object properties: clock_contract: type: object properties: contract_address: type: string description: The address of the contract. is_jailed: type: boolean description: The jail status of the contract. description: |- This object is used to store the contract address and the jail status of the contract. description: >- QueryClockContractResponse is the response type for the Query/ClockContract RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: contract_address description: contract_address is the address of the contract to query. in: path required: true type: string tags: - gRPC Gateway API /cyber/clock/v1/params: get: summary: Params operationId: Params_7NU4D responses: '200': description: A successful response. schema: type: object properties: params: type: object properties: contract_gas_limit: type: string format: uint64 description: >- contract_gas_limit defines the maximum amount of gas that can be used by a contract. description: Params defines the set of module parameters. description: >- QueryClockContractsResponse is the response type for the Query/ClockContracts RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /ibc/core/channel/v1/channels: get: summary: Channels queries all the IBC channels of a chain. operationId: Channels_XUUVY responses: '200': description: A successful response. schema: type: object properties: channels: type: array items: type: object properties: state: title: current state of the channel end type: string enum: - STATE_UNINITIALIZED_UNSPECIFIED - STATE_INIT - STATE_TRYOPEN - STATE_OPEN - STATE_CLOSED default: STATE_UNINITIALIZED_UNSPECIFIED description: >- State defines if a channel is in one of the following states: CLOSED, INIT, TRYOPEN, OPEN or UNINITIALIZED. - STATE_UNINITIALIZED_UNSPECIFIED: Default State - STATE_INIT: A channel has just started the opening handshake. - STATE_TRYOPEN: A channel has acknowledged the handshake step on the counterparty chain. - STATE_OPEN: A channel has completed the handshake. Open channels are ready to send and receive packets. - STATE_CLOSED: A channel has been closed and can no longer be used to send or receive packets. ordering: title: whether the channel is ordered or unordered type: string enum: - ORDER_NONE_UNSPECIFIED - ORDER_UNORDERED - ORDER_ORDERED default: ORDER_NONE_UNSPECIFIED description: >- - ORDER_NONE_UNSPECIFIED: zero-value for channel ordering - ORDER_UNORDERED: packets can be delivered in any order, which may differ from the order in which they were sent. - ORDER_ORDERED: packets are delivered exactly in the order which they were sent counterparty: title: counterparty channel end type: object properties: port_id: type: string description: >- port on the counterparty chain which owns the other end of the channel. channel_id: type: string title: channel end on the counterparty chain connection_hops: type: array items: type: string title: >- list of connection identifiers, in order, along which packets sent on this channel will travel version: type: string title: >- opaque channel version, which is agreed upon during the handshake port_id: type: string title: port identifier channel_id: type: string title: channel identifier description: >- IdentifiedChannel defines a channel with additional port and channel identifier fields. description: list of stored channels of the chain. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: pagination response height: title: query block height type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset description: >- QueryChannelsResponse is the response type for the Query/Channels RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /ibc/core/channel/v1/channels/{channel_id}/ports/{port_id}: get: summary: Channel queries an IBC Channel. operationId: Channel_ENVYK responses: '200': description: A successful response. schema: type: object properties: channel: title: channel associated with the request identifiers type: object properties: state: title: current state of the channel end type: string enum: - STATE_UNINITIALIZED_UNSPECIFIED - STATE_INIT - STATE_TRYOPEN - STATE_OPEN - STATE_CLOSED default: STATE_UNINITIALIZED_UNSPECIFIED description: >- State defines if a channel is in one of the following states: CLOSED, INIT, TRYOPEN, OPEN or UNINITIALIZED. - STATE_UNINITIALIZED_UNSPECIFIED: Default State - STATE_INIT: A channel has just started the opening handshake. - STATE_TRYOPEN: A channel has acknowledged the handshake step on the counterparty chain. - STATE_OPEN: A channel has completed the handshake. Open channels are ready to send and receive packets. - STATE_CLOSED: A channel has been closed and can no longer be used to send or receive packets. ordering: title: whether the channel is ordered or unordered type: string enum: - ORDER_NONE_UNSPECIFIED - ORDER_UNORDERED - ORDER_ORDERED default: ORDER_NONE_UNSPECIFIED description: |- - ORDER_NONE_UNSPECIFIED: zero-value for channel ordering - ORDER_UNORDERED: packets can be delivered in any order, which may differ from the order in which they were sent. - ORDER_ORDERED: packets are delivered exactly in the order which they were sent counterparty: title: counterparty channel end type: object properties: port_id: type: string description: >- port on the counterparty chain which owns the other end of the channel. channel_id: type: string title: channel end on the counterparty chain connection_hops: type: array items: type: string title: >- list of connection identifiers, in order, along which packets sent on this channel will travel version: type: string title: >- opaque channel version, which is agreed upon during the handshake description: >- Channel defines pipeline for exactly-once packet delivery between specific modules on separate blockchains, which has at least one end capable of sending packets and one end capable of receiving packets. proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset description: >- QueryChannelResponse is the response type for the Query/Channel RPC method. Besides the Channel end, it includes a proof and the height from which the proof was retrieved. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: channel_id description: channel unique identifier in: path required: true type: string - name: port_id description: port unique identifier in: path required: true type: string tags: - gRPC Gateway API /ibc/core/channel/v1/channels/{channel_id}/ports/{port_id}/client_state: get: summary: >- ChannelClientState queries for the client state for the channel associated with the provided channel identifiers. operationId: ChannelClientState_928AQ responses: '200': description: A successful response. schema: type: object properties: identified_client_state: title: client state associated with the channel type: object properties: client_id: type: string title: client identifier client_state: type: object properties: type_url: type: string value: type: string format: byte title: client state description: >- IdentifiedClientState defines a client state with an additional client identifier field. proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryChannelClientStateResponse is the Response type for the Query/QueryChannelClientState RPC method default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: channel_id description: channel unique identifier in: path required: true type: string - name: port_id description: port unique identifier in: path required: true type: string tags: - gRPC Gateway API /ibc/core/channel/v1/channels/{channel_id}/ports/{port_id}/consensus_state/revision/{revision_number}/height/{revision_height}: get: summary: |- ChannelConsensusState queries for the consensus state for the channel associated with the provided channel identifiers. operationId: ChannelConsensusState_TYNC0 responses: '200': description: A successful response. schema: type: object properties: consensus_state: type: object properties: type_url: type: string value: type: string format: byte title: consensus state associated with the channel client_id: type: string title: client ID associated with the consensus state proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryChannelClientStateResponse is the Response type for the Query/QueryChannelClientState RPC method default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: channel_id description: channel unique identifier in: path required: true type: string - name: port_id description: port unique identifier in: path required: true type: string - name: revision_number description: revision number of the consensus state in: path required: true type: string format: uint64 - name: revision_height description: revision height of the consensus state in: path required: true type: string format: uint64 tags: - gRPC Gateway API /ibc/core/channel/v1/channels/{channel_id}/ports/{port_id}/next_sequence: get: summary: >- NextSequenceReceive returns the next receive sequence for a given channel. operationId: NextSequenceReceive_GMBZC responses: '200': description: A successful response. schema: type: object properties: next_sequence_receive: type: string format: uint64 title: next sequence receive number proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QuerySequenceResponse is the request type for the Query/QueryNextSequenceReceiveResponse RPC method default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: channel_id description: channel unique identifier in: path required: true type: string - name: port_id description: port unique identifier in: path required: true type: string tags: - gRPC Gateway API /ibc/core/channel/v1/channels/{channel_id}/ports/{port_id}/packet_acknowledgements: get: summary: >- PacketAcknowledgements returns all the packet acknowledgements associated with a channel. operationId: PacketAcknowledgements_L275E responses: '200': description: A successful response. schema: type: object properties: acknowledgements: type: array items: type: object properties: port_id: type: string description: channel port identifier. channel_id: type: string description: channel unique identifier. sequence: type: string format: uint64 description: packet sequence. data: type: string format: byte description: embedded data that represents packet state. description: >- PacketState defines the generic type necessary to retrieve and store packet commitments, acknowledgements, and receipts. Caller is responsible for knowing the context necessary to interpret this state as a commitment, acknowledgement, or a receipt. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: pagination response height: title: query block height type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryPacketAcknowledgemetsResponse is the request type for the Query/QueryPacketAcknowledgements RPC method default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: channel_id description: channel unique identifier in: path required: true type: string - name: port_id description: port unique identifier in: path required: true type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean - name: packet_commitment_sequences description: list of packet sequences. in: query required: false type: array items: type: string format: uint64 collectionFormat: multi tags: - gRPC Gateway API /ibc/core/channel/v1/channels/{channel_id}/ports/{port_id}/packet_acks/{sequence}: get: summary: PacketAcknowledgement queries a stored packet acknowledgement hash. operationId: PacketAcknowledgement_ZZJJ8 responses: '200': description: A successful response. schema: type: object properties: acknowledgement: type: string format: byte title: packet associated with the request fields proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: >- QueryPacketAcknowledgementResponse defines the client query response for a packet which also includes a proof and the height from which the proof was retrieved default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: channel_id description: channel unique identifier in: path required: true type: string - name: port_id description: port unique identifier in: path required: true type: string - name: sequence description: packet sequence in: path required: true type: string format: uint64 tags: - gRPC Gateway API /ibc/core/channel/v1/channels/{channel_id}/ports/{port_id}/packet_commitments: get: summary: |- PacketCommitments returns all the packet commitments hashes associated with a channel. operationId: PacketCommitments_LZDD2 responses: '200': description: A successful response. schema: type: object properties: commitments: type: array items: type: object properties: port_id: type: string description: channel port identifier. channel_id: type: string description: channel unique identifier. sequence: type: string format: uint64 description: packet sequence. data: type: string format: byte description: embedded data that represents packet state. description: >- PacketState defines the generic type necessary to retrieve and store packet commitments, acknowledgements, and receipts. Caller is responsible for knowing the context necessary to interpret this state as a commitment, acknowledgement, or a receipt. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: pagination response height: title: query block height type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryPacketCommitmentsResponse is the request type for the Query/QueryPacketCommitments RPC method default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: channel_id description: channel unique identifier in: path required: true type: string - name: port_id description: port unique identifier in: path required: true type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /ibc/core/channel/v1/channels/{channel_id}/ports/{port_id}/packet_commitments/{packet_ack_sequences}/unreceived_acks: get: summary: >- UnreceivedAcks returns all the unreceived IBC acknowledgements associated with a channel and sequences. operationId: UnreceivedAcks_GU76R responses: '200': description: A successful response. schema: type: object properties: sequences: type: array items: type: string format: uint64 title: list of unreceived acknowledgement sequences height: title: query block height type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryUnreceivedAcksResponse is the response type for the Query/UnreceivedAcks RPC method default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: channel_id description: channel unique identifier in: path required: true type: string - name: port_id description: port unique identifier in: path required: true type: string - name: packet_ack_sequences description: list of acknowledgement sequences in: path required: true type: array items: type: string format: uint64 collectionFormat: csv minItems: 1 tags: - gRPC Gateway API /ibc/core/channel/v1/channels/{channel_id}/ports/{port_id}/packet_commitments/{packet_commitment_sequences}/unreceived_packets: get: summary: >- UnreceivedPackets returns all the unreceived IBC packets associated with a channel and sequences. operationId: UnreceivedPackets_13T8R responses: '200': description: A successful response. schema: type: object properties: sequences: type: array items: type: string format: uint64 title: list of unreceived packet sequences height: title: query block height type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryUnreceivedPacketsResponse is the response type for the Query/UnreceivedPacketCommitments RPC method default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: channel_id description: channel unique identifier in: path required: true type: string - name: port_id description: port unique identifier in: path required: true type: string - name: packet_commitment_sequences description: list of packet sequences in: path required: true type: array items: type: string format: uint64 collectionFormat: csv minItems: 1 tags: - gRPC Gateway API /ibc/core/channel/v1/channels/{channel_id}/ports/{port_id}/packet_commitments/{sequence}: get: summary: PacketCommitment queries a stored packet commitment hash. operationId: PacketCommitment_4UP5U responses: '200': description: A successful response. schema: type: object properties: commitment: type: string format: byte title: packet associated with the request fields proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: >- QueryPacketCommitmentResponse defines the client query response for a packet which also includes a proof and the height from which the proof was retrieved default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: channel_id description: channel unique identifier in: path required: true type: string - name: port_id description: port unique identifier in: path required: true type: string - name: sequence description: packet sequence in: path required: true type: string format: uint64 tags: - gRPC Gateway API /ibc/core/channel/v1/channels/{channel_id}/ports/{port_id}/packet_receipts/{sequence}: get: summary: >- PacketReceipt queries if a given packet sequence has been received on the queried chain operationId: PacketReceipt_907ZV responses: '200': description: A successful response. schema: type: object properties: received: type: boolean title: success flag for if receipt exists proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: >- QueryPacketReceiptResponse defines the client query response for a packet receipt which also includes a proof, and the height from which the proof was retrieved default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: channel_id description: channel unique identifier in: path required: true type: string - name: port_id description: port unique identifier in: path required: true type: string - name: sequence description: packet sequence in: path required: true type: string format: uint64 tags: - gRPC Gateway API /ibc/core/channel/v1/connections/{connection}/channels: get: summary: |- ConnectionChannels queries all the channels associated with a connection end. operationId: ConnectionChannels_DKEMY responses: '200': description: A successful response. schema: type: object properties: channels: type: array items: type: object properties: state: title: current state of the channel end type: string enum: - STATE_UNINITIALIZED_UNSPECIFIED - STATE_INIT - STATE_TRYOPEN - STATE_OPEN - STATE_CLOSED default: STATE_UNINITIALIZED_UNSPECIFIED description: >- State defines if a channel is in one of the following states: CLOSED, INIT, TRYOPEN, OPEN or UNINITIALIZED. - STATE_UNINITIALIZED_UNSPECIFIED: Default State - STATE_INIT: A channel has just started the opening handshake. - STATE_TRYOPEN: A channel has acknowledged the handshake step on the counterparty chain. - STATE_OPEN: A channel has completed the handshake. Open channels are ready to send and receive packets. - STATE_CLOSED: A channel has been closed and can no longer be used to send or receive packets. ordering: title: whether the channel is ordered or unordered type: string enum: - ORDER_NONE_UNSPECIFIED - ORDER_UNORDERED - ORDER_ORDERED default: ORDER_NONE_UNSPECIFIED description: >- - ORDER_NONE_UNSPECIFIED: zero-value for channel ordering - ORDER_UNORDERED: packets can be delivered in any order, which may differ from the order in which they were sent. - ORDER_ORDERED: packets are delivered exactly in the order which they were sent counterparty: title: counterparty channel end type: object properties: port_id: type: string description: >- port on the counterparty chain which owns the other end of the channel. channel_id: type: string title: channel end on the counterparty chain connection_hops: type: array items: type: string title: >- list of connection identifiers, in order, along which packets sent on this channel will travel version: type: string title: >- opaque channel version, which is agreed upon during the handshake port_id: type: string title: port identifier channel_id: type: string title: channel identifier description: >- IdentifiedChannel defines a channel with additional port and channel identifier fields. description: list of channels associated with a connection. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: pagination response height: title: query block height type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryConnectionChannelsResponse is the Response type for the Query/QueryConnectionChannels RPC method default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: connection description: connection unique identifier in: path required: true type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmos/auth/v1beta1/account_info/{address}: get: summary: AccountInfo queries account info which is common to all account types. description: 'Since: cosmos-sdk 0.47' operationId: AccountInfo_J8GK9 responses: '200': description: A successful response. schema: type: object properties: info: description: info is the account info which is represented by BaseAccount. type: object properties: address: type: string pub_key: type: object properties: type_url: type: string value: type: string format: byte account_number: type: string format: uint64 sequence: type: string format: uint64 description: |- QueryAccountInfoResponse is the Query/AccountInfo response type. Since: cosmos-sdk 0.47 default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: address description: address is the account address string. in: path required: true type: string tags: - gRPC Gateway API /cosmos/auth/v1beta1/accounts: get: summary: Accounts returns all the existing accounts. description: >- When called from another module, this query might consume a high amount of gas if the pagination field is incorrectly set. Since: cosmos-sdk 0.43 operationId: Accounts_EI4FZ responses: '200': description: A successful response. schema: type: object properties: accounts: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: accounts are the existing accounts pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- QueryAccountsResponse is the response type for the Query/Accounts RPC method. Since: cosmos-sdk 0.43 default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmos/auth/v1beta1/accounts/{address}: get: summary: Account returns account details based on address. operationId: Account_GVO8V responses: '200': description: A successful response. schema: type: object properties: account: type: object properties: type_url: type: string value: type: string format: byte description: account defines the account of the corresponding address. description: >- QueryAccountResponse is the response type for the Query/Account RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: address description: address defines the address to query for. in: path required: true type: string tags: - gRPC Gateway API /cosmos/auth/v1beta1/address_by_id/{id}: get: summary: AccountAddressByID returns account address based on account number. description: 'Since: cosmos-sdk 0.46.2' operationId: AccountAddressByID_OE1HP responses: '200': description: A successful response. schema: type: object properties: account_address: type: string description: 'Since: cosmos-sdk 0.46.2' title: >- QueryAccountAddressByIDResponse is the response type for AccountAddressByID rpc method default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: id description: |- Deprecated, use account_id instead id is the account number of the address to be queried. This field should have been an uint64 (like all account numbers), and will be updated to uint64 in a future version of the auth query. in: path required: true type: string format: int64 - name: account_id description: |- account_id is the account number of the address to be queried. Since: cosmos-sdk 0.47 in: query required: false type: string format: uint64 tags: - gRPC Gateway API /cosmos/auth/v1beta1/bech32: get: summary: Bech32Prefix queries bech32Prefix description: 'Since: cosmos-sdk 0.46' operationId: Bech32Prefix_1OIJM responses: '200': description: A successful response. schema: type: object properties: bech32_prefix: type: string description: >- Bech32PrefixResponse is the response type for Bech32Prefix rpc method. Since: cosmos-sdk 0.46 default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/auth/v1beta1/bech32/{address_bytes}: get: summary: AddressBytesToString converts Account Address bytes to string description: 'Since: cosmos-sdk 0.46' operationId: AddressBytesToString_P2TYK responses: '200': description: A successful response. schema: type: object properties: address_string: type: string description: >- AddressBytesToStringResponse is the response type for AddressString rpc method. Since: cosmos-sdk 0.46 default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: address_bytes in: path required: true type: string format: byte tags: - gRPC Gateway API /cosmos/auth/v1beta1/bech32/{address_string}: get: summary: AddressStringToBytes converts Address string to bytes description: 'Since: cosmos-sdk 0.46' operationId: AddressStringToBytes_2ADP0 responses: '200': description: A successful response. schema: type: object properties: address_bytes: type: string format: byte description: >- AddressStringToBytesResponse is the response type for AddressBytes rpc method. Since: cosmos-sdk 0.46 default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: address_string in: path required: true type: string tags: - gRPC Gateway API /cosmos/auth/v1beta1/module_accounts: get: summary: ModuleAccounts returns all the existing module accounts. description: 'Since: cosmos-sdk 0.46' operationId: ModuleAccounts_A46V7 responses: '200': description: A successful response. schema: type: object properties: accounts: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- QueryModuleAccountsResponse is the response type for the Query/ModuleAccounts RPC method. Since: cosmos-sdk 0.46 default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/auth/v1beta1/module_accounts/{name}: get: summary: ModuleAccountByName returns the module account info by module name operationId: ModuleAccountByName_R830P responses: '200': description: A successful response. schema: type: object properties: account: type: object properties: type_url: type: string value: type: string format: byte description: >- QueryModuleAccountByNameResponse is the response type for the Query/ModuleAccountByName RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: name in: path required: true type: string tags: - gRPC Gateway API /cosmos/auth/v1beta1/params: get: summary: Params queries all parameters. operationId: Params_NV54V responses: '200': description: A successful response. schema: type: object properties: params: description: params defines the parameters of the module. type: object properties: max_memo_characters: type: string format: uint64 tx_sig_limit: type: string format: uint64 tx_size_cost_per_byte: type: string format: uint64 sig_verify_cost_ed25519: type: string format: uint64 sig_verify_cost_secp256k1: type: string format: uint64 description: >- QueryParamsResponse is the response type for the Query/Params RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/evidence/v1beta1/evidence: get: summary: AllEvidence queries all evidence. operationId: AllEvidence_WTNNZ responses: '200': description: A successful response. schema: type: object properties: evidence: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: evidence returns all evidences. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- QueryAllEvidenceResponse is the response type for the Query/AllEvidence RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmos/evidence/v1beta1/evidence/{hash}: get: summary: Evidence queries evidence based on evidence hash. operationId: Evidence_VCI4U responses: '200': description: A successful response. schema: type: object properties: evidence: type: object properties: type_url: type: string value: type: string format: byte description: evidence returns the requested evidence. description: >- QueryEvidenceResponse is the response type for the Query/Evidence RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: hash description: |- hash defines the evidence hash of the requested evidence. Since: cosmos-sdk 0.47 in: path required: true type: string - name: evidence_hash description: |- evidence_hash defines the hash of the requested evidence. Deprecated: Use hash, a HEX encoded string, instead. in: query required: false type: string format: byte tags: - gRPC Gateway API /ibc/core/client/v1/client_states: get: summary: ClientStates queries all the IBC light clients of a chain. operationId: ClientStates_G5T1X responses: '200': description: A successful response. schema: type: object properties: client_states: type: array items: type: object properties: client_id: type: string title: client identifier client_state: type: object properties: type_url: type: string value: type: string format: byte title: client state description: >- IdentifiedClientState defines a client state with an additional client identifier field. description: list of stored ClientStates of the chain. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: pagination response description: >- QueryClientStatesResponse is the response type for the Query/ClientStates RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /ibc/core/client/v1/client_states/{client_id}: get: summary: ClientState queries an IBC light client. operationId: ClientState_ET75Z responses: '200': description: A successful response. schema: type: object properties: client_state: type: object properties: type_url: type: string value: type: string format: byte title: client state associated with the request identifier proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset description: >- QueryClientStateResponse is the response type for the Query/ClientState RPC method. Besides the client state, it includes a proof and the height from which the proof was retrieved. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: client_id description: client state unique identifier in: path required: true type: string tags: - gRPC Gateway API /ibc/core/client/v1/client_status/{client_id}: get: summary: Status queries the status of an IBC client. operationId: ClientStatus_I48L1 responses: '200': description: A successful response. schema: type: object properties: status: type: string description: >- QueryClientStatusResponse is the response type for the Query/ClientStatus RPC method. It returns the current status of the IBC client. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: client_id description: client unique identifier in: path required: true type: string tags: - gRPC Gateway API /ibc/core/client/v1/consensus_states/{client_id}: get: summary: |- ConsensusStates queries all the consensus state associated with a given client. operationId: ConsensusStates_OEIZR responses: '200': description: A successful response. schema: type: object properties: consensus_states: type: array items: type: object properties: height: title: consensus state height type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset consensus_state: type: object properties: type_url: type: string value: type: string format: byte title: consensus state description: >- ConsensusStateWithHeight defines a consensus state with an additional height field. title: consensus states associated with the identifier pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: pagination response title: |- QueryConsensusStatesResponse is the response type for the Query/ConsensusStates RPC method default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: client_id description: client identifier in: path required: true type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /ibc/core/client/v1/consensus_states/{client_id}/heights: get: summary: >- ConsensusStateHeights queries the height of every consensus states associated with a given client. operationId: ConsensusStateHeights_03B71 responses: '200': description: A successful response. schema: type: object properties: consensus_state_heights: type: array items: type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: >- Height is a monotonically increasing data type that can be compared against another Height for the purposes of updating and freezing clients title: consensus state heights pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: pagination response title: |- QueryConsensusStateHeightsResponse is the response type for the Query/ConsensusStateHeights RPC method default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: client_id description: client identifier in: path required: true type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /ibc/core/client/v1/consensus_states/{client_id}/revision/{revision_number}/height/{revision_height}: get: summary: >- ConsensusState queries a consensus state associated with a client state at a given height. operationId: ConsensusState_AYG3G responses: '200': description: A successful response. schema: type: object properties: consensus_state: type: object properties: type_url: type: string value: type: string format: byte title: >- consensus state associated with the client identifier at the given height proof: type: string format: byte title: merkle proof of existence proof_height: type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: >- Height is a monotonically increasing data type that can be compared against another Height for the purposes of updating and freezing clients title: >- QueryConsensusStateResponse is the response type for the Query/ConsensusState RPC method default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: client_id description: client identifier in: path required: true type: string - name: revision_number description: consensus state revision number in: path required: true type: string format: uint64 - name: revision_height description: consensus state revision height in: path required: true type: string format: uint64 - name: latest_height description: >- latest_height overrrides the height field and queries the latest stored ConsensusState. in: query required: false type: boolean tags: - gRPC Gateway API /ibc/core/client/v1/params: get: summary: ClientParams queries all parameters of the ibc client submodule. operationId: ClientParams_XMXO9 responses: '200': description: A successful response. schema: type: object properties: params: description: params defines the parameters of the module. type: object properties: allowed_clients: type: array items: type: string description: >- allowed_clients defines the list of allowed client state types which can be created and interacted with. If a client type is removed from the allowed clients list, usage of this client will be disabled until it is added again to the list. description: >- QueryClientParamsResponse is the response type for the Query/ClientParams RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /ibc/core/client/v1/upgraded_client_states: get: summary: UpgradedClientState queries an Upgraded IBC light client. operationId: UpgradedClientState_0T6RN responses: '200': description: A successful response. schema: type: object properties: upgraded_client_state: type: object properties: type_url: type: string value: type: string format: byte title: client state associated with the request identifier description: |- QueryUpgradedClientStateResponse is the response type for the Query/UpgradedClientState RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /ibc/core/client/v1/upgraded_consensus_states: get: summary: UpgradedConsensusState queries an Upgraded IBC consensus state. operationId: UpgradedConsensusState_T13SE responses: '200': description: A successful response. schema: type: object properties: upgraded_consensus_state: type: object properties: type_url: type: string value: type: string format: byte title: Consensus state associated with the request identifier description: |- QueryUpgradedConsensusStateResponse is the response type for the Query/UpgradedConsensusState RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/authz/v1beta1/grants: get: summary: Returns list of `Authorization`, granted to the grantee by the granter. operationId: Grants_OHMNO responses: '200': description: A successful response. schema: type: object properties: grants: type: array items: type: object properties: authorization: type: object properties: type_url: type: string value: type: string format: byte expiration: type: string format: date-time title: >- time when the grant will expire and will be pruned. If null, then the grant doesn't have a time expiration (other conditions in `authorization` may apply to invalidate the grant) description: |- Grant gives permissions to execute the provide method with expiration time. description: >- authorizations is a list of grants granted for grantee by granter. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- QueryGrantsResponse is the response type for the Query/Authorizations RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: granter in: query required: false type: string - name: grantee in: query required: false type: string - name: msg_type_url description: >- Optional, msg_type_url, when set, will query only grants matching given msg type. in: query required: false type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmos/authz/v1beta1/grants/grantee/{grantee}: get: summary: GranteeGrants returns a list of `GrantAuthorization` by grantee. description: 'Since: cosmos-sdk 0.46' operationId: GranteeGrants_2HZ2F responses: '200': description: A successful response. schema: type: object properties: grants: type: array items: type: object properties: granter: type: string grantee: type: string authorization: type: object properties: type_url: type: string value: type: string format: byte expiration: type: string format: date-time title: >- GrantAuthorization extends a grant with both the addresses of the grantee and granter. It is used in genesis.proto and query.proto description: grants is a list of grants granted to the grantee. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- QueryGranteeGrantsResponse is the response type for the Query/GranteeGrants RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: grantee in: path required: true type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmos/authz/v1beta1/grants/granter/{granter}: get: summary: GranterGrants returns list of `GrantAuthorization`, granted by granter. description: 'Since: cosmos-sdk 0.46' operationId: GranterGrants_5J801 responses: '200': description: A successful response. schema: type: object properties: grants: type: array items: type: object properties: granter: type: string grantee: type: string authorization: type: object properties: type_url: type: string value: type: string format: byte expiration: type: string format: date-time title: >- GrantAuthorization extends a grant with both the addresses of the grantee and granter. It is used in genesis.proto and query.proto description: grants is a list of grants granted by the granter. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- QueryGranterGrantsResponse is the response type for the Query/GranterGrants RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: granter in: path required: true type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmos/liquidity/v1beta1/params: get: summary: Get all parameters of the liquidity module. operationId: Params_PSZ1M responses: '200': description: A successful response. schema: type: object properties: params: description: params holds all the parameters of this module. type: object properties: pool_types: type: array items: type: object properties: id: type: integer format: int64 title: >- This is the id of the pool_type that is used as pool_type_id for pool creation. In this version, only pool-type-id 1 is supported. {"id":1,"name":"ConstantProductLiquidityPool","min_reserve_coin_num":2,"max_reserve_coin_num":2,"description":""} name: type: string description: name of the pool type. min_reserve_coin_num: type: integer format: int64 description: >- minimum number of reserveCoins for LiquidityPoolType, only 2 reserve coins are supported. max_reserve_coin_num: type: integer format: int64 description: >- maximum number of reserveCoins for LiquidityPoolType, only 2 reserve coins are supported. description: type: string description: description of the pool type. description: >- Structure for the pool type to distinguish the characteristics of the reserve pools. title: list of available pool types min_init_deposit_amount: type: string description: >- Minimum number of coins to be deposited to the liquidity pool on pool creation. init_pool_coin_mint_amount: type: string description: Initial mint amount of pool coins upon pool creation. max_reserve_coin_amount: type: string description: >- Limit the size of each liquidity pool to minimize risk. In development, set to 0 for no limit. In production, set a limit. pool_creation_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- Fee paid to create a Liquidity Pool. Set a fee to prevent spamming. swap_fee_rate: type: string description: Swap fee rate for every executed swap. withdraw_fee_rate: type: string description: >- Reserve coin withdrawal with less proportion by withdrawFeeRate. max_order_amount_ratio: type: string description: >- Maximum ratio of reserve coins that can be ordered at a swap order. unit_batch_height: type: integer format: int64 description: The smallest unit batch height for every liquidity pool. circuit_breaker_enabled: type: boolean description: >- Circuit breaker enables or disables transaction messages in liquidity module. description: >- the response type for the QueryParamsResponse RPC method. This includes current parameter of the liquidity module. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/liquidity/v1beta1/pools: get: summary: Get existing liquidity pools. operationId: LiquidityPools_W7CWM responses: '200': description: A successful response. schema: type: object properties: pools: type: array items: type: object properties: id: type: string format: uint64 title: id of the pool type_id: type: integer format: int64 title: id of the pool_type reserve_coin_denoms: type: array items: type: string title: denoms of reserve coin pair of the pool reserve_account_address: type: string title: reserve account address of the pool pool_coin_denom: type: string title: denom of pool coin of the pool description: >- Pool defines the liquidity pool that contains pool information. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- the response type for the QueryLiquidityPoolsResponse RPC method. This includes a list of all existing liquidity pools and paging results that contain next_key and total count. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmos/liquidity/v1beta1/pools/pool_coin_denom/{pool_coin_denom}: get: summary: Get specific liquidity pool corresponding to the pool_coin_denom. operationId: LiquidityPoolByPoolCoinDenom_90R2T responses: '200': description: A successful response. schema: type: object properties: pool: type: object properties: id: type: string format: uint64 title: id of the pool type_id: type: integer format: int64 title: id of the pool_type reserve_coin_denoms: type: array items: type: string title: denoms of reserve coin pair of the pool reserve_account_address: type: string title: reserve account address of the pool pool_coin_denom: type: string title: denom of pool coin of the pool description: >- Pool defines the liquidity pool that contains pool information. description: >- the response type for the QueryLiquidityPoolResponse RPC method. Returns the liquidity pool that corresponds to the requested pool_id. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pool_coin_denom in: path required: true type: string tags: - gRPC Gateway API /cosmos/liquidity/v1beta1/pools/reserve_acc/{reserve_acc}: get: summary: Get specific liquidity pool corresponding to the reserve account. operationId: LiquidityPoolByReserveAcc_824YS responses: '200': description: A successful response. schema: type: object properties: pool: type: object properties: id: type: string format: uint64 title: id of the pool type_id: type: integer format: int64 title: id of the pool_type reserve_coin_denoms: type: array items: type: string title: denoms of reserve coin pair of the pool reserve_account_address: type: string title: reserve account address of the pool pool_coin_denom: type: string title: denom of pool coin of the pool description: >- Pool defines the liquidity pool that contains pool information. description: >- the response type for the QueryLiquidityPoolResponse RPC method. Returns the liquidity pool that corresponds to the requested pool_id. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: reserve_acc in: path required: true type: string tags: - gRPC Gateway API /cosmos/liquidity/v1beta1/pools/{pool_id}: get: summary: Get specific liquidity pool. operationId: LiquidityPool_GVMM2 responses: '200': description: A successful response. schema: type: object properties: pool: type: object properties: id: type: string format: uint64 title: id of the pool type_id: type: integer format: int64 title: id of the pool_type reserve_coin_denoms: type: array items: type: string title: denoms of reserve coin pair of the pool reserve_account_address: type: string title: reserve account address of the pool pool_coin_denom: type: string title: denom of pool coin of the pool description: >- Pool defines the liquidity pool that contains pool information. description: >- the response type for the QueryLiquidityPoolResponse RPC method. Returns the liquidity pool that corresponds to the requested pool_id. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pool_id in: path required: true type: string format: uint64 tags: - gRPC Gateway API /cosmos/liquidity/v1beta1/pools/{pool_id}/batch: get: summary: Get the pool's current batch. operationId: LiquidityPoolBatch_80103 responses: '200': description: A successful response. schema: type: object properties: batch: type: object properties: pool_id: type: string format: uint64 title: id of the pool index: type: string format: uint64 title: index of this batch begin_height: type: string format: int64 title: height where this batch is started deposit_msg_index: type: string format: uint64 title: last index of DepositMsgStates withdraw_msg_index: type: string format: uint64 title: last index of WithdrawMsgStates swap_msg_index: type: string format: uint64 title: last index of SwapMsgStates executed: type: boolean title: true if executed, false if not executed description: >- PoolBatch defines the batch or batches of a given liquidity pool that contains indexes of deposit, withdraw, and swap messages. Index param increments by 1 if the pool id is same. description: >- the response type for the QueryLiquidityPoolBatchResponse RPC method. Returns the liquidity pool batch that corresponds to the requested pool_id. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pool_id description: id of the target pool for query in: path required: true type: string format: uint64 tags: - gRPC Gateway API /cosmos/liquidity/v1beta1/pools/{pool_id}/batch/deposits: get: summary: Get all deposit messages in the pool's current batch. operationId: PoolBatchDepositMsgs_POD1A responses: '200': description: A successful response. schema: type: object properties: deposits: type: array items: type: object properties: msg_height: type: string format: int64 title: height where this message is appended to the batch msg_index: type: string format: uint64 title: index of this deposit message in this liquidity pool executed: type: boolean title: true if executed on this batch, false if not executed succeeded: type: boolean title: >- true if executed successfully on this batch, false if failed to_be_deleted: type: boolean title: >- true if ready to be deleted on kvstore, false if not ready to be deleted msg: title: MsgDepositWithinBatch type: object properties: depositor_address: type: string pool_id: type: string format: uint64 title: id of the target pool deposit_coins: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: reserve coin pair of the pool to deposit description: >- `MsgDepositWithinBatch defines` an `sdk.Msg` type that supports submitting a deposit request to the batch of the liquidity pool. Deposit is submitted to the batch of the Liquidity pool with the specified `pool_id`, `deposit_coins` for reserve. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. See: https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md description: >- DepositMsgState defines the state of deposit message that contains state information as it is processed in the next batch or batches. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- the response type for the QueryPoolBatchDeposit RPC method. This includes a list of all currently existing deposit messages of the batch and paging results that contain next_key and total count. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pool_id description: id of the target pool for query in: path required: true type: string format: uint64 - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmos/liquidity/v1beta1/pools/{pool_id}/batch/deposits/{msg_index}: get: summary: Get a specific deposit message in the pool's current batch. operationId: PoolBatchDepositMsg_DLP6J responses: '200': description: A successful response. schema: type: object properties: deposit: type: object properties: msg_height: type: string format: int64 title: height where this message is appended to the batch msg_index: type: string format: uint64 title: index of this deposit message in this liquidity pool executed: type: boolean title: true if executed on this batch, false if not executed succeeded: type: boolean title: >- true if executed successfully on this batch, false if failed to_be_deleted: type: boolean title: >- true if ready to be deleted on kvstore, false if not ready to be deleted msg: title: MsgDepositWithinBatch type: object properties: depositor_address: type: string pool_id: type: string format: uint64 title: id of the target pool deposit_coins: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: reserve coin pair of the pool to deposit description: >- `MsgDepositWithinBatch defines` an `sdk.Msg` type that supports submitting a deposit request to the batch of the liquidity pool. Deposit is submitted to the batch of the Liquidity pool with the specified `pool_id`, `deposit_coins` for reserve. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. See: https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md description: >- DepositMsgState defines the state of deposit message that contains state information as it is processed in the next batch or batches. description: >- the response type for the QueryPoolBatchDepositMsg RPC method. This includes a batch swap message of the batch. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pool_id description: id of the target pool for query in: path required: true type: string format: uint64 - name: msg_index description: target msg_index of the pool in: path required: true type: string format: uint64 tags: - gRPC Gateway API /cosmos/liquidity/v1beta1/pools/{pool_id}/batch/swaps: get: summary: Get all swap messages in the pool's current batch. operationId: PoolBatchSwapMsgs_YUF1Y responses: '200': description: A successful response. schema: type: object properties: swaps: type: array items: type: object properties: msg_height: type: string format: int64 title: height where this message is appended to the batch msg_index: type: string format: uint64 title: index of this swap message in this liquidity pool executed: type: boolean title: true if executed on this batch, false if not executed succeeded: type: boolean title: >- true if executed successfully on this batch, false if failed to_be_deleted: type: boolean title: >- true if ready to be deleted on kvstore, false if not ready to be deleted order_expiry_height: type: string format: int64 title: >- swap orders are cancelled when current height is equal to or higher than ExpiryHeight exchanged_offer_coin: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: offer coin exchanged until now remaining_offer_coin: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: offer coin currently remaining to be exchanged reserved_offer_coin_fee: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: reserve fee for pays fee in half offer coin msg: title: MsgSwapWithinBatch type: object properties: swap_requester_address: type: string title: address of swap requester pool_id: type: string format: uint64 description: >- id of swap type, must match the value in the pool. Only `swap_type_id` 1 is supported. swap_type_id: type: integer format: int64 description: id of swap type. Must match the value in the pool. offer_coin: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. demand_coin_denom: type: string description: >- denom of demand coin to be exchanged on the swap request, must match the denom in the pool. offer_coin_fee: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. order_price: type: string description: >- limit order price for the order, the price is the exchange ratio of X/Y where X is the amount of the first coin and Y is the amount of the second coin when their denoms are sorted alphabetically. description: >- `MsgSwapWithinBatch` defines an sdk.Msg type that supports submitting a swap offer request to the batch of the liquidity pool. Submit swap offer to the liquidity pool batch with the specified the `pool_id`, `swap_type_id`, `demand_coin_denom` with the coin and the price you're offering and `offer_coin_fee` must be half of offer coin amount * current `params.swap_fee_rate` and ceil for reservation to pay fees. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. You must request the same fields as the pool. Only the default `swap_type_id` 1 is supported. See: https://github.com/gravity-devs/liquidity/tree/develop/doc https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md description: >- SwapMsgState defines the state of the swap message that contains state information as the message is processed in the next batch or batches. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- the response type for the QueryPoolBatchSwapMsgs RPC method. This includes list of all currently existing swap messages of the batch and paging results that contain next_key and total count. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pool_id description: id of the target pool for query in: path required: true type: string format: uint64 - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmos/liquidity/v1beta1/pools/{pool_id}/batch/swaps/{msg_index}: get: summary: Get a specific swap message in the pool's current batch. operationId: PoolBatchSwapMsg_X08QJ responses: '200': description: A successful response. schema: type: object properties: swap: type: object properties: msg_height: type: string format: int64 title: height where this message is appended to the batch msg_index: type: string format: uint64 title: index of this swap message in this liquidity pool executed: type: boolean title: true if executed on this batch, false if not executed succeeded: type: boolean title: >- true if executed successfully on this batch, false if failed to_be_deleted: type: boolean title: >- true if ready to be deleted on kvstore, false if not ready to be deleted order_expiry_height: type: string format: int64 title: >- swap orders are cancelled when current height is equal to or higher than ExpiryHeight exchanged_offer_coin: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: offer coin exchanged until now remaining_offer_coin: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: offer coin currently remaining to be exchanged reserved_offer_coin_fee: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: reserve fee for pays fee in half offer coin msg: title: MsgSwapWithinBatch type: object properties: swap_requester_address: type: string title: address of swap requester pool_id: type: string format: uint64 description: >- id of swap type, must match the value in the pool. Only `swap_type_id` 1 is supported. swap_type_id: type: integer format: int64 description: id of swap type. Must match the value in the pool. offer_coin: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. demand_coin_denom: type: string description: >- denom of demand coin to be exchanged on the swap request, must match the denom in the pool. offer_coin_fee: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. order_price: type: string description: >- limit order price for the order, the price is the exchange ratio of X/Y where X is the amount of the first coin and Y is the amount of the second coin when their denoms are sorted alphabetically. description: >- `MsgSwapWithinBatch` defines an sdk.Msg type that supports submitting a swap offer request to the batch of the liquidity pool. Submit swap offer to the liquidity pool batch with the specified the `pool_id`, `swap_type_id`, `demand_coin_denom` with the coin and the price you're offering and `offer_coin_fee` must be half of offer coin amount * current `params.swap_fee_rate` and ceil for reservation to pay fees. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. You must request the same fields as the pool. Only the default `swap_type_id` 1 is supported. See: https://github.com/gravity-devs/liquidity/tree/develop/doc https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md description: >- SwapMsgState defines the state of the swap message that contains state information as the message is processed in the next batch or batches. description: >- the response type for the QueryPoolBatchSwapMsg RPC method. This includes a batch swap message of the batch. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pool_id description: id of the target pool for query in: path required: true type: string format: uint64 - name: msg_index description: target msg_index of the pool in: path required: true type: string format: uint64 tags: - gRPC Gateway API /cosmos/liquidity/v1beta1/pools/{pool_id}/batch/withdraws: get: summary: Get all withdraw messages in the pool's current batch. operationId: PoolBatchWithdrawMsgs_605RT responses: '200': description: A successful response. schema: type: object properties: withdraws: type: array items: type: object properties: msg_height: type: string format: int64 title: height where this message is appended to the batch msg_index: type: string format: uint64 title: index of this withdraw message in this liquidity pool executed: type: boolean title: true if executed on this batch, false if not executed succeeded: type: boolean title: >- true if executed successfully on this batch, false if failed to_be_deleted: type: boolean title: >- true if ready to be deleted on kvstore, false if not ready to be deleted msg: title: MsgWithdrawWithinBatch type: object properties: withdrawer_address: type: string pool_id: type: string format: uint64 title: id of the target pool pool_coin: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- `MsgWithdrawWithinBatch` defines an `sdk.Msg` type that supports submitting a withdraw request to the batch of the liquidity pool. Withdraw is submitted to the batch from the Liquidity pool with the specified `pool_id`, `pool_coin` of the pool. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. See: https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md description: >- WithdrawMsgState defines the state of the withdraw message that contains state information as the message is processed in the next batch or batches. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- the response type for the QueryPoolBatchWithdraw RPC method. This includes a list of all currently existing withdraw messages of the batch and paging results that contain next_key and total count. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pool_id description: id of the target pool for query in: path required: true type: string format: uint64 - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmos/liquidity/v1beta1/pools/{pool_id}/batch/withdraws/{msg_index}: get: summary: Get a specific withdraw message in the pool's current batch. operationId: PoolBatchWithdrawMsg_84SDG responses: '200': description: A successful response. schema: type: object properties: withdraw: type: object properties: msg_height: type: string format: int64 title: height where this message is appended to the batch msg_index: type: string format: uint64 title: index of this withdraw message in this liquidity pool executed: type: boolean title: true if executed on this batch, false if not executed succeeded: type: boolean title: >- true if executed successfully on this batch, false if failed to_be_deleted: type: boolean title: >- true if ready to be deleted on kvstore, false if not ready to be deleted msg: title: MsgWithdrawWithinBatch type: object properties: withdrawer_address: type: string pool_id: type: string format: uint64 title: id of the target pool pool_coin: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- `MsgWithdrawWithinBatch` defines an `sdk.Msg` type that supports submitting a withdraw request to the batch of the liquidity pool. Withdraw is submitted to the batch from the Liquidity pool with the specified `pool_id`, `pool_coin` of the pool. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. See: https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md description: >- WithdrawMsgState defines the state of the withdraw message that contains state information as the message is processed in the next batch or batches. description: >- the response type for the QueryPoolBatchWithdrawMsg RPC method. This includes a batch swap message of the batch. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pool_id description: id of the target pool for query in: path required: true type: string format: uint64 - name: msg_index description: target msg_index of the pool in: path required: true type: string format: uint64 tags: - gRPC Gateway API /cosmwasm/wasm/v1/code: get: summary: Codes gets the metadata for all stored wasm codes operationId: Codes_7UDV9 responses: '200': description: A successful response. schema: type: object properties: code_infos: type: array items: type: object properties: code_id: type: string format: uint64 creator: type: string data_hash: type: string format: byte instantiate_permission: type: object properties: permission: type: string enum: - ACCESS_TYPE_UNSPECIFIED - ACCESS_TYPE_NOBODY - ACCESS_TYPE_EVERYBODY - ACCESS_TYPE_ANY_OF_ADDRESSES default: ACCESS_TYPE_UNSPECIFIED description: >- - ACCESS_TYPE_UNSPECIFIED: AccessTypeUnspecified placeholder for empty value - ACCESS_TYPE_NOBODY: AccessTypeNobody forbidden - ACCESS_TYPE_EVERYBODY: AccessTypeEverybody unrestricted - ACCESS_TYPE_ANY_OF_ADDRESSES: AccessTypeAnyOfAddresses allow any of the addresses title: AccessType permission types addresses: type: array items: type: string description: AccessConfig access control type. title: CodeInfoResponse contains code meta data from CodeInfo pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: >- QueryCodesResponse is the response type for the Query/Codes RPC method default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmwasm/wasm/v1/code/{code_id}: get: summary: Code gets the binary code and metadata for a singe wasm code operationId: Code_2D1PE responses: '200': description: A successful response. schema: type: object properties: code_info: type: object properties: code_id: type: string format: uint64 creator: type: string data_hash: type: string format: byte instantiate_permission: type: object properties: permission: type: string enum: - ACCESS_TYPE_UNSPECIFIED - ACCESS_TYPE_NOBODY - ACCESS_TYPE_EVERYBODY - ACCESS_TYPE_ANY_OF_ADDRESSES default: ACCESS_TYPE_UNSPECIFIED description: >- - ACCESS_TYPE_UNSPECIFIED: AccessTypeUnspecified placeholder for empty value - ACCESS_TYPE_NOBODY: AccessTypeNobody forbidden - ACCESS_TYPE_EVERYBODY: AccessTypeEverybody unrestricted - ACCESS_TYPE_ANY_OF_ADDRESSES: AccessTypeAnyOfAddresses allow any of the addresses title: AccessType permission types addresses: type: array items: type: string description: AccessConfig access control type. title: CodeInfoResponse contains code meta data from CodeInfo data: type: string format: byte title: >- QueryCodeResponse is the response type for the Query/Code RPC method default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: code_id in: path required: true type: string format: uint64 tags: - gRPC Gateway API /cosmwasm/wasm/v1/code/{code_id}/contracts: get: summary: ContractsByCode lists all smart contracts for a code id operationId: ContractsByCode_DCS9B responses: '200': description: A successful response. schema: type: object properties: contracts: type: array items: type: string title: contracts are a set of contract addresses pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: |- QueryContractsByCodeResponse is the response type for the Query/ContractsByCode RPC method default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: code_id in: path required: true type: string format: uint64 - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmwasm/wasm/v1/codes/params: get: summary: Params gets the module params operationId: Params_0NI93 responses: '200': description: A successful response. schema: type: object properties: params: description: params defines the parameters of the module. type: object properties: code_upload_access: type: object properties: permission: type: string enum: - ACCESS_TYPE_UNSPECIFIED - ACCESS_TYPE_NOBODY - ACCESS_TYPE_EVERYBODY - ACCESS_TYPE_ANY_OF_ADDRESSES default: ACCESS_TYPE_UNSPECIFIED description: >- - ACCESS_TYPE_UNSPECIFIED: AccessTypeUnspecified placeholder for empty value - ACCESS_TYPE_NOBODY: AccessTypeNobody forbidden - ACCESS_TYPE_EVERYBODY: AccessTypeEverybody unrestricted - ACCESS_TYPE_ANY_OF_ADDRESSES: AccessTypeAnyOfAddresses allow any of the addresses title: AccessType permission types addresses: type: array items: type: string description: AccessConfig access control type. instantiate_default_permission: type: string enum: - ACCESS_TYPE_UNSPECIFIED - ACCESS_TYPE_NOBODY - ACCESS_TYPE_EVERYBODY - ACCESS_TYPE_ANY_OF_ADDRESSES default: ACCESS_TYPE_UNSPECIFIED description: >- - ACCESS_TYPE_UNSPECIFIED: AccessTypeUnspecified placeholder for empty value - ACCESS_TYPE_NOBODY: AccessTypeNobody forbidden - ACCESS_TYPE_EVERYBODY: AccessTypeEverybody unrestricted - ACCESS_TYPE_ANY_OF_ADDRESSES: AccessTypeAnyOfAddresses allow any of the addresses title: AccessType permission types description: >- QueryParamsResponse is the response type for the Query/Params RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmwasm/wasm/v1/codes/pinned: get: summary: PinnedCodes gets the pinned code ids operationId: PinnedCodes_W6G74 responses: '200': description: A successful response. schema: type: object properties: code_ids: type: array items: type: string format: uint64 pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: |- QueryPinnedCodesResponse is the response type for the Query/PinnedCodes RPC method default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmwasm/wasm/v1/contract/{address}: get: summary: ContractInfo gets the contract meta data operationId: ContractInfo_6MJBN responses: '200': description: A successful response. schema: type: object properties: address: type: string title: address is the address of the contract contract_info: type: object properties: code_id: type: string format: uint64 title: CodeID is the reference to the stored Wasm code creator: type: string title: Creator address who initially instantiated the contract admin: type: string title: Admin is an optional address that can execute migrations label: type: string description: >- Label is optional metadata to be stored with a contract instance. created: description: Created Tx position when the contract was instantiated. type: object properties: block_height: type: string format: uint64 title: BlockHeight is the block the contract was created at tx_index: type: string format: uint64 title: >- TxIndex is a monotonic counter within the block (actual transaction index, or gas consumed) ibc_port_id: type: string extension: type: object properties: type_url: type: string value: type: string format: byte description: >- Extension is an extension point to store custom metadata within the persistence model. title: ContractInfo stores a WASM contract instance title: >- QueryContractInfoResponse is the response type for the Query/ContractInfo RPC method default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: address description: address is the address of the contract to query in: path required: true type: string tags: - gRPC Gateway API /cosmwasm/wasm/v1/contract/{address}/history: get: summary: ContractHistory gets the contract code history operationId: ContractHistory_5CXKC responses: '200': description: A successful response. schema: type: object properties: entries: type: array items: type: object properties: operation: type: string enum: - CONTRACT_CODE_HISTORY_OPERATION_TYPE_UNSPECIFIED - CONTRACT_CODE_HISTORY_OPERATION_TYPE_INIT - CONTRACT_CODE_HISTORY_OPERATION_TYPE_MIGRATE - CONTRACT_CODE_HISTORY_OPERATION_TYPE_GENESIS default: CONTRACT_CODE_HISTORY_OPERATION_TYPE_UNSPECIFIED description: >- - CONTRACT_CODE_HISTORY_OPERATION_TYPE_UNSPECIFIED: ContractCodeHistoryOperationTypeUnspecified placeholder for empty value - CONTRACT_CODE_HISTORY_OPERATION_TYPE_INIT: ContractCodeHistoryOperationTypeInit on chain contract instantiation - CONTRACT_CODE_HISTORY_OPERATION_TYPE_MIGRATE: ContractCodeHistoryOperationTypeMigrate code migration - CONTRACT_CODE_HISTORY_OPERATION_TYPE_GENESIS: ContractCodeHistoryOperationTypeGenesis based on genesis data title: >- ContractCodeHistoryOperationType actions that caused a code change code_id: type: string format: uint64 title: CodeID is the reference to the stored WASM code updated: description: Updated Tx position when the operation was executed. type: object properties: block_height: type: string format: uint64 title: BlockHeight is the block the contract was created at tx_index: type: string format: uint64 title: >- TxIndex is a monotonic counter within the block (actual transaction index, or gas consumed) msg: type: string format: byte description: ContractCodeHistoryEntry metadata to a contract. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: |- QueryContractHistoryResponse is the response type for the Query/ContractHistory RPC method default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: address description: address is the address of the contract to query in: path required: true type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmwasm/wasm/v1/contract/{address}/raw/{query_data}: get: summary: RawContractState gets single key from the raw store data of a contract operationId: RawContractState_HN7KQ responses: '200': description: A successful response. schema: type: object properties: data: type: string format: byte title: Data contains the raw store data title: |- QueryRawContractStateResponse is the response type for the Query/RawContractState RPC method default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: address description: address is the address of the contract in: path required: true type: string - name: query_data in: path required: true type: string format: byte tags: - gRPC Gateway API /cosmwasm/wasm/v1/contract/{address}/smart/{query_data}: get: summary: SmartContractState get smart query result from the contract operationId: SmartContractState_7RZK1 responses: '200': description: A successful response. schema: type: object properties: data: type: string format: byte title: Data contains the json data returned from the smart contract title: |- QuerySmartContractStateResponse is the response type for the Query/SmartContractState RPC method default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: address description: address is the address of the contract in: path required: true type: string - name: query_data description: QueryData contains the query data passed to the contract in: path required: true type: string format: byte tags: - gRPC Gateway API /cosmwasm/wasm/v1/contract/{address}/state: get: summary: AllContractState gets all raw store data for a single contract operationId: AllContractState_8F65W responses: '200': description: A successful response. schema: type: object properties: models: type: array items: type: object properties: key: type: string format: byte title: hex-encode key to read it better (this is often ascii) value: type: string format: byte title: base64-encode raw value title: Model is a struct that holds a KV pair pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: |- QueryAllContractStateResponse is the response type for the Query/AllContractState RPC method default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: address description: address is the address of the contract in: path required: true type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmwasm/wasm/v1/contracts/creator/{creator_address}: get: summary: ContractsByCreator gets the contracts by creator operationId: ContractsByCreator_Y148N responses: '200': description: A successful response. schema: type: object properties: contract_addresses: type: array items: type: string title: ContractAddresses result set pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: |- QueryContractsByCreatorResponse is the response type for the Query/ContractsByCreator RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: creator_address description: CreatorAddress is the address of contract creator in: path required: true type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cyber/bandwidth/v1beta1/bandwidth/load: get: operationId: Load_3QI57 responses: '200': description: A successful response. schema: type: object properties: load: type: string default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cyber/bandwidth/v1beta1/bandwidth/neuron/{neuron}: get: operationId: NeuronBandwidth_1DGP1 responses: '200': description: A successful response. schema: type: object properties: neuron_bandwidth: type: object properties: neuron: type: string remained_value: type: string format: uint64 last_updated_block: type: string format: uint64 max_value: type: string format: uint64 default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: neuron in: path required: true type: string tags: - gRPC Gateway API /cyber/bandwidth/v1beta1/bandwidth/params: get: operationId: Params_B8C0X responses: '200': description: A successful response. schema: type: object properties: params: type: object properties: recovery_period: type: string format: uint64 adjust_price_period: type: string format: uint64 base_price: type: string base_load: type: string max_block_bandwidth: type: string format: uint64 default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cyber/bandwidth/v1beta1/bandwidth/price: get: operationId: Price_LCDUB responses: '200': description: A successful response. schema: type: object properties: price: type: string default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cyber/bandwidth/v1beta1/bandwidth/total: get: operationId: TotalBandwidth_7HIK3 responses: '200': description: A successful response. schema: type: object properties: total_bandwidth: type: string format: uint64 default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/base/tendermint/v1beta1/abci_query: get: summary: >- ABCIQuery defines a query handler that supports ABCI queries directly to the application, bypassing Tendermint completely. The ABCI query must contain a valid and supported path, including app, custom, p2p, and store. description: 'Since: cosmos-sdk 0.46' operationId: ABCIQuery_5ACTN responses: '200': description: A successful response. schema: type: object properties: code: type: integer format: int64 log: type: string info: type: string index: type: string format: int64 key: type: string format: byte value: type: string format: byte proof_ops: type: object properties: ops: type: array items: type: object properties: type: type: string key: type: string format: byte data: type: string format: byte description: >- ProofOp defines an operation used for calculating Merkle root. The data could be arbitrary format, providing necessary data for example neighbouring node hash. Note: This type is a duplicate of the ProofOp proto type defined in Tendermint. description: >- ProofOps is Merkle proof defined by the list of ProofOps. Note: This type is a duplicate of the ProofOps proto type defined in Tendermint. height: type: string format: int64 codespace: type: string description: >- ABCIQueryResponse defines the response structure for the ABCIQuery gRPC query. Note: This type is a duplicate of the ResponseQuery proto type defined in Tendermint. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: data in: query required: false type: string format: byte - name: path in: query required: false type: string - name: height in: query required: false type: string format: int64 - name: prove in: query required: false type: boolean tags: - gRPC Gateway API /cosmos/base/tendermint/v1beta1/blocks/latest: get: summary: GetLatestBlock returns the latest block. operationId: GetLatestBlock_QLNC7 responses: '200': description: A successful response. schema: type: object properties: block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID block: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. data: type: object properties: txs: type: array items: type: string format: byte description: >- Txs that will be applied by state @ block.Height+1. NOTE: not all txs here are valid. We're just agreeing on the order first. This means that block.AppHash does not include these txs. title: >- Data contains the set of transactions included in the block evidence: type: object properties: evidence: type: array items: type: object properties: duplicate_vote_evidence: type: object properties: vote_a: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. vote_b: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. total_voting_power: type: string format: int64 validator_power: type: string format: int64 timestamp: type: string format: date-time description: >- DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes. light_client_attack_evidence: type: object properties: conflicting_block: type: object properties: signed_header: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: >- hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: >- Header defines the structure of a block header. commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: >- BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: >- CommitSig is a part of the Vote included in a Commit. description: >- Commit contains the evidence that a block was committed by a set of validators. validator_set: type: object properties: validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 proposer: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 common_height: type: string format: int64 byzantine_validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 timestamp: type: string format: date-time description: >- LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client. last_commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: >- BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: >- CommitSig is a part of the Vote included in a Commit. description: >- Commit contains the evidence that a block was committed by a set of validators. title: 'Deprecated: please use `sdk_block` instead' sdk_block: title: 'Since: cosmos-sdk 0.47' type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string description: >- proposer_address is the original block proposer address, formatted as a Bech32 string. In Tendermint, this type is `bytes`, but in the SDK, we convert it to a Bech32 string for better UX. description: Header defines the structure of a Tendermint block header. data: type: object properties: txs: type: array items: type: string format: byte description: >- Txs that will be applied by state @ block.Height+1. NOTE: not all txs here are valid. We're just agreeing on the order first. This means that block.AppHash does not include these txs. title: >- Data contains the set of transactions included in the block evidence: type: object properties: evidence: type: array items: type: object properties: duplicate_vote_evidence: type: object properties: vote_a: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. vote_b: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. total_voting_power: type: string format: int64 validator_power: type: string format: int64 timestamp: type: string format: date-time description: >- DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes. light_client_attack_evidence: type: object properties: conflicting_block: type: object properties: signed_header: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: >- hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: >- Header defines the structure of a block header. commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: >- BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: >- CommitSig is a part of the Vote included in a Commit. description: >- Commit contains the evidence that a block was committed by a set of validators. validator_set: type: object properties: validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 proposer: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 common_height: type: string format: int64 byzantine_validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 timestamp: type: string format: date-time description: >- LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client. last_commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: >- BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: >- CommitSig is a part of the Vote included in a Commit. description: >- Commit contains the evidence that a block was committed by a set of validators. description: >- Block is tendermint type Block, with the Header proposer address field converted to bech32 string. description: >- GetLatestBlockResponse is the response type for the Query/GetLatestBlock RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/base/tendermint/v1beta1/blocks/{height}: get: summary: GetBlockByHeight queries block for given height. operationId: GetBlockByHeight_FSKO8 responses: '200': description: A successful response. schema: type: object properties: block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID block: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. data: type: object properties: txs: type: array items: type: string format: byte description: >- Txs that will be applied by state @ block.Height+1. NOTE: not all txs here are valid. We're just agreeing on the order first. This means that block.AppHash does not include these txs. title: >- Data contains the set of transactions included in the block evidence: type: object properties: evidence: type: array items: type: object properties: duplicate_vote_evidence: type: object properties: vote_a: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. vote_b: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. total_voting_power: type: string format: int64 validator_power: type: string format: int64 timestamp: type: string format: date-time description: >- DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes. light_client_attack_evidence: type: object properties: conflicting_block: type: object properties: signed_header: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: >- hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: >- Header defines the structure of a block header. commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: >- BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: >- CommitSig is a part of the Vote included in a Commit. description: >- Commit contains the evidence that a block was committed by a set of validators. validator_set: type: object properties: validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 proposer: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 common_height: type: string format: int64 byzantine_validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 timestamp: type: string format: date-time description: >- LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client. last_commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: >- BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: >- CommitSig is a part of the Vote included in a Commit. description: >- Commit contains the evidence that a block was committed by a set of validators. title: 'Deprecated: please use `sdk_block` instead' sdk_block: title: 'Since: cosmos-sdk 0.47' type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string description: >- proposer_address is the original block proposer address, formatted as a Bech32 string. In Tendermint, this type is `bytes`, but in the SDK, we convert it to a Bech32 string for better UX. description: Header defines the structure of a Tendermint block header. data: type: object properties: txs: type: array items: type: string format: byte description: >- Txs that will be applied by state @ block.Height+1. NOTE: not all txs here are valid. We're just agreeing on the order first. This means that block.AppHash does not include these txs. title: >- Data contains the set of transactions included in the block evidence: type: object properties: evidence: type: array items: type: object properties: duplicate_vote_evidence: type: object properties: vote_a: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. vote_b: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. total_voting_power: type: string format: int64 validator_power: type: string format: int64 timestamp: type: string format: date-time description: >- DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes. light_client_attack_evidence: type: object properties: conflicting_block: type: object properties: signed_header: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: >- hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: >- Header defines the structure of a block header. commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: >- BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: >- CommitSig is a part of the Vote included in a Commit. description: >- Commit contains the evidence that a block was committed by a set of validators. validator_set: type: object properties: validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 proposer: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 common_height: type: string format: int64 byzantine_validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 timestamp: type: string format: date-time description: >- LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client. last_commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: >- BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: >- CommitSig is a part of the Vote included in a Commit. description: >- Commit contains the evidence that a block was committed by a set of validators. description: >- Block is tendermint type Block, with the Header proposer address field converted to bech32 string. description: >- GetBlockByHeightResponse is the response type for the Query/GetBlockByHeight RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: height in: path required: true type: string format: int64 tags: - gRPC Gateway API /cosmos/base/tendermint/v1beta1/node_info: get: summary: GetNodeInfo queries the current node info. operationId: GetNodeInfo_IVP7S responses: '200': description: A successful response. schema: type: object properties: default_node_info: type: object properties: protocol_version: type: object properties: p2p: type: string format: uint64 block: type: string format: uint64 app: type: string format: uint64 default_node_id: type: string listen_addr: type: string network: type: string version: type: string channels: type: string format: byte moniker: type: string other: type: object properties: tx_index: type: string rpc_address: type: string application_version: type: object properties: name: type: string app_name: type: string version: type: string git_commit: type: string build_tags: type: string go_version: type: string build_deps: type: array items: type: object properties: path: type: string title: module path version: type: string title: module version sum: type: string title: checksum title: Module is the type for VersionInfo cosmos_sdk_version: type: string title: 'Since: cosmos-sdk 0.43' description: VersionInfo is the type for the GetNodeInfoResponse message. description: >- GetNodeInfoResponse is the response type for the Query/GetNodeInfo RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/base/tendermint/v1beta1/syncing: get: summary: GetSyncing queries node syncing. operationId: GetSyncing_9SHWP responses: '200': description: A successful response. schema: type: object properties: syncing: type: boolean description: >- GetSyncingResponse is the response type for the Query/GetSyncing RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/base/tendermint/v1beta1/validatorsets/latest: get: summary: GetLatestValidatorSet queries latest validator-set. operationId: GetLatestValidatorSet_Y0S55 responses: '200': description: A successful response. schema: type: object properties: block_height: type: string format: int64 validators: type: array items: type: object properties: address: type: string pub_key: type: object properties: type_url: type: string value: type: string format: byte voting_power: type: string format: int64 proposer_priority: type: string format: int64 description: Validator is the type for the validator-set. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- GetLatestValidatorSetResponse is the response type for the Query/GetValidatorSetByHeight RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmos/base/tendermint/v1beta1/validatorsets/{height}: get: summary: GetValidatorSetByHeight queries validator-set at a given height. operationId: GetValidatorSetByHeight_WR03D responses: '200': description: A successful response. schema: type: object properties: block_height: type: string format: int64 validators: type: array items: type: object properties: address: type: string pub_key: type: object properties: type_url: type: string value: type: string format: byte voting_power: type: string format: int64 proposer_priority: type: string format: int64 description: Validator is the type for the validator-set. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- GetValidatorSetByHeightResponse is the response type for the Query/GetValidatorSetByHeight RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: height in: path required: true type: string format: int64 - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmos/slashing/v1beta1/params: get: summary: Params queries the parameters of slashing module operationId: Params_MFGZ0 responses: '200': description: A successful response. schema: type: object properties: params: type: object properties: signed_blocks_window: type: string format: int64 min_signed_per_window: type: string format: byte downtime_jail_duration: type: string slash_fraction_double_sign: type: string format: byte slash_fraction_downtime: type: string format: byte description: >- Params represents the parameters used for by the slashing module. title: >- QueryParamsResponse is the response type for the Query/Params RPC method default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/slashing/v1beta1/signing_infos: get: summary: SigningInfos queries signing info of all validators operationId: SigningInfos_SD3H8 responses: '200': description: A successful response. schema: type: object properties: info: type: array items: type: object properties: address: type: string start_height: type: string format: int64 title: >- Height at which validator was first a candidate OR was unjailed index_offset: type: string format: int64 description: >- Index which is incremented each time the validator was a bonded in a block and may have signed a precommit or not. This in conjunction with the `SignedBlocksWindow` param determines the index in the `MissedBlocksBitArray`. jailed_until: type: string format: date-time description: >- Timestamp until which the validator is jailed due to liveness downtime. tombstoned: type: boolean description: >- Whether or not a validator has been tombstoned (killed out of validator set). It is set once the validator commits an equivocation or for any other configured misbehiavor. missed_blocks_counter: type: string format: int64 description: >- A counter kept to avoid unnecessary array reads. Note that `Sum(MissedBlocksBitArray)` always equals `MissedBlocksCounter`. description: >- ValidatorSigningInfo defines a validator's signing info for monitoring their liveness activity. title: info is the signing info of all validators pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: >- QuerySigningInfosResponse is the response type for the Query/SigningInfos RPC method default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmos/slashing/v1beta1/signing_infos/{cons_address}: get: summary: SigningInfo queries the signing info of given cons address operationId: SigningInfo_2HQ8N responses: '200': description: A successful response. schema: type: object properties: val_signing_info: type: object properties: address: type: string start_height: type: string format: int64 title: >- Height at which validator was first a candidate OR was unjailed index_offset: type: string format: int64 description: >- Index which is incremented each time the validator was a bonded in a block and may have signed a precommit or not. This in conjunction with the `SignedBlocksWindow` param determines the index in the `MissedBlocksBitArray`. jailed_until: type: string format: date-time description: >- Timestamp until which the validator is jailed due to liveness downtime. tombstoned: type: boolean description: >- Whether or not a validator has been tombstoned (killed out of validator set). It is set once the validator commits an equivocation or for any other configured misbehiavor. missed_blocks_counter: type: string format: int64 description: >- A counter kept to avoid unnecessary array reads. Note that `Sum(MissedBlocksBitArray)` always equals `MissedBlocksCounter`. description: >- ValidatorSigningInfo defines a validator's signing info for monitoring their liveness activity. title: >- val_signing_info is the signing info of requested val cons address title: >- QuerySigningInfoResponse is the response type for the Query/SigningInfo RPC method default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: cons_address description: cons_address is the address to query signing info of in: path required: true type: string tags: - gRPC Gateway API /cosmos/gov/v1beta1/params/{params_type}: get: summary: Params queries all parameters of the gov module. operationId: Params_PJJN8 responses: '200': description: A successful response. schema: type: object properties: voting_params: description: voting_params defines the parameters related to voting. type: object properties: voting_period: type: string description: Duration of the voting period. deposit_params: description: deposit_params defines the parameters related to deposit. type: object properties: min_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: Minimum deposit for a proposal to enter voting period. max_deposit_period: type: string description: >- Maximum period for Atom holders to deposit on a proposal. Initial value: 2 months. tally_params: description: tally_params defines the parameters related to tally. type: object properties: quorum: type: string format: byte description: >- Minimum percentage of total stake needed to vote for a result to be considered valid. threshold: type: string format: byte description: >- Minimum proportion of Yes votes for proposal to pass. Default value: 0.5. veto_threshold: type: string format: byte description: >- Minimum value of Veto votes to Total votes ratio for proposal to be vetoed. Default value: 1/3. description: >- QueryParamsResponse is the response type for the Query/Params RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: params_type description: >- params_type defines which parameters to query for, can be one of "voting", "tallying" or "deposit". in: path required: true type: string tags: - gRPC Gateway API /cosmos/gov/v1beta1/proposals: get: summary: Proposals queries all proposals based on given status. operationId: Proposals_XD66Y responses: '200': description: A successful response. schema: type: object properties: proposals: type: array items: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. content: type: object properties: type_url: type: string value: type: string format: byte description: content is the proposal's content. status: description: status defines the proposal status. type: string enum: - PROPOSAL_STATUS_UNSPECIFIED - PROPOSAL_STATUS_DEPOSIT_PERIOD - PROPOSAL_STATUS_VOTING_PERIOD - PROPOSAL_STATUS_PASSED - PROPOSAL_STATUS_REJECTED - PROPOSAL_STATUS_FAILED default: PROPOSAL_STATUS_UNSPECIFIED final_tally_result: description: >- final_tally_result is the final tally result of the proposal. When querying a proposal via gRPC, this field is not populated until the proposal's voting period has ended. type: object properties: 'yes': type: string description: yes is the number of yes votes on a proposal. abstain: type: string description: >- abstain is the number of abstain votes on a proposal. 'no': type: string description: no is the number of no votes on a proposal. no_with_veto: type: string description: >- no_with_veto is the number of no with veto votes on a proposal. submit_time: type: string format: date-time description: submit_time is the time of proposal submission. deposit_end_time: type: string format: date-time description: deposit_end_time is the end time for deposition. total_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: total_deposit is the total deposit on the proposal. voting_start_time: type: string format: date-time description: >- voting_start_time is the starting time to vote on a proposal. voting_end_time: type: string format: date-time description: voting_end_time is the end time of voting on a proposal. description: >- Proposal defines the core field members of a governance proposal. description: proposals defines all the requested governance proposals. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- QueryProposalsResponse is the response type for the Query/Proposals RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: proposal_status description: |- proposal_status defines the status of the proposals. - PROPOSAL_STATUS_UNSPECIFIED: PROPOSAL_STATUS_UNSPECIFIED defines the default proposal status. - PROPOSAL_STATUS_DEPOSIT_PERIOD: PROPOSAL_STATUS_DEPOSIT_PERIOD defines a proposal status during the deposit period. - PROPOSAL_STATUS_VOTING_PERIOD: PROPOSAL_STATUS_VOTING_PERIOD defines a proposal status during the voting period. - PROPOSAL_STATUS_PASSED: PROPOSAL_STATUS_PASSED defines a proposal status of a proposal that has passed. - PROPOSAL_STATUS_REJECTED: PROPOSAL_STATUS_REJECTED defines a proposal status of a proposal that has been rejected. - PROPOSAL_STATUS_FAILED: PROPOSAL_STATUS_FAILED defines a proposal status of a proposal that has failed. in: query required: false type: string enum: - PROPOSAL_STATUS_UNSPECIFIED - PROPOSAL_STATUS_DEPOSIT_PERIOD - PROPOSAL_STATUS_VOTING_PERIOD - PROPOSAL_STATUS_PASSED - PROPOSAL_STATUS_REJECTED - PROPOSAL_STATUS_FAILED default: PROPOSAL_STATUS_UNSPECIFIED - name: voter description: voter defines the voter address for the proposals. in: query required: false type: string - name: depositor description: depositor defines the deposit addresses from the proposals. in: query required: false type: string - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmos/gov/v1beta1/proposals/{proposal_id}: get: summary: Proposal queries proposal details based on ProposalID. operationId: Proposal_Q4TVD responses: '200': description: A successful response. schema: type: object properties: proposal: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. content: type: object properties: type_url: type: string value: type: string format: byte description: content is the proposal's content. status: description: status defines the proposal status. type: string enum: - PROPOSAL_STATUS_UNSPECIFIED - PROPOSAL_STATUS_DEPOSIT_PERIOD - PROPOSAL_STATUS_VOTING_PERIOD - PROPOSAL_STATUS_PASSED - PROPOSAL_STATUS_REJECTED - PROPOSAL_STATUS_FAILED default: PROPOSAL_STATUS_UNSPECIFIED final_tally_result: description: >- final_tally_result is the final tally result of the proposal. When querying a proposal via gRPC, this field is not populated until the proposal's voting period has ended. type: object properties: 'yes': type: string description: yes is the number of yes votes on a proposal. abstain: type: string description: abstain is the number of abstain votes on a proposal. 'no': type: string description: no is the number of no votes on a proposal. no_with_veto: type: string description: >- no_with_veto is the number of no with veto votes on a proposal. submit_time: type: string format: date-time description: submit_time is the time of proposal submission. deposit_end_time: type: string format: date-time description: deposit_end_time is the end time for deposition. total_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: total_deposit is the total deposit on the proposal. voting_start_time: type: string format: date-time description: >- voting_start_time is the starting time to vote on a proposal. voting_end_time: type: string format: date-time description: voting_end_time is the end time of voting on a proposal. description: >- Proposal defines the core field members of a governance proposal. description: >- QueryProposalResponse is the response type for the Query/Proposal RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: proposal_id description: proposal_id defines the unique id of the proposal. in: path required: true type: string format: uint64 tags: - gRPC Gateway API /cosmos/gov/v1beta1/proposals/{proposal_id}/deposits: get: summary: Deposits queries all deposits of a single proposal. operationId: Deposits_1L75C responses: '200': description: A successful response. schema: type: object properties: deposits: type: array items: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. depositor: type: string description: >- depositor defines the deposit addresses from the proposals. amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: amount to be deposited by depositor. description: >- Deposit defines an amount deposited by an account address to an active proposal. description: deposits defines the requested deposits. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- QueryDepositsResponse is the response type for the Query/Deposits RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: proposal_id description: proposal_id defines the unique id of the proposal. in: path required: true type: string format: uint64 - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmos/gov/v1beta1/proposals/{proposal_id}/deposits/{depositor}: get: summary: >- Deposit queries single deposit information based proposalID, depositAddr. operationId: Deposit_VE3QO responses: '200': description: A successful response. schema: type: object properties: deposit: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. depositor: type: string description: >- depositor defines the deposit addresses from the proposals. amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: amount to be deposited by depositor. description: >- Deposit defines an amount deposited by an account address to an active proposal. description: >- QueryDepositResponse is the response type for the Query/Deposit RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: proposal_id description: proposal_id defines the unique id of the proposal. in: path required: true type: string format: uint64 - name: depositor description: depositor defines the deposit addresses from the proposals. in: path required: true type: string tags: - gRPC Gateway API /cosmos/gov/v1beta1/proposals/{proposal_id}/tally: get: summary: TallyResult queries the tally of a proposal vote. operationId: TallyResult_WW72B responses: '200': description: A successful response. schema: type: object properties: tally: description: tally defines the requested tally. type: object properties: 'yes': type: string description: yes is the number of yes votes on a proposal. abstain: type: string description: abstain is the number of abstain votes on a proposal. 'no': type: string description: no is the number of no votes on a proposal. no_with_veto: type: string description: >- no_with_veto is the number of no with veto votes on a proposal. description: >- QueryTallyResultResponse is the response type for the Query/Tally RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: proposal_id description: proposal_id defines the unique id of the proposal. in: path required: true type: string format: uint64 tags: - gRPC Gateway API /cosmos/gov/v1beta1/proposals/{proposal_id}/votes: get: summary: Votes queries votes of a given proposal. operationId: Votes_M6ZAN responses: '200': description: A successful response. schema: type: object properties: votes: type: array items: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. voter: type: string description: voter is the voter address of the proposal. option: description: >- Deprecated: Prefer to use `options` instead. This field is set in queries if and only if `len(options) == 1` and that option has weight 1. In all other cases, this field will default to VOTE_OPTION_UNSPECIFIED. type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED options: type: array items: type: object properties: option: description: >- option defines the valid vote options, it must not contain duplicate vote options. type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED weight: type: string description: >- weight is the vote weight associated with the vote option. description: >- WeightedVoteOption defines a unit of vote for vote split. Since: cosmos-sdk 0.43 description: |- options is the weighted vote options. Since: cosmos-sdk 0.43 description: >- Vote defines a vote on a governance proposal. A Vote consists of a proposal ID, the voter, and the vote option. description: votes defines the queried votes. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- QueryVotesResponse is the response type for the Query/Votes RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: proposal_id description: proposal_id defines the unique id of the proposal. in: path required: true type: string format: uint64 - name: pagination.key description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. in: query required: false type: string format: byte - name: pagination.offset description: >- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. in: query required: false type: string format: uint64 - name: pagination.limit description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. in: query required: false type: string format: uint64 - name: pagination.count_total description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. in: query required: false type: boolean - name: pagination.reverse description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 in: query required: false type: boolean tags: - gRPC Gateway API /cosmos/gov/v1beta1/proposals/{proposal_id}/votes/{voter}: get: summary: Vote queries voted information based on proposalID, voterAddr. operationId: Vote_4I9SV responses: '200': description: A successful response. schema: type: object properties: vote: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. voter: type: string description: voter is the voter address of the proposal. option: description: >- Deprecated: Prefer to use `options` instead. This field is set in queries if and only if `len(options) == 1` and that option has weight 1. In all other cases, this field will default to VOTE_OPTION_UNSPECIFIED. type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED options: type: array items: type: object properties: option: description: >- option defines the valid vote options, it must not contain duplicate vote options. type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED weight: type: string description: >- weight is the vote weight associated with the vote option. description: >- WeightedVoteOption defines a unit of vote for vote split. Since: cosmos-sdk 0.43 description: |- options is the weighted vote options. Since: cosmos-sdk 0.43 description: >- Vote defines a vote on a governance proposal. A Vote consists of a proposal ID, the voter, and the vote option. description: >- QueryVoteResponse is the response type for the Query/Vote RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte parameters: - name: proposal_id description: proposal_id defines the unique id of the proposal. in: path required: true type: string format: uint64 - name: voter description: voter defines the voter address for the proposals. in: path required: true type: string tags: - gRPC Gateway API /cosmos/mint/v1beta1/annual_provisions: get: summary: AnnualProvisions current minting annual provisions value. operationId: AnnualProvisions_JHHBU responses: '200': description: A successful response. schema: type: object properties: annual_provisions: type: string format: byte description: >- annual_provisions is the current minting annual provisions value. description: |- QueryAnnualProvisionsResponse is the response type for the Query/AnnualProvisions RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/mint/v1beta1/inflation: get: summary: Inflation returns the current minting inflation value. operationId: Inflation_RXNBT responses: '200': description: A successful response. schema: type: object properties: inflation: type: string format: byte description: inflation is the current minting inflation value. description: >- QueryInflationResponse is the response type for the Query/Inflation RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API /cosmos/mint/v1beta1/params: get: summary: Params returns the total set of minting parameters. operationId: Params_3M1PF responses: '200': description: A successful response. schema: type: object properties: params: description: params defines the parameters of the module. type: object properties: mint_denom: type: string title: type of coin to mint inflation_rate_change: type: string title: maximum annual change in inflation rate inflation_max: type: string title: maximum inflation rate inflation_min: type: string title: minimum inflation rate goal_bonded: type: string title: goal of percent bonded atoms blocks_per_year: type: string format: uint64 title: expected blocks per year description: >- QueryParamsResponse is the response type for the Query/Params RPC method. default: description: An unexpected error response. schema: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tags: - gRPC Gateway API definitions: cosmos.consensus.v1.QueryParamsResponse: type: object properties: params: description: >- params are the tendermint consensus params stored in the consensus module. Please note that `params.version` is not populated in this response, it is tracked separately in the x/upgrade module. type: object properties: block: type: object properties: max_bytes: type: string format: int64 title: |- Max block size, in bytes. Note: must be greater than 0 max_gas: type: string format: int64 title: |- Max gas per block. Note: must be greater or equal to -1 description: BlockParams contains limits on the block size. evidence: type: object properties: max_age_num_blocks: type: string format: int64 description: >- Max age of evidence, in blocks. The basic formula for calculating this is: MaxAgeDuration / {average block time}. max_age_duration: type: string description: >- Max age of evidence, in time. It should correspond with an app's "unbonding period" or other similar mechanism for handling [Nothing-At-Stake attacks](https://github.com/ethereum/wiki/wiki/Proof-of-Stake-FAQ#what-is-the-nothing-at-stake-problem-and-how-can-it-be-fixed). max_bytes: type: string format: int64 title: >- This sets the maximum size of total evidence in bytes that can be committed in a single block. and should fall comfortably under the max block bytes. Default is 1048576 or 1MB description: EvidenceParams determine how we handle evidence of malfeasance. validator: type: object properties: pub_key_types: type: array items: type: string description: |- ValidatorParams restrict the public key types validators can use. NOTE: uses ABCI pubkey naming, not Amino names. version: type: object properties: app: type: string format: uint64 description: VersionParams contains the ABCI application version. description: >- QueryParamsResponse defines the response type for querying x/consensus parameters. google.protobuf.Any: type: object properties: type_url: type: string value: type: string format: byte grpc.gateway.runtime.Error: type: object properties: error: type: string code: type: integer format: int32 message: type: string details: type: array items: type: object properties: type_url: type: string value: type: string format: byte tendermint.types.BlockParams: type: object properties: max_bytes: type: string format: int64 title: |- Max block size, in bytes. Note: must be greater than 0 max_gas: type: string format: int64 title: |- Max gas per block. Note: must be greater or equal to -1 description: BlockParams contains limits on the block size. tendermint.types.ConsensusParams: type: object properties: block: type: object properties: max_bytes: type: string format: int64 title: |- Max block size, in bytes. Note: must be greater than 0 max_gas: type: string format: int64 title: |- Max gas per block. Note: must be greater or equal to -1 description: BlockParams contains limits on the block size. evidence: type: object properties: max_age_num_blocks: type: string format: int64 description: >- Max age of evidence, in blocks. The basic formula for calculating this is: MaxAgeDuration / {average block time}. max_age_duration: type: string description: >- Max age of evidence, in time. It should correspond with an app's "unbonding period" or other similar mechanism for handling [Nothing-At-Stake attacks](https://github.com/ethereum/wiki/wiki/Proof-of-Stake-FAQ#what-is-the-nothing-at-stake-problem-and-how-can-it-be-fixed). max_bytes: type: string format: int64 title: >- This sets the maximum size of total evidence in bytes that can be committed in a single block. and should fall comfortably under the max block bytes. Default is 1048576 or 1MB description: EvidenceParams determine how we handle evidence of malfeasance. validator: type: object properties: pub_key_types: type: array items: type: string description: |- ValidatorParams restrict the public key types validators can use. NOTE: uses ABCI pubkey naming, not Amino names. version: type: object properties: app: type: string format: uint64 description: VersionParams contains the ABCI application version. description: |- ConsensusParams contains consensus critical parameters that determine the validity of blocks. tendermint.types.EvidenceParams: type: object properties: max_age_num_blocks: type: string format: int64 description: >- Max age of evidence, in blocks. The basic formula for calculating this is: MaxAgeDuration / {average block time}. max_age_duration: type: string description: >- Max age of evidence, in time. It should correspond with an app's "unbonding period" or other similar mechanism for handling [Nothing-At-Stake attacks](https://github.com/ethereum/wiki/wiki/Proof-of-Stake-FAQ#what-is-the-nothing-at-stake-problem-and-how-can-it-be-fixed). max_bytes: type: string format: int64 title: >- This sets the maximum size of total evidence in bytes that can be committed in a single block. and should fall comfortably under the max block bytes. Default is 1048576 or 1MB description: EvidenceParams determine how we handle evidence of malfeasance. tendermint.types.ValidatorParams: type: object properties: pub_key_types: type: array items: type: string description: |- ValidatorParams restrict the public key types validators can use. NOTE: uses ABCI pubkey naming, not Amino names. tendermint.types.VersionParams: type: object properties: app: type: string format: uint64 description: VersionParams contains the ABCI application version. cosmos.base.query.v1beta1.PageRequest: type: object properties: key: type: string format: byte description: |- key is a value returned in PageResponse.next_key to begin querying the next page most efficiently. Only one of offset or key should be set. offset: type: string format: uint64 description: |- offset is a numeric offset that can be used when key is unavailable. It is less efficient than using key. Only one of offset or key should be set. limit: type: string format: uint64 description: >- limit is the total number of results to be returned in the result page. If left empty it will default to a value to be set by each app. count_total: type: boolean description: >- count_total is set to true to indicate that the result set should include a count of the total number of items available for pagination in UIs. count_total is only respected when offset is used. It is ignored when key is set. reverse: type: boolean description: >- reverse is set to true if results are to be returned in the descending order. Since: cosmos-sdk 0.43 description: |- message SomeRequest { Foo some_parameter = 1; PageRequest pagination = 2; } title: |- PageRequest is to be embedded in gRPC request messages for efficient pagination. Ex: cosmos.base.query.v1beta1.PageResponse: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: |- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } cosmos.feegrant.v1beta1.Grant: type: object properties: granter: type: string description: >- granter is the address of the user granting an allowance of their funds. grantee: type: string description: >- grantee is the address of the user being granted an allowance of another user's funds. allowance: type: object properties: type_url: type: string value: type: string format: byte description: allowance can be any of basic, periodic, allowed fee allowance. title: Grant is stored in the KVStore to record a grant with full context cosmos.feegrant.v1beta1.QueryAllowanceResponse: type: object properties: allowance: description: allowance is a allowance granted for grantee by granter. type: object properties: granter: type: string description: >- granter is the address of the user granting an allowance of their funds. grantee: type: string description: >- grantee is the address of the user being granted an allowance of another user's funds. allowance: type: object properties: type_url: type: string value: type: string format: byte description: allowance can be any of basic, periodic, allowed fee allowance. title: Grant is stored in the KVStore to record a grant with full context description: >- QueryAllowanceResponse is the response type for the Query/Allowance RPC method. cosmos.feegrant.v1beta1.QueryAllowancesByGranterResponse: type: object properties: allowances: type: array items: type: object properties: granter: type: string description: >- granter is the address of the user granting an allowance of their funds. grantee: type: string description: >- grantee is the address of the user being granted an allowance of another user's funds. allowance: type: object properties: type_url: type: string value: type: string format: byte description: allowance can be any of basic, periodic, allowed fee allowance. title: Grant is stored in the KVStore to record a grant with full context description: allowances that have been issued by the granter. pagination: description: pagination defines an pagination for the response. type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- QueryAllowancesByGranterResponse is the response type for the Query/AllowancesByGranter RPC method. Since: cosmos-sdk 0.46 cosmos.feegrant.v1beta1.QueryAllowancesResponse: type: object properties: allowances: type: array items: type: object properties: granter: type: string description: >- granter is the address of the user granting an allowance of their funds. grantee: type: string description: >- grantee is the address of the user being granted an allowance of another user's funds. allowance: type: object properties: type_url: type: string value: type: string format: byte description: allowance can be any of basic, periodic, allowed fee allowance. title: Grant is stored in the KVStore to record a grant with full context description: allowances are allowance's granted for grantee by granter. pagination: description: pagination defines an pagination for the response. type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- QueryAllowancesResponse is the response type for the Query/Allowances RPC method. cosmos.base.v1beta1.Coin: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. cosmos.gov.v1.Deposit: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. depositor: type: string description: depositor defines the deposit addresses from the proposals. amount: type: array items: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: amount to be deposited by depositor. description: |- Deposit defines an amount deposited by an account address to an active proposal. cosmos.gov.v1.DepositParams: type: object properties: min_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: Minimum deposit for a proposal to enter voting period. max_deposit_period: type: string description: >- Maximum period for Atom holders to deposit on a proposal. Initial value: 2 months. description: DepositParams defines the params for deposits on governance proposals. cosmos.gov.v1.Params: type: object properties: min_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: Minimum deposit for a proposal to enter voting period. max_deposit_period: type: string description: >- Maximum period for Atom holders to deposit on a proposal. Initial value: 2 months. voting_period: type: string description: Duration of the voting period. quorum: type: string description: |- Minimum percentage of total stake needed to vote for a result to be considered valid. threshold: type: string description: >- Minimum proportion of Yes votes for proposal to pass. Default value: 0.5. veto_threshold: type: string description: |- Minimum value of Veto votes to Total votes ratio for proposal to be vetoed. Default value: 1/3. min_initial_deposit_ratio: type: string description: >- The ratio representing the proportion of the deposit value that must be paid at proposal submission. burn_vote_quorum: type: boolean title: burn deposits if a proposal does not meet quorum burn_proposal_deposit_prevote: type: boolean title: burn deposits if the proposal does not enter voting period burn_vote_veto: type: boolean title: burn deposits if quorum with vote type no_veto is met description: |- Params defines the parameters for the x/gov module. Since: cosmos-sdk 0.47 cosmos.gov.v1.Proposal: type: object properties: id: type: string format: uint64 description: id defines the unique id of the proposal. messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- messages are the arbitrary messages to be executed if the proposal passes. status: description: status defines the proposal status. type: string enum: - PROPOSAL_STATUS_UNSPECIFIED - PROPOSAL_STATUS_DEPOSIT_PERIOD - PROPOSAL_STATUS_VOTING_PERIOD - PROPOSAL_STATUS_PASSED - PROPOSAL_STATUS_REJECTED - PROPOSAL_STATUS_FAILED default: PROPOSAL_STATUS_UNSPECIFIED final_tally_result: description: |- final_tally_result is the final tally result of the proposal. When querying a proposal via gRPC, this field is not populated until the proposal's voting period has ended. type: object properties: yes_count: type: string description: yes_count is the number of yes votes on a proposal. abstain_count: type: string description: abstain_count is the number of abstain votes on a proposal. no_count: type: string description: no_count is the number of no votes on a proposal. no_with_veto_count: type: string description: >- no_with_veto_count is the number of no with veto votes on a proposal. submit_time: type: string format: date-time description: submit_time is the time of proposal submission. deposit_end_time: type: string format: date-time description: deposit_end_time is the end time for deposition. total_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: total_deposit is the total deposit on the proposal. voting_start_time: type: string format: date-time description: voting_start_time is the starting time to vote on a proposal. voting_end_time: type: string format: date-time description: voting_end_time is the end time of voting on a proposal. metadata: type: string description: metadata is any arbitrary metadata attached to the proposal. title: type: string description: 'Since: cosmos-sdk 0.47' title: title is the title of the proposal summary: type: string description: 'Since: cosmos-sdk 0.47' title: summary is a short summary of the proposal proposer: type: string description: 'Since: cosmos-sdk 0.47' title: Proposer is the address of the proposal sumbitter description: Proposal defines the core field members of a governance proposal. cosmos.gov.v1.ProposalStatus: type: string enum: - PROPOSAL_STATUS_UNSPECIFIED - PROPOSAL_STATUS_DEPOSIT_PERIOD - PROPOSAL_STATUS_VOTING_PERIOD - PROPOSAL_STATUS_PASSED - PROPOSAL_STATUS_REJECTED - PROPOSAL_STATUS_FAILED default: PROPOSAL_STATUS_UNSPECIFIED description: |- ProposalStatus enumerates the valid statuses of a proposal. - PROPOSAL_STATUS_UNSPECIFIED: PROPOSAL_STATUS_UNSPECIFIED defines the default proposal status. - PROPOSAL_STATUS_DEPOSIT_PERIOD: PROPOSAL_STATUS_DEPOSIT_PERIOD defines a proposal status during the deposit period. - PROPOSAL_STATUS_VOTING_PERIOD: PROPOSAL_STATUS_VOTING_PERIOD defines a proposal status during the voting period. - PROPOSAL_STATUS_PASSED: PROPOSAL_STATUS_PASSED defines a proposal status of a proposal that has passed. - PROPOSAL_STATUS_REJECTED: PROPOSAL_STATUS_REJECTED defines a proposal status of a proposal that has been rejected. - PROPOSAL_STATUS_FAILED: PROPOSAL_STATUS_FAILED defines a proposal status of a proposal that has failed. cosmos.gov.v1.QueryDepositResponse: type: object properties: deposit: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. depositor: type: string description: depositor defines the deposit addresses from the proposals. amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: amount to be deposited by depositor. description: |- Deposit defines an amount deposited by an account address to an active proposal. description: >- QueryDepositResponse is the response type for the Query/Deposit RPC method. cosmos.gov.v1.QueryDepositsResponse: type: object properties: deposits: type: array items: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. depositor: type: string description: depositor defines the deposit addresses from the proposals. amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: amount to be deposited by depositor. description: >- Deposit defines an amount deposited by an account address to an active proposal. description: deposits defines the requested deposits. pagination: description: pagination defines the pagination in the response. type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- QueryDepositsResponse is the response type for the Query/Deposits RPC method. cosmos.gov.v1.QueryParamsResponse: type: object properties: voting_params: description: |- Deprecated: Prefer to use `params` instead. voting_params defines the parameters related to voting. type: object properties: voting_period: type: string description: Duration of the voting period. deposit_params: description: |- Deprecated: Prefer to use `params` instead. deposit_params defines the parameters related to deposit. type: object properties: min_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: Minimum deposit for a proposal to enter voting period. max_deposit_period: type: string description: >- Maximum period for Atom holders to deposit on a proposal. Initial value: 2 months. tally_params: description: |- Deprecated: Prefer to use `params` instead. tally_params defines the parameters related to tally. type: object properties: quorum: type: string description: >- Minimum percentage of total stake needed to vote for a result to be considered valid. threshold: type: string description: >- Minimum proportion of Yes votes for proposal to pass. Default value: 0.5. veto_threshold: type: string description: >- Minimum value of Veto votes to Total votes ratio for proposal to be vetoed. Default value: 1/3. params: description: |- params defines all the paramaters of x/gov module. Since: cosmos-sdk 0.47 type: object properties: min_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: Minimum deposit for a proposal to enter voting period. max_deposit_period: type: string description: >- Maximum period for Atom holders to deposit on a proposal. Initial value: 2 months. voting_period: type: string description: Duration of the voting period. quorum: type: string description: >- Minimum percentage of total stake needed to vote for a result to be considered valid. threshold: type: string description: >- Minimum proportion of Yes votes for proposal to pass. Default value: 0.5. veto_threshold: type: string description: >- Minimum value of Veto votes to Total votes ratio for proposal to be vetoed. Default value: 1/3. min_initial_deposit_ratio: type: string description: >- The ratio representing the proportion of the deposit value that must be paid at proposal submission. burn_vote_quorum: type: boolean title: burn deposits if a proposal does not meet quorum burn_proposal_deposit_prevote: type: boolean title: burn deposits if the proposal does not enter voting period burn_vote_veto: type: boolean title: burn deposits if quorum with vote type no_veto is met description: QueryParamsResponse is the response type for the Query/Params RPC method. cosmos.gov.v1.QueryProposalResponse: type: object properties: proposal: type: object properties: id: type: string format: uint64 description: id defines the unique id of the proposal. messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- messages are the arbitrary messages to be executed if the proposal passes. status: description: status defines the proposal status. type: string enum: - PROPOSAL_STATUS_UNSPECIFIED - PROPOSAL_STATUS_DEPOSIT_PERIOD - PROPOSAL_STATUS_VOTING_PERIOD - PROPOSAL_STATUS_PASSED - PROPOSAL_STATUS_REJECTED - PROPOSAL_STATUS_FAILED default: PROPOSAL_STATUS_UNSPECIFIED final_tally_result: description: >- final_tally_result is the final tally result of the proposal. When querying a proposal via gRPC, this field is not populated until the proposal's voting period has ended. type: object properties: yes_count: type: string description: yes_count is the number of yes votes on a proposal. abstain_count: type: string description: abstain_count is the number of abstain votes on a proposal. no_count: type: string description: no_count is the number of no votes on a proposal. no_with_veto_count: type: string description: >- no_with_veto_count is the number of no with veto votes on a proposal. submit_time: type: string format: date-time description: submit_time is the time of proposal submission. deposit_end_time: type: string format: date-time description: deposit_end_time is the end time for deposition. total_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: total_deposit is the total deposit on the proposal. voting_start_time: type: string format: date-time description: voting_start_time is the starting time to vote on a proposal. voting_end_time: type: string format: date-time description: voting_end_time is the end time of voting on a proposal. metadata: type: string description: metadata is any arbitrary metadata attached to the proposal. title: type: string description: 'Since: cosmos-sdk 0.47' title: title is the title of the proposal summary: type: string description: 'Since: cosmos-sdk 0.47' title: summary is a short summary of the proposal proposer: type: string description: 'Since: cosmos-sdk 0.47' title: Proposer is the address of the proposal sumbitter description: Proposal defines the core field members of a governance proposal. description: >- QueryProposalResponse is the response type for the Query/Proposal RPC method. cosmos.gov.v1.QueryProposalsResponse: type: object properties: proposals: type: array items: type: object properties: id: type: string format: uint64 description: id defines the unique id of the proposal. messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- messages are the arbitrary messages to be executed if the proposal passes. status: description: status defines the proposal status. type: string enum: - PROPOSAL_STATUS_UNSPECIFIED - PROPOSAL_STATUS_DEPOSIT_PERIOD - PROPOSAL_STATUS_VOTING_PERIOD - PROPOSAL_STATUS_PASSED - PROPOSAL_STATUS_REJECTED - PROPOSAL_STATUS_FAILED default: PROPOSAL_STATUS_UNSPECIFIED final_tally_result: description: >- final_tally_result is the final tally result of the proposal. When querying a proposal via gRPC, this field is not populated until the proposal's voting period has ended. type: object properties: yes_count: type: string description: yes_count is the number of yes votes on a proposal. abstain_count: type: string description: abstain_count is the number of abstain votes on a proposal. no_count: type: string description: no_count is the number of no votes on a proposal. no_with_veto_count: type: string description: >- no_with_veto_count is the number of no with veto votes on a proposal. submit_time: type: string format: date-time description: submit_time is the time of proposal submission. deposit_end_time: type: string format: date-time description: deposit_end_time is the end time for deposition. total_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: total_deposit is the total deposit on the proposal. voting_start_time: type: string format: date-time description: voting_start_time is the starting time to vote on a proposal. voting_end_time: type: string format: date-time description: voting_end_time is the end time of voting on a proposal. metadata: type: string description: metadata is any arbitrary metadata attached to the proposal. title: type: string description: 'Since: cosmos-sdk 0.47' title: title is the title of the proposal summary: type: string description: 'Since: cosmos-sdk 0.47' title: summary is a short summary of the proposal proposer: type: string description: 'Since: cosmos-sdk 0.47' title: Proposer is the address of the proposal sumbitter description: Proposal defines the core field members of a governance proposal. description: proposals defines all the requested governance proposals. pagination: description: pagination defines the pagination in the response. type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- QueryProposalsResponse is the response type for the Query/Proposals RPC method. cosmos.gov.v1.QueryTallyResultResponse: type: object properties: tally: description: tally defines the requested tally. type: object properties: yes_count: type: string description: yes_count is the number of yes votes on a proposal. abstain_count: type: string description: abstain_count is the number of abstain votes on a proposal. no_count: type: string description: no_count is the number of no votes on a proposal. no_with_veto_count: type: string description: >- no_with_veto_count is the number of no with veto votes on a proposal. description: >- QueryTallyResultResponse is the response type for the Query/Tally RPC method. cosmos.gov.v1.QueryVoteResponse: type: object properties: vote: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. voter: type: string description: voter is the voter address of the proposal. options: type: array items: type: object properties: option: description: >- option defines the valid vote options, it must not contain duplicate vote options. type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED weight: type: string description: weight is the vote weight associated with the vote option. description: WeightedVoteOption defines a unit of vote for vote split. description: options is the weighted vote options. metadata: type: string description: metadata is any arbitrary metadata to attached to the vote. description: |- Vote defines a vote on a governance proposal. A Vote consists of a proposal ID, the voter, and the vote option. description: QueryVoteResponse is the response type for the Query/Vote RPC method. cosmos.gov.v1.QueryVotesResponse: type: object properties: votes: type: array items: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. voter: type: string description: voter is the voter address of the proposal. options: type: array items: type: object properties: option: description: >- option defines the valid vote options, it must not contain duplicate vote options. type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED weight: type: string description: weight is the vote weight associated with the vote option. description: WeightedVoteOption defines a unit of vote for vote split. description: options is the weighted vote options. metadata: type: string description: metadata is any arbitrary metadata to attached to the vote. description: |- Vote defines a vote on a governance proposal. A Vote consists of a proposal ID, the voter, and the vote option. description: votes defines the queried votes. pagination: description: pagination defines the pagination in the response. type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: QueryVotesResponse is the response type for the Query/Votes RPC method. cosmos.gov.v1.TallyParams: type: object properties: quorum: type: string description: |- Minimum percentage of total stake needed to vote for a result to be considered valid. threshold: type: string description: >- Minimum proportion of Yes votes for proposal to pass. Default value: 0.5. veto_threshold: type: string description: |- Minimum value of Veto votes to Total votes ratio for proposal to be vetoed. Default value: 1/3. description: TallyParams defines the params for tallying votes on governance proposals. cosmos.gov.v1.TallyResult: type: object properties: yes_count: type: string description: yes_count is the number of yes votes on a proposal. abstain_count: type: string description: abstain_count is the number of abstain votes on a proposal. no_count: type: string description: no_count is the number of no votes on a proposal. no_with_veto_count: type: string description: no_with_veto_count is the number of no with veto votes on a proposal. description: TallyResult defines a standard tally for a governance proposal. cosmos.gov.v1.Vote: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. voter: type: string description: voter is the voter address of the proposal. options: type: array items: type: object properties: option: description: >- option defines the valid vote options, it must not contain duplicate vote options. type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED weight: type: string description: weight is the vote weight associated with the vote option. description: WeightedVoteOption defines a unit of vote for vote split. description: options is the weighted vote options. metadata: type: string description: metadata is any arbitrary metadata to attached to the vote. description: |- Vote defines a vote on a governance proposal. A Vote consists of a proposal ID, the voter, and the vote option. cosmos.gov.v1.VoteOption: type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED description: >- VoteOption enumerates the valid vote options for a given governance proposal. - VOTE_OPTION_UNSPECIFIED: VOTE_OPTION_UNSPECIFIED defines a no-op vote option. - VOTE_OPTION_YES: VOTE_OPTION_YES defines a yes vote option. - VOTE_OPTION_ABSTAIN: VOTE_OPTION_ABSTAIN defines an abstain vote option. - VOTE_OPTION_NO: VOTE_OPTION_NO defines a no vote option. - VOTE_OPTION_NO_WITH_VETO: VOTE_OPTION_NO_WITH_VETO defines a no with veto vote option. cosmos.gov.v1.VotingParams: type: object properties: voting_period: type: string description: Duration of the voting period. description: VotingParams defines the params for voting on governance proposals. cosmos.gov.v1.WeightedVoteOption: type: object properties: option: description: >- option defines the valid vote options, it must not contain duplicate vote options. type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED weight: type: string description: weight is the vote weight associated with the vote option. description: WeightedVoteOption defines a unit of vote for vote split. cyber.graph.v1beta1.QueryGraphStatsResponse: type: object properties: cyberlinks: type: string format: uint64 particles: type: string format: uint64 cyber.resources.v1beta1.Params: type: object properties: max_slots: type: integer format: int64 halving_period_volt_blocks: type: integer format: int64 halving_period_ampere_blocks: type: integer format: int64 base_investmint_period_volt: type: integer format: int64 base_investmint_period_ampere: type: integer format: int64 min_investmint_period: type: integer format: int64 base_investmint_amount_volt: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. base_investmint_amount_ampere: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. cyber.resources.v1beta1.QueryInvestmintResponse: type: object properties: amount: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. cyber.resources.v1beta1.QueryParamsResponse: type: object properties: params: type: object properties: max_slots: type: integer format: int64 halving_period_volt_blocks: type: integer format: int64 halving_period_ampere_blocks: type: integer format: int64 base_investmint_period_volt: type: integer format: int64 base_investmint_period_ampere: type: integer format: int64 min_investmint_period: type: integer format: int64 base_investmint_amount_volt: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. base_investmint_amount_ampere: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. cosmos.base.node.v1beta1.ConfigResponse: type: object properties: minimum_gas_price: type: string description: ConfigResponse defines the response structure for the Config gRPC query. cosmos.upgrade.v1beta1.ModuleVersion: type: object properties: name: type: string title: name of the app module version: type: string format: uint64 title: consensus version of the app module description: |- ModuleVersion specifies a module and its consensus version. Since: cosmos-sdk 0.43 cosmos.upgrade.v1beta1.Plan: type: object properties: name: type: string description: >- Sets the name for the upgrade. This name will be used by the upgraded version of the software to apply any special "on-upgrade" commands during the first BeginBlock method after the upgrade is applied. It is also used to detect whether a software version can handle a given upgrade. If no upgrade handler with this name has been set in the software, it will be assumed that the software is out-of-date when the upgrade Time or Height is reached and the software will exit. time: type: string format: date-time description: >- Deprecated: Time based upgrades have been deprecated. Time based upgrade logic has been removed from the SDK. If this field is not empty, an error will be thrown. height: type: string format: int64 description: The height at which the upgrade must be performed. info: type: string title: |- Any application specific upgrade info to be included on-chain such as a git commit that validators could automatically upgrade to upgraded_client_state: type: object properties: type_url: type: string value: type: string format: byte description: >- Deprecated: UpgradedClientState field has been deprecated. IBC upgrade logic has been moved to the IBC module in the sub module 02-client. If this field is not empty, an error will be thrown. description: >- Plan specifies information about a planned upgrade and when it should occur. cosmos.upgrade.v1beta1.QueryAppliedPlanResponse: type: object properties: height: type: string format: int64 description: height is the block height at which the plan was applied. description: >- QueryAppliedPlanResponse is the response type for the Query/AppliedPlan RPC method. cosmos.upgrade.v1beta1.QueryAuthorityResponse: type: object properties: address: type: string description: 'Since: cosmos-sdk 0.46' title: QueryAuthorityResponse is the response type for Query/Authority cosmos.upgrade.v1beta1.QueryCurrentPlanResponse: type: object properties: plan: description: plan is the current upgrade plan. type: object properties: name: type: string description: >- Sets the name for the upgrade. This name will be used by the upgraded version of the software to apply any special "on-upgrade" commands during the first BeginBlock method after the upgrade is applied. It is also used to detect whether a software version can handle a given upgrade. If no upgrade handler with this name has been set in the software, it will be assumed that the software is out-of-date when the upgrade Time or Height is reached and the software will exit. time: type: string format: date-time description: >- Deprecated: Time based upgrades have been deprecated. Time based upgrade logic has been removed from the SDK. If this field is not empty, an error will be thrown. height: type: string format: int64 description: The height at which the upgrade must be performed. info: type: string title: >- Any application specific upgrade info to be included on-chain such as a git commit that validators could automatically upgrade to upgraded_client_state: type: object properties: type_url: type: string value: type: string format: byte description: >- Deprecated: UpgradedClientState field has been deprecated. IBC upgrade logic has been moved to the IBC module in the sub module 02-client. If this field is not empty, an error will be thrown. description: >- QueryCurrentPlanResponse is the response type for the Query/CurrentPlan RPC method. cosmos.upgrade.v1beta1.QueryModuleVersionsResponse: type: object properties: module_versions: type: array items: type: object properties: name: type: string title: name of the app module version: type: string format: uint64 title: consensus version of the app module description: |- ModuleVersion specifies a module and its consensus version. Since: cosmos-sdk 0.43 description: >- module_versions is a list of module names with their consensus versions. description: >- QueryModuleVersionsResponse is the response type for the Query/ModuleVersions RPC method. Since: cosmos-sdk 0.43 cosmos.upgrade.v1beta1.QueryUpgradedConsensusStateResponse: type: object properties: upgraded_consensus_state: type: string format: byte title: 'Since: cosmos-sdk 0.43' description: >- QueryUpgradedConsensusStateResponse is the response type for the Query/UpgradedConsensusState RPC method. ibc.applications.fee.v1.Fee: type: object properties: recv_fee: type: array items: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet receive fee ack_fee: type: array items: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet acknowledgement fee timeout_fee: type: array items: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet timeout fee title: Fee defines the ICS29 receive, acknowledgement and timeout fees ibc.applications.fee.v1.FeeEnabledChannel: type: object properties: port_id: type: string title: unique port identifier channel_id: type: string title: unique channel identifier title: >- FeeEnabledChannel contains the PortID & ChannelID for a fee enabled channel ibc.applications.fee.v1.IdentifiedPacketFees: type: object properties: packet_id: title: >- unique packet identifier comprised of the channel ID, port ID and sequence type: object properties: port_id: type: string title: channel port identifier channel_id: type: string title: channel unique identifier sequence: type: string format: uint64 title: packet sequence packet_fees: type: array items: type: object properties: fee: title: >- fee encapsulates the recv, ack and timeout fees associated with an IBC packet type: object properties: recv_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet receive fee ack_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet acknowledgement fee timeout_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet timeout fee refund_address: type: string title: the refund address for unspent fees relayers: type: array items: type: string title: optional list of relayers permitted to receive fees title: >- PacketFee contains ICS29 relayer fees, refund address and optional list of permitted relayers title: list of packet fees title: >- IdentifiedPacketFees contains a list of type PacketFee and associated PacketId ibc.applications.fee.v1.PacketFee: type: object properties: fee: title: >- fee encapsulates the recv, ack and timeout fees associated with an IBC packet type: object properties: recv_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet receive fee ack_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet acknowledgement fee timeout_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet timeout fee refund_address: type: string title: the refund address for unspent fees relayers: type: array items: type: string title: optional list of relayers permitted to receive fees title: >- PacketFee contains ICS29 relayer fees, refund address and optional list of permitted relayers ibc.applications.fee.v1.QueryCounterpartyPayeeResponse: type: object properties: counterparty_payee: type: string title: the counterparty payee address used to compensate forward relaying title: >- QueryCounterpartyPayeeResponse defines the response type for the CounterpartyPayee rpc ibc.applications.fee.v1.QueryFeeEnabledChannelResponse: type: object properties: fee_enabled: type: boolean title: boolean flag representing the fee enabled channel status title: >- QueryFeeEnabledChannelResponse defines the response type for the FeeEnabledChannel rpc ibc.applications.fee.v1.QueryFeeEnabledChannelsResponse: type: object properties: fee_enabled_channels: type: array items: type: object properties: port_id: type: string title: unique port identifier channel_id: type: string title: unique channel identifier title: >- FeeEnabledChannel contains the PortID & ChannelID for a fee enabled channel title: list of fee enabled channels title: >- QueryFeeEnabledChannelsResponse defines the response type for the FeeEnabledChannels rpc ibc.applications.fee.v1.QueryIncentivizedPacketResponse: type: object properties: incentivized_packet: type: object properties: packet_id: title: >- unique packet identifier comprised of the channel ID, port ID and sequence type: object properties: port_id: type: string title: channel port identifier channel_id: type: string title: channel unique identifier sequence: type: string format: uint64 title: packet sequence packet_fees: type: array items: type: object properties: fee: title: >- fee encapsulates the recv, ack and timeout fees associated with an IBC packet type: object properties: recv_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet receive fee ack_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet acknowledgement fee timeout_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet timeout fee refund_address: type: string title: the refund address for unspent fees relayers: type: array items: type: string title: optional list of relayers permitted to receive fees title: >- PacketFee contains ICS29 relayer fees, refund address and optional list of permitted relayers title: list of packet fees title: >- IdentifiedPacketFees contains a list of type PacketFee and associated PacketId title: >- QueryIncentivizedPacketsResponse defines the response type for the IncentivizedPacket rpc ibc.applications.fee.v1.QueryIncentivizedPacketsForChannelResponse: type: object properties: incentivized_packets: type: array items: type: object properties: packet_id: title: >- unique packet identifier comprised of the channel ID, port ID and sequence type: object properties: port_id: type: string title: channel port identifier channel_id: type: string title: channel unique identifier sequence: type: string format: uint64 title: packet sequence packet_fees: type: array items: type: object properties: fee: title: >- fee encapsulates the recv, ack and timeout fees associated with an IBC packet type: object properties: recv_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet receive fee ack_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet acknowledgement fee timeout_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet timeout fee refund_address: type: string title: the refund address for unspent fees relayers: type: array items: type: string title: optional list of relayers permitted to receive fees title: >- PacketFee contains ICS29 relayer fees, refund address and optional list of permitted relayers title: list of packet fees title: >- IdentifiedPacketFees contains a list of type PacketFee and associated PacketId title: Map of all incentivized_packets title: >- QueryIncentivizedPacketsResponse defines the response type for the incentivized packets RPC ibc.applications.fee.v1.QueryIncentivizedPacketsResponse: type: object properties: incentivized_packets: type: array items: type: object properties: packet_id: title: >- unique packet identifier comprised of the channel ID, port ID and sequence type: object properties: port_id: type: string title: channel port identifier channel_id: type: string title: channel unique identifier sequence: type: string format: uint64 title: packet sequence packet_fees: type: array items: type: object properties: fee: title: >- fee encapsulates the recv, ack and timeout fees associated with an IBC packet type: object properties: recv_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet receive fee ack_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet acknowledgement fee timeout_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the packet timeout fee refund_address: type: string title: the refund address for unspent fees relayers: type: array items: type: string title: optional list of relayers permitted to receive fees title: >- PacketFee contains ICS29 relayer fees, refund address and optional list of permitted relayers title: list of packet fees title: >- IdentifiedPacketFees contains a list of type PacketFee and associated PacketId title: list of identified fees for incentivized packets title: >- QueryIncentivizedPacketsResponse defines the response type for the IncentivizedPackets rpc ibc.applications.fee.v1.QueryPayeeResponse: type: object properties: payee_address: type: string title: the payee address to which packet fees are paid out title: QueryPayeeResponse defines the response type for the Payee rpc ibc.applications.fee.v1.QueryTotalAckFeesResponse: type: object properties: ack_fees: type: array items: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the total packet acknowledgement fees title: >- QueryTotalAckFeesResponse defines the response type for the TotalAckFees rpc ibc.applications.fee.v1.QueryTotalRecvFeesResponse: type: object properties: recv_fees: type: array items: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the total packet receive fees title: >- QueryTotalRecvFeesResponse defines the response type for the TotalRecvFees rpc ibc.applications.fee.v1.QueryTotalTimeoutFeesResponse: type: object properties: timeout_fees: type: array items: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: the total packet timeout fees title: >- QueryTotalTimeoutFeesResponse defines the response type for the TotalTimeoutFees rpc ibc.core.channel.v1.PacketId: type: object properties: port_id: type: string title: channel port identifier channel_id: type: string title: channel unique identifier sequence: type: string format: uint64 title: packet sequence title: |- PacketId is an identifer for a unique Packet Source chains refer to packets by source port/channel Destination chains refer to packets by destination port/channel cosmos.params.v1beta1.ParamChange: type: object properties: subspace: type: string key: type: string value: type: string description: |- ParamChange defines an individual parameter change, for use in ParameterChangeProposal. cosmos.params.v1beta1.QueryParamsResponse: type: object properties: param: description: param defines the queried parameter. type: object properties: subspace: type: string key: type: string value: type: string description: QueryParamsResponse is response type for the Query/Params RPC method. cosmos.params.v1beta1.QuerySubspacesResponse: type: object properties: subspaces: type: array items: type: object properties: subspace: type: string keys: type: array items: type: string description: >- Subspace defines a parameter subspace name and all the keys that exist for the subspace. Since: cosmos-sdk 0.46 description: |- QuerySubspacesResponse defines the response types for querying for all registered subspaces and all keys for a subspace. Since: cosmos-sdk 0.46 cosmos.params.v1beta1.Subspace: type: object properties: subspace: type: string keys: type: array items: type: string description: |- Subspace defines a parameter subspace name and all the keys that exist for the subspace. Since: cosmos-sdk 0.46 cyber.rank.v1beta1.PageRequest: type: object properties: page: type: integer format: int64 per_page: type: integer format: int64 cyber.rank.v1beta1.PageResponse: type: object properties: total: type: integer format: int64 cyber.rank.v1beta1.Params: type: object properties: calculation_period: type: string format: int64 damping_factor: type: string tolerance: type: string cyber.rank.v1beta1.QueryKarmaResponse: type: object properties: karma: type: string format: uint64 cyber.rank.v1beta1.QueryLinkExistResponse: type: object properties: exist: type: boolean cyber.rank.v1beta1.QueryNegentropyParticleResponse: type: object properties: entropy: type: string format: uint64 cyber.rank.v1beta1.QueryNegentropyResponse: type: object properties: negentropy: type: string format: uint64 cyber.rank.v1beta1.QueryParamsResponse: type: object properties: params: type: object properties: calculation_period: type: string format: int64 damping_factor: type: string tolerance: type: string cyber.rank.v1beta1.QueryRankResponse: type: object properties: rank: type: string format: uint64 cyber.rank.v1beta1.QuerySearchResponse: type: object properties: result: type: array items: type: object properties: particle: type: string rank: type: string format: uint64 pagination: type: object properties: total: type: integer format: int64 cyber.rank.v1beta1.RankedParticle: type: object properties: particle: type: string rank: type: string format: uint64 cosmos.base.v1beta1.DecCoin: type: object properties: denom: type: string amount: type: string description: |- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. cosmos.distribution.v1beta1.DelegationDelegatorReward: type: object properties: validator_address: type: string reward: type: array items: type: object properties: denom: type: string amount: type: string description: |- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. description: |- DelegationDelegatorReward represents the properties of a delegator's delegation reward. cosmos.distribution.v1beta1.Params: type: object properties: community_tax: type: string base_proposer_reward: type: string description: >- Deprecated: The base_proposer_reward field is deprecated and is no longer used in the x/distribution module's reward mechanism. bonus_proposer_reward: type: string description: >- Deprecated: The bonus_proposer_reward field is deprecated and is no longer used in the x/distribution module's reward mechanism. withdraw_addr_enabled: type: boolean description: Params defines the set of params for the distribution module. cosmos.distribution.v1beta1.QueryCommunityPoolResponse: type: object properties: pool: type: array items: type: object properties: denom: type: string amount: type: string description: |- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. description: pool defines community pool's coins. description: >- QueryCommunityPoolResponse is the response type for the Query/CommunityPool RPC method. cosmos.distribution.v1beta1.QueryDelegationRewardsResponse: type: object properties: rewards: type: array items: type: object properties: denom: type: string amount: type: string description: |- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. description: rewards defines the rewards accrued by a delegation. description: |- QueryDelegationRewardsResponse is the response type for the Query/DelegationRewards RPC method. cosmos.distribution.v1beta1.QueryDelegationTotalRewardsResponse: type: object properties: rewards: type: array items: type: object properties: validator_address: type: string reward: type: array items: type: object properties: denom: type: string amount: type: string description: >- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. description: |- DelegationDelegatorReward represents the properties of a delegator's delegation reward. description: rewards defines all the rewards accrued by a delegator. total: type: array items: type: object properties: denom: type: string amount: type: string description: |- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. description: total defines the sum of all the rewards. description: |- QueryDelegationTotalRewardsResponse is the response type for the Query/DelegationTotalRewards RPC method. cosmos.distribution.v1beta1.QueryDelegatorValidatorsResponse: type: object properties: validators: type: array items: type: string description: validators defines the validators a delegator is delegating for. description: |- QueryDelegatorValidatorsResponse is the response type for the Query/DelegatorValidators RPC method. cosmos.distribution.v1beta1.QueryDelegatorWithdrawAddressResponse: type: object properties: withdraw_address: type: string description: withdraw_address defines the delegator address to query for. description: |- QueryDelegatorWithdrawAddressResponse is the response type for the Query/DelegatorWithdrawAddress RPC method. cosmos.distribution.v1beta1.QueryParamsResponse: type: object properties: params: description: params defines the parameters of the module. type: object properties: community_tax: type: string base_proposer_reward: type: string description: >- Deprecated: The base_proposer_reward field is deprecated and is no longer used in the x/distribution module's reward mechanism. bonus_proposer_reward: type: string description: >- Deprecated: The bonus_proposer_reward field is deprecated and is no longer used in the x/distribution module's reward mechanism. withdraw_addr_enabled: type: boolean description: QueryParamsResponse is the response type for the Query/Params RPC method. cosmos.distribution.v1beta1.QueryValidatorCommissionResponse: type: object properties: commission: description: commission defines the commission the validator received. type: object properties: commission: type: array items: type: object properties: denom: type: string amount: type: string description: >- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. title: |- QueryValidatorCommissionResponse is the response type for the Query/ValidatorCommission RPC method cosmos.distribution.v1beta1.QueryValidatorDistributionInfoResponse: type: object properties: operator_address: type: string description: operator_address defines the validator operator address. self_bond_rewards: type: array items: type: object properties: denom: type: string amount: type: string description: |- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. description: self_bond_rewards defines the self delegations rewards. commission: type: array items: type: object properties: denom: type: string amount: type: string description: |- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. description: commission defines the commission the validator received. description: >- QueryValidatorDistributionInfoResponse is the response type for the Query/ValidatorDistributionInfo RPC method. cosmos.distribution.v1beta1.QueryValidatorOutstandingRewardsResponse: type: object properties: rewards: type: object properties: rewards: type: array items: type: object properties: denom: type: string amount: type: string description: >- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. description: >- ValidatorOutstandingRewards represents outstanding (un-withdrawn) rewards for a validator inexpensive to track, allows simple sanity checks. description: |- QueryValidatorOutstandingRewardsResponse is the response type for the Query/ValidatorOutstandingRewards RPC method. cosmos.distribution.v1beta1.QueryValidatorSlashesResponse: type: object properties: slashes: type: array items: type: object properties: validator_period: type: string format: uint64 fraction: type: string description: |- ValidatorSlashEvent represents a validator slash event. Height is implicit within the store key. This is needed to calculate appropriate amount of staking tokens for delegations which are withdrawn after a slash has occurred. description: slashes defines the slashes the validator received. pagination: description: pagination defines the pagination in the response. type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- QueryValidatorSlashesResponse is the response type for the Query/ValidatorSlashes RPC method. cosmos.distribution.v1beta1.ValidatorAccumulatedCommission: type: object properties: commission: type: array items: type: object properties: denom: type: string amount: type: string description: |- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. description: |- ValidatorAccumulatedCommission represents accumulated commission for a validator kept as a running counter, can be withdrawn at any time. cosmos.distribution.v1beta1.ValidatorOutstandingRewards: type: object properties: rewards: type: array items: type: object properties: denom: type: string amount: type: string description: |- DecCoin defines a token with a denomination and a decimal amount. NOTE: The amount field is an Dec which implements the custom method signatures required by gogoproto. description: |- ValidatorOutstandingRewards represents outstanding (un-withdrawn) rewards for a validator inexpensive to track, allows simple sanity checks. cosmos.distribution.v1beta1.ValidatorSlashEvent: type: object properties: validator_period: type: string format: uint64 fraction: type: string description: |- ValidatorSlashEvent represents a validator slash event. Height is implicit within the store key. This is needed to calculate appropriate amount of staking tokens for delegations which are withdrawn after a slash has occurred. cosmos.bank.v1beta1.DenomOwner: type: object properties: address: type: string description: address defines the address that owns a particular denomination. balance: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: |- DenomOwner defines structure representing an account that owns or holds a particular denominated token. It contains the account address and account balance of the denominated token. Since: cosmos-sdk 0.46 cosmos.bank.v1beta1.DenomUnit: type: object properties: denom: type: string description: denom represents the string name of the given denom unit (e.g uatom). exponent: type: integer format: int64 description: >- exponent represents power of 10 exponent that one must raise the base_denom to in order to equal the given DenomUnit's denom 1 denom = 10^exponent base_denom (e.g. with a base_denom of uatom, one can create a DenomUnit of 'atom' with exponent = 6, thus: 1 atom = 10^6 uatom). aliases: type: array items: type: string title: aliases is a list of string aliases for the given denom description: |- DenomUnit represents a struct that describes a given denomination unit of the basic token. cosmos.bank.v1beta1.Metadata: type: object properties: description: type: string denom_units: type: array items: type: object properties: denom: type: string description: >- denom represents the string name of the given denom unit (e.g uatom). exponent: type: integer format: int64 description: >- exponent represents power of 10 exponent that one must raise the base_denom to in order to equal the given DenomUnit's denom 1 denom = 10^exponent base_denom (e.g. with a base_denom of uatom, one can create a DenomUnit of 'atom' with exponent = 6, thus: 1 atom = 10^6 uatom). aliases: type: array items: type: string title: aliases is a list of string aliases for the given denom description: |- DenomUnit represents a struct that describes a given denomination unit of the basic token. title: denom_units represents the list of DenomUnit's for a given coin base: type: string description: >- base represents the base denom (should be the DenomUnit with exponent = 0). display: type: string description: |- display indicates the suggested denom that should be displayed in clients. name: type: string description: 'Since: cosmos-sdk 0.43' title: 'name defines the name of the token (eg: Cosmos Atom)' symbol: type: string description: >- symbol is the token symbol usually shown on exchanges (eg: ATOM). This can be the same as the display. Since: cosmos-sdk 0.43 uri: type: string description: >- URI to a document (on or off-chain) that contains additional information. Optional. Since: cosmos-sdk 0.46 uri_hash: type: string description: >- URIHash is a sha256 hash of a document pointed by URI. It's used to verify that the document didn't change. Optional. Since: cosmos-sdk 0.46 description: |- Metadata represents a struct that describes a basic token. cosmos.bank.v1beta1.Params: type: object properties: send_enabled: type: array items: type: object properties: denom: type: string enabled: type: boolean description: >- SendEnabled maps coin denom to a send_enabled status (whether a denom is sendable). description: >- Deprecated: Use of SendEnabled in params is deprecated. For genesis, use the newly added send_enabled field in the genesis object. Storage, lookup, and manipulation of this information is now in the keeper. As of cosmos-sdk 0.47, this only exists for backwards compatibility of genesis files. default_send_enabled: type: boolean description: Params defines the parameters for the bank module. cosmos.bank.v1beta1.QueryAllBalancesResponse: type: object properties: balances: type: array items: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: balances is the balances of all the coins. pagination: description: pagination defines the pagination in the response. type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- QueryAllBalancesResponse is the response type for the Query/AllBalances RPC method. cosmos.bank.v1beta1.QueryBalanceResponse: type: object properties: balance: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- QueryBalanceResponse is the response type for the Query/Balance RPC method. cosmos.bank.v1beta1.QueryDenomMetadataResponse: type: object properties: metadata: type: object properties: description: type: string denom_units: type: array items: type: object properties: denom: type: string description: >- denom represents the string name of the given denom unit (e.g uatom). exponent: type: integer format: int64 description: >- exponent represents power of 10 exponent that one must raise the base_denom to in order to equal the given DenomUnit's denom 1 denom = 10^exponent base_denom (e.g. with a base_denom of uatom, one can create a DenomUnit of 'atom' with exponent = 6, thus: 1 atom = 10^6 uatom). aliases: type: array items: type: string title: aliases is a list of string aliases for the given denom description: |- DenomUnit represents a struct that describes a given denomination unit of the basic token. title: denom_units represents the list of DenomUnit's for a given coin base: type: string description: >- base represents the base denom (should be the DenomUnit with exponent = 0). display: type: string description: |- display indicates the suggested denom that should be displayed in clients. name: type: string description: 'Since: cosmos-sdk 0.43' title: 'name defines the name of the token (eg: Cosmos Atom)' symbol: type: string description: >- symbol is the token symbol usually shown on exchanges (eg: ATOM). This can be the same as the display. Since: cosmos-sdk 0.43 uri: type: string description: >- URI to a document (on or off-chain) that contains additional information. Optional. Since: cosmos-sdk 0.46 uri_hash: type: string description: >- URIHash is a sha256 hash of a document pointed by URI. It's used to verify that the document didn't change. Optional. Since: cosmos-sdk 0.46 description: |- Metadata represents a struct that describes a basic token. description: >- QueryDenomMetadataResponse is the response type for the Query/DenomMetadata RPC method. cosmos.bank.v1beta1.QueryDenomOwnersResponse: type: object properties: denom_owners: type: array items: type: object properties: address: type: string description: address defines the address that owns a particular denomination. balance: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- DenomOwner defines structure representing an account that owns or holds a particular denominated token. It contains the account address and account balance of the denominated token. Since: cosmos-sdk 0.46 pagination: description: pagination defines the pagination in the response. type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- QueryDenomOwnersResponse defines the RPC response of a DenomOwners RPC query. Since: cosmos-sdk 0.46 cosmos.bank.v1beta1.QueryDenomsMetadataResponse: type: object properties: metadatas: type: array items: type: object properties: description: type: string denom_units: type: array items: type: object properties: denom: type: string description: >- denom represents the string name of the given denom unit (e.g uatom). exponent: type: integer format: int64 description: >- exponent represents power of 10 exponent that one must raise the base_denom to in order to equal the given DenomUnit's denom 1 denom = 10^exponent base_denom (e.g. with a base_denom of uatom, one can create a DenomUnit of 'atom' with exponent = 6, thus: 1 atom = 10^6 uatom). aliases: type: array items: type: string title: aliases is a list of string aliases for the given denom description: |- DenomUnit represents a struct that describes a given denomination unit of the basic token. title: denom_units represents the list of DenomUnit's for a given coin base: type: string description: >- base represents the base denom (should be the DenomUnit with exponent = 0). display: type: string description: |- display indicates the suggested denom that should be displayed in clients. name: type: string description: 'Since: cosmos-sdk 0.43' title: 'name defines the name of the token (eg: Cosmos Atom)' symbol: type: string description: >- symbol is the token symbol usually shown on exchanges (eg: ATOM). This can be the same as the display. Since: cosmos-sdk 0.43 uri: type: string description: >- URI to a document (on or off-chain) that contains additional information. Optional. Since: cosmos-sdk 0.46 uri_hash: type: string description: >- URIHash is a sha256 hash of a document pointed by URI. It's used to verify that the document didn't change. Optional. Since: cosmos-sdk 0.46 description: |- Metadata represents a struct that describes a basic token. description: >- metadata provides the client information for all the registered tokens. pagination: description: pagination defines the pagination in the response. type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- QueryDenomsMetadataResponse is the response type for the Query/DenomsMetadata RPC method. cosmos.bank.v1beta1.QueryParamsResponse: type: object properties: params: type: object properties: send_enabled: type: array items: type: object properties: denom: type: string enabled: type: boolean description: >- SendEnabled maps coin denom to a send_enabled status (whether a denom is sendable). description: >- Deprecated: Use of SendEnabled in params is deprecated. For genesis, use the newly added send_enabled field in the genesis object. Storage, lookup, and manipulation of this information is now in the keeper. As of cosmos-sdk 0.47, this only exists for backwards compatibility of genesis files. default_send_enabled: type: boolean description: Params defines the parameters for the bank module. description: >- QueryParamsResponse defines the response type for querying x/bank parameters. cosmos.bank.v1beta1.QuerySendEnabledResponse: type: object properties: send_enabled: type: array items: type: object properties: denom: type: string enabled: type: boolean description: >- SendEnabled maps coin denom to a send_enabled status (whether a denom is sendable). pagination: description: |- pagination defines the pagination in the response. This field is only populated if the denoms field in the request is empty. type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- QuerySendEnabledResponse defines the RPC response of a SendEnable query. Since: cosmos-sdk 0.47 cosmos.bank.v1beta1.QuerySpendableBalanceByDenomResponse: type: object properties: balance: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- QuerySpendableBalanceByDenomResponse defines the gRPC response structure for querying an account's spendable balance for a specific denom. Since: cosmos-sdk 0.47 cosmos.bank.v1beta1.QuerySpendableBalancesResponse: type: object properties: balances: type: array items: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: balances is the spendable balances of all the coins. pagination: description: pagination defines the pagination in the response. type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: >- QuerySpendableBalancesResponse defines the gRPC response structure for querying an account's spendable balances. Since: cosmos-sdk 0.46 cosmos.bank.v1beta1.QuerySupplyOfResponse: type: object properties: amount: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- QuerySupplyOfResponse is the response type for the Query/SupplyOf RPC method. cosmos.bank.v1beta1.QueryTotalSupplyResponse: type: object properties: supply: type: array items: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: supply is the supply of the coins pagination: description: |- pagination defines the pagination in the response. Since: cosmos-sdk 0.43 type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise title: >- QueryTotalSupplyResponse is the response type for the Query/TotalSupply RPC method cosmos.bank.v1beta1.SendEnabled: type: object properties: denom: type: string enabled: type: boolean description: |- SendEnabled maps coin denom to a send_enabled status (whether a denom is sendable). ibc.core.client.v1.Height: type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: |- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: >- Height is a monotonically increasing data type that can be compared against another Height for the purposes of updating and freezing clients ibc.core.client.v1.IdentifiedClientState: type: object properties: client_id: type: string title: client identifier client_state: type: object properties: type_url: type: string value: type: string format: byte title: client state description: |- IdentifiedClientState defines a client state with an additional client identifier field. ibc.core.commitment.v1.MerklePrefix: type: object properties: key_prefix: type: string format: byte title: |- MerklePrefix is merkle path prefixed to the key. The constructed key from the Path and the key will be append(Path.KeyPath, append(Path.KeyPrefix, key...)) ibc.core.connection.v1.ConnectionEnd: type: object properties: client_id: type: string description: client associated with this connection. versions: type: array items: type: object properties: identifier: type: string title: unique version identifier features: type: array items: type: string title: list of features compatible with the specified identifier description: >- Version defines the versioning scheme used to negotiate the IBC verison in the connection handshake. description: >- IBC version which can be utilised to determine encodings or protocols for channels or packets utilising this connection. state: description: current state of the connection end. type: string enum: - STATE_UNINITIALIZED_UNSPECIFIED - STATE_INIT - STATE_TRYOPEN - STATE_OPEN default: STATE_UNINITIALIZED_UNSPECIFIED counterparty: description: counterparty chain associated with this connection. type: object properties: client_id: type: string description: >- identifies the client on the counterparty chain associated with a given connection. connection_id: type: string description: >- identifies the connection end on the counterparty chain associated with a given connection. prefix: description: commitment merkle prefix of the counterparty chain. type: object properties: key_prefix: type: string format: byte title: >- MerklePrefix is merkle path prefixed to the key. The constructed key from the Path and the key will be append(Path.KeyPath, append(Path.KeyPrefix, key...)) delay_period: type: string format: uint64 description: >- delay period that must pass before a consensus state can be used for packet-verification NOTE: delay period logic is only implemented by some clients. description: |- ConnectionEnd defines a stateful object on a chain connected to another separate one. NOTE: there must only be 2 defined ConnectionEnds to establish a connection between two chains. ibc.core.connection.v1.Counterparty: type: object properties: client_id: type: string description: >- identifies the client on the counterparty chain associated with a given connection. connection_id: type: string description: >- identifies the connection end on the counterparty chain associated with a given connection. prefix: description: commitment merkle prefix of the counterparty chain. type: object properties: key_prefix: type: string format: byte title: >- MerklePrefix is merkle path prefixed to the key. The constructed key from the Path and the key will be append(Path.KeyPath, append(Path.KeyPrefix, key...)) description: >- Counterparty defines the counterparty chain associated with a connection end. ibc.core.connection.v1.IdentifiedConnection: type: object properties: id: type: string description: connection identifier. client_id: type: string description: client associated with this connection. versions: type: array items: type: object properties: identifier: type: string title: unique version identifier features: type: array items: type: string title: list of features compatible with the specified identifier description: >- Version defines the versioning scheme used to negotiate the IBC verison in the connection handshake. title: >- IBC version which can be utilised to determine encodings or protocols for channels or packets utilising this connection state: description: current state of the connection end. type: string enum: - STATE_UNINITIALIZED_UNSPECIFIED - STATE_INIT - STATE_TRYOPEN - STATE_OPEN default: STATE_UNINITIALIZED_UNSPECIFIED counterparty: description: counterparty chain associated with this connection. type: object properties: client_id: type: string description: >- identifies the client on the counterparty chain associated with a given connection. connection_id: type: string description: >- identifies the connection end on the counterparty chain associated with a given connection. prefix: description: commitment merkle prefix of the counterparty chain. type: object properties: key_prefix: type: string format: byte title: >- MerklePrefix is merkle path prefixed to the key. The constructed key from the Path and the key will be append(Path.KeyPath, append(Path.KeyPrefix, key...)) delay_period: type: string format: uint64 description: delay period associated with this connection. description: |- IdentifiedConnection defines a connection with additional connection identifier field. ibc.core.connection.v1.Params: type: object properties: max_expected_time_per_block: type: string format: uint64 description: >- maximum expected time per block (in nanoseconds), used to enforce block delay. This parameter should reflect the largest amount of time that the chain might reasonably take to produce the next block under normal operating conditions. A safe choice is 3-5x the expected time per block. description: Params defines the set of Connection parameters. ibc.core.connection.v1.QueryClientConnectionsResponse: type: object properties: connection_paths: type: array items: type: string description: slice of all the connection paths associated with a client. proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was generated type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryClientConnectionsResponse is the response type for the Query/ClientConnections RPC method ibc.core.connection.v1.QueryConnectionClientStateResponse: type: object properties: identified_client_state: title: client state associated with the channel type: object properties: client_id: type: string title: client identifier client_state: type: object properties: type_url: type: string value: type: string format: byte title: client state description: |- IdentifiedClientState defines a client state with an additional client identifier field. proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryConnectionClientStateResponse is the response type for the Query/ConnectionClientState RPC method ibc.core.connection.v1.QueryConnectionConsensusStateResponse: type: object properties: consensus_state: type: object properties: type_url: type: string value: type: string format: byte title: consensus state associated with the channel client_id: type: string title: client ID associated with the consensus state proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryConnectionConsensusStateResponse is the response type for the Query/ConnectionConsensusState RPC method ibc.core.connection.v1.QueryConnectionParamsResponse: type: object properties: params: description: params defines the parameters of the module. type: object properties: max_expected_time_per_block: type: string format: uint64 description: >- maximum expected time per block (in nanoseconds), used to enforce block delay. This parameter should reflect the largest amount of time that the chain might reasonably take to produce the next block under normal operating conditions. A safe choice is 3-5x the expected time per block. description: >- QueryConnectionParamsResponse is the response type for the Query/ConnectionParams RPC method. ibc.core.connection.v1.QueryConnectionResponse: type: object properties: connection: title: connection associated with the request identifier type: object properties: client_id: type: string description: client associated with this connection. versions: type: array items: type: object properties: identifier: type: string title: unique version identifier features: type: array items: type: string title: list of features compatible with the specified identifier description: >- Version defines the versioning scheme used to negotiate the IBC verison in the connection handshake. description: >- IBC version which can be utilised to determine encodings or protocols for channels or packets utilising this connection. state: description: current state of the connection end. type: string enum: - STATE_UNINITIALIZED_UNSPECIFIED - STATE_INIT - STATE_TRYOPEN - STATE_OPEN default: STATE_UNINITIALIZED_UNSPECIFIED counterparty: description: counterparty chain associated with this connection. type: object properties: client_id: type: string description: >- identifies the client on the counterparty chain associated with a given connection. connection_id: type: string description: >- identifies the connection end on the counterparty chain associated with a given connection. prefix: description: commitment merkle prefix of the counterparty chain. type: object properties: key_prefix: type: string format: byte title: >- MerklePrefix is merkle path prefixed to the key. The constructed key from the Path and the key will be append(Path.KeyPath, append(Path.KeyPrefix, key...)) delay_period: type: string format: uint64 description: >- delay period that must pass before a consensus state can be used for packet-verification NOTE: delay period logic is only implemented by some clients. description: >- ConnectionEnd defines a stateful object on a chain connected to another separate one. NOTE: there must only be 2 defined ConnectionEnds to establish a connection between two chains. proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset description: >- QueryConnectionResponse is the response type for the Query/Connection RPC method. Besides the connection end, it includes a proof and the height from which the proof was retrieved. ibc.core.connection.v1.QueryConnectionsResponse: type: object properties: connections: type: array items: type: object properties: id: type: string description: connection identifier. client_id: type: string description: client associated with this connection. versions: type: array items: type: object properties: identifier: type: string title: unique version identifier features: type: array items: type: string title: list of features compatible with the specified identifier description: >- Version defines the versioning scheme used to negotiate the IBC verison in the connection handshake. title: >- IBC version which can be utilised to determine encodings or protocols for channels or packets utilising this connection state: description: current state of the connection end. type: string enum: - STATE_UNINITIALIZED_UNSPECIFIED - STATE_INIT - STATE_TRYOPEN - STATE_OPEN default: STATE_UNINITIALIZED_UNSPECIFIED counterparty: description: counterparty chain associated with this connection. type: object properties: client_id: type: string description: >- identifies the client on the counterparty chain associated with a given connection. connection_id: type: string description: >- identifies the connection end on the counterparty chain associated with a given connection. prefix: description: commitment merkle prefix of the counterparty chain. type: object properties: key_prefix: type: string format: byte title: >- MerklePrefix is merkle path prefixed to the key. The constructed key from the Path and the key will be append(Path.KeyPath, append(Path.KeyPrefix, key...)) delay_period: type: string format: uint64 description: delay period associated with this connection. description: |- IdentifiedConnection defines a connection with additional connection identifier field. description: list of stored connections of the chain. pagination: title: pagination response type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } height: title: query block height type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset description: >- QueryConnectionsResponse is the response type for the Query/Connections RPC method. ibc.core.connection.v1.State: type: string enum: - STATE_UNINITIALIZED_UNSPECIFIED - STATE_INIT - STATE_TRYOPEN - STATE_OPEN default: STATE_UNINITIALIZED_UNSPECIFIED description: |- State defines if a connection is in one of the following states: INIT, TRYOPEN, OPEN or UNINITIALIZED. - STATE_UNINITIALIZED_UNSPECIFIED: Default State - STATE_INIT: A connection end has just started the opening handshake. - STATE_TRYOPEN: A connection end has acknowledged the handshake step on the counterparty chain. - STATE_OPEN: A connection end has completed the handshake. ibc.core.connection.v1.Version: type: object properties: identifier: type: string title: unique version identifier features: type: array items: type: string title: list of features compatible with the specified identifier description: |- Version defines the versioning scheme used to negotiate the IBC verison in the connection handshake. cyber.grid.v1beta1.Params: type: object properties: max_routes: type: integer format: int64 cyber.grid.v1beta1.QueryParamsResponse: type: object properties: params: type: object properties: max_routes: type: integer format: int64 cyber.grid.v1beta1.QueryRouteResponse: type: object properties: route: type: object properties: source: type: string destination: type: string name: type: string value: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. cyber.grid.v1beta1.QueryRoutedEnergyResponse: type: object properties: value: type: array items: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. cyber.grid.v1beta1.QueryRoutesResponse: type: object properties: routes: type: array items: type: object properties: source: type: string destination: type: string name: type: string value: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } cyber.grid.v1beta1.Route: type: object properties: source: type: string destination: type: string name: type: string value: type: array items: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. cyber.dmn.v1beta1.Load: type: object properties: input: type: string gas_price: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. cyber.dmn.v1beta1.Params: type: object properties: max_slots: type: integer format: int64 max_gas: type: integer format: int64 fee_ttl: type: integer format: int64 cyber.dmn.v1beta1.QueryParamsResponse: type: object properties: params: type: object properties: max_slots: type: integer format: int64 max_gas: type: integer format: int64 fee_ttl: type: integer format: int64 cyber.dmn.v1beta1.QueryThoughtResponse: type: object properties: thought: type: object properties: program: type: string trigger: type: object properties: period: type: string format: uint64 block: type: string format: uint64 load: type: object properties: input: type: string gas_price: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. name: type: string particle: type: string cyber.dmn.v1beta1.QueryThoughtStatsResponse: type: object properties: thought_stats: type: object properties: program: type: string name: type: string calls: type: string format: uint64 fees: type: string format: uint64 gas: type: string format: uint64 last_block: type: string format: uint64 cyber.dmn.v1beta1.QueryThoughtsFeesResponse: type: object properties: fees: type: array items: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. cyber.dmn.v1beta1.QueryThoughtsResponse: type: object properties: thoughts: type: array items: type: object properties: program: type: string trigger: type: object properties: period: type: string format: uint64 block: type: string format: uint64 load: type: object properties: input: type: string gas_price: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. name: type: string particle: type: string cyber.dmn.v1beta1.QueryThoughtsStatsResponse: type: object properties: thoughts_stats: type: array items: type: object properties: program: type: string name: type: string calls: type: string format: uint64 fees: type: string format: uint64 gas: type: string format: uint64 last_block: type: string format: uint64 cyber.dmn.v1beta1.Thought: type: object properties: program: type: string trigger: type: object properties: period: type: string format: uint64 block: type: string format: uint64 load: type: object properties: input: type: string gas_price: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. name: type: string particle: type: string cyber.dmn.v1beta1.ThoughtStats: type: object properties: program: type: string name: type: string calls: type: string format: uint64 fees: type: string format: uint64 gas: type: string format: uint64 last_block: type: string format: uint64 cyber.dmn.v1beta1.Trigger: type: object properties: period: type: string format: uint64 block: type: string format: uint64 cosmos.staking.v1beta1.BondStatus: type: string enum: - BOND_STATUS_UNSPECIFIED - BOND_STATUS_UNBONDED - BOND_STATUS_UNBONDING - BOND_STATUS_BONDED default: BOND_STATUS_UNSPECIFIED description: |- BondStatus is the status of a validator. - BOND_STATUS_UNSPECIFIED: UNSPECIFIED defines an invalid validator status. - BOND_STATUS_UNBONDED: UNBONDED defines a validator that is not bonded. - BOND_STATUS_UNBONDING: UNBONDING defines a validator that is unbonding. - BOND_STATUS_BONDED: BONDED defines a validator that is bonded. cosmos.staking.v1beta1.Commission: type: object properties: commission_rates: description: >- commission_rates defines the initial commission rates to be used for creating a validator. type: object properties: rate: type: string description: rate is the commission rate charged to delegators, as a fraction. max_rate: type: string description: >- max_rate defines the maximum commission rate which validator can ever charge, as a fraction. max_change_rate: type: string description: >- max_change_rate defines the maximum daily increase of the validator commission, as a fraction. update_time: type: string format: date-time description: update_time is the last time the commission rate was changed. description: Commission defines commission parameters for a given validator. cosmos.staking.v1beta1.CommissionRates: type: object properties: rate: type: string description: rate is the commission rate charged to delegators, as a fraction. max_rate: type: string description: >- max_rate defines the maximum commission rate which validator can ever charge, as a fraction. max_change_rate: type: string description: >- max_change_rate defines the maximum daily increase of the validator commission, as a fraction. description: >- CommissionRates defines the initial commission rates to be used for creating a validator. cosmos.staking.v1beta1.Delegation: type: object properties: delegator_address: type: string description: delegator_address is the bech32-encoded address of the delegator. validator_address: type: string description: validator_address is the bech32-encoded address of the validator. shares: type: string description: shares define the delegation shares received. description: |- Delegation represents the bond with tokens held by an account. It is owned by one delegator, and is associated with the voting power of one validator. cosmos.staking.v1beta1.DelegationResponse: type: object properties: delegation: type: object properties: delegator_address: type: string description: delegator_address is the bech32-encoded address of the delegator. validator_address: type: string description: validator_address is the bech32-encoded address of the validator. shares: type: string description: shares define the delegation shares received. description: |- Delegation represents the bond with tokens held by an account. It is owned by one delegator, and is associated with the voting power of one validator. balance: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: |- DelegationResponse is equivalent to Delegation except that it contains a balance in addition to shares which is more suitable for client responses. cosmos.staking.v1beta1.Description: type: object properties: moniker: type: string description: moniker defines a human-readable name for the validator. identity: type: string description: >- identity defines an optional identity signature (ex. UPort or Keybase). website: type: string description: website defines an optional website link. security_contact: type: string description: security_contact defines an optional email for security contact. details: type: string description: details define other optional details. description: Description defines a validator description. cosmos.staking.v1beta1.HistoricalInfo: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. valset: type: array items: type: object properties: operator_address: type: string description: >- operator_address defines the address of the validator's operator; bech encoded in JSON. consensus_pubkey: type: object properties: type_url: type: string value: type: string format: byte description: >- consensus_pubkey is the consensus public key of the validator, as a Protobuf Any. jailed: type: boolean description: >- jailed defined whether the validator has been jailed from bonded status or not. status: description: status is the validator status (bonded/unbonding/unbonded). type: string enum: - BOND_STATUS_UNSPECIFIED - BOND_STATUS_UNBONDED - BOND_STATUS_UNBONDING - BOND_STATUS_BONDED default: BOND_STATUS_UNSPECIFIED tokens: type: string description: tokens define the delegated tokens (incl. self-delegation). delegator_shares: type: string description: >- delegator_shares defines total shares issued to a validator's delegators. description: description: description defines the description terms for the validator. type: object properties: moniker: type: string description: moniker defines a human-readable name for the validator. identity: type: string description: >- identity defines an optional identity signature (ex. UPort or Keybase). website: type: string description: website defines an optional website link. security_contact: type: string description: >- security_contact defines an optional email for security contact. details: type: string description: details define other optional details. unbonding_height: type: string format: int64 description: >- unbonding_height defines, if unbonding, the height at which this validator has begun unbonding. unbonding_time: type: string format: date-time description: >- unbonding_time defines, if unbonding, the min time for the validator to complete unbonding. commission: description: commission defines the commission parameters. type: object properties: commission_rates: description: >- commission_rates defines the initial commission rates to be used for creating a validator. type: object properties: rate: type: string description: >- rate is the commission rate charged to delegators, as a fraction. max_rate: type: string description: >- max_rate defines the maximum commission rate which validator can ever charge, as a fraction. max_change_rate: type: string description: >- max_change_rate defines the maximum daily increase of the validator commission, as a fraction. update_time: type: string format: date-time description: >- update_time is the last time the commission rate was changed. min_self_delegation: type: string description: >- min_self_delegation is the validator's self declared minimum self delegation. Since: cosmos-sdk 0.46 unbonding_on_hold_ref_count: type: string format: int64 title: >- strictly positive if this validator's unbonding has been stopped by external modules unbonding_ids: type: array items: type: string format: uint64 title: >- list of unbonding ids, each uniquely identifing an unbonding of this validator description: >- Validator defines a validator, together with the total amount of the Validator's bond shares and their exchange rate to coins. Slashing results in a decrease in the exchange rate, allowing correct calculation of future undelegations without iterating over delegators. When coins are delegated to this validator, the validator is credited with a delegation whose number of bond shares is based on the amount of coins delegated divided by the current exchange rate. Voting power can be calculated as total bonded shares multiplied by exchange rate. description: >- HistoricalInfo contains header and validator information for a given block. It is stored as part of staking module's state, which persists the `n` most recent HistoricalInfo (`n` is set by the staking module's `historical_entries` parameter). cosmos.staking.v1beta1.Params: type: object properties: unbonding_time: type: string description: unbonding_time is the time duration of unbonding. max_validators: type: integer format: int64 description: max_validators is the maximum number of validators. max_entries: type: integer format: int64 description: >- max_entries is the max entries for either unbonding delegation or redelegation (per pair/trio). historical_entries: type: integer format: int64 description: historical_entries is the number of historical entries to persist. bond_denom: type: string description: bond_denom defines the bondable coin denomination. min_commission_rate: type: string title: >- min_commission_rate is the chain-wide minimum commission rate that a validator can charge their delegators description: Params defines the parameters for the x/staking module. cosmos.staking.v1beta1.Pool: type: object properties: not_bonded_tokens: type: string bonded_tokens: type: string description: |- Pool is used for tracking bonded and not-bonded token supply of the bond denomination. cosmos.staking.v1beta1.QueryDelegationResponse: type: object properties: delegation_response: type: object properties: delegation: type: object properties: delegator_address: type: string description: >- delegator_address is the bech32-encoded address of the delegator. validator_address: type: string description: >- validator_address is the bech32-encoded address of the validator. shares: type: string description: shares define the delegation shares received. description: >- Delegation represents the bond with tokens held by an account. It is owned by one delegator, and is associated with the voting power of one validator. balance: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- DelegationResponse is equivalent to Delegation except that it contains a balance in addition to shares which is more suitable for client responses. description: >- QueryDelegationResponse is response type for the Query/Delegation RPC method. cosmos.staking.v1beta1.QueryDelegatorDelegationsResponse: type: object properties: delegation_responses: type: array items: type: object properties: delegation: type: object properties: delegator_address: type: string description: >- delegator_address is the bech32-encoded address of the delegator. validator_address: type: string description: >- validator_address is the bech32-encoded address of the validator. shares: type: string description: shares define the delegation shares received. description: >- Delegation represents the bond with tokens held by an account. It is owned by one delegator, and is associated with the voting power of one validator. balance: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- DelegationResponse is equivalent to Delegation except that it contains a balance in addition to shares which is more suitable for client responses. description: delegation_responses defines all the delegations' info of a delegator. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: |- QueryDelegatorDelegationsResponse is response type for the Query/DelegatorDelegations RPC method. cosmos.staking.v1beta1.QueryDelegatorUnbondingDelegationsResponse: type: object properties: unbonding_responses: type: array items: type: object properties: delegator_address: type: string description: >- delegator_address is the bech32-encoded address of the delegator. validator_address: type: string description: >- validator_address is the bech32-encoded address of the validator. entries: type: array items: type: object properties: creation_height: type: string format: int64 description: >- creation_height is the height which the unbonding took place. completion_time: type: string format: date-time description: completion_time is the unix time for unbonding completion. initial_balance: type: string description: >- initial_balance defines the tokens initially scheduled to receive at completion. balance: type: string description: balance defines the tokens to receive at completion. unbonding_id: type: string format: uint64 title: Incrementing id that uniquely identifies this entry unbonding_on_hold_ref_count: type: string format: int64 title: >- Strictly positive if this entry's unbonding has been stopped by external modules description: >- UnbondingDelegationEntry defines an unbonding object with relevant metadata. description: entries are the unbonding delegation entries. description: >- UnbondingDelegation stores all of a single delegator's unbonding bonds for a single validator in an time-ordered list. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: |- QueryUnbondingDelegatorDelegationsResponse is response type for the Query/UnbondingDelegatorDelegations RPC method. cosmos.staking.v1beta1.QueryDelegatorValidatorResponse: type: object properties: validator: type: object properties: operator_address: type: string description: >- operator_address defines the address of the validator's operator; bech encoded in JSON. consensus_pubkey: type: object properties: type_url: type: string value: type: string format: byte description: >- consensus_pubkey is the consensus public key of the validator, as a Protobuf Any. jailed: type: boolean description: >- jailed defined whether the validator has been jailed from bonded status or not. status: description: status is the validator status (bonded/unbonding/unbonded). type: string enum: - BOND_STATUS_UNSPECIFIED - BOND_STATUS_UNBONDED - BOND_STATUS_UNBONDING - BOND_STATUS_BONDED default: BOND_STATUS_UNSPECIFIED tokens: type: string description: tokens define the delegated tokens (incl. self-delegation). delegator_shares: type: string description: >- delegator_shares defines total shares issued to a validator's delegators. description: description: description defines the description terms for the validator. type: object properties: moniker: type: string description: moniker defines a human-readable name for the validator. identity: type: string description: >- identity defines an optional identity signature (ex. UPort or Keybase). website: type: string description: website defines an optional website link. security_contact: type: string description: >- security_contact defines an optional email for security contact. details: type: string description: details define other optional details. unbonding_height: type: string format: int64 description: >- unbonding_height defines, if unbonding, the height at which this validator has begun unbonding. unbonding_time: type: string format: date-time description: >- unbonding_time defines, if unbonding, the min time for the validator to complete unbonding. commission: description: commission defines the commission parameters. type: object properties: commission_rates: description: >- commission_rates defines the initial commission rates to be used for creating a validator. type: object properties: rate: type: string description: >- rate is the commission rate charged to delegators, as a fraction. max_rate: type: string description: >- max_rate defines the maximum commission rate which validator can ever charge, as a fraction. max_change_rate: type: string description: >- max_change_rate defines the maximum daily increase of the validator commission, as a fraction. update_time: type: string format: date-time description: update_time is the last time the commission rate was changed. min_self_delegation: type: string description: >- min_self_delegation is the validator's self declared minimum self delegation. Since: cosmos-sdk 0.46 unbonding_on_hold_ref_count: type: string format: int64 title: >- strictly positive if this validator's unbonding has been stopped by external modules unbonding_ids: type: array items: type: string format: uint64 title: >- list of unbonding ids, each uniquely identifing an unbonding of this validator description: >- Validator defines a validator, together with the total amount of the Validator's bond shares and their exchange rate to coins. Slashing results in a decrease in the exchange rate, allowing correct calculation of future undelegations without iterating over delegators. When coins are delegated to this validator, the validator is credited with a delegation whose number of bond shares is based on the amount of coins delegated divided by the current exchange rate. Voting power can be calculated as total bonded shares multiplied by exchange rate. description: |- QueryDelegatorValidatorResponse response type for the Query/DelegatorValidator RPC method. cosmos.staking.v1beta1.QueryDelegatorValidatorsResponse: type: object properties: validators: type: array items: type: object properties: operator_address: type: string description: >- operator_address defines the address of the validator's operator; bech encoded in JSON. consensus_pubkey: type: object properties: type_url: type: string value: type: string format: byte description: >- consensus_pubkey is the consensus public key of the validator, as a Protobuf Any. jailed: type: boolean description: >- jailed defined whether the validator has been jailed from bonded status or not. status: description: status is the validator status (bonded/unbonding/unbonded). type: string enum: - BOND_STATUS_UNSPECIFIED - BOND_STATUS_UNBONDED - BOND_STATUS_UNBONDING - BOND_STATUS_BONDED default: BOND_STATUS_UNSPECIFIED tokens: type: string description: tokens define the delegated tokens (incl. self-delegation). delegator_shares: type: string description: >- delegator_shares defines total shares issued to a validator's delegators. description: description: description defines the description terms for the validator. type: object properties: moniker: type: string description: moniker defines a human-readable name for the validator. identity: type: string description: >- identity defines an optional identity signature (ex. UPort or Keybase). website: type: string description: website defines an optional website link. security_contact: type: string description: >- security_contact defines an optional email for security contact. details: type: string description: details define other optional details. unbonding_height: type: string format: int64 description: >- unbonding_height defines, if unbonding, the height at which this validator has begun unbonding. unbonding_time: type: string format: date-time description: >- unbonding_time defines, if unbonding, the min time for the validator to complete unbonding. commission: description: commission defines the commission parameters. type: object properties: commission_rates: description: >- commission_rates defines the initial commission rates to be used for creating a validator. type: object properties: rate: type: string description: >- rate is the commission rate charged to delegators, as a fraction. max_rate: type: string description: >- max_rate defines the maximum commission rate which validator can ever charge, as a fraction. max_change_rate: type: string description: >- max_change_rate defines the maximum daily increase of the validator commission, as a fraction. update_time: type: string format: date-time description: >- update_time is the last time the commission rate was changed. min_self_delegation: type: string description: >- min_self_delegation is the validator's self declared minimum self delegation. Since: cosmos-sdk 0.46 unbonding_on_hold_ref_count: type: string format: int64 title: >- strictly positive if this validator's unbonding has been stopped by external modules unbonding_ids: type: array items: type: string format: uint64 title: >- list of unbonding ids, each uniquely identifing an unbonding of this validator description: >- Validator defines a validator, together with the total amount of the Validator's bond shares and their exchange rate to coins. Slashing results in a decrease in the exchange rate, allowing correct calculation of future undelegations without iterating over delegators. When coins are delegated to this validator, the validator is credited with a delegation whose number of bond shares is based on the amount of coins delegated divided by the current exchange rate. Voting power can be calculated as total bonded shares multiplied by exchange rate. description: validators defines the validators' info of a delegator. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: |- QueryDelegatorValidatorsResponse is response type for the Query/DelegatorValidators RPC method. cosmos.staking.v1beta1.QueryHistoricalInfoResponse: type: object properties: hist: description: hist defines the historical info at the given height. type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. valset: type: array items: type: object properties: operator_address: type: string description: >- operator_address defines the address of the validator's operator; bech encoded in JSON. consensus_pubkey: type: object properties: type_url: type: string value: type: string format: byte description: >- consensus_pubkey is the consensus public key of the validator, as a Protobuf Any. jailed: type: boolean description: >- jailed defined whether the validator has been jailed from bonded status or not. status: description: status is the validator status (bonded/unbonding/unbonded). type: string enum: - BOND_STATUS_UNSPECIFIED - BOND_STATUS_UNBONDED - BOND_STATUS_UNBONDING - BOND_STATUS_BONDED default: BOND_STATUS_UNSPECIFIED tokens: type: string description: tokens define the delegated tokens (incl. self-delegation). delegator_shares: type: string description: >- delegator_shares defines total shares issued to a validator's delegators. description: description: description defines the description terms for the validator. type: object properties: moniker: type: string description: moniker defines a human-readable name for the validator. identity: type: string description: >- identity defines an optional identity signature (ex. UPort or Keybase). website: type: string description: website defines an optional website link. security_contact: type: string description: >- security_contact defines an optional email for security contact. details: type: string description: details define other optional details. unbonding_height: type: string format: int64 description: >- unbonding_height defines, if unbonding, the height at which this validator has begun unbonding. unbonding_time: type: string format: date-time description: >- unbonding_time defines, if unbonding, the min time for the validator to complete unbonding. commission: description: commission defines the commission parameters. type: object properties: commission_rates: description: >- commission_rates defines the initial commission rates to be used for creating a validator. type: object properties: rate: type: string description: >- rate is the commission rate charged to delegators, as a fraction. max_rate: type: string description: >- max_rate defines the maximum commission rate which validator can ever charge, as a fraction. max_change_rate: type: string description: >- max_change_rate defines the maximum daily increase of the validator commission, as a fraction. update_time: type: string format: date-time description: >- update_time is the last time the commission rate was changed. min_self_delegation: type: string description: >- min_self_delegation is the validator's self declared minimum self delegation. Since: cosmos-sdk 0.46 unbonding_on_hold_ref_count: type: string format: int64 title: >- strictly positive if this validator's unbonding has been stopped by external modules unbonding_ids: type: array items: type: string format: uint64 title: >- list of unbonding ids, each uniquely identifing an unbonding of this validator description: >- Validator defines a validator, together with the total amount of the Validator's bond shares and their exchange rate to coins. Slashing results in a decrease in the exchange rate, allowing correct calculation of future undelegations without iterating over delegators. When coins are delegated to this validator, the validator is credited with a delegation whose number of bond shares is based on the amount of coins delegated divided by the current exchange rate. Voting power can be calculated as total bonded shares multiplied by exchange rate. description: >- QueryHistoricalInfoResponse is response type for the Query/HistoricalInfo RPC method. cosmos.staking.v1beta1.QueryParamsResponse: type: object properties: params: description: params holds all the parameters of this module. type: object properties: unbonding_time: type: string description: unbonding_time is the time duration of unbonding. max_validators: type: integer format: int64 description: max_validators is the maximum number of validators. max_entries: type: integer format: int64 description: >- max_entries is the max entries for either unbonding delegation or redelegation (per pair/trio). historical_entries: type: integer format: int64 description: historical_entries is the number of historical entries to persist. bond_denom: type: string description: bond_denom defines the bondable coin denomination. min_commission_rate: type: string title: >- min_commission_rate is the chain-wide minimum commission rate that a validator can charge their delegators description: QueryParamsResponse is response type for the Query/Params RPC method. cosmos.staking.v1beta1.QueryPoolResponse: type: object properties: pool: description: pool defines the pool info. type: object properties: not_bonded_tokens: type: string bonded_tokens: type: string description: QueryPoolResponse is response type for the Query/Pool RPC method. cosmos.staking.v1beta1.QueryRedelegationsResponse: type: object properties: redelegation_responses: type: array items: type: object properties: redelegation: type: object properties: delegator_address: type: string description: >- delegator_address is the bech32-encoded address of the delegator. validator_src_address: type: string description: >- validator_src_address is the validator redelegation source operator address. validator_dst_address: type: string description: >- validator_dst_address is the validator redelegation destination operator address. entries: type: array items: type: object properties: creation_height: type: string format: int64 description: >- creation_height defines the height which the redelegation took place. completion_time: type: string format: date-time description: >- completion_time defines the unix time for redelegation completion. initial_balance: type: string description: >- initial_balance defines the initial balance when redelegation started. shares_dst: type: string description: >- shares_dst is the amount of destination-validator shares created by redelegation. unbonding_id: type: string format: uint64 title: Incrementing id that uniquely identifies this entry unbonding_on_hold_ref_count: type: string format: int64 title: >- Strictly positive if this entry's unbonding has been stopped by external modules description: >- RedelegationEntry defines a redelegation object with relevant metadata. description: entries are the redelegation entries. description: >- Redelegation contains the list of a particular delegator's redelegating bonds from a particular source validator to a particular destination validator. entries: type: array items: type: object properties: redelegation_entry: type: object properties: creation_height: type: string format: int64 description: >- creation_height defines the height which the redelegation took place. completion_time: type: string format: date-time description: >- completion_time defines the unix time for redelegation completion. initial_balance: type: string description: >- initial_balance defines the initial balance when redelegation started. shares_dst: type: string description: >- shares_dst is the amount of destination-validator shares created by redelegation. unbonding_id: type: string format: uint64 title: Incrementing id that uniquely identifies this entry unbonding_on_hold_ref_count: type: string format: int64 title: >- Strictly positive if this entry's unbonding has been stopped by external modules description: >- RedelegationEntry defines a redelegation object with relevant metadata. balance: type: string description: >- RedelegationEntryResponse is equivalent to a RedelegationEntry except that it contains a balance in addition to shares which is more suitable for client responses. description: >- RedelegationResponse is equivalent to a Redelegation except that its entries contain a balance in addition to shares which is more suitable for client responses. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- QueryRedelegationsResponse is response type for the Query/Redelegations RPC method. cosmos.staking.v1beta1.QueryUnbondingDelegationResponse: type: object properties: unbond: type: object properties: delegator_address: type: string description: delegator_address is the bech32-encoded address of the delegator. validator_address: type: string description: validator_address is the bech32-encoded address of the validator. entries: type: array items: type: object properties: creation_height: type: string format: int64 description: >- creation_height is the height which the unbonding took place. completion_time: type: string format: date-time description: completion_time is the unix time for unbonding completion. initial_balance: type: string description: >- initial_balance defines the tokens initially scheduled to receive at completion. balance: type: string description: balance defines the tokens to receive at completion. unbonding_id: type: string format: uint64 title: Incrementing id that uniquely identifies this entry unbonding_on_hold_ref_count: type: string format: int64 title: >- Strictly positive if this entry's unbonding has been stopped by external modules description: >- UnbondingDelegationEntry defines an unbonding object with relevant metadata. description: entries are the unbonding delegation entries. description: |- UnbondingDelegation stores all of a single delegator's unbonding bonds for a single validator in an time-ordered list. description: |- QueryDelegationResponse is response type for the Query/UnbondingDelegation RPC method. cosmos.staking.v1beta1.QueryValidatorDelegationsResponse: type: object properties: delegation_responses: type: array items: type: object properties: delegation: type: object properties: delegator_address: type: string description: >- delegator_address is the bech32-encoded address of the delegator. validator_address: type: string description: >- validator_address is the bech32-encoded address of the validator. shares: type: string description: shares define the delegation shares received. description: >- Delegation represents the bond with tokens held by an account. It is owned by one delegator, and is associated with the voting power of one validator. balance: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- DelegationResponse is equivalent to Delegation except that it contains a balance in addition to shares which is more suitable for client responses. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: |- QueryValidatorDelegationsResponse is response type for the Query/ValidatorDelegations RPC method cosmos.staking.v1beta1.QueryValidatorResponse: type: object properties: validator: type: object properties: operator_address: type: string description: >- operator_address defines the address of the validator's operator; bech encoded in JSON. consensus_pubkey: type: object properties: type_url: type: string value: type: string format: byte description: >- consensus_pubkey is the consensus public key of the validator, as a Protobuf Any. jailed: type: boolean description: >- jailed defined whether the validator has been jailed from bonded status or not. status: description: status is the validator status (bonded/unbonding/unbonded). type: string enum: - BOND_STATUS_UNSPECIFIED - BOND_STATUS_UNBONDED - BOND_STATUS_UNBONDING - BOND_STATUS_BONDED default: BOND_STATUS_UNSPECIFIED tokens: type: string description: tokens define the delegated tokens (incl. self-delegation). delegator_shares: type: string description: >- delegator_shares defines total shares issued to a validator's delegators. description: description: description defines the description terms for the validator. type: object properties: moniker: type: string description: moniker defines a human-readable name for the validator. identity: type: string description: >- identity defines an optional identity signature (ex. UPort or Keybase). website: type: string description: website defines an optional website link. security_contact: type: string description: >- security_contact defines an optional email for security contact. details: type: string description: details define other optional details. unbonding_height: type: string format: int64 description: >- unbonding_height defines, if unbonding, the height at which this validator has begun unbonding. unbonding_time: type: string format: date-time description: >- unbonding_time defines, if unbonding, the min time for the validator to complete unbonding. commission: description: commission defines the commission parameters. type: object properties: commission_rates: description: >- commission_rates defines the initial commission rates to be used for creating a validator. type: object properties: rate: type: string description: >- rate is the commission rate charged to delegators, as a fraction. max_rate: type: string description: >- max_rate defines the maximum commission rate which validator can ever charge, as a fraction. max_change_rate: type: string description: >- max_change_rate defines the maximum daily increase of the validator commission, as a fraction. update_time: type: string format: date-time description: update_time is the last time the commission rate was changed. min_self_delegation: type: string description: >- min_self_delegation is the validator's self declared minimum self delegation. Since: cosmos-sdk 0.46 unbonding_on_hold_ref_count: type: string format: int64 title: >- strictly positive if this validator's unbonding has been stopped by external modules unbonding_ids: type: array items: type: string format: uint64 title: >- list of unbonding ids, each uniquely identifing an unbonding of this validator description: >- Validator defines a validator, together with the total amount of the Validator's bond shares and their exchange rate to coins. Slashing results in a decrease in the exchange rate, allowing correct calculation of future undelegations without iterating over delegators. When coins are delegated to this validator, the validator is credited with a delegation whose number of bond shares is based on the amount of coins delegated divided by the current exchange rate. Voting power can be calculated as total bonded shares multiplied by exchange rate. title: QueryValidatorResponse is response type for the Query/Validator RPC method cosmos.staking.v1beta1.QueryValidatorUnbondingDelegationsResponse: type: object properties: unbonding_responses: type: array items: type: object properties: delegator_address: type: string description: >- delegator_address is the bech32-encoded address of the delegator. validator_address: type: string description: >- validator_address is the bech32-encoded address of the validator. entries: type: array items: type: object properties: creation_height: type: string format: int64 description: >- creation_height is the height which the unbonding took place. completion_time: type: string format: date-time description: completion_time is the unix time for unbonding completion. initial_balance: type: string description: >- initial_balance defines the tokens initially scheduled to receive at completion. balance: type: string description: balance defines the tokens to receive at completion. unbonding_id: type: string format: uint64 title: Incrementing id that uniquely identifies this entry unbonding_on_hold_ref_count: type: string format: int64 title: >- Strictly positive if this entry's unbonding has been stopped by external modules description: >- UnbondingDelegationEntry defines an unbonding object with relevant metadata. description: entries are the unbonding delegation entries. description: >- UnbondingDelegation stores all of a single delegator's unbonding bonds for a single validator in an time-ordered list. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: |- QueryValidatorUnbondingDelegationsResponse is response type for the Query/ValidatorUnbondingDelegations RPC method. cosmos.staking.v1beta1.QueryValidatorsResponse: type: object properties: validators: type: array items: type: object properties: operator_address: type: string description: >- operator_address defines the address of the validator's operator; bech encoded in JSON. consensus_pubkey: type: object properties: type_url: type: string value: type: string format: byte description: >- consensus_pubkey is the consensus public key of the validator, as a Protobuf Any. jailed: type: boolean description: >- jailed defined whether the validator has been jailed from bonded status or not. status: description: status is the validator status (bonded/unbonding/unbonded). type: string enum: - BOND_STATUS_UNSPECIFIED - BOND_STATUS_UNBONDED - BOND_STATUS_UNBONDING - BOND_STATUS_BONDED default: BOND_STATUS_UNSPECIFIED tokens: type: string description: tokens define the delegated tokens (incl. self-delegation). delegator_shares: type: string description: >- delegator_shares defines total shares issued to a validator's delegators. description: description: description defines the description terms for the validator. type: object properties: moniker: type: string description: moniker defines a human-readable name for the validator. identity: type: string description: >- identity defines an optional identity signature (ex. UPort or Keybase). website: type: string description: website defines an optional website link. security_contact: type: string description: >- security_contact defines an optional email for security contact. details: type: string description: details define other optional details. unbonding_height: type: string format: int64 description: >- unbonding_height defines, if unbonding, the height at which this validator has begun unbonding. unbonding_time: type: string format: date-time description: >- unbonding_time defines, if unbonding, the min time for the validator to complete unbonding. commission: description: commission defines the commission parameters. type: object properties: commission_rates: description: >- commission_rates defines the initial commission rates to be used for creating a validator. type: object properties: rate: type: string description: >- rate is the commission rate charged to delegators, as a fraction. max_rate: type: string description: >- max_rate defines the maximum commission rate which validator can ever charge, as a fraction. max_change_rate: type: string description: >- max_change_rate defines the maximum daily increase of the validator commission, as a fraction. update_time: type: string format: date-time description: >- update_time is the last time the commission rate was changed. min_self_delegation: type: string description: >- min_self_delegation is the validator's self declared minimum self delegation. Since: cosmos-sdk 0.46 unbonding_on_hold_ref_count: type: string format: int64 title: >- strictly positive if this validator's unbonding has been stopped by external modules unbonding_ids: type: array items: type: string format: uint64 title: >- list of unbonding ids, each uniquely identifing an unbonding of this validator description: >- Validator defines a validator, together with the total amount of the Validator's bond shares and their exchange rate to coins. Slashing results in a decrease in the exchange rate, allowing correct calculation of future undelegations without iterating over delegators. When coins are delegated to this validator, the validator is credited with a delegation whose number of bond shares is based on the amount of coins delegated divided by the current exchange rate. Voting power can be calculated as total bonded shares multiplied by exchange rate. description: validators contains all the queried validators. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: >- QueryValidatorsResponse is response type for the Query/Validators RPC method cosmos.staking.v1beta1.Redelegation: type: object properties: delegator_address: type: string description: delegator_address is the bech32-encoded address of the delegator. validator_src_address: type: string description: >- validator_src_address is the validator redelegation source operator address. validator_dst_address: type: string description: >- validator_dst_address is the validator redelegation destination operator address. entries: type: array items: type: object properties: creation_height: type: string format: int64 description: >- creation_height defines the height which the redelegation took place. completion_time: type: string format: date-time description: >- completion_time defines the unix time for redelegation completion. initial_balance: type: string description: >- initial_balance defines the initial balance when redelegation started. shares_dst: type: string description: >- shares_dst is the amount of destination-validator shares created by redelegation. unbonding_id: type: string format: uint64 title: Incrementing id that uniquely identifies this entry unbonding_on_hold_ref_count: type: string format: int64 title: >- Strictly positive if this entry's unbonding has been stopped by external modules description: >- RedelegationEntry defines a redelegation object with relevant metadata. description: entries are the redelegation entries. description: >- Redelegation contains the list of a particular delegator's redelegating bonds from a particular source validator to a particular destination validator. cosmos.staking.v1beta1.RedelegationEntry: type: object properties: creation_height: type: string format: int64 description: creation_height defines the height which the redelegation took place. completion_time: type: string format: date-time description: completion_time defines the unix time for redelegation completion. initial_balance: type: string description: initial_balance defines the initial balance when redelegation started. shares_dst: type: string description: >- shares_dst is the amount of destination-validator shares created by redelegation. unbonding_id: type: string format: uint64 title: Incrementing id that uniquely identifies this entry unbonding_on_hold_ref_count: type: string format: int64 title: >- Strictly positive if this entry's unbonding has been stopped by external modules description: RedelegationEntry defines a redelegation object with relevant metadata. cosmos.staking.v1beta1.RedelegationEntryResponse: type: object properties: redelegation_entry: type: object properties: creation_height: type: string format: int64 description: >- creation_height defines the height which the redelegation took place. completion_time: type: string format: date-time description: completion_time defines the unix time for redelegation completion. initial_balance: type: string description: >- initial_balance defines the initial balance when redelegation started. shares_dst: type: string description: >- shares_dst is the amount of destination-validator shares created by redelegation. unbonding_id: type: string format: uint64 title: Incrementing id that uniquely identifies this entry unbonding_on_hold_ref_count: type: string format: int64 title: >- Strictly positive if this entry's unbonding has been stopped by external modules description: >- RedelegationEntry defines a redelegation object with relevant metadata. balance: type: string description: >- RedelegationEntryResponse is equivalent to a RedelegationEntry except that it contains a balance in addition to shares which is more suitable for client responses. cosmos.staking.v1beta1.RedelegationResponse: type: object properties: redelegation: type: object properties: delegator_address: type: string description: delegator_address is the bech32-encoded address of the delegator. validator_src_address: type: string description: >- validator_src_address is the validator redelegation source operator address. validator_dst_address: type: string description: >- validator_dst_address is the validator redelegation destination operator address. entries: type: array items: type: object properties: creation_height: type: string format: int64 description: >- creation_height defines the height which the redelegation took place. completion_time: type: string format: date-time description: >- completion_time defines the unix time for redelegation completion. initial_balance: type: string description: >- initial_balance defines the initial balance when redelegation started. shares_dst: type: string description: >- shares_dst is the amount of destination-validator shares created by redelegation. unbonding_id: type: string format: uint64 title: Incrementing id that uniquely identifies this entry unbonding_on_hold_ref_count: type: string format: int64 title: >- Strictly positive if this entry's unbonding has been stopped by external modules description: >- RedelegationEntry defines a redelegation object with relevant metadata. description: entries are the redelegation entries. description: >- Redelegation contains the list of a particular delegator's redelegating bonds from a particular source validator to a particular destination validator. entries: type: array items: type: object properties: redelegation_entry: type: object properties: creation_height: type: string format: int64 description: >- creation_height defines the height which the redelegation took place. completion_time: type: string format: date-time description: >- completion_time defines the unix time for redelegation completion. initial_balance: type: string description: >- initial_balance defines the initial balance when redelegation started. shares_dst: type: string description: >- shares_dst is the amount of destination-validator shares created by redelegation. unbonding_id: type: string format: uint64 title: Incrementing id that uniquely identifies this entry unbonding_on_hold_ref_count: type: string format: int64 title: >- Strictly positive if this entry's unbonding has been stopped by external modules description: >- RedelegationEntry defines a redelegation object with relevant metadata. balance: type: string description: >- RedelegationEntryResponse is equivalent to a RedelegationEntry except that it contains a balance in addition to shares which is more suitable for client responses. description: >- RedelegationResponse is equivalent to a Redelegation except that its entries contain a balance in addition to shares which is more suitable for client responses. cosmos.staking.v1beta1.UnbondingDelegation: type: object properties: delegator_address: type: string description: delegator_address is the bech32-encoded address of the delegator. validator_address: type: string description: validator_address is the bech32-encoded address of the validator. entries: type: array items: type: object properties: creation_height: type: string format: int64 description: creation_height is the height which the unbonding took place. completion_time: type: string format: date-time description: completion_time is the unix time for unbonding completion. initial_balance: type: string description: >- initial_balance defines the tokens initially scheduled to receive at completion. balance: type: string description: balance defines the tokens to receive at completion. unbonding_id: type: string format: uint64 title: Incrementing id that uniquely identifies this entry unbonding_on_hold_ref_count: type: string format: int64 title: >- Strictly positive if this entry's unbonding has been stopped by external modules description: >- UnbondingDelegationEntry defines an unbonding object with relevant metadata. description: entries are the unbonding delegation entries. description: |- UnbondingDelegation stores all of a single delegator's unbonding bonds for a single validator in an time-ordered list. cosmos.staking.v1beta1.UnbondingDelegationEntry: type: object properties: creation_height: type: string format: int64 description: creation_height is the height which the unbonding took place. completion_time: type: string format: date-time description: completion_time is the unix time for unbonding completion. initial_balance: type: string description: >- initial_balance defines the tokens initially scheduled to receive at completion. balance: type: string description: balance defines the tokens to receive at completion. unbonding_id: type: string format: uint64 title: Incrementing id that uniquely identifies this entry unbonding_on_hold_ref_count: type: string format: int64 title: >- Strictly positive if this entry's unbonding has been stopped by external modules description: >- UnbondingDelegationEntry defines an unbonding object with relevant metadata. cosmos.staking.v1beta1.Validator: type: object properties: operator_address: type: string description: >- operator_address defines the address of the validator's operator; bech encoded in JSON. consensus_pubkey: type: object properties: type_url: type: string value: type: string format: byte description: >- consensus_pubkey is the consensus public key of the validator, as a Protobuf Any. jailed: type: boolean description: >- jailed defined whether the validator has been jailed from bonded status or not. status: description: status is the validator status (bonded/unbonding/unbonded). type: string enum: - BOND_STATUS_UNSPECIFIED - BOND_STATUS_UNBONDED - BOND_STATUS_UNBONDING - BOND_STATUS_BONDED default: BOND_STATUS_UNSPECIFIED tokens: type: string description: tokens define the delegated tokens (incl. self-delegation). delegator_shares: type: string description: >- delegator_shares defines total shares issued to a validator's delegators. description: description: description defines the description terms for the validator. type: object properties: moniker: type: string description: moniker defines a human-readable name for the validator. identity: type: string description: >- identity defines an optional identity signature (ex. UPort or Keybase). website: type: string description: website defines an optional website link. security_contact: type: string description: security_contact defines an optional email for security contact. details: type: string description: details define other optional details. unbonding_height: type: string format: int64 description: >- unbonding_height defines, if unbonding, the height at which this validator has begun unbonding. unbonding_time: type: string format: date-time description: >- unbonding_time defines, if unbonding, the min time for the validator to complete unbonding. commission: description: commission defines the commission parameters. type: object properties: commission_rates: description: >- commission_rates defines the initial commission rates to be used for creating a validator. type: object properties: rate: type: string description: >- rate is the commission rate charged to delegators, as a fraction. max_rate: type: string description: >- max_rate defines the maximum commission rate which validator can ever charge, as a fraction. max_change_rate: type: string description: >- max_change_rate defines the maximum daily increase of the validator commission, as a fraction. update_time: type: string format: date-time description: update_time is the last time the commission rate was changed. min_self_delegation: type: string description: >- min_self_delegation is the validator's self declared minimum self delegation. Since: cosmos-sdk 0.46 unbonding_on_hold_ref_count: type: string format: int64 title: >- strictly positive if this validator's unbonding has been stopped by external modules unbonding_ids: type: array items: type: string format: uint64 title: >- list of unbonding ids, each uniquely identifing an unbonding of this validator description: >- Validator defines a validator, together with the total amount of the Validator's bond shares and their exchange rate to coins. Slashing results in a decrease in the exchange rate, allowing correct calculation of future undelegations without iterating over delegators. When coins are delegated to this validator, the validator is credited with a delegation whose number of bond shares is based on the amount of coins delegated divided by the current exchange rate. Voting power can be calculated as total bonded shares multiplied by exchange rate. tendermint.types.BlockID: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID tendermint.types.Header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. tendermint.types.PartSetHeader: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader tendermint.version.Consensus: type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. ibc.applications.transfer.v1.DenomTrace: type: object properties: path: type: string description: >- path defines the chain of port/channel identifiers used for tracing the source of the fungible token. base_denom: type: string description: base denomination of the relayed fungible token. description: >- DenomTrace contains the base denomination for ICS20 fungible tokens and the source tracing information path. ibc.applications.transfer.v1.Params: type: object properties: send_enabled: type: boolean description: >- send_enabled enables or disables all cross-chain token transfers from this chain. receive_enabled: type: boolean description: >- receive_enabled enables or disables all cross-chain token transfers to this chain. description: >- Params defines the set of IBC transfer parameters. NOTE: To prevent a single token from being transferred, set the TransfersEnabled parameter to true and then set the bank module's SendEnabled parameter for the denomination to false. ibc.applications.transfer.v1.QueryDenomHashResponse: type: object properties: hash: type: string description: hash (in hex format) of the denomination trace information. description: |- QueryDenomHashResponse is the response type for the Query/DenomHash RPC method. ibc.applications.transfer.v1.QueryDenomTraceResponse: type: object properties: denom_trace: type: object properties: path: type: string description: >- path defines the chain of port/channel identifiers used for tracing the source of the fungible token. base_denom: type: string description: base denomination of the relayed fungible token. description: >- DenomTrace contains the base denomination for ICS20 fungible tokens and the source tracing information path. description: |- QueryDenomTraceResponse is the response type for the Query/DenomTrace RPC method. ibc.applications.transfer.v1.QueryDenomTracesResponse: type: object properties: denom_traces: type: array items: type: object properties: path: type: string description: >- path defines the chain of port/channel identifiers used for tracing the source of the fungible token. base_denom: type: string description: base denomination of the relayed fungible token. description: >- DenomTrace contains the base denomination for ICS20 fungible tokens and the source tracing information path. description: denom_traces returns all denominations trace information. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- QueryConnectionsResponse is the response type for the Query/DenomTraces RPC method. ibc.applications.transfer.v1.QueryEscrowAddressResponse: type: object properties: escrow_address: type: string title: the escrow account address description: >- QueryEscrowAddressResponse is the response type of the EscrowAddress RPC method. ibc.applications.transfer.v1.QueryParamsResponse: type: object properties: params: description: params defines the parameters of the module. type: object properties: send_enabled: type: boolean description: >- send_enabled enables or disables all cross-chain token transfers from this chain. receive_enabled: type: boolean description: >- receive_enabled enables or disables all cross-chain token transfers to this chain. description: QueryParamsResponse is the response type for the Query/Params RPC method. ibc.applications.transfer.v1.QueryTotalEscrowForDenomResponse: type: object properties: amount: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- QueryTotalEscrowForDenomResponse is the response type for TotalEscrowForDenom RPC method. cosmos.base.abci.v1beta1.ABCIMessageLog: type: object properties: msg_index: type: integer format: int64 log: type: string events: type: array items: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string description: >- Attribute defines an attribute wrapper where the key and value are strings instead of raw bytes. description: |- StringEvent defines en Event object wrapper where all the attributes contain key/value pairs that are strings instead of raw bytes. description: |- Events contains a slice of Event objects that were emitted during some execution. description: >- ABCIMessageLog defines a structure containing an indexed tx ABCI message log. cosmos.base.abci.v1beta1.Attribute: type: object properties: key: type: string value: type: string description: |- Attribute defines an attribute wrapper where the key and value are strings instead of raw bytes. cosmos.base.abci.v1beta1.GasInfo: type: object properties: gas_wanted: type: string format: uint64 description: GasWanted is the maximum units of work we allow this tx to perform. gas_used: type: string format: uint64 description: GasUsed is the amount of gas actually consumed. description: GasInfo defines tx execution gas context. cosmos.base.abci.v1beta1.Result: type: object properties: data: type: string format: byte description: >- Data is any data returned from message or handler execution. It MUST be length prefixed in order to separate data from multiple message executions. Deprecated. This field is still populated, but prefer msg_response instead because it also contains the Msg response typeURL. log: type: string description: Log contains the log information from message or handler execution. events: type: array items: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string index: type: boolean description: >- EventAttribute is a single key-value pair, associated with an event. description: >- Event allows application developers to attach additional information to ResponseBeginBlock, ResponseEndBlock, ResponseCheckTx and ResponseDeliverTx. Later, transactions may be queried using these events. description: >- Events contains a slice of Event objects that were emitted during message or handler execution. msg_responses: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: |- msg_responses contains the Msg handler responses type packed in Anys. Since: cosmos-sdk 0.46 description: Result is the union of ResponseFormat and ResponseCheckTx. cosmos.base.abci.v1beta1.StringEvent: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string description: |- Attribute defines an attribute wrapper where the key and value are strings instead of raw bytes. description: |- StringEvent defines en Event object wrapper where all the attributes contain key/value pairs that are strings instead of raw bytes. cosmos.base.abci.v1beta1.TxResponse: type: object properties: height: type: string format: int64 title: The block height txhash: type: string description: The transaction hash. codespace: type: string title: Namespace for the Code code: type: integer format: int64 description: Response code. data: type: string description: Result bytes, if any. raw_log: type: string description: |- The output of the application's logger (raw string). May be non-deterministic. logs: type: array items: type: object properties: msg_index: type: integer format: int64 log: type: string events: type: array items: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string description: >- Attribute defines an attribute wrapper where the key and value are strings instead of raw bytes. description: >- StringEvent defines en Event object wrapper where all the attributes contain key/value pairs that are strings instead of raw bytes. description: >- Events contains a slice of Event objects that were emitted during some execution. description: >- ABCIMessageLog defines a structure containing an indexed tx ABCI message log. description: >- The output of the application's logger (typed). May be non-deterministic. info: type: string description: Additional information. May be non-deterministic. gas_wanted: type: string format: int64 description: Amount of gas requested for transaction. gas_used: type: string format: int64 description: Amount of gas consumed by transaction. tx: type: object properties: type_url: type: string value: type: string format: byte description: The request transaction bytes. timestamp: type: string description: >- Time of the previous block. For heights > 1, it's the weighted median of the timestamps of the valid votes in the block.LastCommit. For height == 1, it's genesis time. events: type: array items: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string index: type: boolean description: >- EventAttribute is a single key-value pair, associated with an event. description: >- Event allows application developers to attach additional information to ResponseBeginBlock, ResponseEndBlock, ResponseCheckTx and ResponseDeliverTx. Later, transactions may be queried using these events. description: >- Events defines all the events emitted by processing a transaction. Note, these events include those emitted by processing all the messages and those emitted from the ante. Whereas Logs contains the events, with additional metadata, emitted only by processing the messages. Since: cosmos-sdk 0.42.11, 0.44.5, 0.45 description: >- TxResponse defines a structure containing relevant tx data and metadata. The tags are stringified and the log is JSON decoded. cosmos.crypto.multisig.v1beta1.CompactBitArray: type: object properties: extra_bits_stored: type: integer format: int64 elems: type: string format: byte description: |- CompactBitArray is an implementation of a space efficient bit array. This is used to ensure that the encoded data takes up a minimal amount of space after proto encoding. This is not thread safe, and is not intended for concurrent usage. cosmos.tx.signing.v1beta1.SignMode: type: string enum: - SIGN_MODE_UNSPECIFIED - SIGN_MODE_DIRECT - SIGN_MODE_TEXTUAL - SIGN_MODE_DIRECT_AUX - SIGN_MODE_LEGACY_AMINO_JSON - SIGN_MODE_EIP_191 default: SIGN_MODE_UNSPECIFIED description: |- SignMode represents a signing mode with its own security guarantees. This enum should be considered a registry of all known sign modes in the Cosmos ecosystem. Apps are not expected to support all known sign modes. Apps that would like to support custom sign modes are encouraged to open a small PR against this file to add a new case to this SignMode enum describing their sign mode so that different apps have a consistent version of this enum. - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be rejected. - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is verified with raw bytes from Tx. - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some human-readable textual representation on top of the binary representation from SIGN_MODE_DIRECT. It is currently not supported. - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses SignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not require signers signing over other signers' `signer_info`. It also allows for adding Tips in transactions. Since: cosmos-sdk 0.46 - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses Amino JSON and will be removed in the future. - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos SDK. Ref: https://eips.ethereum.org/EIPS/eip-191 Currently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant, but is not implemented on the SDK by default. To enable EIP-191, you need to pass a custom `TxConfig` that has an implementation of `SignModeHandler` for EIP-191. The SDK may decide to fully support EIP-191 in the future. Since: cosmos-sdk 0.45.2 cosmos.tx.v1beta1.AuthInfo: type: object properties: signer_infos: type: array items: type: object properties: public_key: type: object properties: type_url: type: string value: type: string format: byte description: >- public_key is the public key of the signer. It is optional for accounts that already exist in state. If unset, the verifier can use the required \ signer address for this position and lookup the public key. mode_info: title: >- mode_info describes the signing mode of the signer and is a nested structure to support nested multisig pubkey's type: object properties: single: title: single represents a single signer type: object properties: mode: title: mode is the signing mode of the single signer type: string enum: - SIGN_MODE_UNSPECIFIED - SIGN_MODE_DIRECT - SIGN_MODE_TEXTUAL - SIGN_MODE_DIRECT_AUX - SIGN_MODE_LEGACY_AMINO_JSON - SIGN_MODE_EIP_191 default: SIGN_MODE_UNSPECIFIED description: >- SignMode represents a signing mode with its own security guarantees. This enum should be considered a registry of all known sign modes in the Cosmos ecosystem. Apps are not expected to support all known sign modes. Apps that would like to support custom sign modes are encouraged to open a small PR against this file to add a new case to this SignMode enum describing their sign mode so that different apps have a consistent version of this enum. - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be rejected. - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is verified with raw bytes from Tx. - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some human-readable textual representation on top of the binary representation from SIGN_MODE_DIRECT. It is currently not supported. - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses SignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not require signers signing over other signers' `signer_info`. It also allows for adding Tips in transactions. Since: cosmos-sdk 0.46 - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses Amino JSON and will be removed in the future. - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos SDK. Ref: https://eips.ethereum.org/EIPS/eip-191 Currently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant, but is not implemented on the SDK by default. To enable EIP-191, you need to pass a custom `TxConfig` that has an implementation of `SignModeHandler` for EIP-191. The SDK may decide to fully support EIP-191 in the future. Since: cosmos-sdk 0.45.2 multi: title: multi represents a nested multisig signer type: object properties: bitarray: title: >- bitarray specifies which keys within the multisig are signing type: object properties: extra_bits_stored: type: integer format: int64 elems: type: string format: byte description: >- CompactBitArray is an implementation of a space efficient bit array. This is used to ensure that the encoded data takes up a minimal amount of space after proto encoding. This is not thread safe, and is not intended for concurrent usage. mode_infos: type: array items: {} title: >- mode_infos is the corresponding modes of the signers of the multisig which could include nested multisig public keys description: >- ModeInfo describes the signing mode of a single or nested multisig signer. sequence: type: string format: uint64 description: >- sequence is the sequence of the account, which describes the number of committed transactions signed by a given address. It is used to prevent replay attacks. description: >- SignerInfo describes the public key and signing mode of a single top-level signer. description: >- signer_infos defines the signing modes for the required signers. The number and order of elements must match the required signers from TxBody's messages. The first element is the primary signer and the one which pays the fee. fee: description: >- Fee is the fee and gas limit for the transaction. The first signer is the primary signer and the one which pays the fee. The fee can be calculated based on the cost of evaluating the body and doing signature verification of the signers. This can be estimated via simulation. type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of coins to be paid as a fee gas_limit: type: string format: uint64 title: >- gas_limit is the maximum gas that can be used in transaction processing before an out of gas error occurs payer: type: string description: >- if unset, the first signer is responsible for paying the fees. If set, the specified account must pay the fees. the payer must be a tx signer (and thus have signed this field in AuthInfo). setting this field does *not* change the ordering of required signers for the transaction. granter: type: string title: >- if set, the fee payer (either the first signer or the value of the payer field) requests that a fee grant be used to pay fees instead of the fee payer's own balance. If an appropriate fee grant does not exist or the chain does not support fee grants, this will fail tip: description: >- Tip is the optional tip used for transactions fees paid in another denom. This field is ignored if the chain didn't enable tips, i.e. didn't add the `TipDecorator` in its posthandler. Since: cosmos-sdk 0.46 type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of the tip tipper: type: string title: tipper is the address of the account paying for the tip description: |- AuthInfo describes the fee and signer modes that are used to sign a transaction. cosmos.tx.v1beta1.BroadcastMode: type: string enum: - BROADCAST_MODE_UNSPECIFIED - BROADCAST_MODE_BLOCK - BROADCAST_MODE_SYNC - BROADCAST_MODE_ASYNC default: BROADCAST_MODE_UNSPECIFIED description: >- BroadcastMode specifies the broadcast mode for the TxService.Broadcast RPC method. - BROADCAST_MODE_UNSPECIFIED: zero-value for mode ordering - BROADCAST_MODE_BLOCK: DEPRECATED: use BROADCAST_MODE_SYNC instead, BROADCAST_MODE_BLOCK is not supported by the SDK from v0.47.x onwards. - BROADCAST_MODE_SYNC: BROADCAST_MODE_SYNC defines a tx broadcasting mode where the client waits for a CheckTx execution response only. - BROADCAST_MODE_ASYNC: BROADCAST_MODE_ASYNC defines a tx broadcasting mode where the client returns immediately. cosmos.tx.v1beta1.BroadcastTxRequest: type: object properties: tx_bytes: type: string format: byte description: tx_bytes is the raw transaction. mode: type: string enum: - BROADCAST_MODE_UNSPECIFIED - BROADCAST_MODE_BLOCK - BROADCAST_MODE_SYNC - BROADCAST_MODE_ASYNC default: BROADCAST_MODE_UNSPECIFIED description: >- BroadcastMode specifies the broadcast mode for the TxService.Broadcast RPC method. - BROADCAST_MODE_UNSPECIFIED: zero-value for mode ordering - BROADCAST_MODE_BLOCK: DEPRECATED: use BROADCAST_MODE_SYNC instead, BROADCAST_MODE_BLOCK is not supported by the SDK from v0.47.x onwards. - BROADCAST_MODE_SYNC: BROADCAST_MODE_SYNC defines a tx broadcasting mode where the client waits for a CheckTx execution response only. - BROADCAST_MODE_ASYNC: BROADCAST_MODE_ASYNC defines a tx broadcasting mode where the client returns immediately. description: |- BroadcastTxRequest is the request type for the Service.BroadcastTxRequest RPC method. cosmos.tx.v1beta1.BroadcastTxResponse: type: object properties: tx_response: type: object properties: height: type: string format: int64 title: The block height txhash: type: string description: The transaction hash. codespace: type: string title: Namespace for the Code code: type: integer format: int64 description: Response code. data: type: string description: Result bytes, if any. raw_log: type: string description: |- The output of the application's logger (raw string). May be non-deterministic. logs: type: array items: type: object properties: msg_index: type: integer format: int64 log: type: string events: type: array items: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string description: >- Attribute defines an attribute wrapper where the key and value are strings instead of raw bytes. description: >- StringEvent defines en Event object wrapper where all the attributes contain key/value pairs that are strings instead of raw bytes. description: >- Events contains a slice of Event objects that were emitted during some execution. description: >- ABCIMessageLog defines a structure containing an indexed tx ABCI message log. description: >- The output of the application's logger (typed). May be non-deterministic. info: type: string description: Additional information. May be non-deterministic. gas_wanted: type: string format: int64 description: Amount of gas requested for transaction. gas_used: type: string format: int64 description: Amount of gas consumed by transaction. tx: type: object properties: type_url: type: string value: type: string format: byte description: The request transaction bytes. timestamp: type: string description: >- Time of the previous block. For heights > 1, it's the weighted median of the timestamps of the valid votes in the block.LastCommit. For height == 1, it's genesis time. events: type: array items: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string index: type: boolean description: >- EventAttribute is a single key-value pair, associated with an event. description: >- Event allows application developers to attach additional information to ResponseBeginBlock, ResponseEndBlock, ResponseCheckTx and ResponseDeliverTx. Later, transactions may be queried using these events. description: >- Events defines all the events emitted by processing a transaction. Note, these events include those emitted by processing all the messages and those emitted from the ante. Whereas Logs contains the events, with additional metadata, emitted only by processing the messages. Since: cosmos-sdk 0.42.11, 0.44.5, 0.45 description: >- TxResponse defines a structure containing relevant tx data and metadata. The tags are stringified and the log is JSON decoded. description: |- BroadcastTxResponse is the response type for the Service.BroadcastTx method. cosmos.tx.v1beta1.Fee: type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of coins to be paid as a fee gas_limit: type: string format: uint64 title: >- gas_limit is the maximum gas that can be used in transaction processing before an out of gas error occurs payer: type: string description: >- if unset, the first signer is responsible for paying the fees. If set, the specified account must pay the fees. the payer must be a tx signer (and thus have signed this field in AuthInfo). setting this field does *not* change the ordering of required signers for the transaction. granter: type: string title: >- if set, the fee payer (either the first signer or the value of the payer field) requests that a fee grant be used to pay fees instead of the fee payer's own balance. If an appropriate fee grant does not exist or the chain does not support fee grants, this will fail description: >- Fee includes the amount of coins paid in fees and the maximum gas to be used by the transaction. The ratio yields an effective "gasprice", which must be above some miminum to be accepted into the mempool. cosmos.tx.v1beta1.GetBlockWithTxsResponse: type: object properties: txs: type: array items: type: object properties: body: title: body is the processable content of the transaction type: object properties: messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- messages is a list of messages to be executed. The required signers of those messages define the number and order of elements in AuthInfo's signer_infos and Tx's signatures. Each required signer address is added to the list only the first time it occurs. By convention, the first required signer (usually from the first message) is referred to as the primary signer and pays the fee for the whole transaction. memo: type: string description: >- memo is any arbitrary note/comment to be added to the transaction. WARNING: in clients, any publicly exposed text should not be called memo, but should be called `note` instead (see https://github.com/cosmos/cosmos-sdk/issues/9122). timeout_height: type: string format: uint64 title: >- timeout is the block height after which this transaction will not be processed by the chain extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, the transaction will be rejected non_critical_extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, they will be ignored description: TxBody is the body of a transaction that all signers sign over. auth_info: title: >- auth_info is the authorization related content of the transaction, specifically signers, signer modes and fee type: object properties: signer_infos: type: array items: type: object properties: public_key: type: object properties: type_url: type: string value: type: string format: byte description: >- public_key is the public key of the signer. It is optional for accounts that already exist in state. If unset, the verifier can use the required \ signer address for this position and lookup the public key. mode_info: title: >- mode_info describes the signing mode of the signer and is a nested structure to support nested multisig pubkey's type: object properties: single: title: single represents a single signer type: object properties: mode: title: mode is the signing mode of the single signer type: string enum: - SIGN_MODE_UNSPECIFIED - SIGN_MODE_DIRECT - SIGN_MODE_TEXTUAL - SIGN_MODE_DIRECT_AUX - SIGN_MODE_LEGACY_AMINO_JSON - SIGN_MODE_EIP_191 default: SIGN_MODE_UNSPECIFIED description: >- SignMode represents a signing mode with its own security guarantees. This enum should be considered a registry of all known sign modes in the Cosmos ecosystem. Apps are not expected to support all known sign modes. Apps that would like to support custom sign modes are encouraged to open a small PR against this file to add a new case to this SignMode enum describing their sign mode so that different apps have a consistent version of this enum. - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be rejected. - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is verified with raw bytes from Tx. - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some human-readable textual representation on top of the binary representation from SIGN_MODE_DIRECT. It is currently not supported. - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses SignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not require signers signing over other signers' `signer_info`. It also allows for adding Tips in transactions. Since: cosmos-sdk 0.46 - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses Amino JSON and will be removed in the future. - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos SDK. Ref: https://eips.ethereum.org/EIPS/eip-191 Currently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant, but is not implemented on the SDK by default. To enable EIP-191, you need to pass a custom `TxConfig` that has an implementation of `SignModeHandler` for EIP-191. The SDK may decide to fully support EIP-191 in the future. Since: cosmos-sdk 0.45.2 multi: title: multi represents a nested multisig signer type: object properties: bitarray: title: >- bitarray specifies which keys within the multisig are signing type: object properties: extra_bits_stored: type: integer format: int64 elems: type: string format: byte description: >- CompactBitArray is an implementation of a space efficient bit array. This is used to ensure that the encoded data takes up a minimal amount of space after proto encoding. This is not thread safe, and is not intended for concurrent usage. mode_infos: type: array items: {} title: >- mode_infos is the corresponding modes of the signers of the multisig which could include nested multisig public keys description: >- ModeInfo describes the signing mode of a single or nested multisig signer. sequence: type: string format: uint64 description: >- sequence is the sequence of the account, which describes the number of committed transactions signed by a given address. It is used to prevent replay attacks. description: >- SignerInfo describes the public key and signing mode of a single top-level signer. description: >- signer_infos defines the signing modes for the required signers. The number and order of elements must match the required signers from TxBody's messages. The first element is the primary signer and the one which pays the fee. fee: description: >- Fee is the fee and gas limit for the transaction. The first signer is the primary signer and the one which pays the fee. The fee can be calculated based on the cost of evaluating the body and doing signature verification of the signers. This can be estimated via simulation. type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of coins to be paid as a fee gas_limit: type: string format: uint64 title: >- gas_limit is the maximum gas that can be used in transaction processing before an out of gas error occurs payer: type: string description: >- if unset, the first signer is responsible for paying the fees. If set, the specified account must pay the fees. the payer must be a tx signer (and thus have signed this field in AuthInfo). setting this field does *not* change the ordering of required signers for the transaction. granter: type: string title: >- if set, the fee payer (either the first signer or the value of the payer field) requests that a fee grant be used to pay fees instead of the fee payer's own balance. If an appropriate fee grant does not exist or the chain does not support fee grants, this will fail tip: description: >- Tip is the optional tip used for transactions fees paid in another denom. This field is ignored if the chain didn't enable tips, i.e. didn't add the `TipDecorator` in its posthandler. Since: cosmos-sdk 0.46 type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of the tip tipper: type: string title: tipper is the address of the account paying for the tip description: >- AuthInfo describes the fee and signer modes that are used to sign a transaction. signatures: type: array items: type: string format: byte description: >- signatures is a list of signatures that matches the length and order of AuthInfo's signer_infos to allow connecting signature meta information like public key and signing mode by position. description: Tx is the standard type used for broadcasting transactions. description: txs are the transactions in the block. block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID block: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. data: type: object properties: txs: type: array items: type: string format: byte description: >- Txs that will be applied by state @ block.Height+1. NOTE: not all txs here are valid. We're just agreeing on the order first. This means that block.AppHash does not include these txs. title: Data contains the set of transactions included in the block evidence: type: object properties: evidence: type: array items: type: object properties: duplicate_vote_evidence: type: object properties: vote_a: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. vote_b: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. total_voting_power: type: string format: int64 validator_power: type: string format: int64 timestamp: type: string format: date-time description: >- DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes. light_client_attack_evidence: type: object properties: conflicting_block: type: object properties: signed_header: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: >- hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: >- Header defines the structure of a block header. commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: >- BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: >- CommitSig is a part of the Vote included in a Commit. description: >- Commit contains the evidence that a block was committed by a set of validators. validator_set: type: object properties: validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 proposer: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 common_height: type: string format: int64 byzantine_validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 timestamp: type: string format: date-time description: >- LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client. last_commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: >- Commit contains the evidence that a block was committed by a set of validators. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- GetBlockWithTxsResponse is the response type for the Service.GetBlockWithTxs method. Since: cosmos-sdk 0.45.2 cosmos.tx.v1beta1.GetTxResponse: type: object properties: tx: type: object properties: body: title: body is the processable content of the transaction type: object properties: messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- messages is a list of messages to be executed. The required signers of those messages define the number and order of elements in AuthInfo's signer_infos and Tx's signatures. Each required signer address is added to the list only the first time it occurs. By convention, the first required signer (usually from the first message) is referred to as the primary signer and pays the fee for the whole transaction. memo: type: string description: >- memo is any arbitrary note/comment to be added to the transaction. WARNING: in clients, any publicly exposed text should not be called memo, but should be called `note` instead (see https://github.com/cosmos/cosmos-sdk/issues/9122). timeout_height: type: string format: uint64 title: >- timeout is the block height after which this transaction will not be processed by the chain extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, the transaction will be rejected non_critical_extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, they will be ignored description: TxBody is the body of a transaction that all signers sign over. auth_info: title: |- auth_info is the authorization related content of the transaction, specifically signers, signer modes and fee type: object properties: signer_infos: type: array items: type: object properties: public_key: type: object properties: type_url: type: string value: type: string format: byte description: >- public_key is the public key of the signer. It is optional for accounts that already exist in state. If unset, the verifier can use the required \ signer address for this position and lookup the public key. mode_info: title: >- mode_info describes the signing mode of the signer and is a nested structure to support nested multisig pubkey's type: object properties: single: title: single represents a single signer type: object properties: mode: title: mode is the signing mode of the single signer type: string enum: - SIGN_MODE_UNSPECIFIED - SIGN_MODE_DIRECT - SIGN_MODE_TEXTUAL - SIGN_MODE_DIRECT_AUX - SIGN_MODE_LEGACY_AMINO_JSON - SIGN_MODE_EIP_191 default: SIGN_MODE_UNSPECIFIED description: >- SignMode represents a signing mode with its own security guarantees. This enum should be considered a registry of all known sign modes in the Cosmos ecosystem. Apps are not expected to support all known sign modes. Apps that would like to support custom sign modes are encouraged to open a small PR against this file to add a new case to this SignMode enum describing their sign mode so that different apps have a consistent version of this enum. - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be rejected. - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is verified with raw bytes from Tx. - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some human-readable textual representation on top of the binary representation from SIGN_MODE_DIRECT. It is currently not supported. - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses SignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not require signers signing over other signers' `signer_info`. It also allows for adding Tips in transactions. Since: cosmos-sdk 0.46 - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses Amino JSON and will be removed in the future. - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos SDK. Ref: https://eips.ethereum.org/EIPS/eip-191 Currently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant, but is not implemented on the SDK by default. To enable EIP-191, you need to pass a custom `TxConfig` that has an implementation of `SignModeHandler` for EIP-191. The SDK may decide to fully support EIP-191 in the future. Since: cosmos-sdk 0.45.2 multi: title: multi represents a nested multisig signer type: object properties: bitarray: title: >- bitarray specifies which keys within the multisig are signing type: object properties: extra_bits_stored: type: integer format: int64 elems: type: string format: byte description: >- CompactBitArray is an implementation of a space efficient bit array. This is used to ensure that the encoded data takes up a minimal amount of space after proto encoding. This is not thread safe, and is not intended for concurrent usage. mode_infos: type: array items: {} title: >- mode_infos is the corresponding modes of the signers of the multisig which could include nested multisig public keys description: >- ModeInfo describes the signing mode of a single or nested multisig signer. sequence: type: string format: uint64 description: >- sequence is the sequence of the account, which describes the number of committed transactions signed by a given address. It is used to prevent replay attacks. description: >- SignerInfo describes the public key and signing mode of a single top-level signer. description: >- signer_infos defines the signing modes for the required signers. The number and order of elements must match the required signers from TxBody's messages. The first element is the primary signer and the one which pays the fee. fee: description: >- Fee is the fee and gas limit for the transaction. The first signer is the primary signer and the one which pays the fee. The fee can be calculated based on the cost of evaluating the body and doing signature verification of the signers. This can be estimated via simulation. type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of coins to be paid as a fee gas_limit: type: string format: uint64 title: >- gas_limit is the maximum gas that can be used in transaction processing before an out of gas error occurs payer: type: string description: >- if unset, the first signer is responsible for paying the fees. If set, the specified account must pay the fees. the payer must be a tx signer (and thus have signed this field in AuthInfo). setting this field does *not* change the ordering of required signers for the transaction. granter: type: string title: >- if set, the fee payer (either the first signer or the value of the payer field) requests that a fee grant be used to pay fees instead of the fee payer's own balance. If an appropriate fee grant does not exist or the chain does not support fee grants, this will fail tip: description: >- Tip is the optional tip used for transactions fees paid in another denom. This field is ignored if the chain didn't enable tips, i.e. didn't add the `TipDecorator` in its posthandler. Since: cosmos-sdk 0.46 type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of the tip tipper: type: string title: tipper is the address of the account paying for the tip description: >- AuthInfo describes the fee and signer modes that are used to sign a transaction. signatures: type: array items: type: string format: byte description: >- signatures is a list of signatures that matches the length and order of AuthInfo's signer_infos to allow connecting signature meta information like public key and signing mode by position. description: Tx is the standard type used for broadcasting transactions. tx_response: type: object properties: height: type: string format: int64 title: The block height txhash: type: string description: The transaction hash. codespace: type: string title: Namespace for the Code code: type: integer format: int64 description: Response code. data: type: string description: Result bytes, if any. raw_log: type: string description: |- The output of the application's logger (raw string). May be non-deterministic. logs: type: array items: type: object properties: msg_index: type: integer format: int64 log: type: string events: type: array items: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string description: >- Attribute defines an attribute wrapper where the key and value are strings instead of raw bytes. description: >- StringEvent defines en Event object wrapper where all the attributes contain key/value pairs that are strings instead of raw bytes. description: >- Events contains a slice of Event objects that were emitted during some execution. description: >- ABCIMessageLog defines a structure containing an indexed tx ABCI message log. description: >- The output of the application's logger (typed). May be non-deterministic. info: type: string description: Additional information. May be non-deterministic. gas_wanted: type: string format: int64 description: Amount of gas requested for transaction. gas_used: type: string format: int64 description: Amount of gas consumed by transaction. tx: type: object properties: type_url: type: string value: type: string format: byte description: The request transaction bytes. timestamp: type: string description: >- Time of the previous block. For heights > 1, it's the weighted median of the timestamps of the valid votes in the block.LastCommit. For height == 1, it's genesis time. events: type: array items: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string index: type: boolean description: >- EventAttribute is a single key-value pair, associated with an event. description: >- Event allows application developers to attach additional information to ResponseBeginBlock, ResponseEndBlock, ResponseCheckTx and ResponseDeliverTx. Later, transactions may be queried using these events. description: >- Events defines all the events emitted by processing a transaction. Note, these events include those emitted by processing all the messages and those emitted from the ante. Whereas Logs contains the events, with additional metadata, emitted only by processing the messages. Since: cosmos-sdk 0.42.11, 0.44.5, 0.45 description: >- TxResponse defines a structure containing relevant tx data and metadata. The tags are stringified and the log is JSON decoded. description: GetTxResponse is the response type for the Service.GetTx method. cosmos.tx.v1beta1.GetTxsEventResponse: type: object properties: txs: type: array items: type: object properties: body: title: body is the processable content of the transaction type: object properties: messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- messages is a list of messages to be executed. The required signers of those messages define the number and order of elements in AuthInfo's signer_infos and Tx's signatures. Each required signer address is added to the list only the first time it occurs. By convention, the first required signer (usually from the first message) is referred to as the primary signer and pays the fee for the whole transaction. memo: type: string description: >- memo is any arbitrary note/comment to be added to the transaction. WARNING: in clients, any publicly exposed text should not be called memo, but should be called `note` instead (see https://github.com/cosmos/cosmos-sdk/issues/9122). timeout_height: type: string format: uint64 title: >- timeout is the block height after which this transaction will not be processed by the chain extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, the transaction will be rejected non_critical_extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, they will be ignored description: TxBody is the body of a transaction that all signers sign over. auth_info: title: >- auth_info is the authorization related content of the transaction, specifically signers, signer modes and fee type: object properties: signer_infos: type: array items: type: object properties: public_key: type: object properties: type_url: type: string value: type: string format: byte description: >- public_key is the public key of the signer. It is optional for accounts that already exist in state. If unset, the verifier can use the required \ signer address for this position and lookup the public key. mode_info: title: >- mode_info describes the signing mode of the signer and is a nested structure to support nested multisig pubkey's type: object properties: single: title: single represents a single signer type: object properties: mode: title: mode is the signing mode of the single signer type: string enum: - SIGN_MODE_UNSPECIFIED - SIGN_MODE_DIRECT - SIGN_MODE_TEXTUAL - SIGN_MODE_DIRECT_AUX - SIGN_MODE_LEGACY_AMINO_JSON - SIGN_MODE_EIP_191 default: SIGN_MODE_UNSPECIFIED description: >- SignMode represents a signing mode with its own security guarantees. This enum should be considered a registry of all known sign modes in the Cosmos ecosystem. Apps are not expected to support all known sign modes. Apps that would like to support custom sign modes are encouraged to open a small PR against this file to add a new case to this SignMode enum describing their sign mode so that different apps have a consistent version of this enum. - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be rejected. - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is verified with raw bytes from Tx. - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some human-readable textual representation on top of the binary representation from SIGN_MODE_DIRECT. It is currently not supported. - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses SignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not require signers signing over other signers' `signer_info`. It also allows for adding Tips in transactions. Since: cosmos-sdk 0.46 - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses Amino JSON and will be removed in the future. - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos SDK. Ref: https://eips.ethereum.org/EIPS/eip-191 Currently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant, but is not implemented on the SDK by default. To enable EIP-191, you need to pass a custom `TxConfig` that has an implementation of `SignModeHandler` for EIP-191. The SDK may decide to fully support EIP-191 in the future. Since: cosmos-sdk 0.45.2 multi: title: multi represents a nested multisig signer type: object properties: bitarray: title: >- bitarray specifies which keys within the multisig are signing type: object properties: extra_bits_stored: type: integer format: int64 elems: type: string format: byte description: >- CompactBitArray is an implementation of a space efficient bit array. This is used to ensure that the encoded data takes up a minimal amount of space after proto encoding. This is not thread safe, and is not intended for concurrent usage. mode_infos: type: array items: {} title: >- mode_infos is the corresponding modes of the signers of the multisig which could include nested multisig public keys description: >- ModeInfo describes the signing mode of a single or nested multisig signer. sequence: type: string format: uint64 description: >- sequence is the sequence of the account, which describes the number of committed transactions signed by a given address. It is used to prevent replay attacks. description: >- SignerInfo describes the public key and signing mode of a single top-level signer. description: >- signer_infos defines the signing modes for the required signers. The number and order of elements must match the required signers from TxBody's messages. The first element is the primary signer and the one which pays the fee. fee: description: >- Fee is the fee and gas limit for the transaction. The first signer is the primary signer and the one which pays the fee. The fee can be calculated based on the cost of evaluating the body and doing signature verification of the signers. This can be estimated via simulation. type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of coins to be paid as a fee gas_limit: type: string format: uint64 title: >- gas_limit is the maximum gas that can be used in transaction processing before an out of gas error occurs payer: type: string description: >- if unset, the first signer is responsible for paying the fees. If set, the specified account must pay the fees. the payer must be a tx signer (and thus have signed this field in AuthInfo). setting this field does *not* change the ordering of required signers for the transaction. granter: type: string title: >- if set, the fee payer (either the first signer or the value of the payer field) requests that a fee grant be used to pay fees instead of the fee payer's own balance. If an appropriate fee grant does not exist or the chain does not support fee grants, this will fail tip: description: >- Tip is the optional tip used for transactions fees paid in another denom. This field is ignored if the chain didn't enable tips, i.e. didn't add the `TipDecorator` in its posthandler. Since: cosmos-sdk 0.46 type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of the tip tipper: type: string title: tipper is the address of the account paying for the tip description: >- AuthInfo describes the fee and signer modes that are used to sign a transaction. signatures: type: array items: type: string format: byte description: >- signatures is a list of signatures that matches the length and order of AuthInfo's signer_infos to allow connecting signature meta information like public key and signing mode by position. description: Tx is the standard type used for broadcasting transactions. description: txs is the list of queried transactions. tx_responses: type: array items: type: object properties: height: type: string format: int64 title: The block height txhash: type: string description: The transaction hash. codespace: type: string title: Namespace for the Code code: type: integer format: int64 description: Response code. data: type: string description: Result bytes, if any. raw_log: type: string description: |- The output of the application's logger (raw string). May be non-deterministic. logs: type: array items: type: object properties: msg_index: type: integer format: int64 log: type: string events: type: array items: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string description: >- Attribute defines an attribute wrapper where the key and value are strings instead of raw bytes. description: >- StringEvent defines en Event object wrapper where all the attributes contain key/value pairs that are strings instead of raw bytes. description: >- Events contains a slice of Event objects that were emitted during some execution. description: >- ABCIMessageLog defines a structure containing an indexed tx ABCI message log. description: >- The output of the application's logger (typed). May be non-deterministic. info: type: string description: Additional information. May be non-deterministic. gas_wanted: type: string format: int64 description: Amount of gas requested for transaction. gas_used: type: string format: int64 description: Amount of gas consumed by transaction. tx: type: object properties: type_url: type: string value: type: string format: byte description: The request transaction bytes. timestamp: type: string description: >- Time of the previous block. For heights > 1, it's the weighted median of the timestamps of the valid votes in the block.LastCommit. For height == 1, it's genesis time. events: type: array items: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string index: type: boolean description: >- EventAttribute is a single key-value pair, associated with an event. description: >- Event allows application developers to attach additional information to ResponseBeginBlock, ResponseEndBlock, ResponseCheckTx and ResponseDeliverTx. Later, transactions may be queried using these events. description: >- Events defines all the events emitted by processing a transaction. Note, these events include those emitted by processing all the messages and those emitted from the ante. Whereas Logs contains the events, with additional metadata, emitted only by processing the messages. Since: cosmos-sdk 0.42.11, 0.44.5, 0.45 description: >- TxResponse defines a structure containing relevant tx data and metadata. The tags are stringified and the log is JSON decoded. description: tx_responses is the list of queried TxResponses. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } total: type: string format: uint64 title: total is total number of results available description: |- GetTxsEventResponse is the response type for the Service.TxsByEvents RPC method. cosmos.tx.v1beta1.ModeInfo: type: object properties: single: title: single represents a single signer type: object properties: mode: title: mode is the signing mode of the single signer type: string enum: - SIGN_MODE_UNSPECIFIED - SIGN_MODE_DIRECT - SIGN_MODE_TEXTUAL - SIGN_MODE_DIRECT_AUX - SIGN_MODE_LEGACY_AMINO_JSON - SIGN_MODE_EIP_191 default: SIGN_MODE_UNSPECIFIED description: >- SignMode represents a signing mode with its own security guarantees. This enum should be considered a registry of all known sign modes in the Cosmos ecosystem. Apps are not expected to support all known sign modes. Apps that would like to support custom sign modes are encouraged to open a small PR against this file to add a new case to this SignMode enum describing their sign mode so that different apps have a consistent version of this enum. - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be rejected. - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is verified with raw bytes from Tx. - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some human-readable textual representation on top of the binary representation from SIGN_MODE_DIRECT. It is currently not supported. - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses SignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not require signers signing over other signers' `signer_info`. It also allows for adding Tips in transactions. Since: cosmos-sdk 0.46 - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses Amino JSON and will be removed in the future. - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos SDK. Ref: https://eips.ethereum.org/EIPS/eip-191 Currently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant, but is not implemented on the SDK by default. To enable EIP-191, you need to pass a custom `TxConfig` that has an implementation of `SignModeHandler` for EIP-191. The SDK may decide to fully support EIP-191 in the future. Since: cosmos-sdk 0.45.2 multi: title: multi represents a nested multisig signer type: object properties: bitarray: title: bitarray specifies which keys within the multisig are signing type: object properties: extra_bits_stored: type: integer format: int64 elems: type: string format: byte description: >- CompactBitArray is an implementation of a space efficient bit array. This is used to ensure that the encoded data takes up a minimal amount of space after proto encoding. This is not thread safe, and is not intended for concurrent usage. mode_infos: type: array items: {} title: >- mode_infos is the corresponding modes of the signers of the multisig which could include nested multisig public keys description: ModeInfo describes the signing mode of a single or nested multisig signer. cosmos.tx.v1beta1.ModeInfo.Multi: type: object properties: bitarray: title: bitarray specifies which keys within the multisig are signing type: object properties: extra_bits_stored: type: integer format: int64 elems: type: string format: byte description: >- CompactBitArray is an implementation of a space efficient bit array. This is used to ensure that the encoded data takes up a minimal amount of space after proto encoding. This is not thread safe, and is not intended for concurrent usage. mode_infos: type: array items: {} title: |- mode_infos is the corresponding modes of the signers of the multisig which could include nested multisig public keys title: Multi is the mode info for a multisig public key cosmos.tx.v1beta1.ModeInfo.Single: type: object properties: mode: title: mode is the signing mode of the single signer type: string enum: - SIGN_MODE_UNSPECIFIED - SIGN_MODE_DIRECT - SIGN_MODE_TEXTUAL - SIGN_MODE_DIRECT_AUX - SIGN_MODE_LEGACY_AMINO_JSON - SIGN_MODE_EIP_191 default: SIGN_MODE_UNSPECIFIED description: >- SignMode represents a signing mode with its own security guarantees. This enum should be considered a registry of all known sign modes in the Cosmos ecosystem. Apps are not expected to support all known sign modes. Apps that would like to support custom sign modes are encouraged to open a small PR against this file to add a new case to this SignMode enum describing their sign mode so that different apps have a consistent version of this enum. - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be rejected. - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is verified with raw bytes from Tx. - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some human-readable textual representation on top of the binary representation from SIGN_MODE_DIRECT. It is currently not supported. - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses SignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not require signers signing over other signers' `signer_info`. It also allows for adding Tips in transactions. Since: cosmos-sdk 0.46 - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses Amino JSON and will be removed in the future. - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos SDK. Ref: https://eips.ethereum.org/EIPS/eip-191 Currently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant, but is not implemented on the SDK by default. To enable EIP-191, you need to pass a custom `TxConfig` that has an implementation of `SignModeHandler` for EIP-191. The SDK may decide to fully support EIP-191 in the future. Since: cosmos-sdk 0.45.2 title: |- Single is the mode info for a single signer. It is structured as a message to allow for additional fields such as locale for SIGN_MODE_TEXTUAL in the future cosmos.tx.v1beta1.OrderBy: type: string enum: - ORDER_BY_UNSPECIFIED - ORDER_BY_ASC - ORDER_BY_DESC default: ORDER_BY_UNSPECIFIED description: >- - ORDER_BY_UNSPECIFIED: ORDER_BY_UNSPECIFIED specifies an unknown sorting order. OrderBy defaults to ASC in this case. - ORDER_BY_ASC: ORDER_BY_ASC defines ascending order - ORDER_BY_DESC: ORDER_BY_DESC defines descending order title: OrderBy defines the sorting order cosmos.tx.v1beta1.SignerInfo: type: object properties: public_key: type: object properties: type_url: type: string value: type: string format: byte description: >- public_key is the public key of the signer. It is optional for accounts that already exist in state. If unset, the verifier can use the required \ signer address for this position and lookup the public key. mode_info: title: |- mode_info describes the signing mode of the signer and is a nested structure to support nested multisig pubkey's type: object properties: single: title: single represents a single signer type: object properties: mode: title: mode is the signing mode of the single signer type: string enum: - SIGN_MODE_UNSPECIFIED - SIGN_MODE_DIRECT - SIGN_MODE_TEXTUAL - SIGN_MODE_DIRECT_AUX - SIGN_MODE_LEGACY_AMINO_JSON - SIGN_MODE_EIP_191 default: SIGN_MODE_UNSPECIFIED description: >- SignMode represents a signing mode with its own security guarantees. This enum should be considered a registry of all known sign modes in the Cosmos ecosystem. Apps are not expected to support all known sign modes. Apps that would like to support custom sign modes are encouraged to open a small PR against this file to add a new case to this SignMode enum describing their sign mode so that different apps have a consistent version of this enum. - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be rejected. - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is verified with raw bytes from Tx. - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some human-readable textual representation on top of the binary representation from SIGN_MODE_DIRECT. It is currently not supported. - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses SignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not require signers signing over other signers' `signer_info`. It also allows for adding Tips in transactions. Since: cosmos-sdk 0.46 - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses Amino JSON and will be removed in the future. - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos SDK. Ref: https://eips.ethereum.org/EIPS/eip-191 Currently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant, but is not implemented on the SDK by default. To enable EIP-191, you need to pass a custom `TxConfig` that has an implementation of `SignModeHandler` for EIP-191. The SDK may decide to fully support EIP-191 in the future. Since: cosmos-sdk 0.45.2 multi: title: multi represents a nested multisig signer type: object properties: bitarray: title: bitarray specifies which keys within the multisig are signing type: object properties: extra_bits_stored: type: integer format: int64 elems: type: string format: byte description: >- CompactBitArray is an implementation of a space efficient bit array. This is used to ensure that the encoded data takes up a minimal amount of space after proto encoding. This is not thread safe, and is not intended for concurrent usage. mode_infos: type: array items: {} title: >- mode_infos is the corresponding modes of the signers of the multisig which could include nested multisig public keys description: >- ModeInfo describes the signing mode of a single or nested multisig signer. sequence: type: string format: uint64 description: >- sequence is the sequence of the account, which describes the number of committed transactions signed by a given address. It is used to prevent replay attacks. description: |- SignerInfo describes the public key and signing mode of a single top-level signer. cosmos.tx.v1beta1.SimulateRequest: type: object properties: tx: description: |- tx is the transaction to simulate. Deprecated. Send raw tx bytes instead. type: object properties: body: title: body is the processable content of the transaction type: object properties: messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- messages is a list of messages to be executed. The required signers of those messages define the number and order of elements in AuthInfo's signer_infos and Tx's signatures. Each required signer address is added to the list only the first time it occurs. By convention, the first required signer (usually from the first message) is referred to as the primary signer and pays the fee for the whole transaction. memo: type: string description: >- memo is any arbitrary note/comment to be added to the transaction. WARNING: in clients, any publicly exposed text should not be called memo, but should be called `note` instead (see https://github.com/cosmos/cosmos-sdk/issues/9122). timeout_height: type: string format: uint64 title: >- timeout is the block height after which this transaction will not be processed by the chain extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, the transaction will be rejected non_critical_extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, they will be ignored description: TxBody is the body of a transaction that all signers sign over. auth_info: title: |- auth_info is the authorization related content of the transaction, specifically signers, signer modes and fee type: object properties: signer_infos: type: array items: type: object properties: public_key: type: object properties: type_url: type: string value: type: string format: byte description: >- public_key is the public key of the signer. It is optional for accounts that already exist in state. If unset, the verifier can use the required \ signer address for this position and lookup the public key. mode_info: title: >- mode_info describes the signing mode of the signer and is a nested structure to support nested multisig pubkey's type: object properties: single: title: single represents a single signer type: object properties: mode: title: mode is the signing mode of the single signer type: string enum: - SIGN_MODE_UNSPECIFIED - SIGN_MODE_DIRECT - SIGN_MODE_TEXTUAL - SIGN_MODE_DIRECT_AUX - SIGN_MODE_LEGACY_AMINO_JSON - SIGN_MODE_EIP_191 default: SIGN_MODE_UNSPECIFIED description: >- SignMode represents a signing mode with its own security guarantees. This enum should be considered a registry of all known sign modes in the Cosmos ecosystem. Apps are not expected to support all known sign modes. Apps that would like to support custom sign modes are encouraged to open a small PR against this file to add a new case to this SignMode enum describing their sign mode so that different apps have a consistent version of this enum. - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be rejected. - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is verified with raw bytes from Tx. - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some human-readable textual representation on top of the binary representation from SIGN_MODE_DIRECT. It is currently not supported. - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses SignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not require signers signing over other signers' `signer_info`. It also allows for adding Tips in transactions. Since: cosmos-sdk 0.46 - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses Amino JSON and will be removed in the future. - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos SDK. Ref: https://eips.ethereum.org/EIPS/eip-191 Currently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant, but is not implemented on the SDK by default. To enable EIP-191, you need to pass a custom `TxConfig` that has an implementation of `SignModeHandler` for EIP-191. The SDK may decide to fully support EIP-191 in the future. Since: cosmos-sdk 0.45.2 multi: title: multi represents a nested multisig signer type: object properties: bitarray: title: >- bitarray specifies which keys within the multisig are signing type: object properties: extra_bits_stored: type: integer format: int64 elems: type: string format: byte description: >- CompactBitArray is an implementation of a space efficient bit array. This is used to ensure that the encoded data takes up a minimal amount of space after proto encoding. This is not thread safe, and is not intended for concurrent usage. mode_infos: type: array items: {} title: >- mode_infos is the corresponding modes of the signers of the multisig which could include nested multisig public keys description: >- ModeInfo describes the signing mode of a single or nested multisig signer. sequence: type: string format: uint64 description: >- sequence is the sequence of the account, which describes the number of committed transactions signed by a given address. It is used to prevent replay attacks. description: >- SignerInfo describes the public key and signing mode of a single top-level signer. description: >- signer_infos defines the signing modes for the required signers. The number and order of elements must match the required signers from TxBody's messages. The first element is the primary signer and the one which pays the fee. fee: description: >- Fee is the fee and gas limit for the transaction. The first signer is the primary signer and the one which pays the fee. The fee can be calculated based on the cost of evaluating the body and doing signature verification of the signers. This can be estimated via simulation. type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of coins to be paid as a fee gas_limit: type: string format: uint64 title: >- gas_limit is the maximum gas that can be used in transaction processing before an out of gas error occurs payer: type: string description: >- if unset, the first signer is responsible for paying the fees. If set, the specified account must pay the fees. the payer must be a tx signer (and thus have signed this field in AuthInfo). setting this field does *not* change the ordering of required signers for the transaction. granter: type: string title: >- if set, the fee payer (either the first signer or the value of the payer field) requests that a fee grant be used to pay fees instead of the fee payer's own balance. If an appropriate fee grant does not exist or the chain does not support fee grants, this will fail tip: description: >- Tip is the optional tip used for transactions fees paid in another denom. This field is ignored if the chain didn't enable tips, i.e. didn't add the `TipDecorator` in its posthandler. Since: cosmos-sdk 0.46 type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of the tip tipper: type: string title: tipper is the address of the account paying for the tip description: >- AuthInfo describes the fee and signer modes that are used to sign a transaction. signatures: type: array items: type: string format: byte description: >- signatures is a list of signatures that matches the length and order of AuthInfo's signer_infos to allow connecting signature meta information like public key and signing mode by position. tx_bytes: type: string format: byte description: |- tx_bytes is the raw transaction. Since: cosmos-sdk 0.43 description: |- SimulateRequest is the request type for the Service.Simulate RPC method. cosmos.tx.v1beta1.SimulateResponse: type: object properties: gas_info: description: gas_info is the information about gas used in the simulation. type: object properties: gas_wanted: type: string format: uint64 description: >- GasWanted is the maximum units of work we allow this tx to perform. gas_used: type: string format: uint64 description: GasUsed is the amount of gas actually consumed. result: description: result is the result of the simulation. type: object properties: data: type: string format: byte description: >- Data is any data returned from message or handler execution. It MUST be length prefixed in order to separate data from multiple message executions. Deprecated. This field is still populated, but prefer msg_response instead because it also contains the Msg response typeURL. log: type: string description: >- Log contains the log information from message or handler execution. events: type: array items: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string index: type: boolean description: >- EventAttribute is a single key-value pair, associated with an event. description: >- Event allows application developers to attach additional information to ResponseBeginBlock, ResponseEndBlock, ResponseCheckTx and ResponseDeliverTx. Later, transactions may be queried using these events. description: >- Events contains a slice of Event objects that were emitted during message or handler execution. msg_responses: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- msg_responses contains the Msg handler responses type packed in Anys. Since: cosmos-sdk 0.46 description: |- SimulateResponse is the response type for the Service.SimulateRPC method. cosmos.tx.v1beta1.Tip: type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of the tip tipper: type: string title: tipper is the address of the account paying for the tip description: |- Tip is the tip used for meta-transactions. Since: cosmos-sdk 0.46 cosmos.tx.v1beta1.Tx: type: object properties: body: title: body is the processable content of the transaction type: object properties: messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- messages is a list of messages to be executed. The required signers of those messages define the number and order of elements in AuthInfo's signer_infos and Tx's signatures. Each required signer address is added to the list only the first time it occurs. By convention, the first required signer (usually from the first message) is referred to as the primary signer and pays the fee for the whole transaction. memo: type: string description: >- memo is any arbitrary note/comment to be added to the transaction. WARNING: in clients, any publicly exposed text should not be called memo, but should be called `note` instead (see https://github.com/cosmos/cosmos-sdk/issues/9122). timeout_height: type: string format: uint64 title: |- timeout is the block height after which this transaction will not be processed by the chain extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, the transaction will be rejected non_critical_extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, they will be ignored description: TxBody is the body of a transaction that all signers sign over. auth_info: title: |- auth_info is the authorization related content of the transaction, specifically signers, signer modes and fee type: object properties: signer_infos: type: array items: type: object properties: public_key: type: object properties: type_url: type: string value: type: string format: byte description: >- public_key is the public key of the signer. It is optional for accounts that already exist in state. If unset, the verifier can use the required \ signer address for this position and lookup the public key. mode_info: title: >- mode_info describes the signing mode of the signer and is a nested structure to support nested multisig pubkey's type: object properties: single: title: single represents a single signer type: object properties: mode: title: mode is the signing mode of the single signer type: string enum: - SIGN_MODE_UNSPECIFIED - SIGN_MODE_DIRECT - SIGN_MODE_TEXTUAL - SIGN_MODE_DIRECT_AUX - SIGN_MODE_LEGACY_AMINO_JSON - SIGN_MODE_EIP_191 default: SIGN_MODE_UNSPECIFIED description: >- SignMode represents a signing mode with its own security guarantees. This enum should be considered a registry of all known sign modes in the Cosmos ecosystem. Apps are not expected to support all known sign modes. Apps that would like to support custom sign modes are encouraged to open a small PR against this file to add a new case to this SignMode enum describing their sign mode so that different apps have a consistent version of this enum. - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be rejected. - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is verified with raw bytes from Tx. - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some human-readable textual representation on top of the binary representation from SIGN_MODE_DIRECT. It is currently not supported. - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses SignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not require signers signing over other signers' `signer_info`. It also allows for adding Tips in transactions. Since: cosmos-sdk 0.46 - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses Amino JSON and will be removed in the future. - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos SDK. Ref: https://eips.ethereum.org/EIPS/eip-191 Currently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant, but is not implemented on the SDK by default. To enable EIP-191, you need to pass a custom `TxConfig` that has an implementation of `SignModeHandler` for EIP-191. The SDK may decide to fully support EIP-191 in the future. Since: cosmos-sdk 0.45.2 multi: title: multi represents a nested multisig signer type: object properties: bitarray: title: >- bitarray specifies which keys within the multisig are signing type: object properties: extra_bits_stored: type: integer format: int64 elems: type: string format: byte description: >- CompactBitArray is an implementation of a space efficient bit array. This is used to ensure that the encoded data takes up a minimal amount of space after proto encoding. This is not thread safe, and is not intended for concurrent usage. mode_infos: type: array items: {} title: >- mode_infos is the corresponding modes of the signers of the multisig which could include nested multisig public keys description: >- ModeInfo describes the signing mode of a single or nested multisig signer. sequence: type: string format: uint64 description: >- sequence is the sequence of the account, which describes the number of committed transactions signed by a given address. It is used to prevent replay attacks. description: >- SignerInfo describes the public key and signing mode of a single top-level signer. description: >- signer_infos defines the signing modes for the required signers. The number and order of elements must match the required signers from TxBody's messages. The first element is the primary signer and the one which pays the fee. fee: description: >- Fee is the fee and gas limit for the transaction. The first signer is the primary signer and the one which pays the fee. The fee can be calculated based on the cost of evaluating the body and doing signature verification of the signers. This can be estimated via simulation. type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of coins to be paid as a fee gas_limit: type: string format: uint64 title: >- gas_limit is the maximum gas that can be used in transaction processing before an out of gas error occurs payer: type: string description: >- if unset, the first signer is responsible for paying the fees. If set, the specified account must pay the fees. the payer must be a tx signer (and thus have signed this field in AuthInfo). setting this field does *not* change the ordering of required signers for the transaction. granter: type: string title: >- if set, the fee payer (either the first signer or the value of the payer field) requests that a fee grant be used to pay fees instead of the fee payer's own balance. If an appropriate fee grant does not exist or the chain does not support fee grants, this will fail tip: description: >- Tip is the optional tip used for transactions fees paid in another denom. This field is ignored if the chain didn't enable tips, i.e. didn't add the `TipDecorator` in its posthandler. Since: cosmos-sdk 0.46 type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of the tip tipper: type: string title: tipper is the address of the account paying for the tip description: |- AuthInfo describes the fee and signer modes that are used to sign a transaction. signatures: type: array items: type: string format: byte description: >- signatures is a list of signatures that matches the length and order of AuthInfo's signer_infos to allow connecting signature meta information like public key and signing mode by position. description: Tx is the standard type used for broadcasting transactions. cosmos.tx.v1beta1.TxBody: type: object properties: messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- messages is a list of messages to be executed. The required signers of those messages define the number and order of elements in AuthInfo's signer_infos and Tx's signatures. Each required signer address is added to the list only the first time it occurs. By convention, the first required signer (usually from the first message) is referred to as the primary signer and pays the fee for the whole transaction. memo: type: string description: >- memo is any arbitrary note/comment to be added to the transaction. WARNING: in clients, any publicly exposed text should not be called memo, but should be called `note` instead (see https://github.com/cosmos/cosmos-sdk/issues/9122). timeout_height: type: string format: uint64 title: |- timeout is the block height after which this transaction will not be processed by the chain extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, the transaction will be rejected non_critical_extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, they will be ignored description: TxBody is the body of a transaction that all signers sign over. cosmos.tx.v1beta1.TxDecodeAminoRequest: type: object properties: amino_binary: type: string format: byte description: |- TxDecodeAminoRequest is the request type for the Service.TxDecodeAmino RPC method. Since: cosmos-sdk 0.47 cosmos.tx.v1beta1.TxDecodeAminoResponse: type: object properties: amino_json: type: string description: |- TxDecodeAminoResponse is the response type for the Service.TxDecodeAmino RPC method. Since: cosmos-sdk 0.47 cosmos.tx.v1beta1.TxDecodeRequest: type: object properties: tx_bytes: type: string format: byte description: tx_bytes is the raw transaction. description: |- TxDecodeRequest is the request type for the Service.TxDecode RPC method. Since: cosmos-sdk 0.47 cosmos.tx.v1beta1.TxDecodeResponse: type: object properties: tx: description: tx is the decoded transaction. type: object properties: body: title: body is the processable content of the transaction type: object properties: messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- messages is a list of messages to be executed. The required signers of those messages define the number and order of elements in AuthInfo's signer_infos and Tx's signatures. Each required signer address is added to the list only the first time it occurs. By convention, the first required signer (usually from the first message) is referred to as the primary signer and pays the fee for the whole transaction. memo: type: string description: >- memo is any arbitrary note/comment to be added to the transaction. WARNING: in clients, any publicly exposed text should not be called memo, but should be called `note` instead (see https://github.com/cosmos/cosmos-sdk/issues/9122). timeout_height: type: string format: uint64 title: >- timeout is the block height after which this transaction will not be processed by the chain extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, the transaction will be rejected non_critical_extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, they will be ignored description: TxBody is the body of a transaction that all signers sign over. auth_info: title: |- auth_info is the authorization related content of the transaction, specifically signers, signer modes and fee type: object properties: signer_infos: type: array items: type: object properties: public_key: type: object properties: type_url: type: string value: type: string format: byte description: >- public_key is the public key of the signer. It is optional for accounts that already exist in state. If unset, the verifier can use the required \ signer address for this position and lookup the public key. mode_info: title: >- mode_info describes the signing mode of the signer and is a nested structure to support nested multisig pubkey's type: object properties: single: title: single represents a single signer type: object properties: mode: title: mode is the signing mode of the single signer type: string enum: - SIGN_MODE_UNSPECIFIED - SIGN_MODE_DIRECT - SIGN_MODE_TEXTUAL - SIGN_MODE_DIRECT_AUX - SIGN_MODE_LEGACY_AMINO_JSON - SIGN_MODE_EIP_191 default: SIGN_MODE_UNSPECIFIED description: >- SignMode represents a signing mode with its own security guarantees. This enum should be considered a registry of all known sign modes in the Cosmos ecosystem. Apps are not expected to support all known sign modes. Apps that would like to support custom sign modes are encouraged to open a small PR against this file to add a new case to this SignMode enum describing their sign mode so that different apps have a consistent version of this enum. - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be rejected. - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is verified with raw bytes from Tx. - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some human-readable textual representation on top of the binary representation from SIGN_MODE_DIRECT. It is currently not supported. - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses SignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not require signers signing over other signers' `signer_info`. It also allows for adding Tips in transactions. Since: cosmos-sdk 0.46 - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses Amino JSON and will be removed in the future. - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos SDK. Ref: https://eips.ethereum.org/EIPS/eip-191 Currently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant, but is not implemented on the SDK by default. To enable EIP-191, you need to pass a custom `TxConfig` that has an implementation of `SignModeHandler` for EIP-191. The SDK may decide to fully support EIP-191 in the future. Since: cosmos-sdk 0.45.2 multi: title: multi represents a nested multisig signer type: object properties: bitarray: title: >- bitarray specifies which keys within the multisig are signing type: object properties: extra_bits_stored: type: integer format: int64 elems: type: string format: byte description: >- CompactBitArray is an implementation of a space efficient bit array. This is used to ensure that the encoded data takes up a minimal amount of space after proto encoding. This is not thread safe, and is not intended for concurrent usage. mode_infos: type: array items: {} title: >- mode_infos is the corresponding modes of the signers of the multisig which could include nested multisig public keys description: >- ModeInfo describes the signing mode of a single or nested multisig signer. sequence: type: string format: uint64 description: >- sequence is the sequence of the account, which describes the number of committed transactions signed by a given address. It is used to prevent replay attacks. description: >- SignerInfo describes the public key and signing mode of a single top-level signer. description: >- signer_infos defines the signing modes for the required signers. The number and order of elements must match the required signers from TxBody's messages. The first element is the primary signer and the one which pays the fee. fee: description: >- Fee is the fee and gas limit for the transaction. The first signer is the primary signer and the one which pays the fee. The fee can be calculated based on the cost of evaluating the body and doing signature verification of the signers. This can be estimated via simulation. type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of coins to be paid as a fee gas_limit: type: string format: uint64 title: >- gas_limit is the maximum gas that can be used in transaction processing before an out of gas error occurs payer: type: string description: >- if unset, the first signer is responsible for paying the fees. If set, the specified account must pay the fees. the payer must be a tx signer (and thus have signed this field in AuthInfo). setting this field does *not* change the ordering of required signers for the transaction. granter: type: string title: >- if set, the fee payer (either the first signer or the value of the payer field) requests that a fee grant be used to pay fees instead of the fee payer's own balance. If an appropriate fee grant does not exist or the chain does not support fee grants, this will fail tip: description: >- Tip is the optional tip used for transactions fees paid in another denom. This field is ignored if the chain didn't enable tips, i.e. didn't add the `TipDecorator` in its posthandler. Since: cosmos-sdk 0.46 type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of the tip tipper: type: string title: tipper is the address of the account paying for the tip description: >- AuthInfo describes the fee and signer modes that are used to sign a transaction. signatures: type: array items: type: string format: byte description: >- signatures is a list of signatures that matches the length and order of AuthInfo's signer_infos to allow connecting signature meta information like public key and signing mode by position. description: |- TxDecodeResponse is the response type for the Service.TxDecode method. Since: cosmos-sdk 0.47 cosmos.tx.v1beta1.TxEncodeAminoRequest: type: object properties: amino_json: type: string description: |- TxEncodeAminoRequest is the request type for the Service.TxEncodeAmino RPC method. Since: cosmos-sdk 0.47 cosmos.tx.v1beta1.TxEncodeAminoResponse: type: object properties: amino_binary: type: string format: byte description: |- TxEncodeAminoResponse is the response type for the Service.TxEncodeAmino RPC method. Since: cosmos-sdk 0.47 cosmos.tx.v1beta1.TxEncodeRequest: type: object properties: tx: description: tx is the transaction to encode. type: object properties: body: title: body is the processable content of the transaction type: object properties: messages: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- messages is a list of messages to be executed. The required signers of those messages define the number and order of elements in AuthInfo's signer_infos and Tx's signatures. Each required signer address is added to the list only the first time it occurs. By convention, the first required signer (usually from the first message) is referred to as the primary signer and pays the fee for the whole transaction. memo: type: string description: >- memo is any arbitrary note/comment to be added to the transaction. WARNING: in clients, any publicly exposed text should not be called memo, but should be called `note` instead (see https://github.com/cosmos/cosmos-sdk/issues/9122). timeout_height: type: string format: uint64 title: >- timeout is the block height after which this transaction will not be processed by the chain extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, the transaction will be rejected non_critical_extension_options: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: >- extension_options are arbitrary options that can be added by chains when the default options are not sufficient. If any of these are present and can't be handled, they will be ignored description: TxBody is the body of a transaction that all signers sign over. auth_info: title: |- auth_info is the authorization related content of the transaction, specifically signers, signer modes and fee type: object properties: signer_infos: type: array items: type: object properties: public_key: type: object properties: type_url: type: string value: type: string format: byte description: >- public_key is the public key of the signer. It is optional for accounts that already exist in state. If unset, the verifier can use the required \ signer address for this position and lookup the public key. mode_info: title: >- mode_info describes the signing mode of the signer and is a nested structure to support nested multisig pubkey's type: object properties: single: title: single represents a single signer type: object properties: mode: title: mode is the signing mode of the single signer type: string enum: - SIGN_MODE_UNSPECIFIED - SIGN_MODE_DIRECT - SIGN_MODE_TEXTUAL - SIGN_MODE_DIRECT_AUX - SIGN_MODE_LEGACY_AMINO_JSON - SIGN_MODE_EIP_191 default: SIGN_MODE_UNSPECIFIED description: >- SignMode represents a signing mode with its own security guarantees. This enum should be considered a registry of all known sign modes in the Cosmos ecosystem. Apps are not expected to support all known sign modes. Apps that would like to support custom sign modes are encouraged to open a small PR against this file to add a new case to this SignMode enum describing their sign mode so that different apps have a consistent version of this enum. - SIGN_MODE_UNSPECIFIED: SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be rejected. - SIGN_MODE_DIRECT: SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is verified with raw bytes from Tx. - SIGN_MODE_TEXTUAL: SIGN_MODE_TEXTUAL is a future signing mode that will verify some human-readable textual representation on top of the binary representation from SIGN_MODE_DIRECT. It is currently not supported. - SIGN_MODE_DIRECT_AUX: SIGN_MODE_DIRECT_AUX specifies a signing mode which uses SignDocDirectAux. As opposed to SIGN_MODE_DIRECT, this sign mode does not require signers signing over other signers' `signer_info`. It also allows for adding Tips in transactions. Since: cosmos-sdk 0.46 - SIGN_MODE_LEGACY_AMINO_JSON: SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses Amino JSON and will be removed in the future. - SIGN_MODE_EIP_191: SIGN_MODE_EIP_191 specifies the sign mode for EIP 191 signing on the Cosmos SDK. Ref: https://eips.ethereum.org/EIPS/eip-191 Currently, SIGN_MODE_EIP_191 is registered as a SignMode enum variant, but is not implemented on the SDK by default. To enable EIP-191, you need to pass a custom `TxConfig` that has an implementation of `SignModeHandler` for EIP-191. The SDK may decide to fully support EIP-191 in the future. Since: cosmos-sdk 0.45.2 multi: title: multi represents a nested multisig signer type: object properties: bitarray: title: >- bitarray specifies which keys within the multisig are signing type: object properties: extra_bits_stored: type: integer format: int64 elems: type: string format: byte description: >- CompactBitArray is an implementation of a space efficient bit array. This is used to ensure that the encoded data takes up a minimal amount of space after proto encoding. This is not thread safe, and is not intended for concurrent usage. mode_infos: type: array items: {} title: >- mode_infos is the corresponding modes of the signers of the multisig which could include nested multisig public keys description: >- ModeInfo describes the signing mode of a single or nested multisig signer. sequence: type: string format: uint64 description: >- sequence is the sequence of the account, which describes the number of committed transactions signed by a given address. It is used to prevent replay attacks. description: >- SignerInfo describes the public key and signing mode of a single top-level signer. description: >- signer_infos defines the signing modes for the required signers. The number and order of elements must match the required signers from TxBody's messages. The first element is the primary signer and the one which pays the fee. fee: description: >- Fee is the fee and gas limit for the transaction. The first signer is the primary signer and the one which pays the fee. The fee can be calculated based on the cost of evaluating the body and doing signature verification of the signers. This can be estimated via simulation. type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of coins to be paid as a fee gas_limit: type: string format: uint64 title: >- gas_limit is the maximum gas that can be used in transaction processing before an out of gas error occurs payer: type: string description: >- if unset, the first signer is responsible for paying the fees. If set, the specified account must pay the fees. the payer must be a tx signer (and thus have signed this field in AuthInfo). setting this field does *not* change the ordering of required signers for the transaction. granter: type: string title: >- if set, the fee payer (either the first signer or the value of the payer field) requests that a fee grant be used to pay fees instead of the fee payer's own balance. If an appropriate fee grant does not exist or the chain does not support fee grants, this will fail tip: description: >- Tip is the optional tip used for transactions fees paid in another denom. This field is ignored if the chain didn't enable tips, i.e. didn't add the `TipDecorator` in its posthandler. Since: cosmos-sdk 0.46 type: object properties: amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: amount is the amount of the tip tipper: type: string title: tipper is the address of the account paying for the tip description: >- AuthInfo describes the fee and signer modes that are used to sign a transaction. signatures: type: array items: type: string format: byte description: >- signatures is a list of signatures that matches the length and order of AuthInfo's signer_infos to allow connecting signature meta information like public key and signing mode by position. description: |- TxEncodeRequest is the request type for the Service.TxEncode RPC method. Since: cosmos-sdk 0.47 cosmos.tx.v1beta1.TxEncodeResponse: type: object properties: tx_bytes: type: string format: byte description: tx_bytes is the encoded transaction bytes. description: |- TxEncodeResponse is the response type for the Service.TxEncode method. Since: cosmos-sdk 0.47 tendermint.abci.Event: type: object properties: type: type: string attributes: type: array items: type: object properties: key: type: string value: type: string index: type: boolean description: EventAttribute is a single key-value pair, associated with an event. description: >- Event allows application developers to attach additional information to ResponseBeginBlock, ResponseEndBlock, ResponseCheckTx and ResponseDeliverTx. Later, transactions may be queried using these events. tendermint.abci.EventAttribute: type: object properties: key: type: string value: type: string index: type: boolean description: EventAttribute is a single key-value pair, associated with an event. tendermint.crypto.PublicKey: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators tendermint.types.Block: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. data: type: object properties: txs: type: array items: type: string format: byte description: >- Txs that will be applied by state @ block.Height+1. NOTE: not all txs here are valid. We're just agreeing on the order first. This means that block.AppHash does not include these txs. title: Data contains the set of transactions included in the block evidence: type: object properties: evidence: type: array items: type: object properties: duplicate_vote_evidence: type: object properties: vote_a: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. vote_b: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. total_voting_power: type: string format: int64 validator_power: type: string format: int64 timestamp: type: string format: date-time description: >- DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes. light_client_attack_evidence: type: object properties: conflicting_block: type: object properties: signed_header: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: >- hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: >- BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: >- CommitSig is a part of the Vote included in a Commit. description: >- Commit contains the evidence that a block was committed by a set of validators. validator_set: type: object properties: validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 proposer: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 common_height: type: string format: int64 byzantine_validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 timestamp: type: string format: date-time description: >- LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client. last_commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: >- Commit contains the evidence that a block was committed by a set of validators. tendermint.types.BlockIDFlag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for tendermint.types.Commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: >- Commit contains the evidence that a block was committed by a set of validators. tendermint.types.CommitSig: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. tendermint.types.Data: type: object properties: txs: type: array items: type: string format: byte description: >- Txs that will be applied by state @ block.Height+1. NOTE: not all txs here are valid. We're just agreeing on the order first. This means that block.AppHash does not include these txs. title: Data contains the set of transactions included in the block tendermint.types.DuplicateVoteEvidence: type: object properties: vote_a: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: |- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. vote_b: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: |- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. total_voting_power: type: string format: int64 validator_power: type: string format: int64 timestamp: type: string format: date-time description: >- DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes. tendermint.types.Evidence: type: object properties: duplicate_vote_evidence: type: object properties: vote_a: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: |- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. vote_b: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: |- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. total_voting_power: type: string format: int64 validator_power: type: string format: int64 timestamp: type: string format: date-time description: >- DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes. light_client_attack_evidence: type: object properties: conflicting_block: type: object properties: signed_header: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: >- BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: >- CommitSig is a part of the Vote included in a Commit. description: >- Commit contains the evidence that a block was committed by a set of validators. validator_set: type: object properties: validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 proposer: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 common_height: type: string format: int64 byzantine_validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 timestamp: type: string format: date-time description: >- LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client. tendermint.types.EvidenceList: type: object properties: evidence: type: array items: type: object properties: duplicate_vote_evidence: type: object properties: vote_a: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. vote_b: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. total_voting_power: type: string format: int64 validator_power: type: string format: int64 timestamp: type: string format: date-time description: >- DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes. light_client_attack_evidence: type: object properties: conflicting_block: type: object properties: signed_header: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: >- BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: >- CommitSig is a part of the Vote included in a Commit. description: >- Commit contains the evidence that a block was committed by a set of validators. validator_set: type: object properties: validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 proposer: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 common_height: type: string format: int64 byzantine_validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 timestamp: type: string format: date-time description: >- LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client. tendermint.types.LightBlock: type: object properties: signed_header: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: >- Commit contains the evidence that a block was committed by a set of validators. validator_set: type: object properties: validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 proposer: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 tendermint.types.LightClientAttackEvidence: type: object properties: conflicting_block: type: object properties: signed_header: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: >- BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: >- Commit contains the evidence that a block was committed by a set of validators. validator_set: type: object properties: validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 proposer: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 common_height: type: string format: int64 byzantine_validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 timestamp: type: string format: date-time description: >- LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client. tendermint.types.SignedHeader: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: >- Commit contains the evidence that a block was committed by a set of validators. tendermint.types.SignedMsgType: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: |- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals tendermint.types.Validator: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 tendermint.types.ValidatorSet: type: object properties: validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 proposer: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 tendermint.types.Vote: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: |- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: |- Vote represents a prevote, precommit, or commit vote from validators for consensus. cyber.clock.v1.ClockContract: type: object properties: contract_address: type: string description: The address of the contract. is_jailed: type: boolean description: The jail status of the contract. description: |- This object is used to store the contract address and the jail status of the contract. cyber.clock.v1.Params: type: object properties: contract_gas_limit: type: string format: uint64 description: >- contract_gas_limit defines the maximum amount of gas that can be used by a contract. description: Params defines the set of module parameters. cyber.clock.v1.QueryClockContractResponse: type: object properties: clock_contract: type: object properties: contract_address: type: string description: The address of the contract. is_jailed: type: boolean description: The jail status of the contract. description: |- This object is used to store the contract address and the jail status of the contract. description: >- QueryClockContractResponse is the response type for the Query/ClockContract RPC method. cyber.clock.v1.QueryClockContractsResponse: type: object properties: clock_contracts: type: array items: type: object properties: contract_address: type: string description: The address of the contract. is_jailed: type: boolean description: The jail status of the contract. description: |- This object is used to store the contract address and the jail status of the contract. description: clock_contracts are the clock contracts. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- QueryClockContractsResponse is the response type for the Query/ClockContracts RPC method. cyber.clock.v1.QueryParamsResponse: type: object properties: params: type: object properties: contract_gas_limit: type: string format: uint64 description: >- contract_gas_limit defines the maximum amount of gas that can be used by a contract. description: Params defines the set of module parameters. description: >- QueryClockContractsResponse is the response type for the Query/ClockContracts RPC method. ibc.core.channel.v1.Channel: type: object properties: state: title: current state of the channel end type: string enum: - STATE_UNINITIALIZED_UNSPECIFIED - STATE_INIT - STATE_TRYOPEN - STATE_OPEN - STATE_CLOSED default: STATE_UNINITIALIZED_UNSPECIFIED description: |- State defines if a channel is in one of the following states: CLOSED, INIT, TRYOPEN, OPEN or UNINITIALIZED. - STATE_UNINITIALIZED_UNSPECIFIED: Default State - STATE_INIT: A channel has just started the opening handshake. - STATE_TRYOPEN: A channel has acknowledged the handshake step on the counterparty chain. - STATE_OPEN: A channel has completed the handshake. Open channels are ready to send and receive packets. - STATE_CLOSED: A channel has been closed and can no longer be used to send or receive packets. ordering: title: whether the channel is ordered or unordered type: string enum: - ORDER_NONE_UNSPECIFIED - ORDER_UNORDERED - ORDER_ORDERED default: ORDER_NONE_UNSPECIFIED description: |- - ORDER_NONE_UNSPECIFIED: zero-value for channel ordering - ORDER_UNORDERED: packets can be delivered in any order, which may differ from the order in which they were sent. - ORDER_ORDERED: packets are delivered exactly in the order which they were sent counterparty: title: counterparty channel end type: object properties: port_id: type: string description: >- port on the counterparty chain which owns the other end of the channel. channel_id: type: string title: channel end on the counterparty chain connection_hops: type: array items: type: string title: |- list of connection identifiers, in order, along which packets sent on this channel will travel version: type: string title: opaque channel version, which is agreed upon during the handshake description: |- Channel defines pipeline for exactly-once packet delivery between specific modules on separate blockchains, which has at least one end capable of sending packets and one end capable of receiving packets. ibc.core.channel.v1.Counterparty: type: object properties: port_id: type: string description: >- port on the counterparty chain which owns the other end of the channel. channel_id: type: string title: channel end on the counterparty chain title: Counterparty defines a channel end counterparty ibc.core.channel.v1.IdentifiedChannel: type: object properties: state: title: current state of the channel end type: string enum: - STATE_UNINITIALIZED_UNSPECIFIED - STATE_INIT - STATE_TRYOPEN - STATE_OPEN - STATE_CLOSED default: STATE_UNINITIALIZED_UNSPECIFIED description: |- State defines if a channel is in one of the following states: CLOSED, INIT, TRYOPEN, OPEN or UNINITIALIZED. - STATE_UNINITIALIZED_UNSPECIFIED: Default State - STATE_INIT: A channel has just started the opening handshake. - STATE_TRYOPEN: A channel has acknowledged the handshake step on the counterparty chain. - STATE_OPEN: A channel has completed the handshake. Open channels are ready to send and receive packets. - STATE_CLOSED: A channel has been closed and can no longer be used to send or receive packets. ordering: title: whether the channel is ordered or unordered type: string enum: - ORDER_NONE_UNSPECIFIED - ORDER_UNORDERED - ORDER_ORDERED default: ORDER_NONE_UNSPECIFIED description: |- - ORDER_NONE_UNSPECIFIED: zero-value for channel ordering - ORDER_UNORDERED: packets can be delivered in any order, which may differ from the order in which they were sent. - ORDER_ORDERED: packets are delivered exactly in the order which they were sent counterparty: title: counterparty channel end type: object properties: port_id: type: string description: >- port on the counterparty chain which owns the other end of the channel. channel_id: type: string title: channel end on the counterparty chain connection_hops: type: array items: type: string title: |- list of connection identifiers, in order, along which packets sent on this channel will travel version: type: string title: opaque channel version, which is agreed upon during the handshake port_id: type: string title: port identifier channel_id: type: string title: channel identifier description: |- IdentifiedChannel defines a channel with additional port and channel identifier fields. ibc.core.channel.v1.Order: type: string enum: - ORDER_NONE_UNSPECIFIED - ORDER_UNORDERED - ORDER_ORDERED default: ORDER_NONE_UNSPECIFIED description: |- - ORDER_NONE_UNSPECIFIED: zero-value for channel ordering - ORDER_UNORDERED: packets can be delivered in any order, which may differ from the order in which they were sent. - ORDER_ORDERED: packets are delivered exactly in the order which they were sent title: Order defines if a channel is ORDERED or UNORDERED ibc.core.channel.v1.PacketState: type: object properties: port_id: type: string description: channel port identifier. channel_id: type: string description: channel unique identifier. sequence: type: string format: uint64 description: packet sequence. data: type: string format: byte description: embedded data that represents packet state. description: |- PacketState defines the generic type necessary to retrieve and store packet commitments, acknowledgements, and receipts. Caller is responsible for knowing the context necessary to interpret this state as a commitment, acknowledgement, or a receipt. ibc.core.channel.v1.QueryChannelClientStateResponse: type: object properties: identified_client_state: title: client state associated with the channel type: object properties: client_id: type: string title: client identifier client_state: type: object properties: type_url: type: string value: type: string format: byte title: client state description: |- IdentifiedClientState defines a client state with an additional client identifier field. proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryChannelClientStateResponse is the Response type for the Query/QueryChannelClientState RPC method ibc.core.channel.v1.QueryChannelConsensusStateResponse: type: object properties: consensus_state: type: object properties: type_url: type: string value: type: string format: byte title: consensus state associated with the channel client_id: type: string title: client ID associated with the consensus state proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryChannelClientStateResponse is the Response type for the Query/QueryChannelClientState RPC method ibc.core.channel.v1.QueryChannelResponse: type: object properties: channel: title: channel associated with the request identifiers type: object properties: state: title: current state of the channel end type: string enum: - STATE_UNINITIALIZED_UNSPECIFIED - STATE_INIT - STATE_TRYOPEN - STATE_OPEN - STATE_CLOSED default: STATE_UNINITIALIZED_UNSPECIFIED description: |- State defines if a channel is in one of the following states: CLOSED, INIT, TRYOPEN, OPEN or UNINITIALIZED. - STATE_UNINITIALIZED_UNSPECIFIED: Default State - STATE_INIT: A channel has just started the opening handshake. - STATE_TRYOPEN: A channel has acknowledged the handshake step on the counterparty chain. - STATE_OPEN: A channel has completed the handshake. Open channels are ready to send and receive packets. - STATE_CLOSED: A channel has been closed and can no longer be used to send or receive packets. ordering: title: whether the channel is ordered or unordered type: string enum: - ORDER_NONE_UNSPECIFIED - ORDER_UNORDERED - ORDER_ORDERED default: ORDER_NONE_UNSPECIFIED description: |- - ORDER_NONE_UNSPECIFIED: zero-value for channel ordering - ORDER_UNORDERED: packets can be delivered in any order, which may differ from the order in which they were sent. - ORDER_ORDERED: packets are delivered exactly in the order which they were sent counterparty: title: counterparty channel end type: object properties: port_id: type: string description: >- port on the counterparty chain which owns the other end of the channel. channel_id: type: string title: channel end on the counterparty chain connection_hops: type: array items: type: string title: >- list of connection identifiers, in order, along which packets sent on this channel will travel version: type: string title: opaque channel version, which is agreed upon during the handshake description: >- Channel defines pipeline for exactly-once packet delivery between specific modules on separate blockchains, which has at least one end capable of sending packets and one end capable of receiving packets. proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset description: >- QueryChannelResponse is the response type for the Query/Channel RPC method. Besides the Channel end, it includes a proof and the height from which the proof was retrieved. ibc.core.channel.v1.QueryChannelsResponse: type: object properties: channels: type: array items: type: object properties: state: title: current state of the channel end type: string enum: - STATE_UNINITIALIZED_UNSPECIFIED - STATE_INIT - STATE_TRYOPEN - STATE_OPEN - STATE_CLOSED default: STATE_UNINITIALIZED_UNSPECIFIED description: |- State defines if a channel is in one of the following states: CLOSED, INIT, TRYOPEN, OPEN or UNINITIALIZED. - STATE_UNINITIALIZED_UNSPECIFIED: Default State - STATE_INIT: A channel has just started the opening handshake. - STATE_TRYOPEN: A channel has acknowledged the handshake step on the counterparty chain. - STATE_OPEN: A channel has completed the handshake. Open channels are ready to send and receive packets. - STATE_CLOSED: A channel has been closed and can no longer be used to send or receive packets. ordering: title: whether the channel is ordered or unordered type: string enum: - ORDER_NONE_UNSPECIFIED - ORDER_UNORDERED - ORDER_ORDERED default: ORDER_NONE_UNSPECIFIED description: |- - ORDER_NONE_UNSPECIFIED: zero-value for channel ordering - ORDER_UNORDERED: packets can be delivered in any order, which may differ from the order in which they were sent. - ORDER_ORDERED: packets are delivered exactly in the order which they were sent counterparty: title: counterparty channel end type: object properties: port_id: type: string description: >- port on the counterparty chain which owns the other end of the channel. channel_id: type: string title: channel end on the counterparty chain connection_hops: type: array items: type: string title: >- list of connection identifiers, in order, along which packets sent on this channel will travel version: type: string title: >- opaque channel version, which is agreed upon during the handshake port_id: type: string title: port identifier channel_id: type: string title: channel identifier description: |- IdentifiedChannel defines a channel with additional port and channel identifier fields. description: list of stored channels of the chain. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: pagination response height: title: query block height type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset description: >- QueryChannelsResponse is the response type for the Query/Channels RPC method. ibc.core.channel.v1.QueryConnectionChannelsResponse: type: object properties: channels: type: array items: type: object properties: state: title: current state of the channel end type: string enum: - STATE_UNINITIALIZED_UNSPECIFIED - STATE_INIT - STATE_TRYOPEN - STATE_OPEN - STATE_CLOSED default: STATE_UNINITIALIZED_UNSPECIFIED description: |- State defines if a channel is in one of the following states: CLOSED, INIT, TRYOPEN, OPEN or UNINITIALIZED. - STATE_UNINITIALIZED_UNSPECIFIED: Default State - STATE_INIT: A channel has just started the opening handshake. - STATE_TRYOPEN: A channel has acknowledged the handshake step on the counterparty chain. - STATE_OPEN: A channel has completed the handshake. Open channels are ready to send and receive packets. - STATE_CLOSED: A channel has been closed and can no longer be used to send or receive packets. ordering: title: whether the channel is ordered or unordered type: string enum: - ORDER_NONE_UNSPECIFIED - ORDER_UNORDERED - ORDER_ORDERED default: ORDER_NONE_UNSPECIFIED description: |- - ORDER_NONE_UNSPECIFIED: zero-value for channel ordering - ORDER_UNORDERED: packets can be delivered in any order, which may differ from the order in which they were sent. - ORDER_ORDERED: packets are delivered exactly in the order which they were sent counterparty: title: counterparty channel end type: object properties: port_id: type: string description: >- port on the counterparty chain which owns the other end of the channel. channel_id: type: string title: channel end on the counterparty chain connection_hops: type: array items: type: string title: >- list of connection identifiers, in order, along which packets sent on this channel will travel version: type: string title: >- opaque channel version, which is agreed upon during the handshake port_id: type: string title: port identifier channel_id: type: string title: channel identifier description: |- IdentifiedChannel defines a channel with additional port and channel identifier fields. description: list of channels associated with a connection. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: pagination response height: title: query block height type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryConnectionChannelsResponse is the Response type for the Query/QueryConnectionChannels RPC method ibc.core.channel.v1.QueryNextSequenceReceiveResponse: type: object properties: next_sequence_receive: type: string format: uint64 title: next sequence receive number proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QuerySequenceResponse is the request type for the Query/QueryNextSequenceReceiveResponse RPC method ibc.core.channel.v1.QueryPacketAcknowledgementResponse: type: object properties: acknowledgement: type: string format: byte title: packet associated with the request fields proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryPacketAcknowledgementResponse defines the client query response for a packet which also includes a proof and the height from which the proof was retrieved ibc.core.channel.v1.QueryPacketAcknowledgementsResponse: type: object properties: acknowledgements: type: array items: type: object properties: port_id: type: string description: channel port identifier. channel_id: type: string description: channel unique identifier. sequence: type: string format: uint64 description: packet sequence. data: type: string format: byte description: embedded data that represents packet state. description: >- PacketState defines the generic type necessary to retrieve and store packet commitments, acknowledgements, and receipts. Caller is responsible for knowing the context necessary to interpret this state as a commitment, acknowledgement, or a receipt. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: pagination response height: title: query block height type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryPacketAcknowledgemetsResponse is the request type for the Query/QueryPacketAcknowledgements RPC method ibc.core.channel.v1.QueryPacketCommitmentResponse: type: object properties: commitment: type: string format: byte title: packet associated with the request fields proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: >- QueryPacketCommitmentResponse defines the client query response for a packet which also includes a proof and the height from which the proof was retrieved ibc.core.channel.v1.QueryPacketCommitmentsResponse: type: object properties: commitments: type: array items: type: object properties: port_id: type: string description: channel port identifier. channel_id: type: string description: channel unique identifier. sequence: type: string format: uint64 description: packet sequence. data: type: string format: byte description: embedded data that represents packet state. description: >- PacketState defines the generic type necessary to retrieve and store packet commitments, acknowledgements, and receipts. Caller is responsible for knowing the context necessary to interpret this state as a commitment, acknowledgement, or a receipt. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: pagination response height: title: query block height type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryPacketCommitmentsResponse is the request type for the Query/QueryPacketCommitments RPC method ibc.core.channel.v1.QueryPacketReceiptResponse: type: object properties: received: type: boolean title: success flag for if receipt exists proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: >- QueryPacketReceiptResponse defines the client query response for a packet receipt which also includes a proof, and the height from which the proof was retrieved ibc.core.channel.v1.QueryUnreceivedAcksResponse: type: object properties: sequences: type: array items: type: string format: uint64 title: list of unreceived acknowledgement sequences height: title: query block height type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryUnreceivedAcksResponse is the response type for the Query/UnreceivedAcks RPC method ibc.core.channel.v1.QueryUnreceivedPacketsResponse: type: object properties: sequences: type: array items: type: string format: uint64 title: list of unreceived packet sequences height: title: query block height type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: |- QueryUnreceivedPacketsResponse is the response type for the Query/UnreceivedPacketCommitments RPC method ibc.core.channel.v1.State: type: string enum: - STATE_UNINITIALIZED_UNSPECIFIED - STATE_INIT - STATE_TRYOPEN - STATE_OPEN - STATE_CLOSED default: STATE_UNINITIALIZED_UNSPECIFIED description: |- State defines if a channel is in one of the following states: CLOSED, INIT, TRYOPEN, OPEN or UNINITIALIZED. - STATE_UNINITIALIZED_UNSPECIFIED: Default State - STATE_INIT: A channel has just started the opening handshake. - STATE_TRYOPEN: A channel has acknowledged the handshake step on the counterparty chain. - STATE_OPEN: A channel has completed the handshake. Open channels are ready to send and receive packets. - STATE_CLOSED: A channel has been closed and can no longer be used to send or receive packets. cosmos.auth.v1beta1.AddressBytesToStringResponse: type: object properties: address_string: type: string description: >- AddressBytesToStringResponse is the response type for AddressString rpc method. Since: cosmos-sdk 0.46 cosmos.auth.v1beta1.AddressStringToBytesResponse: type: object properties: address_bytes: type: string format: byte description: >- AddressStringToBytesResponse is the response type for AddressBytes rpc method. Since: cosmos-sdk 0.46 cosmos.auth.v1beta1.BaseAccount: type: object properties: address: type: string pub_key: type: object properties: type_url: type: string value: type: string format: byte account_number: type: string format: uint64 sequence: type: string format: uint64 description: >- BaseAccount defines a base account type. It contains all the necessary fields for basic account functionality. Any custom account type should extend this type for additional functionality (e.g. vesting). cosmos.auth.v1beta1.Bech32PrefixResponse: type: object properties: bech32_prefix: type: string description: |- Bech32PrefixResponse is the response type for Bech32Prefix rpc method. Since: cosmos-sdk 0.46 cosmos.auth.v1beta1.Params: type: object properties: max_memo_characters: type: string format: uint64 tx_sig_limit: type: string format: uint64 tx_size_cost_per_byte: type: string format: uint64 sig_verify_cost_ed25519: type: string format: uint64 sig_verify_cost_secp256k1: type: string format: uint64 description: Params defines the parameters for the auth module. cosmos.auth.v1beta1.QueryAccountAddressByIDResponse: type: object properties: account_address: type: string description: 'Since: cosmos-sdk 0.46.2' title: >- QueryAccountAddressByIDResponse is the response type for AccountAddressByID rpc method cosmos.auth.v1beta1.QueryAccountInfoResponse: type: object properties: info: description: info is the account info which is represented by BaseAccount. type: object properties: address: type: string pub_key: type: object properties: type_url: type: string value: type: string format: byte account_number: type: string format: uint64 sequence: type: string format: uint64 description: |- QueryAccountInfoResponse is the Query/AccountInfo response type. Since: cosmos-sdk 0.47 cosmos.auth.v1beta1.QueryAccountResponse: type: object properties: account: type: object properties: type_url: type: string value: type: string format: byte description: account defines the account of the corresponding address. description: >- QueryAccountResponse is the response type for the Query/Account RPC method. cosmos.auth.v1beta1.QueryAccountsResponse: type: object properties: accounts: type: array items: type: object properties: type_url: type: string value: type: string format: byte title: accounts are the existing accounts pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- QueryAccountsResponse is the response type for the Query/Accounts RPC method. Since: cosmos-sdk 0.43 cosmos.auth.v1beta1.QueryModuleAccountByNameResponse: type: object properties: account: type: object properties: type_url: type: string value: type: string format: byte description: >- QueryModuleAccountByNameResponse is the response type for the Query/ModuleAccountByName RPC method. cosmos.auth.v1beta1.QueryModuleAccountsResponse: type: object properties: accounts: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: >- QueryModuleAccountsResponse is the response type for the Query/ModuleAccounts RPC method. Since: cosmos-sdk 0.46 cosmos.auth.v1beta1.QueryParamsResponse: type: object properties: params: description: params defines the parameters of the module. type: object properties: max_memo_characters: type: string format: uint64 tx_sig_limit: type: string format: uint64 tx_size_cost_per_byte: type: string format: uint64 sig_verify_cost_ed25519: type: string format: uint64 sig_verify_cost_secp256k1: type: string format: uint64 description: QueryParamsResponse is the response type for the Query/Params RPC method. cosmos.evidence.v1beta1.QueryAllEvidenceResponse: type: object properties: evidence: type: array items: type: object properties: type_url: type: string value: type: string format: byte description: evidence returns all evidences. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- QueryAllEvidenceResponse is the response type for the Query/AllEvidence RPC method. cosmos.evidence.v1beta1.QueryEvidenceResponse: type: object properties: evidence: type: object properties: type_url: type: string value: type: string format: byte description: evidence returns the requested evidence. description: >- QueryEvidenceResponse is the response type for the Query/Evidence RPC method. ibc.core.client.v1.ConsensusStateWithHeight: type: object properties: height: title: consensus state height type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset consensus_state: type: object properties: type_url: type: string value: type: string format: byte title: consensus state description: >- ConsensusStateWithHeight defines a consensus state with an additional height field. ibc.core.client.v1.Params: type: object properties: allowed_clients: type: array items: type: string description: >- allowed_clients defines the list of allowed client state types which can be created and interacted with. If a client type is removed from the allowed clients list, usage of this client will be disabled until it is added again to the list. description: Params defines the set of IBC light client parameters. ibc.core.client.v1.QueryClientParamsResponse: type: object properties: params: description: params defines the parameters of the module. type: object properties: allowed_clients: type: array items: type: string description: >- allowed_clients defines the list of allowed client state types which can be created and interacted with. If a client type is removed from the allowed clients list, usage of this client will be disabled until it is added again to the list. description: >- QueryClientParamsResponse is the response type for the Query/ClientParams RPC method. ibc.core.client.v1.QueryClientStateResponse: type: object properties: client_state: type: object properties: type_url: type: string value: type: string format: byte title: client state associated with the request identifier proof: type: string format: byte title: merkle proof of existence proof_height: title: height at which the proof was retrieved type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset description: >- QueryClientStateResponse is the response type for the Query/ClientState RPC method. Besides the client state, it includes a proof and the height from which the proof was retrieved. ibc.core.client.v1.QueryClientStatesResponse: type: object properties: client_states: type: array items: type: object properties: client_id: type: string title: client identifier client_state: type: object properties: type_url: type: string value: type: string format: byte title: client state description: >- IdentifiedClientState defines a client state with an additional client identifier field. description: list of stored ClientStates of the chain. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: pagination response description: >- QueryClientStatesResponse is the response type for the Query/ClientStates RPC method. ibc.core.client.v1.QueryClientStatusResponse: type: object properties: status: type: string description: >- QueryClientStatusResponse is the response type for the Query/ClientStatus RPC method. It returns the current status of the IBC client. ibc.core.client.v1.QueryConsensusStateHeightsResponse: type: object properties: consensus_state_heights: type: array items: type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: >- Height is a monotonically increasing data type that can be compared against another Height for the purposes of updating and freezing clients title: consensus state heights pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: pagination response title: |- QueryConsensusStateHeightsResponse is the response type for the Query/ConsensusStateHeights RPC method ibc.core.client.v1.QueryConsensusStateResponse: type: object properties: consensus_state: type: object properties: type_url: type: string value: type: string format: byte title: >- consensus state associated with the client identifier at the given height proof: type: string format: byte title: merkle proof of existence proof_height: type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset title: >- Height is a monotonically increasing data type that can be compared against another Height for the purposes of updating and freezing clients title: >- QueryConsensusStateResponse is the response type for the Query/ConsensusState RPC method ibc.core.client.v1.QueryConsensusStatesResponse: type: object properties: consensus_states: type: array items: type: object properties: height: title: consensus state height type: object properties: revision_number: type: string format: uint64 title: the revision that the client is currently on revision_height: type: string format: uint64 title: the height within the given revision description: >- Normally the RevisionHeight is incremented at each height while keeping RevisionNumber the same. However some consensus algorithms may choose to reset the height in certain conditions e.g. hard forks, state-machine breaking changes In these cases, the RevisionNumber is incremented so that height continues to be monitonically increasing even as the RevisionHeight gets reset consensus_state: type: object properties: type_url: type: string value: type: string format: byte title: consensus state description: >- ConsensusStateWithHeight defines a consensus state with an additional height field. title: consensus states associated with the identifier pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: pagination response title: |- QueryConsensusStatesResponse is the response type for the Query/ConsensusStates RPC method ibc.core.client.v1.QueryUpgradedClientStateResponse: type: object properties: upgraded_client_state: type: object properties: type_url: type: string value: type: string format: byte title: client state associated with the request identifier description: |- QueryUpgradedClientStateResponse is the response type for the Query/UpgradedClientState RPC method. ibc.core.client.v1.QueryUpgradedConsensusStateResponse: type: object properties: upgraded_consensus_state: type: object properties: type_url: type: string value: type: string format: byte title: Consensus state associated with the request identifier description: |- QueryUpgradedConsensusStateResponse is the response type for the Query/UpgradedConsensusState RPC method. cosmos.authz.v1beta1.Grant: type: object properties: authorization: type: object properties: type_url: type: string value: type: string format: byte expiration: type: string format: date-time title: >- time when the grant will expire and will be pruned. If null, then the grant doesn't have a time expiration (other conditions in `authorization` may apply to invalidate the grant) description: |- Grant gives permissions to execute the provide method with expiration time. cosmos.authz.v1beta1.GrantAuthorization: type: object properties: granter: type: string grantee: type: string authorization: type: object properties: type_url: type: string value: type: string format: byte expiration: type: string format: date-time title: >- GrantAuthorization extends a grant with both the addresses of the grantee and granter. It is used in genesis.proto and query.proto cosmos.authz.v1beta1.QueryGranteeGrantsResponse: type: object properties: grants: type: array items: type: object properties: granter: type: string grantee: type: string authorization: type: object properties: type_url: type: string value: type: string format: byte expiration: type: string format: date-time title: >- GrantAuthorization extends a grant with both the addresses of the grantee and granter. It is used in genesis.proto and query.proto description: grants is a list of grants granted to the grantee. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- QueryGranteeGrantsResponse is the response type for the Query/GranteeGrants RPC method. cosmos.authz.v1beta1.QueryGranterGrantsResponse: type: object properties: grants: type: array items: type: object properties: granter: type: string grantee: type: string authorization: type: object properties: type_url: type: string value: type: string format: byte expiration: type: string format: date-time title: >- GrantAuthorization extends a grant with both the addresses of the grantee and granter. It is used in genesis.proto and query.proto description: grants is a list of grants granted by the granter. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- QueryGranterGrantsResponse is the response type for the Query/GranterGrants RPC method. cosmos.authz.v1beta1.QueryGrantsResponse: type: object properties: grants: type: array items: type: object properties: authorization: type: object properties: type_url: type: string value: type: string format: byte expiration: type: string format: date-time title: >- time when the grant will expire and will be pruned. If null, then the grant doesn't have a time expiration (other conditions in `authorization` may apply to invalidate the grant) description: |- Grant gives permissions to execute the provide method with expiration time. description: authorizations is a list of grants granted for grantee by granter. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- QueryGrantsResponse is the response type for the Query/Authorizations RPC method. cyber.liquidity.v1beta1.DepositMsgState: type: object properties: msg_height: type: string format: int64 title: height where this message is appended to the batch msg_index: type: string format: uint64 title: index of this deposit message in this liquidity pool executed: type: boolean title: true if executed on this batch, false if not executed succeeded: type: boolean title: true if executed successfully on this batch, false if failed to_be_deleted: type: boolean title: >- true if ready to be deleted on kvstore, false if not ready to be deleted msg: title: MsgDepositWithinBatch type: object properties: depositor_address: type: string pool_id: type: string format: uint64 title: id of the target pool deposit_coins: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: reserve coin pair of the pool to deposit description: >- `MsgDepositWithinBatch defines` an `sdk.Msg` type that supports submitting a deposit request to the batch of the liquidity pool. Deposit is submitted to the batch of the Liquidity pool with the specified `pool_id`, `deposit_coins` for reserve. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. See: https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md description: |- DepositMsgState defines the state of deposit message that contains state information as it is processed in the next batch or batches. cyber.liquidity.v1beta1.MsgDepositWithinBatch: type: object properties: depositor_address: type: string pool_id: type: string format: uint64 title: id of the target pool deposit_coins: type: array items: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: reserve coin pair of the pool to deposit description: >- `MsgDepositWithinBatch defines` an `sdk.Msg` type that supports submitting a deposit request to the batch of the liquidity pool. Deposit is submitted to the batch of the Liquidity pool with the specified `pool_id`, `deposit_coins` for reserve. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. See: https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md cyber.liquidity.v1beta1.MsgSwapWithinBatch: type: object properties: swap_requester_address: type: string title: address of swap requester pool_id: type: string format: uint64 description: >- id of swap type, must match the value in the pool. Only `swap_type_id` 1 is supported. swap_type_id: type: integer format: int64 description: id of swap type. Must match the value in the pool. offer_coin: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. demand_coin_denom: type: string description: >- denom of demand coin to be exchanged on the swap request, must match the denom in the pool. offer_coin_fee: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. order_price: type: string description: >- limit order price for the order, the price is the exchange ratio of X/Y where X is the amount of the first coin and Y is the amount of the second coin when their denoms are sorted alphabetically. description: >- `MsgSwapWithinBatch` defines an sdk.Msg type that supports submitting a swap offer request to the batch of the liquidity pool. Submit swap offer to the liquidity pool batch with the specified the `pool_id`, `swap_type_id`, `demand_coin_denom` with the coin and the price you're offering and `offer_coin_fee` must be half of offer coin amount * current `params.swap_fee_rate` and ceil for reservation to pay fees. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. You must request the same fields as the pool. Only the default `swap_type_id` 1 is supported. See: https://github.com/gravity-devs/liquidity/tree/develop/doc https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md cyber.liquidity.v1beta1.MsgWithdrawWithinBatch: type: object properties: withdrawer_address: type: string pool_id: type: string format: uint64 title: id of the target pool pool_coin: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- `MsgWithdrawWithinBatch` defines an `sdk.Msg` type that supports submitting a withdraw request to the batch of the liquidity pool. Withdraw is submitted to the batch from the Liquidity pool with the specified `pool_id`, `pool_coin` of the pool. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. See: https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md cyber.liquidity.v1beta1.Params: type: object properties: pool_types: type: array items: type: object properties: id: type: integer format: int64 title: >- This is the id of the pool_type that is used as pool_type_id for pool creation. In this version, only pool-type-id 1 is supported. {"id":1,"name":"ConstantProductLiquidityPool","min_reserve_coin_num":2,"max_reserve_coin_num":2,"description":""} name: type: string description: name of the pool type. min_reserve_coin_num: type: integer format: int64 description: >- minimum number of reserveCoins for LiquidityPoolType, only 2 reserve coins are supported. max_reserve_coin_num: type: integer format: int64 description: >- maximum number of reserveCoins for LiquidityPoolType, only 2 reserve coins are supported. description: type: string description: description of the pool type. description: >- Structure for the pool type to distinguish the characteristics of the reserve pools. title: list of available pool types min_init_deposit_amount: type: string description: |- Minimum number of coins to be deposited to the liquidity pool on pool creation. init_pool_coin_mint_amount: type: string description: Initial mint amount of pool coins upon pool creation. max_reserve_coin_amount: type: string description: >- Limit the size of each liquidity pool to minimize risk. In development, set to 0 for no limit. In production, set a limit. pool_creation_fee: type: array items: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: Fee paid to create a Liquidity Pool. Set a fee to prevent spamming. swap_fee_rate: type: string description: Swap fee rate for every executed swap. withdraw_fee_rate: type: string description: Reserve coin withdrawal with less proportion by withdrawFeeRate. max_order_amount_ratio: type: string description: Maximum ratio of reserve coins that can be ordered at a swap order. unit_batch_height: type: integer format: int64 description: The smallest unit batch height for every liquidity pool. circuit_breaker_enabled: type: boolean description: |- Circuit breaker enables or disables transaction messages in liquidity module. description: Params defines the parameters for the liquidity module. cyber.liquidity.v1beta1.Pool: type: object properties: id: type: string format: uint64 title: id of the pool type_id: type: integer format: int64 title: id of the pool_type reserve_coin_denoms: type: array items: type: string title: denoms of reserve coin pair of the pool reserve_account_address: type: string title: reserve account address of the pool pool_coin_denom: type: string title: denom of pool coin of the pool description: Pool defines the liquidity pool that contains pool information. cyber.liquidity.v1beta1.PoolBatch: type: object properties: pool_id: type: string format: uint64 title: id of the pool index: type: string format: uint64 title: index of this batch begin_height: type: string format: int64 title: height where this batch is started deposit_msg_index: type: string format: uint64 title: last index of DepositMsgStates withdraw_msg_index: type: string format: uint64 title: last index of WithdrawMsgStates swap_msg_index: type: string format: uint64 title: last index of SwapMsgStates executed: type: boolean title: true if executed, false if not executed description: |- PoolBatch defines the batch or batches of a given liquidity pool that contains indexes of deposit, withdraw, and swap messages. Index param increments by 1 if the pool id is same. cyber.liquidity.v1beta1.PoolType: type: object properties: id: type: integer format: int64 title: >- This is the id of the pool_type that is used as pool_type_id for pool creation. In this version, only pool-type-id 1 is supported. {"id":1,"name":"ConstantProductLiquidityPool","min_reserve_coin_num":2,"max_reserve_coin_num":2,"description":""} name: type: string description: name of the pool type. min_reserve_coin_num: type: integer format: int64 description: >- minimum number of reserveCoins for LiquidityPoolType, only 2 reserve coins are supported. max_reserve_coin_num: type: integer format: int64 description: >- maximum number of reserveCoins for LiquidityPoolType, only 2 reserve coins are supported. description: type: string description: description of the pool type. description: >- Structure for the pool type to distinguish the characteristics of the reserve pools. cyber.liquidity.v1beta1.QueryLiquidityPoolBatchResponse: type: object properties: batch: type: object properties: pool_id: type: string format: uint64 title: id of the pool index: type: string format: uint64 title: index of this batch begin_height: type: string format: int64 title: height where this batch is started deposit_msg_index: type: string format: uint64 title: last index of DepositMsgStates withdraw_msg_index: type: string format: uint64 title: last index of WithdrawMsgStates swap_msg_index: type: string format: uint64 title: last index of SwapMsgStates executed: type: boolean title: true if executed, false if not executed description: |- PoolBatch defines the batch or batches of a given liquidity pool that contains indexes of deposit, withdraw, and swap messages. Index param increments by 1 if the pool id is same. description: >- the response type for the QueryLiquidityPoolBatchResponse RPC method. Returns the liquidity pool batch that corresponds to the requested pool_id. cyber.liquidity.v1beta1.QueryLiquidityPoolResponse: type: object properties: pool: type: object properties: id: type: string format: uint64 title: id of the pool type_id: type: integer format: int64 title: id of the pool_type reserve_coin_denoms: type: array items: type: string title: denoms of reserve coin pair of the pool reserve_account_address: type: string title: reserve account address of the pool pool_coin_denom: type: string title: denom of pool coin of the pool description: Pool defines the liquidity pool that contains pool information. description: >- the response type for the QueryLiquidityPoolResponse RPC method. Returns the liquidity pool that corresponds to the requested pool_id. cyber.liquidity.v1beta1.QueryLiquidityPoolsResponse: type: object properties: pools: type: array items: type: object properties: id: type: string format: uint64 title: id of the pool type_id: type: integer format: int64 title: id of the pool_type reserve_coin_denoms: type: array items: type: string title: denoms of reserve coin pair of the pool reserve_account_address: type: string title: reserve account address of the pool pool_coin_denom: type: string title: denom of pool coin of the pool description: Pool defines the liquidity pool that contains pool information. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: |- the response type for the QueryLiquidityPoolsResponse RPC method. This includes a list of all existing liquidity pools and paging results that contain next_key and total count. cyber.liquidity.v1beta1.QueryParamsResponse: type: object properties: params: description: params holds all the parameters of this module. type: object properties: pool_types: type: array items: type: object properties: id: type: integer format: int64 title: >- This is the id of the pool_type that is used as pool_type_id for pool creation. In this version, only pool-type-id 1 is supported. {"id":1,"name":"ConstantProductLiquidityPool","min_reserve_coin_num":2,"max_reserve_coin_num":2,"description":""} name: type: string description: name of the pool type. min_reserve_coin_num: type: integer format: int64 description: >- minimum number of reserveCoins for LiquidityPoolType, only 2 reserve coins are supported. max_reserve_coin_num: type: integer format: int64 description: >- maximum number of reserveCoins for LiquidityPoolType, only 2 reserve coins are supported. description: type: string description: description of the pool type. description: >- Structure for the pool type to distinguish the characteristics of the reserve pools. title: list of available pool types min_init_deposit_amount: type: string description: >- Minimum number of coins to be deposited to the liquidity pool on pool creation. init_pool_coin_mint_amount: type: string description: Initial mint amount of pool coins upon pool creation. max_reserve_coin_amount: type: string description: >- Limit the size of each liquidity pool to minimize risk. In development, set to 0 for no limit. In production, set a limit. pool_creation_fee: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- Fee paid to create a Liquidity Pool. Set a fee to prevent spamming. swap_fee_rate: type: string description: Swap fee rate for every executed swap. withdraw_fee_rate: type: string description: Reserve coin withdrawal with less proportion by withdrawFeeRate. max_order_amount_ratio: type: string description: >- Maximum ratio of reserve coins that can be ordered at a swap order. unit_batch_height: type: integer format: int64 description: The smallest unit batch height for every liquidity pool. circuit_breaker_enabled: type: boolean description: >- Circuit breaker enables or disables transaction messages in liquidity module. description: |- the response type for the QueryParamsResponse RPC method. This includes current parameter of the liquidity module. cyber.liquidity.v1beta1.QueryPoolBatchDepositMsgResponse: type: object properties: deposit: type: object properties: msg_height: type: string format: int64 title: height where this message is appended to the batch msg_index: type: string format: uint64 title: index of this deposit message in this liquidity pool executed: type: boolean title: true if executed on this batch, false if not executed succeeded: type: boolean title: true if executed successfully on this batch, false if failed to_be_deleted: type: boolean title: >- true if ready to be deleted on kvstore, false if not ready to be deleted msg: title: MsgDepositWithinBatch type: object properties: depositor_address: type: string pool_id: type: string format: uint64 title: id of the target pool deposit_coins: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: reserve coin pair of the pool to deposit description: >- `MsgDepositWithinBatch defines` an `sdk.Msg` type that supports submitting a deposit request to the batch of the liquidity pool. Deposit is submitted to the batch of the Liquidity pool with the specified `pool_id`, `deposit_coins` for reserve. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. See: https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md description: >- DepositMsgState defines the state of deposit message that contains state information as it is processed in the next batch or batches. description: >- the response type for the QueryPoolBatchDepositMsg RPC method. This includes a batch swap message of the batch. cyber.liquidity.v1beta1.QueryPoolBatchDepositMsgsResponse: type: object properties: deposits: type: array items: type: object properties: msg_height: type: string format: int64 title: height where this message is appended to the batch msg_index: type: string format: uint64 title: index of this deposit message in this liquidity pool executed: type: boolean title: true if executed on this batch, false if not executed succeeded: type: boolean title: true if executed successfully on this batch, false if failed to_be_deleted: type: boolean title: >- true if ready to be deleted on kvstore, false if not ready to be deleted msg: title: MsgDepositWithinBatch type: object properties: depositor_address: type: string pool_id: type: string format: uint64 title: id of the target pool deposit_coins: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: reserve coin pair of the pool to deposit description: >- `MsgDepositWithinBatch defines` an `sdk.Msg` type that supports submitting a deposit request to the batch of the liquidity pool. Deposit is submitted to the batch of the Liquidity pool with the specified `pool_id`, `deposit_coins` for reserve. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. See: https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md description: >- DepositMsgState defines the state of deposit message that contains state information as it is processed in the next batch or batches. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- the response type for the QueryPoolBatchDeposit RPC method. This includes a list of all currently existing deposit messages of the batch and paging results that contain next_key and total count. cyber.liquidity.v1beta1.QueryPoolBatchSwapMsgResponse: type: object properties: swap: type: object properties: msg_height: type: string format: int64 title: height where this message is appended to the batch msg_index: type: string format: uint64 title: index of this swap message in this liquidity pool executed: type: boolean title: true if executed on this batch, false if not executed succeeded: type: boolean title: true if executed successfully on this batch, false if failed to_be_deleted: type: boolean title: >- true if ready to be deleted on kvstore, false if not ready to be deleted order_expiry_height: type: string format: int64 title: >- swap orders are cancelled when current height is equal to or higher than ExpiryHeight exchanged_offer_coin: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: offer coin exchanged until now remaining_offer_coin: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: offer coin currently remaining to be exchanged reserved_offer_coin_fee: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: reserve fee for pays fee in half offer coin msg: title: MsgSwapWithinBatch type: object properties: swap_requester_address: type: string title: address of swap requester pool_id: type: string format: uint64 description: >- id of swap type, must match the value in the pool. Only `swap_type_id` 1 is supported. swap_type_id: type: integer format: int64 description: id of swap type. Must match the value in the pool. offer_coin: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. demand_coin_denom: type: string description: >- denom of demand coin to be exchanged on the swap request, must match the denom in the pool. offer_coin_fee: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. order_price: type: string description: >- limit order price for the order, the price is the exchange ratio of X/Y where X is the amount of the first coin and Y is the amount of the second coin when their denoms are sorted alphabetically. description: >- `MsgSwapWithinBatch` defines an sdk.Msg type that supports submitting a swap offer request to the batch of the liquidity pool. Submit swap offer to the liquidity pool batch with the specified the `pool_id`, `swap_type_id`, `demand_coin_denom` with the coin and the price you're offering and `offer_coin_fee` must be half of offer coin amount * current `params.swap_fee_rate` and ceil for reservation to pay fees. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. You must request the same fields as the pool. Only the default `swap_type_id` 1 is supported. See: https://github.com/gravity-devs/liquidity/tree/develop/doc https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md description: |- SwapMsgState defines the state of the swap message that contains state information as the message is processed in the next batch or batches. description: >- the response type for the QueryPoolBatchSwapMsg RPC method. This includes a batch swap message of the batch. cyber.liquidity.v1beta1.QueryPoolBatchSwapMsgsResponse: type: object properties: swaps: type: array items: type: object properties: msg_height: type: string format: int64 title: height where this message is appended to the batch msg_index: type: string format: uint64 title: index of this swap message in this liquidity pool executed: type: boolean title: true if executed on this batch, false if not executed succeeded: type: boolean title: true if executed successfully on this batch, false if failed to_be_deleted: type: boolean title: >- true if ready to be deleted on kvstore, false if not ready to be deleted order_expiry_height: type: string format: int64 title: >- swap orders are cancelled when current height is equal to or higher than ExpiryHeight exchanged_offer_coin: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: offer coin exchanged until now remaining_offer_coin: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: offer coin currently remaining to be exchanged reserved_offer_coin_fee: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: reserve fee for pays fee in half offer coin msg: title: MsgSwapWithinBatch type: object properties: swap_requester_address: type: string title: address of swap requester pool_id: type: string format: uint64 description: >- id of swap type, must match the value in the pool. Only `swap_type_id` 1 is supported. swap_type_id: type: integer format: int64 description: id of swap type. Must match the value in the pool. offer_coin: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. demand_coin_denom: type: string description: >- denom of demand coin to be exchanged on the swap request, must match the denom in the pool. offer_coin_fee: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. order_price: type: string description: >- limit order price for the order, the price is the exchange ratio of X/Y where X is the amount of the first coin and Y is the amount of the second coin when their denoms are sorted alphabetically. description: >- `MsgSwapWithinBatch` defines an sdk.Msg type that supports submitting a swap offer request to the batch of the liquidity pool. Submit swap offer to the liquidity pool batch with the specified the `pool_id`, `swap_type_id`, `demand_coin_denom` with the coin and the price you're offering and `offer_coin_fee` must be half of offer coin amount * current `params.swap_fee_rate` and ceil for reservation to pay fees. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. You must request the same fields as the pool. Only the default `swap_type_id` 1 is supported. See: https://github.com/gravity-devs/liquidity/tree/develop/doc https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md description: >- SwapMsgState defines the state of the swap message that contains state information as the message is processed in the next batch or batches. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- the response type for the QueryPoolBatchSwapMsgs RPC method. This includes list of all currently existing swap messages of the batch and paging results that contain next_key and total count. cyber.liquidity.v1beta1.QueryPoolBatchWithdrawMsgResponse: type: object properties: withdraw: type: object properties: msg_height: type: string format: int64 title: height where this message is appended to the batch msg_index: type: string format: uint64 title: index of this withdraw message in this liquidity pool executed: type: boolean title: true if executed on this batch, false if not executed succeeded: type: boolean title: true if executed successfully on this batch, false if failed to_be_deleted: type: boolean title: >- true if ready to be deleted on kvstore, false if not ready to be deleted msg: title: MsgWithdrawWithinBatch type: object properties: withdrawer_address: type: string pool_id: type: string format: uint64 title: id of the target pool pool_coin: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- `MsgWithdrawWithinBatch` defines an `sdk.Msg` type that supports submitting a withdraw request to the batch of the liquidity pool. Withdraw is submitted to the batch from the Liquidity pool with the specified `pool_id`, `pool_coin` of the pool. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. See: https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md description: >- WithdrawMsgState defines the state of the withdraw message that contains state information as the message is processed in the next batch or batches. description: >- the response type for the QueryPoolBatchWithdrawMsg RPC method. This includes a batch swap message of the batch. cyber.liquidity.v1beta1.QueryPoolBatchWithdrawMsgsResponse: type: object properties: withdraws: type: array items: type: object properties: msg_height: type: string format: int64 title: height where this message is appended to the batch msg_index: type: string format: uint64 title: index of this withdraw message in this liquidity pool executed: type: boolean title: true if executed on this batch, false if not executed succeeded: type: boolean title: true if executed successfully on this batch, false if failed to_be_deleted: type: boolean title: >- true if ready to be deleted on kvstore, false if not ready to be deleted msg: title: MsgWithdrawWithinBatch type: object properties: withdrawer_address: type: string pool_id: type: string format: uint64 title: id of the target pool pool_coin: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- `MsgWithdrawWithinBatch` defines an `sdk.Msg` type that supports submitting a withdraw request to the batch of the liquidity pool. Withdraw is submitted to the batch from the Liquidity pool with the specified `pool_id`, `pool_coin` of the pool. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. See: https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md description: >- WithdrawMsgState defines the state of the withdraw message that contains state information as the message is processed in the next batch or batches. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- the response type for the QueryPoolBatchWithdraw RPC method. This includes a list of all currently existing withdraw messages of the batch and paging results that contain next_key and total count. cyber.liquidity.v1beta1.SwapMsgState: type: object properties: msg_height: type: string format: int64 title: height where this message is appended to the batch msg_index: type: string format: uint64 title: index of this swap message in this liquidity pool executed: type: boolean title: true if executed on this batch, false if not executed succeeded: type: boolean title: true if executed successfully on this batch, false if failed to_be_deleted: type: boolean title: >- true if ready to be deleted on kvstore, false if not ready to be deleted order_expiry_height: type: string format: int64 title: >- swap orders are cancelled when current height is equal to or higher than ExpiryHeight exchanged_offer_coin: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: offer coin exchanged until now remaining_offer_coin: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: offer coin currently remaining to be exchanged reserved_offer_coin_fee: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. title: reserve fee for pays fee in half offer coin msg: title: MsgSwapWithinBatch type: object properties: swap_requester_address: type: string title: address of swap requester pool_id: type: string format: uint64 description: >- id of swap type, must match the value in the pool. Only `swap_type_id` 1 is supported. swap_type_id: type: integer format: int64 description: id of swap type. Must match the value in the pool. offer_coin: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. demand_coin_denom: type: string description: >- denom of demand coin to be exchanged on the swap request, must match the denom in the pool. offer_coin_fee: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. order_price: type: string description: >- limit order price for the order, the price is the exchange ratio of X/Y where X is the amount of the first coin and Y is the amount of the second coin when their denoms are sorted alphabetically. description: >- `MsgSwapWithinBatch` defines an sdk.Msg type that supports submitting a swap offer request to the batch of the liquidity pool. Submit swap offer to the liquidity pool batch with the specified the `pool_id`, `swap_type_id`, `demand_coin_denom` with the coin and the price you're offering and `offer_coin_fee` must be half of offer coin amount * current `params.swap_fee_rate` and ceil for reservation to pay fees. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. You must request the same fields as the pool. Only the default `swap_type_id` 1 is supported. See: https://github.com/gravity-devs/liquidity/tree/develop/doc https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md description: |- SwapMsgState defines the state of the swap message that contains state information as the message is processed in the next batch or batches. cyber.liquidity.v1beta1.WithdrawMsgState: type: object properties: msg_height: type: string format: int64 title: height where this message is appended to the batch msg_index: type: string format: uint64 title: index of this withdraw message in this liquidity pool executed: type: boolean title: true if executed on this batch, false if not executed succeeded: type: boolean title: true if executed successfully on this batch, false if failed to_be_deleted: type: boolean title: >- true if ready to be deleted on kvstore, false if not ready to be deleted msg: title: MsgWithdrawWithinBatch type: object properties: withdrawer_address: type: string pool_id: type: string format: uint64 title: id of the target pool pool_coin: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: >- `MsgWithdrawWithinBatch` defines an `sdk.Msg` type that supports submitting a withdraw request to the batch of the liquidity pool. Withdraw is submitted to the batch from the Liquidity pool with the specified `pool_id`, `pool_coin` of the pool. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. See: https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md description: >- WithdrawMsgState defines the state of the withdraw message that contains state information as the message is processed in the next batch or batches. cosmos.app.v1alpha1.Config: type: object properties: modules: type: array items: type: object properties: name: type: string description: >- name is the unique name of the module within the app. It should be a name that persists between different versions of a module so that modules can be smoothly upgraded to new versions. For example, for the module cosmos.bank.module.v1.Module, we may chose to simply name the module "bank" in the app. When we upgrade to cosmos.bank.module.v2.Module, the app-specific name "bank" stays the same and the framework knows that the v2 module should receive all the same state that the v1 module had. Note: modules should provide info on which versions they can migrate from in the ModuleDescriptor.can_migration_from field. config: type: object properties: type_url: type: string value: type: string format: byte description: >- config is the config object for the module. Module config messages should define a ModuleDescriptor using the cosmos.app.v1alpha1.is_module extension. golang_bindings: type: array items: type: object properties: interface_type: type: string title: >- interface_type is the interface type which will be bound to a specific implementation type implementation: type: string title: >- implementation is the implementing type which will be supplied when an input of type interface is requested description: >- GolangBinding is an explicit interface type to implementing type binding for dependency injection. description: >- golang_bindings specifies explicit interface to implementation type bindings which depinject uses to resolve interface inputs to provider functions. The scope of this field's configuration is module specific. description: ModuleConfig is a module configuration for an app. description: modules are the module configurations for the app. golang_bindings: type: array items: type: object properties: interface_type: type: string title: >- interface_type is the interface type which will be bound to a specific implementation type implementation: type: string title: >- implementation is the implementing type which will be supplied when an input of type interface is requested description: >- GolangBinding is an explicit interface type to implementing type binding for dependency injection. description: >- golang_bindings specifies explicit interface to implementation type bindings which depinject uses to resolve interface inputs to provider functions. The scope of this field's configuration is global (not module specific). description: >- Config represents the configuration for a Cosmos SDK ABCI app. It is intended that all state machine logic including the version of baseapp and tx handlers (and possibly even Tendermint) that an app needs can be described in a config object. For compatibility, the framework should allow a mixture of declarative and imperative app wiring, however, apps that strive for the maximum ease of maintainability should be able to describe their state machine with a config object alone. cosmos.app.v1alpha1.GolangBinding: type: object properties: interface_type: type: string title: >- interface_type is the interface type which will be bound to a specific implementation type implementation: type: string title: >- implementation is the implementing type which will be supplied when an input of type interface is requested description: >- GolangBinding is an explicit interface type to implementing type binding for dependency injection. cosmos.app.v1alpha1.ModuleConfig: type: object properties: name: type: string description: >- name is the unique name of the module within the app. It should be a name that persists between different versions of a module so that modules can be smoothly upgraded to new versions. For example, for the module cosmos.bank.module.v1.Module, we may chose to simply name the module "bank" in the app. When we upgrade to cosmos.bank.module.v2.Module, the app-specific name "bank" stays the same and the framework knows that the v2 module should receive all the same state that the v1 module had. Note: modules should provide info on which versions they can migrate from in the ModuleDescriptor.can_migration_from field. config: type: object properties: type_url: type: string value: type: string format: byte description: >- config is the config object for the module. Module config messages should define a ModuleDescriptor using the cosmos.app.v1alpha1.is_module extension. golang_bindings: type: array items: type: object properties: interface_type: type: string title: >- interface_type is the interface type which will be bound to a specific implementation type implementation: type: string title: >- implementation is the implementing type which will be supplied when an input of type interface is requested description: >- GolangBinding is an explicit interface type to implementing type binding for dependency injection. description: >- golang_bindings specifies explicit interface to implementation type bindings which depinject uses to resolve interface inputs to provider functions. The scope of this field's configuration is module specific. description: ModuleConfig is a module configuration for an app. cosmos.app.v1alpha1.QueryConfigResponse: type: object properties: config: description: config is the current app config. type: object properties: modules: type: array items: type: object properties: name: type: string description: >- name is the unique name of the module within the app. It should be a name that persists between different versions of a module so that modules can be smoothly upgraded to new versions. For example, for the module cosmos.bank.module.v1.Module, we may chose to simply name the module "bank" in the app. When we upgrade to cosmos.bank.module.v2.Module, the app-specific name "bank" stays the same and the framework knows that the v2 module should receive all the same state that the v1 module had. Note: modules should provide info on which versions they can migrate from in the ModuleDescriptor.can_migration_from field. config: type: object properties: type_url: type: string value: type: string format: byte description: >- config is the config object for the module. Module config messages should define a ModuleDescriptor using the cosmos.app.v1alpha1.is_module extension. golang_bindings: type: array items: type: object properties: interface_type: type: string title: >- interface_type is the interface type which will be bound to a specific implementation type implementation: type: string title: >- implementation is the implementing type which will be supplied when an input of type interface is requested description: >- GolangBinding is an explicit interface type to implementing type binding for dependency injection. description: >- golang_bindings specifies explicit interface to implementation type bindings which depinject uses to resolve interface inputs to provider functions. The scope of this field's configuration is module specific. description: ModuleConfig is a module configuration for an app. description: modules are the module configurations for the app. golang_bindings: type: array items: type: object properties: interface_type: type: string title: >- interface_type is the interface type which will be bound to a specific implementation type implementation: type: string title: >- implementation is the implementing type which will be supplied when an input of type interface is requested description: >- GolangBinding is an explicit interface type to implementing type binding for dependency injection. description: >- golang_bindings specifies explicit interface to implementation type bindings which depinject uses to resolve interface inputs to provider functions. The scope of this field's configuration is global (not module specific). description: QueryConfigRequest is the Query/Config response type. cosmwasm.wasm.v1.AbsoluteTxPosition: type: object properties: block_height: type: string format: uint64 title: BlockHeight is the block the contract was created at tx_index: type: string format: uint64 title: >- TxIndex is a monotonic counter within the block (actual transaction index, or gas consumed) description: |- AbsoluteTxPosition is a unique transaction position that allows for global ordering of transactions. cosmwasm.wasm.v1.AccessConfig: type: object properties: permission: type: string enum: - ACCESS_TYPE_UNSPECIFIED - ACCESS_TYPE_NOBODY - ACCESS_TYPE_EVERYBODY - ACCESS_TYPE_ANY_OF_ADDRESSES default: ACCESS_TYPE_UNSPECIFIED description: >- - ACCESS_TYPE_UNSPECIFIED: AccessTypeUnspecified placeholder for empty value - ACCESS_TYPE_NOBODY: AccessTypeNobody forbidden - ACCESS_TYPE_EVERYBODY: AccessTypeEverybody unrestricted - ACCESS_TYPE_ANY_OF_ADDRESSES: AccessTypeAnyOfAddresses allow any of the addresses title: AccessType permission types addresses: type: array items: type: string description: AccessConfig access control type. cosmwasm.wasm.v1.AccessType: type: string enum: - ACCESS_TYPE_UNSPECIFIED - ACCESS_TYPE_NOBODY - ACCESS_TYPE_EVERYBODY - ACCESS_TYPE_ANY_OF_ADDRESSES default: ACCESS_TYPE_UNSPECIFIED description: >- - ACCESS_TYPE_UNSPECIFIED: AccessTypeUnspecified placeholder for empty value - ACCESS_TYPE_NOBODY: AccessTypeNobody forbidden - ACCESS_TYPE_EVERYBODY: AccessTypeEverybody unrestricted - ACCESS_TYPE_ANY_OF_ADDRESSES: AccessTypeAnyOfAddresses allow any of the addresses title: AccessType permission types cosmwasm.wasm.v1.CodeInfoResponse: type: object properties: code_id: type: string format: uint64 creator: type: string data_hash: type: string format: byte instantiate_permission: type: object properties: permission: type: string enum: - ACCESS_TYPE_UNSPECIFIED - ACCESS_TYPE_NOBODY - ACCESS_TYPE_EVERYBODY - ACCESS_TYPE_ANY_OF_ADDRESSES default: ACCESS_TYPE_UNSPECIFIED description: >- - ACCESS_TYPE_UNSPECIFIED: AccessTypeUnspecified placeholder for empty value - ACCESS_TYPE_NOBODY: AccessTypeNobody forbidden - ACCESS_TYPE_EVERYBODY: AccessTypeEverybody unrestricted - ACCESS_TYPE_ANY_OF_ADDRESSES: AccessTypeAnyOfAddresses allow any of the addresses title: AccessType permission types addresses: type: array items: type: string description: AccessConfig access control type. title: CodeInfoResponse contains code meta data from CodeInfo cosmwasm.wasm.v1.ContractCodeHistoryEntry: type: object properties: operation: type: string enum: - CONTRACT_CODE_HISTORY_OPERATION_TYPE_UNSPECIFIED - CONTRACT_CODE_HISTORY_OPERATION_TYPE_INIT - CONTRACT_CODE_HISTORY_OPERATION_TYPE_MIGRATE - CONTRACT_CODE_HISTORY_OPERATION_TYPE_GENESIS default: CONTRACT_CODE_HISTORY_OPERATION_TYPE_UNSPECIFIED description: >- - CONTRACT_CODE_HISTORY_OPERATION_TYPE_UNSPECIFIED: ContractCodeHistoryOperationTypeUnspecified placeholder for empty value - CONTRACT_CODE_HISTORY_OPERATION_TYPE_INIT: ContractCodeHistoryOperationTypeInit on chain contract instantiation - CONTRACT_CODE_HISTORY_OPERATION_TYPE_MIGRATE: ContractCodeHistoryOperationTypeMigrate code migration - CONTRACT_CODE_HISTORY_OPERATION_TYPE_GENESIS: ContractCodeHistoryOperationTypeGenesis based on genesis data title: ContractCodeHistoryOperationType actions that caused a code change code_id: type: string format: uint64 title: CodeID is the reference to the stored WASM code updated: description: Updated Tx position when the operation was executed. type: object properties: block_height: type: string format: uint64 title: BlockHeight is the block the contract was created at tx_index: type: string format: uint64 title: >- TxIndex is a monotonic counter within the block (actual transaction index, or gas consumed) msg: type: string format: byte description: ContractCodeHistoryEntry metadata to a contract. cosmwasm.wasm.v1.ContractCodeHistoryOperationType: type: string enum: - CONTRACT_CODE_HISTORY_OPERATION_TYPE_UNSPECIFIED - CONTRACT_CODE_HISTORY_OPERATION_TYPE_INIT - CONTRACT_CODE_HISTORY_OPERATION_TYPE_MIGRATE - CONTRACT_CODE_HISTORY_OPERATION_TYPE_GENESIS default: CONTRACT_CODE_HISTORY_OPERATION_TYPE_UNSPECIFIED description: >- - CONTRACT_CODE_HISTORY_OPERATION_TYPE_UNSPECIFIED: ContractCodeHistoryOperationTypeUnspecified placeholder for empty value - CONTRACT_CODE_HISTORY_OPERATION_TYPE_INIT: ContractCodeHistoryOperationTypeInit on chain contract instantiation - CONTRACT_CODE_HISTORY_OPERATION_TYPE_MIGRATE: ContractCodeHistoryOperationTypeMigrate code migration - CONTRACT_CODE_HISTORY_OPERATION_TYPE_GENESIS: ContractCodeHistoryOperationTypeGenesis based on genesis data title: ContractCodeHistoryOperationType actions that caused a code change cosmwasm.wasm.v1.ContractInfo: type: object properties: code_id: type: string format: uint64 title: CodeID is the reference to the stored Wasm code creator: type: string title: Creator address who initially instantiated the contract admin: type: string title: Admin is an optional address that can execute migrations label: type: string description: Label is optional metadata to be stored with a contract instance. created: description: Created Tx position when the contract was instantiated. type: object properties: block_height: type: string format: uint64 title: BlockHeight is the block the contract was created at tx_index: type: string format: uint64 title: >- TxIndex is a monotonic counter within the block (actual transaction index, or gas consumed) ibc_port_id: type: string extension: type: object properties: type_url: type: string value: type: string format: byte description: |- Extension is an extension point to store custom metadata within the persistence model. title: ContractInfo stores a WASM contract instance cosmwasm.wasm.v1.Model: type: object properties: key: type: string format: byte title: hex-encode key to read it better (this is often ascii) value: type: string format: byte title: base64-encode raw value title: Model is a struct that holds a KV pair cosmwasm.wasm.v1.Params: type: object properties: code_upload_access: type: object properties: permission: type: string enum: - ACCESS_TYPE_UNSPECIFIED - ACCESS_TYPE_NOBODY - ACCESS_TYPE_EVERYBODY - ACCESS_TYPE_ANY_OF_ADDRESSES default: ACCESS_TYPE_UNSPECIFIED description: >- - ACCESS_TYPE_UNSPECIFIED: AccessTypeUnspecified placeholder for empty value - ACCESS_TYPE_NOBODY: AccessTypeNobody forbidden - ACCESS_TYPE_EVERYBODY: AccessTypeEverybody unrestricted - ACCESS_TYPE_ANY_OF_ADDRESSES: AccessTypeAnyOfAddresses allow any of the addresses title: AccessType permission types addresses: type: array items: type: string description: AccessConfig access control type. instantiate_default_permission: type: string enum: - ACCESS_TYPE_UNSPECIFIED - ACCESS_TYPE_NOBODY - ACCESS_TYPE_EVERYBODY - ACCESS_TYPE_ANY_OF_ADDRESSES default: ACCESS_TYPE_UNSPECIFIED description: >- - ACCESS_TYPE_UNSPECIFIED: AccessTypeUnspecified placeholder for empty value - ACCESS_TYPE_NOBODY: AccessTypeNobody forbidden - ACCESS_TYPE_EVERYBODY: AccessTypeEverybody unrestricted - ACCESS_TYPE_ANY_OF_ADDRESSES: AccessTypeAnyOfAddresses allow any of the addresses title: AccessType permission types description: Params defines the set of wasm parameters. cosmwasm.wasm.v1.QueryAllContractStateResponse: type: object properties: models: type: array items: type: object properties: key: type: string format: byte title: hex-encode key to read it better (this is often ascii) value: type: string format: byte title: base64-encode raw value title: Model is a struct that holds a KV pair pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: |- QueryAllContractStateResponse is the response type for the Query/AllContractState RPC method cosmwasm.wasm.v1.QueryCodeResponse: type: object properties: code_info: type: object properties: code_id: type: string format: uint64 creator: type: string data_hash: type: string format: byte instantiate_permission: type: object properties: permission: type: string enum: - ACCESS_TYPE_UNSPECIFIED - ACCESS_TYPE_NOBODY - ACCESS_TYPE_EVERYBODY - ACCESS_TYPE_ANY_OF_ADDRESSES default: ACCESS_TYPE_UNSPECIFIED description: >- - ACCESS_TYPE_UNSPECIFIED: AccessTypeUnspecified placeholder for empty value - ACCESS_TYPE_NOBODY: AccessTypeNobody forbidden - ACCESS_TYPE_EVERYBODY: AccessTypeEverybody unrestricted - ACCESS_TYPE_ANY_OF_ADDRESSES: AccessTypeAnyOfAddresses allow any of the addresses title: AccessType permission types addresses: type: array items: type: string description: AccessConfig access control type. title: CodeInfoResponse contains code meta data from CodeInfo data: type: string format: byte title: QueryCodeResponse is the response type for the Query/Code RPC method cosmwasm.wasm.v1.QueryCodesResponse: type: object properties: code_infos: type: array items: type: object properties: code_id: type: string format: uint64 creator: type: string data_hash: type: string format: byte instantiate_permission: type: object properties: permission: type: string enum: - ACCESS_TYPE_UNSPECIFIED - ACCESS_TYPE_NOBODY - ACCESS_TYPE_EVERYBODY - ACCESS_TYPE_ANY_OF_ADDRESSES default: ACCESS_TYPE_UNSPECIFIED description: >- - ACCESS_TYPE_UNSPECIFIED: AccessTypeUnspecified placeholder for empty value - ACCESS_TYPE_NOBODY: AccessTypeNobody forbidden - ACCESS_TYPE_EVERYBODY: AccessTypeEverybody unrestricted - ACCESS_TYPE_ANY_OF_ADDRESSES: AccessTypeAnyOfAddresses allow any of the addresses title: AccessType permission types addresses: type: array items: type: string description: AccessConfig access control type. title: CodeInfoResponse contains code meta data from CodeInfo pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: QueryCodesResponse is the response type for the Query/Codes RPC method cosmwasm.wasm.v1.QueryContractHistoryResponse: type: object properties: entries: type: array items: type: object properties: operation: type: string enum: - CONTRACT_CODE_HISTORY_OPERATION_TYPE_UNSPECIFIED - CONTRACT_CODE_HISTORY_OPERATION_TYPE_INIT - CONTRACT_CODE_HISTORY_OPERATION_TYPE_MIGRATE - CONTRACT_CODE_HISTORY_OPERATION_TYPE_GENESIS default: CONTRACT_CODE_HISTORY_OPERATION_TYPE_UNSPECIFIED description: >- - CONTRACT_CODE_HISTORY_OPERATION_TYPE_UNSPECIFIED: ContractCodeHistoryOperationTypeUnspecified placeholder for empty value - CONTRACT_CODE_HISTORY_OPERATION_TYPE_INIT: ContractCodeHistoryOperationTypeInit on chain contract instantiation - CONTRACT_CODE_HISTORY_OPERATION_TYPE_MIGRATE: ContractCodeHistoryOperationTypeMigrate code migration - CONTRACT_CODE_HISTORY_OPERATION_TYPE_GENESIS: ContractCodeHistoryOperationTypeGenesis based on genesis data title: >- ContractCodeHistoryOperationType actions that caused a code change code_id: type: string format: uint64 title: CodeID is the reference to the stored WASM code updated: description: Updated Tx position when the operation was executed. type: object properties: block_height: type: string format: uint64 title: BlockHeight is the block the contract was created at tx_index: type: string format: uint64 title: >- TxIndex is a monotonic counter within the block (actual transaction index, or gas consumed) msg: type: string format: byte description: ContractCodeHistoryEntry metadata to a contract. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: |- QueryContractHistoryResponse is the response type for the Query/ContractHistory RPC method cosmwasm.wasm.v1.QueryContractInfoResponse: type: object properties: address: type: string title: address is the address of the contract contract_info: type: object properties: code_id: type: string format: uint64 title: CodeID is the reference to the stored Wasm code creator: type: string title: Creator address who initially instantiated the contract admin: type: string title: Admin is an optional address that can execute migrations label: type: string description: Label is optional metadata to be stored with a contract instance. created: description: Created Tx position when the contract was instantiated. type: object properties: block_height: type: string format: uint64 title: BlockHeight is the block the contract was created at tx_index: type: string format: uint64 title: >- TxIndex is a monotonic counter within the block (actual transaction index, or gas consumed) ibc_port_id: type: string extension: type: object properties: type_url: type: string value: type: string format: byte description: >- Extension is an extension point to store custom metadata within the persistence model. title: ContractInfo stores a WASM contract instance title: >- QueryContractInfoResponse is the response type for the Query/ContractInfo RPC method cosmwasm.wasm.v1.QueryContractsByCodeResponse: type: object properties: contracts: type: array items: type: string title: contracts are a set of contract addresses pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: |- QueryContractsByCodeResponse is the response type for the Query/ContractsByCode RPC method cosmwasm.wasm.v1.QueryContractsByCreatorResponse: type: object properties: contract_addresses: type: array items: type: string title: ContractAddresses result set pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: |- QueryContractsByCreatorResponse is the response type for the Query/ContractsByCreator RPC method. cosmwasm.wasm.v1.QueryParamsResponse: type: object properties: params: description: params defines the parameters of the module. type: object properties: code_upload_access: type: object properties: permission: type: string enum: - ACCESS_TYPE_UNSPECIFIED - ACCESS_TYPE_NOBODY - ACCESS_TYPE_EVERYBODY - ACCESS_TYPE_ANY_OF_ADDRESSES default: ACCESS_TYPE_UNSPECIFIED description: >- - ACCESS_TYPE_UNSPECIFIED: AccessTypeUnspecified placeholder for empty value - ACCESS_TYPE_NOBODY: AccessTypeNobody forbidden - ACCESS_TYPE_EVERYBODY: AccessTypeEverybody unrestricted - ACCESS_TYPE_ANY_OF_ADDRESSES: AccessTypeAnyOfAddresses allow any of the addresses title: AccessType permission types addresses: type: array items: type: string description: AccessConfig access control type. instantiate_default_permission: type: string enum: - ACCESS_TYPE_UNSPECIFIED - ACCESS_TYPE_NOBODY - ACCESS_TYPE_EVERYBODY - ACCESS_TYPE_ANY_OF_ADDRESSES default: ACCESS_TYPE_UNSPECIFIED description: >- - ACCESS_TYPE_UNSPECIFIED: AccessTypeUnspecified placeholder for empty value - ACCESS_TYPE_NOBODY: AccessTypeNobody forbidden - ACCESS_TYPE_EVERYBODY: AccessTypeEverybody unrestricted - ACCESS_TYPE_ANY_OF_ADDRESSES: AccessTypeAnyOfAddresses allow any of the addresses title: AccessType permission types description: QueryParamsResponse is the response type for the Query/Params RPC method. cosmwasm.wasm.v1.QueryPinnedCodesResponse: type: object properties: code_ids: type: array items: type: string format: uint64 pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: |- QueryPinnedCodesResponse is the response type for the Query/PinnedCodes RPC method cosmwasm.wasm.v1.QueryRawContractStateResponse: type: object properties: data: type: string format: byte title: Data contains the raw store data title: |- QueryRawContractStateResponse is the response type for the Query/RawContractState RPC method cosmwasm.wasm.v1.QuerySmartContractStateResponse: type: object properties: data: type: string format: byte title: Data contains the json data returned from the smart contract title: |- QuerySmartContractStateResponse is the response type for the Query/SmartContractState RPC method cyber.bandwidth.v1beta1.NeuronBandwidth: type: object properties: neuron: type: string remained_value: type: string format: uint64 last_updated_block: type: string format: uint64 max_value: type: string format: uint64 cyber.bandwidth.v1beta1.Params: type: object properties: recovery_period: type: string format: uint64 adjust_price_period: type: string format: uint64 base_price: type: string base_load: type: string max_block_bandwidth: type: string format: uint64 cyber.bandwidth.v1beta1.QueryLoadResponse: type: object properties: load: type: string cyber.bandwidth.v1beta1.QueryNeuronBandwidthResponse: type: object properties: neuron_bandwidth: type: object properties: neuron: type: string remained_value: type: string format: uint64 last_updated_block: type: string format: uint64 max_value: type: string format: uint64 cyber.bandwidth.v1beta1.QueryParamsResponse: type: object properties: params: type: object properties: recovery_period: type: string format: uint64 adjust_price_period: type: string format: uint64 base_price: type: string base_load: type: string max_block_bandwidth: type: string format: uint64 cyber.bandwidth.v1beta1.QueryPriceResponse: type: object properties: price: type: string cyber.bandwidth.v1beta1.QueryTotalBandwidthResponse: type: object properties: total_bandwidth: type: string format: uint64 cosmos.base.tendermint.v1beta1.ABCIQueryResponse: type: object properties: code: type: integer format: int64 log: type: string info: type: string index: type: string format: int64 key: type: string format: byte value: type: string format: byte proof_ops: type: object properties: ops: type: array items: type: object properties: type: type: string key: type: string format: byte data: type: string format: byte description: >- ProofOp defines an operation used for calculating Merkle root. The data could be arbitrary format, providing necessary data for example neighbouring node hash. Note: This type is a duplicate of the ProofOp proto type defined in Tendermint. description: >- ProofOps is Merkle proof defined by the list of ProofOps. Note: This type is a duplicate of the ProofOps proto type defined in Tendermint. height: type: string format: int64 codespace: type: string description: >- ABCIQueryResponse defines the response structure for the ABCIQuery gRPC query. Note: This type is a duplicate of the ResponseQuery proto type defined in Tendermint. cosmos.base.tendermint.v1beta1.Block: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string description: >- proposer_address is the original block proposer address, formatted as a Bech32 string. In Tendermint, this type is `bytes`, but in the SDK, we convert it to a Bech32 string for better UX. description: Header defines the structure of a Tendermint block header. data: type: object properties: txs: type: array items: type: string format: byte description: >- Txs that will be applied by state @ block.Height+1. NOTE: not all txs here are valid. We're just agreeing on the order first. This means that block.AppHash does not include these txs. title: Data contains the set of transactions included in the block evidence: type: object properties: evidence: type: array items: type: object properties: duplicate_vote_evidence: type: object properties: vote_a: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. vote_b: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. total_voting_power: type: string format: int64 validator_power: type: string format: int64 timestamp: type: string format: date-time description: >- DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes. light_client_attack_evidence: type: object properties: conflicting_block: type: object properties: signed_header: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: >- hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: >- BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: >- CommitSig is a part of the Vote included in a Commit. description: >- Commit contains the evidence that a block was committed by a set of validators. validator_set: type: object properties: validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 proposer: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 common_height: type: string format: int64 byzantine_validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 timestamp: type: string format: date-time description: >- LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client. last_commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: >- Commit contains the evidence that a block was committed by a set of validators. description: |- Block is tendermint type Block, with the Header proposer address field converted to bech32 string. cosmos.base.tendermint.v1beta1.GetBlockByHeightResponse: type: object properties: block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID block: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. data: type: object properties: txs: type: array items: type: string format: byte description: >- Txs that will be applied by state @ block.Height+1. NOTE: not all txs here are valid. We're just agreeing on the order first. This means that block.AppHash does not include these txs. title: Data contains the set of transactions included in the block evidence: type: object properties: evidence: type: array items: type: object properties: duplicate_vote_evidence: type: object properties: vote_a: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. vote_b: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. total_voting_power: type: string format: int64 validator_power: type: string format: int64 timestamp: type: string format: date-time description: >- DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes. light_client_attack_evidence: type: object properties: conflicting_block: type: object properties: signed_header: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: >- hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: >- Header defines the structure of a block header. commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: >- BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: >- CommitSig is a part of the Vote included in a Commit. description: >- Commit contains the evidence that a block was committed by a set of validators. validator_set: type: object properties: validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 proposer: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 common_height: type: string format: int64 byzantine_validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 timestamp: type: string format: date-time description: >- LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client. last_commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: >- Commit contains the evidence that a block was committed by a set of validators. title: 'Deprecated: please use `sdk_block` instead' sdk_block: title: 'Since: cosmos-sdk 0.47' type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string description: >- proposer_address is the original block proposer address, formatted as a Bech32 string. In Tendermint, this type is `bytes`, but in the SDK, we convert it to a Bech32 string for better UX. description: Header defines the structure of a Tendermint block header. data: type: object properties: txs: type: array items: type: string format: byte description: >- Txs that will be applied by state @ block.Height+1. NOTE: not all txs here are valid. We're just agreeing on the order first. This means that block.AppHash does not include these txs. title: Data contains the set of transactions included in the block evidence: type: object properties: evidence: type: array items: type: object properties: duplicate_vote_evidence: type: object properties: vote_a: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. vote_b: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. total_voting_power: type: string format: int64 validator_power: type: string format: int64 timestamp: type: string format: date-time description: >- DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes. light_client_attack_evidence: type: object properties: conflicting_block: type: object properties: signed_header: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: >- hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: >- Header defines the structure of a block header. commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: >- BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: >- CommitSig is a part of the Vote included in a Commit. description: >- Commit contains the evidence that a block was committed by a set of validators. validator_set: type: object properties: validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 proposer: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 common_height: type: string format: int64 byzantine_validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 timestamp: type: string format: date-time description: >- LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client. last_commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: >- Commit contains the evidence that a block was committed by a set of validators. description: |- Block is tendermint type Block, with the Header proposer address field converted to bech32 string. description: >- GetBlockByHeightResponse is the response type for the Query/GetBlockByHeight RPC method. cosmos.base.tendermint.v1beta1.GetLatestBlockResponse: type: object properties: block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID block: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: Header defines the structure of a block header. data: type: object properties: txs: type: array items: type: string format: byte description: >- Txs that will be applied by state @ block.Height+1. NOTE: not all txs here are valid. We're just agreeing on the order first. This means that block.AppHash does not include these txs. title: Data contains the set of transactions included in the block evidence: type: object properties: evidence: type: array items: type: object properties: duplicate_vote_evidence: type: object properties: vote_a: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. vote_b: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. total_voting_power: type: string format: int64 validator_power: type: string format: int64 timestamp: type: string format: date-time description: >- DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes. light_client_attack_evidence: type: object properties: conflicting_block: type: object properties: signed_header: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: >- hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: >- Header defines the structure of a block header. commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: >- BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: >- CommitSig is a part of the Vote included in a Commit. description: >- Commit contains the evidence that a block was committed by a set of validators. validator_set: type: object properties: validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 proposer: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 common_height: type: string format: int64 byzantine_validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 timestamp: type: string format: date-time description: >- LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client. last_commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: >- Commit contains the evidence that a block was committed by a set of validators. title: 'Deprecated: please use `sdk_block` instead' sdk_block: title: 'Since: cosmos-sdk 0.47' type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string description: >- proposer_address is the original block proposer address, formatted as a Bech32 string. In Tendermint, this type is `bytes`, but in the SDK, we convert it to a Bech32 string for better UX. description: Header defines the structure of a Tendermint block header. data: type: object properties: txs: type: array items: type: string format: byte description: >- Txs that will be applied by state @ block.Height+1. NOTE: not all txs here are valid. We're just agreeing on the order first. This means that block.AppHash does not include these txs. title: Data contains the set of transactions included in the block evidence: type: object properties: evidence: type: array items: type: object properties: duplicate_vote_evidence: type: object properties: vote_a: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. vote_b: type: object properties: type: type: string enum: - SIGNED_MSG_TYPE_UNKNOWN - SIGNED_MSG_TYPE_PREVOTE - SIGNED_MSG_TYPE_PRECOMMIT - SIGNED_MSG_TYPE_PROPOSAL default: SIGNED_MSG_TYPE_UNKNOWN description: >- SignedMsgType is a type of signed message in the consensus. - SIGNED_MSG_TYPE_PREVOTE: Votes - SIGNED_MSG_TYPE_PROPOSAL: Proposals height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID timestamp: type: string format: date-time validator_address: type: string format: byte validator_index: type: integer format: int32 signature: type: string format: byte description: >- Vote represents a prevote, precommit, or commit vote from validators for consensus. total_voting_power: type: string format: int64 validator_power: type: string format: int64 timestamp: type: string format: date-time description: >- DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes. light_client_attack_evidence: type: object properties: conflicting_block: type: object properties: signed_header: type: object properties: header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: title: prev block info type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: >- hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string format: byte description: >- Header defines the structure of a block header. commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: >- BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: >- CommitSig is a part of the Vote included in a Commit. description: >- Commit contains the evidence that a block was committed by a set of validators. validator_set: type: object properties: validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 proposer: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 common_height: type: string format: int64 byzantine_validators: type: array items: type: object properties: address: type: string format: byte pub_key: type: object properties: ed25519: type: string format: byte secp256k1: type: string format: byte title: >- PublicKey defines the keys available for use with Validators voting_power: type: string format: int64 proposer_priority: type: string format: int64 total_voting_power: type: string format: int64 timestamp: type: string format: date-time description: >- LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client. last_commit: type: object properties: height: type: string format: int64 round: type: integer format: int32 block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID signatures: type: array items: type: object properties: block_id_flag: type: string enum: - BLOCK_ID_FLAG_UNKNOWN - BLOCK_ID_FLAG_ABSENT - BLOCK_ID_FLAG_COMMIT - BLOCK_ID_FLAG_NIL default: BLOCK_ID_FLAG_UNKNOWN title: BlockIdFlag indicates which BlcokID the signature is for validator_address: type: string format: byte timestamp: type: string format: date-time signature: type: string format: byte description: CommitSig is a part of the Vote included in a Commit. description: >- Commit contains the evidence that a block was committed by a set of validators. description: |- Block is tendermint type Block, with the Header proposer address field converted to bech32 string. description: >- GetLatestBlockResponse is the response type for the Query/GetLatestBlock RPC method. cosmos.base.tendermint.v1beta1.GetLatestValidatorSetResponse: type: object properties: block_height: type: string format: int64 validators: type: array items: type: object properties: address: type: string pub_key: type: object properties: type_url: type: string value: type: string format: byte voting_power: type: string format: int64 proposer_priority: type: string format: int64 description: Validator is the type for the validator-set. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- GetLatestValidatorSetResponse is the response type for the Query/GetValidatorSetByHeight RPC method. cosmos.base.tendermint.v1beta1.GetNodeInfoResponse: type: object properties: default_node_info: type: object properties: protocol_version: type: object properties: p2p: type: string format: uint64 block: type: string format: uint64 app: type: string format: uint64 default_node_id: type: string listen_addr: type: string network: type: string version: type: string channels: type: string format: byte moniker: type: string other: type: object properties: tx_index: type: string rpc_address: type: string application_version: type: object properties: name: type: string app_name: type: string version: type: string git_commit: type: string build_tags: type: string go_version: type: string build_deps: type: array items: type: object properties: path: type: string title: module path version: type: string title: module version sum: type: string title: checksum title: Module is the type for VersionInfo cosmos_sdk_version: type: string title: 'Since: cosmos-sdk 0.43' description: VersionInfo is the type for the GetNodeInfoResponse message. description: >- GetNodeInfoResponse is the response type for the Query/GetNodeInfo RPC method. cosmos.base.tendermint.v1beta1.GetSyncingResponse: type: object properties: syncing: type: boolean description: >- GetSyncingResponse is the response type for the Query/GetSyncing RPC method. cosmos.base.tendermint.v1beta1.GetValidatorSetByHeightResponse: type: object properties: block_height: type: string format: int64 validators: type: array items: type: object properties: address: type: string pub_key: type: object properties: type_url: type: string value: type: string format: byte voting_power: type: string format: int64 proposer_priority: type: string format: int64 description: Validator is the type for the validator-set. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- GetValidatorSetByHeightResponse is the response type for the Query/GetValidatorSetByHeight RPC method. cosmos.base.tendermint.v1beta1.Header: type: object properties: version: title: basic block info type: object properties: block: type: string format: uint64 app: type: string format: uint64 description: >- Consensus captures the consensus rules for processing a block in the blockchain, including all blockchain data structures and the rules of the application's state transition machine. chain_id: type: string height: type: string format: int64 time: type: string format: date-time last_block_id: type: object properties: hash: type: string format: byte part_set_header: type: object properties: total: type: integer format: int64 hash: type: string format: byte title: PartsetHeader title: BlockID last_commit_hash: type: string format: byte title: hashes of block data data_hash: type: string format: byte validators_hash: type: string format: byte title: hashes from the app output from the prev block next_validators_hash: type: string format: byte consensus_hash: type: string format: byte app_hash: type: string format: byte last_results_hash: type: string format: byte evidence_hash: type: string format: byte title: consensus info proposer_address: type: string description: >- proposer_address is the original block proposer address, formatted as a Bech32 string. In Tendermint, this type is `bytes`, but in the SDK, we convert it to a Bech32 string for better UX. description: Header defines the structure of a Tendermint block header. cosmos.base.tendermint.v1beta1.Module: type: object properties: path: type: string title: module path version: type: string title: module version sum: type: string title: checksum title: Module is the type for VersionInfo cosmos.base.tendermint.v1beta1.ProofOp: type: object properties: type: type: string key: type: string format: byte data: type: string format: byte description: >- ProofOp defines an operation used for calculating Merkle root. The data could be arbitrary format, providing necessary data for example neighbouring node hash. Note: This type is a duplicate of the ProofOp proto type defined in Tendermint. cosmos.base.tendermint.v1beta1.ProofOps: type: object properties: ops: type: array items: type: object properties: type: type: string key: type: string format: byte data: type: string format: byte description: >- ProofOp defines an operation used for calculating Merkle root. The data could be arbitrary format, providing necessary data for example neighbouring node hash. Note: This type is a duplicate of the ProofOp proto type defined in Tendermint. description: >- ProofOps is Merkle proof defined by the list of ProofOps. Note: This type is a duplicate of the ProofOps proto type defined in Tendermint. cosmos.base.tendermint.v1beta1.Validator: type: object properties: address: type: string pub_key: type: object properties: type_url: type: string value: type: string format: byte voting_power: type: string format: int64 proposer_priority: type: string format: int64 description: Validator is the type for the validator-set. cosmos.base.tendermint.v1beta1.VersionInfo: type: object properties: name: type: string app_name: type: string version: type: string git_commit: type: string build_tags: type: string go_version: type: string build_deps: type: array items: type: object properties: path: type: string title: module path version: type: string title: module version sum: type: string title: checksum title: Module is the type for VersionInfo cosmos_sdk_version: type: string title: 'Since: cosmos-sdk 0.43' description: VersionInfo is the type for the GetNodeInfoResponse message. tendermint.p2p.DefaultNodeInfo: type: object properties: protocol_version: type: object properties: p2p: type: string format: uint64 block: type: string format: uint64 app: type: string format: uint64 default_node_id: type: string listen_addr: type: string network: type: string version: type: string channels: type: string format: byte moniker: type: string other: type: object properties: tx_index: type: string rpc_address: type: string tendermint.p2p.DefaultNodeInfoOther: type: object properties: tx_index: type: string rpc_address: type: string tendermint.p2p.ProtocolVersion: type: object properties: p2p: type: string format: uint64 block: type: string format: uint64 app: type: string format: uint64 cosmos.slashing.v1beta1.Params: type: object properties: signed_blocks_window: type: string format: int64 min_signed_per_window: type: string format: byte downtime_jail_duration: type: string slash_fraction_double_sign: type: string format: byte slash_fraction_downtime: type: string format: byte description: Params represents the parameters used for by the slashing module. cosmos.slashing.v1beta1.QueryParamsResponse: type: object properties: params: type: object properties: signed_blocks_window: type: string format: int64 min_signed_per_window: type: string format: byte downtime_jail_duration: type: string slash_fraction_double_sign: type: string format: byte slash_fraction_downtime: type: string format: byte description: Params represents the parameters used for by the slashing module. title: QueryParamsResponse is the response type for the Query/Params RPC method cosmos.slashing.v1beta1.QuerySigningInfoResponse: type: object properties: val_signing_info: type: object properties: address: type: string start_height: type: string format: int64 title: Height at which validator was first a candidate OR was unjailed index_offset: type: string format: int64 description: >- Index which is incremented each time the validator was a bonded in a block and may have signed a precommit or not. This in conjunction with the `SignedBlocksWindow` param determines the index in the `MissedBlocksBitArray`. jailed_until: type: string format: date-time description: >- Timestamp until which the validator is jailed due to liveness downtime. tombstoned: type: boolean description: >- Whether or not a validator has been tombstoned (killed out of validator set). It is set once the validator commits an equivocation or for any other configured misbehiavor. missed_blocks_counter: type: string format: int64 description: >- A counter kept to avoid unnecessary array reads. Note that `Sum(MissedBlocksBitArray)` always equals `MissedBlocksCounter`. description: >- ValidatorSigningInfo defines a validator's signing info for monitoring their liveness activity. title: val_signing_info is the signing info of requested val cons address title: >- QuerySigningInfoResponse is the response type for the Query/SigningInfo RPC method cosmos.slashing.v1beta1.QuerySigningInfosResponse: type: object properties: info: type: array items: type: object properties: address: type: string start_height: type: string format: int64 title: Height at which validator was first a candidate OR was unjailed index_offset: type: string format: int64 description: >- Index which is incremented each time the validator was a bonded in a block and may have signed a precommit or not. This in conjunction with the `SignedBlocksWindow` param determines the index in the `MissedBlocksBitArray`. jailed_until: type: string format: date-time description: >- Timestamp until which the validator is jailed due to liveness downtime. tombstoned: type: boolean description: >- Whether or not a validator has been tombstoned (killed out of validator set). It is set once the validator commits an equivocation or for any other configured misbehiavor. missed_blocks_counter: type: string format: int64 description: >- A counter kept to avoid unnecessary array reads. Note that `Sum(MissedBlocksBitArray)` always equals `MissedBlocksCounter`. description: >- ValidatorSigningInfo defines a validator's signing info for monitoring their liveness activity. title: info is the signing info of all validators pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } title: >- QuerySigningInfosResponse is the response type for the Query/SigningInfos RPC method cosmos.slashing.v1beta1.ValidatorSigningInfo: type: object properties: address: type: string start_height: type: string format: int64 title: Height at which validator was first a candidate OR was unjailed index_offset: type: string format: int64 description: >- Index which is incremented each time the validator was a bonded in a block and may have signed a precommit or not. This in conjunction with the `SignedBlocksWindow` param determines the index in the `MissedBlocksBitArray`. jailed_until: type: string format: date-time description: >- Timestamp until which the validator is jailed due to liveness downtime. tombstoned: type: boolean description: >- Whether or not a validator has been tombstoned (killed out of validator set). It is set once the validator commits an equivocation or for any other configured misbehiavor. missed_blocks_counter: type: string format: int64 description: >- A counter kept to avoid unnecessary array reads. Note that `Sum(MissedBlocksBitArray)` always equals `MissedBlocksCounter`. description: >- ValidatorSigningInfo defines a validator's signing info for monitoring their liveness activity. cosmos.gov.v1beta1.Deposit: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. depositor: type: string description: depositor defines the deposit addresses from the proposals. amount: type: array items: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: amount to be deposited by depositor. description: |- Deposit defines an amount deposited by an account address to an active proposal. cosmos.gov.v1beta1.DepositParams: type: object properties: min_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: Minimum deposit for a proposal to enter voting period. max_deposit_period: type: string description: >- Maximum period for Atom holders to deposit on a proposal. Initial value: 2 months. description: DepositParams defines the params for deposits on governance proposals. cosmos.gov.v1beta1.Proposal: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. content: type: object properties: type_url: type: string value: type: string format: byte description: content is the proposal's content. status: description: status defines the proposal status. type: string enum: - PROPOSAL_STATUS_UNSPECIFIED - PROPOSAL_STATUS_DEPOSIT_PERIOD - PROPOSAL_STATUS_VOTING_PERIOD - PROPOSAL_STATUS_PASSED - PROPOSAL_STATUS_REJECTED - PROPOSAL_STATUS_FAILED default: PROPOSAL_STATUS_UNSPECIFIED final_tally_result: description: |- final_tally_result is the final tally result of the proposal. When querying a proposal via gRPC, this field is not populated until the proposal's voting period has ended. type: object properties: 'yes': type: string description: yes is the number of yes votes on a proposal. abstain: type: string description: abstain is the number of abstain votes on a proposal. 'no': type: string description: no is the number of no votes on a proposal. no_with_veto: type: string description: no_with_veto is the number of no with veto votes on a proposal. submit_time: type: string format: date-time description: submit_time is the time of proposal submission. deposit_end_time: type: string format: date-time description: deposit_end_time is the end time for deposition. total_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: |- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: total_deposit is the total deposit on the proposal. voting_start_time: type: string format: date-time description: voting_start_time is the starting time to vote on a proposal. voting_end_time: type: string format: date-time description: voting_end_time is the end time of voting on a proposal. description: Proposal defines the core field members of a governance proposal. cosmos.gov.v1beta1.ProposalStatus: type: string enum: - PROPOSAL_STATUS_UNSPECIFIED - PROPOSAL_STATUS_DEPOSIT_PERIOD - PROPOSAL_STATUS_VOTING_PERIOD - PROPOSAL_STATUS_PASSED - PROPOSAL_STATUS_REJECTED - PROPOSAL_STATUS_FAILED default: PROPOSAL_STATUS_UNSPECIFIED description: |- ProposalStatus enumerates the valid statuses of a proposal. - PROPOSAL_STATUS_UNSPECIFIED: PROPOSAL_STATUS_UNSPECIFIED defines the default proposal status. - PROPOSAL_STATUS_DEPOSIT_PERIOD: PROPOSAL_STATUS_DEPOSIT_PERIOD defines a proposal status during the deposit period. - PROPOSAL_STATUS_VOTING_PERIOD: PROPOSAL_STATUS_VOTING_PERIOD defines a proposal status during the voting period. - PROPOSAL_STATUS_PASSED: PROPOSAL_STATUS_PASSED defines a proposal status of a proposal that has passed. - PROPOSAL_STATUS_REJECTED: PROPOSAL_STATUS_REJECTED defines a proposal status of a proposal that has been rejected. - PROPOSAL_STATUS_FAILED: PROPOSAL_STATUS_FAILED defines a proposal status of a proposal that has failed. cosmos.gov.v1beta1.QueryDepositResponse: type: object properties: deposit: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. depositor: type: string description: depositor defines the deposit addresses from the proposals. amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: amount to be deposited by depositor. description: |- Deposit defines an amount deposited by an account address to an active proposal. description: >- QueryDepositResponse is the response type for the Query/Deposit RPC method. cosmos.gov.v1beta1.QueryDepositsResponse: type: object properties: deposits: type: array items: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. depositor: type: string description: depositor defines the deposit addresses from the proposals. amount: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: amount to be deposited by depositor. description: >- Deposit defines an amount deposited by an account address to an active proposal. description: deposits defines the requested deposits. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: >- QueryDepositsResponse is the response type for the Query/Deposits RPC method. cosmos.gov.v1beta1.QueryParamsResponse: type: object properties: voting_params: description: voting_params defines the parameters related to voting. type: object properties: voting_period: type: string description: Duration of the voting period. deposit_params: description: deposit_params defines the parameters related to deposit. type: object properties: min_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: Minimum deposit for a proposal to enter voting period. max_deposit_period: type: string description: >- Maximum period for Atom holders to deposit on a proposal. Initial value: 2 months. tally_params: description: tally_params defines the parameters related to tally. type: object properties: quorum: type: string format: byte description: >- Minimum percentage of total stake needed to vote for a result to be considered valid. threshold: type: string format: byte description: >- Minimum proportion of Yes votes for proposal to pass. Default value: 0.5. veto_threshold: type: string format: byte description: >- Minimum value of Veto votes to Total votes ratio for proposal to be vetoed. Default value: 1/3. description: QueryParamsResponse is the response type for the Query/Params RPC method. cosmos.gov.v1beta1.QueryProposalResponse: type: object properties: proposal: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. content: type: object properties: type_url: type: string value: type: string format: byte description: content is the proposal's content. status: description: status defines the proposal status. type: string enum: - PROPOSAL_STATUS_UNSPECIFIED - PROPOSAL_STATUS_DEPOSIT_PERIOD - PROPOSAL_STATUS_VOTING_PERIOD - PROPOSAL_STATUS_PASSED - PROPOSAL_STATUS_REJECTED - PROPOSAL_STATUS_FAILED default: PROPOSAL_STATUS_UNSPECIFIED final_tally_result: description: >- final_tally_result is the final tally result of the proposal. When querying a proposal via gRPC, this field is not populated until the proposal's voting period has ended. type: object properties: 'yes': type: string description: yes is the number of yes votes on a proposal. abstain: type: string description: abstain is the number of abstain votes on a proposal. 'no': type: string description: no is the number of no votes on a proposal. no_with_veto: type: string description: >- no_with_veto is the number of no with veto votes on a proposal. submit_time: type: string format: date-time description: submit_time is the time of proposal submission. deposit_end_time: type: string format: date-time description: deposit_end_time is the end time for deposition. total_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: total_deposit is the total deposit on the proposal. voting_start_time: type: string format: date-time description: voting_start_time is the starting time to vote on a proposal. voting_end_time: type: string format: date-time description: voting_end_time is the end time of voting on a proposal. description: Proposal defines the core field members of a governance proposal. description: >- QueryProposalResponse is the response type for the Query/Proposal RPC method. cosmos.gov.v1beta1.QueryProposalsResponse: type: object properties: proposals: type: array items: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. content: type: object properties: type_url: type: string value: type: string format: byte description: content is the proposal's content. status: description: status defines the proposal status. type: string enum: - PROPOSAL_STATUS_UNSPECIFIED - PROPOSAL_STATUS_DEPOSIT_PERIOD - PROPOSAL_STATUS_VOTING_PERIOD - PROPOSAL_STATUS_PASSED - PROPOSAL_STATUS_REJECTED - PROPOSAL_STATUS_FAILED default: PROPOSAL_STATUS_UNSPECIFIED final_tally_result: description: >- final_tally_result is the final tally result of the proposal. When querying a proposal via gRPC, this field is not populated until the proposal's voting period has ended. type: object properties: 'yes': type: string description: yes is the number of yes votes on a proposal. abstain: type: string description: abstain is the number of abstain votes on a proposal. 'no': type: string description: no is the number of no votes on a proposal. no_with_veto: type: string description: >- no_with_veto is the number of no with veto votes on a proposal. submit_time: type: string format: date-time description: submit_time is the time of proposal submission. deposit_end_time: type: string format: date-time description: deposit_end_time is the end time for deposition. total_deposit: type: array items: type: object properties: denom: type: string amount: type: string description: >- Coin defines a token with a denomination and an amount. NOTE: The amount field is an Int which implements the custom method signatures required by gogoproto. description: total_deposit is the total deposit on the proposal. voting_start_time: type: string format: date-time description: voting_start_time is the starting time to vote on a proposal. voting_end_time: type: string format: date-time description: voting_end_time is the end time of voting on a proposal. description: Proposal defines the core field members of a governance proposal. description: proposals defines all the requested governance proposals. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: |- QueryProposalsResponse is the response type for the Query/Proposals RPC method. cosmos.gov.v1beta1.QueryTallyResultResponse: type: object properties: tally: description: tally defines the requested tally. type: object properties: 'yes': type: string description: yes is the number of yes votes on a proposal. abstain: type: string description: abstain is the number of abstain votes on a proposal. 'no': type: string description: no is the number of no votes on a proposal. no_with_veto: type: string description: no_with_veto is the number of no with veto votes on a proposal. description: >- QueryTallyResultResponse is the response type for the Query/Tally RPC method. cosmos.gov.v1beta1.QueryVoteResponse: type: object properties: vote: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. voter: type: string description: voter is the voter address of the proposal. option: description: >- Deprecated: Prefer to use `options` instead. This field is set in queries if and only if `len(options) == 1` and that option has weight 1. In all other cases, this field will default to VOTE_OPTION_UNSPECIFIED. type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED options: type: array items: type: object properties: option: description: >- option defines the valid vote options, it must not contain duplicate vote options. type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED weight: type: string description: weight is the vote weight associated with the vote option. description: |- WeightedVoteOption defines a unit of vote for vote split. Since: cosmos-sdk 0.43 description: |- options is the weighted vote options. Since: cosmos-sdk 0.43 description: |- Vote defines a vote on a governance proposal. A Vote consists of a proposal ID, the voter, and the vote option. description: QueryVoteResponse is the response type for the Query/Vote RPC method. cosmos.gov.v1beta1.QueryVotesResponse: type: object properties: votes: type: array items: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. voter: type: string description: voter is the voter address of the proposal. option: description: >- Deprecated: Prefer to use `options` instead. This field is set in queries if and only if `len(options) == 1` and that option has weight 1. In all other cases, this field will default to VOTE_OPTION_UNSPECIFIED. type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED options: type: array items: type: object properties: option: description: >- option defines the valid vote options, it must not contain duplicate vote options. type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED weight: type: string description: weight is the vote weight associated with the vote option. description: |- WeightedVoteOption defines a unit of vote for vote split. Since: cosmos-sdk 0.43 description: |- options is the weighted vote options. Since: cosmos-sdk 0.43 description: |- Vote defines a vote on a governance proposal. A Vote consists of a proposal ID, the voter, and the vote option. description: votes defines the queried votes. pagination: type: object properties: next_key: type: string format: byte description: |- next_key is the key to be passed to PageRequest.key to query the next page most efficiently. It will be empty if there are no more results. total: type: string format: uint64 title: >- total is total number of results available if PageRequest.count_total was set, its value is undefined otherwise description: |- PageResponse is to be embedded in gRPC response messages where the corresponding request message has used PageRequest. message SomeResponse { repeated Bar results = 1; PageResponse page = 2; } description: QueryVotesResponse is the response type for the Query/Votes RPC method. cosmos.gov.v1beta1.TallyParams: type: object properties: quorum: type: string format: byte description: |- Minimum percentage of total stake needed to vote for a result to be considered valid. threshold: type: string format: byte description: >- Minimum proportion of Yes votes for proposal to pass. Default value: 0.5. veto_threshold: type: string format: byte description: |- Minimum value of Veto votes to Total votes ratio for proposal to be vetoed. Default value: 1/3. description: TallyParams defines the params for tallying votes on governance proposals. cosmos.gov.v1beta1.TallyResult: type: object properties: 'yes': type: string description: yes is the number of yes votes on a proposal. abstain: type: string description: abstain is the number of abstain votes on a proposal. 'no': type: string description: no is the number of no votes on a proposal. no_with_veto: type: string description: no_with_veto is the number of no with veto votes on a proposal. description: TallyResult defines a standard tally for a governance proposal. cosmos.gov.v1beta1.Vote: type: object properties: proposal_id: type: string format: uint64 description: proposal_id defines the unique id of the proposal. voter: type: string description: voter is the voter address of the proposal. option: description: >- Deprecated: Prefer to use `options` instead. This field is set in queries if and only if `len(options) == 1` and that option has weight 1. In all other cases, this field will default to VOTE_OPTION_UNSPECIFIED. type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED options: type: array items: type: object properties: option: description: >- option defines the valid vote options, it must not contain duplicate vote options. type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED weight: type: string description: weight is the vote weight associated with the vote option. description: |- WeightedVoteOption defines a unit of vote for vote split. Since: cosmos-sdk 0.43 description: |- options is the weighted vote options. Since: cosmos-sdk 0.43 description: |- Vote defines a vote on a governance proposal. A Vote consists of a proposal ID, the voter, and the vote option. cosmos.gov.v1beta1.VoteOption: type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED description: >- VoteOption enumerates the valid vote options for a given governance proposal. - VOTE_OPTION_UNSPECIFIED: VOTE_OPTION_UNSPECIFIED defines a no-op vote option. - VOTE_OPTION_YES: VOTE_OPTION_YES defines a yes vote option. - VOTE_OPTION_ABSTAIN: VOTE_OPTION_ABSTAIN defines an abstain vote option. - VOTE_OPTION_NO: VOTE_OPTION_NO defines a no vote option. - VOTE_OPTION_NO_WITH_VETO: VOTE_OPTION_NO_WITH_VETO defines a no with veto vote option. cosmos.gov.v1beta1.VotingParams: type: object properties: voting_period: type: string description: Duration of the voting period. description: VotingParams defines the params for voting on governance proposals. cosmos.gov.v1beta1.WeightedVoteOption: type: object properties: option: description: >- option defines the valid vote options, it must not contain duplicate vote options. type: string enum: - VOTE_OPTION_UNSPECIFIED - VOTE_OPTION_YES - VOTE_OPTION_ABSTAIN - VOTE_OPTION_NO - VOTE_OPTION_NO_WITH_VETO default: VOTE_OPTION_UNSPECIFIED weight: type: string description: weight is the vote weight associated with the vote option. description: |- WeightedVoteOption defines a unit of vote for vote split. Since: cosmos-sdk 0.43 cosmos.mint.v1beta1.Params: type: object properties: mint_denom: type: string title: type of coin to mint inflation_rate_change: type: string title: maximum annual change in inflation rate inflation_max: type: string title: maximum inflation rate inflation_min: type: string title: minimum inflation rate goal_bonded: type: string title: goal of percent bonded atoms blocks_per_year: type: string format: uint64 title: expected blocks per year description: Params defines the parameters for the x/mint module. cosmos.mint.v1beta1.QueryAnnualProvisionsResponse: type: object properties: annual_provisions: type: string format: byte description: annual_provisions is the current minting annual provisions value. description: |- QueryAnnualProvisionsResponse is the response type for the Query/AnnualProvisions RPC method. cosmos.mint.v1beta1.QueryInflationResponse: type: object properties: inflation: type: string format: byte description: inflation is the current minting inflation value. description: |- QueryInflationResponse is the response type for the Query/Inflation RPC method. cosmos.mint.v1beta1.QueryParamsResponse: type: object properties: params: description: params defines the parameters of the module. type: object properties: mint_denom: type: string title: type of coin to mint inflation_rate_change: type: string title: maximum annual change in inflation rate inflation_max: type: string title: maximum inflation rate inflation_min: type: string title: minimum inflation rate goal_bonded: type: string title: goal of percent bonded atoms blocks_per_year: type: string format: uint64 title: expected blocks per year description: QueryParamsResponse is the response type for the Query/Params RPC method. ================================================ FILE: client/docs/template/index.tpl ================================================ {{ .Title }}
Footer © 2022 GitHub, Inc. Footer navigation ================================================ FILE: cmd/cyber/cmd/root.go ================================================ package cmd import ( "errors" "io" "os" "path/filepath" "github.com/cometbft/cometbft/crypto" "github.com/cometbft/cometbft/libs/bytes" "github.com/cosmos/cosmos-sdk/baseapp" "github.com/cosmos/cosmos-sdk/snapshots" snapshottypes "github.com/cosmos/cosmos-sdk/snapshots/types" "github.com/cosmos/cosmos-sdk/store" storetypes "github.com/cosmos/cosmos-sdk/store/types" genutiltypes "github.com/cosmos/cosmos-sdk/x/genutil/types" upgradetypes "github.com/cosmos/cosmos-sdk/x/upgrade/types" v6 "github.com/cybercongress/go-cyber/v7/app/upgrades/v6" "cosmossdk.io/simapp/params" wasmkeeper "github.com/CosmWasm/wasmd/x/wasm/keeper" wasmtypes "github.com/CosmWasm/wasmd/x/wasm/types" tmcfg "github.com/cometbft/cometbft/config" "github.com/cosmos/cosmos-sdk/client/config" "github.com/cosmos/cosmos-sdk/client/pruning" "github.com/prometheus/client_golang/prometheus" "github.com/cybercongress/go-cyber/v7/app" "github.com/CosmWasm/wasmd/x/wasm" "github.com/cosmos/cosmos-sdk/x/crisis" "github.com/cybercongress/go-cyber/v7/x/rank" dbm "github.com/cometbft/cometbft-db" tmcli "github.com/cometbft/cometbft/libs/cli" "github.com/cometbft/cometbft/libs/log" "github.com/spf13/cast" "github.com/spf13/cobra" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/debug" "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/client/keys" "github.com/cosmos/cosmos-sdk/client/rpc" "github.com/cosmos/cosmos-sdk/server" servertypes "github.com/cosmos/cosmos-sdk/server/types" authcmd "github.com/cosmos/cosmos-sdk/x/auth/client/cli" "github.com/cosmos/cosmos-sdk/x/auth/types" genutilcli "github.com/cosmos/cosmos-sdk/x/genutil/client/cli" serverconfig "github.com/cosmos/cosmos-sdk/server/config" "github.com/cosmos/cosmos-sdk/version" rosettaCmd "cosmossdk.io/tools/rosetta/cmd" wasmcli "github.com/CosmWasm/wasmd/x/wasm/client/cli" bostrom "github.com/cybercongress/go-cyber/v7/app" ) // NewRootCmd creates a new root command for simd. It is called once in the // main function. func NewRootCmd() (*cobra.Command, params.EncodingConfig) { encodingConfig := app.MakeEncodingConfig() app.SetConfig() initClientCtx := client.Context{}. WithCodec(encodingConfig.Codec). WithInterfaceRegistry(encodingConfig.InterfaceRegistry). WithTxConfig(encodingConfig.TxConfig). WithLegacyAmino(encodingConfig.Amino). WithInput(os.Stdin). WithAccountRetriever(types.AccountRetriever{}). WithBroadcastMode(flags.FlagBroadcastMode). WithHomeDir(app.DefaultNodeHome). WithViper("") rootCmd := &cobra.Command{ Use: version.AppName, Short: "Bostrom Bootloader Hub", PersistentPreRunE: func(cmd *cobra.Command, _ []string) error { cmd.SetOut(cmd.OutOrStdout()) cmd.SetErr(cmd.ErrOrStderr()) initClientCtx, err := client.ReadPersistentCommandFlags(initClientCtx, cmd.Flags()) if err != nil { return err } initClientCtx, err = config.ReadFromClientConfig(initClientCtx) if err != nil { return err } if err = client.SetCmdClientContextHandler(initClientCtx, cmd); err != nil { return err } customTemplate, customAppConfig := initAppConfig() customTMConfig := initTendermintConfig() return server.InterceptConfigsPreRunHandler(cmd, customTemplate, customAppConfig, customTMConfig) }, } initRootCmd(rootCmd, encodingConfig) return rootCmd, encodingConfig } // initTendermintConfig helps to override default Tendermint Config values. // return tmcfg.DefaultConfig if no custom configuration is required for the application. func initTendermintConfig() *tmcfg.Config { cfg := tmcfg.DefaultConfig() // these values put a higher strain on node memory // cfg.P2P.MaxNumInboundPeers = 100 // cfg.P2P.MaxNumOutboundPeers = 40 // 2 seconds + 1 second tendermint = 3 second blocks (v15 upgrade) // cfg.Consensus.TimeoutCommit = 2 * time.Second return cfg } // ProofExemptConfig holds config for gas-exempt PoW proof submissions. type ProofExemptConfig struct { // Contracts is a list of CosmWasm contract addresses whose // "submit_proof" messages are exempt from gas fees. Contracts []string `mapstructure:"contracts"` } const proofExemptConfigTemplate = ` ############################################################################### ### Proof-of-Work Gas Exemption ### ############################################################################### [proof-exempt] # List of CosmWasm contract addresses whose "submit_proof" execute messages # are exempt from gas fees. This allows miners to submit proofs without # holding any tokens for gas — the mining contract deducts gas cost from rewards. contracts = ["bostrom123wr6faa62xxrft6t5wmpqmh9g0chvu7ddedggx0lkecmgef7thsls9my2"] ` func initAppConfig() (string, interface{}) { type CustomAppConfig struct { serverconfig.Config Wasm wasmtypes.WasmConfig `mapstructure:"wasm"` ProofExempt ProofExemptConfig `mapstructure:"proof-exempt"` } // Allow overrides to the SDK default server config srvCfg := serverconfig.DefaultConfig() srvCfg.MinGasPrices = "0boot" customAppConfig := CustomAppConfig{ Config: *srvCfg, Wasm: wasmtypes.DefaultWasmConfig(), ProofExempt: ProofExemptConfig{Contracts: []string{"bostrom123wr6faa62xxrft6t5wmpqmh9g0chvu7ddedggx0lkecmgef7thsls9my2"}}, } customAppTemplate := serverconfig.DefaultConfigTemplate + wasmtypes.DefaultConfigTemplate() + proofExemptConfigTemplate return customAppTemplate, customAppConfig } func initRootCmd(rootCmd *cobra.Command, encodingConfig params.EncodingConfig) { ac := appCreator{ encCfg: encodingConfig, } rootCmd.AddCommand( genutilcli.InitCmd(app.ModuleBasics, app.DefaultNodeHome), tmcli.NewCompletionCmd(rootCmd, true), debug.Cmd(), config.Cmd(), pruning.PruningCmd(newApp), // analyzeExportCmd(), ) server.AddCommands(rootCmd, app.DefaultNodeHome, newApp, ac.appExport, addModuleInitFlags) server.AddTestnetCreatorCommand(rootCmd, app.DefaultNodeHome, newTestnetApp, addModuleInitFlags) wasmcli.ExtendUnsafeResetAllCmd(rootCmd) // add keybase, auxiliary RPC, query, and tx child commands rootCmd.AddCommand( rpc.StatusCommand(), genesisCommand(encodingConfig), queryCommand(), txCommand(), keys.Commands(app.DefaultNodeHome), ) // add rosetta rootCmd.AddCommand(rosettaCmd.RosettaCommand(encodingConfig.InterfaceRegistry, encodingConfig.Codec)) } func addModuleInitFlags(startCmd *cobra.Command) { crisis.AddModuleInitFlags(startCmd) rank.AddModuleInitFlags(startCmd) wasm.AddModuleInitFlags(startCmd) } // genesisCommand builds genesis-related `simd genesis` command. Users may provide application specific commands as a parameter func genesisCommand(encodingConfig params.EncodingConfig, cmds ...*cobra.Command) *cobra.Command { cmd := genutilcli.GenesisCoreCommand(encodingConfig.TxConfig, app.ModuleBasics, app.DefaultNodeHome) for _, subCmd := range cmds { cmd.AddCommand(subCmd) } return cmd } func queryCommand() *cobra.Command { cmd := &cobra.Command{ Use: "query", Aliases: []string{"q"}, Short: "Querying subcommands", DisableFlagParsing: true, SuggestionsMinimumDistance: 2, RunE: client.ValidateCmd, } cmd.AddCommand( authcmd.GetAccountCmd(), rpc.ValidatorCommand(), rpc.BlockCommand(), authcmd.QueryTxsByEventsCmd(), authcmd.QueryTxCmd(), ) app.ModuleBasics.AddQueryCommands(cmd) cmd.PersistentFlags().String(flags.FlagChainID, "", "The network chain ID") return cmd } func txCommand() *cobra.Command { cmd := &cobra.Command{ Use: "tx", Short: "Transactions subcommands", DisableFlagParsing: true, SuggestionsMinimumDistance: 2, RunE: client.ValidateCmd, } cmd.AddCommand( authcmd.GetSignCommand(), authcmd.GetSignBatchCommand(), authcmd.GetMultiSignCommand(), authcmd.GetMultiSignBatchCmd(), authcmd.GetValidateSignaturesCommand(), flags.LineBreak, authcmd.GetBroadcastCommand(), authcmd.GetEncodeCommand(), authcmd.GetDecodeCommand(), authcmd.GetAuxToFeeCommand(), ) app.ModuleBasics.AddTxCommands(cmd) cmd.PersistentFlags().String(flags.FlagChainID, "", "The network chain ID") return cmd } type appCreator struct { encCfg params.EncodingConfig } func newApp( logger log.Logger, db dbm.DB, traceStore io.Writer, appOpts servertypes.AppOptions, ) servertypes.Application { var cache storetypes.MultiStorePersistentCache if cast.ToBool(appOpts.Get(server.FlagInterBlockCache)) { cache = store.NewCommitKVStoreCacheManager() } skipUpgradeHeights := make(map[int64]bool) for _, h := range cast.ToIntSlice(appOpts.Get(server.FlagUnsafeSkipUpgrades)) { skipUpgradeHeights[int64(h)] = true } pruningOpts, err := server.GetPruningOptionsFromFlags(appOpts) if err != nil { panic(err) } snapshotDir := filepath.Join(cast.ToString(appOpts.Get(flags.FlagHome)), "data", "snapshots") snapshotDB, err := dbm.NewGoLevelDB("metadata", snapshotDir) if err != nil { panic(err) } snapshotStore, err := snapshots.NewStore(snapshotDB, snapshotDir) if err != nil { panic(err) } snapshotOptions := snapshottypes.NewSnapshotOptions( cast.ToUint64(appOpts.Get(server.FlagStateSyncSnapshotInterval)), cast.ToUint32(appOpts.Get(server.FlagStateSyncSnapshotKeepRecent)), ) homeDir := cast.ToString(appOpts.Get(flags.FlagHome)) chainID := cast.ToString(appOpts.Get(flags.FlagChainID)) if chainID == "" { // fallback to genesis chain-id _, genesisDoc, err := genutiltypes.GenesisStateFromGenFile(filepath.Join(homeDir, "config", "genesis.json")) if err != nil { panic(err) } chainID = genesisDoc.ChainID } var wasmOpts []wasmkeeper.Option if cast.ToBool(appOpts.Get("telemetry.enabled")) { wasmOpts = append(wasmOpts, wasmkeeper.WithVMCacheMetrics(prometheus.DefaultRegisterer)) } baseAppOptions := []func(*baseapp.BaseApp){ baseapp.SetPruning(pruningOpts), baseapp.SetMinGasPrices(cast.ToString(appOpts.Get(server.FlagMinGasPrices))), baseapp.SetMinRetainBlocks(cast.ToUint64(appOpts.Get(server.FlagMinRetainBlocks))), baseapp.SetHaltHeight(cast.ToUint64(appOpts.Get(server.FlagHaltHeight))), baseapp.SetHaltTime(cast.ToUint64(appOpts.Get(server.FlagHaltTime))), baseapp.SetMinRetainBlocks(cast.ToUint64(appOpts.Get(server.FlagMinRetainBlocks))), baseapp.SetInterBlockCache(cache), baseapp.SetTrace(cast.ToBool(appOpts.Get(server.FlagTrace))), baseapp.SetIndexEvents(cast.ToStringSlice(appOpts.Get(server.FlagIndexEvents))), baseapp.SetSnapshot(snapshotStore, snapshotOptions), baseapp.SetIAVLCacheSize(cast.ToInt(appOpts.Get(server.FlagIAVLCacheSize))), baseapp.SetIAVLDisableFastNode(cast.ToBool(appOpts.Get(server.FlagDisableIAVLFastNode))), baseapp.SetChainID(chainID), } // If this is an in place testnet, set any new stores that may exist if cast.ToBool(appOpts.Get(server.KeyIsTestnet)) { versionStore := store.NewCommitMultiStore(db).LatestVersion() + 1 baseAppOptions = append(baseAppOptions, baseapp.SetStoreLoader(upgradetypes.UpgradeStoreLoader(versionStore, &v6.Upgrade.StoreUpgrades))) } return app.NewBostromApp( logger, db, traceStore, true, appOpts, wasmOpts, baseAppOptions..., ) } func (ac appCreator) appExport( logger log.Logger, db dbm.DB, traceStore io.Writer, height int64, forZeroHeight bool, jailAllowedAddrs []string, appOpts servertypes.AppOptions, modulesToExport []string, ) (servertypes.ExportedApp, error) { var cyberApp *app.App homePath, ok := appOpts.Get(flags.FlagHome).(string) if !ok || homePath == "" { return servertypes.ExportedApp{}, errors.New("application home is not set") } loadLatest := height == -1 var emptyWasmOpts []wasm.Option cyberApp = app.NewBostromApp( logger, db, traceStore, loadLatest, appOpts, emptyWasmOpts, ) if height != -1 { if err := cyberApp.LoadHeight(height); err != nil { return servertypes.ExportedApp{}, err } } return cyberApp.ExportAppStateAndValidators(forZeroHeight, jailAllowedAddrs, modulesToExport) } // newTestnetApp starts by running the normal newApp method. From there, the app interface returned is modified in order // for a testnet to be created from the provided app. func newTestnetApp(logger log.Logger, db dbm.DB, traceStore io.Writer, appOpts servertypes.AppOptions) servertypes.Application { app := newApp(logger, db, traceStore, appOpts) bostromApp, ok := app.(*bostrom.App) if !ok { panic("app created from newApp is not of type osmosisApp") } newValAddr, ok := appOpts.Get(server.KeyNewValAddr).(bytes.HexBytes) if !ok { panic("newValAddr is not of type bytes.HexBytes") } newValPubKey, ok := appOpts.Get(server.KeyUserPubKey).(crypto.PubKey) if !ok { panic("newValPubKey is not of type crypto.PubKey") } newOperatorAddress, ok := appOpts.Get(server.KeyNewOpAddr).(string) if !ok { panic("newOperatorAddress is not of type string") } upgradeToTrigger, ok := appOpts.Get(server.KeyTriggerTestnetUpgrade).(string) if !ok { panic("upgradeToTrigger is not of type string") } // Make modifications to the normal App required to run the network locally return bostrom.InitAppForTestnet(bostromApp, newValAddr, newValPubKey, newOperatorAddress, upgradeToTrigger) } ================================================ FILE: cmd/cyber/main.go ================================================ package main import ( "os" "github.com/cosmos/cosmos-sdk/server" svrcmd "github.com/cosmos/cosmos-sdk/server/cmd" "github.com/cybercongress/go-cyber/v7/app" "github.com/cybercongress/go-cyber/v7/cmd/cyber/cmd" ) func main() { rootCmd, _ := cmd.NewRootCmd() if err := svrcmd.Execute(rootCmd, "", app.DefaultNodeHome); err != nil { switch e := err.(type) { case server.ErrorCode: os.Exit(e.Code) default: os.Exit(1) } } } ================================================ FILE: cmd/iavltool/README.md ================================================ ## IAVL TOOL ``` go run main.go data ~/.cyber/data ``` ================================================ FILE: cmd/iavltool/cmd/root.go ================================================ package cmd import ( "bytes" "crypto/sha256" "encoding/hex" "fmt" "os" "strconv" "strings" dbm "github.com/cometbft/cometbft-db" "github.com/cosmos/iavl" "github.com/spf13/cobra" goleveldb "github.com/syndtr/goleveldb/leveldb" "github.com/syndtr/goleveldb/leveldb/util" ) const ( DefaultCacheSize int = 16000 ) var ( DefaultHome = os.ExpandEnv("$HOME/") + ".cyber/data" rootCmd = &cobra.Command{Use: "iavltool"} home string ) // TODO autoconf stores var appStores = []string{ "acc", "bank", "staking", "mint", "distribution", "slashing", "gov", "params", "ibc", "upgrade", "evidence", "transfer", "capability", "wasm", "graph", "bandwidth", "grid", "rank", "dmn", "resources", "liquidity", } func Execute() error { return rootCmd.Execute() } func init() { rootCmd.PersistentFlags().StringVar(&home, "home", DefaultHome, "path to cyber data") rootCmd.AddCommand(dataCmd) rootCmd.AddCommand(shapeCmd) rootCmd.AddCommand(versionsCmd) rootCmd.AddCommand(deleteCmd) rootCmd.AddCommand(statsCmd) rootCmd.AddCommand(pruneCmd) } var dataCmd = &cobra.Command{ Use: "data [store] [version] [kv] [hash]", Short: "Print data of given stores at given block", Args: cobra.MinimumNArgs(0), Run: func(cmd *cobra.Command, args []string) { db, err := OpenDB(home) if err != nil { fmt.Println("ERROR DB OPEN:", err) } stores := appStores version := int64(0) keysOpt, hashingOpt := false, false switch len(args) { case 4: hashingOpt, _ = strconv.ParseBool(args[3]) fallthrough case 3: keysOpt, _ = strconv.ParseBool(args[2]) fallthrough case 2: version, _ = strconv.ParseInt(args[1], 10, 64) fallthrough case 1: var a []string if args[0] != "all" { stores = append(a, args[0]) } } for _, name := range stores { tree, err := ReadTree(db, version, name) if err != nil { _, _ = fmt.Fprintf(os.Stderr, "Error reading data: %s\n", err) os.Exit(1) } if keysOpt { PrintKeys(tree, hashingOpt) } hash, err := tree.Hash() if err != nil { _, _ = fmt.Fprintf(os.Stderr, "Error reading data: %s\n", err) os.Exit(1) } fmt.Printf("Hash: %X\n", hash) fmt.Printf("Size: %X\n", tree.Size()) } }, } var shapeCmd = &cobra.Command{ Use: "shape [store] [version]", Short: "Print shape of given stores at given block", Args: cobra.MinimumNArgs(0), Run: func(cmd *cobra.Command, args []string) { db, err := OpenDB(home) if err != nil { fmt.Println("ERROR DB OPEN:", err) } store := "all" version := int64(0) switch len(args) { case 2: version, _ = strconv.ParseInt(args[1], 10, 64) fallthrough case 1: store = args[0] } if store == "all" { for _, name := range appStores { tree, err := ReadTree(db, version, name) if err != nil { _, _ = fmt.Fprintf(os.Stderr, "Error reading data: %s\n", err) os.Exit(1) } PrintShape(tree) } } else { tree, err := ReadTree(db, version, store) if err != nil { fmt.Fprintf(os.Stderr, "Error reading data: %s\n", err) os.Exit(1) } PrintShape(tree) } }, } var versionsCmd = &cobra.Command{ Use: "versions [store]", Short: "Print shape of given stores at given block", Args: cobra.MinimumNArgs(1), Run: func(cmd *cobra.Command, args []string) { db, err := OpenDB(home) if err != nil { fmt.Println("ERROR DB OPEN:", err) } tree, err := ReadTree(db, 0, args[0]) if err != nil { fmt.Fprintf(os.Stderr, "Error reading data: %s\n", err) os.Exit(1) } PrintVersions(tree) }, } var deleteCmd = &cobra.Command{ Use: "delete [store] [from] [to]", Short: "Delete versions range for given stores", Args: cobra.MinimumNArgs(0), Run: func(cmd *cobra.Command, args []string) { db, err := OpenDB(home) if err != nil { fmt.Println("ERROR DB OPEN:", err) } stores := appStores from, to := int64(0), int64(0) switch len(args) { case 3: to, _ = strconv.ParseInt(args[2], 10, 64) fallthrough case 2: from, _ = strconv.ParseInt(args[1], 10, 64) fallthrough case 1: var a []string if args[0] != "all" { stores = append(a, args[0]) } } for _, name := range stores { tree, err := GetTree(db, name) fmt.Println("processing", name) if err != nil { _, _ = fmt.Fprintf(os.Stderr, "Error reading data: %s\n", err) continue } err = tree.DeleteVersionsRange(from, to) if err != nil { _, _ = fmt.Fprintf(os.Stderr, "Error deleting data: %s\n", err) continue } } }, } var statsCmd = &cobra.Command{ Use: "stats [store] [version]", Short: "Print shape of given stores at given block", Args: cobra.MinimumNArgs(0), Run: func(cmd *cobra.Command, args []string) { db, err := OpenDB(home) if err != nil { fmt.Println("ERROR DB OPEN:", err) } PrintDBStats(db) }, } var pruneCmd = &cobra.Command{ Use: "prune", Short: "Prune leveldb", Args: cobra.NoArgs, Run: func(cmd *cobra.Command, args []string) { db, _ := goleveldb.OpenFile(home+"/application.db", nil) defer db.Close() _ = db.CompactRange(util.Range{Start: nil, Limit: nil}) }, } func OpenDB(dir string) (dbm.DB, error) { db, err := dbm.NewDB("application", dbm.GoLevelDBBackend, dir) return db, err } func PrintDBStats(db dbm.DB) { count := 0 prefix := map[string]int{} iter, err := db.Iterator(nil, nil) if err != nil { panic(err) } for ; iter.Valid(); iter.Next() { key := string(iter.Key()[:1]) prefix[key]++ count++ } iter.Close() fmt.Printf("DB contains %d entries\n", count) for k, v := range prefix { fmt.Printf(" %s: %d\n", k, v) } } // ReadTree loads an iavl tree from the directory // If version is 0, load latest, otherwise, load named version func ReadTree(db dbm.DB, version int64, name string) (*iavl.MutableTree, error) { fmt.Println("--------------[", name, "]--------------") tree, err := iavl.NewMutableTree(dbm.NewPrefixDB(db, []byte("s/k:"+name+"/")), DefaultCacheSize, false) if err != nil { return nil, err } ver, err := tree.LoadVersion(version) fmt.Printf("Got version: %d\n", ver) return tree, err } func GetTree(db dbm.DB, name string) (*iavl.MutableTree, error) { tree, err := iavl.NewMutableTree(dbm.NewPrefixDB(db, []byte("s/k:"+name+"/")), DefaultCacheSize, false) if err != nil { return nil, err } _, err = tree.LoadVersion(int64(0)) if err != nil { return nil, err } return tree, err } func PrintKeys(tree *iavl.MutableTree, hashing bool) { fmt.Println("Printing all keys with hashed values (to detect diff)") _, err := tree.Iterate(func(key, value []byte) bool { if hashing { printKey := parseWeaveKey(key) digest := sha256.Sum256(value) fmt.Printf(" %s\n %X\n", printKey, digest) } else { fmt.Printf(" %s\n %X\n", key, value) } return false }) if err != nil { panic(err) } } // parseWeaveKey assumes a separating : where all in front should be ascii, // and all afterwards may be ascii or binary func parseWeaveKey(key []byte) string { cut := bytes.IndexRune(key, ':') if cut == -1 { return encodeID(key) } prefix := key[:cut] id := key[cut+1:] return fmt.Sprintf("%s:%s", encodeID(prefix), encodeID(id)) } // casts to a string if it is printable ascii, hex-encodes otherwise func encodeID(id []byte) string { for _, b := range id { if b < 0x20 || b >= 0x80 { return strings.ToUpper(hex.EncodeToString(id)) } } return string(id) } func PrintShape(tree *iavl.MutableTree) { // shape := tree.RenderShape(" ", nil) shape, _ := tree.RenderShape(" ", nodeEncoder) fmt.Println(strings.Join(shape, "\n")) } func nodeEncoder(id []byte, depth int, isLeaf bool) string { prefix := fmt.Sprintf("-%d ", depth) if isLeaf { prefix = fmt.Sprintf("*%d ", depth) } if len(id) == 0 { return fmt.Sprintf("%s", prefix) } return fmt.Sprintf("%s%s", prefix, parseWeaveKey(id)) } func PrintVersions(tree *iavl.MutableTree) { versions := tree.AvailableVersions() fmt.Println("Available versions:") for _, v := range versions { fmt.Printf(" %d\n", v) } } ================================================ FILE: cmd/iavltool/main.go ================================================ package main import ( "github.com/cybercongress/go-cyber/v7/cmd/iavltool/cmd" ) func main() { err := cmd.Execute() if err != nil { return } } ================================================ FILE: contrib/Dockerfile ================================================ # Simple usage with a mounted data directory: # > docker build -t cyber . # > docker run -it -p 46657:46657 -p 46656:46656 -v ~/.cyber:/root/.cyber -v ~/.cybercli:/root/.cybercli cyber cyber init # > docker run -it -p 46657:46657 -p 46656:46656 -v ~/.cyber:/root/.cyber -v ~/.cybercli:/root/.cybercli cyber cyber start FROM golang:1.16-alpine3.13 AS build-env # Set up dependencies ENV PACKAGES curl make git libc-dev bash gcc linux-headers eudev-dev python3 # Set working directory for the build WORKDIR /go/src/github.com/cybercongress/cyber # Add source files COPY . . # Install minimum necessary dependencies, build Cosmos SDK, remove packages RUN apk add $PACKAGES && \ make install # Final image FROM alpine:edge # Install ca-certificates RUN apk add --update ca-certificates WORKDIR /root # Copy over binaries from the build-env COPY --from=build-env /go/bin/cyber /usr/bin/cyber COPY ./contrib/single-node.sh . EXPOSE 26657 ENTRYPOINT [ "./single-node.sh" ] # NOTE: to run this image, docker run -d -p 26657:26657 ./single-node.sh {{chain_id}} {{genesis_account}} ================================================ FILE: contrib/devtools/Makefile ================================================ ### # Find OS and Go environment # GO contains the Go binary # FS contains the OS file separator ### ifeq ($(OS),Windows_NT) GO := $(shell where go.exe 2> NUL) FS := "\\" else GO := $(shell command -v go 2> /dev/null) FS := "/" endif ifeq ($(GO),) $(error could not find go. Is it in PATH? $(GO)) endif ############################################################################### ### Functions ### ############################################################################### go_get = $(if $(findstring Windows_NT,$(OS)),\ IF NOT EXIST $(GITHUBDIR)$(FS)$(1)$(FS) ( mkdir $(GITHUBDIR)$(FS)$(1) ) else (cd .) &\ IF NOT EXIST $(GITHUBDIR)$(FS)$(1)$(FS)$(2)$(FS) ( cd $(GITHUBDIR)$(FS)$(1) && git clone https://github.com/$(1)/$(2) ) else (cd .) &\ ,\ mkdir -p $(GITHUBDIR)$(FS)$(1) &&\ (test ! -d $(GITHUBDIR)$(FS)$(1)$(FS)$(2) && cd $(GITHUBDIR)$(FS)$(1) && git clone https://github.com/$(1)/$(2)) || true &&\ )\ cd $(GITHUBDIR)$(FS)$(1)$(FS)$(2) && git fetch origin && git checkout -q $(3) mkfile_path := $(abspath $(lastword $(MAKEFILE_LIST))) mkfile_dir := $(shell cd $(shell dirname $(mkfile_path)); pwd) ############################################################################### ### Tools ### ############################################################################### PREFIX ?= /usr/local BIN ?= $(PREFIX)/bin UNAME_S ?= $(shell uname -s) UNAME_M ?= $(shell uname -m) GOPATH ?= $(shell $(GO) env GOPATH) GITHUBDIR := $(GOPATH)$(FS)src$(FS)github.com BUF_VERSION ?= 0.11.0 TOOLS_DESTDIR ?= $(GOPATH)/bin STATIK = $(TOOLS_DESTDIR)/statik RUNSIM = $(TOOLS_DESTDIR)/runsim tools: tools-stamp tools-stamp: statik runsim # Create dummy file to satisfy dependency and avoid # rebuilding when this Makefile target is hit twice # in a row. touch $@ proto-tools: proto-tools-stamp proto-tools-stamp: bash contrib/devtools/proto-tools-installer.sh # Create dummy file to satisfy dependency and avoid # rebuilding when this Makefile target is hit twice # in a row. touch $@ # Install the runsim binary with a temporary workaround of entering an outside # directory as the "go get" command ignores the -mod option and will polute the # go.{mod, sum} files. # # ref: https://github.com/golang/go/issues/30515 statik: $(STATIK) $(STATIK): @echo "Installing statik..." @(cd /tmp && go get github.com/rakyll/statik@v0.1.6) # Install the runsim binary with a temporary workaround of entering an outside # directory as the "go get" command ignores the -mod option and will polute the # go.{mod, sum} files. # # ref: https://github.com/golang/go/issues/30515 runsim: $(RUNSIM) $(RUNSIM): @echo "Installing runsim..." @(cd /tmp && go get github.com/cosmos/tools/cmd/runsim@v1.0.0) tools-clean: rm -f $(STATIK) $(GOLANGCI_LINT) $(RUNSIM) rm -f proto-tools-stamp tools-stamp .PHONY: tools-clean statik runsim ================================================ FILE: contrib/devtools/dockerfile ================================================ ================================================ FILE: contrib/devtools/proto-tools-installer.sh ================================================ #!/bin/bash set -ue DESTDIR=${DESTDIR:-} PREFIX=${PREFIX:-/usr/local} UNAME_S="$(uname -s 2>/dev/null)" UNAME_M="$(uname -m 2>/dev/null)" BUF_VERSION=0.11.0 PROTOC_VERSION=3.13.0 PROTOC_GRPC_GATEWAY_VERSION=1.15.2 f_abort() { local l_rc=$1 shift echo $@ >&2 exit ${l_rc} } case "${UNAME_S}" in Linux) PROTOC_ZIP="protoc-${PROTOC_VERSION}-linux-x86_64.zip" PROTOC_GRPC_GATEWAY_BIN="protoc-gen-grpc-gateway-v${PROTOC_GRPC_GATEWAY_VERSION}-linux-x86_64" ;; Darwin) PROTOC_ZIP="protoc-${PROTOC_VERSION}-osx-x86_64.zip" PROTOC_GRPC_GATEWAY_BIN="protoc-gen-grpc-gateway-v${PROTOC_GRPC_GATEWAY_VERSION}-darwin-x86_64" ;; *) f_abort 1 "Unknown kernel name. Exiting." esac TEMPDIR="$(mktemp -d)" trap "rm -rvf ${TEMPDIR}" EXIT f_print_installing_with_padding() { printf "Installing %30s ..." "$1" >&2 } f_print_done() { echo -e "\tDONE" >&2 } f_ensure_tools() { ! which curl &>/dev/null && f_abort 2 "couldn't find curl, aborting" || true } f_ensure_dirs() { mkdir -p "${DESTDIR}/${PREFIX}/bin" mkdir -p "${DESTDIR}/${PREFIX}/include" } f_needs_install() { if [ -x $1 ]; then echo -e "\talready installed. Skipping." >&2 return 1 fi return 0 } f_install_protoc() { f_print_installing_with_padding proto_c f_needs_install "${DESTDIR}/${PREFIX}/bin/protoc" || return 0 pushd "${TEMPDIR}" >/dev/null curl -o "${PROTOC_ZIP}" -sSL "https://github.com/protocolbuffers/protobuf/releases/download/v${PROTOC_VERSION}/${PROTOC_ZIP}" unzip -q -o ${PROTOC_ZIP} -d ${DESTDIR}/${PREFIX} bin/protoc; \ unzip -q -o ${PROTOC_ZIP} -d ${DESTDIR}/${PREFIX} 'include/*'; \ rm -f ${PROTOC_ZIP} popd >/dev/null f_print_done } f_install_buf() { f_print_installing_with_padding buf f_needs_install "${DESTDIR}/${PREFIX}/bin/buf" || return 0 curl -sSL "https://github.com/bufbuild/buf/releases/download/v${BUF_VERSION}/buf-${UNAME_S}-${UNAME_M}" -o "${DESTDIR}/${PREFIX}/bin/buf" chmod +x "${DESTDIR}/${PREFIX}/bin/buf" f_print_done } f_install_protoc_gen_gocosmos() { f_print_installing_with_padding protoc-gen-gocosmos go get github.com/regen-network/cosmos-proto/protoc-gen-gocosmos 2>/dev/null f_print_done } f_install_protoc_gen_grpc_gateway() { f_print_installing_with_padding protoc-gen-grpc-gateway f_needs_install "${DESTDIR}/${PREFIX}/bin/protoc-gen-grpc-gateway" || return 0 curl -o "${DESTDIR}/${PREFIX}/bin/protoc-gen-grpc-gateway" -sSL "https://github.com/grpc-ecosystem/grpc-gateway/releases/download/v${PROTOC_GRPC_GATEWAY_VERSION}/${PROTOC_GRPC_GATEWAY_BIN}" f_print_done } f_install_protoc_gen_swagger() { f_print_installing_with_padding protoc-gen-swagger f_needs_install "${DESTDIR}/${PREFIX}/bin/protoc-gen-swagger" || return 0 if ! which npm &>/dev/null ; then echo -e "\tNPM is not installed. Skipping." return 0 fi pushd "${TEMPDIR}" >/dev/null go get github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger npm install -g swagger-combine popd >/dev/null f_print_done } f_ensure_tools f_ensure_dirs f_install_protoc f_install_buf f_install_protoc_gen_gocosmos f_install_protoc_gen_grpc_gateway f_install_protoc_gen_swagger ================================================ FILE: contrib/links-load.sh ================================================ #!/bin/sh CNT=0 ITER=$1 SLEEP=$2 NUMBLOCKS=$3 NODEADDR=$4 CHAINID=$5 if [ -z "$1" ]; then echo "Need to input number of iterations to run..." exit 1 fi if [ -z "$2" ]; then echo "Need to input number of seconds to sleep between iterations" exit 1 fi if [ -z "$3" ]; then echo "Need to input block height to declare completion..." exit 1 fi if [ -z "$4" ]; then echo "Need to input node address to poll..." exit 1 fi if [ -z "$5" ]; then echo "Need to input chain-id..." exit 1 fi #MNEMONIC="" #echo $MNEMONIC | cyber keys add $ADDR --recover --keyring-backend test while [ ${CNT} -lt $ITER ]; do curr_block=$(curl -s $NODEADDR:26657/status | jq -r '.result.sync_info.latest_block_height') if [ ! -z ${curr_block} ] ; then echo "Number of Blocks: ${curr_block}" fi if [ ! -z ${curr_block} ] && [ ${curr_block} -gt ${NUMBLOCKS} ]; then echo "Number of blocks reached. Success!" exit 0 fi # if ! ((${CNT} % 5)); then R1=$RANDOM R2=$RANDOM FROM=$(echo $R1 | ipfs add -Q) TO=$(echo $R2 | ipfs add -Q) ADDR=$(cyber keys show tester3 -a --keyring-backend="test") cyber tx graph cyberlink $FROM $TO --from $ADDR --chain-id $CHAINID --keyring-backend="test" --node "tcp://$NODEADDR:26657" -b block -y # fi let CNT=CNT+1 sleep $SLEEP done echo "Timeout reached. Failure!" exit 1 ================================================ FILE: contrib/localnet-blocks-test.sh ================================================ #!/bin/bash CNT=0 ITER=$1 SLEEP=$2 NUMBLOCKS=$3 NODEADDR=$4 if [ -z "$1" ]; then echo "Need to input number of iterations to run..." exit 1 fi if [ -z "$2" ]; then echo "Need to input number of seconds to sleep between iterations" exit 1 fi if [ -z "$3" ]; then echo "Need to input block height to declare completion..." exit 1 fi if [ -z "$4" ]; then echo "Need to input node address to poll..." exit 1 fi docker_containers=( $(docker ps -q -f name=cyber --format='{{.Names}}') ) while [ ${CNT} -lt $ITER ]; do curr_block=$(curl -s $NODEADDR:26657/status | jq -r '.result.sync_info.latest_block_height') if [ ! -z ${curr_block} ] ; then echo "Number of Blocks: ${curr_block}" fi if [ ! -z ${curr_block} ] && [ ${curr_block} -gt ${NUMBLOCKS} ]; then echo "Number of blocks reached. Success!" exit 0 fi # Emulate network chaos: # # Every 10 blocks, pick a random container and restart it. if ! ((${CNT} % 10)); then rand_container=${docker_containers["$[RANDOM % ${#docker_containers[@]}]"]}; echo "Restarting random docker container ${rand_container}" docker restart ${rand_container} &>/dev/null & fi let CNT=CNT+1 sleep $SLEEP done echo "Timeout reached. Failure!" exit 1 ================================================ FILE: contrib/reset-chain.sh ================================================ #!/bin/sh for OUTPUT in ../build/node* do cyber unsafe-reset-all --home $OUTPUT/cyber done ================================================ FILE: contrib/single-node.sh ================================================ #!/bin/sh set -o errexit -o nounset CHAINID=$1 HMDIR=$2 if [ -z "$1" ]; then echo "Need to input chain id" exit 1 fi if [ -z "$2" ]; then echo "Need to input home directory" exit 1 fi # validator and dev accounts should be added to .cyber dir in user's root with keyring-backend test coins="1000000000000boot" cyber init --chain-id "$CHAINID" "$CHAINID" --home "$HMDIR" sed -i '' 's#"stake"#"boot"#g' "$HMDIR"/config/genesis.json cp -R ~/.cyber/keyring-test $HMDIR cyber genesis add-genesis-account "$(cyber keys show validator -a --keyring-backend="test")" $coins --home "$HMDIR" cyber genesis add-genesis-account "$(cyber keys show dev -a --keyring-backend="test")" $coins --home "$HMDIR" cyber genesis gentx validator 5000000000boot --keyring-backend="test" --chain-id $CHAINID --home "$HMDIR" cyber genesis collect-gentxs --home "$HMDIR" ================================================ FILE: docker-compose.yml ================================================ version: '3' services: cybernode0: container_name: cybernode0 image: "cybercongress/cyber" ports: - "26656-26657:26656-26657" - "1317:1317" environment: - ID=0 - LOG=${LOG:-cyber.log} volumes: - ./build:/cyber:Z networks: localnet: ipv4_address: 192.168.10.2 cybernode1: container_name: cybernode1 image: "cybercongress/cyber" ports: - "26659-26660:26656-26657" environment: - ID=1 - LOG=${LOG:-cyber.log} volumes: - ./build:/cyber:Z networks: localnet: ipv4_address: 192.168.10.3 cybernode2: container_name: cybernode2 image: "cybercongress/cyber" environment: - ID=2 - LOG=${LOG:-cyber.log} ports: - "26661-26662:26656-26657" volumes: - ./build:/cyber:Z networks: localnet: ipv4_address: 192.168.10.4 cybernode3: container_name: cybernode3 image: "cybercongress/cyber" environment: - ID=3 - LOG=${LOG:-cyber.log} ports: - "26663-26664:26656-26657" volumes: - ./build:/cyber:Z networks: localnet: ipv4_address: 192.168.10.5 networks: localnet: driver: bridge ipam: driver: default config: - subnet: 192.168.10.0/16 ================================================ FILE: docs/README.md ================================================ # Concepts (WIP) ## soft2 and soft3 - [soft2 and soft3](soft2-soft3-concepts.md) - content from presentation - knowledge graph - content oracle - particle - cyberlink - neuron ## consensus computer - [cyber-sdk](#cyber-sdk-modules-documentation) - resources - tendermint - abci - ibc - ikp ## sequential computation - cosmwasm - dmn - bindings - cw-cyber ## parallel computation - relevance machine - semcon - linkchain - motif - blas - cyb and sparks - superintelligence # Tutorials (WIP) - install cyber cli - run node - [send transactions](send_txs.md) in your dapp - [cyberlink content](cyberlink_content.md) in dapp - [deploy contract](deploy_contract.md) - [run local network](../networks/local/README.md) for development # How-To (WIP) - [run validator](run_validator.md) guide - [network upgrade](upgra) guide - setup local environment - [daemon configuration](setup_cyber_configuration.md) guide - [ultimate cli](ultimate_commands_guide.md) guide - [managing multisig](multisig_guide.md) guide - [ledger](cyber_ledger_guide) guide # Reference - [swagger](https://lcd.bostrom.cybernode.ai/) --- ### Extras - [supported GPUs](supported_gpu_list.md) list - [Tendermint KMS](validator_launch_with_tendermintKMS_and_ledger.md) guide - [keystore](keystore.md) guide ### cyber-sdk modules documentation - **[graph](../x/graph/spec/README.md)** - **[rank](../x/rank/spec/README.md)** - **[bandwidth](../x/bandwidth/spec/README.md)** - **[cyberbank](../x/cyberbank/spec/README.md)** - **[energy](../x/energy/spec/README.md)** - **[resources](../x/resources/spec/README.md)** - **[dmn](../x/dmn/spec/README.md)** - **[staking](../x/staking/spec/README.md)** ================================================ FILE: docs/cyber_ledger_guide.md ================================================ # Ledger Support It is possible to use your Ledger device with cyber to store keys and sign transactions. ## Cyberd CLI & Ledger Nano How to get started. First of all, you'll need a couple of things to be done: + A running and synced cyber node (how to: [here](https://github.com/cybercongress/go-cyber/blob/bostrom-dev/docs/run_validator.md) and [here](https://github.com/cybercongress/go-cyber/blob/main/docs/ultimate_commands_guide.md)) + [Setup](https://support.ledger.com/hc/en-us/articles/360000613793-Set-up-as-new-device) your Ledger device and [install Cosmos app on it](https://github.com/cosmos/ledger-cosmos/blob/master/README.md#installing) (the latest firmware for Ledger and Cosmos app required) It is necessary to verify that cyber is built with netgo and Ledger tags. To check that, we can run: `cyber version --long`. ## Add your Ledger key If you have set up your Ledger device on a different machine than the one running cyber, it is necessary to make sure that the Ledger device is generally working on this machine. A great way to do so is installing [Ledger Live](https://shop.ledger.com/pages/ledger-live) on the machine and trying to connect your Ledger device to it. This will show possible issues and error codes to work with ([Fix connection issues](https://support.ledger.com/hc/en-us/articles/115005165269-Fix-connection-issues) guide from Ledger). When you made sure that your Ledger device is successfully interacting with your machine do the following: + Connect and unlock your Ledger device + Open the Cosmos app on your Ledger + Create an account in cyber from your Ledger key For account creation run: ``` js cyber keys add --ledger ``` After submitting this command your Ledger device should show a generated address and will wait for confirmation. Hit confirm the button and in the console, you'll see the following output: ``` js - name: type: ledger address: cyber1gw5kdey7fs9wvh05w66s034s24tjdvxcp5fhkz pubkey: cyberpub1addwnpepq0lfpdumac47nyel06u95czd4026ahzmjr8stsx4h65kw3dhh60py0m7k6r mnemonic: "" threshold: 0 pubkeys: [] ``` By default, the `...keys add` command with account and index set to 0 of [bip44](https://github.com/bitcoin/bips/blob/master/bip-0044.mediawiki) derivation path is used. To add more than one key account and/or index it must be specified separately in the following way: ``` js cyber keys add --ledger --account 1 --index 1 ``` You don't need to remember which numbers for account and index you've used, it will be matched to automatically. ## Confirm your address To make sure you have added everything correctly just run: ``` js cyber keys show -d ``` It's necessary to confirm that the key on your Ledger matches the one shown in the console. ## Signing transactions You are now ready to sign and send transactions. This could be done by using the `tx bank send` command. Your Ledger device should be connected and unlocked at this step. Run the following to send some CYB tokens: ``` js cyber tx bank send cyb --chain-id ``` `` is your ledger key name, `` is the address of the recipient in the following format: `cyber1wq7p5qfygxr37vqqufhj5fzwlg55zmm4w0p8sw`. When prompted with `confirm transaction before signing`, answer Y. Your Ledger will ask to approve the transaction. Make sure you'll inspect the transaction JSON before signing it. When the transaction is signed on the Ledger, usually, the output will show up in the console. ================================================ FILE: docs/cyberlink_content.md ================================================ # Cyberlink content with Cyber-js ## Script preparation A small, ready-made repository exists so you can experiment with Cyber-js. Clone it from here. You need [NodeJs](https://nodejs.org/en/download/). If you open the folder in [Visual Studio Code](https://code.visualstudio.com/Download), the IDE should give you all the coding help you require. In the cloned folder you need to install the required modules: ```sh $ npm install ``` Create a new file named `experiment.ts`. In it, put these lines to confirm it works: ```typescript const runAll = async(): Promise => { console.log("TODO") } runAll() ``` To execute, this TypeScript file needs to be compiled into JavaScript before being interpreted by NodeJs. Add this as a run target in `package.json`: ```json ... "scripts": { ... "experiment": "ts-node experiment.ts" } ... ``` Confirm that it does what you want: ```sh $ npm run experiment ``` This returns: ``` > ts-node experiment.ts TODO ``` You will soon make this script more meaningful. With the basic script ready, you need to prepare some elements. ## Testnet preparation The Bostrom has a number of testnets running. The Bostrom is currently running a [public testnet](https://github.com/cybercongress/cybernode) for the Space-pussy-1 upgrade that you are connecting to and running your script on. You need to connect to a public node so that you can query information and broadcast transactions. One of the available nodes is: ``` RPC: https://rpc.space-pussy-1.cybernode.ai ``` You need a wallet address on the testnet and you must create a 24-word mnemonic in order to do so. CosmJS can generate one for you. Create a new file `generate_mnemonic.ts` with the following script: ```typescript import { DirectSecp256k1HdWallet } from "@cosmjs/proto-signing" const generateKey = async (): Promise => { const wallet: DirectSecp256k1HdWallet = await DirectSecp256k1HdWallet.generate(24) process.stdout.write(wallet.mnemonic) const accounts = await wallet.getAccounts() console.error("Mnemonic with 1st account:", accounts[0].address) } generateKey() ``` Now create a **key** for our imaginary user **Alice**: *Note: You likely need to update Node.js to a later version if this fails. Find a guide [here](https://phoenixnap.com/kb/update-node-js-version). ```sh $ npx ts-node generate_mnemonic.ts > testnet.alice.mnemonic.key ``` When done, it should also tell you the address of the first account: ``` Mnemonic with 1st account: bostrom1sw8xv3mv2n4xfv6rlpzsevusyzzg78r3e78xnp ``` Temporarily keep this address for convenience, although CosmJS can always recalculate it from the mnemonic. Privately examine the file to confirm it contains your 24 words. Important considerations: 1. `process.stdout.write` was used to avoid any line return. Be careful not to add any empty lines or any other character in your `.key` file (this occurs with VSCode under certain conditions). If you add any characters, ComsJs may not be able to parse it. 2. Adjust the `.gitignore` file to not commit your `.key` file by mistake: ``` node_modules *.key ``` ## Add your imports You need a small, simple interface to a blockchain, one which could eventually have users. Good practice is to refrain from requesting a user address until necessary (e.g. when a user clicks a relevant button). Therefore, in `experiment.ts` you first use the read-only client. Import it at the top of the file: ```typescript import { CyberClient } from "@cybercongress/cyber-js" ``` Note that VSCode assists you to auto-complete [`CyberClient`](https://github.com/cybercongress/soft3.js/blob/main/src/cyberclient.ts#L144) if you type CTRL-Space inside the `{}` of the `import` line. ## Define your connection Next, you need to tell the client how to connect to the RPC port of your blockchain: ```typescript const rpc = "https://rpc.space-pussy-1.cybernode.ai" ``` Inside the `runAll` function you [initialize the connection](https://github.com/cybercongress/soft3.js/blob/main/src/cyberclient.ts#L165) and immediately [check](https://github.com/cybercongress/soft3.js/blob/main/src/cyberclient.ts#L244) you connected to the right place: ```typescript const runAll = async(): Promise => { const client = await CyberClient.connect(rpc) console.log("With client, chain id:", await client.getChainId(), ", height:", await client.getHeight()) } ``` Run again to check with `npm run experiment`, and you get: ``` With client, chain id: space-pussy-1 , height: 9507032 ``` ## Prepare a signing client If you go through the methods inside [`CyberClient`](https://github.com/cybercongress/soft3.js/blob/main/src/cyberclient.ts#L144), you see that it only contains query-type methods and none for sending transactions. Now, for Alice to send transactions, she needs to be able to sign them. And to be able to sign transactions, she needs access to her _private keys_ or _mnemonics_. Or rather she needs a client that has access to those. That is where [`SigningCyberClient`](https://github.com/cybercongress/soft3.js/blob/main/src/signingcyberclient.ts#L239) comes in. Conveniently, `SigningCyberClient` inherits from `CyberClient`. Update your import line: ```typescript import { SigningCyberClient, CyberClient } from "@cybercongress/cyber-js" ``` Look at its declaration by right-clicking on the `SigningCyberClient` in your imports and choosing Go to Definition. When you instantiate `SigningCyberClient` by using the [`connectWithSigner`](https://github.com/cybercongress/soft3.js/blob/main/src/signingcyberclient.ts#L247) method, you need to pass it a [**signer**](https://github.com/cybercongress/soft3.js/blob/main/src/signingcyberclient.ts#L249). In this case, use the [`OfflineDirectSigner`](https://github.com/cybercongress/soft3.js/blob/main/src/signingcyberclient.ts#L29) interface. The recommended way to encode messages is by using `OfflineDirectSigner`, which uses Protobuf. However, hardware wallets such as Ledger do not support this and still require the legacy Amino encoder. If your app requires Amino support, you have to use the `OfflineAminoSigner`.

Read more about encoding [here](https://docs.cosmos.network/master/core/encoding.html).
The signer needs access to Alice's **private key**, and there are several ways to accomplish this. In this example, use Alice's saved **mnemonic**. To load the mnemonic as text in your code you need this import: ```typescript import { readFile } from "fs/promises" ``` There are several implementations of `OfflineDirectSigner` available. The [`DirectSecp256k1HdWallet`](https://github.com/cosmos/cosmjs/blob/0f0c9d8/packages/proto-signing/src/directsecp256k1hdwallet.ts#L133) implementation is most relevant to us due to its [`fromMnemonic`](https://github.com/cosmos/cosmjs/blob/0f0c9d8/packages/proto-signing/src/directsecp256k1hdwallet.ts#L140-L141) method. Add the import: ```typescript import { DirectSecp256k1HdWallet, OfflineDirectSigner } from "@cosmjs/proto-signing" ``` The `fromMnemonic` factory function needs a string with the mnemonic. You read this string from the mnemonic file. Create a new top-level function that returns an `OfflineDirectSigner`: ```typescript [https://github.com/b9lab/cosmjs-sandbox/blob/4168b97/experiment.ts#L9-L13] const getAliceSignerFromMnemonic = async (): Promise => { return DirectSecp256k1HdWallet.fromMnemonic((await readFile("./testnet.alice.mnemonic.key")).toString(), { prefix: "bostrom", }) } ``` The Bostrom Testnet uses the `bostrom` address prefix. This is the default used by `DirectSecp256k1HdWallet`, but you are encouraged to explicitly define it as you might be working with different prefixes on different blockchains. In your `runAll` function, add: ```typescript const aliceSigner: OfflineDirectSigner = await getAliceSignerFromMnemonic() ``` As a first step, confirm that it recovers Alice's address as expected: ```typescript const alice = (await aliceSigner.getAccounts())[0].address console.log("Alice's address from signer", alice) ``` Now add the line that finally creates the signing client: ```typescript const signingClient = await SigningCyberClient.connectWithSigner(rpc, aliceSigner) ``` Check that it works like the read-only client that you used earlier, and from which [it inherits](https://github.com/cybercongress/soft3.js/blob/main/src/signingcyberclient.ts#L239), by adding: ```typescript console.log( "With signing client, chain id:", await signingClient.getChainId(), ", height:", await signingClient.getHeight() ) ``` ## Cyberlinks A cyberlink (noun) is a link between two particles registered in Bostrom blockchain by a particular neuron. To cyberlink (verb) - to create a cyberlink between two particles. ## Bandwidth The bandwidth module process and stores neuron's bandwidth in the network, dynamically adjust bandwidth price to network load. Neurons use bandwidth to add cyberlinks to the network and not need to pay gas fees. ## Bandwidth model Bandwidth is used for billing for cyberlinks creation instead of fee billing based on gas. Using the bandwidth model removes the cognitive gap for cyberlinks creation because not force neurons to pay a fee. Holding 1 volt represents the possibility to create 1 cyberlinks per `RecoveryPeriod` blocks. (example 1 cyberlink per day holding 1 Volt) Total supply of VOLTs (volts' holdings of all neurons) it's desirable network bandwidth. By investminting of HYDROGEN to VOLT then neuron increase personal bandwidth and desirable bandwidth of network. If the network has low bandwidth consumption, then the network provides a discount using `BasePrice` multiplier for neurons. ## Personal Bandwidth The volt's stake of the given neuron are easy to understand as the size of his battery. The creation of cyberlinks will consume battery charge, and the battery will be fully recharged during `RecoveryPeriod` blocks period. If a neuron consumes half of its bandwidth, its battery will be fully charged in the `RecoveryPeriod/2` blocks period. If a neuron act when network bandwidth consumption is low, then he will consume less personal bandwidth. ## Get Bandwidth Alise needs to [`investmint`](https://github.com/cybercongress/soft3.js/blob/main/src/signingcyberclient.ts#L370) `HYDROGEN(stake token)` to `VOLT` and `AMPERE` of get `Bandwidth` Alise would like to investmint 1000000000 BOOT (1 GBOOT) to VOLT resource with lock for 30 DAYS (no spendable) and Alise will get newly minted 1 VOLT to my account locked for 30 DAYS (no spendable). ``` (1 GBOOT | 30 DAYS | VOLT) ---investmint---> locked (1 GBOOT | 30 DAYS) + minted and locked (1 VOLT | 30 DAYS) ``` Alise would like to investmint 4000000000 BOOT (4 GBOOT) to AMPERE resource with lock for 7 DAYS (no spendable) and Alise will get newly minted 1 AMPERE to my account locked for 7 DAYS (no spendable). ``` (4.2 GBOOT | 7 DAYS | AMPERE) ---investmint---> locked (4.2 GBOOT | 7 DAYS) + minted and locked (1 AMPERE | 7 DAYS) ``` ## Cyberlink content Alice can send cyberlink, but to do so she also needs to pay the network's gas fee. How much gas should she use, and at what price? She can copy this: ``` Gas fee: [ { denom: 'boot', amount: '0' } ] Gas limit: 200000 ``` With the gas information now decided, how does Alice structure her command so that she cyberlinks content to network ? `SigningCyberClient`'s [`cyberlink`](https://github.com/cybercongress/soft3.js/blob/main/src/signingcyberclient.ts#L316) function takes a `CidFrom` and `CidTo` as input.: ```typescript cyberlink( neuron: string, from: string, to: string, fee: StdFee, memo = "", ): Promise ``` ### Upload content to IPFS Before sending the cyberlink, Alice needs to upload the content to `ipfs`. She can use [`js-ipfs`](https://github.com/ipfs/js-ipfs/) ### Running js-IPFS in your application If you do not need to run a command line daemon, use the ipfs-core package - it has all the features of ipfs but in a lighter package: ```sh $ npm install ipfs-core ``` Then start a node in your app: ```js import * as IPFS from 'ipfs-core' const ipfs = await IPFS.create() const { cid } = await ipfs.add('Hello world') console.info(cid) // QmXXY5ZxbtuYj6DnfApLiGstzPN7fvSyigrRee3hDWPCaf ``` ### Running js-IPFS on the CLI Installing `ipfs` globally will give you the `jsipfs` command which you can use to start a daemon running: ```sh $ npm install -g ipfs $ jsipfs daemon Initializing IPFS daemon... js-ipfs version: x.x.x System version: x64/darwin Node.js version: x.x.x Swarm listening on /ip4/127.0 .... more output ``` You can then add a file: ```sh $ jsipfs add ./hello-world.txt added QmXXY5ZxbtuYj6DnfApLiGstzPN7fvSyigrRee3hDWPCaf hello-world.txt ``` Before the cyberlink, Alisa needs to check `PersonalBandwidth` for the possibility of making a cyberlink: ```typescript const checkPersonalBandwidth = async (client: CyberClient, alice: string): Promise => { try { const response = await client.price() const priceLink = response.price.dec * 10 ** -18 const responseAccountBandwidth = await client.accountBandwidth(alice) const { maxValue, remainedValue } = responseAccountBandwidth.neuronBandwidth if (maxValue === 0 || remainedValue === 0) { return false } else if (Math.floor(remainedValue / (priceLink * 1000)) === 0) { return false } return true } catch (error) { console.log('error', error) return false } } ``` With this gas and cids, add the command: ```typescript // Execute the cyberlink Tx and store the result const result = await signingClient.cyberlink( alice, CidFrom, CidTo, { amount: [{ denom: "boot", amount: "0" }], gas: "200000", }, ) // Output the result of the Tx console.log("Transfer result:", result) ``` Run this with `npm run experiment` and you should get: ``` ... Transfer result: { code: 0, height: 0, rawLog: '[]', transactionHash: '2A2F6D0610FF60458EFC05A820B610CEFBCB5C9EF1CA322808DD8B88D369B5E0', gasUsed: 0, gasWanted: 0 } ``` Check that Alice upload information with [`getTx`](https://github.com/cybercongress/soft3.js/blob/main/src/cyberclient.ts#L314) ```typescript const result = await client.getTx("2A2F6D0610FF60458EFC05A820B610CEFBCB5C9EF1CA322808DD8B88D369B5E0") ``` ================================================ FILE: docs/deploy_contract.md ================================================ # Deploy contract with Cyber-js ## Script preparation A small, ready-made repository exists so you can experiment with Cyber-js. Clone it from here. You need [NodeJs](https://nodejs.org/en/download/). If you open the folder in [Visual Studio Code](https://code.visualstudio.com/Download), the IDE should give you all the coding help you require. In the cloned folder you need to install the required modules: ```sh $ npm install ``` Create a new file named `experiment.ts`. In it, put these lines to confirm it works: ```typescript const runAll = async(): Promise => { console.log("TODO") } runAll() ``` To execute, this TypeScript file needs to be compiled into JavaScript before being interpreted by NodeJs. Add this as a run target in `package.json`: ```json ... "scripts": { ... "experiment": "ts-node experiment.ts" } ... ``` Confirm that it does what you want: ```sh $ npm run experiment ``` This returns: ``` > ts-node experiment.ts TODO ``` You will soon make this script more meaningful. With the basic script ready, you need to prepare some elements. ## Testnet preparation The Bostrom has a number of testnets running. The Bostrom is currently running a [public testnet](https://github.com/cybercongress/cybernode) for the Space-pussy-1 upgrade that you are connecting to and running your script on. You need to connect to a public node so that you can query information and broadcast transactions. One of the available nodes is: ``` RPC: https://rpc.space-pussy-1.cybernode.ai ``` You need a wallet address on the testnet and you must create a 24-word mnemonic in order to do so. CosmJS can generate one for you. Create a new file `generate_mnemonic.ts` with the following script: ```typescript import { DirectSecp256k1HdWallet } from "@cosmjs/proto-signing" const generateKey = async (): Promise => { const wallet: DirectSecp256k1HdWallet = await DirectSecp256k1HdWallet.generate(24) process.stdout.write(wallet.mnemonic) const accounts = await wallet.getAccounts() console.error("Mnemonic with 1st account:", accounts[0].address) } generateKey() ``` Now create a **key** for our imaginary user **Alice**: *Note: You likely need to update Node.js to a later version if this fails. Find a guide [here](https://phoenixnap.com/kb/update-node-js-version). ```sh $ npx ts-node generate_mnemonic.ts > testnet.alice.mnemonic.key ``` When done, it should also tell you the address of the first account: ``` Mnemonic with 1st account: bostrom1sw8xv3mv2n4xfv6rlpzsevusyzzg78r3e78xnp ``` Temporarily keep this address for convenience, although CosmJS can always recalculate it from the mnemonic. Privately examine the file to confirm it contains your 24 words. Important considerations: 1. `process.stdout.write` was used to avoid any line return. Be careful not to add any empty lines or any other character in your `.key` file (this occurs with VSCode under certain conditions). If you add any characters, ComsJs may not be able to parse it. 2. Adjust the `.gitignore` file to not commit your `.key` file by mistake: ``` node_modules *.key ``` ## Add your imports You need a small, simple interface to a blockchain, one which could eventually have users. Good practice is to refrain from requesting a user address until necessary (e.g. when a user clicks a relevant button). Therefore, in `experiment.ts` you first use the read-only client. Import it at the top of the file: ```typescript import { CyberClient } from "@cybercongress/cyber-js" ``` Note that VSCode assists you to auto-complete [`CyberClient`](https://github.com/cybercongress/soft3.js/blob/main/src/cyberclient.ts#L144) if you type CTRL-Space inside the `{}` of the `import` line. ## Define your connection Next, you need to tell the client how to connect to the RPC port of your blockchain: ```typescript const rpc = "https://rpc.space-pussy-1.cybernode.ai" ``` Inside the `runAll` function you [initialize the connection](https://github.com/cybercongress/soft3.js/blob/main/src/cyberclient.ts#L165) and immediately [check](https://github.com/cybercongress/soft3.js/blob/main/src/cyberclient.ts#L244) you connected to the right place: ```typescript const runAll = async(): Promise => { const client = await CyberClient.connect(rpc) console.log("With client, chain id:", await client.getChainId(), ", height:", await client.getHeight()) } ``` Run again to check with `npm run experiment`, and you get: ``` With client, chain id: space-pussy-1 , height: 9507032 ``` ## Get a balance Normally you would not yet have access to your user's address. However, for this exercise you need to know how many tokens Alice has, so add a temporary new command inside `runAll`: ```typescript console.log( "Alice balances:", await client.getAllBalances("bostrom1sw8xv3mv2n4xfv6rlpzsevusyzzg78r3e78xnp"), // <-- replace with your generated address ) ``` `getAllBalances` is used because the default token name is not yet known. When you run it again, you get: ``` Alice balances: [] ``` If you just created this account, Alice's balance is zero. Alice needs tokens to be able to send transactions and participate in the network. A common practice with testnets is to expose **faucets** (services that send you test tokens for free, within limits). Request tokens for Alice by entering this command in command line: ```sh curl --header "Content-Type: application/json" --request POST --data '{"denom":"boot","address":"bostrom1sw8xv3mv2n4xfv6rlpzsevusyzzg78r3e78xnp"}' https://space-pussy-1.cybernode.ai/credit ``` Check that Alice received the tokens with `npm run experiment`. ## Prepare a signing client If you go through the methods inside [`CyberClient`](https://github.com/cybercongress/soft3.js/blob/main/src/cyberclient.ts#L144), you see that it only contains query-type methods and none for sending transactions. Now, for Alice to send transactions, she needs to be able to sign them. And to be able to sign transactions, she needs access to her _private keys_ or _mnemonics_. Or rather she needs a client that has access to those. That is where [`SigningCyberClient`](https://github.com/cybercongress/soft3.js/blob/main/src/signingcyberclient.ts#L239) comes in. Conveniently, `SigningCyberClient` inherits from `CyberClient`. Update your import line: ```typescript import { SigningCyberClient, CyberClient } from "@cybercongress/cyber-js" ``` Look at its declaration by right-clicking on the `SigningCyberClient` in your imports and choosing Go to Definition. When you instantiate `SigningCyberClient` by using the [`connectWithSigner`](https://github.com/cybercongress/soft3.js/blob/main/src/signingcyberclient.ts#L247) method, you need to pass it a [**signer**](https://github.com/cybercongress/soft3.js/blob/main/src/signingcyberclient.ts#L249). In this case, use the [`OfflineDirectSigner`](https://github.com/cybercongress/soft3.js/blob/main/src/signingcyberclient.ts#L29) interface. The recommended way to encode messages is by using `OfflineDirectSigner`, which uses Protobuf. However, hardware wallets such as Ledger do not support this and still require the legacy Amino encoder. If your app requires Amino support, you have to use the `OfflineAminoSigner`.

Read more about encoding [here](https://docs.cosmos.network/master/core/encoding.html).
The signer needs access to Alice's **private key**, and there are several ways to accomplish this. In this example, use Alice's saved **mnemonic**. To load the mnemonic as text in your code you need this import: ```typescript import { readFile } from "fs/promises" ``` There are several implementations of `OfflineDirectSigner` available. The [`DirectSecp256k1HdWallet`](https://github.com/cosmos/cosmjs/blob/0f0c9d8/packages/proto-signing/src/directsecp256k1hdwallet.ts#L133) implementation is most relevant to us due to its [`fromMnemonic`](https://github.com/cosmos/cosmjs/blob/0f0c9d8/packages/proto-signing/src/directsecp256k1hdwallet.ts#L140-L141) method. Add the import: ```typescript import { DirectSecp256k1HdWallet, OfflineDirectSigner } from "@cosmjs/proto-signing" ``` The `fromMnemonic` factory function needs a string with the mnemonic. You read this string from the mnemonic file. Create a new top-level function that returns an `OfflineDirectSigner`: ```typescript [https://github.com/b9lab/cosmjs-sandbox/blob/4168b97/experiment.ts#L9-L13] const getAliceSignerFromMnemonic = async (): Promise => { return DirectSecp256k1HdWallet.fromMnemonic((await readFile("./testnet.alice.mnemonic.key")).toString(), { prefix: "bostrom", }) } ``` The Bostrom Testnet uses the `bostrom` address prefix. This is the default used by `DirectSecp256k1HdWallet`, but you are encouraged to explicitly define it as you might be working with different prefixes on different blockchains. In your `runAll` function, add: ```typescript const aliceSigner: OfflineDirectSigner = await getAliceSignerFromMnemonic() ``` As a first step, confirm that it recovers Alice's address as expected: ```typescript const alice = (await aliceSigner.getAccounts())[0].address console.log("Alice's address from signer", alice) ``` Now add the line that finally creates the signing client: ```typescript const signingClient = await SigningCyberClient.connectWithSigner(rpc, aliceSigner) ``` Check that it works like the read-only client that you used earlier, and from which [it inherits](https://github.com/cybercongress/soft3.js/blob/main/src/signingcyberclient.ts#L239), by adding: ```typescript console.log( "With signing client, chain id:", await signingClient.getChainId(), ", height:", await signingClient.getHeight() ) ``` ## Upload wasm code Alice can now upload wasm code, but to do so she also needs to pay the network's gas fee. How much gas should she use, and at what price? She can copy this and change GasLimit if need: ``` Gas fee: [ { denom: 'boot', amount: '0' } ] Gas limit: 200000 ``` With the gas information now decided, how does Alice structure her command so that she uploads wasm code to network ? `SigningCyberClient`'s [`upload`](https://github.com/cybercongress/soft3.js/blob/main/src/signingcyberclient.ts#L466) function takes a `wasmCode` as input. `wasmCode` must be as `Uint8Array`: ```typescript upload( senderAddress: string, wasmCode: Uint8Array, fee: StdFee, memo = "", ): Promise ``` Alice can pick any `wasmCodeData` and upload, the signing client signs the transaction and broadcasts it. In this case it is: ```typescript const wasmCode = new Uint8Array(wasmCodeData); ``` With this gas and wasm information, add the command: ```typescript [https://github.com/b9lab/cosmjs-sandbox/blob/2c7b137/experiment.ts#L57-L63] // Execute the upload Tx and store the result const result = await signingClient.upload( alice, wasmCode, { amount: [{ denom: "boot", amount: "0" }], gas: "200000", }, ) // Output the result of the Tx console.log("Transfer result:", result) ``` Run this with `npm run experiment` and you should get: ``` ... Transfer result: { code: 0, height: 0, rawLog: '[]', transactionHash: '60F91D7B365245409E71D35C405D1FD5AD9D00E333CC0F992D0AC9E3A04DF0F2', gasUsed: 0, gasWanted: 0 } ``` Check that Alice upload information with [`getTx`](https://github.com/cybercongress/soft3.js/blob/main/src/cyberclient.ts#L314) ```typescript const result = await client.getTx("60F91D7B365245409E71D35C405D1FD5AD9D00E333CC0F992D0AC9E3A04DF0F2") ``` Uploads code and returns a receipt, including the code ID: ```JSON [ { "events": [ { "type": "message", "attributes": [ { "key": "action", "value": "/cosmwasm.wasm.v1.MsgStoreCode" }, { "key": "module", "value": "wasm" }, { "key": "sender", "value": "bostrom1sw8xv3mv2n4xfv6rlpzsevusyzzg78r3e78xnp" } ] }, { "type": "store_code", "attributes": [{ "key": "code_id", "value": "68" }] } ] } ] ``` ================================================ FILE: docs/help/problem_to_install_drivers.md ================================================ # Possible issue during drivers install In an installation from 0 we can find an error that forces us to restart and modify some parts in [BIOS](https://en.wikipedia.org/wiki/BIOS), I put the necessary steps here. > In this case the motherboard is an [Asus Z-97A](https://www.asus.com/Motherboards/Z97A/), but will be similar in others motherboards. ## Steps to follow 1. Go to BIOS by pressing the key for it (usually `F10` or `DEL`) 2. Go to Advanced Mode (`F7`) 3. Go to `Secure Boot` 4. In `OS Type` change `Windows UEFI mode` to `Other OS` 5. Save and restart ![mod_BIOS](../img/cyberdModBIOS2.gif) ================================================ FILE: docs/keystore.md ================================================ # Keystore management ## Key types Key types can be conditionally divided into two groups: **agents** and **validators**. **Agents** keys are used for linking content, sending liquid tokens, delegating, redelegating, and undelegating tokens to validators. Also, withdrawing rewards, voting and creating multisig accounts. - `bostrom` a.k.a. address. Cyber application key. - Derived from account mnemonic phrase, generated by `cyber keys add` - e.g. `bostrom 15h6vd5f0wqps26zjlwrc6chah08ryu4hzzdwhc` - `bostrom pub` the public key of an account address. It is used for generating multisig addresses. - Derived from account mnemonic phrase, generated by `cyber keys add` - e.g. `bostrom pub1zcjduc3q7fu03jnlu2xpl75s2nkt7krm6grh4cc5aqth73v0zwmea25wj2hsqhlqzm` All agents keypairs are stored locally in the `PATH_TO_CYBER/keys` folder. **Validators** are actors on the network committing new blocks by submitting their votes. This refers to the node itself, not a single person or a single account. Therefore, the public key here is referring to the nodes public key, not the public key of the agent address. - `bostrom valoper` validator application-level address. It is associated with a public key `bostrom valconspub`. This is the address used to identify your validator publicly. The private key associated with this address is used to delegate, unbond, claim rewards, and participate in governance. Generated by cyber on the application level. Application keys are associated with a public key prefixed by `bostrom pub` and an address prefixed by cyber network. Both are derived from account keys generated by cyber keys add. - e.g. `bostrom valoper1carzvgq3e6y3z5kz5y6gxp3wpy3qdrv928vyah` - the public key of node/validator address has been recently migrated to protobuf look. The private key associated with this Tendermint PubKey is used to sign prevotes and precommits. - Generated when the node is created - Get this value with `cyber tendermint show-validator` - e.g. `{"@type":"/cosmos.crypto.ed25519.PubKey","key":"YxN/kkQlXBwKNF4Cgi6tiqMh2ae8+tpo9VxENmFUhv8="}` > Note: A validator's operator key is directly tied to an application key, but uses reserved prefixes solely for this purpose: `bostrom valoper`. A nodes keypair is stored in `node_key.json` and `priv_validator_key.json` at `$HOME/.cyber/config` folder. You can delete them and restart `cyber` if you want to change this keypair. The new pair will be created automatically. ## Generate keys You'll need an account private and public key pair \(a.k.a. `sk, pk` respectively\) to be able to receive funds, send txs, bond tx, etc. To generate a new _secp256k1_ key: ```bash cyber keys add ``` Next, you will have to create a passphrase to protect the key on disk. The output of the above command will contain a _seed phrase_. It is recommended to save the _seed phrase_ in a safe place so that in case you forget the password, you could eventually regenerate the key from the seed phrase with the following command: ```bash cyber keys add --recover ``` Also, you can import your Cosmos account to `cyber cli` using seed phrase: ```bash cyber keys add --recover ``` cyber provides compatibility of Cosmos with Cyber addresses. You can check your application account details by account name: ```bash cyber keys show ``` You can see all of your available keys by typing: ```bash cyber keys list ``` View the validator pubkey for your node by typing: ```bash cyber tendermint show-validator ``` Note that this is the Tendermint signing key, _not_ the operator key you will use in delegation transactions. **Important note**: Starting with v.38 cosmos-SDK uses os-native keyring to store all your keys. We've noticed that in certain cases this does not work well by default (for example if you don't have any GUI installed on your machine). If during the execution of the `cyber keys add` command you get this type of error: ```bash panic: No such interface 'org.freedesktop.DBus.Properties' on object at path / goroutine 1 [running]: github.com/cosmos/cosmos-sdk/crypto/keys.keyringKeybase.writeInfo(0x1307a18, 0x1307a10, 0xc000b37160, 0x1, 0x1, 0xc000b37170, 0x1, 0x1, 0x147a6c0, 0xc000f1c780, ...) /root/go/pkg/mod/github.com/cosmos/cosmos-sdk@v0.38.1/crypto/keys/keyring.go:479 +0x38c github.com/cosmos/cosmos-sdk/crypto/keys.keyringKeybase.writeLocalKey(0x1307a18, 0x1307a10, 0xc000b37160, 0x1, 0x1, 0xc000b37170, 0x1, 0x1, 0x147a6c0, 0xc000f1c780, ...) /root/go/pkg/mod/github.com/cosmos/cosmos-sdk@v0.38.1/crypto/keys/keyring.go:465 +0x189 github.com/cosmos/cosmos-sdk/crypto/keys.baseKeybase.CreateAccount(0x1307a18, 0x1307a10, 0xc000b37160, 0x1, 0x1, 0xc000b37170, 0x1, 0x1, 0x146aa00, 0xc000b15630, ...) /root/go/pkg/mod/github.com/cosmos/cosmos-sdk@v0.38.1/crypto/keys/keybase_base.go:171 +0x192 github.com/cosmos/cosmos-sdk/crypto/keys.keyringKeybase.CreateAccount(...) /root/go/pkg/mod/github.com/cosmos/cosmos-sdk@v0.38.1/crypto/keys/keyring.go:107 github.com/cosmos/cosmos-sdk/client/keys.RunAddCmd(0xc000f0b400, 0xc000f125f0, 0x1, 0x1, 0x148dcc0, 0xc000aca550, 0xc000ea75c0, 0xc000ae1c08, 0x5e93b7) /root/go/pkg/mod/github.com/cosmos/cosmos-sdk@v0.38.1/client/keys/add.go:273 +0xa8b ... etc ``` You will have to use another keyring backend to keep your keys. Here are 2 options: store the files within the cli folder or a `pass` manager. Using the keyring backend as a **local file**: Execute: ```bash cyber keys add keyring-backend file ``` This means that you've saved your keyring-backend to a local file. *Note*, in this case, all the keys in your keyring will be encrypted using the same password. If you would like to set up a unique password for each key, you should set a unique `--home` folder for each key. To do that, just use `--home=//` with setup keyring backend and at all interactions with keys when using cyber cli: ```bash cyber config keyring-backend file --home=// cyber keys add --home=// cyber keys list --home=// ``` ================================================ FILE: docs/menu/index.md ================================================ --- headless: true --- - [Whitepaper]({{< relref "/docs/go-cyber/cyber.md" >}}) - Usage: - [Run the validator]({{< relref "/docs/go-cyber/run_validator.md" >}}) - [Supported GPUs list]({{< relref "/docs/go-cyber/supported_gpu_list.md" >}}) - [CLI guide]({{< relref "/docs/go-cyber/ultimate-commands-guide.md" >}}) - [Port forwarding]({{< relref "/docs/go-cyber/port_forwarding_guide.md" >}}) - [Cyberd Ledger guide]({{< relref "/docs/go-cyber/cyber_Ledger_guide.md" >}}) - [Multisig guide]({{< relref "/docs/go-cyber/multisig_guide.md" >}}) - [Run validator with Tendermint and Ledger]({{< relref "/docs/go-cyber/validator_launch_with_tendermintKMS_and_ledger.md" >}}) - [Set up config.toml in the right way]({{< relref "/docs/go-cyber/setup_cyber_configuration.md" >}}) - [Upgrade guide]({{< relref "/docs/go-cyber/upgrade_guide.md" >}}) - Dev environment: - [Setup development environment]({{< relref "/docs/go-cyber/setup_dev_env.md" >}}) - Specs: - [RPC]({{< relref "/docs/go-cyber/rpc.md" >}}) - [Keystore]({{< relref "/docs/go-cyber/keystore.md" >}}) - [CHANGELOG]({{< relref "/docs/go-cyber/Changelog.md" >}}) - [CONTRIBUTING]({{< relref "/docs/go-cyber/Contributing.md" >}}) ================================================ FILE: docs/multisig_guide.md ================================================ # A guide for creating a 2 of 3 multisig account and sending transactions To follow this guide you'll need `cyber` installed and connected to any cyber node (refer to our cli [guide](https://github.com/cybercongress/go-cyber/blob/main/docs/ultimate_commands_guide.md)). A reminder: this guide covers all types of transactions, not only send transactions. This guide is also relevant for Cosmos Hub Gaiacli users, except for the bandwidth params, in Cosmos we pay a fee using tokens. Do not forget about the `--chain-id` flag in `cyber`, and in the `Cosmos Hub` networks. You can always get the current `` in the master branch of the [repository](https://github.com/cybercongress/go-cyber). ## Creating a multisig The multisig account creation and sending transactions are simple and clear but can be a little long. 1. Import or create a thresholder accounts for multisig: ```bash cyber keys add test1 cyber keys add test2 ``` 2. Add pubkeys of remote thresholder accounts: ```bash cyber keys add test3 --pubkey= ``` We now have 3 accounts for multisig account generating: `test1` and `test2` on a local machine that we have access to. `test3` from a remote thresholder that we do not have access to. All the created and imported accounts can be checked with: ```bash cyber keys list ``` 3. Now, we can create and test the 2-of-3 multisig account, named for example: `multitest1` with keys `test1`,`test2` on a local machine and `test3` on a remote thresholder: ```bash cyber keys add multitest1 --multisig=test1,test2,test3 --multisig-threshold=2 ``` 4. You should top up the balance of your multisig account. Make sure that you have enough bandwidth to execute transactions later. ## Spending out of a multisig account 5. Create an unsigned transaction from the multisig account and store it in the `unsigned.json` file: ```bash cyber tx send boot \ --from= \ --chain-id= \ --generate-only > unsigned.json ``` 6. Sign this transaction with the following command and then store the signed file in `sign1.json`: ```bash cyber tx sign unsigned.json --multisig= \ --from= \ --output-document=sign1.json \ --chain-id= ``` 7. You need to send the obtained file to a remote thresholders for signing. You can see the content of the file containing the transaction with: ```bash cat unsigned.json ``` You may now copy the content that is convenient to your `.json` file and send it. 8. You should also sign the remote thresholder, just like you did two steps above, and send your signed file back. For example `sign2.json` 9. Copy the signed file from the remote thresholder into your cli home directory with the following command: ```bash cp sign2.json $HOME/.cyber ``` Your cli-home folder should content 3 `.json` files: `unsigned.json`, `sign1.json`, and `sign2.json` (at least). Those are the necessary and sufficient conditions, because we've set up a 2-out-of 3 multisig account. 10. Generate a multisig transaction with all signatures: ```bash cyber tx multisign unsigned.json multitest1 sign1.json sign2.json \ --chain-id= > signed.json ``` 11. Finally, we need to broadcast this transaction to the network: ```bash cyber tx broadcast signed.json --chain-id= ``` If the multisig account has enough bandwidth, the transaction should be broadcasted to the network. ================================================ FILE: docs/port_forwarding_guide.md ================================================ # Decentralization must be decentralized January 3, 2019, we've launched first public testnet Euler-3. Since this time we have 3 relaunches and there will be some in the future. With help from our testers and validators we are finding and fixing new bugs every day. But now one fundamental and critical bug is not fixed yet. An obvious problem of decentralization is that no entity has a global vision of the system, and there is no central authority to direct nodes in making optimal decisions with regard to software updates, routing, or solving consensus. This makes the availability of a decentralized network more difficult to maintain, a factor significant enough to contribute to the failure of a system. By the way, a huge part of disconnections and, as result, validators jailing happens by this reason. Cyberd cli can’t automatically configure your router to open port `26656`, so you will need to manually configure your router. Enabling inbound connections requires two steps: 1. Giving your computer a static (unchanging) internal IP address by configuring the Dynamic Host Configuration Protocol (DHCP) on your router. 2. Forwarding inbound connections from the Internet through your router to your computer where cyber container can process them. 3. Editing cyber configuration file. ## Configuring DHCP In order for your router to direct incoming port `26656` connections to your computer, it needs to know your computer’s internal IP address. However, routers usually give computers dynamic IP addresses that change frequently, so we need to ensure your router always gives your computer the same internal IP address. Start by logging into your router’s administration interface. Most routers can be configured using one of the following URLs, so keep clicking links until you find one that works. If none work, consult your router’s manual. ```py http://192.168.0.1 (some Linksys/Cisco models) http://192.168.1.1 (some D-Link/Netgear models) http://192.168.2.1 (some Belkin/SMC models) http://192.168.123.254 (some US Robotics models) http://10.0.1.1 (some Apple models) ``` Upon connecting, you will probably be prompted for a username and password. If you configured a password, enter it now. If not, the Router Passwords site provides a database of known default username and password pairs. After logging in, you want to search your router’s menus for options related to DHCP, the Dynamic Host Configuration Protocol. These options may also be called Address Reservation. In the reservation configuration, some routers will display a list of computers and devices currently connected to your network, and then let you select a device to make its current IP address permanent. If that’s the case, find the computer running cyber container in the list, select it, and add it to the list of reserved addresses. Make a note of its current IP address—we’ll use the address in the next section. Other routers require a more manual configuration. For these routers, you will need to look up the fixed address (MAC address) for your computer’s network card and add it to the list. Open a terminal and type ifconfig. Find the result that best matches your connection—a result starting with wlan indicates a wireless connection. Find the field that starts with HWaddr and copy the immediately following field that looks like `01:23:45:67:89:ab`. Use that value in the instructions below. Once you have the MAC address, you can fill it into to your router’s manual DHCP assignment table. Also, choose an IP address and make a note of it for the instructions in the next subsection. After entering this information, click the Add or Save button. Then reboot your computer to ensure it gets assigned the address you selected and proceed to the Port Forwarding instructions below. ## Port Forwarding An easiest way to find some detailed instructions for your router is to check [here](https://portforward.com/router.htm) or [here](https://setuprouter.com/). Here we'll provide you general idea of what has to be done. You need to know the local IP address of the computer running cyber container. You should have this information from configuring the DHCP assignment table in the subsection above. Login to your router using the same steps described near the top of the DHCP subsection. Look for an option called Port Forwarding, Port Assignment, or anything with “Port” in its name. On some routers, this option is buried in an Applications & Gaming menu. The port forwarding settings should allow you to map an external port on your router to the “internal port” of a device on your network. Both the external port and the internal port should be `26656` for cyber container. Make sure the IP address you enter is the same one you configured in the previous subsection. After filling in the details for the mapping, save the entry. You should not need to restart anything. If you still can’t connect and you use a firewall, you probably need to change your firewall settings. Ubuntu comes with its firewall disabled by default, but if you have enabled it, see the Ubuntu [wiki page](https://help.ubuntu.com/community/Gufw) for information about adding port forwarding rules. If something else went wrong, it’s probably a problem with your router configuration. Re-read the instructions above to see if you missed anything, try to look for some port-forwarding instructions [here](https://portforward.com/router.htm) or [here](https://setuprouter.com/). ## Configuring cyber Go to cyber daemon folder, then go to `config` folder and open `config.toml` file for editing. Find `peer to peer configuration options` section and edit `external_address` variable with your IP address and port `26656` ![peer_to_peer_config](https://ipfs.io/ipfs/QmQRqM4PbPt8cbDN49nAktT23XWfCixbfzfyUEkSyDUWYP) Restart cyber service. --- We call to you, validators, with a proposal to open port `26656` and make your validator-nodes available to the incoming connection. ================================================ FILE: docs/proto/proto-docs.md ================================================ # Protobuf Documentation ## Table of Contents - [cyber/bandwidth/v1beta1/types.proto](#cyber/bandwidth/v1beta1/types.proto) - [NeuronBandwidth](#cyber.bandwidth.v1beta1.NeuronBandwidth) - [Params](#cyber.bandwidth.v1beta1.Params) - [Price](#cyber.bandwidth.v1beta1.Price) - [cyber/bandwidth/v1beta1/genesis.proto](#cyber/bandwidth/v1beta1/genesis.proto) - [GenesisState](#cyber.bandwidth.v1beta1.GenesisState) - [cyber/bandwidth/v1beta1/query.proto](#cyber/bandwidth/v1beta1/query.proto) - [QueryLoadRequest](#cyber.bandwidth.v1beta1.QueryLoadRequest) - [QueryLoadResponse](#cyber.bandwidth.v1beta1.QueryLoadResponse) - [QueryNeuronBandwidthRequest](#cyber.bandwidth.v1beta1.QueryNeuronBandwidthRequest) - [QueryNeuronBandwidthResponse](#cyber.bandwidth.v1beta1.QueryNeuronBandwidthResponse) - [QueryParamsRequest](#cyber.bandwidth.v1beta1.QueryParamsRequest) - [QueryParamsResponse](#cyber.bandwidth.v1beta1.QueryParamsResponse) - [QueryPriceRequest](#cyber.bandwidth.v1beta1.QueryPriceRequest) - [QueryPriceResponse](#cyber.bandwidth.v1beta1.QueryPriceResponse) - [QueryTotalBandwidthRequest](#cyber.bandwidth.v1beta1.QueryTotalBandwidthRequest) - [QueryTotalBandwidthResponse](#cyber.bandwidth.v1beta1.QueryTotalBandwidthResponse) - [Query](#cyber.bandwidth.v1beta1.Query) - [cyber/bandwidth/v1beta1/tx.proto](#cyber/bandwidth/v1beta1/tx.proto) - [MsgUpdateParams](#cyber.bandwidth.v1beta1.MsgUpdateParams) - [MsgUpdateParamsResponse](#cyber.bandwidth.v1beta1.MsgUpdateParamsResponse) - [Msg](#cyber.bandwidth.v1beta1.Msg) - [cyber/clock/v1/clock.proto](#cyber/clock/v1/clock.proto) - [ClockContract](#cyber.clock.v1.ClockContract) - [cyber/clock/v1/genesis.proto](#cyber/clock/v1/genesis.proto) - [GenesisState](#cyber.clock.v1.GenesisState) - [Params](#cyber.clock.v1.Params) - [cyber/clock/v1/query.proto](#cyber/clock/v1/query.proto) - [QueryClockContract](#cyber.clock.v1.QueryClockContract) - [QueryClockContractResponse](#cyber.clock.v1.QueryClockContractResponse) - [QueryClockContracts](#cyber.clock.v1.QueryClockContracts) - [QueryClockContractsResponse](#cyber.clock.v1.QueryClockContractsResponse) - [QueryParamsRequest](#cyber.clock.v1.QueryParamsRequest) - [QueryParamsResponse](#cyber.clock.v1.QueryParamsResponse) - [Query](#cyber.clock.v1.Query) - [cyber/clock/v1/tx.proto](#cyber/clock/v1/tx.proto) - [MsgRegisterClockContract](#cyber.clock.v1.MsgRegisterClockContract) - [MsgRegisterClockContractResponse](#cyber.clock.v1.MsgRegisterClockContractResponse) - [MsgUnjailClockContract](#cyber.clock.v1.MsgUnjailClockContract) - [MsgUnjailClockContractResponse](#cyber.clock.v1.MsgUnjailClockContractResponse) - [MsgUnregisterClockContract](#cyber.clock.v1.MsgUnregisterClockContract) - [MsgUnregisterClockContractResponse](#cyber.clock.v1.MsgUnregisterClockContractResponse) - [MsgUpdateParams](#cyber.clock.v1.MsgUpdateParams) - [MsgUpdateParamsResponse](#cyber.clock.v1.MsgUpdateParamsResponse) - [Msg](#cyber.clock.v1.Msg) - [cyber/dmn/v1beta1/types.proto](#cyber/dmn/v1beta1/types.proto) - [Load](#cyber.dmn.v1beta1.Load) - [Params](#cyber.dmn.v1beta1.Params) - [Thought](#cyber.dmn.v1beta1.Thought) - [ThoughtStats](#cyber.dmn.v1beta1.ThoughtStats) - [Trigger](#cyber.dmn.v1beta1.Trigger) - [cyber/dmn/v1beta1/genesis.proto](#cyber/dmn/v1beta1/genesis.proto) - [GenesisState](#cyber.dmn.v1beta1.GenesisState) - [cyber/dmn/v1beta1/query.proto](#cyber/dmn/v1beta1/query.proto) - [QueryParamsRequest](#cyber.dmn.v1beta1.QueryParamsRequest) - [QueryParamsResponse](#cyber.dmn.v1beta1.QueryParamsResponse) - [QueryThoughtParamsRequest](#cyber.dmn.v1beta1.QueryThoughtParamsRequest) - [QueryThoughtResponse](#cyber.dmn.v1beta1.QueryThoughtResponse) - [QueryThoughtStatsResponse](#cyber.dmn.v1beta1.QueryThoughtStatsResponse) - [QueryThoughtsFeesRequest](#cyber.dmn.v1beta1.QueryThoughtsFeesRequest) - [QueryThoughtsFeesResponse](#cyber.dmn.v1beta1.QueryThoughtsFeesResponse) - [QueryThoughtsRequest](#cyber.dmn.v1beta1.QueryThoughtsRequest) - [QueryThoughtsResponse](#cyber.dmn.v1beta1.QueryThoughtsResponse) - [QueryThoughtsStatsRequest](#cyber.dmn.v1beta1.QueryThoughtsStatsRequest) - [QueryThoughtsStatsResponse](#cyber.dmn.v1beta1.QueryThoughtsStatsResponse) - [Query](#cyber.dmn.v1beta1.Query) - [cyber/dmn/v1beta1/tx.proto](#cyber/dmn/v1beta1/tx.proto) - [MsgChangeThoughtBlock](#cyber.dmn.v1beta1.MsgChangeThoughtBlock) - [MsgChangeThoughtBlockResponse](#cyber.dmn.v1beta1.MsgChangeThoughtBlockResponse) - [MsgChangeThoughtGasPrice](#cyber.dmn.v1beta1.MsgChangeThoughtGasPrice) - [MsgChangeThoughtGasPriceResponse](#cyber.dmn.v1beta1.MsgChangeThoughtGasPriceResponse) - [MsgChangeThoughtInput](#cyber.dmn.v1beta1.MsgChangeThoughtInput) - [MsgChangeThoughtInputResponse](#cyber.dmn.v1beta1.MsgChangeThoughtInputResponse) - [MsgChangeThoughtName](#cyber.dmn.v1beta1.MsgChangeThoughtName) - [MsgChangeThoughtNameResponse](#cyber.dmn.v1beta1.MsgChangeThoughtNameResponse) - [MsgChangeThoughtParticle](#cyber.dmn.v1beta1.MsgChangeThoughtParticle) - [MsgChangeThoughtParticleResponse](#cyber.dmn.v1beta1.MsgChangeThoughtParticleResponse) - [MsgChangeThoughtPeriod](#cyber.dmn.v1beta1.MsgChangeThoughtPeriod) - [MsgChangeThoughtPeriodResponse](#cyber.dmn.v1beta1.MsgChangeThoughtPeriodResponse) - [MsgCreateThought](#cyber.dmn.v1beta1.MsgCreateThought) - [MsgCreateThoughtResponse](#cyber.dmn.v1beta1.MsgCreateThoughtResponse) - [MsgForgetThought](#cyber.dmn.v1beta1.MsgForgetThought) - [MsgForgetThoughtResponse](#cyber.dmn.v1beta1.MsgForgetThoughtResponse) - [MsgUpdateParams](#cyber.dmn.v1beta1.MsgUpdateParams) - [MsgUpdateParamsResponse](#cyber.dmn.v1beta1.MsgUpdateParamsResponse) - [Msg](#cyber.dmn.v1beta1.Msg) - [cyber/graph/v1beta1/query.proto](#cyber/graph/v1beta1/query.proto) - [QueryBurnStatsRequest](#cyber.graph.v1beta1.QueryBurnStatsRequest) - [QueryBurnStatsResponse](#cyber.graph.v1beta1.QueryBurnStatsResponse) - [QueryGraphStatsRequest](#cyber.graph.v1beta1.QueryGraphStatsRequest) - [QueryGraphStatsResponse](#cyber.graph.v1beta1.QueryGraphStatsResponse) - [Query](#cyber.graph.v1beta1.Query) - [cyber/graph/v1beta1/types.proto](#cyber/graph/v1beta1/types.proto) - [Link](#cyber.graph.v1beta1.Link) - [cyber/graph/v1beta1/tx.proto](#cyber/graph/v1beta1/tx.proto) - [MsgCyberlink](#cyber.graph.v1beta1.MsgCyberlink) - [MsgCyberlinkResponse](#cyber.graph.v1beta1.MsgCyberlinkResponse) - [Msg](#cyber.graph.v1beta1.Msg) - [cyber/grid/v1beta1/types.proto](#cyber/grid/v1beta1/types.proto) - [Params](#cyber.grid.v1beta1.Params) - [Route](#cyber.grid.v1beta1.Route) - [Value](#cyber.grid.v1beta1.Value) - [cyber/grid/v1beta1/genesis.proto](#cyber/grid/v1beta1/genesis.proto) - [GenesisState](#cyber.grid.v1beta1.GenesisState) - [cyber/grid/v1beta1/query.proto](#cyber/grid/v1beta1/query.proto) - [QueryDestinationRequest](#cyber.grid.v1beta1.QueryDestinationRequest) - [QueryParamsRequest](#cyber.grid.v1beta1.QueryParamsRequest) - [QueryParamsResponse](#cyber.grid.v1beta1.QueryParamsResponse) - [QueryRouteRequest](#cyber.grid.v1beta1.QueryRouteRequest) - [QueryRouteResponse](#cyber.grid.v1beta1.QueryRouteResponse) - [QueryRoutedEnergyResponse](#cyber.grid.v1beta1.QueryRoutedEnergyResponse) - [QueryRoutesRequest](#cyber.grid.v1beta1.QueryRoutesRequest) - [QueryRoutesResponse](#cyber.grid.v1beta1.QueryRoutesResponse) - [QuerySourceRequest](#cyber.grid.v1beta1.QuerySourceRequest) - [Query](#cyber.grid.v1beta1.Query) - [cyber/grid/v1beta1/tx.proto](#cyber/grid/v1beta1/tx.proto) - [MsgCreateRoute](#cyber.grid.v1beta1.MsgCreateRoute) - [MsgCreateRouteResponse](#cyber.grid.v1beta1.MsgCreateRouteResponse) - [MsgDeleteRoute](#cyber.grid.v1beta1.MsgDeleteRoute) - [MsgDeleteRouteResponse](#cyber.grid.v1beta1.MsgDeleteRouteResponse) - [MsgEditRoute](#cyber.grid.v1beta1.MsgEditRoute) - [MsgEditRouteName](#cyber.grid.v1beta1.MsgEditRouteName) - [MsgEditRouteNameResponse](#cyber.grid.v1beta1.MsgEditRouteNameResponse) - [MsgEditRouteResponse](#cyber.grid.v1beta1.MsgEditRouteResponse) - [MsgUpdateParams](#cyber.grid.v1beta1.MsgUpdateParams) - [MsgUpdateParamsResponse](#cyber.grid.v1beta1.MsgUpdateParamsResponse) - [Msg](#cyber.grid.v1beta1.Msg) - [cyber/liquidity/v1beta1/tx.proto](#cyber/liquidity/v1beta1/tx.proto) - [MsgCreatePool](#cyber.liquidity.v1beta1.MsgCreatePool) - [MsgCreatePoolResponse](#cyber.liquidity.v1beta1.MsgCreatePoolResponse) - [MsgDepositWithinBatch](#cyber.liquidity.v1beta1.MsgDepositWithinBatch) - [MsgDepositWithinBatchResponse](#cyber.liquidity.v1beta1.MsgDepositWithinBatchResponse) - [MsgSwapWithinBatch](#cyber.liquidity.v1beta1.MsgSwapWithinBatch) - [MsgSwapWithinBatchResponse](#cyber.liquidity.v1beta1.MsgSwapWithinBatchResponse) - [MsgWithdrawWithinBatch](#cyber.liquidity.v1beta1.MsgWithdrawWithinBatch) - [MsgWithdrawWithinBatchResponse](#cyber.liquidity.v1beta1.MsgWithdrawWithinBatchResponse) - [Msg](#cyber.liquidity.v1beta1.Msg) - [cyber/liquidity/v1beta1/liquidity.proto](#cyber/liquidity/v1beta1/liquidity.proto) - [DepositMsgState](#cyber.liquidity.v1beta1.DepositMsgState) - [Params](#cyber.liquidity.v1beta1.Params) - [Pool](#cyber.liquidity.v1beta1.Pool) - [PoolBatch](#cyber.liquidity.v1beta1.PoolBatch) - [PoolMetadata](#cyber.liquidity.v1beta1.PoolMetadata) - [PoolType](#cyber.liquidity.v1beta1.PoolType) - [SwapMsgState](#cyber.liquidity.v1beta1.SwapMsgState) - [WithdrawMsgState](#cyber.liquidity.v1beta1.WithdrawMsgState) - [cyber/liquidity/v1beta1/genesis.proto](#cyber/liquidity/v1beta1/genesis.proto) - [GenesisState](#cyber.liquidity.v1beta1.GenesisState) - [PoolRecord](#cyber.liquidity.v1beta1.PoolRecord) - [cyber/liquidity/v1beta1/query.proto](#cyber/liquidity/v1beta1/query.proto) - [QueryLiquidityPoolBatchRequest](#cyber.liquidity.v1beta1.QueryLiquidityPoolBatchRequest) - [QueryLiquidityPoolBatchResponse](#cyber.liquidity.v1beta1.QueryLiquidityPoolBatchResponse) - [QueryLiquidityPoolByPoolCoinDenomRequest](#cyber.liquidity.v1beta1.QueryLiquidityPoolByPoolCoinDenomRequest) - [QueryLiquidityPoolByReserveAccRequest](#cyber.liquidity.v1beta1.QueryLiquidityPoolByReserveAccRequest) - [QueryLiquidityPoolRequest](#cyber.liquidity.v1beta1.QueryLiquidityPoolRequest) - [QueryLiquidityPoolResponse](#cyber.liquidity.v1beta1.QueryLiquidityPoolResponse) - [QueryLiquidityPoolsRequest](#cyber.liquidity.v1beta1.QueryLiquidityPoolsRequest) - [QueryLiquidityPoolsResponse](#cyber.liquidity.v1beta1.QueryLiquidityPoolsResponse) - [QueryParamsRequest](#cyber.liquidity.v1beta1.QueryParamsRequest) - [QueryParamsResponse](#cyber.liquidity.v1beta1.QueryParamsResponse) - [QueryPoolBatchDepositMsgRequest](#cyber.liquidity.v1beta1.QueryPoolBatchDepositMsgRequest) - [QueryPoolBatchDepositMsgResponse](#cyber.liquidity.v1beta1.QueryPoolBatchDepositMsgResponse) - [QueryPoolBatchDepositMsgsRequest](#cyber.liquidity.v1beta1.QueryPoolBatchDepositMsgsRequest) - [QueryPoolBatchDepositMsgsResponse](#cyber.liquidity.v1beta1.QueryPoolBatchDepositMsgsResponse) - [QueryPoolBatchSwapMsgRequest](#cyber.liquidity.v1beta1.QueryPoolBatchSwapMsgRequest) - [QueryPoolBatchSwapMsgResponse](#cyber.liquidity.v1beta1.QueryPoolBatchSwapMsgResponse) - [QueryPoolBatchSwapMsgsRequest](#cyber.liquidity.v1beta1.QueryPoolBatchSwapMsgsRequest) - [QueryPoolBatchSwapMsgsResponse](#cyber.liquidity.v1beta1.QueryPoolBatchSwapMsgsResponse) - [QueryPoolBatchWithdrawMsgRequest](#cyber.liquidity.v1beta1.QueryPoolBatchWithdrawMsgRequest) - [QueryPoolBatchWithdrawMsgResponse](#cyber.liquidity.v1beta1.QueryPoolBatchWithdrawMsgResponse) - [QueryPoolBatchWithdrawMsgsRequest](#cyber.liquidity.v1beta1.QueryPoolBatchWithdrawMsgsRequest) - [QueryPoolBatchWithdrawMsgsResponse](#cyber.liquidity.v1beta1.QueryPoolBatchWithdrawMsgsResponse) - [Query](#cyber.liquidity.v1beta1.Query) - [cyber/rank/v1beta1/types.proto](#cyber/rank/v1beta1/types.proto) - [Params](#cyber.rank.v1beta1.Params) - [RankedParticle](#cyber.rank.v1beta1.RankedParticle) - [cyber/rank/v1beta1/genesis.proto](#cyber/rank/v1beta1/genesis.proto) - [GenesisState](#cyber.rank.v1beta1.GenesisState) - [cyber/rank/v1beta1/pagination.proto](#cyber/rank/v1beta1/pagination.proto) - [PageRequest](#cyber.rank.v1beta1.PageRequest) - [PageResponse](#cyber.rank.v1beta1.PageResponse) - [cyber/rank/v1beta1/query.proto](#cyber/rank/v1beta1/query.proto) - [QueryIsAnyLinkExistRequest](#cyber.rank.v1beta1.QueryIsAnyLinkExistRequest) - [QueryIsLinkExistRequest](#cyber.rank.v1beta1.QueryIsLinkExistRequest) - [QueryKarmaRequest](#cyber.rank.v1beta1.QueryKarmaRequest) - [QueryKarmaResponse](#cyber.rank.v1beta1.QueryKarmaResponse) - [QueryLinkExistResponse](#cyber.rank.v1beta1.QueryLinkExistResponse) - [QueryNegentropyParticleResponse](#cyber.rank.v1beta1.QueryNegentropyParticleResponse) - [QueryNegentropyPartilceRequest](#cyber.rank.v1beta1.QueryNegentropyPartilceRequest) - [QueryNegentropyRequest](#cyber.rank.v1beta1.QueryNegentropyRequest) - [QueryNegentropyResponse](#cyber.rank.v1beta1.QueryNegentropyResponse) - [QueryParamsRequest](#cyber.rank.v1beta1.QueryParamsRequest) - [QueryParamsResponse](#cyber.rank.v1beta1.QueryParamsResponse) - [QueryRankRequest](#cyber.rank.v1beta1.QueryRankRequest) - [QueryRankResponse](#cyber.rank.v1beta1.QueryRankResponse) - [QuerySearchRequest](#cyber.rank.v1beta1.QuerySearchRequest) - [QuerySearchResponse](#cyber.rank.v1beta1.QuerySearchResponse) - [QueryTopRequest](#cyber.rank.v1beta1.QueryTopRequest) - [Query](#cyber.rank.v1beta1.Query) - [cyber/rank/v1beta1/tx.proto](#cyber/rank/v1beta1/tx.proto) - [MsgUpdateParams](#cyber.rank.v1beta1.MsgUpdateParams) - [MsgUpdateParamsResponse](#cyber.rank.v1beta1.MsgUpdateParamsResponse) - [Msg](#cyber.rank.v1beta1.Msg) - [cyber/resources/v1beta1/types.proto](#cyber/resources/v1beta1/types.proto) - [Params](#cyber.resources.v1beta1.Params) - [cyber/resources/v1beta1/genesis.proto](#cyber/resources/v1beta1/genesis.proto) - [GenesisState](#cyber.resources.v1beta1.GenesisState) - [cyber/resources/v1beta1/query.proto](#cyber/resources/v1beta1/query.proto) - [QueryAdjustedPriceRequest](#cyber.resources.v1beta1.QueryAdjustedPriceRequest) - [QueryAdjustedPriceResponse](#cyber.resources.v1beta1.QueryAdjustedPriceResponse) - [QueryInvestmintRequest](#cyber.resources.v1beta1.QueryInvestmintRequest) - [QueryInvestmintResponse](#cyber.resources.v1beta1.QueryInvestmintResponse) - [QueryParamsRequest](#cyber.resources.v1beta1.QueryParamsRequest) - [QueryParamsResponse](#cyber.resources.v1beta1.QueryParamsResponse) - [Query](#cyber.resources.v1beta1.Query) - [cyber/resources/v1beta1/tx.proto](#cyber/resources/v1beta1/tx.proto) - [MsgInvestmint](#cyber.resources.v1beta1.MsgInvestmint) - [MsgInvestmintResponse](#cyber.resources.v1beta1.MsgInvestmintResponse) - [MsgUpdateParams](#cyber.resources.v1beta1.MsgUpdateParams) - [MsgUpdateParamsResponse](#cyber.resources.v1beta1.MsgUpdateParamsResponse) - [Msg](#cyber.resources.v1beta1.Msg) - [osmosis/tokenfactory/v1beta1/authority_metadata.proto](#osmosis/tokenfactory/v1beta1/authority_metadata.proto) - [DenomAuthorityMetadata](#osmosis.tokenfactory.v1beta1.DenomAuthorityMetadata) - [osmosis/tokenfactory/v1beta1/params.proto](#osmosis/tokenfactory/v1beta1/params.proto) - [Params](#osmosis.tokenfactory.v1beta1.Params) - [osmosis/tokenfactory/v1beta1/genesis.proto](#osmosis/tokenfactory/v1beta1/genesis.proto) - [GenesisDenom](#osmosis.tokenfactory.v1beta1.GenesisDenom) - [GenesisState](#osmosis.tokenfactory.v1beta1.GenesisState) - [osmosis/tokenfactory/v1beta1/query.proto](#osmosis/tokenfactory/v1beta1/query.proto) - [QueryDenomAuthorityMetadataRequest](#osmosis.tokenfactory.v1beta1.QueryDenomAuthorityMetadataRequest) - [QueryDenomAuthorityMetadataResponse](#osmosis.tokenfactory.v1beta1.QueryDenomAuthorityMetadataResponse) - [QueryDenomsFromCreatorRequest](#osmosis.tokenfactory.v1beta1.QueryDenomsFromCreatorRequest) - [QueryDenomsFromCreatorResponse](#osmosis.tokenfactory.v1beta1.QueryDenomsFromCreatorResponse) - [QueryParamsRequest](#osmosis.tokenfactory.v1beta1.QueryParamsRequest) - [QueryParamsResponse](#osmosis.tokenfactory.v1beta1.QueryParamsResponse) - [Query](#osmosis.tokenfactory.v1beta1.Query) - [osmosis/tokenfactory/v1beta1/tx.proto](#osmosis/tokenfactory/v1beta1/tx.proto) - [MsgBurn](#osmosis.tokenfactory.v1beta1.MsgBurn) - [MsgBurnResponse](#osmosis.tokenfactory.v1beta1.MsgBurnResponse) - [MsgChangeAdmin](#osmosis.tokenfactory.v1beta1.MsgChangeAdmin) - [MsgChangeAdminResponse](#osmosis.tokenfactory.v1beta1.MsgChangeAdminResponse) - [MsgCreateDenom](#osmosis.tokenfactory.v1beta1.MsgCreateDenom) - [MsgCreateDenomResponse](#osmosis.tokenfactory.v1beta1.MsgCreateDenomResponse) - [MsgForceTransfer](#osmosis.tokenfactory.v1beta1.MsgForceTransfer) - [MsgForceTransferResponse](#osmosis.tokenfactory.v1beta1.MsgForceTransferResponse) - [MsgMint](#osmosis.tokenfactory.v1beta1.MsgMint) - [MsgMintResponse](#osmosis.tokenfactory.v1beta1.MsgMintResponse) - [MsgSetDenomMetadata](#osmosis.tokenfactory.v1beta1.MsgSetDenomMetadata) - [MsgSetDenomMetadataResponse](#osmosis.tokenfactory.v1beta1.MsgSetDenomMetadataResponse) - [MsgUpdateParams](#osmosis.tokenfactory.v1beta1.MsgUpdateParams) - [MsgUpdateParamsResponse](#osmosis.tokenfactory.v1beta1.MsgUpdateParamsResponse) - [Msg](#osmosis.tokenfactory.v1beta1.Msg) - [Scalar Value Types](#scalar-value-types)

Top

## cyber/bandwidth/v1beta1/types.proto ### NeuronBandwidth | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `neuron` | [string](#string) | | | | `remained_value` | [uint64](#uint64) | | | | `last_updated_block` | [uint64](#uint64) | | | | `max_value` | [uint64](#uint64) | | | ### Params | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `recovery_period` | [uint64](#uint64) | | | | `adjust_price_period` | [uint64](#uint64) | | | | `base_price` | [string](#string) | | | | `base_load` | [string](#string) | | | | `max_block_bandwidth` | [uint64](#uint64) | | | ### Price | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `price` | [string](#string) | | |

Top

## cyber/bandwidth/v1beta1/genesis.proto ### GenesisState | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `params` | [Params](#cyber.bandwidth.v1beta1.Params) | | |

Top

## cyber/bandwidth/v1beta1/query.proto ### QueryLoadRequest ### QueryLoadResponse | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `load` | [string](#string) | | | ### QueryNeuronBandwidthRequest | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `neuron` | [string](#string) | | | ### QueryNeuronBandwidthResponse | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `neuron_bandwidth` | [NeuronBandwidth](#cyber.bandwidth.v1beta1.NeuronBandwidth) | | | ### QueryParamsRequest ### QueryParamsResponse | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `params` | [Params](#cyber.bandwidth.v1beta1.Params) | | | ### QueryPriceRequest ### QueryPriceResponse | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `price` | [string](#string) | | | ### QueryTotalBandwidthRequest ### QueryTotalBandwidthResponse | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `total_bandwidth` | [uint64](#uint64) | | | ### Query | Method Name | Request Type | Response Type | Description | HTTP Verb | Endpoint | | ----------- | ------------ | ------------- | ------------| ------- | -------- | | `Load` | [QueryLoadRequest](#cyber.bandwidth.v1beta1.QueryLoadRequest) | [QueryLoadResponse](#cyber.bandwidth.v1beta1.QueryLoadResponse) | | GET|/cyber/bandwidth/v1beta1/bandwidth/load| | `Price` | [QueryPriceRequest](#cyber.bandwidth.v1beta1.QueryPriceRequest) | [QueryPriceResponse](#cyber.bandwidth.v1beta1.QueryPriceResponse) | | GET|/cyber/bandwidth/v1beta1/bandwidth/price| | `TotalBandwidth` | [QueryTotalBandwidthRequest](#cyber.bandwidth.v1beta1.QueryTotalBandwidthRequest) | [QueryTotalBandwidthResponse](#cyber.bandwidth.v1beta1.QueryTotalBandwidthResponse) | | GET|/cyber/bandwidth/v1beta1/bandwidth/total| | `NeuronBandwidth` | [QueryNeuronBandwidthRequest](#cyber.bandwidth.v1beta1.QueryNeuronBandwidthRequest) | [QueryNeuronBandwidthResponse](#cyber.bandwidth.v1beta1.QueryNeuronBandwidthResponse) | | GET|/cyber/bandwidth/v1beta1/bandwidth/neuron/{neuron}| | `Params` | [QueryParamsRequest](#cyber.bandwidth.v1beta1.QueryParamsRequest) | [QueryParamsResponse](#cyber.bandwidth.v1beta1.QueryParamsResponse) | | GET|/cyber/bandwidth/v1beta1/bandwidth/params|

Top

## cyber/bandwidth/v1beta1/tx.proto ### MsgUpdateParams | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `authority` | [string](#string) | | | | `params` | [Params](#cyber.bandwidth.v1beta1.Params) | | | ### MsgUpdateParamsResponse ### Msg | Method Name | Request Type | Response Type | Description | HTTP Verb | Endpoint | | ----------- | ------------ | ------------- | ------------| ------- | -------- | | `UpdateParams` | [MsgUpdateParams](#cyber.bandwidth.v1beta1.MsgUpdateParams) | [MsgUpdateParamsResponse](#cyber.bandwidth.v1beta1.MsgUpdateParamsResponse) | | |

Top

## cyber/clock/v1/clock.proto ### ClockContract This object is used to store the contract address and the jail status of the contract. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `contract_address` | [string](#string) | | The address of the contract. | | `is_jailed` | [bool](#bool) | | The jail status of the contract. |

Top

## cyber/clock/v1/genesis.proto ### GenesisState GenesisState - initial state of module | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `params` | [Params](#cyber.clock.v1.Params) | | Params of this module | ### Params Params defines the set of module parameters. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `contract_gas_limit` | [uint64](#uint64) | | contract_gas_limit defines the maximum amount of gas that can be used by a contract. |

Top

## cyber/clock/v1/query.proto ### QueryClockContract QueryClockContract is the request type to get a single contract. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `contract_address` | [string](#string) | | contract_address is the address of the contract to query. | ### QueryClockContractResponse QueryClockContractResponse is the response type for the Query/ClockContract RPC method. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `clock_contract` | [ClockContract](#cyber.clock.v1.ClockContract) | | contract is the clock contract. | ### QueryClockContracts QueryClockContracts is the request type to get all contracts. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `pagination` | [cosmos.base.query.v1beta1.PageRequest](#cosmos.base.query.v1beta1.PageRequest) | | pagination defines an optional pagination for the request. | ### QueryClockContractsResponse QueryClockContractsResponse is the response type for the Query/ClockContracts RPC method. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `clock_contracts` | [ClockContract](#cyber.clock.v1.ClockContract) | repeated | clock_contracts are the clock contracts. | | `pagination` | [cosmos.base.query.v1beta1.PageResponse](#cosmos.base.query.v1beta1.PageResponse) | | pagination defines the pagination in the response. | ### QueryParamsRequest QueryParams is the request type to get all module params. ### QueryParamsResponse QueryClockContractsResponse is the response type for the Query/ClockContracts RPC method. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `params` | [Params](#cyber.clock.v1.Params) | | | ### Query Query defines the gRPC querier service. | Method Name | Request Type | Response Type | Description | HTTP Verb | Endpoint | | ----------- | ------------ | ------------- | ------------| ------- | -------- | | `ClockContracts` | [QueryClockContracts](#cyber.clock.v1.QueryClockContracts) | [QueryClockContractsResponse](#cyber.clock.v1.QueryClockContractsResponse) | ClockContracts | GET|/cyber/clock/v1/contracts| | `ClockContract` | [QueryClockContract](#cyber.clock.v1.QueryClockContract) | [QueryClockContractResponse](#cyber.clock.v1.QueryClockContractResponse) | ClockContract | GET|/cyber/clock/v1/contracts/{contract_address}| | `Params` | [QueryParamsRequest](#cyber.clock.v1.QueryParamsRequest) | [QueryParamsResponse](#cyber.clock.v1.QueryParamsResponse) | Params | GET|/cyber/clock/v1/params|

Top

## cyber/clock/v1/tx.proto ### MsgRegisterClockContract MsgRegisterClockContract is the Msg/RegisterClockContract request type. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `sender_address` | [string](#string) | | The address of the sender. | | `contract_address` | [string](#string) | | The address of the contract to register. | ### MsgRegisterClockContractResponse MsgRegisterClockContractResponse defines the response structure for executing a MsgRegisterClockContract message. ### MsgUnjailClockContract MsgUnjailClockContract is the Msg/UnjailClockContract request type. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `sender_address` | [string](#string) | | The address of the sender. | | `contract_address` | [string](#string) | | The address of the contract to unjail. | ### MsgUnjailClockContractResponse MsgUnjailClockContractResponse defines the response structure for executing a MsgUnjailClockContract message. ### MsgUnregisterClockContract MsgUnregisterClockContract is the Msg/UnregisterClockContract request type. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `sender_address` | [string](#string) | | The address of the sender. | | `contract_address` | [string](#string) | | The address of the contract to unregister. | ### MsgUnregisterClockContractResponse MsgUnregisterClockContractResponse defines the response structure for executing a MsgUnregisterClockContract message. ### MsgUpdateParams MsgUpdateParams is the Msg/UpdateParams request type. Since: cosmos-sdk 0.47 | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `authority` | [string](#string) | | authority is the address of the governance account. | | `params` | [Params](#cyber.clock.v1.Params) | | params defines the x/clock parameters to update. NOTE: All parameters must be supplied. | ### MsgUpdateParamsResponse MsgUpdateParamsResponse defines the response structure for executing a MsgUpdateParams message. Since: cosmos-sdk 0.47 ### Msg Msg defines the Msg service. | Method Name | Request Type | Response Type | Description | HTTP Verb | Endpoint | | ----------- | ------------ | ------------- | ------------| ------- | -------- | | `RegisterClockContract` | [MsgRegisterClockContract](#cyber.clock.v1.MsgRegisterClockContract) | [MsgRegisterClockContractResponse](#cyber.clock.v1.MsgRegisterClockContractResponse) | RegisterClockContract defines the endpoint for registering a new clock contract. | POST|/cyber/clock/v1/tx/register| | `UnregisterClockContract` | [MsgUnregisterClockContract](#cyber.clock.v1.MsgUnregisterClockContract) | [MsgUnregisterClockContractResponse](#cyber.clock.v1.MsgUnregisterClockContractResponse) | UnregisterClockContract defines the endpoint for unregistering a clock contract. | POST|/cyber/clock/v1/tx/unregister| | `UnjailClockContract` | [MsgUnjailClockContract](#cyber.clock.v1.MsgUnjailClockContract) | [MsgUnjailClockContractResponse](#cyber.clock.v1.MsgUnjailClockContractResponse) | UnjailClockContract defines the endpoint for unjailing a clock contract. | POST|/cyber/clock/v1/tx/unjail| | `UpdateParams` | [MsgUpdateParams](#cyber.clock.v1.MsgUpdateParams) | [MsgUpdateParamsResponse](#cyber.clock.v1.MsgUpdateParamsResponse) | UpdateParams defines a governance operation for updating the x/clock module parameters. The authority is hard-coded to the x/gov module account. Since: cosmos-sdk 0.47 | |

Top

## cyber/dmn/v1beta1/types.proto ### Load | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `input` | [string](#string) | | | | `gas_price` | [cosmos.base.v1beta1.Coin](#cosmos.base.v1beta1.Coin) | | | ### Params | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `max_slots` | [uint32](#uint32) | | | | `max_gas` | [uint32](#uint32) | | | | `fee_ttl` | [uint32](#uint32) | | | ### Thought | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `program` | [string](#string) | | | | `trigger` | [Trigger](#cyber.dmn.v1beta1.Trigger) | | | | `load` | [Load](#cyber.dmn.v1beta1.Load) | | | | `name` | [string](#string) | | | | `particle` | [string](#string) | | | ### ThoughtStats | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `program` | [string](#string) | | | | `name` | [string](#string) | | | | `calls` | [uint64](#uint64) | | | | `fees` | [uint64](#uint64) | | | | `gas` | [uint64](#uint64) | | | | `last_block` | [uint64](#uint64) | | | ### Trigger | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `period` | [uint64](#uint64) | | | | `block` | [uint64](#uint64) | | |

Top

## cyber/dmn/v1beta1/genesis.proto ### GenesisState | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `params` | [Params](#cyber.dmn.v1beta1.Params) | | |

Top

## cyber/dmn/v1beta1/query.proto ### QueryParamsRequest ### QueryParamsResponse | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `params` | [Params](#cyber.dmn.v1beta1.Params) | | | ### QueryThoughtParamsRequest | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `program` | [string](#string) | | | | `name` | [string](#string) | | | ### QueryThoughtResponse | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `thought` | [Thought](#cyber.dmn.v1beta1.Thought) | | | ### QueryThoughtStatsResponse | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `thought_stats` | [ThoughtStats](#cyber.dmn.v1beta1.ThoughtStats) | | | ### QueryThoughtsFeesRequest ### QueryThoughtsFeesResponse | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `fees` | [cosmos.base.v1beta1.Coin](#cosmos.base.v1beta1.Coin) | repeated | | ### QueryThoughtsRequest ### QueryThoughtsResponse | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `thoughts` | [Thought](#cyber.dmn.v1beta1.Thought) | repeated | | ### QueryThoughtsStatsRequest ### QueryThoughtsStatsResponse | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `thoughts_stats` | [ThoughtStats](#cyber.dmn.v1beta1.ThoughtStats) | repeated | | ### Query | Method Name | Request Type | Response Type | Description | HTTP Verb | Endpoint | | ----------- | ------------ | ------------- | ------------| ------- | -------- | | `Params` | [QueryParamsRequest](#cyber.dmn.v1beta1.QueryParamsRequest) | [QueryParamsResponse](#cyber.dmn.v1beta1.QueryParamsResponse) | | GET|/cyber/dmn/v1beta1/dmn/params| | `Thought` | [QueryThoughtParamsRequest](#cyber.dmn.v1beta1.QueryThoughtParamsRequest) | [QueryThoughtResponse](#cyber.dmn.v1beta1.QueryThoughtResponse) | | GET|/cyber/dmn/v1beta1/dmn/thought| | `ThoughtStats` | [QueryThoughtParamsRequest](#cyber.dmn.v1beta1.QueryThoughtParamsRequest) | [QueryThoughtStatsResponse](#cyber.dmn.v1beta1.QueryThoughtStatsResponse) | | GET|/cyber/dmn/v1beta1/dmn/thought_stats| | `Thoughts` | [QueryThoughtsRequest](#cyber.dmn.v1beta1.QueryThoughtsRequest) | [QueryThoughtsResponse](#cyber.dmn.v1beta1.QueryThoughtsResponse) | | GET|/cyber/dmn/v1beta1/dmn/thoughts| | `ThoughtsStats` | [QueryThoughtsStatsRequest](#cyber.dmn.v1beta1.QueryThoughtsStatsRequest) | [QueryThoughtsStatsResponse](#cyber.dmn.v1beta1.QueryThoughtsStatsResponse) | | GET|/cyber/dmn/v1beta1/dmn/thoughts_stats| | `ThoughtsFees` | [QueryThoughtsFeesRequest](#cyber.dmn.v1beta1.QueryThoughtsFeesRequest) | [QueryThoughtsFeesResponse](#cyber.dmn.v1beta1.QueryThoughtsFeesResponse) | | GET|/cyber/dmn/v1beta1/dmn/thoughts_fees|

Top

## cyber/dmn/v1beta1/tx.proto ### MsgChangeThoughtBlock | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `program` | [string](#string) | | | | `name` | [string](#string) | | | | `block` | [uint64](#uint64) | | | ### MsgChangeThoughtBlockResponse ### MsgChangeThoughtGasPrice | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `program` | [string](#string) | | | | `name` | [string](#string) | | | | `gas_price` | [cosmos.base.v1beta1.Coin](#cosmos.base.v1beta1.Coin) | | | ### MsgChangeThoughtGasPriceResponse ### MsgChangeThoughtInput | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `program` | [string](#string) | | | | `name` | [string](#string) | | | | `input` | [string](#string) | | | ### MsgChangeThoughtInputResponse ### MsgChangeThoughtName | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `program` | [string](#string) | | | | `name` | [string](#string) | | | | `new_name` | [string](#string) | | | ### MsgChangeThoughtNameResponse ### MsgChangeThoughtParticle | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `program` | [string](#string) | | | | `name` | [string](#string) | | | | `particle` | [string](#string) | | | ### MsgChangeThoughtParticleResponse ### MsgChangeThoughtPeriod | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `program` | [string](#string) | | | | `name` | [string](#string) | | | | `period` | [uint64](#uint64) | | | ### MsgChangeThoughtPeriodResponse ### MsgCreateThought | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `program` | [string](#string) | | | | `trigger` | [Trigger](#cyber.dmn.v1beta1.Trigger) | | | | `load` | [Load](#cyber.dmn.v1beta1.Load) | | | | `name` | [string](#string) | | | | `particle` | [string](#string) | | | ### MsgCreateThoughtResponse ### MsgForgetThought | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `program` | [string](#string) | | | | `name` | [string](#string) | | | ### MsgForgetThoughtResponse ### MsgUpdateParams | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `authority` | [string](#string) | | | | `params` | [Params](#cyber.dmn.v1beta1.Params) | | | ### MsgUpdateParamsResponse ### Msg | Method Name | Request Type | Response Type | Description | HTTP Verb | Endpoint | | ----------- | ------------ | ------------- | ------------| ------- | -------- | | `CreateThought` | [MsgCreateThought](#cyber.dmn.v1beta1.MsgCreateThought) | [MsgCreateThoughtResponse](#cyber.dmn.v1beta1.MsgCreateThoughtResponse) | | | | `ForgetThought` | [MsgForgetThought](#cyber.dmn.v1beta1.MsgForgetThought) | [MsgForgetThoughtResponse](#cyber.dmn.v1beta1.MsgForgetThoughtResponse) | | | | `ChangeThoughtParticle` | [MsgChangeThoughtParticle](#cyber.dmn.v1beta1.MsgChangeThoughtParticle) | [MsgChangeThoughtParticleResponse](#cyber.dmn.v1beta1.MsgChangeThoughtParticleResponse) | | | | `ChangeThoughtName` | [MsgChangeThoughtName](#cyber.dmn.v1beta1.MsgChangeThoughtName) | [MsgChangeThoughtNameResponse](#cyber.dmn.v1beta1.MsgChangeThoughtNameResponse) | | | | `ChangeThoughtInput` | [MsgChangeThoughtInput](#cyber.dmn.v1beta1.MsgChangeThoughtInput) | [MsgChangeThoughtInputResponse](#cyber.dmn.v1beta1.MsgChangeThoughtInputResponse) | | | | `ChangeThoughtGasPrice` | [MsgChangeThoughtGasPrice](#cyber.dmn.v1beta1.MsgChangeThoughtGasPrice) | [MsgChangeThoughtGasPriceResponse](#cyber.dmn.v1beta1.MsgChangeThoughtGasPriceResponse) | | | | `ChangeThoughtPeriod` | [MsgChangeThoughtPeriod](#cyber.dmn.v1beta1.MsgChangeThoughtPeriod) | [MsgChangeThoughtPeriodResponse](#cyber.dmn.v1beta1.MsgChangeThoughtPeriodResponse) | | | | `ChangeThoughtBlock` | [MsgChangeThoughtBlock](#cyber.dmn.v1beta1.MsgChangeThoughtBlock) | [MsgChangeThoughtBlockResponse](#cyber.dmn.v1beta1.MsgChangeThoughtBlockResponse) | | | | `UpdateParams` | [MsgUpdateParams](#cyber.dmn.v1beta1.MsgUpdateParams) | [MsgUpdateParamsResponse](#cyber.dmn.v1beta1.MsgUpdateParamsResponse) | | |

Top

## cyber/graph/v1beta1/query.proto ### QueryBurnStatsRequest ### QueryBurnStatsResponse | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `millivolt` | [uint64](#uint64) | | | | `milliampere` | [uint64](#uint64) | | | ### QueryGraphStatsRequest ### QueryGraphStatsResponse | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `cyberlinks` | [uint64](#uint64) | | | | `particles` | [uint64](#uint64) | | | ### Query | Method Name | Request Type | Response Type | Description | HTTP Verb | Endpoint | | ----------- | ------------ | ------------- | ------------| ------- | -------- | | `GraphStats` | [QueryGraphStatsRequest](#cyber.graph.v1beta1.QueryGraphStatsRequest) | [QueryGraphStatsResponse](#cyber.graph.v1beta1.QueryGraphStatsResponse) | | GET|/cyber/graph/v1beta1/graph_stats| | `BurnStats` | [QueryBurnStatsRequest](#cyber.graph.v1beta1.QueryBurnStatsRequest) | [QueryBurnStatsResponse](#cyber.graph.v1beta1.QueryBurnStatsResponse) | | GET|/cyber/graph/v1beta1/burn_stats|

Top

## cyber/graph/v1beta1/types.proto ### Link | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `from` | [string](#string) | | | | `to` | [string](#string) | | |

Top

## cyber/graph/v1beta1/tx.proto ### MsgCyberlink | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `neuron` | [string](#string) | | | | `links` | [Link](#cyber.graph.v1beta1.Link) | repeated | | ### MsgCyberlinkResponse ### Msg | Method Name | Request Type | Response Type | Description | HTTP Verb | Endpoint | | ----------- | ------------ | ------------- | ------------| ------- | -------- | | `Cyberlink` | [MsgCyberlink](#cyber.graph.v1beta1.MsgCyberlink) | [MsgCyberlinkResponse](#cyber.graph.v1beta1.MsgCyberlinkResponse) | | |

Top

## cyber/grid/v1beta1/types.proto ### Params | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `max_routes` | [uint32](#uint32) | | | ### Route | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `source` | [string](#string) | | | | `destination` | [string](#string) | | | | `name` | [string](#string) | | | | `value` | [cosmos.base.v1beta1.Coin](#cosmos.base.v1beta1.Coin) | repeated | | ### Value | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `value` | [cosmos.base.v1beta1.Coin](#cosmos.base.v1beta1.Coin) | repeated | |

Top

## cyber/grid/v1beta1/genesis.proto ### GenesisState | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `params` | [Params](#cyber.grid.v1beta1.Params) | | | | `routes` | [Route](#cyber.grid.v1beta1.Route) | repeated | |

Top

## cyber/grid/v1beta1/query.proto ### QueryDestinationRequest | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `destination` | [string](#string) | | | ### QueryParamsRequest ### QueryParamsResponse | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `params` | [Params](#cyber.grid.v1beta1.Params) | | | ### QueryRouteRequest | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `source` | [string](#string) | | | | `destination` | [string](#string) | | | ### QueryRouteResponse | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `route` | [Route](#cyber.grid.v1beta1.Route) | | | ### QueryRoutedEnergyResponse | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `value` | [cosmos.base.v1beta1.Coin](#cosmos.base.v1beta1.Coin) | repeated | | ### QueryRoutesRequest | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `pagination` | [cosmos.base.query.v1beta1.PageRequest](#cosmos.base.query.v1beta1.PageRequest) | | | ### QueryRoutesResponse | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `routes` | [Route](#cyber.grid.v1beta1.Route) | repeated | | | `pagination` | [cosmos.base.query.v1beta1.PageResponse](#cosmos.base.query.v1beta1.PageResponse) | | | ### QuerySourceRequest | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `source` | [string](#string) | | | ### Query | Method Name | Request Type | Response Type | Description | HTTP Verb | Endpoint | | ----------- | ------------ | ------------- | ------------| ------- | -------- | | `Params` | [QueryParamsRequest](#cyber.grid.v1beta1.QueryParamsRequest) | [QueryParamsResponse](#cyber.grid.v1beta1.QueryParamsResponse) | | GET|/cyber/grid/v1beta1/grid/params| | `SourceRoutes` | [QuerySourceRequest](#cyber.grid.v1beta1.QuerySourceRequest) | [QueryRoutesResponse](#cyber.grid.v1beta1.QueryRoutesResponse) | | GET|/cyber/grid/v1beta1/grid/source_routes| | `DestinationRoutes` | [QueryDestinationRequest](#cyber.grid.v1beta1.QueryDestinationRequest) | [QueryRoutesResponse](#cyber.grid.v1beta1.QueryRoutesResponse) | | GET|/cyber/grid/v1beta1/grid/destination_routes| | `DestinationRoutedEnergy` | [QueryDestinationRequest](#cyber.grid.v1beta1.QueryDestinationRequest) | [QueryRoutedEnergyResponse](#cyber.grid.v1beta1.QueryRoutedEnergyResponse) | | GET|/cyber/grid/v1beta1/grid/destination_routed_energy| | `SourceRoutedEnergy` | [QuerySourceRequest](#cyber.grid.v1beta1.QuerySourceRequest) | [QueryRoutedEnergyResponse](#cyber.grid.v1beta1.QueryRoutedEnergyResponse) | | GET|/cyber/grid/v1beta1/grid/source_routed_energy| | `Route` | [QueryRouteRequest](#cyber.grid.v1beta1.QueryRouteRequest) | [QueryRouteResponse](#cyber.grid.v1beta1.QueryRouteResponse) | | GET|/cyber/grid/v1beta1/grid/route| | `Routes` | [QueryRoutesRequest](#cyber.grid.v1beta1.QueryRoutesRequest) | [QueryRoutesResponse](#cyber.grid.v1beta1.QueryRoutesResponse) | | GET|/cyber/grid/v1beta1/grid/routes|

Top

## cyber/grid/v1beta1/tx.proto ### MsgCreateRoute | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `source` | [string](#string) | | | | `destination` | [string](#string) | | | | `name` | [string](#string) | | | ### MsgCreateRouteResponse ### MsgDeleteRoute | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `source` | [string](#string) | | | | `destination` | [string](#string) | | | ### MsgDeleteRouteResponse ### MsgEditRoute | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `source` | [string](#string) | | | | `destination` | [string](#string) | | | | `value` | [cosmos.base.v1beta1.Coin](#cosmos.base.v1beta1.Coin) | | | ### MsgEditRouteName | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `source` | [string](#string) | | | | `destination` | [string](#string) | | | | `name` | [string](#string) | | | ### MsgEditRouteNameResponse ### MsgEditRouteResponse ### MsgUpdateParams | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `authority` | [string](#string) | | | | `params` | [Params](#cyber.grid.v1beta1.Params) | | | ### MsgUpdateParamsResponse ### Msg | Method Name | Request Type | Response Type | Description | HTTP Verb | Endpoint | | ----------- | ------------ | ------------- | ------------| ------- | -------- | | `CreateRoute` | [MsgCreateRoute](#cyber.grid.v1beta1.MsgCreateRoute) | [MsgCreateRouteResponse](#cyber.grid.v1beta1.MsgCreateRouteResponse) | | | | `EditRoute` | [MsgEditRoute](#cyber.grid.v1beta1.MsgEditRoute) | [MsgEditRouteResponse](#cyber.grid.v1beta1.MsgEditRouteResponse) | | | | `DeleteRoute` | [MsgDeleteRoute](#cyber.grid.v1beta1.MsgDeleteRoute) | [MsgDeleteRouteResponse](#cyber.grid.v1beta1.MsgDeleteRouteResponse) | | | | `EditRouteName` | [MsgEditRouteName](#cyber.grid.v1beta1.MsgEditRouteName) | [MsgEditRouteNameResponse](#cyber.grid.v1beta1.MsgEditRouteNameResponse) | | | | `UpdateParams` | [MsgUpdateParams](#cyber.grid.v1beta1.MsgUpdateParams) | [MsgUpdateParamsResponse](#cyber.grid.v1beta1.MsgUpdateParamsResponse) | | |

Top

## cyber/liquidity/v1beta1/tx.proto ### MsgCreatePool MsgCreatePool defines an sdk.Msg type that supports submitting a create liquidity pool tx. See: https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `pool_creator_address` | [string](#string) | | | | `pool_type_id` | [uint32](#uint32) | | id of the target pool type, must match the value in the pool. Only pool-type-id 1 is supported. | | `deposit_coins` | [cosmos.base.v1beta1.Coin](#cosmos.base.v1beta1.Coin) | repeated | reserve coin pair of the pool to deposit. | ### MsgCreatePoolResponse MsgCreatePoolResponse defines the Msg/CreatePool response type. ### MsgDepositWithinBatch `MsgDepositWithinBatch defines` an `sdk.Msg` type that supports submitting a deposit request to the batch of the liquidity pool. Deposit is submitted to the batch of the Liquidity pool with the specified `pool_id`, `deposit_coins` for reserve. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. See: https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `depositor_address` | [string](#string) | | | | `pool_id` | [uint64](#uint64) | | id of the target pool | | `deposit_coins` | [cosmos.base.v1beta1.Coin](#cosmos.base.v1beta1.Coin) | repeated | reserve coin pair of the pool to deposit | ### MsgDepositWithinBatchResponse MsgDepositWithinBatchResponse defines the Msg/DepositWithinBatch response type. ### MsgSwapWithinBatch `MsgSwapWithinBatch` defines an sdk.Msg type that supports submitting a swap offer request to the batch of the liquidity pool. Submit swap offer to the liquidity pool batch with the specified the `pool_id`, `swap_type_id`, `demand_coin_denom` with the coin and the price you're offering and `offer_coin_fee` must be half of offer coin amount * current `params.swap_fee_rate` and ceil for reservation to pay fees. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. You must request the same fields as the pool. Only the default `swap_type_id` 1 is supported. See: https://github.com/gravity-devs/liquidity/tree/develop/doc https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `swap_requester_address` | [string](#string) | | address of swap requester | | `pool_id` | [uint64](#uint64) | | id of swap type, must match the value in the pool. Only `swap_type_id` 1 is supported. | | `swap_type_id` | [uint32](#uint32) | | id of swap type. Must match the value in the pool. | | `offer_coin` | [cosmos.base.v1beta1.Coin](#cosmos.base.v1beta1.Coin) | | offer sdk.coin for the swap request, must match the denom in the pool. | | `demand_coin_denom` | [string](#string) | | denom of demand coin to be exchanged on the swap request, must match the denom in the pool. | | `offer_coin_fee` | [cosmos.base.v1beta1.Coin](#cosmos.base.v1beta1.Coin) | | half of offer coin amount * params.swap_fee_rate and ceil for reservation to pay fees. | | `order_price` | [string](#string) | | limit order price for the order, the price is the exchange ratio of X/Y where X is the amount of the first coin and Y is the amount of the second coin when their denoms are sorted alphabetically. | ### MsgSwapWithinBatchResponse MsgSwapWithinBatchResponse defines the Msg/Swap response type. ### MsgWithdrawWithinBatch `MsgWithdrawWithinBatch` defines an `sdk.Msg` type that supports submitting a withdraw request to the batch of the liquidity pool. Withdraw is submitted to the batch from the Liquidity pool with the specified `pool_id`, `pool_coin` of the pool. This request is stacked in the batch of the liquidity pool, is not processed immediately, and is processed in the `endblock` at the same time as other requests. See: https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `withdrawer_address` | [string](#string) | | | | `pool_id` | [uint64](#uint64) | | id of the target pool | | `pool_coin` | [cosmos.base.v1beta1.Coin](#cosmos.base.v1beta1.Coin) | | | ### MsgWithdrawWithinBatchResponse MsgWithdrawWithinBatchResponse defines the Msg/WithdrawWithinBatch response type. ### Msg Msg defines the liquidity Msg service. | Method Name | Request Type | Response Type | Description | HTTP Verb | Endpoint | | ----------- | ------------ | ------------- | ------------| ------- | -------- | | `CreatePool` | [MsgCreatePool](#cyber.liquidity.v1beta1.MsgCreatePool) | [MsgCreatePoolResponse](#cyber.liquidity.v1beta1.MsgCreatePoolResponse) | Submit a create liquidity pool message. | | | `DepositWithinBatch` | [MsgDepositWithinBatch](#cyber.liquidity.v1beta1.MsgDepositWithinBatch) | [MsgDepositWithinBatchResponse](#cyber.liquidity.v1beta1.MsgDepositWithinBatchResponse) | Submit a deposit to the liquidity pool batch. | | | `WithdrawWithinBatch` | [MsgWithdrawWithinBatch](#cyber.liquidity.v1beta1.MsgWithdrawWithinBatch) | [MsgWithdrawWithinBatchResponse](#cyber.liquidity.v1beta1.MsgWithdrawWithinBatchResponse) | Submit a withdraw from the liquidity pool batch. | | | `Swap` | [MsgSwapWithinBatch](#cyber.liquidity.v1beta1.MsgSwapWithinBatch) | [MsgSwapWithinBatchResponse](#cyber.liquidity.v1beta1.MsgSwapWithinBatchResponse) | Submit a swap to the liquidity pool batch. | |

Top

## cyber/liquidity/v1beta1/liquidity.proto ### DepositMsgState DepositMsgState defines the state of deposit message that contains state information as it is processed in the next batch or batches. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `msg_height` | [int64](#int64) | | height where this message is appended to the batch | | `msg_index` | [uint64](#uint64) | | index of this deposit message in this liquidity pool | | `executed` | [bool](#bool) | | true if executed on this batch, false if not executed | | `succeeded` | [bool](#bool) | | true if executed successfully on this batch, false if failed | | `to_be_deleted` | [bool](#bool) | | true if ready to be deleted on kvstore, false if not ready to be deleted | | `msg` | [MsgDepositWithinBatch](#cyber.liquidity.v1beta1.MsgDepositWithinBatch) | | MsgDepositWithinBatch | ### Params Params defines the parameters for the liquidity module. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `pool_types` | [PoolType](#cyber.liquidity.v1beta1.PoolType) | repeated | list of available pool types | | `min_init_deposit_amount` | [string](#string) | | Minimum number of coins to be deposited to the liquidity pool on pool creation. | | `init_pool_coin_mint_amount` | [string](#string) | | Initial mint amount of pool coins upon pool creation. | | `max_reserve_coin_amount` | [string](#string) | | Limit the size of each liquidity pool to minimize risk. In development, set to 0 for no limit. In production, set a limit. | | `pool_creation_fee` | [cosmos.base.v1beta1.Coin](#cosmos.base.v1beta1.Coin) | repeated | Fee paid to create a Liquidity Pool. Set a fee to prevent spamming. | | `swap_fee_rate` | [string](#string) | | Swap fee rate for every executed swap. | | `withdraw_fee_rate` | [string](#string) | | Reserve coin withdrawal with less proportion by withdrawFeeRate. | | `max_order_amount_ratio` | [string](#string) | | Maximum ratio of reserve coins that can be ordered at a swap order. | | `unit_batch_height` | [uint32](#uint32) | | The smallest unit batch height for every liquidity pool. | | `circuit_breaker_enabled` | [bool](#bool) | | Circuit breaker enables or disables transaction messages in liquidity module. | ### Pool Pool defines the liquidity pool that contains pool information. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `id` | [uint64](#uint64) | | id of the pool | | `type_id` | [uint32](#uint32) | | id of the pool_type | | `reserve_coin_denoms` | [string](#string) | repeated | denoms of reserve coin pair of the pool | | `reserve_account_address` | [string](#string) | | reserve account address of the pool | | `pool_coin_denom` | [string](#string) | | denom of pool coin of the pool | ### PoolBatch PoolBatch defines the batch or batches of a given liquidity pool that contains indexes of deposit, withdraw, and swap messages. Index param increments by 1 if the pool id is same. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `pool_id` | [uint64](#uint64) | | id of the pool | | `index` | [uint64](#uint64) | | index of this batch | | `begin_height` | [int64](#int64) | | height where this batch is started | | `deposit_msg_index` | [uint64](#uint64) | | last index of DepositMsgStates | | `withdraw_msg_index` | [uint64](#uint64) | | last index of WithdrawMsgStates | | `swap_msg_index` | [uint64](#uint64) | | last index of SwapMsgStates | | `executed` | [bool](#bool) | | true if executed, false if not executed | ### PoolMetadata Metadata for the state of each pool for invariant checking after genesis export or import. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `pool_id` | [uint64](#uint64) | | id of the pool | | `pool_coin_total_supply` | [cosmos.base.v1beta1.Coin](#cosmos.base.v1beta1.Coin) | | pool coin issued at the pool | | `reserve_coins` | [cosmos.base.v1beta1.Coin](#cosmos.base.v1beta1.Coin) | repeated | reserve coins deposited in the pool | ### PoolType Structure for the pool type to distinguish the characteristics of the reserve pools. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `id` | [uint32](#uint32) | | This is the id of the pool_type that is used as pool_type_id for pool creation. In this version, only pool-type-id 1 is supported. {"id":1,"name":"ConstantProductLiquidityPool","min_reserve_coin_num":2,"max_reserve_coin_num":2,"description":""} | | `name` | [string](#string) | | name of the pool type. | | `min_reserve_coin_num` | [uint32](#uint32) | | minimum number of reserveCoins for LiquidityPoolType, only 2 reserve coins are supported. | | `max_reserve_coin_num` | [uint32](#uint32) | | maximum number of reserveCoins for LiquidityPoolType, only 2 reserve coins are supported. | | `description` | [string](#string) | | description of the pool type. | ### SwapMsgState SwapMsgState defines the state of the swap message that contains state information as the message is processed in the next batch or batches. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `msg_height` | [int64](#int64) | | height where this message is appended to the batch | | `msg_index` | [uint64](#uint64) | | index of this swap message in this liquidity pool | | `executed` | [bool](#bool) | | true if executed on this batch, false if not executed | | `succeeded` | [bool](#bool) | | true if executed successfully on this batch, false if failed | | `to_be_deleted` | [bool](#bool) | | true if ready to be deleted on kvstore, false if not ready to be deleted | | `order_expiry_height` | [int64](#int64) | | swap orders are cancelled when current height is equal to or higher than ExpiryHeight | | `exchanged_offer_coin` | [cosmos.base.v1beta1.Coin](#cosmos.base.v1beta1.Coin) | | offer coin exchanged until now | | `remaining_offer_coin` | [cosmos.base.v1beta1.Coin](#cosmos.base.v1beta1.Coin) | | offer coin currently remaining to be exchanged | | `reserved_offer_coin_fee` | [cosmos.base.v1beta1.Coin](#cosmos.base.v1beta1.Coin) | | reserve fee for pays fee in half offer coin | | `msg` | [MsgSwapWithinBatch](#cyber.liquidity.v1beta1.MsgSwapWithinBatch) | | MsgSwapWithinBatch | ### WithdrawMsgState WithdrawMsgState defines the state of the withdraw message that contains state information as the message is processed in the next batch or batches. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `msg_height` | [int64](#int64) | | height where this message is appended to the batch | | `msg_index` | [uint64](#uint64) | | index of this withdraw message in this liquidity pool | | `executed` | [bool](#bool) | | true if executed on this batch, false if not executed | | `succeeded` | [bool](#bool) | | true if executed successfully on this batch, false if failed | | `to_be_deleted` | [bool](#bool) | | true if ready to be deleted on kvstore, false if not ready to be deleted | | `msg` | [MsgWithdrawWithinBatch](#cyber.liquidity.v1beta1.MsgWithdrawWithinBatch) | | MsgWithdrawWithinBatch |

Top

## cyber/liquidity/v1beta1/genesis.proto ### GenesisState GenesisState defines the liquidity module's genesis state. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `params` | [Params](#cyber.liquidity.v1beta1.Params) | | params defines all the parameters for the liquidity module. | | `pool_records` | [PoolRecord](#cyber.liquidity.v1beta1.PoolRecord) | repeated | | ### PoolRecord records the state of each pool after genesis export or import, used to check variables | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `pool` | [Pool](#cyber.liquidity.v1beta1.Pool) | | | | `pool_metadata` | [PoolMetadata](#cyber.liquidity.v1beta1.PoolMetadata) | | | | `pool_batch` | [PoolBatch](#cyber.liquidity.v1beta1.PoolBatch) | | | | `deposit_msg_states` | [DepositMsgState](#cyber.liquidity.v1beta1.DepositMsgState) | repeated | | | `withdraw_msg_states` | [WithdrawMsgState](#cyber.liquidity.v1beta1.WithdrawMsgState) | repeated | | | `swap_msg_states` | [SwapMsgState](#cyber.liquidity.v1beta1.SwapMsgState) | repeated | |

Top

## cyber/liquidity/v1beta1/query.proto ### QueryLiquidityPoolBatchRequest the request type for the QueryLiquidityPoolBatch RPC method. requestable including specified pool_id. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `pool_id` | [uint64](#uint64) | | id of the target pool for query | ### QueryLiquidityPoolBatchResponse the response type for the QueryLiquidityPoolBatchResponse RPC method. Returns the liquidity pool batch that corresponds to the requested pool_id. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `batch` | [PoolBatch](#cyber.liquidity.v1beta1.PoolBatch) | | | ### QueryLiquidityPoolByPoolCoinDenomRequest the request type for the QueryLiquidityByPoolCoinDenomPool RPC method. Requestable specified pool_coin_denom. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `pool_coin_denom` | [string](#string) | | | ### QueryLiquidityPoolByReserveAccRequest the request type for the QueryLiquidityByReserveAcc RPC method. Requestable specified reserve_acc. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `reserve_acc` | [string](#string) | | | ### QueryLiquidityPoolRequest the request type for the QueryLiquidityPool RPC method. requestable specified pool_id. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `pool_id` | [uint64](#uint64) | | | ### QueryLiquidityPoolResponse the response type for the QueryLiquidityPoolResponse RPC method. Returns the liquidity pool that corresponds to the requested pool_id. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `pool` | [Pool](#cyber.liquidity.v1beta1.Pool) | | | ### QueryLiquidityPoolsRequest the request type for the QueryLiquidityPools RPC method. Requestable including pagination offset, limit, key. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `pagination` | [cosmos.base.query.v1beta1.PageRequest](#cosmos.base.query.v1beta1.PageRequest) | | pagination defines an optional pagination for the request. | ### QueryLiquidityPoolsResponse the response type for the QueryLiquidityPoolsResponse RPC method. This includes a list of all existing liquidity pools and paging results that contain next_key and total count. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `pools` | [Pool](#cyber.liquidity.v1beta1.Pool) | repeated | | | `pagination` | [cosmos.base.query.v1beta1.PageResponse](#cosmos.base.query.v1beta1.PageResponse) | | pagination defines the pagination in the response. not working on this version. | ### QueryParamsRequest QueryParamsRequest is request type for the QueryParams RPC method. ### QueryParamsResponse the response type for the QueryParamsResponse RPC method. This includes current parameter of the liquidity module. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `params` | [Params](#cyber.liquidity.v1beta1.Params) | | params holds all the parameters of this module. | ### QueryPoolBatchDepositMsgRequest the request type for the QueryPoolBatchDeposit RPC method. requestable including specified pool_id and msg_index. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `pool_id` | [uint64](#uint64) | | id of the target pool for query | | `msg_index` | [uint64](#uint64) | | target msg_index of the pool | ### QueryPoolBatchDepositMsgResponse the response type for the QueryPoolBatchDepositMsg RPC method. This includes a batch swap message of the batch. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `deposit` | [DepositMsgState](#cyber.liquidity.v1beta1.DepositMsgState) | | | ### QueryPoolBatchDepositMsgsRequest the request type for the QueryPoolBatchDeposit RPC method. Requestable including specified pool_id and pagination offset, limit, key. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `pool_id` | [uint64](#uint64) | | id of the target pool for query | | `pagination` | [cosmos.base.query.v1beta1.PageRequest](#cosmos.base.query.v1beta1.PageRequest) | | pagination defines an optional pagination for the request. | ### QueryPoolBatchDepositMsgsResponse the response type for the QueryPoolBatchDeposit RPC method. This includes a list of all currently existing deposit messages of the batch and paging results that contain next_key and total count. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `deposits` | [DepositMsgState](#cyber.liquidity.v1beta1.DepositMsgState) | repeated | | | `pagination` | [cosmos.base.query.v1beta1.PageResponse](#cosmos.base.query.v1beta1.PageResponse) | | pagination defines the pagination in the response. not working on this version. | ### QueryPoolBatchSwapMsgRequest the request type for the QueryPoolBatchSwap RPC method. Requestable including specified pool_id and msg_index. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `pool_id` | [uint64](#uint64) | | id of the target pool for query | | `msg_index` | [uint64](#uint64) | | target msg_index of the pool | ### QueryPoolBatchSwapMsgResponse the response type for the QueryPoolBatchSwapMsg RPC method. This includes a batch swap message of the batch. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `swap` | [SwapMsgState](#cyber.liquidity.v1beta1.SwapMsgState) | | | ### QueryPoolBatchSwapMsgsRequest the request type for the QueryPoolBatchSwapMsgs RPC method. Requestable including specified pool_id and pagination offset, limit, key. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `pool_id` | [uint64](#uint64) | | id of the target pool for query | | `pagination` | [cosmos.base.query.v1beta1.PageRequest](#cosmos.base.query.v1beta1.PageRequest) | | pagination defines an optional pagination for the request. | ### QueryPoolBatchSwapMsgsResponse the response type for the QueryPoolBatchSwapMsgs RPC method. This includes list of all currently existing swap messages of the batch and paging results that contain next_key and total count. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `swaps` | [SwapMsgState](#cyber.liquidity.v1beta1.SwapMsgState) | repeated | | | `pagination` | [cosmos.base.query.v1beta1.PageResponse](#cosmos.base.query.v1beta1.PageResponse) | | pagination defines the pagination in the response. not working on this version. | ### QueryPoolBatchWithdrawMsgRequest the request type for the QueryPoolBatchWithdraw RPC method. requestable including specified pool_id and msg_index. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `pool_id` | [uint64](#uint64) | | id of the target pool for query | | `msg_index` | [uint64](#uint64) | | target msg_index of the pool | ### QueryPoolBatchWithdrawMsgResponse the response type for the QueryPoolBatchWithdrawMsg RPC method. This includes a batch swap message of the batch. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `withdraw` | [WithdrawMsgState](#cyber.liquidity.v1beta1.WithdrawMsgState) | | | ### QueryPoolBatchWithdrawMsgsRequest the request type for the QueryPoolBatchWithdraw RPC method. Requestable including specified pool_id and pagination offset, limit, key. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `pool_id` | [uint64](#uint64) | | id of the target pool for query | | `pagination` | [cosmos.base.query.v1beta1.PageRequest](#cosmos.base.query.v1beta1.PageRequest) | | pagination defines an optional pagination for the request. | ### QueryPoolBatchWithdrawMsgsResponse the response type for the QueryPoolBatchWithdraw RPC method. This includes a list of all currently existing withdraw messages of the batch and paging results that contain next_key and total count. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `withdraws` | [WithdrawMsgState](#cyber.liquidity.v1beta1.WithdrawMsgState) | repeated | | | `pagination` | [cosmos.base.query.v1beta1.PageResponse](#cosmos.base.query.v1beta1.PageResponse) | | pagination defines the pagination in the response. Not supported on this version. | ### Query Query defines the gRPC query service for the liquidity module. | Method Name | Request Type | Response Type | Description | HTTP Verb | Endpoint | | ----------- | ------------ | ------------- | ------------| ------- | -------- | | `LiquidityPools` | [QueryLiquidityPoolsRequest](#cyber.liquidity.v1beta1.QueryLiquidityPoolsRequest) | [QueryLiquidityPoolsResponse](#cyber.liquidity.v1beta1.QueryLiquidityPoolsResponse) | Get existing liquidity pools. | GET|/cosmos/liquidity/v1beta1/pools| | `LiquidityPool` | [QueryLiquidityPoolRequest](#cyber.liquidity.v1beta1.QueryLiquidityPoolRequest) | [QueryLiquidityPoolResponse](#cyber.liquidity.v1beta1.QueryLiquidityPoolResponse) | Get specific liquidity pool. | GET|/cosmos/liquidity/v1beta1/pools/{pool_id}| | `LiquidityPoolByPoolCoinDenom` | [QueryLiquidityPoolByPoolCoinDenomRequest](#cyber.liquidity.v1beta1.QueryLiquidityPoolByPoolCoinDenomRequest) | [QueryLiquidityPoolResponse](#cyber.liquidity.v1beta1.QueryLiquidityPoolResponse) | Get specific liquidity pool corresponding to the pool_coin_denom. | GET|/cosmos/liquidity/v1beta1/pools/pool_coin_denom/{pool_coin_denom}| | `LiquidityPoolByReserveAcc` | [QueryLiquidityPoolByReserveAccRequest](#cyber.liquidity.v1beta1.QueryLiquidityPoolByReserveAccRequest) | [QueryLiquidityPoolResponse](#cyber.liquidity.v1beta1.QueryLiquidityPoolResponse) | Get specific liquidity pool corresponding to the reserve account. | GET|/cosmos/liquidity/v1beta1/pools/reserve_acc/{reserve_acc}| | `LiquidityPoolBatch` | [QueryLiquidityPoolBatchRequest](#cyber.liquidity.v1beta1.QueryLiquidityPoolBatchRequest) | [QueryLiquidityPoolBatchResponse](#cyber.liquidity.v1beta1.QueryLiquidityPoolBatchResponse) | Get the pool's current batch. | GET|/cosmos/liquidity/v1beta1/pools/{pool_id}/batch| | `PoolBatchSwapMsgs` | [QueryPoolBatchSwapMsgsRequest](#cyber.liquidity.v1beta1.QueryPoolBatchSwapMsgsRequest) | [QueryPoolBatchSwapMsgsResponse](#cyber.liquidity.v1beta1.QueryPoolBatchSwapMsgsResponse) | Get all swap messages in the pool's current batch. | GET|/cosmos/liquidity/v1beta1/pools/{pool_id}/batch/swaps| | `PoolBatchSwapMsg` | [QueryPoolBatchSwapMsgRequest](#cyber.liquidity.v1beta1.QueryPoolBatchSwapMsgRequest) | [QueryPoolBatchSwapMsgResponse](#cyber.liquidity.v1beta1.QueryPoolBatchSwapMsgResponse) | Get a specific swap message in the pool's current batch. | GET|/cosmos/liquidity/v1beta1/pools/{pool_id}/batch/swaps/{msg_index}| | `PoolBatchDepositMsgs` | [QueryPoolBatchDepositMsgsRequest](#cyber.liquidity.v1beta1.QueryPoolBatchDepositMsgsRequest) | [QueryPoolBatchDepositMsgsResponse](#cyber.liquidity.v1beta1.QueryPoolBatchDepositMsgsResponse) | Get all deposit messages in the pool's current batch. | GET|/cosmos/liquidity/v1beta1/pools/{pool_id}/batch/deposits| | `PoolBatchDepositMsg` | [QueryPoolBatchDepositMsgRequest](#cyber.liquidity.v1beta1.QueryPoolBatchDepositMsgRequest) | [QueryPoolBatchDepositMsgResponse](#cyber.liquidity.v1beta1.QueryPoolBatchDepositMsgResponse) | Get a specific deposit message in the pool's current batch. | GET|/cosmos/liquidity/v1beta1/pools/{pool_id}/batch/deposits/{msg_index}| | `PoolBatchWithdrawMsgs` | [QueryPoolBatchWithdrawMsgsRequest](#cyber.liquidity.v1beta1.QueryPoolBatchWithdrawMsgsRequest) | [QueryPoolBatchWithdrawMsgsResponse](#cyber.liquidity.v1beta1.QueryPoolBatchWithdrawMsgsResponse) | Get all withdraw messages in the pool's current batch. | GET|/cosmos/liquidity/v1beta1/pools/{pool_id}/batch/withdraws| | `PoolBatchWithdrawMsg` | [QueryPoolBatchWithdrawMsgRequest](#cyber.liquidity.v1beta1.QueryPoolBatchWithdrawMsgRequest) | [QueryPoolBatchWithdrawMsgResponse](#cyber.liquidity.v1beta1.QueryPoolBatchWithdrawMsgResponse) | Get a specific withdraw message in the pool's current batch. | GET|/cosmos/liquidity/v1beta1/pools/{pool_id}/batch/withdraws/{msg_index}| | `Params` | [QueryParamsRequest](#cyber.liquidity.v1beta1.QueryParamsRequest) | [QueryParamsResponse](#cyber.liquidity.v1beta1.QueryParamsResponse) | Get all parameters of the liquidity module. | GET|/cosmos/liquidity/v1beta1/params|

Top

## cyber/rank/v1beta1/types.proto ### Params | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `calculation_period` | [int64](#int64) | | | | `damping_factor` | [string](#string) | | | | `tolerance` | [string](#string) | | | ### RankedParticle | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `particle` | [string](#string) | | | | `rank` | [uint64](#uint64) | | |

Top

## cyber/rank/v1beta1/genesis.proto ### GenesisState | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `params` | [Params](#cyber.rank.v1beta1.Params) | | |

Top

## cyber/rank/v1beta1/pagination.proto ### PageRequest | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `page` | [uint32](#uint32) | | | | `per_page` | [uint32](#uint32) | | | ### PageResponse | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `total` | [uint32](#uint32) | | |

Top

## cyber/rank/v1beta1/query.proto ### QueryIsAnyLinkExistRequest | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `from` | [string](#string) | | | | `to` | [string](#string) | | | ### QueryIsLinkExistRequest | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `from` | [string](#string) | | | | `to` | [string](#string) | | | | `address` | [string](#string) | | | ### QueryKarmaRequest | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `neuron` | [string](#string) | | | ### QueryKarmaResponse | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `karma` | [uint64](#uint64) | | | ### QueryLinkExistResponse | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `exist` | [bool](#bool) | | | ### QueryNegentropyParticleResponse | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `entropy` | [uint64](#uint64) | | | ### QueryNegentropyPartilceRequest | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `particle` | [string](#string) | | | ### QueryNegentropyRequest ### QueryNegentropyResponse | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `negentropy` | [uint64](#uint64) | | | ### QueryParamsRequest ### QueryParamsResponse | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `params` | [Params](#cyber.rank.v1beta1.Params) | | | ### QueryRankRequest | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `particle` | [string](#string) | | | ### QueryRankResponse | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `rank` | [uint64](#uint64) | | | ### QuerySearchRequest | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `particle` | [string](#string) | | | | `pagination` | [PageRequest](#cyber.rank.v1beta1.PageRequest) | | | ### QuerySearchResponse | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `result` | [RankedParticle](#cyber.rank.v1beta1.RankedParticle) | repeated | | | `pagination` | [PageResponse](#cyber.rank.v1beta1.PageResponse) | | | ### QueryTopRequest | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `pagination` | [PageRequest](#cyber.rank.v1beta1.PageRequest) | | | ### Query | Method Name | Request Type | Response Type | Description | HTTP Verb | Endpoint | | ----------- | ------------ | ------------- | ------------| ------- | -------- | | `Params` | [QueryParamsRequest](#cyber.rank.v1beta1.QueryParamsRequest) | [QueryParamsResponse](#cyber.rank.v1beta1.QueryParamsResponse) | | GET|/cyber/rank/v1beta1/rank/params| | `Rank` | [QueryRankRequest](#cyber.rank.v1beta1.QueryRankRequest) | [QueryRankResponse](#cyber.rank.v1beta1.QueryRankResponse) | | GET|/cyber/rank/v1beta1/rank/rank/{particle}| | `Search` | [QuerySearchRequest](#cyber.rank.v1beta1.QuerySearchRequest) | [QuerySearchResponse](#cyber.rank.v1beta1.QuerySearchResponse) | | GET|/cyber/rank/v1beta1/rank/search/{particle}| | `Backlinks` | [QuerySearchRequest](#cyber.rank.v1beta1.QuerySearchRequest) | [QuerySearchResponse](#cyber.rank.v1beta1.QuerySearchResponse) | | GET|/cyber/rank/v1beta1/rank/backlinks/{particle}| | `Top` | [QueryTopRequest](#cyber.rank.v1beta1.QueryTopRequest) | [QuerySearchResponse](#cyber.rank.v1beta1.QuerySearchResponse) | | GET|/cyber/rank/v1beta1/rank/top| | `IsLinkExist` | [QueryIsLinkExistRequest](#cyber.rank.v1beta1.QueryIsLinkExistRequest) | [QueryLinkExistResponse](#cyber.rank.v1beta1.QueryLinkExistResponse) | | GET|/cyber/rank/v1beta1/is_link_exist| | `IsAnyLinkExist` | [QueryIsAnyLinkExistRequest](#cyber.rank.v1beta1.QueryIsAnyLinkExistRequest) | [QueryLinkExistResponse](#cyber.rank.v1beta1.QueryLinkExistResponse) | | GET|/cyber/rank/v1beta1/is_any_link_exist| | `ParticleNegentropy` | [QueryNegentropyPartilceRequest](#cyber.rank.v1beta1.QueryNegentropyPartilceRequest) | [QueryNegentropyParticleResponse](#cyber.rank.v1beta1.QueryNegentropyParticleResponse) | | GET|/cyber/rank/v1beta1/negentropy/{particle}| | `Negentropy` | [QueryNegentropyRequest](#cyber.rank.v1beta1.QueryNegentropyRequest) | [QueryNegentropyResponse](#cyber.rank.v1beta1.QueryNegentropyResponse) | | GET|/cyber/rank/v1beta1/negentropy| | `Karma` | [QueryKarmaRequest](#cyber.rank.v1beta1.QueryKarmaRequest) | [QueryKarmaResponse](#cyber.rank.v1beta1.QueryKarmaResponse) | | GET|/cyber/rank/v1beta1/karma/{neuron}|

Top

## cyber/rank/v1beta1/tx.proto ### MsgUpdateParams | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `authority` | [string](#string) | | | | `params` | [Params](#cyber.rank.v1beta1.Params) | | | ### MsgUpdateParamsResponse ### Msg | Method Name | Request Type | Response Type | Description | HTTP Verb | Endpoint | | ----------- | ------------ | ------------- | ------------| ------- | -------- | | `UpdateParams` | [MsgUpdateParams](#cyber.rank.v1beta1.MsgUpdateParams) | [MsgUpdateParamsResponse](#cyber.rank.v1beta1.MsgUpdateParamsResponse) | | |

Top

## cyber/resources/v1beta1/types.proto ### Params | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `max_slots` | [uint32](#uint32) | | | | `halving_period_volt_blocks` | [uint32](#uint32) | | | | `halving_period_ampere_blocks` | [uint32](#uint32) | | | | `base_investmint_period_volt` | [uint32](#uint32) | | | | `base_investmint_period_ampere` | [uint32](#uint32) | | | | `min_investmint_period` | [uint32](#uint32) | | | | `base_investmint_amount_volt` | [cosmos.base.v1beta1.Coin](#cosmos.base.v1beta1.Coin) | | | | `base_investmint_amount_ampere` | [cosmos.base.v1beta1.Coin](#cosmos.base.v1beta1.Coin) | | |

Top

## cyber/resources/v1beta1/genesis.proto ### GenesisState | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `params` | [Params](#cyber.resources.v1beta1.Params) | | |

Top

## cyber/resources/v1beta1/query.proto ### QueryAdjustedPriceRequest | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `base` | [cosmos.base.v1beta1.Coin](#cosmos.base.v1beta1.Coin) | | | | `resource` | [string](#string) | | | ### QueryAdjustedPriceResponse | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `adjusted` | [cosmos.base.v1beta1.Coin](#cosmos.base.v1beta1.Coin) | | | ### QueryInvestmintRequest | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `amount` | [cosmos.base.v1beta1.Coin](#cosmos.base.v1beta1.Coin) | | | | `resource` | [string](#string) | | | | `length` | [uint64](#uint64) | | | ### QueryInvestmintResponse | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `amount` | [cosmos.base.v1beta1.Coin](#cosmos.base.v1beta1.Coin) | | | ### QueryParamsRequest ### QueryParamsResponse | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `params` | [Params](#cyber.resources.v1beta1.Params) | | | ### Query | Method Name | Request Type | Response Type | Description | HTTP Verb | Endpoint | | ----------- | ------------ | ------------- | ------------| ------- | -------- | | `Params` | [QueryParamsRequest](#cyber.resources.v1beta1.QueryParamsRequest) | [QueryParamsResponse](#cyber.resources.v1beta1.QueryParamsResponse) | | GET|/cyber/resources/v1beta1/resources/params| | `Investmint` | [QueryInvestmintRequest](#cyber.resources.v1beta1.QueryInvestmintRequest) | [QueryInvestmintResponse](#cyber.resources.v1beta1.QueryInvestmintResponse) | | GET|/cyber/resources/v1beta1/resources/investmint| | `AdjustedPrice` | [QueryAdjustedPriceRequest](#cyber.resources.v1beta1.QueryAdjustedPriceRequest) | [QueryAdjustedPriceResponse](#cyber.resources.v1beta1.QueryAdjustedPriceResponse) | | GET|/cyber/resources/v1beta1/resources/adjusted_price|

Top

## cyber/resources/v1beta1/tx.proto ### MsgInvestmint | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `neuron` | [string](#string) | | | | `amount` | [cosmos.base.v1beta1.Coin](#cosmos.base.v1beta1.Coin) | | | | `resource` | [string](#string) | | | | `length` | [uint64](#uint64) | | | ### MsgInvestmintResponse ### MsgUpdateParams | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `authority` | [string](#string) | | | | `params` | [Params](#cyber.resources.v1beta1.Params) | | | ### MsgUpdateParamsResponse ### Msg | Method Name | Request Type | Response Type | Description | HTTP Verb | Endpoint | | ----------- | ------------ | ------------- | ------------| ------- | -------- | | `Investmint` | [MsgInvestmint](#cyber.resources.v1beta1.MsgInvestmint) | [MsgInvestmintResponse](#cyber.resources.v1beta1.MsgInvestmintResponse) | | | | `UpdateParams` | [MsgUpdateParams](#cyber.resources.v1beta1.MsgUpdateParams) | [MsgUpdateParamsResponse](#cyber.resources.v1beta1.MsgUpdateParamsResponse) | | |

Top

## osmosis/tokenfactory/v1beta1/authority_metadata.proto ### DenomAuthorityMetadata DenomAuthorityMetadata specifies metadata for addresses that have specific capabilities over a token factory denom. Right now there is only one Admin permission, but is planned to be extended to the future. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `admin` | [string](#string) | | Can be empty for no admin, or a valid osmosis address |

Top

## osmosis/tokenfactory/v1beta1/params.proto ### Params Params defines the parameters for the tokenfactory module. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `denom_creation_fee` | [cosmos.base.v1beta1.Coin](#cosmos.base.v1beta1.Coin) | repeated | | | `denom_creation_gas_consume` | [uint64](#uint64) | | if denom_creation_fee is an empty array, then this field is used to add more gas consumption to the base cost. https://github.com/CosmWasm/token-factory/issues/11 |

Top

## osmosis/tokenfactory/v1beta1/genesis.proto ### GenesisDenom GenesisDenom defines a tokenfactory denom that is defined within genesis state. The structure contains DenomAuthorityMetadata which defines the denom's admin. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `denom` | [string](#string) | | | | `authority_metadata` | [DenomAuthorityMetadata](#osmosis.tokenfactory.v1beta1.DenomAuthorityMetadata) | | | ### GenesisState GenesisState defines the tokenfactory module's genesis state. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `params` | [Params](#osmosis.tokenfactory.v1beta1.Params) | | params defines the parameters of the module. | | `factory_denoms` | [GenesisDenom](#osmosis.tokenfactory.v1beta1.GenesisDenom) | repeated | |

Top

## osmosis/tokenfactory/v1beta1/query.proto ### QueryDenomAuthorityMetadataRequest QueryDenomAuthorityMetadataRequest defines the request structure for the DenomAuthorityMetadata gRPC query. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `denom` | [string](#string) | | | ### QueryDenomAuthorityMetadataResponse QueryDenomAuthorityMetadataResponse defines the response structure for the DenomAuthorityMetadata gRPC query. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `authority_metadata` | [DenomAuthorityMetadata](#osmosis.tokenfactory.v1beta1.DenomAuthorityMetadata) | | | ### QueryDenomsFromCreatorRequest QueryDenomsFromCreatorRequest defines the request structure for the DenomsFromCreator gRPC query. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `creator` | [string](#string) | | | ### QueryDenomsFromCreatorResponse QueryDenomsFromCreatorRequest defines the response structure for the DenomsFromCreator gRPC query. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `denoms` | [string](#string) | repeated | | ### QueryParamsRequest QueryParamsRequest is the request type for the Query/Params RPC method. ### QueryParamsResponse QueryParamsResponse is the response type for the Query/Params RPC method. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `params` | [Params](#osmosis.tokenfactory.v1beta1.Params) | | params defines the parameters of the module. | ### Query Query defines the gRPC querier service. | Method Name | Request Type | Response Type | Description | HTTP Verb | Endpoint | | ----------- | ------------ | ------------- | ------------| ------- | -------- | | `Params` | [QueryParamsRequest](#osmosis.tokenfactory.v1beta1.QueryParamsRequest) | [QueryParamsResponse](#osmosis.tokenfactory.v1beta1.QueryParamsResponse) | Params defines a gRPC query method that returns the tokenfactory module's parameters. | GET|/osmosis/tokenfactory/v1beta1/params| | `DenomAuthorityMetadata` | [QueryDenomAuthorityMetadataRequest](#osmosis.tokenfactory.v1beta1.QueryDenomAuthorityMetadataRequest) | [QueryDenomAuthorityMetadataResponse](#osmosis.tokenfactory.v1beta1.QueryDenomAuthorityMetadataResponse) | DenomAuthorityMetadata defines a gRPC query method for fetching DenomAuthorityMetadata for a particular denom. | GET|/osmosis/tokenfactory/v1beta1/denoms/{denom}/authority_metadata| | `DenomsFromCreator` | [QueryDenomsFromCreatorRequest](#osmosis.tokenfactory.v1beta1.QueryDenomsFromCreatorRequest) | [QueryDenomsFromCreatorResponse](#osmosis.tokenfactory.v1beta1.QueryDenomsFromCreatorResponse) | DenomsFromCreator defines a gRPC query method for fetching all denominations created by a specific admin/creator. | GET|/osmosis/tokenfactory/v1beta1/denoms_from_creator/{creator}|

Top

## osmosis/tokenfactory/v1beta1/tx.proto ### MsgBurn MsgBurn is the sdk.Msg type for allowing an admin account to burn a token. For now, we only support burning from the sender account. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `sender` | [string](#string) | | | | `amount` | [cosmos.base.v1beta1.Coin](#cosmos.base.v1beta1.Coin) | | | | `burnFromAddress` | [string](#string) | | | ### MsgBurnResponse ### MsgChangeAdmin MsgChangeAdmin is the sdk.Msg type for allowing an admin account to reassign adminship of a denom to a new account | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `sender` | [string](#string) | | | | `denom` | [string](#string) | | | | `new_admin` | [string](#string) | | | ### MsgChangeAdminResponse MsgChangeAdminResponse defines the response structure for an executed MsgChangeAdmin message. ### MsgCreateDenom MsgCreateDenom defines the message structure for the CreateDenom gRPC service method. It allows an account to create a new denom. It requires a sender address and a sub denomination. The (sender_address, sub_denomination) tuple must be unique and cannot be re-used. The resulting denom created is defined as . The resulting denom's admin is originally set to be the creator, but this can be changed later. The token denom does not indicate the current admin. | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `sender` | [string](#string) | | | | `subdenom` | [string](#string) | | subdenom can be up to 44 "alphanumeric" characters long. | ### MsgCreateDenomResponse MsgCreateDenomResponse is the return value of MsgCreateDenom It returns the full string of the newly created denom | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `new_token_denom` | [string](#string) | | | ### MsgForceTransfer | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `sender` | [string](#string) | | | | `amount` | [cosmos.base.v1beta1.Coin](#cosmos.base.v1beta1.Coin) | | | | `transferFromAddress` | [string](#string) | | | | `transferToAddress` | [string](#string) | | | ### MsgForceTransferResponse ### MsgMint MsgMint is the sdk.Msg type for allowing an admin account to mint more of a token. For now, we only support minting to the sender account | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `sender` | [string](#string) | | | | `amount` | [cosmos.base.v1beta1.Coin](#cosmos.base.v1beta1.Coin) | | | | `mintToAddress` | [string](#string) | | | ### MsgMintResponse ### MsgSetDenomMetadata MsgSetDenomMetadata is the sdk.Msg type for allowing an admin account to set the denom's bank metadata | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `sender` | [string](#string) | | | | `metadata` | [cosmos.bank.v1beta1.Metadata](#cosmos.bank.v1beta1.Metadata) | | | ### MsgSetDenomMetadataResponse MsgSetDenomMetadataResponse defines the response structure for an executed MsgSetDenomMetadata message. ### MsgUpdateParams MsgUpdateParams is the Msg/UpdateParams request type. Since: cosmos-sdk 0.47 | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | | `authority` | [string](#string) | | authority is the address of the governance account. | | `params` | [Params](#osmosis.tokenfactory.v1beta1.Params) | | params defines the x/mint parameters to update. NOTE: All parameters must be supplied. | ### MsgUpdateParamsResponse MsgUpdateParamsResponse defines the response structure for executing a MsgUpdateParams message. Since: cosmos-sdk 0.47 ### Msg Msg defines the tokefactory module's gRPC message service. | Method Name | Request Type | Response Type | Description | HTTP Verb | Endpoint | | ----------- | ------------ | ------------- | ------------| ------- | -------- | | `CreateDenom` | [MsgCreateDenom](#osmosis.tokenfactory.v1beta1.MsgCreateDenom) | [MsgCreateDenomResponse](#osmosis.tokenfactory.v1beta1.MsgCreateDenomResponse) | | | | `Mint` | [MsgMint](#osmosis.tokenfactory.v1beta1.MsgMint) | [MsgMintResponse](#osmosis.tokenfactory.v1beta1.MsgMintResponse) | | | | `Burn` | [MsgBurn](#osmosis.tokenfactory.v1beta1.MsgBurn) | [MsgBurnResponse](#osmosis.tokenfactory.v1beta1.MsgBurnResponse) | | | | `ChangeAdmin` | [MsgChangeAdmin](#osmosis.tokenfactory.v1beta1.MsgChangeAdmin) | [MsgChangeAdminResponse](#osmosis.tokenfactory.v1beta1.MsgChangeAdminResponse) | | | | `SetDenomMetadata` | [MsgSetDenomMetadata](#osmosis.tokenfactory.v1beta1.MsgSetDenomMetadata) | [MsgSetDenomMetadataResponse](#osmosis.tokenfactory.v1beta1.MsgSetDenomMetadataResponse) | | | | `ForceTransfer` | [MsgForceTransfer](#osmosis.tokenfactory.v1beta1.MsgForceTransfer) | [MsgForceTransferResponse](#osmosis.tokenfactory.v1beta1.MsgForceTransferResponse) | | | | `UpdateParams` | [MsgUpdateParams](#osmosis.tokenfactory.v1beta1.MsgUpdateParams) | [MsgUpdateParamsResponse](#osmosis.tokenfactory.v1beta1.MsgUpdateParamsResponse) | UpdateParams defines a governance operation for updating the x/mint module parameters. The authority is hard-coded to the x/gov module account. Since: cosmos-sdk 0.47 | | ## Scalar Value Types | .proto Type | Notes | C++ | Java | Python | Go | C# | PHP | Ruby | | ----------- | ----- | --- | ---- | ------ | -- | -- | --- | ---- | | double | | double | double | float | float64 | double | float | Float | | float | | float | float | float | float32 | float | float | Float | | int32 | Uses variable-length encoding. Inefficient for encoding negative numbers – if your field is likely to have negative values, use sint32 instead. | int32 | int | int | int32 | int | integer | Bignum or Fixnum (as required) | | int64 | Uses variable-length encoding. Inefficient for encoding negative numbers – if your field is likely to have negative values, use sint64 instead. | int64 | long | int/long | int64 | long | integer/string | Bignum | | uint32 | Uses variable-length encoding. | uint32 | int | int/long | uint32 | uint | integer | Bignum or Fixnum (as required) | | uint64 | Uses variable-length encoding. | uint64 | long | int/long | uint64 | ulong | integer/string | Bignum or Fixnum (as required) | | sint32 | Uses variable-length encoding. Signed int value. These more efficiently encode negative numbers than regular int32s. | int32 | int | int | int32 | int | integer | Bignum or Fixnum (as required) | | sint64 | Uses variable-length encoding. Signed int value. These more efficiently encode negative numbers than regular int64s. | int64 | long | int/long | int64 | long | integer/string | Bignum | | fixed32 | Always four bytes. More efficient than uint32 if values are often greater than 2^28. | uint32 | int | int | uint32 | uint | integer | Bignum or Fixnum (as required) | | fixed64 | Always eight bytes. More efficient than uint64 if values are often greater than 2^56. | uint64 | long | int/long | uint64 | ulong | integer/string | Bignum | | sfixed32 | Always four bytes. | int32 | int | int | int32 | int | integer | Bignum or Fixnum (as required) | | sfixed64 | Always eight bytes. | int64 | long | int/long | int64 | long | integer/string | Bignum | | bool | | bool | boolean | boolean | bool | bool | boolean | TrueClass/FalseClass | | string | A string must always contain UTF-8 encoded or 7-bit ASCII text. | string | String | str/unicode | string | string | string | String (UTF-8) | | bytes | May contain any arbitrary sequence of bytes. | string | ByteString | str | []byte | ByteString | string | String (ASCII-8BIT) | ================================================ FILE: docs/proto/protodoc-markdown.tmpl ================================================ # Protobuf Documentation ## Table of Contents {{range .Files}} {{$file_name := .Name}}- [{{.Name}}](#{{.Name}}) {{- if .Messages }} {{range .Messages}} - [{{.LongName}}](#{{.FullName}}) {{end}} {{- end -}} {{- if .Enums }} {{range .Enums}} - [{{.LongName}}](#{{.FullName}}) {{end}} {{- end -}} {{- if .Extensions }} {{range .Extensions}} - [File-level Extensions](#{{$file_name}}-extensions) {{end}} {{- end -}} {{- if .Services }} {{range .Services}} - [{{.Name}}](#{{.FullName}}) {{end}} {{- end -}} {{end}} - [Scalar Value Types](#scalar-value-types) {{range .Files}} {{$file_name := .Name}}

Top

## {{.Name}} {{.Description}} {{range .Messages}} ### {{.LongName}} {{.Description}} {{if .HasFields}} | Field | Type | Label | Description | | ----- | ---- | ----- | ----------- | {{range .Fields -}} | `{{.Name}}` | [{{.LongType}}](#{{.FullType}}) | {{.Label}} | {{if (index .Options "deprecated"|default false)}}**Deprecated.** {{end}}{{nobr .Description}}{{if .DefaultValue}} Default: {{.DefaultValue}}{{end}} | {{end}} {{end}} {{if .HasExtensions}} | Extension | Type | Base | Number | Description | | --------- | ---- | ---- | ------ | ----------- | {{range .Extensions -}} | `{{.Name}}` | {{.LongType}} | {{.ContainingLongType}} | {{.Number}} | {{nobr .Description}}{{if .DefaultValue}} Default: {{.DefaultValue}}{{end}} | {{end}} {{end}} {{end}} {{range .Enums}} ### {{.LongName}} {{.Description}} | Name | Number | Description | | ---- | ------ | ----------- | {{range .Values -}} | {{.Name}} | {{.Number}} | {{nobr .Description}} | {{end}} {{end}} {{if .HasExtensions}} ### File-level Extensions | Extension | Type | Base | Number | Description | | --------- | ---- | ---- | ------ | ----------- | {{range .Extensions -}} | `{{.Name}}` | {{.LongType}} | {{.ContainingLongType}} | {{.Number}} | {{nobr .Description}}{{if .DefaultValue}} Default: `{{.DefaultValue}}`{{end}} | {{end}} {{end}} {{range .Services}} ### {{.Name}} {{.Description}} | Method Name | Request Type | Response Type | Description | HTTP Verb | Endpoint | | ----------- | ------------ | ------------- | ------------| ------- | -------- | {{range .Methods -}} | `{{.Name}}` | [{{.RequestLongType}}](#{{.RequestFullType}}){{if .RequestStreaming}} stream{{end}} | [{{.ResponseLongType}}](#{{.ResponseFullType}}){{if .ResponseStreaming}} stream{{end}} | {{nobr .Description}} | {{with (index .Options "google.api.http")}}{{range .Rules}}{{.Method}}|{{.Pattern}}{{end}}{{end}}| {{end}} {{end}} {{end}} ## Scalar Value Types | .proto Type | Notes | C++ | Java | Python | Go | C# | PHP | Ruby | | ----------- | ----- | --- | ---- | ------ | -- | -- | --- | ---- | {{range .Scalars -}} | {{.ProtoType}} | {{.Notes}} | {{.CppType}} | {{.JavaType}} | {{.PythonType}} | {{.GoType}} | {{.CSharp}} | {{.PhpType}} | {{.RubyType}} | {{end}} ================================================ FILE: docs/rpc.md ================================================ # API reference ** TODO upgrade for bostrom network ** Cyberd provides a [JSON-RPC](http://json-rpc.org/wiki/specification) type API. The HTTP endpoint is served under `localhost:20657`. WebSockets are the preferred transport for cyberd RPC and are used by applications, such as cyb. The default WebSocket connection endpoint for cyberd is `ws://localhost:26657/websocket`. There are test endpoints available at `https://titan.cybernode.ai/api/` and `ws://titan.cybernode.ai/websocket`.
## Standard Methods ### Query Example Query the HTTP endpoint using curl: ```bash curl --data '{"method":"status","params":[],"id":"1","jsonrpc":"2.0"}' \ -H "Content-Type: application/json" -X POST earth.cybernode.ai:34657 ``` Query ws endpoint from JS: ```js let websocket = new WebSocket("ws://earth.cybernode.ai:34657/websocket"); websocket.send(JSON.stringify({ "method":"status", "params":[], "id":"1", "jsonrpc":"2.0" })); ``` ### Method Overview The following is an overview of the RPC methods and their current status. Click the method name for further detail, such as parameter, and this will return information. |#|Method|Description| |---|------|-----------| |1|[status](#status)|Get node info, pubkey, latest block hash, app hash, block height and time.| |2|[account](#account)|Get account nonce, pubkey, number, and coins.| |3|[account_bandwidth](#account-bandwidth)|Get account bandwidth info for current height.| |4|[is_link_exist](#link-exist)|Return true, if given link exist.| |5|[current_bandwidth_price](#current-bandwidth-price)|Returns current bandwidth credit price.| |6|[index_stats](#index-stats)|Returns current index entities count.| ### Method Details ***
| | | |---|---| |Method|status| |Parameters|None| |Description|Get node info, pubkey, latest block hash, app hash, block height and time.| |[Return to Overview](#method-overview)
| | | |---|---| |Method|account| |Parameters|1. address (string, required)
| |Description|Get account nonce, pubkey, number, and coins.| |[Return to Overview](#method-overview)
| | | |---|---| |Method|account_bandwidth| |Parameters|1. address (string, required)
| |Description|Get account bandwidth info for current height.| |[Return to Overview](#method-overview)
| | | |---|---| |Method|is_link_exist| |Parameters|1. from (cid, required)
2. to (cid, required)
3. address (string, required)
| |Description|Return true, if given link exist.| |[Return to Overview](#method-overview)
| | | |---|---| |Method|current_bandwidth_price| |Parameters|None| |Description|Returns current bandwidth credit price.| |[Return to Overview](#method-overview)
| | | |---|---| |Method|index_stats| |Parameters|None| |Description|Returns current index entities count.| |[Return to Overview](#method-overview)
***

## Notifications (WebSocket-specific) Cyberd uses standard JSON-RPC notifications to notify clients of changes rather than requiring clients to poll cyberd for updates. JSON-RPC notifications are a subset of requests, but do not contain an ID. The notification type is categorized by the `query` params field. ### Subscribe Example Subscribe for new block headers from JS: ```js let websocket = new WebSocket("ws://earth.cybernode.ai:34657/websocket"); websocket.send(JSON.stringify({ "method": "subscribe", "params": ["tm.event='NewBlockHeader'"], "id": "1", "jsonrpc": "2.0" })); ``` ### Events Overview |#|Event|Description| |---|------|-----------| |1|[NewBlockHeader](#NewBlockHeader)|Sends a block header notification when a new block is committed.| |2|[CoinsReceived](#CoinsReceived)|Sends a notification when new coinc arrive to a given address.| |3|[CoinsSend](#CoinsSend)|Sends a notification when new coins are sent from a given address.| |4|[СidsLinked](#СidsLinked)|Notification of links created by a given address.| |5|[SignedTxCommitted](#SignedTxCommitted)|Notify when any tx for a given signer is committed.| ### Events Details #### NewBlockHeader | | | |---|---| |Event|NewBlockHeader| |Description|Sends block header notification when a new block is committed.| |Query|`tm.event='NewBlockHeader'`| |[Return to Overview](#events-overview)
#### CoinsReceived | | | |---|---| |Event|CoinsReceived| |Description|Sends a notification when new coins have arrived to a given address.| |Query|`tm.event='EventTx' AND recipient='cbd1sk3uvpacpjm2t3389caqk4gd9n9gkzq2054yds'`| |[Return to Overview](#events-overview)
#### CoinsSend | | | |---|---| |Event|CoinsSend| |Description|Sends a notification when new coins are sent from a given address.| |Query|`tm.event='EventTx' AND sender='cbd1sk3uvpacpjm2t3389caqk4gd9n9gkzq2054yds'`| |[Return to Overview](#events-overview)
#### СidsLinked | | | |---|---| |Event|СidsLinked| |Description|Notification of links created by a given address.| |Query|`tm.event='EventTx' AND signer='cbd1sk3uvpacpjm2t3389caqk4gd9n9gkzq2054yds' AND action='link'`| |[Return to Overview](#events-overview)
#### SignedTxCommitted | | | |---|---| |Event|SignedTxCommitted| |Description|Notify when any tx for a given signer is committed.| |Query|`tm.event='EventTx' AND signer='cbd1sk3uvpacpjm2t3389caqk4gd9n9gkzq2054yds'`| |[Return to Overview](#events-overview)
================================================ FILE: docs/run_validator.md ================================================ # Join cyber as a Validator ## Prepare your server First, you should set up a server. Your node should be online constantly. This means that you will need a reliable server. You may also consider using any cloud service with a dedicated GPU, like Hetzner, Cherryservers etc. (or use a local machine). Whatever you choose, in order to achieve better stability and consistency we recommend you use a dedicated server for each validator node. Cyber is based on Cosmos-SDK and is written in Go. It should work on any platform which can compile and run programs in Go. We strongly recommend running the validator node on a Linux-based server. Cyber-rank computations are performed on GPU, so it is required to have it (GPU) on-board your node. Recommended hardware setup: ```js CPU: 6 cores RAM: 32 GB SSD: 1 TB Connection: 50+Mbps, Stable and low-latency connection GPU: Nvidia GeForce (or Tesla/Titan/Quadro) with CUDA-cores; 4+ Gb of video memory* Software: Ubuntu 20.04 LTS / 22.04 LTS ``` *Cyber runs well on consumer-grade cards like Geforce GTX 1070, but we expect load growth and advise you use Error Correction compatible cards from Tesla or Quadro families. Also, make sure your card is compatible with >= v.410 of NVIDIA driver.* Of course the hardware is your own choice and technically it might be possible to run the node on *"even - 1 CUDA core GPU"*, but you should be aware of performance drop and rank calculation speed decline. ## Node setup *To avoid possible misconfiguration issues and simplify the setup of `$ENV`, we recommend to perform all the commands as `root` (here root - is literally root, not just a user with root priveliges). For the case of a dedicated server for cybernode it should be concidered as ok from the security side.* ### Third-party software The main distribution unit for Cyber is a [docker](https://www.docker.com/) container. All images are located in the default [Dockerhub registry](https://hub.docker.com/r/cyberd/cyber). In order to access the GPU from the container, Nvidia driver version **410+** and [Nvidia docker runtime](https://github.com/NVIDIA/nvidia-docker) should be installed on the host system. All commands below suppose `amd64` architecture, as the different architectures commands may differ accordingly. ### Docker installation Simply copy the commands below and paste into CLI. 1. Update the `apt` package index: ```bash sudo apt-get update ``` 2. Install packages to allow apt to use a repository over HTTPS: ```bash sudo apt install -y \ apt-transport-https \ ca-certificates \ curl \ gnupg-agent \ software-properties-common ``` 3. Add Docker’s official GPG key: ```bash curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add - ``` ```bash sudo add-apt-repository \ "deb [arch=amd64] https://download.docker.com/linux/ubuntu \ $(lsb_release -cs) \ stable" ``` 4. Update the apt package index: ```bash sudo apt update ``` 5. Install the latest version of Docker CE and containerd: ```bash sudo apt-get install docker-ce docker-ce-cli containerd.io ``` ### Installing Nvidia drivers 1. To proceed, first add the `ppa:graphics-drivers/ppa` repository: ```bash sudo add-apt-repository ppa:graphics-drivers/ppa ``` ```bash sudo apt update ``` 2. Install Ubuntu-drivers: ```bash sudo apt install -y ubuntu-drivers-common ``` 3. Next check what are recommended drivers for your card: ```bash ubuntu-drivers devices ``` You should see something similar to this: ```bash == /sys/devices/pci0000:00/0000:00:01.0/0000:01:00.0 == modalias : pci:v000010DEd00001BA1sv00001462sd000011E4bc03sc00i00 vendor : NVIDIA Corporation model : GP104M [GeForce GTX 1070 Mobile] driver : nvidia-driver-418 - third-party free driver : nvidia-driver-430 - third-party free driver : nvidia-driver-440 - third-party free driver : nvidia-driver-460 - third-party free recommended driver : xserver-xorg-video-nouveau - distro free builtin ``` 4. We need the **410+** drivers release, *up to v515 is tested*. As you can see the v460 is recommended. The command below will install the recommended version of the drivers: ```bash sudo ubuntu-drivers autoinstall ``` To install specific version of a driver use `sudo apt install nvidia-driver-460` The driver installation takes approximately 10 minutes. ```bash DKMS: install completed. Setting up libxdamage1:i386 (1:1.1.4-3) ... Setting up libxext6:i386 (2:1.3.3-1) ... Setting up libxfixes3:i386 (1:5.0.3-1) ... Setting up libnvidia-decode-415:i386 (460.84-0ubuntu0~gpu18.04.1) ... Setting up build-essential (12.4ubuntu1) ... Setting up libnvidia-gl-415:i386 (460.84-0ubuntu0~gpu18.04.1) ... Setting up libnvidia-encode-415:i386 (460.84-0ubuntu0~gpu18.04.1) ... Setting up nvidia-driver-415 (460.84-0ubuntu0~gpu18.04.1) ... Setting up libxxf86vm1:i386 (1:1.1.4-1) ... Setting up libglx-mesa0:i386 (18.0.5-0ubuntu0~18.04.1) ... Setting up libglx0:i386 (1.0.0-2ubuntu2.2) ... Setting up libgl1:i386 (1.0.0-2ubuntu2.2) ... Setting up libnvidia-ifr1-415:i386 (460.84-0ubuntu0~gpu18.04.1) ... Setting up libnvidia-fbc1-415:i386 (460.84-0ubuntu0~gpu18.04.1) ... Processing triggers for libc-bin (2.27-3ubuntu1) ... Processing triggers for initramfs-tools (0.130ubuntu3.1) ... update-initramfs: Generating /boot/initrd.img-4.15.0-45-generic ``` 5. **Reboot** the system for the changes to take effect. ```bash sudo reboot ``` 6. Check the installed drivers: ```bash nvidia-smi ``` You should see this: (Some version/driver numbers might differ. You might also have some processes already running) ```bash +-----------------------------------------------------------------------------+ | NVIDIA-SMI 460.84 Driver Version: 460.84 CUDA Version: 11.2 | |-------------------------------+----------------------+----------------------+ | GPU Name Persistence-M| Bus-Id Disp.A | Volatile Uncorr. ECC | | Fan Temp Perf Pwr:Usage/Cap| Memory-Usage | GPU-Util Compute M. | |===============================+======================+======================| | 0 GeForce GTX 1070 Off | 00000000:01:00.0 Off | N/A | | 26% 36C P5 26W / 180W | 0MiB / 8119MiB | 2% Default | +-------------------------------+----------------------+----------------------+ +-----------------------------------------------------------------------------+ | Processes: GPU Memory | | GPU PID Type Process name Usage | |=============================================================================| | No running processes found | +-----------------------------------------------------------------------------+ ``` #### Install Nvidia container runtime for docker 1. Add package repositories: ```bash distribution=$(. /etc/os-release;echo $ID$VERSION_ID) ``` ```bash curl -s -L https://nvidia.github.io/nvidia-docker/gpgkey | sudo apt-key add - ``` ```bash curl -s -L https://nvidia.github.io/nvidia-docker/$distribution/nvidia-docker.list | sudo tee /etc/apt/sources.list.d/nvidia-docker.list ``` You should see something like this: ```bash deb https://nvidia.github.io/libnvidia-container/ubuntu20.04/$(ARCH) / deb https://nvidia.github.io/nvidia-container-runtime/ubuntu20.04/$(ARCH) / deb https://nvidia.github.io/nvidia-docker/ubuntu20.04/$(ARCH) / ``` 2. Install nvidia-container toolkit and reload the Docker daemon configuration ```bash sudo apt-get update && sudo apt-get install -y nvidia-container-toolkit ``` ```bash sudo systemctl restart docker ``` 3. Test nvidia-smi with the latest official CUDA image ```bash docker run --gpus all nvidia/cuda:11.4.0-base nvidia-smi ``` Output logs should coincide as earlier: ```bash Unable to find image 'nvidia/cuda:11.4.0-base' locally 11.1-base: Pulling from nvidia/cuda 54ee1f796a1e: Pull complete f7bfea53ad12: Pull complete 46d371e02073: Pull complete b66c17bbf772: Pull complete 3642f1a6dfb3: Pull complete e5ce55b8b4b9: Pull complete 155bc0332b0a: Pull complete Digest: sha256:774ca3d612de15213102c2dbbba55df44dc5cf9870ca2be6c6e9c627fa63d67a Status: Downloaded newer image for nvidia/cuda:11.2.0-base-ubuntu20.04 Mon Jun 21 14:07:52 2021 +------------------------------------------------------------------------+ |NVIDIA-SMI 460.84 Driver Version:460.84 CUDA Version: 11.4 | |-----------------------------+--------------------+---------------------+ |GPU Name Persistence-M| Bus-Id Disp.A| Volatile Uncorr. ECC| |Fan Temp Perf Pwr:Usage/Cap| Memory-Usage| GPU-Util Compute M.| | | | MIG M.| |=============================+====================+=====================| | 0 GeForce GTX165... Off |00000000:01:00.0 Off| N/A| |N/A 47C P0 16W / N/A | 0MB / 3914MiB| 0% Default| | | | N/A| +-----------------------------+--------------------+---------------------+ +------------------------------------------------------------------------+ |Processes: | | GPU GI CI PID Type Process name GPU Memory| | ID ID Usage | |========================================================================| | No running processes found | +------------------------------------------------------------------------+ ``` Your machine is ready to launch the node. ### Launching cyber fullnode Make a directory tree for storing your daemon: ```bash mkdir $HOME/.cyber mkdir $HOME/.cyber/data mkdir $HOME/.cyber/config ``` 2. Run the full node: (This will pull and extract the image from cyberd/cyber of latest version, containing all upgrades binaries) ```bash docker run -d --gpus all --name=bostrom --restart always -p 26656:26656 -p 26657:26657 -p 1317:1317 -e ALLOW_SEARCH=true -v $HOME/.cyber:/root/.cyber cyberd/bostrom:v3.0.0-cuda11.4 ``` Docker image already contain all binaries to either sync from 0 or start form snapshot. 3. Setup some peers to `persistent_peers` and `seeds` to $HOME/.cyber/config/config.toml line 184: ```bash # Comma separated list of seed nodes to connect to seeds = "" # Comma separated list of nodes to keep persistent connections to persistent_peers = "" ``` For peers addresses please refer to appropriate section of the [networks](https://github.com/cybercongress/networks) repo. 4. To speed-up sync use chain snapshot (check for most recent pinned snap in [Hall of Fame](https://t.me/fameofcyber)). Download the snapshot, unpack it and replace your node `.cyber/data` and `.cyber/wasm` folders to one's from snapshot. ```bash wget https://link_to_actual_snapshot:bostrom_pruned_4302990.tar.gz tar -I pigz -xf bostrom_pruned_4302990.tar.gz -C $HOME/.cyber rm -rf $HOME/.cyber/data $HOME/.cyber/wasm cp bostrom_pruned_4302990/* $HOME/.cyber ``` Also adjust your config `.cyber/config/app.toml` pruning stratege to be similar with snapshot you've selected (`pruning = "everything"` for pruned snapshot, `pruning = "nothing"` for archive) ```bash nano $HOME/.cyber/config/app.toml set line 17 `pruning = "everything"` ``` If you would like to sync all the way from the bottom - you may just fill the peers and let thing spin, upgrade block would be handled automatically. 5. To apply config changes restart the container: ```bash docker restart bostrom ``` 6. Then check the status of your node: ```bash docker exec bostrom cyber status ``` A possible output may look like this: ```bash {"NodeInfo":{"protocol_version":{"p2p":"8","block":"11","app":"0"},"id":"808a3773d8adabc78bca6ef8d6b2ee20456bfbcb","listen_addr":"tcp://86.57.207.105:26656","network":"bostrom","version":"","channels":"40202122233038606100","moniker":"node1234","other": {"tx_index":"on","rpc_address":"tcp://0.0.0.0:26657"}},"SyncInfo":{"latest_block_hash":"241BA3E744A9024A2D04BDF4CE7CF4985D7922054B38AF258712027D0854E930","latest_app_hash":"5BF4B64508A95984F017BD6C29012FE5E66ADCB367D06345EE1EB2ED18314437","latest_block_height":"521", "latest_block_time":"2021-06-21T14:21:41.817756021Z","earliest_block_hash":"98DD3065543108F5EBEBC45FAAAEA868B3C84426572BE9FDA2E3F1C49A2C0CE8","earliest_app_hash":"E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855","earliest_block_height":"1", "earliest_block_time":"2021-06-10T00:00:00Z","catching_up":false},"ValidatorInfo":{"Address":"611C9F3568E7341155DBF0546795BF673FD84EB1","PubKey":{"type":"tendermint/PubKeyEd25519","value":"0iGriT3gyRJXQXR/98c+2MTAhChIo5F5v7FfPmOAH5o="},"VotingPower":"0"}} ``` To check container logs use: ```bash docker logs bostrom -f --tail 10 ``` ## Validator start After your node has successfully synced, you can run a validator. ### Prepare the staking address 1. To proceed further you need to add your existing address to the node or generate one and fund it. To **create** a new one use: ```bash docker exec -ti bostrom cyber keys add ``` The above command returns the address, the public key and the seed phrase, which you can use to recover your account if you forget your password later. **Keep you seed phrase safe. Your keys are only your responsibility!** To **import** existing address use: ```bash docker exec -ti bostrom cyber keys add --recover ``` You can use your **ledger** device with the Cosmos app installed on it to sign transactions. Add address from Ledger: ```bash docker exec -ti bostrom cyber keys add --ledger ``` **** is any name you pick to represent this key pair. You have to refer to that name later when you use cli to sign transactions. ### Send the create validator transaction Validators are actors on the network committing new blocks by submitting their votes. This refers to the node itself, not a single person or a single account. The next step is to declare a validator candidate. To declare a validator candidate, run the following command adjusting the stake amount and the other fields: ```bash docker exec -ti bostrom cyber tx staking create-validator \ --amount=10000000boot \ --min-self-delegation "1000000" \ --pubkey=$(docker exec -ti bostrom cyber tendermint show-validator) \ --moniker= \ --from= \ --commission-rate="0.10" \ --commission-max-rate="0.20" \ --commission-max-change-rate="0.01" \ --chain-id=bostrom \ --gas-prices=0.01boot \ --gas=600000 ``` ### Verify that you are validating ```bash docker exec -ti bostrom cyber query staking validators ``` If you see your `` with the status `Bonded` and Jailed `false` everything is good. You are validating the network. ## Maintenance of the validator ### Jailing If your validator got under slashing conditions, it will be jailed. After such an event an operator must unjail the validator manually: ```bash docker exec -ti bostrom cyber tx slashing unjail --from= --chain-id=bostrom --gas-prices=0.01boot --gas=300000 ``` ### Back-up validator keys (!) Your identity as a validator consists of two things: - your account (to sign transactions) - your validator private key (to sign stuff on the chain consensus layer) Please back up `$HOME/.cyber/config/priv_validator_key.json` along with your seed phrase. In case of occasional node loss you would be able to restore your validator operation with this file and another full node. Finally, in case you want to keep your cyber node ID consistent during networks please backup `$HOME/.cyber/config/node_key.json`. ### Rebase to snapshot You can use a snapshot to start a node from scratch, as well as to reduce its disk space. Please check the latest snapshot [here](https://snapshot.cybernode.ai/). Download snapshot ```bash wget https://snapshot.cybernode.ai/bostrom_pruned_<*>.tar ``` Stop your node ```bash docker stop bostrom ``` Replace data folder to snapshot ```bash sudo -H rm -r ~/.cyber/data/ ~/.cyber/wasm/ tar -xf bostrom_pruned_<*>.tar -C ~/.cyber/ ``` Start node ```bash docker start bostrom ``` Check node status and logs after startup ```bash docker exec -ti bostrom cyber status docker logs bostrom -f --tail 20 ``` ================================================ FILE: docs/send_txs.md ================================================ # Your First Cyber-js Actions - Send Tokens Take your first steps with cyber-js. Use it to send some simple transactions.

In this section, you will: * Download and install cyber-js. * Create a small experiment. * Testnet preparation * Establish your connection. * Inspect a balance. * Send transactions.
A basic feature of a Bostrom chain is the ability to send tokens via the `bank` module. Cyber-js naturally offers functions to cover this facility. You are going to: 1. Use an existing test network (testnet) with a key of your own. 2. Run basic Cyber-js commands in a script that you run using the CLI. Additionally, you can choose to: 1. Start a local chain that exposes RPCs instead of using a testnet. 2. Run the same basic Cyber-js commands, but for this local chain. Along the way, you learn the basic Cyber-js concepts needed to start interacting with the Cosmos Ecosystem. ## Script preparation A small, ready-made repository exists so you can experiment with Cyber-js. Clone it from here. You need [NodeJs](https://nodejs.org/en/download/). If you open the folder in [Visual Studio Code](https://code.visualstudio.com/Download), the IDE should give you all the coding help you require. In the cloned folder you need to install the required modules: ```sh $ npm install ``` Create a new file named `experiment.ts`. In it, put these lines to confirm it works: ```typescript const runAll = async(): Promise => { console.log("TODO") } runAll() ``` To execute, this TypeScript file needs to be compiled into JavaScript before being interpreted by NodeJs. Add this as a run target in `package.json`: ```json ... "scripts": { ... "experiment": "ts-node experiment.ts" } ... ``` Confirm that it does what you want: ```sh $ npm run experiment ``` This returns: ``` > ts-node experiment.ts TODO ``` You will soon make this script more meaningful. With the basic script ready, you need to prepare some elements. ## Testnet preparation The Bostrom has a number of testnets running. The Bostrom is currently running a [public testnet](https://github.com/cybercongress/cybernode) for the Space-pussy-1 upgrade that you are connecting to and running your script on. You need to connect to a public node so that you can query information and broadcast transactions. One of the available nodes is: ``` RPC: https://rpc.space-pussy-1.cybernode.ai ``` You need a wallet address on the testnet and you must create a 24-word mnemonic in order to do so. CosmJS can generate one for you. Create a new file `generate_mnemonic.ts` with the following script: ```typescript import { DirectSecp256k1HdWallet } from "@cosmjs/proto-signing" const generateKey = async (): Promise => { const wallet: DirectSecp256k1HdWallet = await DirectSecp256k1HdWallet.generate(24) process.stdout.write(wallet.mnemonic) const accounts = await wallet.getAccounts() console.error("Mnemonic with 1st account:", accounts[0].address) } generateKey() ``` Now create a **key** for our imaginary user **Alice**: *Note: You likely need to update Node.js to a later version if this fails. Find a guide [here](https://phoenixnap.com/kb/update-node-js-version). ```sh $ npx ts-node generate_mnemonic.ts > testnet.alice.mnemonic.key ``` When done, it should also tell you the address of the first account: ``` Mnemonic with 1st account: bostrom1sw8xv3mv2n4xfv6rlpzsevusyzzg78r3e78xnp ``` Temporarily keep this address for convenience, although CosmJS can always recalculate it from the mnemonic. Privately examine the file to confirm it contains your 24 words. Important considerations: 1. `process.stdout.write` was used to avoid any line return. Be careful not to add any empty lines or any other character in your `.key` file (this occurs with VSCode under certain conditions). If you add any characters, ComsJs may not be able to parse it. 2. Adjust the `.gitignore` file to not commit your `.key` file by mistake: ``` node_modules *.key ``` ## Add your imports You need a small, simple interface to a blockchain, one which could eventually have users. Good practice is to refrain from requesting a user address until necessary (e.g. when a user clicks a relevant button). Therefore, in `experiment.ts` you first use the read-only client. Import it at the top of the file: ```typescript import { CyberClient } from "@cybercongress/cyber-js" ``` Note that VSCode assists you to auto-complete [`CyberClient`](https://github.com/cybercongress/soft3.js/blob/main/src/cyberclient.ts#L144) if you type CTRL-Space inside the `{}` of the `import` line. ## Define your connection Next, you need to tell the client how to connect to the RPC port of your blockchain: ```typescript const rpc = "https://rpc.space-pussy-1.cybernode.ai" ``` Inside the `runAll` function you [initialize the connection](https://github.com/cybercongress/soft3.js/blob/main/src/cyberclient.ts#L165) and immediately [check](https://github.com/cybercongress/soft3.js/blob/main/src/cyberclient.ts#L244) you connected to the right place: ```typescript const runAll = async(): Promise => { const client = await CyberClient.connect(rpc) console.log("With client, chain id:", await client.getChainId(), ", height:", await client.getHeight()) } ``` Run again to check with `npm run experiment`, and you get: ``` With client, chain id: space-pussy-1 , height: 9507032 ``` ## Get a balance Normally you would not yet have access to your user's address. However, for this exercise you need to know how many tokens Alice has, so add a temporary new command inside `runAll`: ```typescript console.log( "Alice balances:", await client.getAllBalances("bostrom1sw8xv3mv2n4xfv6rlpzsevusyzzg78r3e78xnp"), // <-- replace with your generated address ) ``` `getAllBalances` is used because the default token name is not yet known. When you run it again, you get: ``` Alice balances: [] ``` If you just created this account, Alice's balance is zero. Alice needs tokens to be able to send transactions and participate in the network. A common practice with testnets is to expose **faucets** (services that send you test tokens for free, within limits). Request tokens for Alice by entering this command in command line: ```sh curl --header "Content-Type: application/json" --request POST --data '{"denom":"boot","address":"bostrom1sw8xv3mv2n4xfv6rlpzsevusyzzg78r3e78xnp"}' https://space-pussy-1.cybernode.ai/credit ``` Check that Alice received the tokens with `npm run experiment`. ## Prepare a signing client If you go through the methods inside [`CyberClient`](https://github.com/cybercongress/soft3.js/blob/main/src/cyberclient.ts#L144), you see that it only contains query-type methods and none for sending transactions. Now, for Alice to send transactions, she needs to be able to sign them. And to be able to sign transactions, she needs access to her _private keys_ or _mnemonics_. Or rather she needs a client that has access to those. That is where [`SigningCyberClient`](https://github.com/cybercongress/soft3.js/blob/main/src/signingcyberclient.ts#L239) comes in. Conveniently, `SigningCyberClient` inherits from `CyberClient`. Update your import line: ```typescript import { SigningCyberClient, CyberClient } from "@cybercongress/cyber-js" ``` Look at its declaration by right-clicking on the `SigningCyberClient` in your imports and choosing Go to Definition. When you instantiate `SigningCyberClient` by using the [`connectWithSigner`](https://github.com/cybercongress/soft3.js/blob/main/src/signingcyberclient.ts#L247) method, you need to pass it a [**signer**](https://github.com/cybercongress/soft3.js/blob/main/src/signingcyberclient.ts#L249). In this case, use the [`OfflineDirectSigner`](https://github.com/cybercongress/soft3.js/blob/main/src/signingcyberclient.ts#L29) interface. The recommended way to encode messages is by using `OfflineDirectSigner`, which uses Protobuf. However, hardware wallets such as Ledger do not support this and still require the legacy Amino encoder. If your app requires Amino support, you have to use the `OfflineAminoSigner`.

Read more about encoding [here](https://docs.cosmos.network/master/core/encoding.html).
The signer needs access to Alice's **private key**, and there are several ways to accomplish this. In this example, use Alice's saved **mnemonic**. To load the mnemonic as text in your code you need this import: ```typescript import { readFile } from "fs/promises" ``` There are several implementations of `OfflineDirectSigner` available. The [`DirectSecp256k1HdWallet`](https://github.com/cosmos/cosmjs/blob/0f0c9d8/packages/proto-signing/src/directsecp256k1hdwallet.ts#L133) implementation is most relevant to us due to its [`fromMnemonic`](https://github.com/cosmos/cosmjs/blob/0f0c9d8/packages/proto-signing/src/directsecp256k1hdwallet.ts#L140-L141) method. Add the import: ```typescript import { DirectSecp256k1HdWallet, OfflineDirectSigner } from "@cosmjs/proto-signing" ``` The `fromMnemonic` factory function needs a string with the mnemonic. You read this string from the mnemonic file. Create a new top-level function that returns an `OfflineDirectSigner`: ```typescript [https://github.com/b9lab/cosmjs-sandbox/blob/4168b97/experiment.ts#L9-L13] const getAliceSignerFromMnemonic = async (): Promise => { return DirectSecp256k1HdWallet.fromMnemonic((await readFile("./testnet.alice.mnemonic.key")).toString(), { prefix: "bostrom", }) } ``` The Bostrom Testnet uses the `bostrom` address prefix. This is the default used by `DirectSecp256k1HdWallet`, but you are encouraged to explicitly define it as you might be working with different prefixes on different blockchains. In your `runAll` function, add: ```typescript const aliceSigner: OfflineDirectSigner = await getAliceSignerFromMnemonic() ``` As a first step, confirm that it recovers Alice's address as expected: ```typescript const alice = (await aliceSigner.getAccounts())[0].address console.log("Alice's address from signer", alice) ``` Now add the line that finally creates the signing client: ```typescript const signingClient = await SigningCyberClient.connectWithSigner(rpc, aliceSigner) ``` Check that it works like the read-only client that you used earlier, and from which [it inherits](https://github.com/cybercongress/soft3.js/blob/main/src/signingcyberclient.ts#L239), by adding: ```typescript console.log( "With signing client, chain id:", await signingClient.getChainId(), ", height:", await signingClient.getHeight() ) ``` ## Send tokens Alice can now send some tokens to Bob, but to do so she also needs to pay the network's gas fee. How much gas should she use, and at what price? She can copy this: ``` Gas fee: [ { denom: 'boot', amount: '0' } ] Gas limit: 200000 ``` With the gas information now decided, how does Alice structure her command so that she sends tokens to Bob ? `SigningCyberClient`'s [`sendTokens`](https://github.com/cybercongress/soft3.js/blob/main/src/signingcyberclient.ts#L604) function takes a `Coin[]` as input. `Coin` is simply defined as: ```typescript export interface Coin { denom: string; amount: string; } ``` Alice can pick any `denom` and any `amount` as long as she owns them, the signing client signs the transaction and broadcasts it. In this case it is: ```typescript { denom: "boot", amount: "1" } ``` With this gas and coin information, add the command: ```typescript [https://github.com/b9lab/cosmjs-sandbox/blob/2c7b137/experiment.ts#L57-L63] // Check the balance of Alice and the Faucet console.log("Alice balance before:", await client.getAllBalances(alice)) console.log("Bob balance before:", await client.getAllBalances(bobAddress)) // Execute the sendTokens Tx and store the result const result = await signingClient.sendTokens( alice, bobAddress, [{ denom: "boot", amount: "1" }], { amount: [{ denom: "boot", amount: "0" }], gas: "200000", }, ) // Output the result of the Tx console.log("Transfer result:", result) ``` Run this with `npm run experiment` and you should get: ``` ... Transfer result: { code: 0, height: 0, rawLog: '[]', transactionHash: '104BFAB101D8EB88C14D7EFCF50F96F29DA02C7DD85C70FAAB1D96D41C2FA04E', gasUsed: 0, gasWanted: 0 } ``` Check that Alice sended the tokens with [`getTx`](https://github.com/cybercongress/soft3.js/blob/main/src/cyberclient.ts#L314) ```typescript const result = await client.getTx("104BFAB101D8EB88C14D7EFCF50F96F29DA02C7DD85C70FAAB1D96D41C2FA04E") ``` This concludes your first use of cyber-js to send tokens. ================================================ FILE: docs/setup_cyber_configuration.md ================================================ # Setup config.toml Correct configuration is one of the main keys to consistent and proper functioning of your node no matter if it is a validator or a sentinel/service node. Throughout this document, we will check all the key points of the `config.toml` file and explain how to configure them for all use-cases. We will operate a basic configuration file (according to the number of the line in the actual file), generated after the initialization of cyber daemon and typically located inside `$HOME/.cyber/config directory`. > All changes made to the `config.toml` file, require to restart cyber to take effect! ## Port / Address configuration ### RPC port First of all, let's look through the ports cyber uses to communicate with the outside world. On *line 84* the specified port is used for an RPC server (TCP and UNIX websocket connections): ```bash # TCP or UNIX socket address for the RPC server to listen on laddr = "tcp://127.0.0.1:26657" ``` After the node starts the RPC server provides endpoints to check chain/node parameters, accepts $POST transactions and so on. It can be opened locally using your favourite browser via: `http://localhost:26657`. - We do not recommend a validator node to open this port to the outside world, as it may allow anyone to produce transactions using your node and allows DOS attacks (you don't want your validator attacked, right?). So let's leave it like this: ```bash laddr = "tcp://127.0.0.1:26657" ``` - For Sentinel nodes this should be kept the same as for validators: ```bash laddr = "tcp://127.0.0.1:26657" ``` - For Service nodes, when use cases include remote access to the RPC for yourself or for your great service, it is allowable to expose it to the outside by using the following values: ```bash laddr = "tcp://0.0.0.0:26657" ``` If you would like to make the RPC server respond on a different port, you may change this value to whatever you'd like (just make sure it will not cross with any of the other services), for example, to change it to `9588` use: ```bash # TCP or UNIX socket address for the RPC server to listen on laddr = "tcp://0.0.0.0:9588" ``` ### Cyberd communication port On *line 163* we can find the following: ```bash # Address to listen for incoming connections laddr = "tcp://0.0.0.0:26656" ``` This is the way the node communicates with other nodes in the chain. For all possible cases(**Validator, Sentinel, Service**) leave it as default, bound to `0.0.0.0`. And if you need to change the port number to something different like `35622` just use: ```bash laddr = "tcp://0.0.0.0:35622" ``` If changed, your node peer address would be changed accordingly: `75e8f44072b0dd598dfa95aaf9b5f2c60f956819@your_external_ip:35622`. ### Prometheus collectors port On *line 325* the port for Prometheus monitoring service is located: ```bash # Address to listen for Prometheus collector(s) connections prometheus_listen_addr = ":26660" ``` It is useful if you want to monitor remotely the condition of your node using the [Prometheus](https://prometheus.io/) metrics collector service and could be changed to whatever you like `23456`: ```bash prometheus_listen_addr = ":23456" ``` Don't forget to enable Prometheus metrics by changing to `true` on *line 322*, if needed: ```bash # When true, Prometheus metrics are served under /metrics on # PrometheusListenAddr. # Check out the documentation for the list of available metrics. prometheus = true ``` ### External address On *line 169* you should find the following: ```bash # Address to advertise to peers for them to dial # If empty, will use the same port as the laddr, # and will introspect on the listener or use UPnP # to figure out the address. external_address = "" ``` This line implies specifying your external IP address, which means the presence of a static external address at your network connection. If you don't have one, just skip it. - For Validator nodes, you may skip it, until you have **enough private peers** to get synced with. Otherwise, you have to specify your external static IP to improve peer discovery for your node. Also, don't forget to change the port according to *line [163](#cyber-communication-port)*: ```bash external_address = "tcp://:26656" ``` - For Sentinel nodes it is a good idea to specify the IP for better peer discovery: ```bash external_address = "tcp://:26656" ``` - For Servie nodes this setting can be the same as for Sentinel nodes: ```bash external_address = "tcp://:26656" ``` And again, all of the above settings apply to the cases when **STATIC EXTERNAL IP** is available. ### Allow duplicated IP's *Line 224* of the config.toml holds the following: ```bash # Toggle to disable guard against peers connecting from the same ip. allow_duplicate_ip = false ``` This variable configures the possibility for different peers to be connected from the same IP. Lets imagine a situation where you run 2 nodes (lets say that the node ID of the first one is: `75e8f44072b0dd598dfa95aaf9b5f2c60f956819` and the second one is: `d0518ce9881a4b0c5872e5e9b7c4ea8d760dad3f`) on one internet provider, with an external IP of 92.23.45.123. In this case, all other nodes in the network with `allow_duplicate_ip = false` will see attempts to connect from peers `d0518ce9881a4b0c5872e5e9b7c4ea8d760dad3f@92.23.45.123:26656` and `75e8f44072b0dd598dfa95aaf9b5f2c60f956819@92.23.45.123:36656` and will block the one which comes last because the originating IP address is the same for both nodes. If this case applies to you, change this setting to the following: ```bash # Toggle to disable guard against peers connecting from the same ip. allow_duplicate_ip = true ``` ## P2P configuration ### Seed nodes On *line 172* of the config.toml we see the following: ```bash # Comma separated list of seed nodes to connect to seeds = "" ``` This line is dedicated to the list of seed nodes you want to establish a connection with. To get some seed and peers addresses take a look at networks [repository](https://github.com/cybercongress/networks). - For validators with sentinel nodes or with a decent quantity of peers connected it is not required to fill it out: ```bash seeds = "" ``` - For Sentinel nodes and Service nodes it's a good idea to fill it out with a couple of seed node addresses, separated with commas: ```bash seeds = "@:,@:" ``` ### Persistent peers The place to add persistent peers is located on *line 175.* Presence of persistent peers is very important for the correct functioning of the node: ```bash # Comma separated list of nodes to keep persistent connections to persistent_peers = "" ``` - For Validator nodes you have to fill out this line with a decent amount of peers you **trust**, otherwise, your validator node address will be exposed. In the perfect case scenario, you should add to this section only the addresses of your sentinel nodes: ```bash persistent_peers ="@:,@:" ``` - For Sentinel nodes and Service nodes add as many peers as possible to keep a persistent connection and network stability, but **DO NOT** put here you'r validator nodes ID's: ```bash persistent_peers ="@:,@:,...,@:" ``` ### Peer Exchange Reactor *Line 212* shows by default: ```bash # Set true to enable the peer-exchange reactor pex = true ``` This is a peer exchange module, which is responsible for exchanging node IDs across the network. - For Validator nodes with Sentinel architecture set this to be disabled: ```bash pex = false ``` - For Sentinel nodes and Service nodes leave as default: ```bash pex = true ``` ### Private peers ID's On *line 221* we see: ```bash # Comma separated list of peer IDs to keep private (will not be gossiped to other peers) private_peer_ids = "" ``` This is the list of peers which IDs should not gossip to others. - For Validator nodes, leave as default: ```bash private_peer_ids = "" ``` - For Sentinel nodes, add your validator/s address here: ```bash private_peer_ids = "@:" ``` - For Service nodes leave blank: ```bash private_peer_ids = "" ``` ## Node Index, Naming ### Indexed tags A node can index and store a decent amount of keys and values with regards to transactions, accounts etc. *Lines 306 and 304* are responsible for this: ```bash # You can also index transactions by height by adding "tx.height" key here. # # It's recommended to index only a subset of keys due to possible memory # bloat. This is, of course, depends on the indexer's DB and the volume of # transactions. index_keys = "" # When set to true, tells indexer to index all compositeKeys (predefined keys: # "tx.hash", "tx.height" and all keys from DeliverTx responses). # # Note this may be not desirable (see the comment above). IndexKeys has a # precedence over IndexAllKeys (i.e. when given both, IndexKeys will be # indexed). index_all_keys = false ``` - For Validator and Sentinel nodes this is not necessary, so leave as default: ```bash index_keys = "" index_all_keys = false ``` - For Service nodes, you should specify a subset of keys you want to index: ```bash index_keys = "tx.hash,tx.height,...etc.." index_all_keys = true ``` ### Naming To setup up your node moniker please refer to *line 16* and type in whatever you want to have as moniker: ```bash # A custom human readable name for this node moniker = "rocket_node" ``` ================================================ FILE: docs/setup_dev_env.md ================================================ # Setup development environment ## Prestart * Install [Golang 1.11+](https://golang.org/doc/install) * Install [GoLand IDE](https://www.jetbrains.com/go/) ## Import project to GoLand Open Project in GoLand by selecting: Open Project -> selecting cloned repository root folder ![Open project](https://ipfs.io/ipfs/QmYQxSKzQkkpCofuHmbJZqYoTo4cuvHQuUNYkJRBKgSduL) Enable **go mod** package management ![Enable go mod](https://ipfs.io/ipfs/Qmaz3o7LjAG9bNhE8VkHSUokM8EqgfcVXT9R5qB3XxLZSe) Wait for dependency downloading and indexation ## Add Run Configurations ###Add testnet configuration ![Generate testnet](./img/generate-testnet.png) ### Add run configuration with GPU ![Run node](./img/run-node.png) #### Notes about GPU dev environment ``` TO DO ``` ### Add run configuration with CPU ![Run node CPU](./img/run-node-cpu.png) ``` start --allow-search=true --compute-rank-on-gpu=false --home=./mytestnet/node0/cyberd ``` ### Add reset configuration ![Reset node data](./img/reset-node-data.png) ## Running Node ### Generate testnet Before node running, setup testnet with run configuration **D TESTNET**. - Folder **/mytestnet** will be added to the project root. - In **/node0** subfolder you can find daemon and cli folders. - Daemon folder will contain validator node data. - In **/cyberdcli** folder you can find initial validator seed. ``` mytestnet ├── gentxs │   └── node0.json └── node0 ├── cyberd │   ├── config │   │   ├── config.toml │   │   ├── genesis.json │   │   ├── node_key.json │   │   └── priv_validator_key.json │   └── data │   ├── priv_validator_state.json └── cyberdcli └── key_seed.json ``` ### Run with GPU or CPU After, just run **RUN** node configuration. ``` I[2019-05-15|15:06:56.735] Starting ABCI with Tendermint module=main I[2019-05-15|15:06:56.789] Loading mem state module=main I[2019-05-15|15:06:56.789] App loaded module=main time=118.743µs I[2019-05-15|15:06:56.793] Search index loaded! module=main time=3.416449ms I[2019-05-15|15:06:56.793] Search index starting listen new links module=main I[2019-05-15|15:06:56.793] Search index starting listen new rank module=main I[2019-05-15|15:06:56.910] Applying genesis module=main I[2019-05-15|15:06:56.914] File with links not found. Empty set will be used module=main I[2019-05-15|15:06:56.914] Genesis applied module=main time=3.420262ms E[2019-05-15|15:06:56.947] Couldn't connect to any seeds module=p2p I[2019-05-15|15:07:02.014] Executed block module=state height=1 validTxs=0 invalidTxs=0 I[2019-05-15|15:07:02.014] Rank calculated module=main time=2.069µs links=0 cids=0 hash=e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855 I[2019-05-15|15:07:02.047] Committed state module=state height=1 txs=0 appHash=E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855 I[2019-05-15|15:07:07.078] Executed block module=state height=2 validTxs=0 invalidTxs=0 I[2019-05-15|15:07:07.107] Committed state module=state height=2 txs=0 appHash=E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855 I[2019-05-15|15:07:12.113] Executed block module=state height=3 validTxs=0 invalidTxs=0 I[2019-05-15|15:07:12.144] Committed state module=state height=3 txs=0 appHash=E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855 I[2019-05-15|15:07:17.168] Executed block module=state height=4 validTxs=0 invalidTxs=0 I[2019-05-15|15:07:17.207] Committed state module=state height=4 txs=0 appHash=E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855 ``` ### You may stop, and RUN again ``` I[2019-05-15|14:48:58.191] Starting ABCI with Tendermint module=main I[2019-05-15|14:48:58.343] Loading mem state module=main I[2019-05-15|14:48:58.344] App loaded module=main time=929.472µs I[2019-05-15|14:48:58.399] Search index loaded! module=main time=16.928556ms I[2019-05-15|14:48:58.399] Search index starting listen new links module=main I[2019-05-15|14:48:58.399] Search index starting listen new rank module=main E[2019-05-15|14:48:58.638] Couldn't connect to any seeds module=p2p I[2019-05-15|14:49:03.716] Executed block module=state height=2032 validTxs=0 invalidTxs=0 I[2019-05-15|14:49:03.755] Committed state module=state height=2032 txs=0 appHash=1BAA91AD6FD9742B7B094204037F80A8174673BA0FF304D3FF5DFEEAF8FF7DDC I[2019-05-15|14:49:08.759] Executed block module=state height=2033 validTxs=0 invalidTxs=0 I[2019-05-15|14:49:08.793] Committed state module=state height=2033 txs=0 appHash=1BAA91AD6FD9742B7B094204037F80A8174673BA0FF304D3FF5DFEEAF8FF7DDC I[2019-05-15|14:49:13.826] Executed block module=state height=2034 validTxs=0 invalidTxs=0 I[2019-05-15|14:49:13.860] Committed state module=state height=2034 txs=0 appHash=1BAA91AD6FD9742B7B094204037F80A8174673BA0FF304D3FF5DFEEAF8FF7DDC ``` ### Reset You can reset chains data to genesis at any time by executing **RESET** run configuration ``` I[2019-05-15|15:09:43.338] Removed existing address book module=main file=mytestnet/node0/cyberd/config/addrbook.json I[2019-05-15|15:09:43.345] Removed all blockchain history module=main dir=mytestnet/node0/cyberd/data I[2019-05-15|15:09:43.347] Reset private validator file to genesis state module=main keyFile=mytestnet/node0/cyberd/config/priv_validator_key.json stateFile=mytestnet/node0/cyberd/data/priv_validator_state.json ``` ## Exploring Guide to all commands you may to research here: [Ultimate cyberd CLI guide](https://github.com/cybercongress/cyberd/blob/master/docs/help/ultimate-commands-guide_v2.md) ### Before, build cyberd cli: ``` go build -o cyberdcli ./cli ``` You will get cyberdcli into you project root ### Add keys: ``` ./cyberdcli keys add validator --recover ``` Enter and you protection password-passphrase and mnemocic from file **mytestnet/node0/cyberdcli/key_seed.json** ``` Enter a passphrase to encrypt your key to disk: Repeat the passphrase: > Enter your bip39 mnemonic inhale enforce brand fever core smart draft ceiling among cluster orbit robust tonight elephant below twice goat update uncover employ spider brass consider shiver NAME: TYPE: ADDRESS: PUBKEY: validator local cyber18l4v00ar4xsgzc4rr40tfctcjgyp7ppwysdcns cyberpub1addwnpepq0zm06twxtf7ezv4nj9dhud9ds0fnhkks6qw4g8pdwxzh3evggpvvksh60l ``` ### Query status: ``` ./cyberdcli status --indent ``` ``` { "node_info": { "protocol_version": { "p2p": "7", "block": "10", "app": "0" }, "id": "b99f3254757310d1f470f5cd0331b766f2a843f9", "listen_addr": "tcp://0.0.0.0:26656", "network": "chain-K6U4uZ", "version": "0.30.1", "channels": "4020212223303800", "moniker": "node0", "other": { "tx_index": "on", "rpc_address": "tcp://0.0.0.0:26657" } }, "sync_info": { "latest_block_hash": "8059683636349AF9237FABFD147BAD89C7188571E37E8F09356B1837A88337BA", "latest_app_hash": "E3B0C44298FC1C149AFBF4C8996FB92427AE41E4649B934CA495991B7852B855", "latest_block_height": "134", "latest_block_time": "2019-05-15T09:04:31.768026Z", "catching_up": false }, "validator_info": { "address": "9C2C13F2B6608BF00BADF501A04E728AC5FF7ADC", "pub_key": { "type": "tendermint/PubKeyEd25519", "value": "or7X/1BYcGE1cVX5e3vG9G76JPfXZDKTDg8YL3vtKzo=" }, "voting_power": "10000000000" } } ``` ### Query balance: ``` ./cyberdcli query account cyber18l4v00ar4xsgzc4rr40tfctcjgyp7ppwysdcns ``` ``` Account: Address: cyber18l4v00ar4xsgzc4rr40tfctcjgyp7ppwysdcns Pubkey: cyberpub1addwnpepq0zm06twxtf7ezv4nj9dhud9ds0fnhkks6qw4g8pdwxzh3evggpvvksh60l Coins: 10000000000000000cyb AccountNumber: 0 Sequence: 1 ``` ### Query validators: ``` ./cyberdcli query staking validators ``` ``` Validator Operator Address: cybervaloper18l4v00ar4xsgzc4rr40tfctcjgyp7ppwy3lgak Validator Consensus Pubkey: cybervalconspub1zcjduepq52ld0l6stpcxzdt32huhk77x73h05f8h6ajr9ycwpuvz77ld9vaq6ka2zl Jailed: false Status: Bonded Tokens: 10000000000000000 Delegator Shares: 10000000000000000.000000000000000000 Description: {node0 tst com.com det} Unbonding Height: 0 Unbonding Completion Time: 1970-01-01 00:00:00 +0000 UTC Minimum Self Delegation: 1 Commission: rate: 0.000000000000000000, maxRate: 0.000000000000000000, maxChangeRate: 0.000000000000000000, updateTime: 2019-05-15 08:52:36.324624 +0000 UTC ``` ### Add links ``` ./cyberdcli link --from=validator --cid-from=QmbTARMsUw9X2ZEbBaFXRu9JEqNN2g4VZ6DPgtgZH1opy9 --cid-to=QmNWkR2v4ZEzT43xiNKJcFPkFQioGbhqsWcE5qayWQHXAo --chain-id=chain-K6U4uZ ./cyberdcli link --from=validator --cid-from=QmbTARMsUw9X2ZEbBaFXRu9JEqNN2g4VZ6DPgtgZH1opy9 --cid-to=Qmd7AaekFAxXedSQx3B3h8Wc5aeYPYRiYF83Vjb4tVLkMM --chain-id=chain-K6U4uZ ./cyberdcli link --from=validator --cid-from=QmbTARMsUw9X2ZEbBaFXRu9JEqNN2g4VZ6DPgtgZH1opy9 --cid-to=QmfSh5obPXmkaTd9aaNCYWxnKHZTH6EYeEh7Hq7xgGnRVy --chain-id=chain-K6U4uZ ``` ``` {"chain_id":"chain-K6U4uZ","account_number":"0","sequence":"1","fee":{"amount":null,"gas":"200000"},"msgs":[{"type":"cyberd/Link","value":{"address":"cyber18l4v00ar4xsgzc4rr40tfctcjgyp7ppwysdcns","links":[{"from":"QmbTARMsUw9X2ZEbBaFXRu9JEqNN2g4VZ6DPgtgZH1opy9","to":"QmNWkR2v4ZEzT43xiNKJcFPkFQioGbhqsWcE5qayWQHXAo"}]}}],"memo":""} confirm transaction before signing and broadcasting [Y/n]: Y Password to sign with 'validator': Response: Height: 1720 TxHash: 68C4F6389D36747A6A609CCDD9D44027A5234850FF065C78D1B1AB3FAC421541 Logs: [{"msg_index":0,"success":true,"log":""}] GasUsed: 31368 Tags: - action = link ``` ### Search and get links with rank: ``` curl -X GET 'localhost:26657/search?cid="QmbTARMsUw9X2ZEbBaFXRu9JEqNN2g4VZ6DPgtgZH1opy9"' ``` #### Links added, rank for them will be computed at next round: ``` { "jsonrpc": "2.0", "id": "", "result": { "cids": [ { "cid": "QmNWkR2v4ZEzT43xiNKJcFPkFQioGbhqsWcE5qayWQHXAo", "rank": 0 }, { "cid": "Qmd7AaekFAxXedSQx3B3h8Wc5aeYPYRiYF83Vjb4tVLkMM", "rank": 0 }, { "cid": "QmfSh5obPXmkaTd9aaNCYWxnKHZTH6EYeEh7Hq7xgGnRVy", "rank": 0 } ], "total": "3", "page": "0", "perPage": "100" } }% ``` #### When rank computed: ``` { "jsonrpc": "2.0", "id": "", "result": { "cids": [ { "cid": "QmNWkR2v4ZEzT43xiNKJcFPkFQioGbhqsWcE5qayWQHXAo", "rank": 0.056093750000000005 }, { "cid": "Qmd7AaekFAxXedSQx3B3h8Wc5aeYPYRiYF83Vjb4tVLkMM", "rank": 0.056093750000000005 }, { "cid": "QmfSh5obPXmkaTd9aaNCYWxnKHZTH6EYeEh7Hq7xgGnRVy", "rank": 0.056093750000000005 } ], "total": "3", "page": "0", "perPage": "100" } } ``` # #fuckgoogle ================================================ FILE: docs/soft2-soft3-concepts.md ================================================ # soft2 and soft3 ## content from presentation ## particle A particle is a content identifier (CID) of the file in IPFS network. CIDs are based on the file’s cryptographic hash. That means: - Any difference in the content will produce a different CID and - The same content added to two different IPFS nodes using the same settings will produce the same CID. A file can be retrieved from IPFS network using this hash. Particles are written into Bostrom blockchain in a form of cyberlinks. ## cyberlink A cyberlink is a link between two particles registered in Bostrom blockchain by a particular neuron. Cyberlinks are the edges of the knowledge graph, particles are the vertexes (aka nodes). ## neuron Neuron is an agent that creates cyberlinks. A neuron can be: - a private key holder; - a cosm-wasm contract (autonomus program). ## knowledge graph The knowledge graph is a directed weighted graph between particles. The knowledge graph of Bostrom blockchain consists of pairs: each source particle is connected to a destination particle via cyberlink (with additional information of neuron's address and the height info). So each cyberlink recorded into blockchain in a form of: `source_particle - destination_particle - neuron - height` ## content oracle ================================================ FILE: docs/supported_gpu_list.md ================================================ # Supported GPU list for cyber validators In our `cyber protocol` implementation on `GO` proof of relevance root hash is computed on Cuda GPUs every round as the best way to calculate merkle tree faster. We need to load the whole graph in memory for calculating that's why memory volume is important. GPU with 6Gb memory can calculate graph with ~200 M links. |GPU|Supported|Tested|CUDA cores|Memory|Year of production| |---|---|---|---|---|---| |[GEFORCE RTX 2080 Ti](https://www.nvidia.com/en-us/geforce/graphics-cards/rtx-2080-ti/)|:white_check_mark:|:x:|4352|11GB GDDR 6|2018| |[GEFORCE RTX 2080](https://www.nvidia.com/en-us/geforce/graphics-cards/rtx-2080/)|:white_check_mark:|:x:|4352|11GB GDDR 6|2018| |[GEFORCE RTX 2070](https://www.nvidia.com/en-us/geforce/graphics-cards/rtx-2070/)|:white_check_mark:|:x:|2304|8 GB GDDR6|2019| |[GeForce RTX 2060](https://www.nvidia.com/en-us/geforce/graphics-cards/rtx-2060/)|:white_check_mark:|:x:|1920|6 GB GDDR6|2019| |[GEFORCE GTX 1660 Ti](https://www.nvidia.com/en-us/geforce/graphics-cards/gtx-1660-ti/)|:white_check_mark:|:x:|1536|6GB GDDR6|2019| |[GEFORCE GTX 1660](https://www.nvidia.com/en-us/geforce/graphics-cards/gtx-1660-ti/)|:white_check_mark:|:x:|1408|6GB GDDR5|2019| |[GEFORCE GTX 1650](https://www.nvidia.com/en-us/geforce/graphics-cards/gtx-1650/)|:white_check_mark:|:white_check_mark:|896|4GB GDDR5|2019| |[GeForce GTX 1080](https://www.nvidia.com/en-us/geforce/products/10series/geforce-gtx-1080/)|:white_check_mark:|:white_check_mark:|2560|8 GB GDDR5X|2016| |[GeForce GTX 980](https://www.geforce.com/hardware/desktop-gpus/geforce-gtx-980/specifications)|:white_check_mark:|:x:|2048|4 GB GDDR5|2014| |[TITAN Xp](https://www.nvidia.com/en-us/titan/titan-xp/)|:white_check_mark:|:x:|3840|12 GB GDDR5|2017| |[GeForce GTX 1080 Ti](https://www.nvidia.com/en-us/geforce/products/10series/geforce-gtx-1080-ti/)|:white_check_mark:|:x:|3584|11 GB GDDR5X|2017| |[GeForce GTX 980 Ti](https://www.nvidia.com/en-us/geforce/products/10series/geforce-gtx-1080-ti/)|:white_check_mark:|:x:|2816|6 GB GDDR5|2015| |[GeForce GTX 1070 Ti](https://www.nvidia.com/en-us/geforce/products/10series/geforce-gtx-1070-ti/)|:white_check_mark:|:white_check_mark:|2432|8 GB GDDR5|2017| |[GeForce GTX 1070](https://www.nvidia.com/en-us/geforce/products/10series/geforce-gtx-1070-ti/)|:white_check_mark:|:white_check_mark:|1920|8 GB GDDR5|2016| |[GeForce GTX 970](https://www.nvidia.com/en-us/geforce/products/10series/geforce-gtx-1070-ti/)|:white_check_mark:|:x:|1664|4 GB GDDR5|2015| |[GEFORCE GTX 1060 6GB](https://www.nvidia.com/en-us/geforce/products/10series/geforce-gtx-1060/)|:white_check_mark:|:white_check_mark:|1280|6 GB GDDR5|2016| |[GeForce GTX 1050 Ti 4GB](https://www.nvidia.com/en-us/geforce/products/10series/geforce-gtx-1050/)|:white_check_mark:|:white_check_mark:|768|4 GB GDDR5|2016| |[GeForce GTX 1050 4GB mobile](https://www.techpowerup.com/gpu-specs/asus-gtx-1050-mobile-4-gb.b5497)|:white_check_mark:|:white_check_mark:|640|4 GB GDDR5|2020| |[GeForce GTX 745 (OEM) 4GB](https://www.geforce.com/hardware/desktop-gpus/geforce-gtx-745-oem/specifications)|:white_check_mark:|:x:|768|4 GB GDDR3|2014| |[GeForce GTX TITAN X](https://www.geforce.com/hardware/desktop-gpus/geforce-gtx-titan-x/specifications)|:white_check_mark:|:x:|3072|12 GB GDDR5|2016| |[GeForce GTX TITAN Z](https://www.geforce.com/hardware/desktop-gpus/geforce-gtx-titan-z/specifications)|:white_check_mark:|:x:|5760|12 GB GDDR5|2014| |[GeForce GTX TITAN Black](https://www.geforce.com/hardware/desktop-gpus/geforce-gtx-titan-black/specifications)|:white_check_mark:|:x:|2880|6 GB GDDR5|2014| |[GeForce GTX 770](https://www.geforce.com/hardware/desktop-gpus/geforce-gtx-770/specifications)|:white_check_mark:|:x:|1536|4 GB GDDR5|2013| |[Nvidia Quadro K2200](https://www.nvidia.com/content/dam/en-zz/Solutions/design-visualization/documents/75509_DS_NV_Quadro_K2200_US_NV_HR.pdf)|:white_check_mark:|:white_check_mark:|640|4 GB GDDR5|2016| If you have used some GPU from `column` supported but without :white_check_mark: at `tested` column please submit a pull request with corrections. If you have tested GPU and it's not contained in that list submit PR too. **Note** If you using some old cards (like GTX 770, or older) make sure your card will be supported by al least **v.410** of NVIDIA diver for Linux. ================================================ FILE: docs/ultimate_commands_guide.md ================================================ # Ultimate cyber CLI guide. Chain: bostrom ## Install cyber client It is possible to interact with cyber even if you don't have your own node. All you need to do is install `cyber` client on your machine using the script below, paste it in the console (currently Linux supported): ```bash bash < <(curl -s https://raw.githubusercontent.com/cybercongress/go-cyber/main/scripts/install_cyber.sh) ``` After installation, you will be able to use `cyber` to [import accounts](#account-management), create links or swap tokens. In case you have your own node, which is already running inside Docker container, please add `docker exec -ti container-name` before every cyber command: ```bash docker exec -ti bostrom cyber --help ``` First of all, I would like to encourage you to use the `--help` feature if you want to have a better experience using cyber. This is a really easy way to find all the necessary commands with the appropriate options and flags. For example, you can enter: ```bash cyber --help ``` You should see this message: ```bash Usage: cyber [command] Available Commands: add-genesis-account Add a genesis account to genesis.json collect-gentxs Collect genesis txs and output a genesis.json file config Create or query an application CLI configuration file debug Tool for helping with debugging your application export Export state to JSON gentx Generate a genesis tx carrying a self delegation help Help about any command init Initialize private validator, p2p, genesis, and application configuration files keys Manage your applications keys migrate Migrate genesis to a specified target version query Querying subcommands start Run the full node status Query remote node for status tendermint Tendermint subcommands testnet Initialize files for a simapp testnet tx Transactions subcommands unsafe-reset-all Resets the blockchain database, removes address book files, and resets data/priv_validator_state.json to the genesis state validate-genesis validates the genesis file at the default location or at the location passed as an arg version Print the application binary version information ``` The help feature works like a pyramid, you can use it with any command to find available options, subcommands and flags. For example, lets explore the `query` subcommands: ```bash cyber query --help ``` You can see the structure of the subcommand: ```bash Usage: cyber query [flags] cyber query [command] ``` And the available subcommands and flags: ```bash Querying subcommands Aliases: query, q Available Commands: account Query for account by address auth Querying commands for the auth module authz Querying commands for the authz module bandwidth Querying commands for the bandwidth module bank Querying commands for the bank module block Get verified data for a the block at given height distribution Querying commands for the distribution module dmn Querying commands for the dmn module evidence Query for evidence by hash or for all (paginated) submitted evidence feegrant Querying commands for the feegrant module gov Querying commands for the governance module graph Querying commands for the graph module grid Querying commands for the grid module ibc Querying commands for the IBC module ibc-transfer IBC fungible token transfer query subcommands liquidity Querying commands for the liquidity module mint Querying commands for the minting module params Querying commands for the params module rank Querying commands for the rank module resources Querying commands for the resources module slashing Querying commands for the slashing module staking Querying commands for the staking module tendermint-validator-set Get the full tendermint validator set at given height tx Query for a transaction by hash, "/" combination or comma-separated signatures in a committed block txs Query for paginated transactions that match a set of events upgrade Querying commands for the upgrade module wasm Querying commands for the wasm module Flags: --chain-id string The network chain ID -h, --help help for query Global Flags: --home string directory for config and data (default "/root/.cyber") --log_format string The logging format (json|plain) (default "plain") --log_level string The logging level (trace|debug|info|warn|error|fatal|panic) (default "info") --trace print out full stack trace on errors Use "cyber query [command] --help" for more information about a command. ``` Let's explore the `bank` subcommand: ```bash cyber query bank --help ``` We can see all of the options available for these subcommands, names and account address: ```bash Usage: cyber query bank [flags] cyber query bank [command] Available Commands: balances Query for account balances by address denom-metadata Query the client metadata for coin denominations total Query the total supply of coins of the chain ``` In most cases you will need just two extra flags: ```bash --from= \ --chain-id=bostrom \ --node= ``` That's it. This is a very useful tool for using cyber and troubleshooting. ## Glossary **Bonded tokens** - Tokens that are nominated to a validator, non transferable. **Commission** - The tokens that you've earned via validating from delegators. **Dyson Sphere** - Construct in cyber responsible for energy transformation and routing. **Investminting** - Process of convertation Hydrogen to Volts or Amperes, locking a certain amount of H for a certain amount of time produces some V or A. **Hero** - A validator. **Hydrogen** - Token issued after boot delegation, 1:1 H to boot. Used to generate enery through the Dyson sphere (investminting process). **Unbonding** - The process of taking back your share (delegated tokens + any rewards). 4 days for `bostrom` chain. **link** - A reference between a CID key and a CID value. Link message cost is `100*n`, where `n` is the number of links in a message. Link finalization time is 1 block. New rank for CIDs of links will be recalculated at a period of 5 blocks. **liquid tokens** - Transferable tokens within the cyber. **local keystore** - A store with keys on your local machine. **rewards** - Tokens that a hero earned via delegation. To reduce network load all the rewards are stored in a pool. You can take your part of the bounty at any time with commands from the **delegator** section. **** - The commission that a validator gets for their work. Must be a fraction >0 and <=1 **** - Delegator address. Starts with `bostrom` most often coinciding with **** **** - An account address. Starts with `bostrom` **** - The name of the account in cyber **** - Validator address. Starts with `cybervaloper` **** - The part of illiquid tokens that you want to unbond or redelegate. Must be a fraction >0 and <=1 **** - The current version of the chain (bostrom). ## General commands ### Show all validators Return the set of all active and jailed validators: ```bash cyber query staking validators ``` ### Show chain status Return general chain information: ```bash cyber status ``` ### Distribution params ```bash cyber query distribution params ``` ### Staking params Chain staking info: ```bash cyber query staking params ``` ### Staking pool ```bash cyber query staking pool ``` ## Account management ### Import an account with a seed phrase and store it in the local keystore ```bash cyber keys add --recover ``` ### Create a new account ```bash cyber keys add ``` ### Show account information Name, address and the public key of the current account ```bash cyber keys show ``` ### Show account balance Return account number and amount of tokens. ```bash cyber query bank balances ``` ### List existing keys Return all the existing keys in cyber: ```bash cyber keys list ``` ### Delete account from cyber ```bash cyber keys delete ``` ### Keyring manipulation settings **Important note**: Starting with v.38, Cosmos-SDK uses os-native keyring to store all of your keys. We've noticed that in certain cases it does not work well by default (for example if you don't have any GUI installed on your machine). If during the execution `cyber keys add` command, you are getting this type of error: ```bash panic: No such interface 'org.freedesktop.DBus.Properties' on object at path / goroutine 1 [running]: github.com/cosmos/cosmos-sdk/crypto/keys.keyringKeybase.writeInfo(0x1307a18, 0x1307a10, 0xc000b37160, 0x1, 0x1, 0xc000b37170, 0x1, 0x1, 0x147a6c0, 0xc000f1c780, ...) /root/go/pkg/mod/github.com/cosmos/cosmos-sdk@v0.38.1/crypto/keys/keyring.go:479 +0x38c github.com/cosmos/cosmos-sdk/crypto/keys.keyringKeybase.writeLocalKey(0x1307a18, 0x1307a10, 0xc000b37160, 0x1, 0x1, 0xc000b37170, 0x1, 0x1, 0x147a6c0, 0xc000f1c780, ...) /root/go/pkg/mod/github.com/cosmos/cosmos-sdk@v0.38.1/crypto/keys/keyring.go:465 +0x189 github.com/cosmos/cosmos-sdk/crypto/keys.baseKeybase.CreateAccount(0x1307a18, 0x1307a10, 0xc000b37160, 0x1, 0x1, 0xc000b37170, 0x1, 0x1, 0x146aa00, 0xc000b15630, ...) /root/go/pkg/mod/github.com/cosmos/cosmos-sdk@v0.38.1/crypto/keys/keybase_base.go:171 +0x192 github.com/cosmos/cosmos-sdk/crypto/keys.keyringKeybase.CreateAccount(...) /root/go/pkg/mod/github.com/cosmos/cosmos-sdk@v0.38.1/crypto/keys/keyring.go:107 github.com/cosmos/cosmos-sdk/client/keys.RunAddCmd(0xc000f0b400, 0xc000f125f0, 0x1, 0x1, 0x148dcc0, 0xc000aca550, 0xc000ea75c0, 0xc000ae1c08, 0x5e93b7) /root/go/pkg/mod/github.com/cosmos/cosmos-sdk@v0.38.1/client/keys/add.go:273 +0xa8b ... etc ``` You will have to use another keyring backend to keep your keys. In that case you'll have to use file based keyring by adding the `--keyring-backend file` option to every key manipulation command: ```bash cyber keys add key_name --keyring-backend file ``` That means that you've set your keyring-backend to a local file. *Note*, in this case, all the keys in your keyring will be encrypted using the same password. If you would like to set up a unique password for each key, you should set a unique `--home` folder for each key. To do that, just use `--home=//` with setup keyring backend and at all interactions with keys when using cyber: ```bash cyber keys add --keyring-backend file --home=// cyber keys list --home=// ``` ### Send tokens ```bash cyber tx bank send [from_key_or_address] [to_address] [amount] \ --from= \ --chain-id=bostrom ``` ### Linking content Only IPFS hashes are available to use as CIDs ```bash cyber tx graph cyberlink [cid-from] [cid-to] [flags] \ --from= \ --chain-id=bostrom ``` Real command example: ```bash cyber tx graph cyberlink QmWZYRj344JSLShtBnrMS4vw5DQ2zsGqrytYKMqcQgEneB QmfZwbahFLTcB3MTMT8TA8si5khhRmzm7zbHToo4WVK3zn --from fuckgoogle --chain-id bostrom --yes ``` ## Validator commands ### Get all validators ```bash cyber query staking validators ``` ### State of a current validator ```bash cyber query staking validator ``` ### Return all delegations to a validator ```bash cyber query staking delegations-to ``` ### Edit the commission in an existing validator account ```bash cyber tx staking edit-validator \ --from= \ --commission-rate= \ --chain-id=bostrom ``` ### Withdraw the commission for any delegation ```bash cyber tx distribution withdraw-rewards --commission \ --from= \ --chain-id=bostrom ``` ### Edit the site and description for an existing validator account ```bash cyber tx staking edit-validator \ --from= \ --details="" \ --website= \ --chain-id=bostrom ``` ### Unjail a validator previously jailed for downtime ```bash cyber tx slashing unjail --from= --chain-id=bostrom ``` ### Get info about a redelegation process from a validator ```bash cyber query staking redelegations-from ``` ## Delegator commands ### Return distribution delegator rewards for a specified validator ```bash cyber query distribution rewards ``` ### Return delegator shares for the specified validator ```bash cyber query staking delegation ``` ### Return all delegations made from a delegator ```bash cyber query staking delegations ``` ### Return all unbonding delegations from a validator ```bash cyber query staking unbonding-delegations-from ``` ### Withdraw rewards for any delegation ```bash cyber tx distribution withdraw-rewards \ --from= \ --chain-id=bostrom ``` ### Withdraw all delegation rewards ```bash cyber tx distribution withdraw-all-rewards \ --from= \ --chain-id=bostrom ``` ### Change the default withdrawal address for rewards associated with an address ```bash cyber tx distribution set-withdraw-addr \ --from= \ --chain-id=bostrom ``` ### Delegate liquid tokens to a validator ```bash cyber tx staking delegate \ --from= \ --chain-id=bostrom ``` ### Redelegate illiquid tokens from one validator to another in absolute BOOT value > There is a 4-day unbonding period ```bash cyber tx staking redelegate \ --from= \ --chain-id=bostrom ``` ### Redelegate illiquid tokens from one validator to another in percentages ```bash cyber tx staking redelegate --from= \ --chain-id=bostrom ``` ### Unbond shares from a validator in absolute BOOT value > 8 days for unbonding ```bash cyber tx staking unbond --from= \ --chain-id=bostrom ``` ### Unbond shares from a validator in percentages > 8 days for unbonding ```bash cyber tx staking unbond --from= \ --chain-id=bostrom ``` ### Get info about the unbonding delegation process to any validator ```bash cyber query staking unbonding-delegation ``` ### Get info about the unbonding delegation process to all unbonded validators ```bash cyber query staking unbonding-delegation ``` ### Get info about redelegation process from to current validator ```bash cyber query staking redelegation ``` ### Get the info about all the redelegation processes by a delegator ```bash cyber query staking redelegations ``` ## Governance and voting ### Query specific proposal ```bash cyber q gov proposal ``` ### Query all proposals ```bash cyber q gov proposals ``` ### Query votes on proposal ```bash cyber q gov votes ``` ### Query parameters from governance module ```bash cyber q gov params ``` ### Vote for specific proposal ```bash cyber tx gov vote \ --from= \ --chain-id=bostrom ``` ### Submit text proposal ```bash cyber tx gov submit-proposal --title="Test Proposal" --description="My awesome proposal" --type="Text" --deposit="10boot" \ --from= \ --chain-id=bostrom ``` ### Submit community spend proposal ```bash cyber tx gov submit-proposal community-pool-spend \ --from= \ --chain-id=bostrom ``` Where `proposal.json` is a file, structured in following way: ```json { "title": "Community Pool Spend", "description": "Pay me some boots!", "recipient": "bostrom1s5afhd6gxevu37mkqcvvsj8qeylhn0rz46zdlq", "amount": [ { "denom": "boot", "amount": "10000" } ], "deposit": [ { "denom": "boot", "amount": "10000" } ] } ``` ### Submit chain parameters change proposal ```bash cyber tx gov submit-proposal param-change \ --from= \ --chain-id=bostrom ``` Where `proposal.json` is a file, structured in following way: ```json { "title": "Staking Param Change", "description": "Update max validators", "changes": [ { "subspace": "staking", "key": "MaxValidators", "value": 105 } ], "deposit": [ { "denom": "stake", "amount": "10000" } ] } ``` Few examples of real param-change proposals: - Change max block bandwidth: ```json { "title": "Insrease max block bandwidth to 500000", "description": "Increase max block bandwidth to 500000.\n", "changes": [ { "subspace": "bandwidth", "key": "MaxBlockBandwidth", "value": "500000" } ], "deposit": "10000boot" } ``` - Increase max block gas: ```json { "title": "Increase max gasprice", "description": "Increase maximum block gas.\n", "changes": [ { "subspace": "baseapp", "key": "BlockParams", "value": '"{\n \"max_bytes\": \"22020096\", \n \"max_gas\": \"200000000\",\n \"time_iota_ms\": \"1000\"\n }"' } ], "deposit": "10000boot" } ``` - Change rank calculation window: ```json { "title": "Change rank calculation window to 25", "description": "Increase rank calculation window from every 5 to every 25 blocks.\n", "changes": [ { "subspace": "rank", "key": "CalculationPeriod", "value": "25" } ], "deposit": "10000boot" } ``` ## Liquidity and pools Cyber has Gravity-DEX module implemented, so it is possible to create pools, swap tokens and add\remove liquidity to exisitng pools: ```bash Liquidity transaction subcommands Usage: cyber tx liquidity [flags] cyber tx liquidity [command] Available Commands: create-pool Create liquidity pool and deposit coins deposit Deposit coins to a liquidity pool swap Swap offer coin with demand coin from the liquidity pool with the given order price withdraw Withdraw pool coin from the specified liquidity pool ``` ### Create liquidity pool This example creates a liquidity pool of pool-type 1 (two coins) and deposits 2000000milliampere and 200000000000boot. New liquidity pools can be created only for coin combinations that do not already exist in the network. [pool-type]: The id of the liquidity pool-type. The only supported pool type is 1 [deposit-coins]: The amount of coins to deposit to the liquidity pool. The number of deposit coins must be 2 in pool type 1. Example: ```bash cyber tx liquidity create-pool 1 2000000milliampere,200000000000boot \ --from=mykey \ --chain-id=bostrom \ --yes ``` ### Deposit tokens to liquidity pool Deposit coins a liquidity pool. This deposit request is not processed immediately since it is accumulated in the liquidity pool batch. All requests in a batch are treated equally and executed at the same swap price. Example: ```bash cyber tx liquidity deposit 1 100000000milliampere,50000000000boot \ --from=mykey \ --chain-id=bostrom ``` This example request deposits 100000000milliampere and 50000000000boot to pool-id 1. Deposits must be the same coin denoms as the reserve coins. [pool-id]: The pool id of the liquidity pool [deposit-coins]: The amount of coins to deposit to the liquidity pool ### Swap coins Swap offer coin with demand coin from the liquidity pool with the given order price. This swap request is not processed immediately since it is accumulated in the liquidity pool batch. All requests in a batch are treated equally and executed at the same swap price. The order of swap requests is ignored since the universal swap price is calculated in every batch to prevent front running. The requested swap is executed with a swap price that is calculated from the given swap price function of the pool, the other swap requests, and the liquidity pool coin reserve status. Swap orders are executed only when the execution swap price is equal to or greater than the submitted order price of the swap order. Example: ```bash cyber tx liquidity swap 1 1 50000000boot hydrogen 0.019 0.003 \ --from=mykey \ --chain-id=bostrom ``` For this example, imagine that an existing liquidity pool has with 1000000000hydrogen and 50000000000boot. This example request swaps 50000000boot for at least 950000hydrogen with the order price of 0.019 and swap fee rate of 0.003. A sufficient balance of half of the swap-fee-rate of the offer coin is required to reserve the offer coin fee. The order price is the exchange ratio of X/Y, where X is the amount of the first coin and Y is the amount of the second coin when their denoms are sorted alphabetically. Increasing order price reduces the possibility for your request to be processed and results in buying hydrogen at a lower price than the pool price. For explicit calculations, The swap fee rate must be the value that is set as liquidity parameter in the current network. The only supported swap-type is 1. For the detailed swap algorithm, see https://github.com/gravity-devs/liquidity [pool-id]: The pool id of the liquidity pool [swap-type]: The swap type of the swap message. The only supported swap type is 1 (instant swap). [offer-coin]: The amount of offer coin to swap [demand-coin-denom]: The denomination of the coin to exchange with offer coin [order-price]: The limit order price for the swap order. The price is the exchange ratio of X/Y where X is the amount of the first coin and Y is the amount of the second coin when their denoms are sorted alphabetically [swap-fee-rate]: The swap fee rate to pay for swap that is proportional to swap amount. The swap fee rate must be the value that is set as liquidity parameter in the current network. Usage: ```bash cyber tx liquidity swap [pool-id] [swap-type] [offer-coin] [demand-coin-denom] [order-price] [swap-fee-rate] [flags] ``` ### Withdraw tokens from liquidity pool Withdraw pool coin from the specified liquidity pool. This swap request is not processed immediately since it is accumulated in the liquidity pool batch. All requests in a batch are treated equally and executed at the same swap price. Example: ```bash cyber tx liquidity withdraw 1 10000pool96EF6EA6E5AC828ED87E8D07E7AE2A8180570ADD212117B2DA6F0B75D17A6295 \ --from=mykey \ --chain-id=bostrom ``` This example request withdraws 10000 pool coin from the specified liquidity pool. The appropriate pool coin must be requested from the specified pool. [pool-id]: The pool id of the liquidity pool [pool-coin]: The amount of pool coin to withdraw from the liquidity pool Usage: ```bash cyber tx liquidity withdraw [pool-id] [pool-coin] [flags]\ --from= \ --chain-id=bostrom ``` ### Query existing pools Query details of a liquidity pool ```bash cyber query liquidity pool 1 ``` Example (with pool coin denom): ```bash cyber query liquidity pool --pool-coin-denom=[denom] ``` Query details about all liquidity pools on a network. Example: ```bash cyber query liquidity pools ``` ## ================================================ FILE: docs/upgrade-plan.md ================================================ # go-cyber Dependency Upgrade Plan This document describes the upgrade path for go-cyber's core dependencies from the current v7 stack to the latest available versions, covering what each step unlocks, what breaks, and the recommended execution order. ## Current Stack (go-cyber v7) | Component | Version | Notes | |---|---|---| | Cosmos SDK | v0.47.16 | Forked as `cybercongress/cosmos-sdk` | | CometBFT | v0.37.18 | Tachyon security fix applied | | IBC-Go | v7.10.0 | | | CosmWasm/wasmd | v0.46.0 | | | CosmWasm/wasmvm | v1.5.9 | CosmWasm 1.x runtime | | Packet-Forward-Middleware | v7.3.0 | | | async-icq | v7.1.1 | | | ibc-hooks | v7.0.0 | | | Go | 1.22.7 | | ## Target Stack (Latest Stable) | Component | Version | Notes | |---|---|---| | Cosmos SDK | **v0.53.6** | Released 2026-02-10 | | CometBFT | **v0.38.21** | Released 2026-01-23 | | IBC-Go | **v10.5.0** | IBC Eureka / IBC v2 | | CosmWasm/wasmd | **v0.61.8** | Released 2026-02-11 | | CosmWasm/wasmvm | **v3.0.3** | CosmWasm 3.0 runtime | | Packet-Forward-Middleware | **v10.1.0** | | | async-icq | **v8.0.0** | No v10 release yet | | ibc-hooks | **v8.0.0** | No v10 release yet | | Go | 1.23.2+ | Required by SDK v0.53 | --- ## Roadmap: Priorities and Execution Order Everything we want to do, sorted by dependency chain and impact. Three phases: what we can ship **now** on SDK v0.47, what requires the **SDK v0.50 upgrade**, and what comes **after v0.53**. ### Phase 0 — Now (SDK v0.47, no consensus change) These items can ship as point releases or soft-fork patches. No chain upgrade required. | # | Item | Scope | Depends On | |---|------|-------|------------| | 0.1 | **Graph Streaming gRPC** — `GraphSnapshot`, `CyberlinksAfter`, `CyberlinksByParticle` endpoints | `x/graph` new queries | — | | 0.2 | **Native Graph Query Endpoints** — `CyberlinksByNeuron`, `ParticlesByNeuron` (replace cyberindex for basic queries) | `x/graph` new queries | — | | 0.3 | **cyb (go-cyb) Tray App** — orchestrator managing `cyber` + `ipfs`, tray icon, health polling, Start/Stop | new repo `go-cyb` | — | | 0.4 | **Embedded Dashboard** — single HTML page on `:26660`, node/IPFS/graph/rank stats | `cyber` binary, `//go:embed` | — | | 0.5 | **IPFS Sidecar: Kubo Lifecycle** — `cyber init` creates IPFS repo, `cyber start` manages Kubo subprocess | `app/` startup code | — | | 0.6 | **`cyber service` command** — systemd/launchd install/start/stop for headless servers | `cmd/cyber/` | — | | 0.7 | **CPU Rank Optimization** — SIMD, goroutine parallelism, memoize per-CID stake | `x/rank/keeper/calculate_cpu.go` | — | | 0.8 | **Installer & Packaging** — `get.cyber.page` script, GoReleaser update, Homebrew formula | build/release infra | 0.3, 0.5 | | 0.9 | **Graph Inference: Embeddings + Retrieval** — cid2vec from topology (TransE/RotatE), HNSW index, Similar/Predict gRPC | `scripts/`, `x/inference` | 0.1 | | 0.10 | **Graph Inference: LLM Training + Native Inference** — resolve content via IPFS, fine-tune Llama 3B (LoRA), llama-server sidecar, Ask/AskStream gRPC, RAG pipeline | `scripts/`, `x/inference`, sidecar | 0.5, 0.9 | | 0.11 | **Query-time Negentropy** *(done)* — `J(π) = log₂(n) − H(π)` from rank distribution | `x/rank` gRPC | ✅ committed | | 0.12 | **Dead Code Removal** *(done)* — karma/entropy/luminosity kernels removed | `x/rank/cuda/rank.cu` | ✅ committed | **Priority order:** 0.1 → 0.3 → 0.5 → 0.4 → 0.2 → 0.9 → 0.10 → 0.6 → 0.7 → 0.8 Rationale: Graph streaming (0.1) is the foundation for light clients, inference training, and any external tool. The tray app (0.3) and IPFS sidecar (0.5) together make "download → run → it works" possible. Dashboard (0.4) gives visual feedback. Native queries (0.2) start replacing cyberindex. Inference training (0.9) needs graph streaming, then native inference (0.10) makes it available on the node. Service management (0.6) and CPU optimization (0.7) are independent polish items. Packaging (0.8) wraps everything for distribution. ### Phase 1 — SDK v0.50 Chain Upgrade All of these require the consensus-breaking upgrade to Cosmos SDK v0.50 + CometBFT v0.38. | # | Item | Scope | Depends On | |---|------|-------|------------| | 1.0 | **Remove `x/liquidity` module** — delete module code, drop store key via `StoreUpgrades.Deleted`, clean up params and codec registrations | `x/liquidity`, `app/`, upgrade handler | — | | 1.1 | **SDK v0.47 → v0.50 migration** — ABCI 2.0, FinalizeBlock, context.Context keepers, x/params removal | all modules, `app/` | 1.0 | | 1.2 | **Eliminate Cosmos SDK fork** — remove `cybercongress/cosmos-sdk` replace directive | `go.mod` | 1.1 | | 1.3 | **Snapshot Extensions** — graph + rank data in state-sync snapshots (instant sync without GPU) | `x/graph`, `x/rank` snapshotters | 1.1 | | 1.4 | **Height Index for Incremental Sync** — `[0x07][Height][Seq]` secondary index for O(k) `CyberlinksAfter` | `x/graph` store | 1.1 | | 1.5 | **Rank Computation Fixes** — div-by-zero guard (CPU), overflow protection, dangling node decision | `x/rank` | 1.1 | | 1.6 | **Multi-chain Binary (Phase A)** — configurable bech32, denoms from genesis, chain-id switch in upgrade handlers | `app/`, `types/` | 1.1 | | 1.7 | **ABCIListener Indexing Plugin** — embedded SQLite/DuckDB via ADR-038, replace cyberindex | `app/`, new plugin | 1.1 | | 1.8 | **Space-Pussy Upgrade (Phase B)** — in-place upgrade v0.45→v0.50 using unified binary | upgrade handler | 1.1, 1.6 | | 1.9 | **IBC-Go v7 → v8, wasmd v0.46 → v0.54, wasmvm v1.5 → v2.2** | deps | 1.1 | | 1.10 | **Graph Inference: On-Chain Commitment** — `MsgCommitModel`, validator verification, embedding merkle tree | `x/inference` | 0.10, 1.1 | | 1.11 | **Personal Networks (`cyber network`)** — one-command launch of a private chain, peer join, graph sync between machines | `cmd/cyber/`, `app/` | 1.6 | | 1.12 | **Inter-Knowledge Protocol (IKP): Basic Link Sync** — `x/ikp` IBC module, SyncCyberlinks packet, derived neurons, push links between chains | `x/ikp`, new module | 1.1, 1.9 | **Priority order:** 1.0 → 1.1 → 1.2 → 1.9 → 1.5 → 1.3 → 1.4 → 1.6 → 1.11 → 1.12 → 1.7 → 1.8 → 1.10 Rationale: Liquidity removal (1.0) comes first — it is a standalone consensus-breaking change that eliminates dead module code, its SDK fork dependency (`RegisterCustomTypeURL`), and simplifies the subsequent SDK migration. The SDK migration (1.1) unlocks everything else. Fork elimination (1.2) and dep updates (1.9) are part of the same push. Rank fixes (1.5) are consensus-breaking so bundle with the upgrade. Snapshots (1.3) and height index (1.4) make light client experience good. Multi-chain binary (1.6) is prerequisite for personal networks (1.11). IKP (1.12) enables graph sync between personal networks and bostrom — requires IBC v8 from 1.9. ABCIListener indexing (1.7) replaces cyberindex. Inference on-chain commitment (1.10) makes the model verifiable. ### Phase 2 — SDK v0.53 + CosmWasm 3.0 | # | Item | Scope | Depends On | |---|------|-------|------------| | 2.1 | **SDK v0.50 → v0.53 migration** — IBC Eureka, unordered TXs, x/epochs, auth PreBlocker | all modules | 1.1 | | 2.2 | **IBC-Go v8 → v10 (IBC Eureka)** — Ethereum connectivity, remove capabilities module | IBC wiring | 2.1 | | 2.3 | **CosmWasm 3.0** — IBCv2 entrypoints, Uint256 balances, wasmd v0.61, wasmvm v3.0 | deps | 2.1 | | 2.4 | **Schema/Indexer Framework** — `HasModuleCodec` for auto-generated SQL tables | custom modules | 2.1, 1.7 | | 2.5 | **wgpu Prototype (f32)** — port 4 CUDA kernels to WGSL compute shaders, test precision | `x/rank` | 0.7 | | 2.6 | **Light Client with Rank Proofs** — `QueryRankWithProof`, `--rank-proofs` flag, full merkle tree | `x/rank` | 1.3 | | 2.7 | **Graph Inference: Incremental Training + 7B Model** — daily LoRA adapters, weekly full retrain, 7B option for validators | `x/inference` | 0.10 | | 2.8 | **IKP: Pull Sync + Rank Signals** — RequestSubgraph, selective filters, ShareRankSignal, trust governance | `x/ikp` | 1.12 | ### Phase 3 — Long-term / Research | # | Item | Notes | |---|------|-------| | 3.1 | **Rust Migration Path** — CosmWasm-first (move logic to contracts), then pure Rust ABCI | Research done: Penumbra, Namada, Nomic as references | | 3.2 | **wgpu f64** — native on Vulkan/DX12, emulated double-single on Metal | Depends on 2.5 precision results | | 3.3 | **Graph Store Separation** — flat append-only store for cyberlinks, only merkle root in IAVL | SDK v0.53 pluggable storage | | 3.4 | **SDK v0.54 + CometBFT v0.39** — BlockSTM, BLS signing, concurrent ABCI | Planned Q2 2026 | | 3.5 | **macOS .dmg / Linux .deb** — native OS packages for cyb | Depends on 0.3, 0.8 | ### Summary Table | Phase | Items | Consensus Change | Key Deliverable | |-------|-------|:----------------:|-----------------| | **0** | 12 items (2 done) | No | Graph sync + Desktop app + IPFS sidecar + **LLM inference from graph** | | **1** | 13 items | Yes (SDK v0.50) | Liquidity removal + full SDK upgrade + snapshot sync + rank fixes + **personal networks** + **IKP basic sync** | | **2** | 8 items | Yes (SDK v0.53) | IBC Eureka + CosmWasm 3.0 + wgpu + **IKP pull/rank signals** | | **3** | 5 items | TBD | Rust migration + advanced GPU + native packages | --- ## Compatibility Matrix All versions in a row must be used together. Mixing across rows is not supported. | SDK | CometBFT | IBC-Go | wasmd | wasmvm | CosmWasm | |---|---|---|---|---|---| | v0.47.x (current) | v0.37.x | v7.x | v0.46.x | v1.5.x | 1.x | | **v0.50.x** | **v0.38.x** | **v8.x** | v0.50 - v0.54 | v1.5 - v2.2.x | 2.0 - 2.2 | | **v0.53.x** | **v0.38.x** | **v10.x** | v0.60 - v0.61 | v2.3 - v3.0.x | 2.3 - 3.0 | | v0.54.x (planned Q2 2026) | v0.39.x | v11.x | TBD | TBD | TBD | Skipped versions that were never released: SDK v0.48/v0.49/v0.51/v0.52, IBC-Go v9, wasmd v0.47-v0.49, CometBFT v1.x (retracted). --- ## Upgrade Path: Two Steps The upgrade must happen in two sequential steps. There is no way to skip Step 1. ### Step 1: SDK v0.47 -> v0.50 (Major) This is the largest and hardest step. All four core dependencies change simultaneously. #### Version Targets for Step 1 | Component | From | To | |---|---|---| | Cosmos SDK | v0.47.16 | **v0.50.15** | | CometBFT | v0.37.18 | **v0.38.21** | | IBC-Go | v7.10.0 | **v8.8.0** | | wasmd | v0.46.0 | **v0.54.6** | | wasmvm | v1.5.9 | **v2.2.6** | | PFM | v7.3.0 | **v8.2.0** | | async-icq | v7.1.1 | **v8.0.0** | | ibc-hooks | v7.0.0 | **v8.0.0** | | Go | 1.22.7 | 1.22+ (no change required) | #### Breaking Changes in Step 1 **ABCI 2.0 (CometBFT v0.37 -> v0.38)** - `BeginBlock`, `DeliverTx`, and `EndBlock` are removed. Replaced by a single `FinalizeBlock` method. - New `ExtendVote` and `VerifyVoteExtension` methods added (vote extensions). - CometBFT package renames: `client.TendermintRPC` -> `client.CometRPC`, `client/grpc/tmservice` -> `client/grpc/cmtservice`. **Cosmos SDK v0.50 Module Interface Overhaul** - All keeper methods now accept `context.Context` instead of `sdk.Context`. - `BeginBlock` signature changes from `(sdk.Context, abci.RequestBeginBlock)` to `(context.Context) error`. - `EndBlock` no longer returns `[]abci.ValidatorUpdate`; returns `error` instead. - Messages no longer need `ValidateBasic()` or `GetSignBytes()` implementations. Validation moves to message server handlers. - `GetSigners()` replaced by protobuf `cosmos.msg.v1.signer` field annotations. **App Wiring** - Global `ModuleBasics` variable eliminated; use `module.NewBasicManagerFromManager()`. - Modules accept `KVStoreService` instead of `StoreKey` (wrap with `runtime.NewKVStoreService()`). - New `PreBlocker` concept: upgrade module must be in `PreBlockers`. - Store upgrades required for new modules `circuit` and `feeibc` (panic without them). **x/params Deprecation** - `x/params` is deprecated. All SDK modules store parameters directly via `MsgUpdateParams`. - Custom modules must migrate their parameters out of `x/params`. - v0.50 is the mandatory migration point; future versions drop `x/params` migration support entirely. **Database Backends** - ClevelDB, BoltDB, and BadgerDB are no longer supported. **wasmvm v2 (v1.5 -> v2.2)** - Import path changes from `github.com/CosmWasm/wasmvm` to `github.com/CosmWasm/wasmvm/v2`. - Gas values reduced by 1000x. Any hardcoded gas values or gas-related parameters need recalibration. - `InstantiateContractCosts` renamed to `SetupContractCost`. - Backward compatible for existing contracts: contracts compiled with cosmwasm-std ^1.0.0 continue to work. **IBC-Go v8** - `PortKeeper` field changed to `*portkeeper.Keeper` (pointer type). - `NewKeeper` functions require an authority identifier parameter. - `SerializeCosmosTx` / `DeserializeCosmosTx` take an extra `encoding` parameter. - Channel upgradability introduced (new channel states: `FLUSHING`, `FLUSHCOMPLETE`). **go-cyber Specific: Forked Cosmos SDK** - The fork `cybercongress/cosmos-sdk` must be rebased onto SDK v0.50.x. - This is the single largest piece of work in the entire upgrade. The v0.50 SDK has fundamental changes to BaseApp, module interfaces, and the ABCI layer. - All cyber-specific modules must migrate keepers to `context.Context`, remove legacy `BeginBlock`/`EndBlock`, and update parameter management. #### What Step 1 Unlocks | Capability | Description | |---|---| | **ABCI 2.0 / FinalizeBlock** | Simplified block processing, foundation for all advanced features | | **Vote Extensions** | Validators inject custom data into consensus (oracles, MEV protection, encrypted mempools). Rujira reported oracle latency dropping from 30s to 6s | | **Optimistic Execution** | Block execution runs in parallel with voting. Sei Network showed 50% block time reduction (~300ms saved) | | **IAVL v1** | ~7x improvement in set operations (1,800 -> 12,225 leaves/sec), reduced storage overhead via orphan removal | | **AutoCLI** | Automatic CLI command generation from gRPC definitions, no more hand-written CLI boilerplate | | **SIGN_MODE_TEXTUAL** | Human-readable transaction signing for hardware wallets | | **CosmWasm 2.x** | `CosmosMsg::Any`, `QueryRequest::Grpc`, IBC callbacks (ADR-8), secp256r1/BLS12-381 crypto, MessagePack support | | **IBC Channel Upgradability** | Upgrade existing IBC channels without closing them | --- ### Step 2: SDK v0.50 -> v0.53 + CosmWasm 3.0 (Moderate) This step is significantly easier. The SDK v0.50 -> v0.53 upgrade was designed to be non-breaking and was described by Cosmos Labs as requiring "only 2 lines of code changed" for many chains. #### Version Targets for Step 2 | Component | From | To | |---|---|---| | Cosmos SDK | v0.50.15 | **v0.53.6** | | CometBFT | v0.38.21 | v0.38.21 (no change) | | IBC-Go | v8.8.0 | **v10.5.0** | | wasmd | v0.54.6 | **v0.61.8** | | wasmvm | v2.2.6 | **v3.0.3** | | PFM | v8.2.0 | **v10.1.0** | | async-icq | v8.0.0 | v8.0.0 (no v10 release yet) | | ibc-hooks | v8.0.0 | v8.0.0 (no v10 release yet) | | Go | 1.22+ | **1.23.2+** | #### Breaking Changes in Step 2 **Cosmos SDK v0.53** - `x/auth` module now has a `PreBlocker` that must be added to `SetOrderPreBlockers` alongside the upgrade module. - All modules split into separate `go.mod` files (`cosmossdk.io/x/{moduleName}`). - Address codecs and bech32 prefixes must be supplied in `client.Context`. **IBC-Go v10 (IBC Eureka)** - **Capabilities module removed entirely.** Remove `CapabilityKeeper`, all scoped keepers, and related store keys. - **Fee middleware (ICS-29) removed entirely.** Remove `IBCFeeKeeper` from App struct, module account permissions, and store keys. - **Channel upgradability removed** (was added in v8, removed in v10). - Import paths change from `/v8/` to `/v10/`. - Light client modules need explicit wiring in keeper construction. - IBC v2 stack must be wired alongside the classic IBC stack. **CosmWasm 3.0 / wasmvm v3** - `Coin::amount` changed from `Uint128` to `Uint256` in the contract API. - `serde-json-wasm` replaced with standard `serde_json`. - `MemoryStorage` removed (use `MockStorage`). - `BankQuery::AllBalances` and `IbcQuery::ListChannels` removed. - Backward compatible: contracts compiled with cosmwasm-std ^1.0.0 and ^2.0.0 continue to work on CosmWasm 3.0 chains. **Potential Blockers** - `async-icq` and `ibc-hooks` do not have v10 releases as of February 2026. If go-cyber depends on these, this may require using unreleased branches or waiting for releases. #### What Step 2 Unlocks | Capability | Description | |---|---| | **IBC Eureka / IBC v2** | Ethereum connectivity via ZK light clients. Any chain connected to the Cosmos Hub can reach Ethereum permissionlessly. Transfer WETH, WBTC, stablecoins for ~$1 in fees | | **IBC v2 Simplified Setup** | 3-step handshake instead of 8-10 steps. Dramatically cheaper channel establishment | | **CosmWasm 3.0 IBCv2 Entrypoints** | Native `ibc2_packet_send`, `ibc2_packet_receive`, `ibc2_packet_ack`, `ibc2_packet_timeout` in smart contracts | | **Unordered Transactions** | Timestamp-based transactions without sequence numbers. Enables concurrent sends from same account (critical for relayers and exchanges) | | **x/epochs** | Cron-job scheduling for periodic on-chain actions | | **x/protocolpool** | Upgraded community pool with continuous fund streaming | | **Wasmer 5.0.6** | Fully FOSS-licensed Wasm runtime | | **CosmWasm cw-schema** | Concise alternative to JSON Schema for contract interfaces | | **Path to IAVLx** | SDK v0.53+ positions for IAVLx storage backend (Q2 2026): 30x faster writes, 20ms commits, ~25,000 ops/sec | --- ## Future: Step 3 (SDK v0.54, planned Q2 2026) Not yet released. When available, this step would bring: | Component | Version | Key Feature | |---|---|---| | Cosmos SDK | v0.54.x | BlockSTM parallel execution, x/poa | | CometBFT | v0.39.x | BLS signing, concurrent ABCI | | IBC-Go | v11.x | TBD | | IAVLx | New | 30x write improvement, 20ms commits | Key capabilities: - **BlockSTM**: Parallel transaction execution. Internal testing showed doubled TPS. - **BLS Signing**: Aggregated validator signatures for reduced block size and faster verification. - **Native Proof of Authority**: Token-free PoA with migration path to PoS via `x/poa`. - **Target**: 5,000 TPS and 500ms block times sustained in production by Q4 2026. --- ## Why Upgrade: Summary of Benefits ### Performance | Metric | Current (SDK v0.47) | After Step 1 (SDK v0.50) | After Step 2 (SDK v0.53) | |---|---|---|---| | IAVL set ops/sec | ~1,800 | ~12,225 (IAVL v1) | ~25,000 (IAVLx, when ready) | | Block execution | Sequential | Optimistic (50% faster) | Optimistic | | ABCI calls per block | 3+ (BeginBlock, DeliverTx..., EndBlock) | 1 (FinalizeBlock) | 1 (FinalizeBlock) | ### Security - CometBFT v0.37.x has received critical security advisories (ASA-2024-001, ASA-2025-003). While patches exist for v0.37, the line receives only critical fixes and is approaching end of life. - SDK v0.53.3 fixed a chain-halting bug in `x/distribution` (GHSA-p22h-3m2v-cmgh). - The `x/params` module (used in v0.47) is a historical attack vector; direct parameter storage in modules is more secure. ### Interoperability | Feature | Current | After Step 1 | After Step 2 | |---|---|---|---| | IBC Classic | Yes | Yes | Yes | | IBC Eureka (Ethereum) | No | No | **Yes** | | CosmWasm contract compatibility | 1.x only | 1.x + 2.x | 1.x + 2.x + **3.x** | | IBC Callbacks in contracts | No | **Yes** (CosmWasm 2.1) | Yes | | IBCv2 in contracts | No | No | **Yes** (CosmWasm 3.0) | | Vote extensions (oracles) | No | **Yes** | Yes | | Unordered transactions | No | No | **Yes** | ### Ecosystem Relevance Chains that have already upgraded to SDK v0.53: Cosmos Hub, Babylon, MANTRA, Warden, Cronos, Akash Network. Osmosis remains on SDK v0.50.x. Smart contracts and dApps targeting CosmWasm 2.0+ features will not deploy on chains running SDK < v0.50. As the ecosystem moves forward, staying on v0.47 means growing incompatibility with new contracts and tooling. --- ## Cosmos SDK Fork Analysis The `go.mod` replace directive points to a fork: `github.com/cybercongress/cosmos-sdk` (branch `bostrom-47-custom`). The fork contains **exactly 4 commits** (5 files changed) on top of upstream `release/v0.47.x`: ### Change 1: `RegisterCustomTypeURL` on InterfaceRegistry Interface **Files:** `codec/types/interface_registry.go`, `client/grpc_query.go` The upstream SDK v0.47 has `RegisterCustomTypeURL` as a method on the **concrete struct** `interfaceRegistry`, but it is **not declared on the `InterfaceRegistry` interface**. The fork promotes it to the interface level. **Why:** The `x/liquidity` module registers messages under legacy Tendermint-namespaced type URLs for backward compatibility: ```go // x/liquidity/types/codec.go registry.RegisterCustomTypeURL((*sdk.Msg)(nil), "/tendermint.liquidity.v1beta1.MsgCreatePool", &MsgCreatePool{}) registry.RegisterCustomTypeURL((*sdk.Msg)(nil), "/tendermint.liquidity.v1beta1.MsgDepositWithinBatch", &MsgDepositWithinBatch{}) registry.RegisterCustomTypeURL((*sdk.Msg)(nil), "/tendermint.liquidity.v1beta1.MsgWithdrawWithinBatch", &MsgWithdrawWithinBatch{}) registry.RegisterCustomTypeURL((*sdk.Msg)(nil), "/tendermint.liquidity.v1beta1.MsgSwapWithinBatch", &MsgSwapWithinBatch{}) ``` This call goes through the `InterfaceRegistry` interface (not the concrete type), so without the fork change it fails to compile. **Elimination strategy for v0.50+:** Use a type assertion to the concrete `interfaceRegistry` type instead of modifying the interface. Alternatively, check if SDK v0.50+ already exposes this method on the interface. ### Change 2: In-Place Testnet Command **Files:** `server/start.go` (+325 lines), `server/util.go`, `baseapp/options.go` Adds a CLI command `in-place-testnet [newChainID] [newOperatorAddress]` that takes a node's existing mainnet state and rewrites it into a single-validator local testnet. Originally pioneered by Osmosis. Used in `cmd/cyber/cmd/root.go`: ```go server.AddTestnetCreatorCommand(rootCmd, app.DefaultNodeHome, newTestnetApp, addModuleInitFlags) ``` **Elimination strategy for v0.50+:** This feature was upstreamed into later SDK versions. On SDK v0.50+ the fork change is unnecessary — use the native implementation. ### Fork Elimination Plan Both fork changes can be eliminated during the Step 1 upgrade, **removing the need for a forked SDK entirely**: | Fork Change | Action on SDK v0.50+ | |---|---| | `RegisterCustomTypeURL` on interface | No longer needed — `x/liquidity` (sole consumer) is removed in Step 0 (item 1.0) | | In-place testnet command | Use the native SDK implementation (upstreamed from Osmosis) | Eliminating the fork removes the highest-risk item in the upgrade plan and dramatically simplifies future maintenance. --- ## Space-Pussy Network Unification ### Current State of Divergence Space-pussy was forked from go-cyber circa 2022 and has not been updated since. The codebases have diverged massively: | | **go-cyber (bostrom)** | **space-pussy** | |---|---|---| | Cosmos SDK | v0.47.16 | v0.45.5 | | Consensus | CometBFT v0.37.18 | Tendermint v0.34.19 | | IBC-Go | v7.10.0 | v3.0.0 | | CosmWasm/wasmd | v0.46.0 | v0.28.0 | | wasmvm | v1.5.9 | v1.0.0 | | Go | 1.22.7 | 1.17 | | Module path | `github.com/cybercongress/go-cyber/v7` | `github.com/joinresistance/space-pussy` | | Custom modules | bandwidth, clock, cyberbank, dmn, graph, grid, ~~liquidity~~ *(removed in 1.0)*, rank, resources, staking, **tokenfactory** | bandwidth, cyberbank, dmn, graph, grid, rank, resources, staking | | Bech32 prefix | `bostrom` | `pussy` | | Bond denom | `boot` | `pussy` | | Staking denom | `hydrogen` | `liquidpussy` | ### The Problem: Hardcoded Chain Identity The go-cyber binary currently **hardcodes** chain-specific values that prevent it from running space-pussy: - `app/app.go`: `Bech32Prefix = "bostrom"`, `appName = "BostromHub"` - `app/params/const.go`: `DefaultDenom = "boot"`, `BondDenom = "boot"` - `types/coins.go`: `CYB = "boot"`, `SCYB = "hydrogen"`, `VOLT = "millivolt"`, `AMPERE = "milliampere"` - `app/prefix.go`: bech32 prefix sealed at init with `config.Seal()` These constants are referenced across 13+ source files in 6+ modules. A single go-cyber binary cannot currently serve both networks. ### Solution: Configurable Chain Identity + In-Place Upgrade The approach is two-phase: first make go-cyber multi-chain capable, then upgrade space-pussy to use the unified binary. #### Phase A: Make go-cyber Multi-Chain (prerequisite, do during Step 1) Refactor hardcoded chain identity into runtime configuration driven by genesis.json or app config: 1. **Replace hardcoded denoms with genesis-derived values.** Read `bond_denom` from staking params at init. Replace all references to `"boot"`, `"hydrogen"` etc. with configuration read from genesis or module params. 2. **Make bech32 prefix configurable.** Read prefix from app config or derive from chain-id. Set before `config.Seal()`. Osmosis and other chains already do this — the prefix is set based on configuration, not hardcoded. 3. **Use `ctx.ChainID()` in upgrade handlers** for chain-specific migration logic (Osmosis v25 pattern): ```go func CreateUpgradeHandler(...) { return func(ctx sdk.Context, ...) { switch ctx.ChainID() { case "bostrom": // bostrom-specific migrations case "space-pussy": // space-pussy-specific migrations } } } ``` 4. **Remaining modules (tokenfactory, clock) stay included** for both chains. Modules that space-pussy doesn't use are simply empty (no state, no genesis entries). They become available for space-pussy to use in the future. Note: `x/liquidity` is removed in 1.0 before the SDK migration, so it is not present in the unified binary. After this refactor, one `cyber` binary serves any chain with the appropriate genesis.json and config. #### Phase B: Upgrade Space-Pussy to Unified Binary This is an **in-place chain upgrade** submitted via governance on space-pussy. The new binary is the multi-chain go-cyber binary with a massive upgrade handler. The upgrade handler must perform these migrations in order: 1. **Cosmos SDK v0.45 -> v0.47 state migrations** - Migrate all module stores to v0.47 format - Migrate x/params to per-module param storage - Add store keys for new modules (crisis, feegrant, authz changes) 2. **Tendermint v0.34 -> CometBFT v0.37 compatibility** - CometBFT v0.37 can read Tendermint v0.34 state (backward compatible at data level) - ABCI changes are handled by the new binary, not by state migration 3. **IBC-Go v3 -> v7 sequential migrations** - v3 -> v4: ICS-29 fee middleware state - v4 -> v5: ICS-27 interchain accounts controller changes - v5 -> v6: self-managing params migration - v6 -> v7: localhost v2 client migration - Each step has its own SDK migration module that must run in sequence 4. **CosmWasm v0.28 -> v0.46 state migration** - Contract store format changes - Pin/unpin contract code migrations 5. **Add store keys for new modules** - `clock`, `tokenfactory` (empty initial state) - Module stores must be added via `StoreUpgrades.Added` **Precedent**: Akash Network successfully jumped from SDK v0.45 directly to v0.53 in their Mainnet 14 upgrade. The approach was a single large upgrade handler that performed all intermediate migrations. #### Execution Order The space-pussy upgrade happens **after** Step 1 (bostrom -> SDK v0.50) because: 1. The multi-chain refactor is done as part of Step 1 2. Space-pussy can then upgrade directly to the same binary as bostrom 3. Both chains advance together in Step 2 Timeline: ``` Step 1: go-cyber v0.50 + multi-chain refactor │ ├── Deploy on bostrom (upgrade proposal) │ └── Deploy on space-pussy (upgrade proposal, includes v0.45->v0.50 migration) └── space-pussy now runs same binary as bostrom │ Step 2: go-cyber v0.53 + CosmWasm 3.0 │ ├── Deploy on bostrom (upgrade proposal) └── Deploy on space-pussy (upgrade proposal) └── Both chains in sync going forward ``` ### Space-Pussy Upgrade Checklist - [ ] Refactor `app/app.go`, `app/params/const.go`, `types/coins.go` to read denoms from config/genesis - [ ] Make bech32 prefix configurable (read from app config) - [ ] Verify all 13+ source files that reference hardcoded denoms are updated - [ ] Write space-pussy upgrade handler with chain-id conditional logic - [ ] Implement SDK v0.45 -> v0.50 state migrations for space-pussy's state - [ ] Implement IBC v3 -> v8 sequential state migrations - [ ] Implement CosmWasm v0.28 -> v0.54 state migrations - [ ] Add store upgrades for new modules (clock, tokenfactory, circuit, feeibc) - [ ] Test upgrade against space-pussy mainnet state export (in-place testnet) - [ ] Submit upgrade proposal on space-pussy governance - [ ] Coordinate validator binary swap - [ ] Archive `cyberia-to/space-pussy` repo (replaced by go-cyber) --- ## Graph Sync, Topology Export, and Dynamic Rank ### Goal A client can sync the **full graph topology** (all particles + all cyberlinks) quickly and cheaply, then **pull rank dynamically** only for the subgraph it cares about. Everything through go-cyber natively, no external indexer required. ### Current Architecture and Its Limitations The knowledge graph has three layers of state: 1. **Graph store (IAVL):** CID registry, cyberlinks stored as `CompactLink` (24 bytes: `from_cid uint64 + to_cid uint64 + account uint64`), neuron degree counters. IAVL keys: `[0x03][From 8B][Account 8B][To 8B]`, value: `[BlockHeight 8B]`. 2. **In-memory index (`IndexKeeper`):** On startup, full graph loaded from IAVL into RAM as adjacency lists (`outLinks`, `inLinks` maps of `map[CidNumber]map[CidNumber]map[AccNumber]struct{}`). This is what the rank algorithm reads. 3. **Rank values (in-memory only):** `uint64[]` array holding PageRank for every CID. Computed by GPU/CPU every `CalculationPeriod` blocks (default: 5). Only the merkle tree root is stored on-chain — **rank values are never persisted to disk**. **Current bottlenecks:** | Problem | Details | |---|---| | **No graph streaming** | No gRPC endpoint to get all links or particles in bulk. Only `GraphStats()` (counts) and per-particle `Search`/`Backlinks` exist. | | **No incremental sync** | Block height stored in IAVL value, not key — cannot efficiently query "links after height X" without full scan. | | **Snapshot is empty** | Both `GraphSnapshotter.SnapshotExtension()` and `RankSnapshotter.SnapshotExtension()` return `nil` — state-sync snapshots contain no graph or rank data. | | **No index by neuron** | IAVL key is `[From][Account][To]` — can prefix-scan by From, but finding all links by a specific Account requires full scan. | | **No index by particle (To)** | Finding all backlinks to a particle in IAVL requires full scan — the in-memory index does this, but there's no query endpoint for it from IAVL. | | **Rank requires full recalc** | After state-sync restore, node must load entire graph + run full PageRank before serving queries. Requires GPU or hours of CPU time. | ### Target Architecture: Graph Topology Sync + Lazy Rank ``` Light client / indexer / UI: 1. Initial sync: call GraphSnapshot stream → receive full topology (particles + links) 2. Incremental sync: call CyberlinksAfter(height) → receive new links since last sync 3. Rank on demand: call Rank(particle), Search(particle), Backlinks(particle) → node returns pre-computed rank for requested particles 4. Bulk rank: call TopParticles(limit) → top N ranked particles with scores ``` The client builds a local graph representation, and lazily fetches rank values for the subgraph it's exploring. No need to sync all rank values — only what the user is looking at. ### Implementation: Three Levels #### Level 1: Graph Streaming gRPC (Now, No Consensus Change) New gRPC endpoints in `x/graph`, using existing IAVL data: ```protobuf service Query { // Existing rpc GraphStats(QueryGraphStatsRequest) returns (QueryGraphStatsResponse); // NEW: Stream full graph topology in chunks // Server-side streaming: sends batches of 1000 links until complete. // Under the hood: IterateLinks() prefix scan on 0x03. rpc GraphSnapshot(QueryGraphSnapshotRequest) returns (stream QueryGraphSnapshotResponse); // NEW: Incremental sync — links created after a given height. // Implementation: full IAVL scan + filter by height value. // Slow (O(n)) but correct. Secondary index added in Level 2. rpc CyberlinksAfter(QueryCyberlinksAfterRequest) returns (QueryCyberlinksAfterResponse); // NEW: All links from/to a specific particle (paginated). // Uses in-memory index (inLinks/outLinks) — fast, O(degree). rpc CyberlinksByParticle(QueryCyberlinksByParticleRequest) returns (QueryCyberlinksByParticleResponse); } ``` Size estimate for full graph sync (1M links): - Particles: ~34 MB (CID strings + numbers) - Links: ~24 MB (24 bytes × 1M) - Total: ~58 MB uncompressed, ~15 MB with gRPC compression This is the **minimum viable product** for graph sync — can be implemented immediately on SDK v0.47. #### Level 2: Snapshot Extensions + Height Index (Consensus Change, with SDK Upgrade) **A. Fill the empty snapshotters:** ```go // x/graph/keeper/snapshotter.go func (gs *GraphSnapshotter) SnapshotExtension(height uint64, pw snapshot.ExtensionPayloadWriter) error { // Binary format already exists: WriteCids() + WriteLinks() // 1. Write all CIDs (variable-length binary) // 2. Write all CompactLinks (24 bytes each) return gs.graphKeeper.WriteGenesis(pw) } // x/rank/keeper/snapshotter.go func (rs *RankSnapshotter) SnapshotExtension(height uint64, pw snapshot.ExtensionPayloadWriter) error { // 1. Write cidCount (uint64) // 2. Write rankValues[] (cidCount × 8 bytes) return rs.WriteRankValues(pw) } func (rs *RankSnapshotter) RestoreExtension(...) error { // 1. Read rank values from payload // 2. Build merkle tree from values // 3. Verify merkle root matches on-chain LatestMerkleTree // 4. Load into networkCidRank — node is immediately ready, NO GPU needed return rs.LoadRankValues(pr) } ``` Snapshot payload sizes (estimated): - 1M links: ~58 MB graph + ~8 MB rank = ~66 MB (→ ~15-20 MB compressed) - 10M links: ~580 MB graph + ~80 MB rank = ~660 MB (→ ~150-200 MB compressed) **B. Secondary index by height** (for efficient `CyberlinksAfter`): New IAVL key prefix: `[0x07][Height 8B][LinkSeq 8B]` → enables O(k) incremental sync where k = new links only. This is a consensus change (new store key) and must ship with a chain upgrade. #### Level 3: Light Client with Rank Proofs The codebase already has the foundation: `merkle/tree.go` implements RFC-6962 merkle tree with `GetIndexProofs()` and `ValidateIndexByProofs()`. **A. Rank Inclusion Proofs:** Two merkle tree modes: - `full=false` — stores only subtree roots (used for consensus, 40 hashes for 1T links) - `full=true` — stores all nodes (enables proof generation for any leaf) New node flag `--rank-proofs=true` enables full mode on nodes that serve light clients. New gRPC endpoint: ``` QueryRankWithProof(particle) → { rank, cid_number, proofs[], merkle_root } ``` **B. Graph Inclusion Proofs (already available):** IAVL natively supports merkle proofs. Any gRPC query with `prove=true` returns an IAVL proof verifiable against app_hash. **C. Full verification path:** ``` CometBFT light client → verified block header → app_hash → IAVL proof for graph queries (cyberlink existence) → RFC-6962 proof for rank queries (rank value for a CID) ``` A trustless light client can verify any cyberlink exists and verify the rank of any particle — without downloading full chain state or running PageRank. ### Dynamic Rank: How It Works for Clients The client does NOT need all rank values. The workflow: ``` Client: 1. Sync full graph topology via GraphSnapshot (one-time, ~15-60 MB compressed) 2. Keep up via CyberlinksAfter(lastHeight) every N blocks 3. User navigates to particle "QmFoo": a. Client knows local topology: QmFoo has 47 outlinks, 312 backlinks b. Client calls Search("QmFoo", page=0, limit=10) → top 10 outlinks with rank c. Client calls Backlinks("QmFoo", page=0, limit=10) → top 10 backlinks with rank d. Client calls Rank("QmFoo") → rank value of QmFoo itself 4. User drills into "QmBar" (linked from QmFoo): a. Repeat step 3 for QmBar — lazy load rank for this subgraph 5. Client caches rank values locally, invalidates every CalculationPeriod blocks ``` This is already possible with existing `Rank`, `Search`, `Backlinks`, `Top` gRPC endpoints. The missing piece is only Level 1 (graph topology streaming). ### Graph Store Separation (Future, SDK v0.53) SDK v0.53 introduces pluggable storage backends and IAVL v2. This opens the possibility of: - **Current:** Cyberlinks stored as individual IAVL KV pairs. Each write goes through full IAVL tree path (O(log n) with proof generation). - **Future:** Flat append-only store for cyberlinks (no per-link proof needed), with only the graph merkle root in IAVL for consensus. Dramatically reduces storage overhead and speeds up full graph iteration. ### Checklist **Level 1 (Now, no consensus change):** - [ ] Add `GraphSnapshot` server-side streaming gRPC endpoint (prefix scan on `0x03`) - [ ] Add `CyberlinksAfter` gRPC endpoint (full scan + height filter, O(n)) - [ ] Add `CyberlinksByParticle` gRPC endpoint (from in-memory index, O(degree)) - [ ] Benchmark: full graph stream time for production graph size - [ ] Test: client syncs full topology, then lazy-loads rank via existing Search/Backlinks **Level 2 (Consensus change, with SDK upgrade):** - [ ] Implement graph data in `GraphSnapshotter.SnapshotExtension()` using existing `WriteGenesis()` format - [ ] Implement rank values in `RankSnapshotter.SnapshotExtension()` - [ ] Implement rank values restore + merkle verification in `RankSnapshotter.RestoreExtension()` - [ ] Add secondary index `[0x07][Height][Seq]` for efficient incremental sync - [ ] Benchmark snapshot size with rank values for production graph - [ ] Test state-sync restore without GPU (rank loaded from snapshot) **Level 3 (Light client):** - [ ] Add `--rank-proofs` node flag to control `full=true` merkle tree mode - [ ] Add `QueryRankWithProof` gRPC endpoint to `x/rank` module - [ ] Document light client verification protocol - [ ] Evaluate graph store separation feasibility after SDK v0.53 migration --- ## Native Graph Indexing (Replace Cyberindex) ### Problem The current indexing architecture requires three external services (cyberindex, PostgreSQL, Hasura) running alongside the node. This adds operational complexity, deployment overhead, and introduces latency (block polling). For the knowledge graph use case, the node itself should be the primary data source. ### Current State - **cyberindex** (separate Go service) polls RPC, parses blocks/events, writes to PostgreSQL - **Hasura** auto-generates GraphQL API over PostgreSQL - **go-cyber already loads** `streaming.LoadStreamingServices()` in `app/keepers/keepers.go` — the ADR-038 infrastructure is wired but unused - CometBFT `tx_index = "kv"` with `index-events = []` already indexes ALL events natively - Transaction queries by address work out of the box: `query txs --events 'message.sender='` ### What Cyberindex Captures (SQL Schema) | Table | Source | Can Node Do This Natively? | |---|---|---| | `block`, `transaction`, `message` | Block/TX parsing | Yes — CometBFT tx_index already provides this | | `cyberlinks`, `particles` | `EventTypeCyberlink` events | Yes — events indexed, but no structured query API | | `account_balance` | Bank module state | Yes — gRPC query already exists | | `routes` | Grid module events | Yes — events indexed | | `investmints` | Resources module events | Yes — events indexed | | `contracts` | Wasm module state | Yes — gRPC query already exists | | `validator`, `pre_commit` | CometBFT consensus | Yes — CometBFT RPC provides this | ### Architecture: Embedded ABCIListener Plugin Replace cyberindex with a native streaming plugin that writes to an embedded database (SQLite or embedded PostgreSQL): ``` go-cyber node BaseApp ├── FinalizeBlock → ABCIListener │ ├── cyberlink events → embedded DB (cyberlinks, particles) │ ├── investmint events → embedded DB │ ├── grid events → embedded DB │ └── wasm events → embedded DB └── Commit → flush batch ↓ Embedded SQLite/DuckDB ↓ Native gRPC query endpoints (graph by address, history, analytics) ↓ Optional: Hasura over embedded DB (for GraphQL compatibility) ``` ### Implementation Plan #### Step 0: Native Graph Query Endpoints (No Consensus Change) Add gRPC query endpoints to the graph module for data that currently requires cyberindex: ```protobuf service Query { // Existing rpc GraphStats(QueryGraphStatsRequest) returns (QueryGraphStatsResponse); // New: paginated cyberlinks by neuron address rpc CyberlinksByNeuron(QueryCyberlinksByNeuronRequest) returns (QueryCyberlinksByNeuronResponse); // New: paginated cyberlinks by particle (all links from/to a CID) rpc CyberlinksByParticle(QueryCyberlinksByParticleRequest) returns (QueryCyberlinksByParticleResponse); // New: all particles created by a neuron rpc ParticlesByNeuron(QueryParticlesByNeuronRequest) returns (QueryParticlesByNeuronResponse); // New: incremental graph export (for external indexers and light clients) rpc CyberlinksAfter(CyberlinksAfterRequest) returns (CyberlinksAfterResponse); } ``` These queries can be implemented by iterating the existing IAVL store with prefix scans — no new state needed. #### Step 1: ABCIListener Streaming Plugin (With SDK v0.50) SDK v0.50 fixes the `ListenFinalizeBlock` bug and provides proper event grouping. Implement a streaming plugin that: 1. Receives all state changes and events via `ABCIListener` 2. Writes structured data to an embedded database (SQLite for simplicity, DuckDB for analytics) 3. Exposes additional gRPC endpoints for historical queries (link history, balance history) 4. Configuration via `app.toml`: ```toml [indexer] enabled = true backend = "sqlite" # or "duckdb", "postgres" path = "data/index.db" ``` #### Step 2: Schema/Indexer Framework (With SDK v0.53) SDK v0.53 introduces `cosmossdk.io/schema/indexer` with automatic table generation from module schemas. Implement `HasModuleCodec` for custom modules (graph, rank, resources, grid) so the native indexer framework can auto-generate SQL tables. ### What This Eliminates | Component | Status | |---|---| | cyberindex Docker service | **Eliminated** — node indexes natively | | PostgreSQL for indexing | **Replaced** by embedded DB (or optional external Postgres) | | Hasura | **Optional** — can still point at embedded DB for GraphQL, or use native gRPC | | Block polling latency | **Eliminated** — data available at commit time | | Separate deployment/monitoring | **Eliminated** — single binary | ### Checklist - [ ] Add `CyberlinksByNeuron` gRPC endpoint (IAVL prefix scan, no new state) - [ ] Add `CyberlinksByParticle` gRPC endpoint (IAVL prefix scan) - [ ] Add `ParticlesByNeuron` gRPC endpoint (IAVL prefix scan) - [ ] Add `CyberlinksAfter` gRPC endpoint (incremental export by height) - [ ] Implement ABCIListener plugin with SQLite backend (SDK v0.50) - [ ] Implement `HasModuleCodec` for graph, rank, resources, grid modules (SDK v0.53) - [ ] Add `[indexer]` configuration section to `app.toml` - [ ] Benchmark embedded DB vs external PostgreSQL for query performance - [ ] Migration guide: cyberindex users → native indexing --- ## IPFS Sidecar: Kubo as Managed Subprocess ### Problem go-cyber stores CID references but cannot resolve them to content. Users must install, configure, and maintain a separate Kubo (IPFS) node — a process that has historically been painful and error-prone (port conflicts, CORS configuration, bootstrap peers, garbage collection tuning). Without a working IPFS node, the knowledge graph is just a graph of opaque hashes. Content resolution is essential for search, discovery, and any meaningful interaction with the graph. ### Why Not Embed IPFS in the Binary Three approaches were evaluated: | Approach | Verdict | Why | |---|---|---| | **Embed full Kubo** | Rejected | +50MB binary, 68 direct deps, go-cid v0.0.7→v0.5.0 breaking upgrade, monthly Kubo releases break integration. Textile tried this, deprecated it. | | **Embed libp2p + Bitswap** | Rejected | Bitswap without DHT is useless (can't find content providers). Adding DHT = 80% of Kubo without the useful 20% (gateway, pinning, GC). Still massive dep conflicts. | | **Kubo as managed sidecar** | **Selected** | Zero dep conflicts, full IPFS functionality, process isolation, independent updates, battle-tested. IPFS Cluster uses this pattern. | ### Architecture: Managed Kubo Sidecar ``` cyber init ├── Initialize blockchain node (as before) └── Initialize IPFS repo with pre-configured config ├── Ports: API 5001, Gateway 8080, Swarm 4001 (no conflicts with CometBFT) ├── Bootstrap: cyber network peers + default IPFS bootstrap ├── CORS: configured for cyber.page and localhost ├── Gateway: writable=false, localhost only ├── Peering: known cyber full nodes pre-configured └── GC: automatic, watermark-based cyber start ├── Start CometBFT + go-cyber (blockchain) └── Start Kubo daemon (managed subprocess) ├── Lifecycle tied to cyber process (start/stop together) ├── Health monitoring (restart on crash) └── HTTP API on localhost:5001 (not exposed externally) go-cyber ←→ Kubo communication: HTTP API (localhost:5001) ``` ### What This Gives - **"Install once, everything works"** — `cyber init` sets up IPFS with sane defaults, no manual configuration - **Full IPFS** — DHT, Bitswap, DAG resolution, gateway, pinning, GC — everything works because it's real Kubo - **Process isolation** — Kubo crash doesn't affect consensus; blockchain crash doesn't lose pinned content - **Independent updates** — upgrade Kubo without touching the blockchain binary, and vice versa - **Zero dependency conflicts** — go-cyber binary unchanged, Kubo runs as separate process ### go-cyber Integration (Minimal Code) The blockchain side needs only an HTTP client to Kubo's RPC API: ```go // x/content/keeper/ipfs.go type IPFSClient struct { apiURL string // default: http://localhost:5001 } func (c *IPFSClient) Resolve(cid string) ([]byte, error) { resp, err := http.Post(c.apiURL+"/api/v0/cat?arg="+cid, "", nil) // ... } func (c *IPFSClient) Pin(cid string) error { resp, err := http.Post(c.apiURL+"/api/v0/pin/add?arg="+cid, "", nil) // ... } func (c *IPFSClient) Add(data []byte) (string, error) { // multipart upload to /api/v0/add // returns CID } ``` New gRPC endpoints exposed by go-cyber (proxying to Kubo): ```protobuf service Query { // Resolve particle CID to content bytes (proxied to Kubo) rpc ResolveParticle(QueryResolveParticleRequest) returns (QueryResolveParticleResponse); } ``` ### Pre-configured Kubo Config The `cyber init` command generates `~/.cyber/ipfs/config` with: ```json { "Addresses": { "API": "/ip4/127.0.0.1/tcp/5001", "Gateway": "/ip4/127.0.0.1/tcp/8080", "Swarm": ["/ip4/0.0.0.0/tcp/4001", "/ip6/::/tcp/4001"] }, "Bootstrap": [ "/dnsaddr/bootstrap.libp2p.io/p2p/QmNnooDu7...", "/dns4/hub.bostrom.cybernode.ai/tcp/4001/p2p/..." ], "Peering": { "Peers": [ {"ID": "...", "Addrs": ["/dns4/earth.bostrom.cybernode.ai/tcp/4001"]} ] }, "Datastore": { "StorageMax": "50GB", "GCPeriod": "1h" }, "Gateway": { "HTTPHeaders": { "Access-Control-Allow-Origin": ["http://localhost:3000", "https://cyber.page"] } }, "API": { "HTTPHeaders": { "Access-Control-Allow-Origin": ["http://localhost:3000", "https://cyber.page"] } }, "Swarm": { "ConnMgr": {"LowWater": 50, "HighWater": 200, "GracePeriod": "60s"} } } ``` ### Implementation Plan #### Phase 1: Managed Lifecycle - `cyber init` generates IPFS repo with pre-configured config - `cyber start` launches Kubo as subprocess, manages lifecycle (restart on crash) - `cyber stop` cleanly shuts down both processes - `[ipfs]` section in `app.toml` for enabling/disabling and config path - Kubo binary location: bundled in release tarball or auto-downloaded on first init #### Phase 2: Content Integration - `ResolveParticle` gRPC endpoint (proxy to Kubo API) - Auto-pin particles from new cyberlinks (configurable) - Pin top-ranked particles from search index (configurable) #### Phase 3: Cyber-Aware IPFS - Custom Kubo plugin or peering config that preferentially connects to other cyber nodes - Content availability metrics per particle (how many cyber nodes pin it) - Integration with rank: content availability as a signal ### Configuration ```toml [ipfs] enabled = true binary = "/usr/local/bin/ipfs" # or bundled path repo_path = "ipfs" # relative to cyber home auto_pin = true # pin particles from new cyberlinks pin_top = 1000 # pin top N ranked particles ``` ### Checklist - [ ] Add IPFS repo initialization to `cyber init` with pre-configured config - [ ] Implement Kubo subprocess management in `cyber start` (launch, health check, restart) - [ ] Add `[ipfs]` configuration section to `app.toml` - [ ] Implement `IPFSClient` HTTP wrapper for Kubo API - [ ] Add `ResolveParticle` gRPC endpoint - [ ] Bundle Kubo binary in release artifacts (or auto-download script) - [ ] Pre-configure bootstrap peers and peering for cyber network - [ ] Pre-configure CORS for cyber.page and localhost - [ ] Implement auto-pin for new cyberlinks (Phase 2) - [ ] Implement top-ranked particle pinning (Phase 2) - [ ] Test: `cyber init && cyber start` on clean machine gives working IPFS + blockchain - [ ] Document: how to use existing Kubo installation instead of managed sidecar --- ## Cross-Platform GPU Compute (wgpu, Replace CUDA) ### Problem CybeRank computation currently requires NVIDIA CUDA — only Linux + NVIDIA GPU can run rank calculation on GPU. macOS, AMD, Intel Arc, and any non-NVIDIA setup falls back to CPU, which is orders of magnitude slower for large graphs. This limits who can run a full node with fast rank computation. ### Current CUDA Architecture After removing karma/entropy/luminosity, **4 CUDA kernels remain** in `x/rank/cuda/rank.cu`: | Kernel | Purpose | Complexity | |---|---|---| | `get_particle_stake_by_links` | Weighted stake per neuron's links | Simple: divide stake by neudeg | | `get_compressed_in_links_count` | Count incoming links per particle | Simple: parallel count | | `get_compressed_in_links` | Build compressed in-links array with weights | Medium: prefix sum + scatter | | `run_rank_iteration` | One PageRank iteration (core algorithm) | Medium: weighted sum + normalize | Supporting operations: - `find_max_ranks_diff` — Thrust-based reduction (convergence check) - `get_links_start_index` — CPU prefix sum (link offsets) Build: `//go:build cuda` tag, `-fmad=false` flag for **consensus determinism** (disables fused multiply-add to ensure all nodes compute identical float64 results). Data types: **float64 (double precision)** throughout — `CompressedInLink` = `{uint64_t fromIndex, double weight}` (16 bytes). ### wgpu/WebGPU as Cross-Platform Alternative WebGPU (via wgpu-native, written in Rust) provides a cross-platform GPU compute API over: - **Vulkan** (Linux, Windows, Android) - **Metal** (macOS, iOS) - **DX12** (Windows) Best Go binding: **`go-webgpu/webgpu`** (v0.3.1, zero-CGO, active project). Uses wgpu-native under the hood. Performance: **85-100% of CUDA** for optimized compute shaders on Vulkan. ### Critical Blockers #### 1. f64 Not Supported on Apple Silicon / Metal **This is the biggest blocker for the Mac use case.** Metal (and therefore wgpu on macOS) does **not support 64-bit floating point** in compute shaders. WGSL's `f64` type requires the `shader-f64` extension, which is only available on: - Vulkan devices with `shaderFloat64` feature (most discrete NVIDIA/AMD GPUs) - DX12 devices (most desktop GPUs) - **NOT Metal** — Apple has never shipped f64 in Metal shaders This means the exact same algorithm (using float64) **cannot run on Mac GPU**. Workarounds: - **f32 (single precision):** Works on all GPUs including Apple Silicon. But reduces precision from ~15 decimal digits to ~7. Must prove that PageRank convergence and final values are identical (or acceptably close) to the f64 version for consensus. - **Emulated f64:** Use double-single (ds) arithmetic — represent each f64 as a pair of f32. ~4x slower than native f64, but still much faster than CPU. Determinism is hard to guarantee. #### 2. Consensus Determinism (no `-fmad=false` equivalent) CUDA's `-fmad=false` disables fused multiply-add to ensure `a*b+c` is computed as two separate operations, producing identical results across all NVIDIA GPUs. WGSL has **no equivalent flag**: - Metal: no FMA control - Vulkan/SPIR-V: can annotate `NoContraction` on individual operations - WGSL: no standard annotation yet (proposal exists but not adopted) This means: ensuring bit-exact results across different GPU vendors (NVIDIA vs AMD vs Intel vs Apple) requires manual effort — either hand-written SPIR-V with `NoContraction`, or proving that FMA differences don't affect final convergence. ### Recommended Approach: Three Phases #### Phase 1: Optimize CPU Path (Now, No Risk) The CPU fallback (`calculate_cpu.go`) is unoptimized. Before adding wgpu complexity, make CPU viable for medium-sized graphs: - [ ] SIMD (AVX2/NEON) for the rank iteration inner loop - [ ] `sync.Pool` + goroutine parallelism for multi-core utilization - [ ] Precompute `getOverallOutLinksStake` per CID (currently recomputed O(|V| × avg_degree²)) - [ ] Cache-friendly memory layout for compressed links (struct-of-arrays vs array-of-structs) Target: **10x CPU speedup** — viable for graphs up to ~1M links without GPU. #### Phase 2: wgpu Prototype with f32 (Medium Term) Build a wgpu compute shader implementation of the 4 kernels using f32: - [ ] Port `run_rank_iteration` to WGSL compute shader (f32) - [ ] Port `get_compressed_in_links` to WGSL - [ ] Port `get_particle_stake_by_links` to WGSL - [ ] Implement max_diff reduction in WGSL - [ ] Benchmark: compare f32 wgpu vs f64 CUDA rank values on mainnet graph - [ ] Quantify precision loss: max absolute and relative error in rank values - [ ] Test consensus: run f32 and f64 on same graph, verify convergence to same ordering (top-N agreement) If f32 precision is **sufficient for consensus** (same merkle root), this becomes the cross-platform default: - Works on Mac (Apple Silicon Metal) - Works on Linux (Vulkan, any GPU vendor) - Works on Windows (DX12/Vulkan) - Build tag: `//go:build wgpu` If f32 precision is **not sufficient**, fall back to Phase 3. #### Phase 3: Full f64 wgpu (Long Term) For validators and full nodes that need consensus-grade f64: - [ ] wgpu with f64 on Vulkan/DX12 (NVIDIA, AMD, Intel Arc on Linux/Windows) - [ ] Emulated f64 (double-single) on Metal for Mac — slower but correct - [ ] Cross-vendor determinism testing: NVIDIA vs AMD vs Intel GPU producing identical rank values - [ ] `NoContraction` annotation in SPIR-V backend for Vulkan determinism - [ ] Build tag: `//go:build wgpu_f64` ### Decision Matrix | Platform | CUDA (current) | wgpu f32 (Phase 2) | wgpu f64 (Phase 3) | CPU optimized (Phase 1) | |---|---|---|---|---| | Linux + NVIDIA | **Yes** | Yes | Yes (Vulkan) | Yes | | Linux + AMD | No | Yes (Vulkan) | Yes (Vulkan) | Yes | | macOS + Apple Silicon | No | **Yes (Metal)** | Emulated only | Yes | | Windows + any GPU | No | Yes (DX12/Vulkan) | Yes (DX12/Vulkan) | Yes | | ARM server (no GPU) | No | No | No | **Yes** | ### Migration Path ``` Current: [CUDA (NVIDIA only)] ←OR→ [CPU (slow, unoptimized)] ↓ Phase 1: [CUDA (NVIDIA only)] ←OR→ [CPU optimized (10x faster)] ↓ Phase 2: [CUDA] ←OR→ [wgpu f32 (cross-platform)] ←OR→ [CPU optimized] ↓ Phase 3: [wgpu f64 (Vulkan/DX12)] ←OR→ [wgpu f32 (Metal)] ←OR→ [CPU] └── CUDA becomes optional/deprecated ``` ### Checklist **Phase 1 (CPU optimization, now):** - [ ] Profile CPU rank calculation on mainnet-sized graph, identify hotspots - [ ] Parallelize rank iteration across goroutines - [ ] Add SIMD intrinsics for inner loop (AVX2 on x86, NEON on ARM) - [ ] Precompute per-CID outgoing stake totals - [ ] Benchmark: CPU optimized vs CUDA on same hardware **Phase 2 (wgpu f32 prototype):** - [ ] Evaluate `go-webgpu/webgpu` v0.3.1: build, run compute shader example - [ ] Port 4 CUDA kernels to WGSL compute shaders (f32) - [ ] Integrate with go-cyber via `//go:build wgpu` tag - [ ] Precision analysis: f32 vs f64 rank values on mainnet state export - [ ] Consensus test: can f32 produce identical merkle roots as f64? - [ ] Cross-platform test: same rank output on Mac Metal vs Linux Vulkan **Phase 3 (wgpu f64, long term):** - [ ] f64 WGSL shaders with `shader-f64` extension - [ ] Emulated f64 on Metal (double-single arithmetic) - [ ] Cross-vendor determinism test (NVIDIA Vulkan vs AMD Vulkan vs Intel Vulkan) - [ ] `NoContraction` SPIR-V annotation for FMA determinism - [ ] Deprecation path for CUDA: runtime detection of best available backend --- ## Node Distribution: cyb Desktop App (Tray + Dashboard) ### Problem go-cyber is currently distributed as a bare CLI binary. Running a node requires manual configuration (config.toml, app.toml, genesis), separate IPFS installation, no visual status feedback, no auto-start, no OS integration. This is a barrier for anyone who isn't a devops specialist. Goal: **"Download → double-click → it works."** Like Docker Desktop — a daemon with a tray icon and a web dashboard. ### Current State | What | Status | |---|---| | Binary build | `make build` → `build/cyber` CLI | | Installation | Manual or `scripts/install_cyber.sh` (outdated, references v0.2.0) | | OS service | None (no systemd/launchd files) | | Dashboard/UI | None (only Swagger at `:1317/swagger`) | | IPFS | Separate manual install | | Desktop app | None | | GoReleaser | Outdated (references `cyberdcli`) | ### Target Architecture: Three Binaries, One App The distribution consists of three binaries. The user interacts only with **cyb** (`go-cyb`) — the desktop app that orchestrates the other two. ``` Binaries: cyber (~50MB) ← blockchain node (Cosmos SDK + CosmWasm + rank) ipfs (~50MB) ← Kubo IPFS node (separate project, cannot embed due to dep conflicts) cyb (~5MB) ← desktop app: tray, orchestrator, the only thing user launches (separate repo: go-cyb) Why three binaries: - cyber + ipfs cannot be one binary: massive Go dependency conflicts (go-cid v0.0.7 vs v0.5.0, libp2p versions, etc.) - cyb is lightweight: no blockchain deps, no IPFS deps, just HTTP + systray - Each has its own release cycle: update IPFS or node without touching the others Process tree (when running): cyb (always running, started at login) ├── manages → cyber start --home ~/.cyber │ ├── CometBFT consensus │ ├── Cosmos SDK app │ ├── gRPC/REST/RPC servers │ └── embedded dashboard (port 26660) └── manages → ipfs daemon --repo-dir ~/.cyber/ipfs ├── DHT ├── Bitswap ├── Gateway (port 8080) └── API (port 5001) ``` **cyb is the orchestrator:** - Launches `cyber` and `ipfs` as child processes - Monitors health of both (restart on crash) - Shows combined status in tray icon - Provides Start/Stop for the whole stack - On quit: gracefully stops both daemons **CLI still works independently:** - `cyber start` works without cyb (for servers, Docker, CI) - `ipfs daemon` works without cyb (for advanced users) - cyb is the desktop UX layer, not a requirement ### Port Map (all services from one install) | Port | Service | Binding | |---|---|---| | 26656 | P2P (CometBFT peers) | 0.0.0.0 | | 26657 | CometBFT RPC | 0.0.0.0 | | 9090 | gRPC | 0.0.0.0 | | 9091 | gRPC-Web (browser) | 0.0.0.0 | | 1317 | REST API + Swagger | 0.0.0.0 | | **26660** | **Dashboard (web UI)** | localhost | | 5001 | IPFS API (Kubo) | localhost | | 4001 | IPFS Swarm (Kubo) | 0.0.0.0 | | 8080 | IPFS Gateway (Kubo) | localhost | ### Component 1: cyb (go-cyb) — Desktop App & Orchestrator The **only thing the user launches**. Manages both `cyber` and `ipfs` processes. Separate repository: `go-cyb`. **Technology:** Go + `getlantern/systray` (cross-platform: macOS, Linux, Windows). No blockchain or IPFS dependencies — only `net/http`, `os/exec`, and `systray`. **Process Management:** ``` cyb start sequence: 1. Check if cyber and ipfs are already running (poll health endpoints) 2. If not: find binaries (PATH or configured location) 3. Launch ipfs daemon --repo-dir ~/.cyber/ipfs (background) 4. Wait for IPFS API ready (poll localhost:5001/api/v0/id) 5. Launch cyber start --home ~/.cyber (background) 6. Wait for node ready (poll localhost:26657/health) 7. Show tray icon: 🟡 syncing cyb health loop (every 5s): - GET localhost:26657/status → height, catching_up, voting_power - GET localhost:5001/api/v0/id → IPFS peer ID, connected peers - If cyber crashed → restart (up to 3 retries, then show error) - If ipfs crashed → restart - Update icon: 🟢 both synced, 🟡 syncing, 🟠 IPFS down, 🔴 node down cyb stop sequence: 1. Send SIGTERM to cyber process → wait for graceful shutdown 2. Send SIGTERM to ipfs process → wait for graceful shutdown 3. Icon → 🔴 stopped ``` **Tray Menu:** ``` ┌─────────────────────────────────┐ │ 🟢 Cyber Node │ │ Height: 22,451,003 │ │ Peers: 47 | Block: 5.2s │ │ 🟢 IPFS │ │ Peers: 156 | Repo: 12 GB │ ├─────────────────────────────────┤ │ Open Dashboard │ → open http://localhost:26660 │ Open IPFS Gateway │ → open http://localhost:8080 │ Open IPFS WebUI │ → open http://localhost:5001/webui ├─────────────────────────────────┤ │ Start All │ → start ipfs + cyber │ Stop All │ → stop cyber + ipfs │ Restart All │ → stop all, start all ├─────────────────────────────────┤ │ View Logs │ → open ~/.cyber/logs/ │ Open Config │ → open ~/.cyber/ ├─────────────────────────────────┤ │ Quit │ → stop all + exit tray └─────────────────────────────────┘ ``` **macOS specifics:** - Tray lives in menu bar (standard macOS pattern) - `Cyb.app` bundle in `/Applications/` (contains cyb binary + references to cyber and ipfs binaries) - Login item via launchd plist or `SMAppService` - First launch: if binaries not found, offer to download **Linux specifics:** - Tray via AppIndicator (GNOME) or SNI (KDE) - `.desktop` file for autostart: `~/.config/autostart/cyb.desktop` **Key design:** cyb never touches chain state. Communication is purely HTTP polling. Start/stop is `os/exec.Command`. cyb is a thin orchestrator + status display. ### Component 2: Embedded Dashboard (port 26660) Single HTML page embedded in the `cyber` binary via Go `embed`. Served by a goroutine alongside the node. **Content:** ``` ┌──────────────────────────────────────────────────────────┐ │ CYBER NODE DASHBOARD chain: bostrom │ ├──────────────────────────────────────────────────────────┤ │ │ │ STATUS NETWORK GRAPH │ │ ● Synced Peers: 47/50 Particles: 8.2M │ │ Height: 22.4M In: 32 Out: 15 Cyberlinks: 12.1M │ │ Block time: 5s Bandwidth: 42% Neurons: 340K │ │ │ │ RANK IPFS │ │ Method: GPU (CUDA) ● Connected │ │ Last calc: block 22.4M Peers: 156 │ │ Iterations: 23 Pinned: 45.2K objects │ │ Tolerance: 0.001 Repo size: 12.3 GB │ │ │ │ RESOURCES │ │ CPU: 34% RAM: 8.2 GB Disk: 124 GB GPU: 67% │ │ │ │ LOGS (last 50 lines, auto-scroll) │ │ ┌────────────────────────────────────────────────────┐ │ │ │ 14:23:01 INF committed state height=22451003 ... │ │ │ │ 14:23:06 INF committed state height=22451004 ... │ │ │ │ ... │ │ │ └────────────────────────────────────────────────────┘ │ └──────────────────────────────────────────────────────────┘ ``` **Implementation:** - One `index.html` + vanilla JS (~500 lines total) - Polls every 3-5 seconds: - `localhost:26657/status` — height, sync, validator info - `localhost:26657/net_info` — peers - `localhost:1317/cyber/graph/v1beta1/graph_stats` — graph metrics - `localhost:5001/api/v0/id` — IPFS status - `localhost:5001/api/v0/repo/stat` — IPFS storage - Embedded via `//go:embed dashboard/*` - Served on `localhost:26660` by `net/http` goroutine in the node process - No frameworks, no npm, no build step — just static files - Dark theme, monospace, minimal ### Component 3: OS Service Management (`cyber service`) ```bash cyber service install # Create systemd unit / launchd plist cyber service uninstall # Remove service cyber service start # Start via OS service manager cyber service stop # Stop via OS service manager cyber service restart # Restart cyber service status # Show service status cyber service logs # Tail service logs (journalctl / log show) ``` **Linux (systemd):** ```ini [Unit] Description=Cyber Node — Knowledge Graph Computer After=network-online.target Wants=network-online.target [Service] Type=simple User=%u ExecStart=/usr/local/bin/cyber start --home %h/.cyber ExecStop=/usr/local/bin/cyber stop Restart=always RestartSec=5 LimitNOFILE=65535 Environment=DAEMON_HOME=%h/.cyber [Install] WantedBy=default.target ``` **macOS (launchd):** ```xml Labelai.cyber.node ProgramArguments /usr/local/bin/cyber start --home ~/.cyber KeepAlive RunAtLoad StandardOutPath~/.cyber/logs/node.log StandardErrorPath~/.cyber/logs/node.err SoftResourceLimits NumberOfFiles65535 ``` ### Component 4: Installer **One-liner (Linux/macOS):** ```bash curl -sL https://get.cyber.page | bash ``` Script does: 1. Detect OS/arch (darwin-arm64, linux-amd64, linux-arm64) 2. Download `cyber` + `cyb` binaries from GitHub Releases (go-cyber + go-cyb) 3. Download Kubo binary (or detect existing installation) 4. Install to `/usr/local/bin/` 5. Install `libwasmvm` shared library 6. Run `cyber init` (if first install) 7. Register `cyb` as login item 8. Launch `cyb` (which starts everything) 9. Print: "Dashboard: http://localhost:26660" **Homebrew (macOS):** ```bash brew install cybercongress/tap/cyb # Installs: cyb, cyber, kubo (dependencies) # Post-install: cyber init, register cyb as login item ``` **Desktop packages:** - macOS: `Cyb.dmg` containing `Cyb.app` + `cyber` + `ipfs` + `libwasmvm.dylib` - Linux: `.deb` / `.rpm` / AppImage — all three binaries + libwasmvm.so - Snap/Flatpak: future option ### User Experience Flow ``` First time (macOS): 1. User downloads Cyb.dmg 2. Drags Cyb.app to Applications 3. Launches Cyb.app → tray icon appears (red — nothing running) 4. cyb detects first run → runs cyber init + ipfs init 5. cyb starts ipfs daemon + cyber start 6. Icon turns yellow (syncing), dashboard opens in browser 7. User watches sync progress on dashboard 8. Icon turns green when both synced 9. On reboot: cyb auto-launches → starts both daemons First time (Linux, curl): 1. curl -sL https://get.cyber.page | bash 2. Script installs cyber + ipfs + cyb + libwasmvm 3. Runs cyber init + ipfs init 4. Registers cyb as login item 5. Starts everything 6. Prints: "Dashboard: http://localhost:26660" Daily use: - Tray icon always visible — one glance: green = all running - Click "Open Dashboard" for details - Click "Stop All" before closing laptop - cyb auto-restarts crashed processes - Updates: cyb checks GitHub Releases for all components, shows notification ``` ### Implementation Priority | Step | Component | Effort | Impact | |---|---|---|---| | **1** | **cyb** (go-cyb tray app) | 3-5 days | Critical — primary UX touchpoint | | **2** | **Dashboard** (embedded web page) | 2-3 days | High — visual status | | **3** | **`cyber service`** (systemd + launchd) | 1-2 days | High — auto-start/restart | | **4** | **Kubo sidecar** in `cyber start` | 3-5 days | High — IPFS out of box | | **5** | **Installer script** (`get.cyber.page`) | 1 day | Medium — easy onboarding | | **6** | **GoReleaser** update + multi-platform | 1 day | Medium — automated releases | | **7** | **macOS .dmg / Linux .deb** packages | 2-3 days | Medium — native install | ### Checklist **cyb (go-cyb — orchestrator + tray UI):** - [ ] Create `go-cyb` repository, implement with `getlantern/systray` (macOS + Linux) - [ ] Process management: launch/monitor/restart `cyber` and `ipfs` as child processes - [ ] Health polling loop: node status + IPFS status → tray icon update - [ ] Tray menu: Start All / Stop All / Restart / Dashboard / IPFS WebUI / Logs / Config / Quit - [ ] First-run detection: run `cyber init` + `ipfs init` with preconfigured settings - [ ] macOS: `Cyb.app` bundle, login item registration (launchd plist or SMAppService) - [ ] Linux: `.desktop` file for autostart - [ ] Graceful shutdown: SIGTERM to both processes on Quit **Dashboard (embedded in cyber):** - [ ] Embed dashboard HTML/JS in `cyber` binary via `//go:embed` - [ ] Dashboard: node status, peers, graph stats, rank info, IPFS stats, logs - [ ] Serve dashboard on `localhost:26660` from node process **OS service (headless/server use without tray):** - [ ] `cyber service install/uninstall/start/stop` for systemd - [ ] `cyber service install/uninstall/start/stop` for launchd **Packaging:** - [ ] Update `.goreleaser.yml` in go-cyber: build `cyber` for darwin-arm64, linux-amd64, linux-arm64 - [ ] GoReleaser in go-cyb: build `cyb` for darwin-arm64, linux-amd64, linux-arm64 - [ ] Release tarball: `cyber` + `cyb` + `ipfs` (Kubo) + `libwasmvm` per platform - [ ] macOS `.dmg`: `Cyb.app` bundle containing cyb + bundled `cyber` + `ipfs` binaries - [ ] Linux `.deb` / `.rpm`: all three binaries + libwasmvm + systemd unit + .desktop file - [ ] Installer script (`get.cyber.page`): detect OS, download all binaries, init, launch cyb - [ ] Homebrew formula: `brew install cybercongress/tap/cyb` (cyb + cyber + ipfs as deps) - [ ] Auto-update notification in cyb (check GitHub Releases for all three components) - [ ] Documentation: first-time setup guide with screenshots --- ## Graph Inference: LLM Trained on Knowledge Graph ### Problem CybeRank gives each particle a single number (PageRank). You can find "what's important" but you can't ask a question and get a human-readable answer. The knowledge graph has 3M particles linked to real content on IPFS — text, markdown, documents. With an IPFS sidecar resolving content, we can train an actual LLM on the graph's content and make it answer questions. Goal: **periodically train a small LLM from the knowledge graph content, distribute the model as a downloadable binary, enable generative text inference on the node and on clients. Ask a question → get a coherent text answer grounded in the graph's knowledge.** ### Two-Layer Architecture The inference system has two complementary layers: | Layer | What | Size | Speed | Purpose | |-------|------|------|-------|---------| | **Embeddings** (cid2vec) | Vector per particle from graph topology | ~200 MB | microseconds | Retrieval: find relevant particles | | **LLM** (cyber-LLM) | Fine-tuned language model on resolved content | ~2 GB | seconds | Generation: answer questions in text | Both are needed. Embeddings find what's relevant. LLM generates the answer. Together: **RAG (Retrieval-Augmented Generation) grounded in the knowledge graph.** ### Inference Costs a Cyberlink — The Full Loop **Every inference request requires a cyberlink transaction.** This is the core design: asking the LLM is not free — it costs a link, and that link feeds the graph, and the graph feeds the next model. ``` User wants to ask: "What is the relationship between entropy and consensus?" 1. PREPARE (client-side) - User's question text → ipfs add → question_CID - question_CID is now a particle in IPFS 2. CYBERLINK (on-chain transaction) - User submits: MsgCyberlink { from: question_CID, to: INFERENCE_PARTICLE } (INFERENCE_PARTICLE is a well-known CID, e.g. "QmInference...") - This costs bandwidth (anti-spam), requires stake (Sybil resistance) - The cyberlink is now ON-CHAIN — question is part of the graph 3. INFERENCE (triggered by the link, node-side) - Node sees cyberlink to INFERENCE_PARTICLE → triggers inference pipeline - RETRIEVE: embed question → HNSW search → top-K relevant particles - RESOLVE: top-K CIDs → text content via IPFS - GENERATE: llama-server produces answer text - answer text → ipfs add → answer_CID 4. RESPONSE LINK (node creates the return link) - Node (or user's client) creates: MsgCyberlink { from: question_CID, to: answer_CID } - Answer is now a particle, linked to the question, IN THE GRAPH 5. THE GRAPH GROWS - question_CID and answer_CID are new particles - Both are linked (question → inference, question → answer) - Next rank recalculation includes these new particles - Next model training includes this new content - Model gets better → more people ask → more links → better model ┌──────────────────────────────────────────┐ │ THE FULL LOOP │ │ │ │ Ask question ──→ cyberlink (pays) │ │ │ │ │ ▼ │ │ LLM generates answer │ │ │ │ │ ▼ │ │ Answer → graph (new particle + link) │ │ │ │ │ ▼ │ │ Graph grows → rank recalculates │ │ │ │ │ ▼ │ │ Model retrains on bigger graph │ │ │ │ │ ▼ │ │ Better model → more questions → ───┐ │ │ ▲ │ │ │ └─────────────────────────────┘ │ └──────────────────────────────────────────┘ ``` **Why this matters:** | Property | Mechanism | |----------|-----------| | **Spam control** | Cyberlink costs bandwidth + requires stake. No stake = no questions. | | **Demand signal** | Each question is a real on-chain signal of what users want to know. This feeds PageRank — popular questions/answers rank higher. | | **Self-improving** | Every Q&A pair enriches the graph. The model trains on the graph. More questions → richer graph → better model. | | **Censorship resistance** | Questions and answers are CIDs on IPFS, linked on-chain. No one can delete them. | | **Economic alignment** | Neurons who ask good questions (that get linked to by others) earn rank. Neurons who create cyberlinks to inference create demand. | ### Inference Request Flow (Technical) ``` Client: 1. ipfs add "What is entropy?" → QmQuestion123 2. sign & broadcast MsgCyberlink(from=QmQuestion123, to=QmInference) └── requires: bandwidth, stake (existing anti-spam) 3. wait for block inclusion Node (inference trigger): 4. EndBlocker or event listener sees link to QmInference 5. Resolve QmQuestion123 via IPFS → "What is entropy?" 6. RAG pipeline: a. Embed question → HNSW → top-5 relevant particles b. Resolve top-5 CIDs → context text c. llama-server: generate answer with context 7. ipfs add answer_text → QmAnswer456 8. Create link: QmQuestion123 → QmAnswer456 (node signs with module account or user pre-authorizes) Client: 9. Query: Search(QmQuestion123) → finds QmAnswer456 10. Resolve QmAnswer456 → read answer text Alternative (client-side inference): 4. Client has local cyber-llm.gguf + embedding.bin 5. Client runs RAG locally (no node needed for inference) 6. Client creates answer link: MsgCyberlink(from=QmQuestion123, to=QmAnswer456) 7. Both question and answer are in the graph either way ``` **Two modes:** | Mode | Where inference runs | Cyberlink | Graph grows | |------|---------------------|-----------|-------------| | **Node-side** | Node runs llama-server, generates answer | User pays link to trigger | Yes — node creates answer link | | **Client-side** | Client has local model, generates locally | User pays link to record Q&A | Yes — client creates answer link | Both modes require a cyberlink. Both modes grow the graph. The model itself doesn't care who runs it — the graph is the source of truth. ### Base Model Selection Target: small enough for consumer hardware (Mac M1 8GB, Linux no GPU), good enough for domain Q&A after fine-tuning. | Model | Params | Q4_K_M Size | RAM for Inference | Mac M1 Speed | Quality | |-------|--------|-------------|-------------------|-------------|---------| | Qwen2.5-1.5B | 1.5B | ~1.0 GB | ~2 GB | ~70 tok/s | Good for simple Q&A | | **Llama 3.2 3B** | 3.2B | **~1.8 GB** | **~3.5 GB** | **~35 tok/s** | **Best quality/size** | | Phi-3.5 mini | 3.8B | ~2.2 GB | ~4 GB | ~30 tok/s | Strong reasoning | | Mistral 7B | 7.2B | ~4.1 GB | ~6.5 GB | ~20 tok/s | Best quality | **Recommendation: Llama 3.2 3B at Q4_K_M quantization.** 1.8 GB on disk, runs on any Mac M1+, 35 tokens/sec. A fine-tuned 3B matches general-purpose 7B on domain-specific questions. ### Training Pipeline ``` PERIODIC TRAINING (daily or per-epoch) ══════════════════════════════════════ ┌──────────────────────────────────────────────────────────────┐ │ Step 1: CONTENT RESOLUTION │ │ │ │ GraphSnapshot gRPC → all particles (CID list) │ │ Rank values → sort by PageRank │ │ For top-N particles (by rank): │ │ IPFS resolve CID → raw content (text, markdown) │ │ Filter: keep text, skip binary/images │ │ Cache locally: ~/.cyber/data/content_cache/ │ │ │ │ Result: corpus of resolved text documents │ │ Size estimate: 3M particles, ~50% text, ~1KB avg │ │ = ~1.5M documents, ~1.5 GB text │ └──────────────────────────────────────────────────────────────┘ │ ▼ ┌──────────────────────────────────────────────────────────────┐ │ Step 2: TRAINING DATA CONSTRUCTION │ │ │ │ A) Continued Pre-Training (CPT) corpus: │ │ - All resolved text, PageRank-weighted sampling │ │ - High-rank particles repeated more often │ │ - Graph walks: follow cyberlinks to create │ │ "document sequences" (linked content concatenated) │ │ │ │ B) Instruction Fine-Tuning (IFT) pairs: │ │ - Graph-structure Q&A: "What links from X?" "What is Y?" │ │ - Synthetic Q&A: use larger model to generate │ │ question-answer pairs from content │ │ - Link-based pairs: "How does [content A] relate │ │ to [content B]?" for linked particles │ │ - Target: ~50K-100K Q&A pairs │ │ │ │ C) Graph walk sequences (teaches link structure): │ │ - Random walks following cyberlinks, weighted by stake │ │ - Concatenate resolved content along the walk │ │ - Model learns that linked content is related │ └──────────────────────────────────────────────────────────────┘ │ ▼ ┌──────────────────────────────────────────────────────────────┐ │ Step 3: FINE-TUNING │ │ │ │ Base model: Llama 3.2 3B (frozen) │ │ Method: LoRA (r=32, alpha=64) │ │ │ │ Phase 1 (weekly): CPT on full corpus │ │ - 1 epoch over all resolved content │ │ - GPU: 12-24 hours on RTX 4090 / 8-15 hours on A100 │ │ - CPU: feasible but slow (~2-3 days) │ │ │ │ Phase 2 (daily): IFT on Q&A pairs │ │ - LoRA fine-tune on 50K-100K Q&A pairs │ │ - GPU: 30-60 min on RTX 4090 │ │ - CPU: 3-6 hours │ │ │ │ Determinism: fixed seeds, pinned library versions │ │ CPU training is bit-exact on x86_64 │ │ │ │ Output: LoRA adapter (~30-80 MB) │ └──────────────────────────────────────────────────────────────┘ │ ▼ ┌──────────────────────────────────────────────────────────────┐ │ Step 4: MERGE, QUANTIZE, PUBLISH │ │ │ │ Merge LoRA adapter into base weights │ │ Quantize to GGUF Q4_K_M → cyber-llm.gguf (~1.8 GB) │ │ ipfs add cyber-llm.gguf → model CID │ │ On-chain: commit {epoch, height, model_cid, hash} │ └──────────────────────────────────────────────────────────────┘ ``` ### Inference Architecture ``` cyber node or client │ ├── llama-server (subprocess, bundled binary) │ └── loads cyber-llm.gguf (~1.8 GB) │ └── serves OpenAI-compatible HTTP API on localhost:8091 │ ├── embedding index (in-process, Go) │ └── loads embedding.bin (~200 MB) + HNSW index │ └── retrieval: query → top-K relevant particles │ └── IPFS sidecar (subprocess) └── resolves CIDs to content for RAG context Query flow: 1. User sends question via gRPC/REST 2. Node embeds query → HNSW retrieval → top-K particles 3. Node resolves top-K CIDs via IPFS cache → text chunks 4. Node builds prompt: system + retrieved context + question 5. Node sends prompt to llama-server → streaming text response 6. Return generated answer to user ``` ### Four Managed Processes With LLM inference, cyb now orchestrates four processes: ``` cyb (tray app) ├── cyber (blockchain node, ~50 MB) ├── ipfs (Kubo IPFS node, ~50 MB) └── llama-server (LLM inference, ~5 MB binary + ~2 GB model) ``` Port map: | Port | Service | |------|---------| | 26656 | P2P (CometBFT) | | 26657 | CometBFT RPC | | 9090 | gRPC | | 1317 | REST API | | 26660 | Dashboard | | 5001 | IPFS API | | 8080 | IPFS Gateway | | **8091** | **llama-server (LLM inference)** | ### Embeddings Layer (cid2vec) — Retrieval Same as before but serves as the retrieval component for RAG: **Training:** TransE/RotatE from graph topology (minutes on CPU, 3M edges). **Model:** `embedding.bin` — flat `[3M × 64] float32` + HNSW index. ~200 MB after quantization. **gRPC endpoints (pure Go, no Python):** ```protobuf service Query { // Find particles with similar embeddings (retrieval for RAG) rpc Similar(QuerySimilarRequest) returns (QuerySimilarResponse); // Predict likely outgoing links rpc Predict(QueryPredictRequest) returns (QueryPredictResponse); // Raw embedding vector for a particle rpc Embedding(QueryEmbeddingRequest) returns (QueryEmbeddingResponse); // Current embedding model info rpc EmbeddingModel(QueryEmbeddingModelRequest) returns (QueryEmbeddingModelResponse); } ``` ### LLM Layer (cyber-LLM) — Generation **Runtime:** `llama-server` (from llama.cpp project) as subprocess. Bundled binary, ~5 MB. Supports: - Apple Silicon (Metal acceleration, native) - Linux (CUDA for NVIDIA, Vulkan for AMD/Intel) - CPU fallback everywhere **Integration from Go:** ```go // x/inference/keeper/llm.go type LLMClient struct { serverURL string // default: http://localhost:8091 } func (c *LLMClient) Generate(ctx context.Context, question string, context []string) (string, error) { // Build prompt with retrieved context systemPrompt := "You are a knowledge assistant. Answer based on the provided context from the cyber knowledge graph." contextText := strings.Join(context, "\n\n---\n\n") prompt := fmt.Sprintf("Context:\n%s\n\nQuestion: %s", contextText, question) resp, err := http.Post(c.serverURL+"/v1/chat/completions", "application/json", // OpenAI-compatible request ) return parseResponse(resp) } ``` **gRPC endpoints:** ```protobuf service Query { // Inference triggered by cyberlink: resolve question, generate answer, return answer CID // Caller must have already submitted MsgCyberlink(question_cid → INFERENCE_PARTICLE) rpc Infer(QueryInferRequest) returns (QueryInferResponse); // Request: { question_particle: string } (the CID that was linked to INFERENCE_PARTICLE) // Response: { answer_particle: string, answer_text: string, // sources: [{ particle: string, rank: uint64 }], model_epoch: uint64 } // Stream the answer token by token (same requirement: cyberlink must exist) rpc InferStream(QueryInferRequest) returns (stream QueryInferStreamResponse); // Current LLM model info (no link required) rpc LLMModel(QueryLLMModelRequest) returns (QueryLLMModelResponse); // Response: { epoch, height, model_cid, base_model, params_count, quantization } } ``` **Link validation:** The `Infer` endpoint checks that a cyberlink `(question_particle → INFERENCE_PARTICLE)` exists on-chain before running inference. No link = no inference. This is enforced at the gRPC handler level — not consensus, but node-side policy. **INFERENCE_PARTICLE:** A well-known CID registered at genesis (e.g. content "inference" → `QmInference...`). Linking to it signals "I want inference for this question". Different inference types could use different target particles (e.g. `QmSummary...` for summarization, `QmTranslate...` for translation). ### Model Distribution Two distributable artifacts per epoch: | Artifact | Size | Format | Purpose | |----------|------|--------|---------| | `embedding.bin` | ~200 MB | flat binary + HNSW | Retrieval (cid2vec) | | `cyber-llm.gguf` | ~1.8 GB | GGUF Q4_K_M | Generation (LLM) | | **Total** | **~2 GB** | | | Distribution via IPFS (content-addressed, verifiable): ``` On-chain commitment per epoch: { epoch: 42, height: 22451000, embedding_cid: "QmEmb...", // ~200 MB llm_cid: "QmLLM...", // ~1.8 GB embedding_hash: "sha256:...", llm_hash: "sha256:...", base_model: "llama-3.2-3b", lora_rank: 32, training_seed: 42 } ``` **Update strategy:** - Full model: download `cyber-llm.gguf` (~1.8 GB) — for first sync - LoRA adapter only: download `adapter.safetensors` (~30-80 MB) — for daily updates (clients already have base model) - llama.cpp supports runtime `--lora` adapter loading ### Determinism and Verification **LoRA adapter** (the trainable part) is deterministic on CPU with fixed seeds: ```python torch.manual_seed(42) torch.use_deterministic_algorithms(True) # CPU: bit-for-bit reproducible on x86_64 with pinned PyTorch version ``` **Verification protocol:** 1. Training config published on-chain: `{base_model_hash, training_data_cid, seed, hyperparams}` 2. Anyone can reproduce: download same base model + same training data + same config → same adapter hash 3. Merged GGUF hash committed on-chain 4. Validators with GPU can verify daily; light clients trust the commitment **Caveat:** Full determinism requires pinning: PyTorch version, Python version, OS (x86_64 Linux). Provide a Docker image or Nix flake as canonical training environment. ### Training Data from Graph Structure The knowledge graph provides unique training signals that generic LLMs don't have: **1. PageRank-weighted corpus (most important content seen more)** ```python for particle in sorted(particles, key=lambda p: p.rank, reverse=True): content = ipfs_resolve(particle.cid) repetitions = max(1, int(log(particle.rank * 1000))) # 1-7x for _ in range(repetitions): corpus.append(content) ``` **2. Graph walk sequences (linked content concatenated)** ```python def walk_sequence(start_cid, graph, max_tokens=2048): """Follow cyberlinks, concatenate resolved content""" seq = ipfs_resolve(start_cid) current = start_cid while len(tokenize(seq)) < max_tokens: neighbors = graph.outlinks(current) # weighted by stake next_cid = weighted_sample(neighbors) seq += "\n\n---\n\n" + ipfs_resolve(next_cid) current = next_cid return seq ``` **3. Link-based Q&A pairs** ``` Q: "How does [summary of content A] relate to [summary of content B]?" A: "These are linked in the knowledge graph: [content A] connects to [content B] through..." ``` **4. Graph structure Q&A** ``` Q: "What are the most important topics about X?" A: "Based on the knowledge graph, the top-ranked particles about X are: ..." (generated from Search(X) results + resolved content) ``` ### Configuration ```toml [inference] enabled = true [inference.embeddings] model_path = "data/embedding.bin" auto_update = true [inference.llm] enabled = true binary = "llama-server" # bundled or PATH model_path = "data/cyber-llm.gguf" # ~1.8 GB port = 8091 context_size = 4096 gpu_layers = 99 # auto: use GPU if available auto_update = true # download new model each epoch [inference.rag] top_k = 5 # retrieve top-K particles for context resolve_content = true # resolve CIDs via IPFS for context ``` ### Implementation Plan #### Phase A: Embeddings + Retrieval (Now, no consensus change) The retrieval layer can ship immediately with graph streaming (item 0.1). - [ ] Python script `scripts/train_embeddings.py`: TransE/RotatE on graph topology - [ ] Go embedding index in `x/inference`: load flat binary, HNSW search - [ ] gRPC: `Similar`, `Predict`, `Embedding`, `EmbeddingModel` - [ ] Benchmark: training time, retrieval quality (MRR, hits@10) #### Phase B: Content Resolution + Training Data (With IPFS sidecar) - [ ] Content resolver: bulk IPFS resolution of top-ranked particles - [ ] Content cache: `~/.cyber/data/content_cache/` with CID→text mapping - [ ] Corpus builder: PageRank-weighted + graph walk sequences - [ ] Synthetic Q&A generator: script using existing LLM to create training pairs - [ ] Training script `scripts/train_llm.py`: LoRA fine-tuning with deterministic config - [ ] Merge + quantize script: output GGUF Q4_K_M #### Phase C: Native LLM Inference in Node (Inference-via-Link) - [ ] Register `INFERENCE_PARTICLE` at genesis (well-known CID for inference requests) - [ ] Bundle `llama-server` binary in release artifacts - [ ] Process management: launch/monitor/restart llama-server from cyber node - [ ] LLM HTTP client in Go: query llama-server for generation - [ ] RAG pipeline: embed query → retrieve → resolve → generate - [ ] **Link validation:** `Infer` gRPC checks that cyberlink `(question → INFERENCE_PARTICLE)` exists on-chain before running - [ ] **Answer publishing:** node creates answer CID via IPFS, creates answer link `(question → answer)` - [ ] gRPC: `Infer`, `InferStream`, `LLMModel` - [ ] `[inference.llm]` section in `app.toml` - [ ] Dashboard integration: show LLM model info, inference stats, recent Q&A pairs - [ ] Support multiple inference types via different target particles (e.g. `QmSummary`, `QmTranslate`) #### Phase D: On-Chain Model Commitment (Consensus integration) - [ ] `MsgCommitModel` message type: `{epoch, embedding_cid, llm_cid, training_config_cid}` - [ ] Validator verification: re-run training from same data, compare hashes - [ ] Auto-download: node fetches new model from IPFS when new epoch committed - [ ] Governance: `inference_epoch_period` param (blocks between retraining) - [ ] Q&A feedback loop: track which answer particles get linked to by other neurons (quality signal) #### Phase E: Incremental Training + Optimization - [ ] Incremental LoRA: daily fine-tune on new content only (~30 min GPU) - [ ] **Include inference Q&A pairs in training data:** previous epoch's questions + answers feed next model - [ ] Weekly full retrain to prevent drift - [ ] LoRA adapter distribution (base model + small daily adapter, ~30-80 MB updates) - [ ] Evaluate 7B model for validators with more resources - [ ] Explore Rust training (burn/candle) to eliminate Python dependency ### Checklist Summary - [ ] **Phase A:** Embeddings pipeline + retrieval gRPC (pure Go) - [ ] **Phase B:** Content resolution, corpus building, LLM fine-tuning scripts - [ ] **Phase C:** llama-server sidecar, inference-via-link, RAG pipeline, Infer/InferStream gRPC - [ ] **Phase D:** On-chain model commitment, validator verification - [ ] **Phase E:** Incremental training with feedback loop, LoRA adapters --- ## Personal Networks: Private Knowledge Graphs with Sync ### Problem Launching a personal knowledge graph on go-cyber today requires understanding Cosmos SDK internals: genesis construction, gentx ceremony, validator setup, bech32 prefixes. The binary is hardcoded to bostrom. There is no path from "I want my own graph" to "it's running and syncing across my machines" without significant manual work. Goal: **`cyber network create my-graph` on one machine, `cyber network join` on another, graphs sync via consensus.** A personal or team knowledge graph that runs on your own machines with the same rank, inference, and IPFS infrastructure as bostrom. ### Why Not Solo Mode A single-node graph without consensus is just a database. The value is in **sync** — the same graph state replicated across laptop, server, phone. This requires consensus (even with 1 validator), because consensus gives you: - **Deterministic state** — every machine has the exact same graph after sync - **State-sync / snapshot** — new machine catches up fast - **Rank agreement** — all machines compute identical PageRank - **Model agreement** — inference model trained from identical graph - **IBC bridge** — personal graph can exchange links with bostrom or other personal graphs Solo mode without consensus is just SQLite. With consensus, it's a distributed knowledge computer. ### Current Blockers | Blocker | Details | |---------|---------| | **Hardcoded bostrom** | `Bech32Prefix = "bostrom"`, `appName = "BostromHub"`, denoms `"boot"/"hydrogen"` in 5+ files. Cannot change without recompiling. | | **No `--bech32-prefix` flag** | Prefix sealed at init-time from hardcoded constant. | | **Hardcoded valoper encoding** | `app.go:589`: `bech32.ConvertAndEncode("bostromvaloper", bz)` — crashes for non-bostrom prefixes. | | **Complex genesis ceremony** | Standard Cosmos flow: `init` → edit genesis → `add-genesis-account` → `gentx` → `collect-gentxs` → distribute genesis → `start`. 6+ manual steps for single-validator. | | **No peer discovery** | Peers are empty by default. Second machine needs manual `persistent_peers` configuration with node ID + IP + port. | | **No quick join** | New machine must get genesis.json + correct config + peer address manually. | ### Target UX ``` Machine A (creator): $ cyber network create my-graph → generates genesis with single validator (this machine) → picks random denom name or uses default → starts the chain → prints join token: "cyber network join " → token = base64(genesis_hash + peer_addr + chain_id) Machine B (joiner): $ cyber network join eyJjaGFp... → decodes token → gets genesis + peer address → initializes node with matching genesis → connects to Machine A as persistent peer → state-syncs (with graph + rank snapshots from item 1.3) → running — same graph, same rank, same state Machine C (another join): $ cyber network join eyJjaGFp... → same flow, now 3 nodes in the network → all three have identical graph state ``` ### Architecture ``` cyber network create my-graph │ ├── 1. Generate keypair (validator key) ├── 2. Build genesis.json: │ chain_id: "my-graph-1" │ bech32_prefix: "cyber" (default, configurable) │ denom: "stake" (default, configurable) │ single validator with all initial tokens │ all cyber modules enabled (graph, rank, bandwidth, etc.) │ sane defaults for personal use: │ - bandwidth: relaxed (high base, low price) │ - rank: CalculationPeriod=5 (keep frequent) │ - block time: 1s (low-latency for personal use) │ ├── 3. Write config.toml: │ listen on 0.0.0.0 (accessible from LAN) │ fast block times (timeout_commit = 1s) │ ├── 4. Start chain │ └── 5. Print join token: cyber network join eyJjaGFpbklkIjoibXktZ3Jh... cyber network join │ ├── 1. Decode token: │ { chain_id, genesis_hash, peer_addrs, rpc_addr } │ ├── 2. Fetch genesis from peer: │ GET http://:26657/genesis → verify hash │ ├── 3. Initialize node: │ cyber init --home ~/.cyber- │ replace genesis.json with fetched one │ set persistent_peers in config.toml │ ├── 4. State-sync or full sync: │ if snapshots available (item 1.3): fast state-sync │ includes graph + rank data → instant graph access │ └── 5. Start chain connected to creator's node, syncing ``` ### Join Token The join token encodes everything a new node needs to connect: ```json { "chain_id": "my-graph-1", "genesis_hash": "sha256:abc123...", "peers": ["node_id@192.168.1.10:26656"], "rpc": "http://192.168.1.10:26657" } ``` Base64-encoded → single copyable string. Similar to how WireGuard or Tailscale share connection configs. For LAN discovery: optionally, nodes could broadcast mDNS/Bonjour so `cyber network join` auto-discovers peers on the same network without a token. ### Validator Topology for Personal Networks Single-validator is the common case (your laptop = the validator). But the system supports adding more: ``` Scenario A: One person, multiple machines - Laptop creates network, is the validator - Server joins as full node (syncs graph, not a validator) - Phone joins as light client (graph streaming from item 0.1) Scenario B: Team / small group - Machine A creates network, is validator - Machine B joins, becomes validator via staking TX - Now 2 validators — network survives if one goes offline - Machine C joins as full node ``` For single-validator personal use: if the validator goes offline, the chain pauses. When it comes back — resumes. This is fine for personal graphs. ### Multi-Network Support A single cyb (tray app) can manage multiple networks: ``` cyb tray menu: ┌─────────────────────────────┐ │ 🟢 bostrom (main network) │ │ Height: 22.4M │ │ 🟢 my-graph (personal) │ │ Height: 1,234 │ │ 🟡 team-wiki (team) │ │ Height: 567, syncing │ ├─────────────────────────────┤ │ Create New Network... │ │ Join Network... │ └─────────────────────────────┘ ``` Each network runs in its own home directory (`~/.cyber-/`) with its own data, config, and ports. Port allocation is automatic (26656, 26756, 26856, ...). ### IBC Between Personal Graphs and Bostrom Once both personal network and bostrom run IBC (already available in go-cyber v7), personal graphs can bridge to the global network: ``` Personal graph ←──IBC──→ Bostrom Use cases: - Publish selected links from personal graph to bostrom (selective sharing) - Pull high-rank content from bostrom into personal graph - Cross-reference: personal notes linked to public knowledge - Team graph publishes research to bostrom when ready ``` This is standard IBC relaying — no new code needed, just configuration. The personal chain and bostrom are both Cosmos SDK chains with IBC modules. ### Relation to Multi-Chain Binary (Item 1.6) The multi-chain binary work (planned for space-pussy unification) is the **prerequisite** for personal networks: | Multi-chain binary gives | Personal networks use it for | |--------------------------|------------------------------| | Configurable bech32 prefix | Each network has its own prefix (or shares "cyber") | | Denoms from genesis | Each network names its own tokens | | Chain-id switch in upgrade handlers | Not needed for personal (no upgrades from mainnet state) | | Single binary serves any genesis | `cyber network create` just generates a new genesis | Once the binary is chain-agnostic, `cyber network create` is mostly genesis generation + config templating + a join token printer. The hard part (making the binary multi-chain) is already scoped in item 1.6. ### Personal Network Defaults (Tuned for Personal Use) | Parameter | Bostrom Default | Personal Default | Why | |-----------|----------------|-----------------|-----| | Block time | ~5s | **1s** | Low latency, single validator | | Bandwidth BasePrice | 0.25 | **0.01** | Relaxed — it's your own network | | Bandwidth RecoveryPeriod | 100 | **10** | Fast recovery | | Rank CalculationPeriod | 5 | **5** | Keep same — rank is fast on small graphs | | Max validators | 150 | **10** | Personal networks are small | | Min gas price | varies | **0** | No fees on personal network | | Staking unbonding | 21 days | **1 hour** | Personal use, no adversarial setting | ### Checklist **Prerequisites (from other items):** - [ ] Multi-chain binary (item 1.6): configurable bech32, denoms from genesis - [ ] Snapshot extensions (item 1.3): graph + rank in state-sync for fast join **`cyber network create`:** - [ ] Subcommand: generates genesis, validator key, starts chain — all in one step - [ ] Genesis template with personal-network defaults (relaxed bandwidth, fast blocks, zero gas) - [ ] Configurable: `--denom`, `--bech32-prefix`, `--chain-id` flags - [ ] Join token generation: base64 encoded `{chain_id, genesis_hash, peers, rpc}` - [ ] Print join command to stdout after start **`cyber network join`:** - [ ] Decode join token → fetch genesis from RPC → verify hash - [ ] Auto-configure: persistent_peers, chain-id, home directory - [ ] State-sync by default (if snapshots available) - [ ] Fallback to full sync from genesis **`cyber network list`:** - [ ] List all local networks (scan `~/.cyber-*/config/genesis.json`) - [ ] Show: chain_id, height, peers, running status **Multi-network support:** - [ ] Separate home directories per chain-id (`~/.cyber-/`) - [ ] Automatic port allocation (avoid conflicts between networks) - [ ] cyb tray: manage multiple networks from one menu **Optional / Future:** - [ ] LAN auto-discovery (mDNS/Bonjour): `cyber network join --auto` finds peers on local network - [ ] IBC relayer setup between personal graph and bostrom - [ ] `cyber network invite` — generate a new join token for an existing network - [ ] `cyber network export` — export graph as flat file for offline sharing --- ## Inter-Knowledge Protocol (IKP): Graph Sync Over IBC ### Problem IBC moves tokens and messages between chains. But knowledge graphs need to sync **particles, cyberlinks, and rank** — not tokens. When a personal graph wants to publish selected links to bostrom, or pull high-rank content from bostrom into a team graph, raw IBC transfer doesn't help. There is no protocol that understands the semantic structure of a knowledge graph. Goal: **a protocol layer over IBC that enables selective, bidirectional sync of knowledge graph data between any two go-cyber chains.** Personal ↔ bostrom, team ↔ bostrom, personal ↔ personal. ### What IBC Gives Us (Transport Layer) go-cyber already has a full IBC stack: - IBC Transfer (token moves) - IBC Hooks (wasm contract triggers on packet receive) - Packet Forward Middleware (multi-hop routing) - ICA (interchain accounts) - ICQ (interchain queries) - Wasm IBC handler (contracts can send/receive IBC packets) IBC provides: reliable packet delivery, channel management, timeout handling, light client verification. IKP builds on top. ### What IKP Adds (Knowledge Layer) | IBC (transport) | IKP (knowledge) | |-----------------|------------------| | Sends bytes between chains | Sends particles + cyberlinks + rank signals | | Channels between ports | Knowledge channels between graphs | | Token denomination tracking | Particle origin tracking (which chain created this CID) | | Fungible transfer | Non-fungible graph structure sync | ### Protocol Design #### Packet Types IKP defines 3 packet types carried over an IBC channel: ``` 1. SyncCyberlinks — create cyberlinks on the receiving chain 2. ShareRankSignal — share rank values as advisory weights 3. RequestSubgraph — pull a subgraph from the remote chain ``` No separate "SyncParticles" — particles in go-cyber auto-register on first use via `GetOrPutCidNumber()`. Sending cyberlinks is sufficient; CIDs register themselves on arrival. #### Packet 1: SyncCyberlinks (Core) ```protobuf message IKPSyncCyberlinksPacket { repeated IKPCyberlink links = 1; string source_chain_id = 2; uint64 source_height = 3; } message IKPCyberlink { string from_cid = 1; // CID string (not number — portable) string to_cid = 2; // CID string string source_neuron = 3; // original author address on source chain uint64 source_weight = 4; // normalized stake on source chain (advisory) } ``` **Key design decisions:** **Who is the neuron on the receiving chain?** Links on the receiving chain need an `Account` (neuron). Three options: | Approach | How | Pros | Cons | |----------|-----|------|------| | **Bridge neuron** (module account) | All IBC links attributed to `ikp-bridge` module account | Simple, no auth complexity | Loses original authorship. One account = all imported links have equal weight | | **Derived address** | `neuron = hash(source_chain_id + source_neuron)` → deterministic address per-source-author | Preserves per-author distinction | Derived accounts have no stake → zero weight in rank. Need "virtual stake" | | **Mapped address** | Source neuron registers a local account on dest chain, links mapped to it | Full authorship preservation | Requires pre-registration, complex UX | **Recommended: Derived address + virtual stake.** Each source chain gets a "trust weight" set by governance or channel config. Links from that chain's neurons get virtual stake proportional to: ``` virtual_stake(link) = channel_trust_weight × source_weight(link) ``` This means: bostrom can assign high trust to links from a known team's graph, and low trust to random unknown personal graphs. The receiving chain controls how much influence imported links have on its rank. **Bandwidth cost:** Imported links should cost bandwidth on the receiving chain — otherwise they're a spam vector. Two options: - Relayer pays bandwidth (like IBC relayer pays gas) - Channel has a "bandwidth budget" per epoch (governance-set) **Deduplication:** Same `(from_cid, to_cid, derived_neuron)` on the receiving chain = link already exists → no-op. IAVL key structure already handles this naturally. #### Packet 2: ShareRankSignal (Advisory) ```protobuf message IKPShareRankSignalPacket { repeated IKPRankEntry ranks = 1; string source_chain_id = 2; uint64 source_height = 3; uint64 source_cid_count = 4; // total particles on source for normalization } message IKPRankEntry { string cid = 1; uint64 rank_value = 2; // PageRank × 10^15 on source chain } ``` **This is NOT consensus-binding.** Rank signals from other chains are advisory data. The receiving chain can: - Store them in a separate index (not in consensus state) - Use them as **boost signals** in local rank display (UI re-ranking, not PageRank modification) - Use them as **training signals** for the inference model (external rank as node feature) - Ignore them entirely Rank cannot be directly "imported" because PageRank depends on the entire topology. But knowing that a particle is highly ranked on bostrom is useful information for a personal graph's UI and inference. #### Packet 3: RequestSubgraph (Pull) ```protobuf message IKPRequestSubgraphPacket { oneof request { string particle_cid = 1; // "give me all links to/from this CID" string neuron_address = 2; // "give me all links by this neuron" uint64 min_rank = 3; // "give me all particles with rank > X" uint64 since_height = 4; // "give me all links since height H" } uint32 max_links = 5; // pagination } ``` Response comes as a `SyncCyberlinks` packet. This enables **pull-based sync**: personal graph asks bostrom "what are the top 1000 particles about topic X?" and bostrom responds with the relevant subgraph. ### Sync Modes | Mode | Direction | Trigger | Use Case | |------|-----------|---------|----------| | **Push** | Source → Dest | Source decides what to export | Publish personal notes to bostrom | | **Pull** | Dest ← Source | Dest requests specific subgraph | Import bostrom knowledge into personal graph | | **Mirror** | Bidirectional, continuous | Auto-sync all new links | Two machines syncing the same personal graph (but this is already handled by consensus within the same chain) | | **Selective push** | Source → Dest, filtered | Source filters by neuron, topic, or rank | Team publishes only their reviewed research | ### Channel Configuration Each IKP channel has parameters set at channel opening: ```protobuf message IKPChannelConfig { uint64 trust_weight = 1; // how much rank influence imported links get (0-10000 basis points) uint64 bandwidth_budget = 2; // max links per epoch via this channel bool allow_pull = 3; // whether remote can request subgraphs bool auto_sync = 4; // continuously forward new links repeated string neuron_filter = 5; // only sync links from these neurons (empty = all) uint64 min_rank_filter = 6; // only sync particles with rank above this } ``` ### Architecture ``` Chain A (e.g., personal graph) Chain B (e.g., bostrom) ┌──────────────────────────┐ ┌──────────────────────────┐ │ x/graph (local graph) │ │ x/graph (local graph) │ │ x/rank (local rank) │ │ x/rank (local rank) │ │ │ │ │ │ x/ikp │ │ x/ikp │ │ ├── IKP Keeper │ │ ├── IKP Keeper │ │ ├── Link Filter │ │ ├── Link Filter │ │ ├── Trust Weight Mgr │ │ ├── Trust Weight Mgr │ │ └── IBC Module impl │ │ └── IBC Module impl │ │ │ │ │ │ │ │ └──── IBC ───────┼───────────┼─────────┘ │ │ Channel │ │ Channel │ └──────────────────────────┘ └──────────────────────────┘ Data flow (push): 1. Neuron on Chain A creates cyberlinks normally 2. IKP module sees new links (EndBlocker hook or event listener) 3. If auto_sync on channel: build SyncCyberlinks packet 4. Apply neuron_filter + min_rank_filter 5. Send packet over IBC 6. Chain B receives packet 7. Chain B creates links with derived neuron address + virtual stake 8. Chain B's graph grows, rank recalculates 9. Chain B acknowledges packet Data flow (pull): 1. Chain A sends RequestSubgraph(particle_cid="QmFoo") 2. Chain B receives, queries local graph for QmFoo subgraph 3. Chain B responds with SyncCyberlinks packet 4. Chain A receives, creates links locally ``` ### Trust and Rank Interaction This is the most subtle part. How do imported links affect the receiving chain's PageRank? ``` Local PageRank computation: - Local links: neuron has real stake → real weight in rank - Imported links: derived neuron has virtual_stake = channel_trust × source_weight virtual_stake is NOT real staking tokens. It's a parameter set per-channel. Example: Channel bostrom↔personal has trust_weight = 5000 (50%) Link from bostrom neuron with source_weight 1000 → virtual_stake on personal chain = 500 This means: imported links from bostrom have 50% the influence of equivalent local links. Tunable per-channel. ``` **Why not import rank directly?** PageRank is a global property of the entire graph topology. You can't meaningfully "add" rank from one graph to another — the matrices are different sizes, the damping factors mix differently, the topology is different. What you CAN do: 1. Import links → they participate in local rank computation naturally 2. Use remote rank as a UI boost (display, not consensus) 3. Use remote rank as inference model feature ### Relation to Existing Modules | Existing | IKP Uses | |----------|----------| | `x/graph` GraphKeeper | `GetOrPutCidNumber()`, `SaveLink()` — creating particles and links on receive | | `x/graph` IndexKeeper | `PutLink()` — update in-memory index after import | | `x/bandwidth` | Cost accounting for imported links | | `x/cyberbank` | Virtual stake accounting for derived neurons | | `x/rank` | Imported links participate in rank computation via virtual stake | | IBC Keeper | Channel management, packet routing | | Capability Keeper | Scoped capability for IKP port | ### Implementation Plan #### Phase A: Basic Link Sync (With SDK v0.50 + IBC v8) Minimum viable IKP: push cyberlinks from one chain to another. - [ ] New module `x/ikp` implementing `porttypes.IBCModule` - [ ] `SyncCyberlinks` packet type: send links, receive and create on dest - [ ] Derived neuron address: `hash(source_chain + source_neuron)` → deterministic account - [ ] Fixed trust weight per channel (set at channel open) - [ ] Bandwidth cost: relayer pays, or fixed budget per channel - [ ] CLI: `cyber ikp push --channel --neuron ` (push all links from a neuron) - [ ] CLI: `cyber ikp push --channel --particle ` (push all links to/from a CID) #### Phase B: Pull + Selective Sync - [ ] `RequestSubgraph` packet: request links by particle, neuron, rank threshold, or height - [ ] Channel configuration: neuron filter, rank filter, bandwidth budget - [ ] Auto-sync mode: EndBlocker hook forwards new links matching filter criteria - [ ] CLI: `cyber ikp pull --channel --particle ` (pull subgraph from remote) #### Phase C: Rank Signals + Trust Tuning - [ ] `ShareRankSignal` packet: share rank values as advisory data - [ ] Rank signal storage (separate from consensus rank — off-chain index) - [ ] Governance: update `trust_weight` per channel via `MsgUpdateChannelTrust` - [ ] Dashboard: show imported links, their source chains, trust weights - [ ] Use imported rank signals as node features in inference model training #### Phase D: Multi-Chain Knowledge Network - [ ] Relayer config templates for IKP channels (Hermes / Go relayer) - [ ] Auto-channel setup in `cyber network create` (IKP channel to bostrom by default) - [ ] Graph federation: personal graph ↔ team graph ↔ bostrom — multi-hop knowledge routing - [ ] Reputation system: channels that import high-quality links (as judged by local rank over time) get trust_weight increased automatically ### Checklist Summary - [ ] **Phase A:** `x/ikp` module, SyncCyberlinks, derived neurons, basic push - [ ] **Phase B:** Pull requests, selective sync, channel filters, auto-sync - [ ] **Phase C:** Rank signals, trust governance, inference integration - [ ] **Phase D:** Multi-chain federation, auto-channels, reputation --- ## CybeRank Computation Fixes (Consensus-Breaking) These issues were found during a code audit of the rank computation (`x/rank/keeper/calculate_cpu.go`, `x/rank/cuda/rank.cu`). They require a coordinated chain upgrade since they affect consensus state (rank values feed into the on-chain merkle tree commitment). ### Issue 1: CRITICAL — Divide by Zero in `getNormalizedStake()` (CPU only) **File:** `x/rank/keeper/calculate_cpu.go:94-96` ```go func getNormalizedStake(ctx *types.CalculationContext, agent uint64) uint64 { return ctx.GetStakes()[agent] / ctx.GetNeudegs()[agent] } ``` If `neudeg == 0` for any account appearing in links, this **panics** with integer divide by zero. The GPU code guards against this (`calculate_gpu.go:48-53`): ```go if neudeg != 0 { stakes[neuron] = stake / neudeg } else { stakes[neuron] = 0 } ``` The CPU code does not have this guard. This is a **CPU/GPU divergence** — if the same edge case is hit, GPU returns 0 while CPU crashes. **Fix:** ```go func getNormalizedStake(ctx *types.CalculationContext, agent uint64) uint64 { neudeg := ctx.GetNeudegs()[agent] if neudeg == 0 { return 0 } return ctx.GetStakes()[agent] / neudeg } ``` ### Issue 2: MEDIUM — Dangling Node Detection Uses Wrong Direction **File:** `x/rank/keeper/calculate_cpu.go:26` ```go if len(inLinks[graphtypes.CidNumber(i)]) == 0 { danglingNodesSize++ } ``` Standard PageRank defines **dangling nodes** as nodes with **no outgoing links** (sinks). This code counts nodes with **no incoming links** instead. Both CPU and GPU implementations have this same behavior — it's consistent but deviates from textbook PageRank. Additionally, `defaultRankWithCorrection` is computed **once** before iteration and frozen. In standard PageRank, dangling mass must be recomputed each iteration as rank values change. **Impact:** The algorithm converges to a well-defined fixed point, but it is not the textbook PageRank fixed point. Whether to fix this is a design decision — changing it would alter all rank values. ### Issue 3: MEDIUM — Potential Integer Overflow in Stake Accumulation **Files:** `calculate_cpu.go:78-83`, `calculate_cpu.go:86-92` `getOverallLinkStake()` and `getOverallOutLinksStake()` accumulate `uint64` sums without overflow checks. With high stakes (e.g., 10^18 per account) and many contributors per link, the sum could exceed `uint64` max (~1.84 × 10^19), silently wrapping around and producing incorrect weights. **Fix:** Add overflow-safe arithmetic or assert bounds on individual normalized stakes. ### Issue 4: LOW — Nodes Without In-Links Miss Correction Term **File:** `calculate_cpu.go:54` `step()` only iterates `ctx.GetInLinks()`, so nodes without incoming links retain `defaultRank = (1-d)/N` instead of `defaultRankWithCorrection = d*(danglingMass/N) + (1-d)/N`. They miss the redistribution correction. Both CPU and GPU have this same behavior. ### Issue 5: PERFORMANCE — `getOverallOutLinksStake()` Redundant Recomputation **File:** `calculate_cpu.go:86-92` The total outgoing stake for a CID is recomputed every time it appears as a source in some other CID's in-links. This is O(|V| × avg_degree²). The GPU precomputes this once. Could be memoized in the CPU path for significant speedup. ### Rank Fix Checklist These fixes must ship as part of a chain upgrade (Step 1 or a dedicated rank-fix upgrade): - [ ] Fix `getNormalizedStake` divide by zero guard (CPU parity with GPU) - [ ] Decide on dangling node direction: keep as-is (document) or fix to standard PageRank (consensus-breaking) - [ ] Add overflow protection to stake accumulation - [ ] Document the intentional deviations from textbook PageRank - [ ] If any rank computation changes are made: compute expected rank delta on mainnet state export to assess migration impact - [ ] Precompute `getOverallOutLinksStake` per CID in the CPU path (performance, not consensus) --- ## Execution Checklist ### Pre-work - [ ] Verify in-place testnet command exists natively in SDK v0.50 - [ ] Confirm fork can be fully eliminated — switch `go.mod` replace to upstream `github.com/cosmos/cosmos-sdk v0.50.15` - [ ] Audit all custom modules for `x/params` usage, `BeginBlock`/`EndBlock` implementations, and `sdk.Context` in keeper methods - [ ] Set up a testnet environment for migration testing ### Step 0: Remove x/liquidity (before SDK migration) - [ ] Add new upgrade version (e.g. `v8`) with `StoreUpgrades.Deleted` for `liquidity` store key - [ ] Remove `x/liquidity` module code and all references from `app/app.go` - [ ] Remove `liquiditytypes.ParamKeyTable()` case from v4 upgrade handler params migration - [ ] Remove liquidity-related `RegisterCustomTypeURL` calls from codec registration - [ ] Remove liquidity keeper, message server, and gRPC query server wiring - [ ] Clean up any remaining references in genesis, params, and module registrations - [ ] Verify the `RegisterCustomTypeURL` SDK fork change is no longer needed (sole consumer was `x/liquidity`) - [ ] Test upgrade against bostrom mainnet state export (in-place testnet) - [ ] Mainnet upgrade proposal and execution ### Step 1: SDK v0.50 - [ ] **Eliminate the cosmos-sdk fork** — remove the `go.mod` replace directive and use upstream SDK v0.50.15 (the `RegisterCustomTypeURL` fork change is no longer needed after liquidity removal in Step 0) - [ ] Switch to native in-place testnet command from SDK v0.50 - [ ] Migrate all custom modules: - [ ] Replace `sdk.Context` with `context.Context` in keeper methods - [ ] Replace `BeginBlock`/`EndBlock` with the new signatures returning `error` - [ ] Remove `ValidateBasic()` and `GetSignBytes()` from messages - [ ] Add `cosmos.msg.v1.signer` protobuf annotations - [ ] Migrate parameters out of `x/params` into direct module storage - [ ] Rewrite `app.go`: - [ ] Replace `ModuleBasics` with `module.NewBasicManagerFromManager()` - [ ] Add `PreBlocker` with upgrade module - [ ] Add store upgrades for `circuit` and `feeibc` - [ ] Migrate to `KVStoreService` from `StoreKey` - [ ] Update CometBFT v0.37 -> v0.38 package references - [ ] Update IBC-Go v7 -> v8 - [ ] Update ibc-apps: PFM v8, async-icq v8, ibc-hooks v8 - [ ] Update wasmd v0.46 -> v0.54.6 and wasmvm v1.5 -> v2.2 - [ ] Update protobuf code generation if needed - [ ] Write and test state migration handler - [ ] Full testnet deployment and validation - [ ] Mainnet upgrade proposal and execution ### Step 2: SDK v0.53 + CosmWasm 3.0 - [ ] Update Cosmos SDK v0.50 -> v0.53.6 - [ ] Add `x/auth` PreBlocker to `SetOrderPreBlockers` - [ ] Update module imports to `cosmossdk.io/x/{moduleName}` where applicable - [ ] Update IBC-Go v8 -> v10: - [ ] Remove capabilities module and all scoped keepers - [ ] Remove IBC fee middleware (ICS-29) - [ ] Wire IBC v2 stack alongside classic stack - [ ] Wire light client modules explicitly - [ ] Update wasmd v0.54 -> v0.61.8 and wasmvm v2.2 -> v3.0 - [ ] Update PFM v8 -> v10 - [ ] Assess async-icq and ibc-hooks (v10 releases may not be available) - [ ] Update Go version to 1.23.2+ - [ ] Testnet deployment and validation - [ ] Mainnet upgrade proposal and execution --- ## Risk Assessment | Risk | Severity | Mitigation | |---|---|---| | Cosmos SDK fork elimination | **Medium** (downgraded from High) | Fork has only 4 commits. `RegisterCustomTypeURL` solvable via type assertion; in-place testnet is upstreamed. Plan is to eliminate the fork entirely, not rebase it | | State migration failure | **High** | Extensive testnet testing with mainnet state export | | ibc-hooks / async-icq lacking v10 releases | **Medium** | Can stay on Step 1 (IBC v8) until releases appear. Or use unreleased branches | | Gas parameter recalibration (wasmvm 1000x change) | **Medium** | Benchmark contract gas usage on testnet before mainnet | | Breaking changes in custom modules | **Medium** | Systematic migration of each module with unit tests | | Database backend incompatibility | **Low** | go-cyber uses goleveldb/rocksdb which remain supported | | Space-pussy v0.45->v0.50 state migration | **High** | Largest version jump (3 SDK majors, 4 IBC majors). Test extensively with mainnet state. Akash successfully did v0.45->v0.53 as precedent | | Hardcoded denom/prefix refactor | **Medium** | Systematic search-and-replace across 13+ files. Must not break bostrom compatibility. Test both chains | | Space-pussy validator coordination | **Medium** | Space-pussy has its own validator set that must coordinate the binary swap. Adequate notice and testing required | | wgpu f32 precision for consensus | **High** | f32 may not produce identical merkle roots as f64. Requires empirical testing on mainnet state. Fallback: CPU or emulated f64 | | wgpu cross-vendor determinism | **Medium** | Different GPU vendors may produce different float results. Requires NoContraction annotations and extensive testing | | Apple Silicon f64 absence | **Low** (design constraint) | Accept f32 on Metal or use CPU. Not a risk — a known platform limitation to design around | | LLM training determinism | **Medium** | LoRA fine-tuning on CPU with fixed seeds is bit-exact on x86_64. Different architectures (ARM) may differ. Mitigation: canonical Docker/Nix training environment on x86_64 Linux | | LLM quality on graph corpus (~1.5 GB text) | **Low** | 1.5 GB of domain text is sufficient for LoRA fine-tuning. Fine-tuned 3B matches general 7B on domain tasks. Synthetic Q&A pairs critical for instruction-following quality | | Python dependency for training | **Medium** | Training requires PyTorch — acceptable as offline process (cron/script), never in consensus path. Inference uses llama-server (C++ binary). Future: Rust training (burn/candle) to eliminate Python | | LLM + embeddings distribution size | **Medium** | ~2 GB total (1.8 GB GGUF + 200 MB embeddings). Comparable to state-sync snapshot. Distribute via IPFS. Daily updates via LoRA adapter only (~30-80 MB) | | Content resolution for training | **Medium** | Requires IPFS sidecar + time to resolve 3M CIDs. Many CIDs may be unavailable. Mitigation: train on available content, weighted by PageRank (high-rank content more likely pinned) | | llama-server as fourth managed process | **Low** | Same pattern as IPFS sidecar — subprocess managed by cyb. Separate lifecycle, crash doesn't affect consensus. ~5 MB binary + ~2 GB model | | Personal networks: port conflicts | **Low** | Automatic port allocation per chain-id. Each network gets its own port range (26656+N*100). cyb manages this | | Personal networks: single-validator liveness | **Low** (design constraint) | If validator goes offline — chain pauses, resumes when back. Acceptable for personal use. For teams: add second validator | | IKP: spam via imported links | **Medium** | Imported links cost bandwidth (relayer pays or channel budget). Trust weight controls rank influence. Governance can close abusive channels | | IKP: derived neuron stake | **Medium** | Derived neurons have no real stake — need virtual stake mechanism. Must be carefully designed to prevent rank manipulation via cheap personal chains | ## Reference Chains These chains have completed similar migrations and their repositories can serve as reference implementations: | Chain | Migration | Repository | |---|---|---| | Cosmos Hub (Gaia) | SDK v0.47 -> v0.53 | github.com/cosmos/gaia | | Akash Network | SDK v0.45 -> v0.53 (skipped v0.47/v0.50) | github.com/akash-network/node | | Osmosis | SDK v0.47 -> v0.50 | github.com/osmosis-labs/osmosis | | Neutron | SDK v0.47 -> v0.50 (CosmWasm chain) | github.com/neutron-org/neutron | ## Sources - [Cosmos SDK Releases](https://github.com/cosmos/cosmos-sdk/releases) - [Cosmos SDK v0.50 UPGRADING.md](https://github.com/cosmos/cosmos-sdk/blob/release/v0.50.x/UPGRADING.md) - [CometBFT Releases](https://github.com/cometbft/cometbft/releases) - [IBC-Go Releases](https://github.com/cosmos/ibc-go/releases) - [IBC-Go v7 to v8 Migration](https://ibc.cosmos.network/main/migrations/v7-to-v8/) - [IBC-Go v8.1 to v10 Migration](https://ibc.cosmos.network/main/migrations/v8_1-to-v10/) - [CosmWasm/wasmd Releases](https://github.com/CosmWasm/wasmd/releases) - [CosmWasm 3.0 Announcement](https://medium.com/cosmwasm/cosmwasm-3-0-fd84d72c2d35) - [CosmWasm 2.1 / 2.2 Announcements](https://medium.com/cosmwasm) - [The Cosmos Stack Roadmap for 2026](https://www.cosmoslabs.io/blog/the-cosmos-stack-roadmap-2026) - [IAVL v1.0 Performance](https://medium.com/the-interchain-foundation/iavl-v1-0-optimizing-storage-in-the-cosmos-sdk-41e871e4ec1c) - [Optimistic Execution in SDK](https://medium.com/the-interchain-foundation/optimistic-execution-landing-in-the-cosmos-sdk-a28fc72af650) - [cosmos/ibc-apps Repository](https://github.com/cosmos/ibc-apps) ================================================ FILE: entrypoint.sh ================================================ #!/bin/sh ln -s /root/.cyber/cosmovisor/current/bin/cyber /usr/bin/cyber if [ ! -d "/root/.cyber/" ] then mkdir /root/.cyber/ mkdir /root/.cyber/config/ /cyber/cosmovisor/genesis/bin/cyber init ${NODE_MONIKER} cp -r /cyber/cosmovisor/ /root/.cyber fi if [ ! -f "/root/.cyber/config/node_key.json" ] then /cyber/cosmovisor/genesis/bin/cyber init ${NODE_MONIKER} cp /genesis.json /root/.cyber/config/ cp -r /cyber/cosmovisor/ /root/.cyber fi if [ ! -d "/root/.cyber/cosmovisor" ] then cp -r /cyber/cosmovisor/ /root/.cyber/ fi if [ ! -d "/root/.cyber/cosmovisor/updgrades" ] then cp -r /cyber/cosmovisor/upgrades /root/.cyber/cosmovisor/ fi if [ -d "/root/.cyber/cosmovisor/upgrades/v4/" ] then cp -r /cyber/cosmovisor/upgrades/v4 /root/.cyber/cosmovisor/upgrades/v4 fi if [ -d "/root/.cyber/cosmovisor/upgrades/v6/" ] then cp -r /cyber/cosmovisor/upgrades/v6 /root/.cyber/cosmovisor/upgrades/v6 fi if [ -d "/root/.cyber/cosmovisor/upgrades/v7/" ] then cp -r /cyber/cosmovisor/upgrades/v7 /root/.cyber/cosmovisor/upgrades/v7 fi if [ ! -f "/root/.cyber/config/genesis.json" ] then cp /genesis.json /root/.cyber/config/ fi if [ "$2" = 'init' ] then return 0 else exec "$@" fi ================================================ FILE: go.mod ================================================ module github.com/cybercongress/go-cyber/v7 go 1.22.7 require ( cosmossdk.io/api v0.3.1 cosmossdk.io/errors v1.0.1 cosmossdk.io/math v1.4.0 cosmossdk.io/simapp v0.0.0-20230323161446-0af178d721ff cosmossdk.io/tools/rosetta v0.2.1 github.com/CosmWasm/wasmd v0.46.0 github.com/CosmWasm/wasmvm v1.5.9 github.com/armon/go-metrics v0.4.1 github.com/cometbft/cometbft v0.37.18 github.com/cometbft/cometbft-db v0.12.0 github.com/cosmos/cosmos-proto v1.0.0-beta.5 github.com/cosmos/cosmos-sdk v0.47.16 github.com/cosmos/gogoproto v1.7.0 github.com/cosmos/iavl v0.20.1 github.com/cosmos/ibc-apps/middleware/packet-forward-middleware/v7 v7.3.0 github.com/cosmos/ibc-apps/modules/async-icq/v7 v7.1.1 github.com/cosmos/ibc-apps/modules/ibc-hooks/v7 v7.0.0 github.com/cosmos/ibc-go/v7 v7.10.0 github.com/golang/protobuf v1.5.4 github.com/gorilla/mux v1.8.0 github.com/grpc-ecosystem/grpc-gateway v1.16.0 github.com/ipfs/go-cid v0.0.7 github.com/prometheus/client_golang v1.20.5 github.com/rakyll/statik v0.1.7 // indirect github.com/spf13/cast v1.6.0 github.com/spf13/cobra v1.8.1 github.com/spf13/pflag v1.0.5 github.com/spf13/viper v1.19.0 github.com/stretchr/testify v1.10.0 github.com/syndtr/goleveldb v1.0.1-0.20220721030215-126854af5e6d google.golang.org/genproto/googleapis/api v0.0.0-20240903143218-8af14fe29dc1 google.golang.org/grpc v1.68.0 gopkg.in/yaml.v2 v2.4.0 ) require ( cloud.google.com/go v0.112.1 // indirect cloud.google.com/go/compute/metadata v0.5.0 // indirect cloud.google.com/go/iam v1.1.6 // indirect cloud.google.com/go/storage v1.38.0 // indirect cosmossdk.io/core v0.6.1 // indirect cosmossdk.io/depinject v1.0.0-alpha.4 // indirect cosmossdk.io/log v1.4.1 // indirect filippo.io/edwards25519 v1.0.0 // indirect github.com/99designs/go-keychain v0.0.0-20191008050251-8e49817e8af4 // indirect github.com/99designs/keyring v1.2.2 // indirect github.com/ChainSafe/go-schnorrkel v1.1.0 // indirect github.com/DataDog/zstd v1.5.2 // indirect github.com/aws/aws-sdk-go v1.44.203 // indirect github.com/beorn7/perks v1.0.1 // indirect github.com/bgentry/go-netrc v0.0.0-20140422174119-9fd32a8b3d3d // indirect github.com/bgentry/speakeasy v0.1.1-0.20220910012023-760eaf8b6816 // indirect github.com/btcsuite/btcd/btcec/v2 v2.3.2 // indirect github.com/cenkalti/backoff/v4 v4.2.1 // indirect github.com/cespare/xxhash/v2 v2.3.0 // indirect github.com/chzyer/readline v1.5.1 // indirect github.com/cockroachdb/apd/v2 v2.0.2 // indirect github.com/cockroachdb/errors v1.11.1 // indirect github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b // indirect github.com/cockroachdb/pebble v1.1.0 // indirect github.com/cockroachdb/redact v1.1.5 // indirect github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06 // indirect github.com/coinbase/rosetta-sdk-go/types v1.0.0 // indirect github.com/confio/ics23/go v0.9.0 // indirect github.com/cosmos/btcutil v1.0.5 // indirect github.com/cosmos/go-bip39 v1.0.0 // indirect github.com/cosmos/gogogateway v1.2.0 // indirect github.com/cosmos/ics23/go v0.10.0 // indirect github.com/cosmos/ledger-cosmos-go v0.12.4 // indirect github.com/cosmos/rosetta-sdk-go v0.10.0 // indirect github.com/creachadair/taskgroup v0.13.0 // indirect github.com/danieljoos/wincred v1.1.2 // indirect github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc // indirect github.com/decred/dcrd/dcrec/secp256k1/v4 v4.3.0 // indirect github.com/desertbit/timer v0.0.0-20180107155436-c41aec40b27f // indirect github.com/dgraph-io/badger/v4 v4.2.0 // indirect github.com/dgraph-io/ristretto v0.1.1 // indirect github.com/docker/distribution v2.8.2+incompatible // indirect github.com/dustin/go-humanize v1.0.1 // indirect github.com/dvsekhvalnov/jose2go v1.6.0 // indirect github.com/felixge/httpsnoop v1.0.4 // indirect github.com/fsnotify/fsnotify v1.7.0 // indirect github.com/getsentry/sentry-go v0.23.0 // indirect github.com/go-kit/kit v0.13.0 // indirect github.com/go-kit/log v0.2.1 // indirect github.com/go-logfmt/logfmt v0.6.0 // indirect github.com/go-logr/logr v1.4.1 // indirect github.com/go-logr/stdr v1.2.2 // indirect github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2 // indirect github.com/gogo/googleapis v1.4.1 // indirect github.com/gogo/protobuf v1.3.2 // indirect github.com/golang/glog v1.2.2 // indirect github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect github.com/golang/mock v1.6.0 // indirect github.com/golang/snappy v0.0.4 // indirect github.com/google/btree v1.1.3 // indirect github.com/google/flatbuffers v1.12.1 // indirect github.com/google/go-cmp v0.6.0 // indirect github.com/google/gofuzz v1.2.0 // indirect github.com/google/orderedcode v0.0.1 // indirect github.com/google/s2a-go v0.1.7 // indirect github.com/google/uuid v1.6.0 // indirect github.com/googleapis/enterprise-certificate-proxy v0.3.2 // indirect github.com/googleapis/gax-go/v2 v2.12.3 // indirect github.com/gorilla/handlers v1.5.1 // indirect github.com/gorilla/websocket v1.5.3 // indirect github.com/grpc-ecosystem/go-grpc-middleware v1.3.0 // indirect github.com/gsterjov/go-libsecret v0.0.0-20161001094733-a6f4afe4910c // indirect github.com/gtank/merlin v0.1.1 // indirect github.com/gtank/ristretto255 v0.1.2 // indirect github.com/hashicorp/go-cleanhttp v0.5.2 // indirect github.com/hashicorp/go-getter v1.7.5 // indirect github.com/hashicorp/go-immutable-radix v1.3.1 // indirect github.com/hashicorp/go-safetemp v1.0.0 // indirect github.com/hashicorp/go-version v1.6.0 // indirect github.com/hashicorp/golang-lru v0.5.5-0.20210104140557-80c98217689d // indirect github.com/hashicorp/golang-lru/v2 v2.0.7 // indirect github.com/hashicorp/hcl v1.0.0 // indirect github.com/hdevalence/ed25519consensus v0.1.0 // indirect github.com/huandu/skiplist v1.2.0 // indirect github.com/iancoleman/orderedmap v0.3.0 // indirect github.com/improbable-eng/grpc-web v0.15.0 // indirect github.com/inconshreveable/mousetrap v1.1.0 // indirect github.com/jmespath/go-jmespath v0.4.0 // indirect github.com/jmhodges/levigo v1.0.0 // indirect github.com/klauspost/compress v1.17.9 // indirect github.com/kr/pretty v0.3.1 // indirect github.com/kr/text v0.2.0 // indirect github.com/lib/pq v1.10.9 // indirect github.com/linxGnu/grocksdb v1.9.3 // indirect github.com/magiconair/properties v1.8.7 // indirect github.com/manifoldco/promptui v0.9.0 // indirect github.com/mattn/go-colorable v0.1.13 // indirect github.com/mattn/go-isatty v0.0.20 // indirect github.com/mimoo/StrobeGo v0.0.0-20210601165009-122bf33a46e0 // indirect github.com/minio/blake2b-simd v0.0.0-20160723061019-3f5f724cb5b1 // indirect github.com/minio/highwayhash v1.0.3 // indirect github.com/minio/sha256-simd v0.1.1-0.20190913151208-6de447530771 // indirect github.com/mitchellh/go-homedir v1.1.0 // indirect github.com/mitchellh/go-testing-interface v1.14.1 // indirect github.com/mitchellh/mapstructure v1.5.0 // indirect github.com/mr-tron/base58 v1.1.3 // indirect github.com/mtibben/percent v0.2.1 // indirect github.com/multiformats/go-base32 v0.0.3 // indirect github.com/multiformats/go-base36 v0.1.0 // indirect github.com/multiformats/go-multibase v0.0.3 // indirect github.com/multiformats/go-multihash v0.0.13 // indirect github.com/multiformats/go-varint v0.0.5 // indirect github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect github.com/opencontainers/go-digest v1.0.0 // indirect github.com/pelletier/go-toml/v2 v2.2.2 // indirect github.com/petermattis/goid v0.0.0-20240813172612-4fcff4a6cae7 // indirect github.com/pkg/errors v0.9.1 // indirect github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect github.com/prometheus/client_model v0.6.1 // indirect github.com/prometheus/common v0.60.1 // indirect github.com/prometheus/procfs v0.15.1 // indirect github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475 // indirect github.com/rogpeppe/go-internal v1.11.0 // indirect github.com/rs/cors v1.11.1 // indirect github.com/rs/zerolog v1.33.0 // indirect github.com/sagikazarmark/locafero v0.4.0 // indirect github.com/sagikazarmark/slog-shim v0.1.0 // indirect github.com/sasha-s/go-deadlock v0.3.5 // indirect github.com/sourcegraph/conc v0.3.0 // indirect github.com/spaolacci/murmur3 v1.1.0 // indirect github.com/spf13/afero v1.11.0 // indirect github.com/subosito/gotenv v1.6.0 // indirect github.com/tendermint/go-amino v0.16.0 // indirect github.com/tidwall/btree v1.6.0 // indirect github.com/ulikunitz/xz v0.5.11 // indirect github.com/zondax/hid v0.9.2 // indirect github.com/zondax/ledger-go v0.14.3 // indirect go.etcd.io/bbolt v1.4.0-alpha.0.0.20240404170359-43604f3112c5 // indirect go.opencensus.io v0.24.0 // indirect go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.49.0 // indirect go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.49.0 // indirect go.opentelemetry.io/otel v1.24.0 // indirect go.opentelemetry.io/otel/metric v1.24.0 // indirect go.opentelemetry.io/otel/trace v1.24.0 // indirect go.uber.org/multierr v1.10.0 // indirect golang.org/x/crypto v0.31.0 // indirect golang.org/x/exp v0.0.0-20240719175910-8a7402abbf56 // indirect golang.org/x/net v0.33.0 // indirect golang.org/x/oauth2 v0.23.0 // indirect golang.org/x/sync v0.10.0 // indirect golang.org/x/sys v0.28.0 // indirect golang.org/x/term v0.27.0 // indirect golang.org/x/text v0.21.0 // indirect golang.org/x/time v0.5.0 // indirect google.golang.org/api v0.171.0 // indirect google.golang.org/genproto v0.0.0-20240213162025-012b6fc9bca9 // indirect google.golang.org/genproto/googleapis/rpc v0.0.0-20240903143218-8af14fe29dc1 // indirect google.golang.org/protobuf v1.36.1 // indirect gopkg.in/ini.v1 v1.67.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect nhooyr.io/websocket v1.8.7 // indirect pgregory.net/rapid v1.1.0 // indirect sigs.k8s.io/yaml v1.4.0 // indirect ) replace ( // use cosmos fork of keyring github.com/99designs/keyring => github.com/cosmos/keyring v1.2.0 github.com/cosmos/cosmos-sdk => github.com/cybercongress/cosmos-sdk v0.47.15-0.20250911123242-45d67c430be3 // support concurrency for iavl github.com/cosmos/iavl => github.com/cosmos/iavl v0.20.1 // dgrijalva/jwt-go is deprecated and doesn't receive security updates. // See: https://github.com/cosmos/cosmos-sdk/issues/13134 github.com/dgrijalva/jwt-go => github.com/golang-jwt/jwt/v4 v4.4.2 github.com/gin-gonic/gin => github.com/gin-gonic/gin v1.9.0 // pin the version of goleveldb to v1.0.1-0.20210819022825-2ae1ddf74ef7 required by SDK v47 upgrade guide. github.com/syndtr/goleveldb => github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 // lock exp golang.org/x/exp => golang.org/x/exp v0.0.0-20230711153332-06a737ee72cb ) ================================================ FILE: go.sum ================================================ cloud.google.com/go v0.26.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= cloud.google.com/go v0.34.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= cloud.google.com/go v0.38.0/go.mod h1:990N+gfupTy94rShfmMCWGDn0LpTmnzTp2qbd1dvSRU= cloud.google.com/go v0.44.1/go.mod h1:iSa0KzasP4Uvy3f1mN/7PiObzGgflwredwwASm/v6AU= cloud.google.com/go v0.44.2/go.mod h1:60680Gw3Yr4ikxnPRS/oxxkBccT6SA1yMk63TGekxKY= cloud.google.com/go v0.45.1/go.mod h1:RpBamKRgapWJb87xiFSdk4g1CME7QZg3uwTez+TSTjc= cloud.google.com/go v0.46.3/go.mod h1:a6bKKbmY7er1mI7TEI4lsAkts/mkhTSZK8w33B4RAg0= cloud.google.com/go v0.50.0/go.mod h1:r9sluTvynVuxRIOHXQEHMFffphuXHOMZMycpNR5e6To= cloud.google.com/go v0.52.0/go.mod h1:pXajvRH/6o3+F9jDHZWQ5PbGhn+o8w9qiu/CffaVdO4= cloud.google.com/go v0.53.0/go.mod h1:fp/UouUEsRkN6ryDKNW/Upv/JBKnv6WDthjR6+vze6M= cloud.google.com/go v0.54.0/go.mod h1:1rq2OEkV3YMf6n/9ZvGWI3GWw0VoqH/1x2nd8Is/bPc= cloud.google.com/go v0.56.0/go.mod h1:jr7tqZxxKOVYizybht9+26Z/gUq7tiRzu+ACVAMbKVk= cloud.google.com/go v0.57.0/go.mod h1:oXiQ6Rzq3RAkkY7N6t3TcE6jE+CIBBbA36lwQ1JyzZs= cloud.google.com/go v0.62.0/go.mod h1:jmCYTdRCQuc1PHIIJ/maLInMho30T/Y0M4hTdTShOYc= cloud.google.com/go v0.65.0/go.mod h1:O5N8zS7uWy9vkA9vayVHs65eM1ubvY4h553ofrNHObY= cloud.google.com/go v0.72.0/go.mod h1:M+5Vjvlc2wnp6tjzE102Dw08nGShTscUx2nZMufOKPI= cloud.google.com/go v0.74.0/go.mod h1:VV1xSbzvo+9QJOxLDaJfTjx5e+MePCpCWwvftOeQmWk= cloud.google.com/go v0.78.0/go.mod h1:QjdrLG0uq+YwhjoVOLsS1t7TW8fs36kLs4XO5R5ECHg= cloud.google.com/go v0.79.0/go.mod h1:3bzgcEeQlzbuEAYu4mrWhKqWjmpprinYgKJLgKHnbb8= cloud.google.com/go v0.81.0/go.mod h1:mk/AM35KwGk/Nm2YSeZbxXdrNK3KZOYHmLkOqC2V6E0= cloud.google.com/go v0.83.0/go.mod h1:Z7MJUsANfY0pYPdw0lbnivPx4/vhy/e2FEkSkF7vAVY= cloud.google.com/go v0.84.0/go.mod h1:RazrYuxIK6Kb7YrzzhPoLmCVzl7Sup4NrbKPg8KHSUM= cloud.google.com/go v0.87.0/go.mod h1:TpDYlFy7vuLzZMMZ+B6iRiELaY7z/gJPaqbMx6mlWcY= cloud.google.com/go v0.90.0/go.mod h1:kRX0mNRHe0e2rC6oNakvwQqzyDmg57xJ+SZU1eT2aDQ= cloud.google.com/go v0.93.3/go.mod h1:8utlLll2EF5XMAV15woO4lSbWQlk8rer9aLOfLh7+YI= cloud.google.com/go v0.94.1/go.mod h1:qAlAugsXlC+JWO+Bke5vCtc9ONxjQT3drlTTnAplMW4= cloud.google.com/go v0.97.0/go.mod h1:GF7l59pYBVlXQIBLx3a761cZ41F9bBH3JUlihCt2Udc= cloud.google.com/go v0.99.0/go.mod h1:w0Xx2nLzqWJPuozYQX+hFfCSI8WioryfRDzkoI/Y2ZA= cloud.google.com/go v0.100.2/go.mod h1:4Xra9TjzAeYHrl5+oeLlzbM2k3mjVhZh4UqTZ//w99A= cloud.google.com/go v0.102.0/go.mod h1:oWcCzKlqJ5zgHQt9YsaeTY9KzIvjyy0ArmiBUgpQ+nc= cloud.google.com/go v0.102.1/go.mod h1:XZ77E9qnTEnrgEOvr4xzfdX5TRo7fB4T2F4O6+34hIU= cloud.google.com/go v0.104.0/go.mod h1:OO6xxXdJyvuJPcEPBLN9BJPD+jep5G1+2U5B5gkRYtA= cloud.google.com/go v0.112.1 h1:uJSeirPke5UNZHIb4SxfZklVSiWWVqW4oXlETwZziwM= cloud.google.com/go v0.112.1/go.mod h1:+Vbu+Y1UU+I1rjmzeMOb/8RfkKJK2Gyxi1X6jJCZLo4= cloud.google.com/go/aiplatform v1.22.0/go.mod h1:ig5Nct50bZlzV6NvKaTwmplLLddFx0YReh9WfTO5jKw= cloud.google.com/go/aiplatform v1.24.0/go.mod h1:67UUvRBKG6GTayHKV8DBv2RtR1t93YRu5B1P3x99mYY= cloud.google.com/go/analytics v0.11.0/go.mod h1:DjEWCu41bVbYcKyvlws9Er60YE4a//bK6mnhWvQeFNI= cloud.google.com/go/analytics v0.12.0/go.mod h1:gkfj9h6XRf9+TS4bmuhPEShsh3hH8PAZzm/41OOhQd4= cloud.google.com/go/area120 v0.5.0/go.mod h1:DE/n4mp+iqVyvxHN41Vf1CR602GiHQjFPusMFW6bGR4= cloud.google.com/go/area120 v0.6.0/go.mod h1:39yFJqWVgm0UZqWTOdqkLhjoC7uFfgXRC8g/ZegeAh0= cloud.google.com/go/artifactregistry v1.6.0/go.mod h1:IYt0oBPSAGYj/kprzsBjZ/4LnG/zOcHyFHjWPCi6SAQ= cloud.google.com/go/artifactregistry v1.7.0/go.mod h1:mqTOFOnGZx8EtSqK/ZWcsm/4U8B77rbcLP6ruDU2Ixk= cloud.google.com/go/asset v1.5.0/go.mod h1:5mfs8UvcM5wHhqtSv8J1CtxxaQq3AdBxxQi2jGW/K4o= cloud.google.com/go/asset v1.7.0/go.mod h1:YbENsRK4+xTiL+Ofoj5Ckf+O17kJtgp3Y3nn4uzZz5s= cloud.google.com/go/asset v1.8.0/go.mod h1:mUNGKhiqIdbr8X7KNayoYvyc4HbbFO9URsjbytpUaW0= cloud.google.com/go/assuredworkloads v1.5.0/go.mod h1:n8HOZ6pff6re5KYfBXcFvSViQjDwxFkAkmUFffJRbbY= cloud.google.com/go/assuredworkloads v1.6.0/go.mod h1:yo2YOk37Yc89Rsd5QMVECvjaMKymF9OP+QXWlKXUkXw= cloud.google.com/go/assuredworkloads v1.7.0/go.mod h1:z/736/oNmtGAyU47reJgGN+KVoYoxeLBoj4XkKYscNI= cloud.google.com/go/automl v1.5.0/go.mod h1:34EjfoFGMZ5sgJ9EoLsRtdPSNZLcfflJR39VbVNS2M0= cloud.google.com/go/automl v1.6.0/go.mod h1:ugf8a6Fx+zP0D59WLhqgTDsQI9w07o64uf/Is3Nh5p8= cloud.google.com/go/bigquery v1.0.1/go.mod h1:i/xbL2UlR5RvWAURpBYZTtm/cXjCha9lbfbpx4poX+o= cloud.google.com/go/bigquery v1.3.0/go.mod h1:PjpwJnslEMmckchkHFfq+HTD2DmtT67aNFKH1/VBDHE= cloud.google.com/go/bigquery v1.4.0/go.mod h1:S8dzgnTigyfTmLBfrtrhyYhwRxG72rYxvftPBK2Dvzc= cloud.google.com/go/bigquery v1.5.0/go.mod h1:snEHRnqQbz117VIFhE8bmtwIDY80NLUZUMb4Nv6dBIg= cloud.google.com/go/bigquery v1.7.0/go.mod h1://okPTzCYNXSlb24MZs83e2Do+h+VXtc4gLoIoXIAPc= cloud.google.com/go/bigquery v1.8.0/go.mod h1:J5hqkt3O0uAFnINi6JXValWIb1v0goeZM77hZzJN/fQ= cloud.google.com/go/bigquery v1.42.0/go.mod h1:8dRTJxhtG+vwBKzE5OseQn/hiydoQN3EedCaOdYmxRA= cloud.google.com/go/billing v1.4.0/go.mod h1:g9IdKBEFlItS8bTtlrZdVLWSSdSyFUZKXNS02zKMOZY= cloud.google.com/go/billing v1.5.0/go.mod h1:mztb1tBc3QekhjSgmpf/CV4LzWXLzCArwpLmP2Gm88s= cloud.google.com/go/binaryauthorization v1.1.0/go.mod h1:xwnoWu3Y84jbuHa0zd526MJYmtnVXn0syOjaJgy4+dM= cloud.google.com/go/binaryauthorization v1.2.0/go.mod h1:86WKkJHtRcv5ViNABtYMhhNWRrD1Vpi//uKEy7aYEfI= cloud.google.com/go/cloudtasks v1.5.0/go.mod h1:fD92REy1x5woxkKEkLdvavGnPJGEn8Uic9nWuLzqCpY= cloud.google.com/go/cloudtasks v1.6.0/go.mod h1:C6Io+sxuke9/KNRkbQpihnW93SWDU3uXt92nu85HkYI= cloud.google.com/go/compute v0.1.0/go.mod h1:GAesmwr110a34z04OlxYkATPBEfVhkymfTBXtfbBFow= cloud.google.com/go/compute v1.3.0/go.mod h1:cCZiE1NHEtai4wiufUhW8I8S1JKkAnhnQJWM7YD99wM= cloud.google.com/go/compute v1.5.0/go.mod h1:9SMHyhJlzhlkJqrPAc839t2BZFTSk6Jdj6mkzQJeu0M= cloud.google.com/go/compute v1.6.0/go.mod h1:T29tfhtVbq1wvAPo0E3+7vhgmkOYeXjhFvz/FMzPu0s= cloud.google.com/go/compute v1.6.1/go.mod h1:g85FgpzFvNULZ+S8AYq87axRKuf2Kh7deLqV/jJ3thU= cloud.google.com/go/compute v1.7.0/go.mod h1:435lt8av5oL9P3fv1OEzSbSUe+ybHXGMPQHHZWZxy9U= cloud.google.com/go/compute v1.10.0/go.mod h1:ER5CLbMxl90o2jtNbGSbtfOpQKR0t15FOtRsugnLrlU= cloud.google.com/go/compute/metadata v0.5.0 h1:Zr0eK8JbFv6+Wi4ilXAR8FJ3wyNdpxHKJNPos6LTZOY= cloud.google.com/go/compute/metadata v0.5.0/go.mod h1:aHnloV2TPI38yx4s9+wAZhHykWvVCfu7hQbF+9CWoiY= cloud.google.com/go/containeranalysis v0.5.1/go.mod h1:1D92jd8gRR/c0fGMlymRgxWD3Qw9C1ff6/T7mLgVL8I= cloud.google.com/go/containeranalysis v0.6.0/go.mod h1:HEJoiEIu+lEXM+k7+qLCci0h33lX3ZqoYFdmPcoO7s4= cloud.google.com/go/datacatalog v1.3.0/go.mod h1:g9svFY6tuR+j+hrTw3J2dNcmI0dzmSiyOzm8kpLq0a0= cloud.google.com/go/datacatalog v1.5.0/go.mod h1:M7GPLNQeLfWqeIm3iuiruhPzkt65+Bx8dAKvScX8jvs= cloud.google.com/go/datacatalog v1.6.0/go.mod h1:+aEyF8JKg+uXcIdAmmaMUmZ3q1b/lKLtXCmXdnc0lbc= cloud.google.com/go/dataflow v0.6.0/go.mod h1:9QwV89cGoxjjSR9/r7eFDqqjtvbKxAK2BaYU6PVk9UM= cloud.google.com/go/dataflow v0.7.0/go.mod h1:PX526vb4ijFMesO1o202EaUmouZKBpjHsTlCtB4parQ= cloud.google.com/go/dataform v0.3.0/go.mod h1:cj8uNliRlHpa6L3yVhDOBrUXH+BPAO1+KFMQQNSThKo= cloud.google.com/go/dataform v0.4.0/go.mod h1:fwV6Y4Ty2yIFL89huYlEkwUPtS7YZinZbzzj5S9FzCE= cloud.google.com/go/datalabeling v0.5.0/go.mod h1:TGcJ0G2NzcsXSE/97yWjIZO0bXj0KbVlINXMG9ud42I= cloud.google.com/go/datalabeling v0.6.0/go.mod h1:WqdISuk/+WIGeMkpw/1q7bK/tFEZxsrFJOJdY2bXvTQ= cloud.google.com/go/dataqna v0.5.0/go.mod h1:90Hyk596ft3zUQ8NkFfvICSIfHFh1Bc7C4cK3vbhkeo= cloud.google.com/go/dataqna v0.6.0/go.mod h1:1lqNpM7rqNLVgWBJyk5NF6Uen2PHym0jtVJonplVsDA= cloud.google.com/go/datastore v1.0.0/go.mod h1:LXYbyblFSglQ5pkeyhO+Qmw7ukd3C+pD7TKLgZqpHYE= cloud.google.com/go/datastore v1.1.0/go.mod h1:umbIZjpQpHh4hmRpGhH4tLFup+FVzqBi1b3c64qFpCk= cloud.google.com/go/datastream v1.2.0/go.mod h1:i/uTP8/fZwgATHS/XFu0TcNUhuA0twZxxQ3EyCUQMwo= cloud.google.com/go/datastream v1.3.0/go.mod h1:cqlOX8xlyYF/uxhiKn6Hbv6WjwPPuI9W2M9SAXwaLLQ= cloud.google.com/go/dialogflow v1.15.0/go.mod h1:HbHDWs33WOGJgn6rfzBW1Kv807BE3O1+xGbn59zZWI4= cloud.google.com/go/dialogflow v1.16.1/go.mod h1:po6LlzGfK+smoSmTBnbkIZY2w8ffjz/RcGSS+sh1el0= cloud.google.com/go/dialogflow v1.17.0/go.mod h1:YNP09C/kXA1aZdBgC/VtXX74G/TKn7XVCcVumTflA+8= cloud.google.com/go/documentai v1.7.0/go.mod h1:lJvftZB5NRiFSX4moiye1SMxHx0Bc3x1+p9e/RfXYiU= cloud.google.com/go/documentai v1.8.0/go.mod h1:xGHNEB7CtsnySCNrCFdCyyMz44RhFEEX2Q7UD0c5IhU= cloud.google.com/go/domains v0.6.0/go.mod h1:T9Rz3GasrpYk6mEGHh4rymIhjlnIuB4ofT1wTxDeT4Y= cloud.google.com/go/domains v0.7.0/go.mod h1:PtZeqS1xjnXuRPKE/88Iru/LdfoRyEHYA9nFQf4UKpg= cloud.google.com/go/edgecontainer v0.1.0/go.mod h1:WgkZ9tp10bFxqO8BLPqv2LlfmQF1X8lZqwW4r1BTajk= cloud.google.com/go/edgecontainer v0.2.0/go.mod h1:RTmLijy+lGpQ7BXuTDa4C4ssxyXT34NIuHIgKuP4s5w= cloud.google.com/go/functions v1.6.0/go.mod h1:3H1UA3qiIPRWD7PeZKLvHZ9SaQhR26XIJcC0A5GbvAk= cloud.google.com/go/functions v1.7.0/go.mod h1:+d+QBcWM+RsrgZfV9xo6KfA1GlzJfxcfZcRPEhDDfzg= cloud.google.com/go/gaming v1.5.0/go.mod h1:ol7rGcxP/qHTRQE/RO4bxkXq+Fix0j6D4LFPzYTIrDM= cloud.google.com/go/gaming v1.6.0/go.mod h1:YMU1GEvA39Qt3zWGyAVA9bpYz/yAhTvaQ1t2sK4KPUA= cloud.google.com/go/gkeconnect v0.5.0/go.mod h1:c5lsNAg5EwAy7fkqX/+goqFsU1Da/jQFqArp+wGNr/o= cloud.google.com/go/gkeconnect v0.6.0/go.mod h1:Mln67KyU/sHJEBY8kFZ0xTeyPtzbq9StAVvEULYK16A= cloud.google.com/go/gkehub v0.9.0/go.mod h1:WYHN6WG8w9bXU0hqNxt8rm5uxnk8IH+lPY9J2TV7BK0= cloud.google.com/go/gkehub v0.10.0/go.mod h1:UIPwxI0DsrpsVoWpLB0stwKCP+WFVG9+y977wO+hBH0= cloud.google.com/go/grafeas v0.2.0/go.mod h1:KhxgtF2hb0P191HlY5besjYm6MqTSTj3LSI+M+ByZHc= cloud.google.com/go/iam v0.3.0/go.mod h1:XzJPvDayI+9zsASAFO68Hk07u3z+f+JrT2xXNdp4bnY= cloud.google.com/go/iam v0.5.0/go.mod h1:wPU9Vt0P4UmCux7mqtRu6jcpPAb74cP1fh50J3QpkUc= cloud.google.com/go/iam v1.1.6 h1:bEa06k05IO4f4uJonbB5iAgKTPpABy1ayxaIZV/GHVc= cloud.google.com/go/iam v1.1.6/go.mod h1:O0zxdPeGBoFdWW3HWmBxJsk0pfvNM/p/qa82rWOGTwI= cloud.google.com/go/language v1.4.0/go.mod h1:F9dRpNFQmJbkaop6g0JhSBXCNlO90e1KWx5iDdxbWic= cloud.google.com/go/language v1.6.0/go.mod h1:6dJ8t3B+lUYfStgls25GusK04NLh3eDLQnWM3mdEbhI= cloud.google.com/go/lifesciences v0.5.0/go.mod h1:3oIKy8ycWGPUyZDR/8RNnTOYevhaMLqh5vLUXs9zvT8= cloud.google.com/go/lifesciences v0.6.0/go.mod h1:ddj6tSX/7BOnhxCSd3ZcETvtNr8NZ6t/iPhY2Tyfu08= cloud.google.com/go/mediatranslation v0.5.0/go.mod h1:jGPUhGTybqsPQn91pNXw0xVHfuJ3leR1wj37oU3y1f4= cloud.google.com/go/mediatranslation v0.6.0/go.mod h1:hHdBCTYNigsBxshbznuIMFNe5QXEowAuNmmC7h8pu5w= cloud.google.com/go/memcache v1.4.0/go.mod h1:rTOfiGZtJX1AaFUrOgsMHX5kAzaTQ8azHiuDoTPzNsE= cloud.google.com/go/memcache v1.5.0/go.mod h1:dk3fCK7dVo0cUU2c36jKb4VqKPS22BTkf81Xq617aWM= cloud.google.com/go/metastore v1.5.0/go.mod h1:2ZNrDcQwghfdtCwJ33nM0+GrBGlVuh8rakL3vdPY3XY= cloud.google.com/go/metastore v1.6.0/go.mod h1:6cyQTls8CWXzk45G55x57DVQ9gWg7RiH65+YgPsNh9s= cloud.google.com/go/networkconnectivity v1.4.0/go.mod h1:nOl7YL8odKyAOtzNX73/M5/mGZgqqMeryi6UPZTk/rA= cloud.google.com/go/networkconnectivity v1.5.0/go.mod h1:3GzqJx7uhtlM3kln0+x5wyFvuVH1pIBJjhCpjzSt75o= cloud.google.com/go/networksecurity v0.5.0/go.mod h1:xS6fOCoqpVC5zx15Z/MqkfDwH4+m/61A3ODiDV1xmiQ= cloud.google.com/go/networksecurity v0.6.0/go.mod h1:Q5fjhTr9WMI5mbpRYEbiexTzROf7ZbDzvzCrNl14nyU= cloud.google.com/go/notebooks v1.2.0/go.mod h1:9+wtppMfVPUeJ8fIWPOq1UnATHISkGXGqTkxeieQ6UY= cloud.google.com/go/notebooks v1.3.0/go.mod h1:bFR5lj07DtCPC7YAAJ//vHskFBxA5JzYlH68kXVdk34= cloud.google.com/go/osconfig v1.7.0/go.mod h1:oVHeCeZELfJP7XLxcBGTMBvRO+1nQ5tFG9VQTmYS2Fs= cloud.google.com/go/osconfig v1.8.0/go.mod h1:EQqZLu5w5XA7eKizepumcvWx+m8mJUhEwiPqWiZeEdg= cloud.google.com/go/oslogin v1.4.0/go.mod h1:YdgMXWRaElXz/lDk1Na6Fh5orF7gvmJ0FGLIs9LId4E= cloud.google.com/go/oslogin v1.5.0/go.mod h1:D260Qj11W2qx/HVF29zBg+0fd6YCSjSqLUkY/qEenQU= cloud.google.com/go/phishingprotection v0.5.0/go.mod h1:Y3HZknsK9bc9dMi+oE8Bim0lczMU6hrX0UpADuMefr0= cloud.google.com/go/phishingprotection v0.6.0/go.mod h1:9Y3LBLgy0kDTcYET8ZH3bq/7qni15yVUoAxiFxnlSUA= cloud.google.com/go/privatecatalog v0.5.0/go.mod h1:XgosMUvvPyxDjAVNDYxJ7wBW8//hLDDYmnsNcMGq1K0= cloud.google.com/go/privatecatalog v0.6.0/go.mod h1:i/fbkZR0hLN29eEWiiwue8Pb+GforiEIBnV9yrRUOKI= cloud.google.com/go/pubsub v1.0.1/go.mod h1:R0Gpsv3s54REJCy4fxDixWD93lHJMoZTyQ2kNxGRt3I= cloud.google.com/go/pubsub v1.1.0/go.mod h1:EwwdRX2sKPjnvnqCa270oGRyludottCI76h+R3AArQw= cloud.google.com/go/pubsub v1.2.0/go.mod h1:jhfEVHT8odbXTkndysNHCcx0awwzvfOlguIAii9o8iA= cloud.google.com/go/pubsub v1.3.1/go.mod h1:i+ucay31+CNRpDW4Lu78I4xXG+O1r/MAHgjpRVR+TSU= cloud.google.com/go/recaptchaenterprise v1.3.1/go.mod h1:OdD+q+y4XGeAlxRaMn1Y7/GveP6zmq76byL6tjPE7d4= cloud.google.com/go/recaptchaenterprise/v2 v2.1.0/go.mod h1:w9yVqajwroDNTfGuhmOjPDN//rZGySaf6PtFVcSCa7o= cloud.google.com/go/recaptchaenterprise/v2 v2.2.0/go.mod h1:/Zu5jisWGeERrd5HnlS3EUGb/D335f9k51B/FVil0jk= cloud.google.com/go/recaptchaenterprise/v2 v2.3.0/go.mod h1:O9LwGCjrhGHBQET5CA7dd5NwwNQUErSgEDit1DLNTdo= cloud.google.com/go/recommendationengine v0.5.0/go.mod h1:E5756pJcVFeVgaQv3WNpImkFP8a+RptV6dDLGPILjvg= cloud.google.com/go/recommendationengine v0.6.0/go.mod h1:08mq2umu9oIqc7tDy8sx+MNJdLG0fUi3vaSVbztHgJ4= cloud.google.com/go/recommender v1.5.0/go.mod h1:jdoeiBIVrJe9gQjwd759ecLJbxCDED4A6p+mqoqDvTg= cloud.google.com/go/recommender v1.6.0/go.mod h1:+yETpm25mcoiECKh9DEScGzIRyDKpZ0cEhWGo+8bo+c= cloud.google.com/go/redis v1.7.0/go.mod h1:V3x5Jq1jzUcg+UNsRvdmsfuFnit1cfe3Z/PGyq/lm4Y= cloud.google.com/go/redis v1.8.0/go.mod h1:Fm2szCDavWzBk2cDKxrkmWBqoCiL1+Ctwq7EyqBCA/A= cloud.google.com/go/retail v1.8.0/go.mod h1:QblKS8waDmNUhghY2TI9O3JLlFk8jybHeV4BF19FrE4= cloud.google.com/go/retail v1.9.0/go.mod h1:g6jb6mKuCS1QKnH/dpu7isX253absFl6iE92nHwlBUY= cloud.google.com/go/scheduler v1.4.0/go.mod h1:drcJBmxF3aqZJRhmkHQ9b3uSSpQoltBPGPxGAWROx6s= cloud.google.com/go/scheduler v1.5.0/go.mod h1:ri073ym49NW3AfT6DZi21vLZrG07GXr5p3H1KxN5QlI= cloud.google.com/go/secretmanager v1.6.0/go.mod h1:awVa/OXF6IiyaU1wQ34inzQNc4ISIDIrId8qE5QGgKA= cloud.google.com/go/security v1.5.0/go.mod h1:lgxGdyOKKjHL4YG3/YwIL2zLqMFCKs0UbQwgyZmfJl4= cloud.google.com/go/security v1.7.0/go.mod h1:mZklORHl6Bg7CNnnjLH//0UlAlaXqiG7Lb9PsPXLfD0= cloud.google.com/go/security v1.8.0/go.mod h1:hAQOwgmaHhztFhiQ41CjDODdWP0+AE1B3sX4OFlq+GU= cloud.google.com/go/securitycenter v1.13.0/go.mod h1:cv5qNAqjY84FCN6Y9z28WlkKXyWsgLO832YiWwkCWcU= cloud.google.com/go/securitycenter v1.14.0/go.mod h1:gZLAhtyKv85n52XYWt6RmeBdydyxfPeTrpToDPw4Auc= cloud.google.com/go/servicedirectory v1.4.0/go.mod h1:gH1MUaZCgtP7qQiI+F+A+OpeKF/HQWgtAddhTbhL2bs= cloud.google.com/go/servicedirectory v1.5.0/go.mod h1:QMKFL0NUySbpZJ1UZs3oFAmdvVxhhxB6eJ/Vlp73dfg= cloud.google.com/go/speech v1.6.0/go.mod h1:79tcr4FHCimOp56lwC01xnt/WPJZc4v3gzyT7FoBkCM= cloud.google.com/go/speech v1.7.0/go.mod h1:KptqL+BAQIhMsj1kOP2la5DSEEerPDuOP/2mmkhHhZQ= cloud.google.com/go/storage v1.0.0/go.mod h1:IhtSnM/ZTZV8YYJWCY8RULGVqBDmpoyjwiyrjsg+URw= cloud.google.com/go/storage v1.5.0/go.mod h1:tpKbwo567HUNpVclU5sGELwQWBDZ8gh0ZeosJ0Rtdos= cloud.google.com/go/storage v1.6.0/go.mod h1:N7U0C8pVQ/+NIKOBQyamJIeKQKkZ+mxpohlUTyfDhBk= cloud.google.com/go/storage v1.8.0/go.mod h1:Wv1Oy7z6Yz3DshWRJFhqM/UCfaWIRTdp0RXyy7KQOVs= cloud.google.com/go/storage v1.10.0/go.mod h1:FLPqc6j+Ki4BU591ie1oL6qBQGu2Bl/tZ9ullr3+Kg0= cloud.google.com/go/storage v1.22.1/go.mod h1:S8N1cAStu7BOeFfE8KAQzmyyLkK8p/vmRq6kuBTW58Y= cloud.google.com/go/storage v1.23.0/go.mod h1:vOEEDNFnciUMhBeT6hsJIn3ieU5cFRmzeLgDvXzfIXc= cloud.google.com/go/storage v1.27.0/go.mod h1:x9DOL8TK/ygDUMieqwfhdpQryTeEkhGKMi80i/iqR2s= cloud.google.com/go/storage v1.38.0 h1:Az68ZRGlnNTpIBbLjSMIV2BDcwwXYlRlQzis0llkpJg= cloud.google.com/go/storage v1.38.0/go.mod h1:tlUADB0mAb9BgYls9lq+8MGkfzOXuLrnHXlpHmvFJoY= cloud.google.com/go/talent v1.1.0/go.mod h1:Vl4pt9jiHKvOgF9KoZo6Kob9oV4lwd/ZD5Cto54zDRw= cloud.google.com/go/talent v1.2.0/go.mod h1:MoNF9bhFQbiJ6eFD3uSsg0uBALw4n4gaCaEjBw9zo8g= cloud.google.com/go/videointelligence v1.6.0/go.mod h1:w0DIDlVRKtwPCn/C4iwZIJdvC69yInhW0cfi+p546uU= cloud.google.com/go/videointelligence v1.7.0/go.mod h1:k8pI/1wAhjznARtVT9U1llUaFNPh7muw8QyOUpavru4= cloud.google.com/go/vision v1.2.0/go.mod h1:SmNwgObm5DpFBme2xpyOyasvBc1aPdjvMk2bBk0tKD0= cloud.google.com/go/vision/v2 v2.2.0/go.mod h1:uCdV4PpN1S0jyCyq8sIM42v2Y6zOLkZs+4R9LrGYwFo= cloud.google.com/go/vision/v2 v2.3.0/go.mod h1:UO61abBx9QRMFkNBbf1D8B1LXdS2cGiiCRx0vSpZoUo= cloud.google.com/go/webrisk v1.4.0/go.mod h1:Hn8X6Zr+ziE2aNd8SliSDWpEnSS1u4R9+xXZmFiHmGE= cloud.google.com/go/webrisk v1.5.0/go.mod h1:iPG6fr52Tv7sGk0H6qUFzmL3HHZev1htXuWDEEsqMTg= cloud.google.com/go/workflows v1.6.0/go.mod h1:6t9F5h/unJz41YqfBmqSASJSXccBLtD1Vwf+KmJENM0= cloud.google.com/go/workflows v1.7.0/go.mod h1:JhSrZuVZWuiDfKEFxU0/F1PQjmpnpcoISEXH2bcHC3M= cosmossdk.io/api v0.3.1 h1:NNiOclKRR0AOlO4KIqeaG6PS6kswOMhHD0ir0SscNXE= cosmossdk.io/api v0.3.1/go.mod h1:DfHfMkiNA2Uhy8fj0JJlOCYOBp4eWUUJ1te5zBGNyIw= cosmossdk.io/core v0.6.1 h1:OBy7TI2W+/gyn2z40vVvruK3di+cAluinA6cybFbE7s= cosmossdk.io/core v0.6.1/go.mod h1:g3MMBCBXtxbDWBURDVnJE7XML4BG5qENhs0gzkcpuFA= cosmossdk.io/depinject v1.0.0-alpha.4 h1:PLNp8ZYAMPTUKyG9IK2hsbciDWqna2z1Wsl98okJopc= cosmossdk.io/depinject v1.0.0-alpha.4/go.mod h1:HeDk7IkR5ckZ3lMGs/o91AVUc7E596vMaOmslGFM3yU= cosmossdk.io/errors v1.0.1 h1:bzu+Kcr0kS/1DuPBtUFdWjzLqyUuCiyHjyJB6srBV/0= cosmossdk.io/errors v1.0.1/go.mod h1:MeelVSZThMi4bEakzhhhE/CKqVv3nOJDA25bIqRDu/U= cosmossdk.io/log v1.4.1 h1:wKdjfDRbDyZRuWa8M+9nuvpVYxrEOwbD/CA8hvhU8QM= cosmossdk.io/log v1.4.1/go.mod h1:k08v0Pyq+gCP6phvdI6RCGhLf/r425UT6Rk/m+o74rU= cosmossdk.io/math v1.4.0 h1:XbgExXFnXmF/CccPPEto40gOO7FpWu9yWNAZPN3nkNQ= cosmossdk.io/math v1.4.0/go.mod h1:O5PkD4apz2jZs4zqFdTr16e1dcaQCc5z6lkEnrrppuk= cosmossdk.io/simapp v0.0.0-20230323161446-0af178d721ff h1:P1ialzTepD1oxdNPYc5N8Eggq3RdejZq3cJs8YYMs9Y= cosmossdk.io/simapp v0.0.0-20230323161446-0af178d721ff/go.mod h1:AKzx6Mb544LjJ9RHmGFHjY9rEOLiUAi8I0F727TR0dY= cosmossdk.io/tools/rosetta v0.2.1 h1:ddOMatOH+pbxWbrGJKRAawdBkPYLfKXutK9IETnjYxw= cosmossdk.io/tools/rosetta v0.2.1/go.mod h1:Pqdc1FdvkNV3LcNIkYWt2RQY6IP1ge6YWZk8MhhO9Hw= filippo.io/edwards25519 v1.0.0 h1:0wAIcmJUqRdI8IJ/3eGi5/HwXZWPujYXXlkrQogz0Ek= filippo.io/edwards25519 v1.0.0/go.mod h1:N1IkdkCkiLB6tki+MYJoSx2JTY9NUlxZE7eHn5EwJns= github.com/99designs/go-keychain v0.0.0-20191008050251-8e49817e8af4 h1:/vQbFIOMbk2FiG/kXiLl8BRyzTWDw7gX/Hz7Dd5eDMs= github.com/99designs/go-keychain v0.0.0-20191008050251-8e49817e8af4/go.mod h1:hN7oaIRCjzsZ2dE+yG5k+rsdt3qcwykqK6HVGcKwsw4= github.com/Azure/go-ansiterm v0.0.0-20210617225240-d185dfc1b5a1 h1:UQHMgLO+TxOElx5B5HZ4hJQsoJ/PvUvKRhJHDQXO8P8= github.com/Azure/go-ansiterm v0.0.0-20210617225240-d185dfc1b5a1/go.mod h1:xomTg63KZ2rFqZQzSB4Vz2SUXa1BpHTVz9L5PTmPC4E= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= github.com/ChainSafe/go-schnorrkel v1.1.0 h1:rZ6EU+CZFCjB4sHUE1jIu8VDoB/wRKZxoe1tkcO71Wk= github.com/ChainSafe/go-schnorrkel v1.1.0/go.mod h1:ABkENxiP+cvjFiByMIZ9LYbRoNNLeBLiakC1XeTFxfE= github.com/CosmWasm/wasmd v0.46.0 h1:78kmiobbVE8JWBcM+ssxiFV2cS+4l9lmZQqPAQ0mA04= github.com/CosmWasm/wasmd v0.46.0/go.mod h1:BZFz+CFGdLNGomshb3IeccFyD4R+XbnS/mXpytOUyTA= github.com/CosmWasm/wasmvm v1.5.9 h1:EMSIsG4eAhgIZ6SQQs+ZWFT0ONnUjbH9FSdeBUnItoQ= github.com/CosmWasm/wasmvm v1.5.9/go.mod h1:2qaMB5ISmYXtpkJR2jy8xxx5Ti8sntOEf1cUgolb4QI= github.com/DataDog/datadog-go v3.2.0+incompatible/go.mod h1:LButxg5PwREeZtORoXG3tL4fMGNddJ+vMq1mwgfaqoQ= github.com/DataDog/zstd v1.5.2 h1:vUG4lAyuPCXO0TLbXvPv7EB7cNK1QV/luu55UHLrrn8= github.com/DataDog/zstd v1.5.2/go.mod h1:g4AWEaM3yOg3HYfnJ3YIawPnVdXJh9QME85blwSAmyw= github.com/Knetic/govaluate v3.0.1-0.20171022003610-9aa49832a739+incompatible/go.mod h1:r7JcOSlj0wfOMncg0iLm8Leh48TZaKVeNIfJntJ2wa0= github.com/Microsoft/go-winio v0.6.1 h1:9/kr64B9VUZrLm5YYwbGtUJnMgqWVOdUAXu6Migciow= github.com/Microsoft/go-winio v0.6.1/go.mod h1:LRdKpFKfdobln8UmuiYcKPot9D2v6svN5+sAH+4kjUM= github.com/Nvveen/Gotty v0.0.0-20120604004816-cd527374f1e5 h1:TngWCqHvy9oXAN6lEVMRuU21PR1EtLVZJmdB18Gu3Rw= github.com/Nvveen/Gotty v0.0.0-20120604004816-cd527374f1e5/go.mod h1:lmUJ/7eu/Q8D7ML55dXQrVaamCz2vxCfdQBasLZfHKk= github.com/OneOfOne/xxhash v1.2.2/go.mod h1:HSdplMjZKSmBqAxg5vPj2TmRDmfkzw+cTzAElWljhcU= github.com/Shopify/sarama v1.19.0/go.mod h1:FVkBWblsNy7DGZRfXLU0O9RCGt5g3g3yEuWXgklEdEo= github.com/Shopify/toxiproxy v2.1.4+incompatible/go.mod h1:OXgGpZ6Cli1/URJOF1DMxUHB2q5Ap20/P/eIdh4G0pI= github.com/VividCortex/gohistogram v1.0.0 h1:6+hBz+qvs0JOrrNhhmR7lFxo5sINxBCGXrdtl/UvroE= github.com/VividCortex/gohistogram v1.0.0/go.mod h1:Pf5mBqqDxYaXu3hDrrU+w6nw50o/4+TcAqDqk/vUH7g= github.com/adlio/schema v1.3.6 h1:k1/zc2jNfeiZBA5aFTRy37jlBIuCkXCm0XmvpzCKI9I= github.com/adlio/schema v1.3.6/go.mod h1:qkxwLgPBd1FgLRHYVCmQT/rrBr3JH38J9LjmVzWNudg= github.com/afex/hystrix-go v0.0.0-20180502004556-fa1af6a1f4f5/go.mod h1:SkGFH1ia65gfNATL8TAiHDNxPzPdmEL5uirI2Uyuz6c= github.com/alecthomas/template v0.0.0-20160405071501-a0175ee3bccc/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= github.com/alecthomas/template v0.0.0-20190718012654-fb15b899a751/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= github.com/alecthomas/units v0.0.0-20151022065526-2efee857e7cf/go.mod h1:ybxpYRFXyAe+OPACYpWeL0wqObRcbAqCMya13uyzqw0= github.com/alecthomas/units v0.0.0-20190717042225-c3de453c63f4/go.mod h1:ybxpYRFXyAe+OPACYpWeL0wqObRcbAqCMya13uyzqw0= github.com/alecthomas/units v0.0.0-20190924025748-f65c72e2690d/go.mod h1:rBZYJk541a8SKzHPHnH3zbiI+7dagKZ0cgpgrD7Fyho= github.com/antihax/optional v1.0.0/go.mod h1:uupD/76wgC+ih3iEmQUL+0Ugr19nfwCT1kdvxnR2qWY= github.com/apache/thrift v0.12.0/go.mod h1:cp2SuWMxlEZw2r+iP2GNCdIi4C1qmUzdZFSVb+bacwQ= github.com/apache/thrift v0.13.0/go.mod h1:cp2SuWMxlEZw2r+iP2GNCdIi4C1qmUzdZFSVb+bacwQ= github.com/armon/circbuf v0.0.0-20150827004946-bbbad097214e/go.mod h1:3U/XgcO3hCbHZ8TKRvWD2dDTCfh9M9ya+I9JpbB7O8o= github.com/armon/go-metrics v0.0.0-20180917152333-f0300d1749da/go.mod h1:Q73ZrmVTwzkszR9V5SSuryQ31EELlFMUz1kKyl939pY= github.com/armon/go-metrics v0.4.1 h1:hR91U9KYmb6bLBYLQjyM+3j+rcd/UhE+G78SFnF8gJA= github.com/armon/go-metrics v0.4.1/go.mod h1:E6amYzXo6aW1tqzoZGT755KkbgrJsSdpwZ+3JqfkOG4= github.com/armon/go-radix v0.0.0-20180808171621-7fddfc383310/go.mod h1:ufUuZ+zHj4x4TnLV4JWEpy2hxWSpsRywHrMgIH9cCH8= github.com/aryann/difflib v0.0.0-20170710044230-e206f873d14a/go.mod h1:DAHtR1m6lCRdSC2Tm3DSWRPvIPr6xNKyeHdqDQSQT+A= github.com/aws/aws-lambda-go v1.13.3/go.mod h1:4UKl9IzQMoD+QF79YdCuzCwp8VbmG4VAQwij/eHl5CU= github.com/aws/aws-sdk-go v1.27.0/go.mod h1:KmX6BPdI08NWTb3/sm4ZGu5ShLoqVDhKgpiN924inxo= github.com/aws/aws-sdk-go v1.44.122/go.mod h1:y4AeaBuwd2Lk+GepC1E9v0qOiTws0MIWAX4oIKwKHZo= github.com/aws/aws-sdk-go v1.44.203 h1:pcsP805b9acL3wUqa4JR2vg1k2wnItkDYNvfmcy6F+U= github.com/aws/aws-sdk-go v1.44.203/go.mod h1:aVsgQcEevwlmQ7qHE9I3h+dtQgpqhFB+i8Phjh7fkwI= github.com/aws/aws-sdk-go-v2 v0.18.0/go.mod h1:JWVYvqSMppoMJC0x5wdwiImzgXTI9FuZwxzkQq9wy+g= github.com/beorn7/perks v0.0.0-20180321164747-3a771d992973/go.mod h1:Dwedo/Wpr24TaqPxmxbtue+5NUziq4I4S80YR8gNf3Q= github.com/beorn7/perks v1.0.0/go.mod h1:KWe93zE9D1o94FZ5RNwFwVgaQK1VOXiVxmqh+CedLV8= github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM= github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6rlkpw= github.com/bgentry/go-netrc v0.0.0-20140422174119-9fd32a8b3d3d h1:xDfNPAt8lFiC1UJrqV3uuy861HCTo708pDMbjHHdCas= github.com/bgentry/go-netrc v0.0.0-20140422174119-9fd32a8b3d3d/go.mod h1:6QX/PXZ00z/TKoufEY6K/a0k6AhaJrQKdFe6OfVXsa4= github.com/bgentry/speakeasy v0.1.0/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kBD4zp0CCIs= github.com/bgentry/speakeasy v0.1.1-0.20220910012023-760eaf8b6816 h1:41iFGWnSlI2gVpmOtVTJZNodLdLQLn/KsJqFvXwnd/s= github.com/bgentry/speakeasy v0.1.1-0.20220910012023-760eaf8b6816/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kBD4zp0CCIs= github.com/btcsuite/btcd/btcec/v2 v2.3.2 h1:5n0X6hX0Zk+6omWcihdYvdAlGf2DfasC0GMf7DClJ3U= github.com/btcsuite/btcd/btcec/v2 v2.3.2/go.mod h1:zYzJ8etWJQIv1Ogk7OzpWjowwOdXY1W/17j2MW85J04= github.com/btcsuite/btcd/btcutil v1.1.6 h1:zFL2+c3Lb9gEgqKNzowKUPQNb8jV7v5Oaodi/AYFd6c= github.com/btcsuite/btcd/btcutil v1.1.6/go.mod h1:9dFymx8HpuLqBnsPELrImQeTQfKBQqzqGbbV3jK55aE= github.com/btcsuite/btcd/chaincfg/chainhash v1.0.1 h1:q0rUy8C/TYNBQS1+CGKw68tLOFYSNEs0TFnxxnS9+4U= github.com/btcsuite/btcd/chaincfg/chainhash v1.0.1/go.mod h1:7SFka0XMvUgj3hfZtydOrQY2mwhPclbT2snogU7SQQc= github.com/bufbuild/protocompile v0.4.0 h1:LbFKd2XowZvQ/kajzguUp2DC9UEIQhIq77fZZlaQsNA= github.com/bufbuild/protocompile v0.4.0/go.mod h1:3v93+mbWn/v3xzN+31nwkJfrEpAUwp+BagBSZWx+TP8= github.com/bytedance/sonic v1.5.0/go.mod h1:ED5hyg4y6t3/9Ku1R6dU/4KyJ48DZ4jPhfY1O2AihPM= github.com/bytedance/sonic v1.8.0 h1:ea0Xadu+sHlu7x5O3gKhRpQ1IKiMrSiHttPF0ybECuA= github.com/bytedance/sonic v1.8.0/go.mod h1:i736AoUSYt75HyZLoJW9ERYxcy6eaN6h4BZXU064P/U= github.com/casbin/casbin/v2 v2.1.2/go.mod h1:YcPU1XXisHhLzuxH9coDNf2FbKpjGlbCg3n9yuLkIJQ= github.com/cenkalti/backoff v2.2.1+incompatible h1:tNowT99t7UNflLxfYYSlKYsBpXdEet03Pg2g16Swow4= github.com/cenkalti/backoff v2.2.1+incompatible/go.mod h1:90ReRw6GdpyfrHakVjL/QHaoyV4aDUVVkXQJJJ3NXXM= github.com/cenkalti/backoff/v4 v4.1.1/go.mod h1:scbssz8iZGpm3xbr14ovlUdkxfGXNInqkPWOWmG2CLw= github.com/cenkalti/backoff/v4 v4.2.1 h1:y4OZtCnogmCPw98Zjyt5a6+QwPLGkiQsYW5oUqylYbM= github.com/cenkalti/backoff/v4 v4.2.1/go.mod h1:Y3VNntkOUPxTVeUxJ/G5vcM//AlwfmyYozVcomhLiZE= github.com/census-instrumentation/opencensus-proto v0.2.1/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU= github.com/cespare/xxhash v1.1.0/go.mod h1:XrSqR1VqqWfGrhpAt58auRo0WTKS1nRRg3ghfAqPWnc= github.com/cespare/xxhash/v2 v2.1.1/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= github.com/cespare/xxhash/v2 v2.3.0 h1:UL815xU9SqsFlibzuggzjXhog7bL6oX9BbNZnL2UFvs= github.com/cespare/xxhash/v2 v2.3.0/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= github.com/cheggaaa/pb v1.0.27/go.mod h1:pQciLPpbU0oxA0h+VJYYLxO+XeDQb5pZijXscXHm81s= github.com/chenzhuoyu/base64x v0.0.0-20211019084208-fb5309c8db06/go.mod h1:DH46F32mSOjUmXrMHnKwZdA8wcEefY7UVqBKYGjpdQY= github.com/chenzhuoyu/base64x v0.0.0-20221115062448-fe3a3abad311 h1:qSGYFH7+jGhDF8vLC+iwCD4WpbV1EBDSzWkJODFLams= github.com/chenzhuoyu/base64x v0.0.0-20221115062448-fe3a3abad311/go.mod h1:b583jCggY9gE99b6G5LEC39OIiVsWj+R97kbl5odCEk= github.com/chzyer/logex v1.1.10/go.mod h1:+Ywpsq7O8HXn0nuIou7OrIPyXbp3wmkHB+jjWRnGsAI= github.com/chzyer/logex v1.2.1 h1:XHDu3E6q+gdHgsdTPH6ImJMIp436vR6MPtH8gP05QzM= github.com/chzyer/logex v1.2.1/go.mod h1:JLbx6lG2kDbNRFnfkgvh4eRJRPX1QCoOIWomwysCBrQ= github.com/chzyer/readline v0.0.0-20180603132655-2972be24d48e/go.mod h1:nSuG5e5PlCu98SY8svDHJxuZscDgtXS6KTTbou5AhLI= github.com/chzyer/readline v1.5.1 h1:upd/6fQk4src78LMRzh5vItIt361/o4uq553V8B5sGI= github.com/chzyer/readline v1.5.1/go.mod h1:Eh+b79XXUwfKfcPLepksvw2tcLE/Ct21YObkaSkeBlk= github.com/chzyer/test v0.0.0-20180213035817-a1ea475d72b1/go.mod h1:Q3SI9o4m/ZMnBNeIyt5eFwwo7qiLfzFZmjNmxjkiQlU= github.com/chzyer/test v1.0.0 h1:p3BQDXSxOhOG0P9z6/hGnII4LGiEPOYBhs8asl/fC04= github.com/chzyer/test v1.0.0/go.mod h1:2JlltgoNkt4TW/z9V/IzDdFaMTM2JPIi26O1pF38GC8= github.com/circonus-labs/circonus-gometrics v2.3.1+incompatible/go.mod h1:nmEj6Dob7S7YxXgwXpfOuvO54S+tGdZdw9fuRZt25Ag= github.com/circonus-labs/circonusllhist v0.1.3/go.mod h1:kMXHVDlOchFAehlya5ePtbp5jckzBHf4XRpQvBOLI+I= github.com/clbanning/x2j v0.0.0-20191024224557-825249438eec/go.mod h1:jMjuTZXRI4dUb/I5gc9Hdhagfvm9+RyrPryS/auMzxE= github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw= github.com/cncf/udpa/go v0.0.0-20191209042840-269d4d468f6f/go.mod h1:M8M6+tZqaGXZJjfX53e64911xZQV5JYwmTeXPW+k8Sc= github.com/cncf/udpa/go v0.0.0-20200629203442-efcf912fb354/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk= github.com/cncf/udpa/go v0.0.0-20201120205902-5459f2c99403/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk= github.com/cncf/udpa/go v0.0.0-20210930031921-04548b0d99d4/go.mod h1:6pvJx4me5XPnfI9Z40ddWsdw2W/uZgQLFXToKeRcDiI= github.com/cncf/xds/go v0.0.0-20210312221358-fbca930ec8ed/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= github.com/cncf/xds/go v0.0.0-20210805033703-aa0b78936158/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= github.com/cncf/xds/go v0.0.0-20210922020428-25de7278fc84/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= github.com/cncf/xds/go v0.0.0-20211001041855-01bcc9b48dfe/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= github.com/cncf/xds/go v0.0.0-20211011173535-cb28da3451f1/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= github.com/cockroachdb/apd/v2 v2.0.2 h1:weh8u7Cneje73dDh+2tEVLUvyBc89iwepWCD8b8034E= github.com/cockroachdb/apd/v2 v2.0.2/go.mod h1:DDxRlzC2lo3/vSlmSoS7JkqbbrARPuFOGr0B9pvN3Gw= github.com/cockroachdb/datadriven v0.0.0-20190809214429-80d97fb3cbaa/go.mod h1:zn76sxSg3SzpJ0PPJaLDCu+Bu0Lg3sKTORVIj19EIF8= github.com/cockroachdb/datadriven v1.0.3-0.20230413201302-be42291fc80f h1:otljaYPt5hWxV3MUfO5dFPFiOXg9CyG5/kCfayTqsJ4= github.com/cockroachdb/datadriven v1.0.3-0.20230413201302-be42291fc80f/go.mod h1:a9RdTaap04u637JoCzcUoIcDmvwSUtcUFtT/C3kJlTU= github.com/cockroachdb/errors v1.11.1 h1:xSEW75zKaKCWzR3OfxXUxgrk/NtT4G1MiOv5lWZazG8= github.com/cockroachdb/errors v1.11.1/go.mod h1:8MUxA3Gi6b25tYlFEBGLf+D8aISL+M4MIpiWMSNRfxw= github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b h1:r6VH0faHjZeQy818SGhaone5OnYfxFR/+AzdY3sf5aE= github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b/go.mod h1:Vz9DsVWQQhf3vs21MhPMZpMGSht7O/2vFW2xusFUVOs= github.com/cockroachdb/pebble v1.1.0 h1:pcFh8CdCIt2kmEpK0OIatq67Ln9uGDYY3d5XnE0LJG4= github.com/cockroachdb/pebble v1.1.0/go.mod h1:sEHm5NOXxyiAoKWhoFxT8xMgd/f3RA6qUqQ1BXKrh2E= github.com/cockroachdb/redact v1.1.5 h1:u1PMllDkdFfPWaNGMyLD1+so+aq3uUItthCFqzwPJ30= github.com/cockroachdb/redact v1.1.5/go.mod h1:BVNblN9mBWFyMyqK1k3AAiSxhvhfK2oOZZ2lK+dpvRg= github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06 h1:zuQyyAKVxetITBuuhv3BI9cMrmStnpT18zmgmTxunpo= github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06/go.mod h1:7nc4anLGjupUW/PeY5qiNYsdNXj7zopG+eqsS7To5IQ= github.com/codahale/hdrhistogram v0.0.0-20161010025455-3a0bb77429bd/go.mod h1:sE/e/2PUdi/liOCUjSTXgM1o87ZssimdTWN964YiIeI= github.com/coinbase/rosetta-sdk-go/types v1.0.0 h1:jpVIwLcPoOeCR6o1tU+Xv7r5bMONNbHU7MuEHboiFuA= github.com/coinbase/rosetta-sdk-go/types v1.0.0/go.mod h1:eq7W2TMRH22GTW0N0beDnN931DW0/WOI1R2sdHNHG4c= github.com/cometbft/cometbft v0.37.18 h1:JIjGMHxPqnuoGcCn3gRnmFSCBP6bCIeJWWWILwiDwUk= github.com/cometbft/cometbft v0.37.18/go.mod h1:t/BvwfSJKt2HUHX01L6y1+uw+LOoxU6hFj447wOB5IA= github.com/cometbft/cometbft-db v0.12.0 h1:v77/z0VyfSU7k682IzZeZPFZrQAKiQwkqGN0QzAjMi0= github.com/cometbft/cometbft-db v0.12.0/go.mod h1:aX2NbCrjNVd2ZajYxt1BsiFf/Z+TQ2MN0VxdicheYuw= github.com/confio/ics23/go v0.9.0 h1:cWs+wdbS2KRPZezoaaj+qBleXgUk5WOQFMP3CQFGTr4= github.com/confio/ics23/go v0.9.0/go.mod h1:4LPZ2NYqnYIVRklaozjNR1FScgDJ2s5Xrp+e/mYVRak= github.com/containerd/continuity v0.3.0 h1:nisirsYROK15TAMVukJOUyGJjz4BNQJBVsNvAXZJ/eg= github.com/containerd/continuity v0.3.0/go.mod h1:wJEAIwKOm/pBZuBd0JmeTvnLquTB1Ag8espWhkykbPM= github.com/coreos/go-semver v0.2.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk= github.com/coreos/go-systemd v0.0.0-20180511133405-39ca1b05acc7/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4= github.com/coreos/go-systemd/v22 v22.5.0/go.mod h1:Y58oyj3AT4RCenI/lSvhwexgC+NSVTIJ3seZv2GcEnc= github.com/coreos/pkg v0.0.0-20160727233714-3ac0863d7acf/go.mod h1:E3G3o1h8I7cfcXa63jLwjI0eiQQMgzzUDFVpN/nH/eA= github.com/cosmos/btcutil v1.0.5 h1:t+ZFcX77LpKtDBhjucvnOH8C2l2ioGsBNEQ3jef8xFk= github.com/cosmos/btcutil v1.0.5/go.mod h1:IyB7iuqZMJlthe2tkIFL33xPyzbFYP0XVdS8P5lUPis= github.com/cosmos/cosmos-proto v1.0.0-beta.5 h1:eNcayDLpip+zVLRLYafhzLvQlSmyab+RC5W7ZfmxJLA= github.com/cosmos/cosmos-proto v1.0.0-beta.5/go.mod h1:hQGLpiIUloJBMdQMMWb/4wRApmI9hjHH05nefC0Ojec= github.com/cosmos/go-bip39 v1.0.0 h1:pcomnQdrdH22njcAatO0yWojsUnCO3y2tNoV1cb6hHY= github.com/cosmos/go-bip39 v1.0.0/go.mod h1:RNJv0H/pOIVgxw6KS7QeX2a0Uo0aKUlfhZ4xuwvCdJw= github.com/cosmos/gogogateway v1.2.0 h1:Ae/OivNhp8DqBi/sh2A8a1D0y638GpL3tkmLQAiKxTE= github.com/cosmos/gogogateway v1.2.0/go.mod h1:iQpLkGWxYcnCdz5iAdLcRBSw3h7NXeOkZ4GUkT+tbFI= github.com/cosmos/gogoproto v1.4.2/go.mod h1:cLxOsn1ljAHSV527CHOtaIP91kK6cCrZETRBrkzItWU= github.com/cosmos/gogoproto v1.7.0 h1:79USr0oyXAbxg3rspGh/m4SWNyoz/GLaAh0QlCe2fro= github.com/cosmos/gogoproto v1.7.0/go.mod h1:yWChEv5IUEYURQasfyBW5ffkMHR/90hiHgbNgrtp4j0= github.com/cosmos/iavl v0.20.1 h1:rM1kqeG3/HBT85vsZdoSNsehciqUQPWrR4BYmqE2+zg= github.com/cosmos/iavl v0.20.1/go.mod h1:WO7FyvaZJoH65+HFOsDir7xU9FWk2w9cHXNW1XHcl7A= github.com/cosmos/ibc-apps/middleware/packet-forward-middleware/v7 v7.3.0 h1:hYsyOQ94H5uYPuVZ7siye+4iDzMDqhQHgsa9x/XqJzI= github.com/cosmos/ibc-apps/middleware/packet-forward-middleware/v7 v7.3.0/go.mod h1:tLfRg+cJc0Dzx/jtF0Lo4n9Pa/NqobagOMrB+BVjCrk= github.com/cosmos/ibc-apps/modules/async-icq/v7 v7.1.1 h1:02RCbih5lQ8aGdDMSvxhTnk5JDLEDitn17ytEE1Qhko= github.com/cosmos/ibc-apps/modules/async-icq/v7 v7.1.1/go.mod h1:LvVkEXTORVgd87W2Yu7ZY3acKKeTMq/txdTworn8EZI= github.com/cosmos/ibc-apps/modules/ibc-hooks/v7 v7.0.0 h1:XtxqFntyBDqPFF4ayhzN6/HYoXPifRzt1url/afbx1U= github.com/cosmos/ibc-apps/modules/ibc-hooks/v7 v7.0.0/go.mod h1:md+Y3uUV5K7B3ddGYULcuU9excvr9mCXZjP8S0m7hTE= github.com/cosmos/ibc-go/v7 v7.10.0 h1:/IUJ6wilNnGcpP5XMb7p74JnctKDrFSv30i7aoJRnVI= github.com/cosmos/ibc-go/v7 v7.10.0/go.mod h1:PiVSJhIPBq/rI+6UOfKPy4RKDCvQ2vR+Vdb6SaowETQ= github.com/cosmos/ics23/go v0.10.0 h1:iXqLLgp2Lp+EdpIuwXTYIQU+AiHj9mOC2X9ab++bZDM= github.com/cosmos/ics23/go v0.10.0/go.mod h1:ZfJSmng/TBNTBkFemHHHj5YY7VAU/MBU980F4VU1NG0= github.com/cosmos/keyring v1.2.0 h1:8C1lBP9xhImmIabyXW4c3vFjjLiBdGCmfLUfeZlV1Yo= github.com/cosmos/keyring v1.2.0/go.mod h1:fc+wB5KTk9wQ9sDx0kFXB3A0MaeGHM9AwRStKOQ5vOA= github.com/cosmos/ledger-cosmos-go v0.12.4 h1:drvWt+GJP7Aiw550yeb3ON/zsrgW0jgh5saFCr7pDnw= github.com/cosmos/ledger-cosmos-go v0.12.4/go.mod h1:fjfVWRf++Xkygt9wzCsjEBdjcf7wiiY35fv3ctT+k4M= github.com/cosmos/rosetta-sdk-go v0.10.0 h1:E5RhTruuoA7KTIXUcMicL76cffyeoyvNybzUGSKFTcM= github.com/cosmos/rosetta-sdk-go v0.10.0/go.mod h1:SImAZkb96YbwvoRkzSMQB6noNJXFgWl/ENIznEoYQI4= github.com/cpuguy83/go-md2man/v2 v2.0.0-20190314233015-f79a8a8ca69d/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU= github.com/cpuguy83/go-md2man/v2 v2.0.4/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= github.com/creachadair/taskgroup v0.13.0 h1:VKaW1fi1/Erkkrvx4NvaddzHCGA+hh5QPc5Veiq+joI= github.com/creachadair/taskgroup v0.13.0/go.mod h1:9oDDPt/5QPS4iylvPMC81GRlj+1je8AFDbjUh4zaQWo= github.com/creack/pty v1.1.7/go.mod h1:lj5s0c3V2DBrqTV7llrYr5NG6My20zk30Fl46Y7DoTY= github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= github.com/cybercongress/cosmos-sdk v0.47.15-0.20250911123242-45d67c430be3 h1:VEdumhHrqaMW3he9R3dBYTRZAGDdop/125iUXd2tSDc= github.com/cybercongress/cosmos-sdk v0.47.15-0.20250911123242-45d67c430be3/go.mod h1:GrDj/zd9Tiuy8ZpG9PbUbhghCVU7lwyH0GS7CpxHpyM= github.com/danieljoos/wincred v1.1.2 h1:QLdCxFs1/Yl4zduvBdcHB8goaYk9RARS2SgLLRuAyr0= github.com/danieljoos/wincred v1.1.2/go.mod h1:GijpziifJoIBfYh+S7BbkdUTU4LfM+QnGqR5Vl2tAx0= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc h1:U9qPSI2PIWSS1VwoXQT9A3Wy9MM3WgvqSxFWenqJduM= github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/decred/dcrd/crypto/blake256 v1.0.1 h1:7PltbUIQB7u/FfZ39+DGa/ShuMyJ5ilcvdfma9wOH6Y= github.com/decred/dcrd/crypto/blake256 v1.0.1/go.mod h1:2OfgNZ5wDpcsFmHmCK5gZTPcCXqlm2ArzUIkw9czNJo= github.com/decred/dcrd/dcrec/secp256k1/v4 v4.3.0 h1:rpfIENRNNilwHwZeG5+P150SMrnNEcHYvcCuK6dPZSg= github.com/decred/dcrd/dcrec/secp256k1/v4 v4.3.0/go.mod h1:v57UDF4pDQJcEfFUCRop3lJL149eHGSe9Jvczhzjo/0= github.com/desertbit/timer v0.0.0-20180107155436-c41aec40b27f h1:U5y3Y5UE0w7amNe7Z5G/twsBW0KEalRQXZzf8ufSh9I= github.com/desertbit/timer v0.0.0-20180107155436-c41aec40b27f/go.mod h1:xH/i4TFMt8koVQZ6WFms69WAsDWr2XsYL3Hkl7jkoLE= github.com/dgraph-io/badger/v4 v4.2.0 h1:kJrlajbXXL9DFTNuhhu9yCx7JJa4qpYWxtE8BzuWsEs= github.com/dgraph-io/badger/v4 v4.2.0/go.mod h1:qfCqhPoWDFJRx1gp5QwwyGo8xk1lbHUxvK9nK0OGAak= github.com/dgraph-io/ristretto v0.1.1 h1:6CWw5tJNgpegArSHpNHJKldNeq03FQCwYvfMVWajOK8= github.com/dgraph-io/ristretto v0.1.1/go.mod h1:S1GPSBCYCIhmVNfcth17y2zZtQT6wzkzgwUve0VDWWA= github.com/dgryski/go-farm v0.0.0-20190423205320-6a90982ecee2/go.mod h1:SqUrOPUnsFjfmXRMNPybcSiG0BgUW2AuFH8PAnS2iTw= github.com/dgryski/go-farm v0.0.0-20200201041132-a6ae2369ad13 h1:fAjc9m62+UWV/WAFKLNi6ZS0675eEUC9y3AlwSbQu1Y= github.com/dgryski/go-farm v0.0.0-20200201041132-a6ae2369ad13/go.mod h1:SqUrOPUnsFjfmXRMNPybcSiG0BgUW2AuFH8PAnS2iTw= github.com/docker/distribution v2.8.2+incompatible h1:T3de5rq0dB1j30rp0sA2rER+m322EBzniBPB6ZIzuh8= github.com/docker/distribution v2.8.2+incompatible/go.mod h1:J2gT2udsDAN96Uj4KfcMRqY0/ypR+oyYUYmja8H+y+w= github.com/docker/go-connections v0.4.0 h1:El9xVISelRB7BuFusrZozjnkIM5YnzCViNKohAFqRJQ= github.com/docker/go-connections v0.4.0/go.mod h1:Gbd7IOopHjR8Iph03tsViu4nIes5XhDvyHbTtUxmeec= github.com/docker/go-units v0.5.0 h1:69rxXcBk27SvSaaxTtLh/8llcHD8vYHT7WSdRZ/jvr4= github.com/docker/go-units v0.5.0/go.mod h1:fgPhTUdO+D/Jk86RDLlptpiXQzgHJF7gydDDbaIK4Dk= github.com/dustin/go-humanize v0.0.0-20171111073723-bb3d318650d4/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk= github.com/dustin/go-humanize v1.0.0/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk= github.com/dustin/go-humanize v1.0.1 h1:GzkhY7T5VNhEkwH0PVJgjz+fX1rhBrR7pRT3mDkpeCY= github.com/dustin/go-humanize v1.0.1/go.mod h1:Mu1zIs6XwVuF/gI1OepvI0qD18qycQx+mFykh5fBlto= github.com/dvsekhvalnov/jose2go v1.6.0 h1:Y9gnSnP4qEI0+/uQkHvFXeD2PLPJeXEL+ySMEA2EjTY= github.com/dvsekhvalnov/jose2go v1.6.0/go.mod h1:QsHjhyTlD/lAVqn/NSbVZmSCGeDehTB/mPZadG+mhXU= github.com/eapache/go-resiliency v1.1.0/go.mod h1:kFI+JgMyC7bLPUVY133qvEBtVayf5mFgVsvEsIPBvNs= github.com/eapache/go-xerial-snappy v0.0.0-20180814174437-776d5712da21/go.mod h1:+020luEh2TKB4/GOp8oxxtq0Daoen/Cii55CzbTV6DU= github.com/eapache/queue v1.1.0/go.mod h1:6eCeP0CKFpHLu8blIFXhExK/dRa7WDZfr6jVFPTqq+I= github.com/edsrzf/mmap-go v1.0.0/go.mod h1:YO35OhQPt3KJa3ryjFM5Bs14WD66h8eGKpfaBNrHW5M= github.com/envoyproxy/go-control-plane v0.6.9/go.mod h1:SBwIajubJHhxtWwsL9s8ss4safvEdbitLhGGK48rN6g= github.com/envoyproxy/go-control-plane v0.9.0/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= github.com/envoyproxy/go-control-plane v0.9.4/go.mod h1:6rpuAdCZL397s3pYoYcLgu1mIlRU8Am5FuJP05cCM98= github.com/envoyproxy/go-control-plane v0.9.7/go.mod h1:cwu0lG7PUMfa9snN8LXBig5ynNVH9qI8YYLbd1fK2po= github.com/envoyproxy/go-control-plane v0.9.9-0.20201210154907-fd9021fe5dad/go.mod h1:cXg6YxExXjJnVBQHBLXeUAgxn2UodCpnH306RInaBQk= github.com/envoyproxy/go-control-plane v0.9.9-0.20210217033140-668b12f5399d/go.mod h1:cXg6YxExXjJnVBQHBLXeUAgxn2UodCpnH306RInaBQk= github.com/envoyproxy/go-control-plane v0.9.9-0.20210512163311-63b5d3c536b0/go.mod h1:hliV/p42l8fGbc6Y9bQ70uLwIvmJyVE5k4iMKlh8wCQ= github.com/envoyproxy/go-control-plane v0.9.10-0.20210907150352-cf90f659a021/go.mod h1:AFq3mo9L8Lqqiid3OhADV3RfLJnjiw63cSpi+fDTRC0= github.com/envoyproxy/go-control-plane v0.10.2-0.20220325020618-49ff273808a1/go.mod h1:KJwIaB5Mv44NWtYuAOFCVOjcI94vtpEz2JU/D2v6IjE= github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c= github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4= github.com/felixge/httpsnoop v1.0.1/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U= github.com/felixge/httpsnoop v1.0.4 h1:NFTV2Zj1bL4mc9sqWACXbQFVBBg2W3GPvqp8/ESS2Wg= github.com/felixge/httpsnoop v1.0.4/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U= github.com/fortytw2/leaktest v1.3.0 h1:u8491cBMTQ8ft8aeV+adlcytMZylmA5nnwwkRZjI8vw= github.com/fortytw2/leaktest v1.3.0/go.mod h1:jDsjWgpAGjm2CA7WthBh/CdZYEPF31XHquHwclZch5g= github.com/franela/goblin v0.0.0-20200105215937-c9ffbefa60db/go.mod h1:7dvUGVsVBjqR7JHJk0brhHOZYGmfBYOrK0ZhYMEtBr4= github.com/franela/goreq v0.0.0-20171204163338-bcd34c9993f8/go.mod h1:ZhphrRTfi2rbfLwlschooIH4+wKKDR4Pdxhh+TRoA20= github.com/frankban/quicktest v1.14.6 h1:7Xjx+VpznH+oBnejlPUj8oUpdxnVs4f8XU8WnHkI4W8= github.com/frankban/quicktest v1.14.6/go.mod h1:4ptaffx2x8+WTWXmUCuVU6aPUX1/Mz7zb5vbUoiM6w0= github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4IgpuI1SZQ= github.com/fsnotify/fsnotify v1.7.0 h1:8JEhPFa5W2WU7YfeZzPNqzMP6Lwt7L2715Ggo0nosvA= github.com/fsnotify/fsnotify v1.7.0/go.mod h1:40Bi/Hjc2AVfZrqy+aj+yEI+/bRxZnMJyTJwOpGvigM= github.com/getsentry/sentry-go v0.23.0 h1:dn+QRCeJv4pPt9OjVXiMcGIBIefaTJPw/h0bZWO05nE= github.com/getsentry/sentry-go v0.23.0/go.mod h1:lc76E2QywIyW8WuBnwl8Lc4bkmQH4+w1gwTf25trprY= github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= github.com/gin-contrib/sse v0.1.0 h1:Y/yl/+YNO8GZSjAhjMsSuLt29uWRFHdHYUb5lYOV9qE= github.com/gin-contrib/sse v0.1.0/go.mod h1:RHrZQHXnP2xjPF+u1gW/2HnVO7nvIa9PG3Gm+fLHvGI= github.com/gin-gonic/gin v1.9.0 h1:OjyFBKICoexlu99ctXNR2gg+c5pKrKMuyjgARg9qeY8= github.com/gin-gonic/gin v1.9.0/go.mod h1:W1Me9+hsUSyj3CePGrd1/QrKJMSJ1Tu/0hFEH89961k= github.com/go-errors/errors v1.4.2 h1:J6MZopCL4uSllY1OfXM374weqZFFItUbrImctkmUxIA= github.com/go-errors/errors v1.4.2/go.mod h1:sIVyrIiJhuEF+Pj9Ebtd6P/rEYROXFi3BopGUQ5a5Og= github.com/go-kit/kit v0.8.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as= github.com/go-kit/kit v0.9.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as= github.com/go-kit/kit v0.10.0/go.mod h1:xUsJbQ/Fp4kEt7AFgCuvyX4a71u8h9jB8tj/ORgOZ7o= github.com/go-kit/kit v0.13.0 h1:OoneCcHKHQ03LfBpoQCUfCluwd2Vt3ohz+kvbJneZAU= github.com/go-kit/kit v0.13.0/go.mod h1:phqEHMMUbyrCFCTgH48JueqrM3md2HcAZ8N3XE4FKDg= github.com/go-kit/log v0.2.1 h1:MRVx0/zhvdseW+Gza6N9rVzU/IVzaeE1SFI4raAhmBU= github.com/go-kit/log v0.2.1/go.mod h1:NwTd00d/i8cPZ3xOwwiv2PO5MOcx78fFErGNcVmBjv0= github.com/go-logfmt/logfmt v0.3.0/go.mod h1:Qt1PoO58o5twSAckw1HlFXLmHsOX5/0LbT9GBnD5lWE= github.com/go-logfmt/logfmt v0.4.0/go.mod h1:3RMwSq7FuexP4Kalkev3ejPJsZTpXXBr9+V4qmtdjCk= github.com/go-logfmt/logfmt v0.5.0/go.mod h1:wCYkCAKZfumFQihp8CzCvQ3paCTfi41vtzG1KdI/P7A= github.com/go-logfmt/logfmt v0.6.0 h1:wGYYu3uicYdqXVgoYbvnkrPVXkuLM1p1ifugDMEdRi4= github.com/go-logfmt/logfmt v0.6.0/go.mod h1:WYhtIu8zTZfxdn5+rREduYbwxfcBr/Vr6KEVveWlfTs= github.com/go-logr/logr v1.2.2/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= github.com/go-logr/logr v1.4.1 h1:pKouT5E8xu9zeFC39JXRDukb6JFQPXM5p5I91188VAQ= github.com/go-logr/logr v1.4.1/go.mod h1:9T104GzyrTigFIr8wt5mBrctHMim0Nb2HLGrmQ40KvY= github.com/go-logr/stdr v1.2.2 h1:hSWxHoqTgW2S2qGc0LTAI563KZ5YKYRhT3MFKZMbjag= github.com/go-logr/stdr v1.2.2/go.mod h1:mMo/vtBO5dYbehREoey6XUKy/eSumjCCveDpRre4VKE= github.com/go-playground/assert/v2 v2.2.0/go.mod h1:VDjEfimB/XKnb+ZQfWdccd7VUvScMdVu0Titje2rxJ4= github.com/go-playground/locales v0.14.1 h1:EWaQ/wswjilfKLTECiXz7Rh+3BjFhfDFKv/oXslEjJA= github.com/go-playground/locales v0.14.1/go.mod h1:hxrqLVvrK65+Rwrd5Fc6F2O76J/NuW9t0sjnWqG1slY= github.com/go-playground/universal-translator v0.18.1 h1:Bcnm0ZwsGyWbCzImXv+pAJnYK9S473LQFuzCbDbfSFY= github.com/go-playground/universal-translator v0.18.1/go.mod h1:xekY+UJKNuX9WP91TpwSH2VMlDf28Uj24BCp08ZFTUY= github.com/go-playground/validator/v10 v10.11.2 h1:q3SHpufmypg+erIExEKUmsgmhDTyhcJ38oeKGACXohU= github.com/go-playground/validator/v10 v10.11.2/go.mod h1:NieE624vt4SCTJtD87arVLvdmjPAeV8BQlHtMnw9D7s= github.com/go-sql-driver/mysql v1.4.0/go.mod h1:zAC/RDZ24gD3HViQzih4MyKcchzm+sOG5ZlKdlhCg5w= github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY= github.com/gobwas/httphead v0.0.0-20180130184737-2c6c146eadee h1:s+21KNqlpePfkah2I+gwHF8xmJWRjooY+5248k6m4A0= github.com/gobwas/httphead v0.0.0-20180130184737-2c6c146eadee/go.mod h1:L0fX3K22YWvt/FAX9NnzrNzcI4wNYi9Yku4O0LKYflo= github.com/gobwas/pool v0.2.0 h1:QEmUOlnSjWtnpRGHF3SauEiOsy82Cup83Vf2LcMlnc8= github.com/gobwas/pool v0.2.0/go.mod h1:q8bcK0KcYlCgd9e7WYLm9LpyS+YeLd8JVDW6WezmKEw= github.com/gobwas/ws v1.0.2 h1:CoAavW/wd/kulfZmSIBt6p24n4j7tHgNVCjsfHVNUbo= github.com/gobwas/ws v1.0.2/go.mod h1:szmBTxLgaFppYjEmNtny/v3w89xOydFnnZMcgRRu/EM= github.com/goccy/go-json v0.10.0 h1:mXKd9Qw4NuzShiRlOXKews24ufknHO7gx30lsDyokKA= github.com/goccy/go-json v0.10.0/go.mod h1:6MelG93GURQebXPDq3khkgXZkazVtN9CRI+MGFi0w8I= github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2 h1:ZpnhV/YsD2/4cESfV5+Hoeu/iUR3ruzNvZ+yQfO03a0= github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2/go.mod h1:bBOAhwG1umN6/6ZUMtDFBMQR8jRg9O75tm9K00oMsK4= github.com/godbus/dbus/v5 v5.0.4/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5xrFpKfA= github.com/gogo/googleapis v1.1.0/go.mod h1:gf4bu3Q80BeJ6H1S1vYPm8/ELATdvryBaNFGgqEef3s= github.com/gogo/googleapis v1.4.1-0.20201022092350-68b0159b7869/go.mod h1:5YRNX2z1oM5gXdAkurHa942MDgEJyk02w4OecKY87+c= github.com/gogo/googleapis v1.4.1 h1:1Yx4Myt7BxzvUr5ldGSbwYiZG6t9wGBZ+8/fX3Wvtq0= github.com/gogo/googleapis v1.4.1/go.mod h1:2lpHqI5OcWCtVElxXnPt+s8oJvMpySlOyM6xDCrzib4= github.com/gogo/protobuf v1.1.1/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ= github.com/gogo/protobuf v1.2.0/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ= github.com/gogo/protobuf v1.2.1/go.mod h1:hp+jE20tsWTFYpLwKvXlhS1hjn+gTNwPg2I6zVXpSg4= github.com/gogo/protobuf v1.3.1/go.mod h1:SlYgWuQ5SjCEi6WLHjHCa1yvBfUnHcTbrrZtXPKa29o= github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q= github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q= github.com/golang-jwt/jwt/v4 v4.4.2/go.mod h1:m21LjoU+eqJr34lmDMbreY2eSTRJ1cv77w39/MY0Ch0= github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q= github.com/golang/glog v1.2.2 h1:1+mZ9upx1Dh6FmUTFR1naJ77miKiXgALjWOZ3NVFPmY= github.com/golang/glog v1.2.2/go.mod h1:6AhwSGph0fcJtXVM/PEHPqZlFeoLxhs7/t5UDAwmO+w= github.com/golang/groupcache v0.0.0-20160516000752-02826c3e7903/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= github.com/golang/groupcache v0.0.0-20190702054246-869f871628b6/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= github.com/golang/groupcache v0.0.0-20191227052852-215e87163ea7/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= github.com/golang/groupcache v0.0.0-20200121045136-8c9f03a8e57e/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da h1:oI5xCqsCo564l8iNU+DwB5epxmsaqB+rhGL0m5jtYqE= github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= github.com/golang/mock v1.1.1/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A= github.com/golang/mock v1.2.0/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A= github.com/golang/mock v1.3.1/go.mod h1:sBzyDLLjw3U8JLTeZvSv8jJB+tU5PVekmnlKIyFUx0Y= github.com/golang/mock v1.4.0/go.mod h1:UOMv5ysSaYNkG+OFQykRIcU/QvvxJf3p21QfJ2Bt3cw= github.com/golang/mock v1.4.1/go.mod h1:UOMv5ysSaYNkG+OFQykRIcU/QvvxJf3p21QfJ2Bt3cw= github.com/golang/mock v1.4.3/go.mod h1:UOMv5ysSaYNkG+OFQykRIcU/QvvxJf3p21QfJ2Bt3cw= github.com/golang/mock v1.4.4/go.mod h1:l3mdAwkq5BuhzHwde/uurv3sEJeZMXNpwsxVWU71h+4= github.com/golang/mock v1.5.0/go.mod h1:CWnOUgYIOo4TcNZ0wHX3YZCqsaM1I1Jvs6v3mP3KVu8= github.com/golang/mock v1.6.0 h1:ErTB+efbowRARo13NNdxyJji2egdxLGQhRaY+DUumQc= github.com/golang/mock v1.6.0/go.mod h1:p6yTPP+5HYm5mzsMV8JkE6ZKdX+/wYM6Hr+LicevLPs= github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= github.com/golang/protobuf v1.3.0/go.mod h1:Qd/q+1AKNOZr9uGQzbzCmRO6sUih6GTPZv6a1/R87v0= github.com/golang/protobuf v1.3.1/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= github.com/golang/protobuf v1.3.2/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= github.com/golang/protobuf v1.3.3/go.mod h1:vzj43D7+SQXF/4pzW/hwtAqwc6iTitCiVSaWz5lYuqw= github.com/golang/protobuf v1.3.4/go.mod h1:vzj43D7+SQXF/4pzW/hwtAqwc6iTitCiVSaWz5lYuqw= github.com/golang/protobuf v1.3.5/go.mod h1:6O5/vntMXwX2lRkT1hjjk0nAC1IDOTvTlVgjlRvqsdk= github.com/golang/protobuf v1.4.0-rc.1/go.mod h1:ceaxUfeHdC40wWswd/P6IGgMaK3YpKi5j83Wpe3EHw8= github.com/golang/protobuf v1.4.0-rc.1.0.20200221234624-67d41d38c208/go.mod h1:xKAWHe0F5eneWXFV3EuXVDTCmh+JuBKY0li0aMyXATA= github.com/golang/protobuf v1.4.0-rc.2/go.mod h1:LlEzMj4AhA7rCAGe4KMBDvJI+AwstrUpVNzEA03Pprs= github.com/golang/protobuf v1.4.0-rc.4.0.20200313231945-b860323f09d0/go.mod h1:WU3c8KckQ9AFe+yFwt9sWVRKCVIyN9cPHBJSNnbL67w= github.com/golang/protobuf v1.4.0/go.mod h1:jodUvKwWbYaEsadDk5Fwe5c77LiNKVO9IDvqG2KuDX0= github.com/golang/protobuf v1.4.1/go.mod h1:U8fpvMrcmy5pZrNK1lt4xCsGvpyWQ/VVv6QDs8UjoX8= github.com/golang/protobuf v1.4.2/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= github.com/golang/protobuf v1.4.3/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= github.com/golang/protobuf v1.5.0/go.mod h1:FsONVRAS9T7sI+LIUmWTfcYkHO4aIWwzhcaSAoJOfIk= github.com/golang/protobuf v1.5.1/go.mod h1:DopwsBzvsk0Fs44TXzsVbJyPhcCPeIwnvohx4u74HPM= github.com/golang/protobuf v1.5.2/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= github.com/golang/protobuf v1.5.4 h1:i7eJL8qZTpSEXOPTxNKhASYpMn+8e5Q6AdndVa1dWek= github.com/golang/protobuf v1.5.4/go.mod h1:lnTiLA8Wa4RWRcIUkrtSVa5nRhsEGBg48fD6rSs7xps= github.com/golang/snappy v0.0.0-20180518054509-2e65f85255db/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= github.com/golang/snappy v0.0.3/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= github.com/golang/snappy v0.0.4 h1:yAGX7huGHXlcLOEtBnF4w7FQwA26wojNCwOYAEhLjQM= github.com/golang/snappy v0.0.4/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= github.com/google/btree v0.0.0-20180813153112-4030bb1f1f0c/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= github.com/google/btree v1.0.0/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= github.com/google/btree v1.1.3 h1:CVpQJjYgC4VbzxeGVHfvZrv1ctoYCAI8vbl07Fcxlyg= github.com/google/btree v1.1.3/go.mod h1:qOPhT0dTNdNzV6Z/lhRX0YXUafgPLFUh+gZMl761Gm4= github.com/google/flatbuffers v1.12.1 h1:MVlul7pQNoDzWRLTw5imwYsl+usrS1TXG2H4jg6ImGw= github.com/google/flatbuffers v1.12.1/go.mod h1:1AeVuKshWv4vARoZatz6mlQ0JxURH0Kv5+zNeJKJCa8= github.com/google/go-cmp v0.2.0/go.mod h1:oXzfMopK8JAjlY9xF4vHSVASa0yLyX7SntLO5aqRK0M= github.com/google/go-cmp v0.3.0/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= github.com/google/go-cmp v0.3.1/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= github.com/google/go-cmp v0.4.0/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.4.1/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.0/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.1/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.2/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.3/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.4/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.6/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.7/go.mod h1:n+brtR0CgQNWTVd5ZUFpTBC8YFBDLK/h/bpaJ8/DtOE= github.com/google/go-cmp v0.5.8/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= github.com/google/go-cmp v0.5.9/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI= github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= github.com/google/gofuzz v0.0.0-20170612174753-24818f796faf/go.mod h1:HP5RmnzzSNb993RKQDq4+1A4ia9nllfqcQFTQJedwGI= github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/gofuzz v1.2.0 h1:xRy4A+RhZaiKjJ1bPfwQ8sedCA+YS2YcCHW6ec7JMi0= github.com/google/gofuzz v1.2.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/martian v2.1.0+incompatible h1:/CP5g8u/VJHijgedC/Legn3BAbAaWPgecwXBIDzw5no= github.com/google/martian v2.1.0+incompatible/go.mod h1:9I4somxYTbIHy5NJKHRl3wXiIaQGbYVAs8BPL6v8lEs= github.com/google/martian/v3 v3.0.0/go.mod h1:y5Zk1BBys9G+gd6Jrk0W3cC1+ELVxBWuIGO+w/tUAp0= github.com/google/martian/v3 v3.1.0/go.mod h1:y5Zk1BBys9G+gd6Jrk0W3cC1+ELVxBWuIGO+w/tUAp0= github.com/google/martian/v3 v3.2.1/go.mod h1:oBOf6HBosgwRXnUGWUB05QECsc6uvmMiJ3+6W4l/CUk= github.com/google/martian/v3 v3.3.2 h1:IqNFLAmvJOgVlpdEBiQbDc2EwKW77amAycfTuWKdfvw= github.com/google/martian/v3 v3.3.2/go.mod h1:oBOf6HBosgwRXnUGWUB05QECsc6uvmMiJ3+6W4l/CUk= github.com/google/orderedcode v0.0.1 h1:UzfcAexk9Vhv8+9pNOgRu41f16lHq725vPwnSeiG/Us= github.com/google/orderedcode v0.0.1/go.mod h1:iVyU4/qPKHY5h/wSd6rZZCDcLJNxiWO6dvsYES2Sb20= github.com/google/pprof v0.0.0-20181206194817-3ea8567a2e57/go.mod h1:zfwlbNMJ+OItoe0UupaVj+oy1omPYYDuagoSzA8v9mc= github.com/google/pprof v0.0.0-20190515194954-54271f7e092f/go.mod h1:zfwlbNMJ+OItoe0UupaVj+oy1omPYYDuagoSzA8v9mc= github.com/google/pprof v0.0.0-20191218002539-d4f498aebedc/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM= github.com/google/pprof v0.0.0-20200212024743-f11f1df84d12/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM= github.com/google/pprof v0.0.0-20200229191704-1ebb73c60ed3/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM= github.com/google/pprof v0.0.0-20200430221834-fc25d7d30c6d/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM= github.com/google/pprof v0.0.0-20200708004538-1a94d8640e99/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM= github.com/google/pprof v0.0.0-20201023163331-3e6fc7fc9c4c/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/pprof v0.0.0-20201203190320-1bf35d6f28c2/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/pprof v0.0.0-20210122040257-d980be63207e/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/pprof v0.0.0-20210226084205-cbba55b83ad5/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/pprof v0.0.0-20210601050228-01bbb1931b22/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/pprof v0.0.0-20210609004039-a478d1d731e9/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/pprof v0.0.0-20210720184732-4bb14d4b1be1/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI= github.com/google/s2a-go v0.1.7 h1:60BLSyTrOV4/haCDW4zb1guZItoSq8foHCXrAnjBo/o= github.com/google/s2a-go v0.1.7/go.mod h1:50CgR4k1jNlWBu4UfS4AcfhVe1r6pdZPygJ3R8F0Qdw= github.com/google/uuid v1.0.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/google/uuid v1.3.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/google/uuid v1.6.0 h1:NIvaJDMOsjHA8n1jAhLSgzrAzy1Hgr+hNrb57e+94F0= github.com/google/uuid v1.6.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/googleapis/enterprise-certificate-proxy v0.0.0-20220520183353-fd19c99a87aa/go.mod h1:17drOmN3MwGY7t0e+Ei9b45FFGA3fBs3x36SsCg1hq8= github.com/googleapis/enterprise-certificate-proxy v0.1.0/go.mod h1:17drOmN3MwGY7t0e+Ei9b45FFGA3fBs3x36SsCg1hq8= github.com/googleapis/enterprise-certificate-proxy v0.2.0/go.mod h1:8C0jb7/mgJe/9KK8Lm7X9ctZC2t60YyIpYEI16jx0Qg= github.com/googleapis/enterprise-certificate-proxy v0.3.2 h1:Vie5ybvEvT75RniqhfFxPRy3Bf7vr3h0cechB90XaQs= github.com/googleapis/enterprise-certificate-proxy v0.3.2/go.mod h1:VLSiSSBs/ksPL8kq3OBOQ6WRI2QnaFynd1DCjZ62+V0= github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+vpHVxEJEs9eg= github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5mhpdKc/us6bOk= github.com/googleapis/gax-go/v2 v2.1.0/go.mod h1:Q3nei7sK6ybPYH7twZdmQpAd1MKb7pfu6SK+H1/DsU0= github.com/googleapis/gax-go/v2 v2.1.1/go.mod h1:hddJymUZASv3XPyGkUpKj8pPO47Rmb0eJc8R6ouapiM= github.com/googleapis/gax-go/v2 v2.2.0/go.mod h1:as02EH8zWkzwUoLbBaFeQ+arQaj/OthfcblKl4IGNaM= github.com/googleapis/gax-go/v2 v2.3.0/go.mod h1:b8LNqSzNabLiUpXKkY7HAR5jr6bIT99EXz9pXxye9YM= github.com/googleapis/gax-go/v2 v2.4.0/go.mod h1:XOTVJ59hdnfJLIP/dh8n5CGryZR2LxK9wbMD5+iXC6c= github.com/googleapis/gax-go/v2 v2.5.1/go.mod h1:h6B0KMMFNtI2ddbGJn3T3ZbwkeT6yqEF02fYlzkUCyo= github.com/googleapis/gax-go/v2 v2.6.0/go.mod h1:1mjbznJAPHFpesgE5ucqfYEscaz5kMdcIDwU/6+DDoY= github.com/googleapis/gax-go/v2 v2.12.3 h1:5/zPPDvw8Q1SuXjrqrZslrqT7dL/uJT2CQii/cLCKqA= github.com/googleapis/gax-go/v2 v2.12.3/go.mod h1:AKloxT6GtNbaLm8QTNSidHUVsHYcBHwWRvkNFJUQcS4= github.com/googleapis/go-type-adapters v1.0.0/go.mod h1:zHW75FOG2aur7gAO2B+MLby+cLsWGBF62rFAi7WjWO4= github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY= github.com/gorilla/context v1.1.1/go.mod h1:kBGZzfjB9CEq2AlWe17Uuf7NDRt0dE0s8S51q0aT7Yg= github.com/gorilla/handlers v1.5.1 h1:9lRY6j8DEeeBT10CvO9hGW0gmky0BprnvDI5vfhUHH4= github.com/gorilla/handlers v1.5.1/go.mod h1:t8XrUpc4KVXb7HGyJ4/cEnwQiaxrX/hz1Zv/4g96P1Q= github.com/gorilla/mux v1.6.2/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2zaAs= github.com/gorilla/mux v1.7.3/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2zaAs= github.com/gorilla/mux v1.8.0 h1:i40aqfkR1h2SlN9hojwV5ZA91wcXFOvkdNIeFDP5koI= github.com/gorilla/mux v1.8.0/go.mod h1:DVbg23sWSpFRCP0SfiEN6jmj59UnW/n46BH5rLB71So= github.com/gorilla/websocket v0.0.0-20170926233335-4201258b820c/go.mod h1:E7qHFY5m1UJ88s3WnNqhKjPHQ0heANvMoAMk2YaljkQ= github.com/gorilla/websocket v1.4.1/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= github.com/gorilla/websocket v1.5.3 h1:saDtZ6Pbx/0u+bgYQ3q96pZgCzfhKXGPqt7kZ72aNNg= github.com/gorilla/websocket v1.5.3/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= github.com/grpc-ecosystem/go-grpc-middleware v1.0.1-0.20190118093823-f849b5445de4/go.mod h1:FiyG127CGDf3tlThmgyCl78X/SZQqEOJBCDaAfeWzPs= github.com/grpc-ecosystem/go-grpc-middleware v1.2.2/go.mod h1:EaizFBKfUKtMIF5iaDEhniwNedqGo9FuLFzppDr3uwI= github.com/grpc-ecosystem/go-grpc-middleware v1.3.0 h1:+9834+KizmvFV7pXQGSXQTsaWhq2GjuNUt0aUU0YBYw= github.com/grpc-ecosystem/go-grpc-middleware v1.3.0/go.mod h1:z0ButlSOZa5vEBq9m2m2hlwIgKw+rp3sdCBRoJY+30Y= github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= github.com/grpc-ecosystem/grpc-gateway v1.9.5/go.mod h1:vNeuVxBJEsws4ogUvrchl83t/GYV9WGTSLVdBhOQFDY= github.com/grpc-ecosystem/grpc-gateway v1.16.0 h1:gmcG1KaJ57LophUzW0Hy8NmPhnMZb4M0+kPpLofRdBo= github.com/grpc-ecosystem/grpc-gateway v1.16.0/go.mod h1:BDjrQk3hbvj6Nolgz8mAMFbcEtjT1g+wF4CSlocrBnw= github.com/gsterjov/go-libsecret v0.0.0-20161001094733-a6f4afe4910c h1:6rhixN/i8ZofjG1Y75iExal34USq5p+wiN1tpie8IrU= github.com/gsterjov/go-libsecret v0.0.0-20161001094733-a6f4afe4910c/go.mod h1:NMPJylDgVpX0MLRlPy15sqSwOFv/U1GZ2m21JhFfek0= github.com/gtank/merlin v0.1.1 h1:eQ90iG7K9pOhtereWsmyRJ6RAwcP4tHTDBHXNg+u5is= github.com/gtank/merlin v0.1.1/go.mod h1:T86dnYJhcGOh5BjZFCJWTDeTK7XW8uE+E21Cy/bIQ+s= github.com/gtank/ristretto255 v0.1.2 h1:JEqUCPA1NvLq5DwYtuzigd7ss8fwbYay9fi4/5uMzcc= github.com/gtank/ristretto255 v0.1.2/go.mod h1:Ph5OpO6c7xKUGROZfWVLiJf9icMDwUeIvY4OmlYW69o= github.com/hashicorp/consul/api v1.3.0/go.mod h1:MmDNSzIMUjNpY/mQ398R4bk2FnqQLoPndWW5VkKPlCE= github.com/hashicorp/consul/sdk v0.3.0/go.mod h1:VKf9jXwCTEY1QZP2MOLRhb5i/I/ssyNV1vwHyQBF0x8= github.com/hashicorp/errwrap v1.0.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4= github.com/hashicorp/go-cleanhttp v0.5.0/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80= github.com/hashicorp/go-cleanhttp v0.5.1/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80= github.com/hashicorp/go-cleanhttp v0.5.2 h1:035FKYIWjmULyFRBKPs8TBQoi0x6d9G4xc9neXJWAZQ= github.com/hashicorp/go-cleanhttp v0.5.2/go.mod h1:kO/YDlP8L1346E6Sodw+PrpBSV4/SoxCXGY6BqNFT48= github.com/hashicorp/go-getter v1.7.5 h1:dT58k9hQ/vbxNMwoI5+xFYAJuv6152UNvdHokfI5wE4= github.com/hashicorp/go-getter v1.7.5/go.mod h1:W7TalhMmbPmsSMdNjD0ZskARur/9GJ17cfHTRtXV744= github.com/hashicorp/go-immutable-radix v1.0.0/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60= github.com/hashicorp/go-immutable-radix v1.3.1 h1:DKHmCUm2hRBK510BaiZlwvpD40f8bJFeZnpfm2KLowc= github.com/hashicorp/go-immutable-radix v1.3.1/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60= github.com/hashicorp/go-msgpack v0.5.3/go.mod h1:ahLV/dePpqEmjfWmKiqvPkv/twdG7iPBM1vqhUKIvfM= github.com/hashicorp/go-multierror v1.0.0/go.mod h1:dHtQlpGsu+cZNNAkkCN/P3hoUDHhCYQXV3UM06sGGrk= github.com/hashicorp/go-retryablehttp v0.5.3/go.mod h1:9B5zBasrRhHXnJnui7y6sL7es7NDiJgTc6Er0maI1Xs= github.com/hashicorp/go-rootcerts v1.0.0/go.mod h1:K6zTfqpRlCUIjkwsN4Z+hiSfzSTQa6eBIzfwKfwNnHU= github.com/hashicorp/go-safetemp v1.0.0 h1:2HR189eFNrjHQyENnQMMpCiBAsRxzbTMIgBhEyExpmo= github.com/hashicorp/go-safetemp v1.0.0/go.mod h1:oaerMy3BhqiTbVye6QuFhFtIceqFoDHxNAB65b+Rj1I= github.com/hashicorp/go-sockaddr v1.0.0/go.mod h1:7Xibr9yA9JjQq1JpNB2Vw7kxv8xerXegt+ozgdvDeDU= github.com/hashicorp/go-syslog v1.0.0/go.mod h1:qPfqrKkXGihmCqbJM2mZgkZGvKG1dFdvsLplgctolz4= github.com/hashicorp/go-uuid v1.0.0/go.mod h1:6SBZvOh/SIDV7/2o3Jml5SYk/TvGqwFJ/bN7x4byOro= github.com/hashicorp/go-uuid v1.0.1 h1:fv1ep09latC32wFoVwnqcnKJGnMSdBanPczbHAYm1BE= github.com/hashicorp/go-uuid v1.0.1/go.mod h1:6SBZvOh/SIDV7/2o3Jml5SYk/TvGqwFJ/bN7x4byOro= github.com/hashicorp/go-version v1.2.0/go.mod h1:fltr4n8CU8Ke44wwGCBoEymUuxUHl09ZGVZPK5anwXA= github.com/hashicorp/go-version v1.6.0 h1:feTTfFNnjP967rlCxM/I9g701jU+RN74YKx2mOkIeek= github.com/hashicorp/go-version v1.6.0/go.mod h1:fltr4n8CU8Ke44wwGCBoEymUuxUHl09ZGVZPK5anwXA= github.com/hashicorp/go.net v0.0.1/go.mod h1:hjKkEWcCURg++eb33jQU7oqQcI9XDCnUzHA0oac0k90= github.com/hashicorp/golang-lru v0.5.0/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= github.com/hashicorp/golang-lru v0.5.1/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= github.com/hashicorp/golang-lru v0.5.5-0.20210104140557-80c98217689d h1:dg1dEPuWpEqDnvIw251EVy4zlP8gWbsGj4BsUKCRpYs= github.com/hashicorp/golang-lru v0.5.5-0.20210104140557-80c98217689d/go.mod h1:iADmTwqILo4mZ8BN3D2Q6+9jd8WM5uGBxy+E8yxSoD4= github.com/hashicorp/golang-lru/v2 v2.0.7 h1:a+bsQ5rvGLjzHuww6tVxozPZFVghXaHOwFs4luLUK2k= github.com/hashicorp/golang-lru/v2 v2.0.7/go.mod h1:QeFd9opnmA6QUJc5vARoKUSoFhyfM2/ZepoAG6RGpeM= github.com/hashicorp/hcl v1.0.0 h1:0Anlzjpi4vEasTeNFn2mLJgTSwt0+6sfsiTG8qcWGx4= github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T20WEQ= github.com/hashicorp/logutils v1.0.0/go.mod h1:QIAnNjmIWmVIIkWDTG1z5v++HQmx9WQRO+LraFDTW64= github.com/hashicorp/mdns v1.0.0/go.mod h1:tL+uN++7HEJ6SQLQ2/p+z2pH24WQKWjBPkE0mNTz8vQ= github.com/hashicorp/memberlist v0.1.3/go.mod h1:ajVTdAv/9Im8oMAAj5G31PhhMCZJV2pPBoIllUwCN7I= github.com/hashicorp/serf v0.8.2/go.mod h1:6hOLApaqBFA1NXqRQAsxw9QxuDEvNxSQRwA/JwenrHc= github.com/hdevalence/ed25519consensus v0.1.0 h1:jtBwzzcHuTmFrQN6xQZn6CQEO/V9f7HsjsjeEZ6auqU= github.com/hdevalence/ed25519consensus v0.1.0/go.mod h1:w3BHWjwJbFU29IRHL1Iqkw3sus+7FctEyM4RqDxYNzo= github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU= github.com/huandu/go-assert v1.1.5 h1:fjemmA7sSfYHJD7CUqs9qTwwfdNAx7/j2/ZlHXzNB3c= github.com/huandu/go-assert v1.1.5/go.mod h1:yOLvuqZwmcHIC5rIzrBhT7D3Q9c3GFnd0JrPVhn/06U= github.com/huandu/skiplist v1.2.0 h1:gox56QD77HzSC0w+Ws3MH3iie755GBJU1OER3h5VsYw= github.com/huandu/skiplist v1.2.0/go.mod h1:7v3iFjLcSAzO4fN5B8dvebvo/qsfumiLiDXMrPiHF9w= github.com/hudl/fargo v1.3.0/go.mod h1:y3CKSmjA+wD2gak7sUSXTAoopbhU08POFhmITJgmKTg= github.com/iancoleman/orderedmap v0.3.0 h1:5cbR2grmZR/DiVt+VJopEhtVs9YGInGIxAoMJn+Ichc= github.com/iancoleman/orderedmap v0.3.0/go.mod h1:XuLcCUkdL5owUCQeF2Ue9uuw1EptkJDkXXS7VoV7XGE= github.com/ianlancetaylor/demangle v0.0.0-20181102032728-5e5cf60278f6/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= github.com/ianlancetaylor/demangle v0.0.0-20200824232613-28f6c0f3b639/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= github.com/improbable-eng/grpc-web v0.15.0 h1:BN+7z6uNXZ1tQGcNAuaU1YjsLTApzkjt2tzCixLaUPQ= github.com/improbable-eng/grpc-web v0.15.0/go.mod h1:1sy9HKV4Jt9aEs9JSnkWlRJPuPtwNr0l57L4f878wP8= github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8= github.com/inconshreveable/mousetrap v1.1.0 h1:wN+x4NVGpMsO7ErUn/mUI3vEoE6Jt13X2s0bqwp9tc8= github.com/inconshreveable/mousetrap v1.1.0/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw= github.com/influxdata/influxdb1-client v0.0.0-20191209144304-8bf82d3c094d/go.mod h1:qj24IKcXYK6Iy9ceXlo3Tc+vtHo9lIhSX5JddghvEPo= github.com/ipfs/go-cid v0.0.7 h1:ysQJVJA3fNDF1qigJbsSQOdjhVLsOEoPdh0+R97k3jY= github.com/ipfs/go-cid v0.0.7/go.mod h1:6Ux9z5e+HpkQdckYoX1PG/6xqKspzlEIR5SDmgqgC/I= github.com/jhump/protoreflect v1.15.1 h1:HUMERORf3I3ZdX05WaQ6MIpd/NJ434hTp5YiKgfCL6c= github.com/jhump/protoreflect v1.15.1/go.mod h1:jD/2GMKKE6OqX8qTjhADU1e6DShO+gavG9e0Q693nKo= github.com/jmespath/go-jmespath v0.0.0-20180206201540-c2b33e8439af/go.mod h1:Nht3zPeWKUH0NzdCt2Blrr5ys8VGpn0CEB0cQHVjt7k= github.com/jmespath/go-jmespath v0.4.0 h1:BEgLn5cpjn8UN1mAw4NjwDrS35OdebyEtFe+9YPoQUg= github.com/jmespath/go-jmespath v0.4.0/go.mod h1:T8mJZnbsbmF+m6zOOFylbeCJqk5+pHWvzYPziyZiYoo= github.com/jmespath/go-jmespath/internal/testify v1.5.1 h1:shLQSRRSCCPj3f2gpwzGwWFoC7ycTf1rcQZHOlsJ6N8= github.com/jmespath/go-jmespath/internal/testify v1.5.1/go.mod h1:L3OGu8Wl2/fWfCI6z80xFu9LTZmf1ZRjMHUOPmWr69U= github.com/jmhodges/levigo v1.0.0 h1:q5EC36kV79HWeTBWsod3mG11EgStG3qArTKcvlksN1U= github.com/jmhodges/levigo v1.0.0/go.mod h1:Q6Qx+uH3RAqyK4rFQroq9RL7mdkABMcfhEI+nNuzMJQ= github.com/jonboulle/clockwork v0.1.0/go.mod h1:Ii8DK3G1RaLaWxj9trq07+26W01tbo22gdxWY5EU2bo= github.com/jpillora/backoff v1.0.0/go.mod h1:J/6gKK9jxlEcS3zixgDgUAsiuZ7yrSoa/FX5e0EB2j4= github.com/json-iterator/go v1.1.6/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU= github.com/json-iterator/go v1.1.7/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= github.com/json-iterator/go v1.1.8/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= github.com/json-iterator/go v1.1.9/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= github.com/json-iterator/go v1.1.10/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= github.com/json-iterator/go v1.1.12 h1:PV8peI4a0ysnczrg+LtxykD8LfKY9ML6u2jnxaEnrnM= github.com/json-iterator/go v1.1.12/go.mod h1:e30LSqwooZae/UwlEbR2852Gd8hjQvJoHmT4TnhNGBo= github.com/jstemmer/go-junit-report v0.0.0-20190106144839-af01ea7f8024/go.mod h1:6v2b51hI/fHJwM22ozAgKL4VKDeJcHhJFhtBdhmNjmU= github.com/jstemmer/go-junit-report v0.9.1/go.mod h1:Brl9GWCQeLvo8nXZwPNNblvFj/XSXhF0NWZEnDohbsk= github.com/jtolds/gls v4.20.0+incompatible/go.mod h1:QJZ7F/aHp+rZTRtaJ1ow/lLfFfVYBRgL+9YlvaHOwJU= github.com/julienschmidt/httprouter v1.2.0/go.mod h1:SYymIcj16QtmaHHD7aYtjjsJG7VTCxuUUipMqKk8s4w= github.com/julienschmidt/httprouter v1.3.0/go.mod h1:JR6WtHb+2LUe8TCKY3cZOxFyyO8IZAc4RVcycCCAKdM= github.com/kisielk/errcheck v1.1.0/go.mod h1:EZBBE59ingxPouuu3KfxchcWSUPOHkagtvWXihfKN4Q= github.com/kisielk/errcheck v1.2.0/go.mod h1:/BMXB+zMLi60iA8Vv6Ksmxu/1UDYcXs4uQLJ+jE2L00= github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8= github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= github.com/klauspost/compress v1.10.3/go.mod h1:aoV0uJVorq1K+umq18yTdKaF57EivdYsUV+/s2qKfXs= github.com/klauspost/compress v1.11.7/go.mod h1:aoV0uJVorq1K+umq18yTdKaF57EivdYsUV+/s2qKfXs= github.com/klauspost/compress v1.15.11/go.mod h1:QPwzmACJjUTFsnSHH934V6woptycfrDDJnH7hvFVbGM= github.com/klauspost/compress v1.17.9 h1:6KIumPrER1LHsvBVuDa0r5xaG0Es51mhhB9BQB2qeMA= github.com/klauspost/compress v1.17.9/go.mod h1:Di0epgTjJY877eYKx5yC51cX2A2Vl2ibi7bDH9ttBbw= github.com/klauspost/cpuid/v2 v2.0.9 h1:lgaqFMSdTdQYdZ04uHyN2d/eKdOMyi2YLSvlQIBFYa4= github.com/klauspost/cpuid/v2 v2.0.9/go.mod h1:FInQzS24/EEf25PyTYn52gqo7WaD8xa0213Md/qVLRg= github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= github.com/konsorten/go-windows-terminal-sequences v1.0.3/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515/go.mod h1:+0opPa2QZZtGFBFZlji/RkVcI2GknAs/DXo4wKdlNEc= github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo= github.com/kr/pretty v0.2.1/go.mod h1:ipq/a2n7PKx3OHsz4KJII5eveXtPO4qwEXGdVfWzfnI= github.com/kr/pretty v0.3.0/go.mod h1:640gp4NfQd8pI5XOwp5fnNeVWj67G7CFk/SaSQn7NBk= github.com/kr/pretty v0.3.1 h1:flRD4NNwYAUpkphVc1HcthR4KEIFJ65n8Mw5qdRn3LE= github.com/kr/pretty v0.3.1/go.mod h1:hoEshYVHaxMs3cyo3Yncou5ZscifuDolrwPKZanG3xk= github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ= github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI= github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY= github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= github.com/kylelemons/godebug v1.1.0 h1:RPNrshWIDI6G2gRW9EHilWtl7Z6Sb1BR0xunSBf0SNc= github.com/kylelemons/godebug v1.1.0/go.mod h1:9/0rRGxNHcop5bhtWyNeEfOS8JIWk580+fNqagV/RAw= github.com/leodido/go-urn v1.2.1 h1:BqpAaACuzVSgi/VLzGZIobT2z4v53pjosyNd9Yv6n/w= github.com/leodido/go-urn v1.2.1/go.mod h1:zt4jvISO2HfUBqxjfIshjdMTYS56ZS/qv49ictyFfxY= github.com/lib/pq v1.10.9 h1:YXG7RB+JIjhP29X+OtkiDnYaXQwpS4JEWq7dtCCRUEw= github.com/lib/pq v1.10.9/go.mod h1:AlVN5x4E4T544tWzH6hKfbfQvm3HdbOxrmggDNAPY9o= github.com/lightstep/lightstep-tracer-common/golang/gogo v0.0.0-20190605223551-bc2310a04743/go.mod h1:qklhhLq1aX+mtWk9cPHPzaBjWImj5ULL6C7HFJtXQMM= github.com/lightstep/lightstep-tracer-go v0.18.1/go.mod h1:jlF1pusYV4pidLvZ+XD0UBX0ZE6WURAspgAczcDHrL4= github.com/linxGnu/grocksdb v1.9.3 h1:s1cbPcOd0cU2SKXRG1nEqCOWYAELQjdqg3RVI2MH9ik= github.com/linxGnu/grocksdb v1.9.3/go.mod h1:QYiYypR2d4v63Wj1adOOfzglnoII0gLj3PNh4fZkcFA= github.com/lyft/protoc-gen-validate v0.0.13/go.mod h1:XbGvPuh87YZc5TdIa2/I4pLk0QoUACkjt2znoq26NVQ= github.com/magiconair/properties v1.8.7 h1:IeQXZAiQcpL9mgcAe1Nu6cX9LLw6ExEHKjN0VQdvPDY= github.com/magiconair/properties v1.8.7/go.mod h1:Dhd985XPs7jluiymwWYZ0G4Z61jb3vdS329zhj2hYo0= github.com/manifoldco/promptui v0.9.0 h1:3V4HzJk1TtXW1MTZMP7mdlwbBpIinw3HztaIlYthEiA= github.com/manifoldco/promptui v0.9.0/go.mod h1:ka04sppxSGFAtxX0qhlYQjISsg9mR4GWtQEhdbn6Pgg= github.com/mattn/go-colorable v0.0.9/go.mod h1:9vuHe8Xs5qXnSaW/c/ABM9alt+Vo+STaOChaDxuIBZU= github.com/mattn/go-colorable v0.1.13 h1:fFA4WZxdEF4tXPZVKMLwD8oUnCTTo08duU7wxecdEvA= github.com/mattn/go-colorable v0.1.13/go.mod h1:7S9/ev0klgBDR4GtXTXX8a3vIGJpMovkB8vQcUbaXHg= github.com/mattn/go-isatty v0.0.3/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4= github.com/mattn/go-isatty v0.0.4/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4= github.com/mattn/go-isatty v0.0.16/go.mod h1:kYGgaQfpe5nmfYZH+SKPsOc2e4SrIfOl2e/yFXSvRLM= github.com/mattn/go-isatty v0.0.17/go.mod h1:kYGgaQfpe5nmfYZH+SKPsOc2e4SrIfOl2e/yFXSvRLM= github.com/mattn/go-isatty v0.0.19/go.mod h1:W+V8PltTTMOvKvAeJH7IuucS94S2C6jfK/D7dTCTo3Y= github.com/mattn/go-isatty v0.0.20 h1:xfD0iDuEKnDkl03q4limB+vH+GxLEtL/jb4xVJSWWEY= github.com/mattn/go-isatty v0.0.20/go.mod h1:W+V8PltTTMOvKvAeJH7IuucS94S2C6jfK/D7dTCTo3Y= github.com/mattn/go-runewidth v0.0.2/go.mod h1:LwmH8dsx7+W8Uxz3IHJYH5QSwggIsqBzpuz5H//U1FU= github.com/mattn/go-runewidth v0.0.4/go.mod h1:LwmH8dsx7+W8Uxz3IHJYH5QSwggIsqBzpuz5H//U1FU= github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0= github.com/miekg/dns v1.0.14/go.mod h1:W1PPwlIAgtquWBMBEV9nkV9Cazfe8ScdGz/Lj7v3Nrg= github.com/mimoo/StrobeGo v0.0.0-20181016162300-f8f6d4d2b643/go.mod h1:43+3pMjjKimDBf5Kr4ZFNGbLql1zKkbImw+fZbw3geM= github.com/mimoo/StrobeGo v0.0.0-20210601165009-122bf33a46e0 h1:QRUSJEgZn2Snx0EmT/QLXibWjSUDjKWvXIT19NBVp94= github.com/mimoo/StrobeGo v0.0.0-20210601165009-122bf33a46e0/go.mod h1:43+3pMjjKimDBf5Kr4ZFNGbLql1zKkbImw+fZbw3geM= github.com/minio/blake2b-simd v0.0.0-20160723061019-3f5f724cb5b1 h1:lYpkrQH5ajf0OXOcUbGjvZxxijuBwbbmlSxLiuofa+g= github.com/minio/blake2b-simd v0.0.0-20160723061019-3f5f724cb5b1/go.mod h1:pD8RvIylQ358TN4wwqatJ8rNavkEINozVn9DtGI3dfQ= github.com/minio/highwayhash v1.0.3 h1:kbnuUMoHYyVl7szWjSxJnxw11k2U709jqFPPmIUyD6Q= github.com/minio/highwayhash v1.0.3/go.mod h1:GGYsuwP/fPD6Y9hMiXuapVvlIUEhFhMTh0rxU3ik1LQ= github.com/minio/sha256-simd v0.1.1-0.20190913151208-6de447530771 h1:MHkK1uRtFbVqvAgvWxafZe54+5uBxLluGylDiKgdhwo= github.com/minio/sha256-simd v0.1.1-0.20190913151208-6de447530771/go.mod h1:B5e1o+1/KgNmWrSQK08Y6Z1Vb5pwIktudl0J58iy0KM= github.com/mitchellh/cli v1.0.0/go.mod h1:hNIlj7HEI86fIcpObd7a0FcrxTWetlwJDGcceTlRvqc= github.com/mitchellh/go-homedir v1.0.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0= github.com/mitchellh/go-homedir v1.1.0 h1:lukF9ziXFxDFPkA1vsr5zpc1XuPDn/wFntq5mG+4E0Y= github.com/mitchellh/go-homedir v1.1.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0= github.com/mitchellh/go-testing-interface v1.0.0/go.mod h1:kRemZodwjscx+RGhAo8eIhFbs2+BFgRtFPeD/KE+zxI= github.com/mitchellh/go-testing-interface v1.14.1 h1:jrgshOhYAUVNMAJiKbEu7EqAwgJJ2JqpQmpLJOu07cU= github.com/mitchellh/go-testing-interface v1.14.1/go.mod h1:gfgS7OtZj6MA4U1UrDRp04twqAjfvlZyCfX3sDjEym8= github.com/mitchellh/gox v0.4.0/go.mod h1:Sd9lOJ0+aimLBi73mGofS1ycjY8lL3uZM3JPS42BGNg= github.com/mitchellh/iochan v1.0.0/go.mod h1:JwYml1nuB7xOzsp52dPpHFffvOCDupsG0QubkSMEySY= github.com/mitchellh/mapstructure v0.0.0-20160808181253-ca63d7c062ee/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= github.com/mitchellh/mapstructure v1.5.0 h1:jeMsZIYE/09sWLaz43PL7Gy6RuMjD2eJVyuac5Z2hdY= github.com/mitchellh/mapstructure v1.5.0/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd h1:TRLaZ9cD/w8PVh93nsPXa1VrQ6jlwL5oN8l14QlcNfg= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= github.com/modern-go/reflect2 v0.0.0-20180701023420-4b7aa43c6742/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0= github.com/modern-go/reflect2 v1.0.1/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0= github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9Gz0M= github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk= github.com/mr-tron/base58 v1.1.0/go.mod h1:xcD2VGqlgYjBdcBLw+TuYLr8afG+Hj8g2eTVqeSzSU8= github.com/mr-tron/base58 v1.1.3 h1:v+sk57XuaCKGXpWtVBX8YJzO7hMGx4Aajh4TQbdEFdc= github.com/mr-tron/base58 v1.1.3/go.mod h1:BinMc/sQntlIE1frQmRFPUoPA1Zkr8VRgBdjWI2mNwc= github.com/mtibben/percent v0.2.1 h1:5gssi8Nqo8QU/r2pynCm+hBQHpkB/uNK7BJCFogWdzs= github.com/mtibben/percent v0.2.1/go.mod h1:KG9uO+SZkUp+VkRHsCdYQV3XSZrrSpR3O9ibNBTZrns= github.com/multiformats/go-base32 v0.0.3 h1:tw5+NhuwaOjJCC5Pp82QuXbrmLzWg7uxlMFp8Nq/kkI= github.com/multiformats/go-base32 v0.0.3/go.mod h1:pLiuGC8y0QR3Ue4Zug5UzK9LjgbkL8NSQj0zQ5Nz/AA= github.com/multiformats/go-base36 v0.1.0 h1:JR6TyF7JjGd3m6FbLU2cOxhC0Li8z8dLNGQ89tUg4F4= github.com/multiformats/go-base36 v0.1.0/go.mod h1:kFGE83c6s80PklsHO9sRn2NCoffoRdUUOENyW/Vv6sM= github.com/multiformats/go-multibase v0.0.3 h1:l/B6bJDQjvQ5G52jw4QGSYeOTZoAwIO77RblWplfIqk= github.com/multiformats/go-multibase v0.0.3/go.mod h1:5+1R4eQrT3PkYZ24C3W2Ue2tPwIdYQD509ZjSb5y9Oc= github.com/multiformats/go-multihash v0.0.13 h1:06x+mk/zj1FoMsgNejLpy6QTvJqlSt/BhLEy87zidlc= github.com/multiformats/go-multihash v0.0.13/go.mod h1:VdAWLKTwram9oKAatUcLxBNUjdtcVwxObEQBtRfuyjc= github.com/multiformats/go-varint v0.0.5 h1:XVZwSo04Cs3j/jS0uAEPpT3JY6DzMcVLLoWOSnCxOjg= github.com/multiformats/go-varint v0.0.5/go.mod h1:3Ls8CIEsrijN6+B7PbrXRPxHRPuXSrVKRY101jdMZYE= github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 h1:C3w9PqII01/Oq1c1nUAm88MOHcQC9l5mIlSMApZMrHA= github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822/go.mod h1:+n7T8mK8HuQTcFwEeznm/DIxMOiR9yIdICNftLE1DvQ= github.com/mwitkow/go-conntrack v0.0.0-20161129095857-cc309e4a2223/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= github.com/mwitkow/go-conntrack v0.0.0-20190716064945-2f068394615f h1:KUppIJq7/+SVif2QVs3tOP0zanoHgBEVAwHxUSIzRqU= github.com/mwitkow/go-conntrack v0.0.0-20190716064945-2f068394615f/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= github.com/mwitkow/grpc-proxy v0.0.0-20181017164139-0f1106ef9c76/go.mod h1:x5OoJHDHqxHS801UIuhqGl6QdSAEJvtausosHSdazIo= github.com/nats-io/jwt v0.3.0/go.mod h1:fRYCDE99xlTsqUzISS1Bi75UBJ6ljOJQOAAu5VglpSg= github.com/nats-io/jwt v0.3.2/go.mod h1:/euKqTS1ZD+zzjYrY7pseZrTtWQSjujC7xjPc8wL6eU= github.com/nats-io/nats-server/v2 v2.1.2/go.mod h1:Afk+wRZqkMQs/p45uXdrVLuab3gwv3Z8C4HTBu8GD/k= github.com/nats-io/nats.go v1.9.1/go.mod h1:ZjDU1L/7fJ09jvUSRVBR2e7+RnLiiIQyqyzEE/Zbp4w= github.com/nats-io/nkeys v0.1.0/go.mod h1:xpnFELMwJABBLVhffcfd1MZx6VsNRFpEugbxziKVo7w= github.com/nats-io/nkeys v0.1.3/go.mod h1:xpnFELMwJABBLVhffcfd1MZx6VsNRFpEugbxziKVo7w= github.com/nats-io/nuid v1.0.1/go.mod h1:19wcPz3Ph3q0Jbyiqsd0kePYG7A95tJPxeL+1OSON2c= github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e/go.mod h1:zD1mROLANZcx1PVRCS0qkT7pwLkGfwJo4zjcN/Tysno= github.com/nxadm/tail v1.4.4/go.mod h1:kenIhsEOeOJmVchQTgglprH7qJGnHDVpk1VPCcaMI8A= github.com/nxadm/tail v1.4.8 h1:nPr65rt6Y5JFSKQO7qToXr7pePgD6Gwiw05lkbyAQTE= github.com/nxadm/tail v1.4.8/go.mod h1:+ncqLTQzXmGhMZNUePPaPqPvBxHAIsmXswZKocGu+AU= github.com/oklog/oklog v0.3.2/go.mod h1:FCV+B7mhrz4o+ueLpx+KqkyXRGMWOYEvfiXtdGtbWGs= github.com/oklog/run v1.0.0/go.mod h1:dlhp/R75TPv97u0XWUtDeV/lRKWPKSdTuV0TZvrmrQA= github.com/olekukonko/tablewriter v0.0.0-20170122224234-a0225b3f23b5/go.mod h1:vsDQFd/mU46D+Z4whnwzcISnGGzXWMclvtLoiIKAKIo= github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= github.com/onsi/ginkgo v1.7.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= github.com/onsi/ginkgo v1.12.1/go.mod h1:zj2OWP4+oCPe1qIXoGWkgMRwljMUYCdkwsT2108oapk= github.com/onsi/ginkgo v1.14.0 h1:2mOpI4JVVPBN+WQRa0WKH2eXR+Ey+uK4n7Zj0aYpIQA= github.com/onsi/ginkgo v1.14.0/go.mod h1:iSB4RoI2tjJc9BBv4NKIKWKya62Rps+oPG/Lv9klQyY= github.com/onsi/gomega v1.4.3/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1CpauHY= github.com/onsi/gomega v1.7.1/go.mod h1:XdKZgCCFLUoM/7CFJVPcG8C1xQ1AJ0vpAezJrB7JYyY= github.com/onsi/gomega v1.10.1/go.mod h1:iN09h71vgCQne3DLsj+A5owkum+a2tYe+TOCB1ybHNo= github.com/onsi/gomega v1.20.0 h1:8W0cWlwFkflGPLltQvLRB7ZVD5HuP6ng320w2IS245Q= github.com/onsi/gomega v1.20.0/go.mod h1:DtrZpjmvpn2mPm4YWQa0/ALMDj9v4YxLgojwPeREyVo= github.com/op/go-logging v0.0.0-20160315200505-970db520ece7/go.mod h1:HzydrMdWErDVzsI23lYNej1Htcns9BCg93Dk0bBINWk= github.com/opencontainers/go-digest v1.0.0 h1:apOUWs51W5PlhuyGyz9FCeeBIOUDA/6nW8Oi/yOhh5U= github.com/opencontainers/go-digest v1.0.0/go.mod h1:0JzlMkj0TRzQZfJkVvzbP0HBR3IKzErnv2BNG4W4MAM= github.com/opencontainers/image-spec v1.0.2 h1:9yCKha/T5XdGtO0q9Q9a6T5NUCsTn/DrBg0D7ufOcFM= github.com/opencontainers/image-spec v1.0.2/go.mod h1:BtxoFyWECRxE4U/7sNtV5W15zMzWCbyJoFRP3s7yZA0= github.com/opencontainers/runc v1.1.12 h1:BOIssBaW1La0/qbNZHXOOa71dZfZEQOzW7dqQf3phss= github.com/opencontainers/runc v1.1.12/go.mod h1:S+lQwSfncpBha7XTy/5lBwWgm5+y5Ma/O44Ekby9FK8= github.com/opentracing-contrib/go-observer v0.0.0-20170622124052-a52f23424492/go.mod h1:Ngi6UdF0k5OKD5t5wlmGhe/EDKPoUM3BXZSSfIuJbis= github.com/opentracing/basictracer-go v1.0.0/go.mod h1:QfBfYuafItcjQuMwinw9GhYKwFXS9KnPs5lxoYwgW74= github.com/opentracing/opentracing-go v1.0.2/go.mod h1:UkNAQd3GIcIGf0SeVgPpRdFStlNbqXla1AfSYxPUl2o= github.com/opentracing/opentracing-go v1.1.0/go.mod h1:UkNAQd3GIcIGf0SeVgPpRdFStlNbqXla1AfSYxPUl2o= github.com/openzipkin-contrib/zipkin-go-opentracing v0.4.5/go.mod h1:/wsWhb9smxSfWAKL3wpBW7V8scJMt8N8gnaMCS9E/cA= github.com/openzipkin/zipkin-go v0.1.6/go.mod h1:QgAqvLzwWbR/WpD4A3cGpPtJrZXNIiJc5AZX7/PBEpw= github.com/openzipkin/zipkin-go v0.2.1/go.mod h1:NaW6tEwdmWMaCDZzg8sh+IBNOxHMPnhQw8ySjnjRyN4= github.com/openzipkin/zipkin-go v0.2.2/go.mod h1:NaW6tEwdmWMaCDZzg8sh+IBNOxHMPnhQw8ySjnjRyN4= github.com/ory/dockertest v3.3.5+incompatible h1:iLLK6SQwIhcbrG783Dghaaa3WPzGc+4Emza6EbVUUGA= github.com/ory/dockertest v3.3.5+incompatible/go.mod h1:1vX4m9wsvi00u5bseYwXaSnhNrne+V0E6LAcBILJdPs= github.com/pact-foundation/pact-go v1.0.4/go.mod h1:uExwJY4kCzNPcHRj+hCR/HBbOOIwwtUjcrb0b5/5kLM= github.com/pascaldekloe/goe v0.0.0-20180627143212-57f6aae5913c/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc= github.com/pascaldekloe/goe v0.1.0 h1:cBOtyMzM9HTpWjXfbbunk26uA6nG3a8n06Wieeh0MwY= github.com/pascaldekloe/goe v0.1.0/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc= github.com/pborman/uuid v1.2.0/go.mod h1:X/NO0urCmaxf9VXbdlT7C2Yzkj2IKimNn4k+gtPdI/k= github.com/pelletier/go-toml/v2 v2.0.6/go.mod h1:eumQOmlWiOPt5WriQQqoM5y18pDHwha2N+QD+EUNTek= github.com/pelletier/go-toml/v2 v2.2.2 h1:aYUidT7k73Pcl9nb2gScu7NSrKCSHIDE89b3+6Wq+LM= github.com/pelletier/go-toml/v2 v2.2.2/go.mod h1:1t835xjRzz80PqgE6HHgN2JOsmgYu/h4qDAS4n929Rs= github.com/performancecopilot/speed v3.0.0+incompatible/go.mod h1:/CLtqpZ5gBg1M9iaPbIdPPGyKcA8hKdoy6hAWba7Yac= github.com/petermattis/goid v0.0.0-20240813172612-4fcff4a6cae7 h1:Dx7Ovyv/SFnMFw3fD4oEoeorXc6saIiQ23LrGLth0Gw= github.com/petermattis/goid v0.0.0-20240813172612-4fcff4a6cae7/go.mod h1:pxMtw7cyUw6B2bRH0ZBANSPg+AoSud1I1iyJHI69jH4= github.com/pierrec/lz4 v1.0.2-0.20190131084431-473cd7ce01a1/go.mod h1:3/3N9NVKO0jef7pBehbT1qWhCMrIgbYNnFAZCqQ5LRc= github.com/pierrec/lz4 v2.0.5+incompatible/go.mod h1:pdkljMzZIN41W+lC3N2tnIh5sFi+IEE17M5jbnwPHcY= github.com/pingcap/errors v0.11.4 h1:lFuQV/oaUMGcD2tqt+01ROSmJs75VG1ToEOkZIZ4nE4= github.com/pingcap/errors v0.11.4/go.mod h1:Oi8TUi2kEtXXLMJk9l1cGmz20kV3TaQ0usTwv5KuLY8= github.com/pkg/diff v0.0.0-20210226163009-20ebb0f2a09e/go.mod h1:pJLUxLENpZxwdsKMEsNbx1VGcRFpLqf3715MtcvvzbA= github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/profile v1.2.1/go.mod h1:hJw3o1OdXxsrSjjVksARp5W95eeEaEfptyVZyv6JUPA= github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 h1:Jamvg5psRIccs7FGNTlIRMkT8wgtp5eCXdBlqhYGL6U= github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= github.com/posener/complete v1.1.1/go.mod h1:em0nMJCgc9GFtwrmVmEMR/ZL6WyhyjMBndrE9hABlRI= github.com/prometheus/client_golang v0.9.1/go.mod h1:7SWBe2y4D6OKWSNQJUaRYU/AaXPKyh/dDVn+NZz0KFw= github.com/prometheus/client_golang v0.9.3-0.20190127221311-3c4408c8b829/go.mod h1:p2iRAGwDERtqlqzRXnrOVns+ignqQo//hLXqYxZYVNs= github.com/prometheus/client_golang v1.0.0/go.mod h1:db9x61etRT2tGnBNRi70OPL5FsnadC4Ky3P0J6CfImo= github.com/prometheus/client_golang v1.3.0/go.mod h1:hJaj2vgQTGQmVCsAACORcieXFeDPbaTKGT+JTgUa3og= github.com/prometheus/client_golang v1.4.0/go.mod h1:e9GMxYsXl05ICDXkRhurwBS4Q3OK1iX/F2sw+iXX5zU= github.com/prometheus/client_golang v1.7.1/go.mod h1:PY5Wy2awLA44sXw4AOSfFBetzPP4j5+D6mVACh+pe2M= github.com/prometheus/client_golang v1.20.5 h1:cxppBPuYhUnsO6yo/aoRol4L7q7UFfdm+bR9r+8l63Y= github.com/prometheus/client_golang v1.20.5/go.mod h1:PIEt8X02hGcP8JWbeHyeZ53Y/jReSnHgO035n//V5WE= github.com/prometheus/client_model v0.0.0-20180712105110-5c3871d89910/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo= github.com/prometheus/client_model v0.0.0-20190115171406-56726106282f/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo= github.com/prometheus/client_model v0.0.0-20190129233127-fd36f4220a90/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= github.com/prometheus/client_model v0.0.0-20190812154241-14fe0d1b01d4/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= github.com/prometheus/client_model v0.1.0/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= github.com/prometheus/client_model v0.2.0/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= github.com/prometheus/client_model v0.6.1 h1:ZKSh/rekM+n3CeS952MLRAdFwIKqeY8b62p8ais2e9E= github.com/prometheus/client_model v0.6.1/go.mod h1:OrxVMOVHjw3lKMa8+x6HeMGkHMQyHDk9E3jmP2AmGiY= github.com/prometheus/common v0.2.0/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4= github.com/prometheus/common v0.4.1/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4= github.com/prometheus/common v0.7.0/go.mod h1:DjGbpBbp5NYNiECxcL/VnbXCCaQpKd3tt26CguLLsqA= github.com/prometheus/common v0.9.1/go.mod h1:yhUN8i9wzaXS3w1O07YhxHEBxD+W35wd8bs7vj7HSQ4= github.com/prometheus/common v0.10.0/go.mod h1:Tlit/dnDKsSWFlCLTWaA1cyBgKHSMdTB80sz/V91rCo= github.com/prometheus/common v0.15.0/go.mod h1:U+gB1OBLb1lF3O42bTCL+FK18tX9Oar16Clt/msog/s= github.com/prometheus/common v0.60.1 h1:FUas6GcOw66yB/73KC+BOZoFJmbo/1pojoILArPAaSc= github.com/prometheus/common v0.60.1/go.mod h1:h0LYf1R1deLSKtD4Vdg8gy4RuOvENW2J/h19V5NADQw= github.com/prometheus/procfs v0.0.0-20181005140218-185b4288413d/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk= github.com/prometheus/procfs v0.0.0-20190117184657-bf6a532e95b1/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk= github.com/prometheus/procfs v0.0.2/go.mod h1:TjEm7ze935MbeOT/UhFTIMYKhuLP4wbCsTZCD3I8kEA= github.com/prometheus/procfs v0.0.8/go.mod h1:7Qr8sr6344vo1JqZ6HhLceV9o3AJ1Ff+GxbHq6oeK9A= github.com/prometheus/procfs v0.1.3/go.mod h1:lV6e/gmhEcM9IjHGsFOCxxuZ+z1YqCvr4OA4YeYWdaU= github.com/prometheus/procfs v0.3.0/go.mod h1:lV6e/gmhEcM9IjHGsFOCxxuZ+z1YqCvr4OA4YeYWdaU= github.com/prometheus/procfs v0.15.1 h1:YagwOFzUgYfKKHX6Dr+sHT7km/hxC76UB0learggepc= github.com/prometheus/procfs v0.15.1/go.mod h1:fB45yRUv8NstnjriLhBQLuOUt+WW4BsoGhij/e3PBqk= github.com/rakyll/statik v0.1.7 h1:OF3QCZUuyPxuGEP7B4ypUa7sB/iHtqOTDYZXGM8KOdQ= github.com/rakyll/statik v0.1.7/go.mod h1:AlZONWzMtEnMs7W4e/1LURLiI49pIMmp6V9Unghqrcc= github.com/rcrowley/go-metrics v0.0.0-20181016184325-3113b8401b8a/go.mod h1:bCqnVzQkZxMG4s8nGwiZ5l3QUCyqpo9Y+/ZMZ9VjZe4= github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475 h1:N/ElC8H3+5XpJzTSTfLsJV/mx9Q9g7kxmchpfZyxgzM= github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475/go.mod h1:bCqnVzQkZxMG4s8nGwiZ5l3QUCyqpo9Y+/ZMZ9VjZe4= github.com/rogpeppe/fastuuid v0.0.0-20150106093220-6724a57986af/go.mod h1:XWv6SoW27p1b0cqNHllgS5HIMJraePCO15w5zCzIWYg= github.com/rogpeppe/fastuuid v1.2.0/go.mod h1:jVj6XXZzXRy/MSR5jhDC/2q6DgLz+nrA6LYCDYWNEvQ= github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4= github.com/rogpeppe/go-internal v1.6.1/go.mod h1:xXDCJY+GAPziupqXw64V24skbSoqbTEfhy4qGm1nDQc= github.com/rogpeppe/go-internal v1.8.0/go.mod h1:WmiCO8CzOY8rg0OYDC4/i/2WRWAB6poM+XZ2dLUbcbE= github.com/rogpeppe/go-internal v1.9.0/go.mod h1:WtVeX8xhTBvf0smdhujwtBcq4Qrzq/fJaraNFVN+nFs= github.com/rogpeppe/go-internal v1.11.0 h1:cWPaGQEPrBb5/AsnsZesgZZ9yb1OQ+GOISoDNXVBh4M= github.com/rogpeppe/go-internal v1.11.0/go.mod h1:ddIwULY96R17DhadqLgMfk9H9tvdUzkipdSkR5nkCZA= github.com/rs/cors v1.7.0/go.mod h1:gFx+x8UowdsKA9AchylcLynDq+nNFfI8FkUZdN/jGCU= github.com/rs/cors v1.11.1 h1:eU3gRzXLRK57F5rKMGMZURNdIG4EoAmX8k94r9wXWHA= github.com/rs/cors v1.11.1/go.mod h1:XyqrcTp5zjWr1wsJ8PIRZssZ8b/WMcMf71DJnit4EMU= github.com/rs/xid v1.5.0/go.mod h1:trrq9SKmegXys3aeAKXMUTdJsYXVwGY3RLcfgqegfbg= github.com/rs/zerolog v1.33.0 h1:1cU2KZkvPxNyfgEmhHAz/1A9Bz+llsdYzklWFzgp0r8= github.com/rs/zerolog v1.33.0/go.mod h1:/7mN4D5sKwJLZQ2b/znpjC3/GQWY/xaDXUM0kKWRHss= github.com/russross/blackfriday/v2 v2.0.1/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= github.com/ryanuber/columnize v0.0.0-20160712163229-9b3edd62028f/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts= github.com/sagikazarmark/locafero v0.4.0 h1:HApY1R9zGo4DBgr7dqsTH/JJxLTTsOt7u6keLGt6kNQ= github.com/sagikazarmark/locafero v0.4.0/go.mod h1:Pe1W6UlPYUk/+wc/6KFhbORCfqzgYEpgQ3O5fPuL3H4= github.com/sagikazarmark/slog-shim v0.1.0 h1:diDBnUNK9N/354PgrxMywXnAwEr1QZcOr6gto+ugjYE= github.com/sagikazarmark/slog-shim v0.1.0/go.mod h1:SrcSrq8aKtyuqEI1uvTDTK1arOWRIczQRv+GVI1AkeQ= github.com/samuel/go-zookeeper v0.0.0-20190923202752-2cc03de413da/go.mod h1:gi+0XIa01GRL2eRQVjQkKGqKF3SF9vZR/HnPullcV2E= github.com/sasha-s/go-deadlock v0.3.5 h1:tNCOEEDG6tBqrNDOX35j/7hL5FcFViG6awUGROb2NsU= github.com/sasha-s/go-deadlock v0.3.5/go.mod h1:bugP6EGbdGYObIlx7pUZtWqlvo8k9H6vCBBsiChJQ5U= github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529/go.mod h1:DxrIzT+xaE7yg65j358z/aeFdxmN0P9QXhEzd20vsDc= github.com/shurcooL/sanitized_anchor_name v1.0.0/go.mod h1:1NzhyTcUVG4SuEtjjoZeVRXNmyL/1OwPU0+IJeTBvfc= github.com/sirupsen/logrus v1.2.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo= github.com/sirupsen/logrus v1.4.2/go.mod h1:tLMulIdttU9McNUspp0xgXVQah82FyeX6MwdIuYE2rE= github.com/sirupsen/logrus v1.6.0/go.mod h1:7uNnSEd1DgxDLC74fIahvMZmmYsHGZGEOFrfsX/uA88= github.com/sirupsen/logrus v1.7.0/go.mod h1:yWOB1SBYBC5VeMP7gHvWumXLIWorT60ONWic61uBYv0= github.com/sirupsen/logrus v1.9.0 h1:trlNQbNUG3OdDrDil03MCb1H2o9nJ1x4/5LYw7byDE0= github.com/sirupsen/logrus v1.9.0/go.mod h1:naHLuLoDiP4jHNo9R0sCBMtWGeIprob74mVsIT4qYEQ= github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d/go.mod h1:OnSkiWE9lh6wB0YB77sQom3nweQdgAjqCqsofrRNTgc= github.com/smartystreets/goconvey v1.6.4/go.mod h1:syvi0/a8iFYH4r/RixwvyeAJjdLS9QV7WQ/tjFTllLA= github.com/soheilhy/cmux v0.1.4/go.mod h1:IM3LyeVVIOuxMH7sFAkER9+bJ4dT7Ms6E4xg4kGIyLM= github.com/sony/gobreaker v0.4.1/go.mod h1:ZKptC7FHNvhBz7dN2LGjPVBz2sZJmc0/PkyDJOjmxWY= github.com/sourcegraph/conc v0.3.0 h1:OQTbbt6P72L20UqAkXXuLOj79LfEanQ+YQFNpLA9ySo= github.com/sourcegraph/conc v0.3.0/go.mod h1:Sdozi7LEKbFPqYX2/J+iBAM6HpqSLTASQIKqDmF7Mt0= github.com/spaolacci/murmur3 v0.0.0-20180118202830-f09979ecbc72/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA= github.com/spaolacci/murmur3 v1.1.0 h1:7c1g84S4BPRrfL5Xrdp6fOJ206sU9y293DDHaoy0bLI= github.com/spaolacci/murmur3 v1.1.0/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA= github.com/spf13/afero v1.11.0 h1:WJQKhtpdm3v2IzqG8VMqrr6Rf3UYpEF239Jy9wNepM8= github.com/spf13/afero v1.11.0/go.mod h1:GH9Y3pIexgf1MTIWtNGyogA5MwRIDXGUr+hbWNoBjkY= github.com/spf13/cast v1.6.0 h1:GEiTHELF+vaR5dhz3VqZfFSzZjYbgeKDpBxQVS4GYJ0= github.com/spf13/cast v1.6.0/go.mod h1:ancEpBxwJDODSW/UG4rDrAqiKolqNNh2DX3mk86cAdo= github.com/spf13/cobra v0.0.3/go.mod h1:1l0Ry5zgKvJasoi3XT1TypsSe7PqH0Sj9dhYf7v3XqQ= github.com/spf13/cobra v1.8.1 h1:e5/vxKd/rZsfSJMUX1agtjeTDf+qv1/JdBF8gg5k9ZM= github.com/spf13/cobra v1.8.1/go.mod h1:wHxEcudfqmLYa8iTfL+OuZPbBZkmvliBWKIezN3kD9Y= github.com/spf13/pflag v1.0.1/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4= github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA= github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= github.com/spf13/viper v1.19.0 h1:RWq5SEjt8o25SROyN3z2OrDB9l7RPd3lwTWU8EcEdcI= github.com/spf13/viper v1.19.0/go.mod h1:GQUN9bilAbhU/jgc1bKs99f/suXKeUMct8Adx5+Ntkg= github.com/streadway/amqp v0.0.0-20190404075320-75d898a42a94/go.mod h1:AZpEONHx3DKn8O/DFsRAY58/XVQiIPMTMB1SddzLXVw= github.com/streadway/amqp v0.0.0-20190827072141-edfb9018d271/go.mod h1:AZpEONHx3DKn8O/DFsRAY58/XVQiIPMTMB1SddzLXVw= github.com/streadway/handy v0.0.0-20190108123426-d5acb3125c2a/go.mod h1:qNTQ5P5JnDBl6z3cMAg/SywNDC5ABu5ApDIw6lUbRmI= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSSt89Yw= github.com/stretchr/objx v0.5.0/go.mod h1:Yh+to48EsGEfYuaHDzXPcE3xhTkx73EhmCGUpEOglKo= github.com/stretchr/objx v0.5.2 h1:xuMeJ0Sdp5ZMRXx/aWO6RZxdr3beISkG5/G/aIRr3pY= github.com/stretchr/objx v0.5.2/go.mod h1:FRsXN1f5AsAjCGJKqEizvkpNtU+EGNCLh3NxZ/8L+MA= github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI= github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4= github.com/stretchr/testify v1.5.1/go.mod h1:5W2xD1RspED5o8YsWQXVCued0rvSQ+mT+I5cxcmMvtA= github.com/stretchr/testify v1.6.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU= github.com/stretchr/testify v1.8.1/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4= github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= github.com/stretchr/testify v1.9.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY= github.com/stretchr/testify v1.10.0 h1:Xv5erBjTwe/5IxqUQTdXv5kgmIvbHo3QQyRwhJsOfJA= github.com/stretchr/testify v1.10.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY= github.com/subosito/gotenv v1.6.0 h1:9NlTDc1FTs4qu0DDq7AEtTPNw6SVm7uBMsUCUjABIf8= github.com/subosito/gotenv v1.6.0/go.mod h1:Dk4QP5c2W3ibzajGcXpNraDfq2IrhjMIvMSWPKKo0FU= github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 h1:epCh84lMvA70Z7CTTCmYQn2CKbY8j86K7/FAIr141uY= github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7/go.mod h1:q4W45IWZaF22tdD+VEXcAWRA037jwmWEB5VWYORlTpc= github.com/tendermint/go-amino v0.16.0 h1:GyhmgQKvqF82e2oZeuMSp9JTN0N09emoSZlb2lyGa2E= github.com/tendermint/go-amino v0.16.0/go.mod h1:TQU0M1i/ImAo+tYpZi73AU3V/dKeCoMC9Sphe2ZwGME= github.com/tidwall/btree v1.6.0 h1:LDZfKfQIBHGHWSwckhXI0RPSXzlo+KYdjK7FWSqOzzg= github.com/tidwall/btree v1.6.0/go.mod h1:twD9XRA5jj9VUQGELzDO4HPQTNJsoWWfYEL+EUQ2cKY= github.com/tmc/grpc-websocket-proxy v0.0.0-20170815181823-89b8d40f7ca8/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U= github.com/tv42/httpunix v0.0.0-20150427012821-b75d8614f926/go.mod h1:9ESjWnEqriFuLhtthL60Sar/7RFoluCcXsuvEwTV5KM= github.com/twitchyliquid64/golang-asm v0.15.1 h1:SU5vSMR7hnwNxj24w34ZyCi/FmDZTkS4MhqMhdFk5YI= github.com/twitchyliquid64/golang-asm v0.15.1/go.mod h1:a1lVb/DtPvCB8fslRZhAngC2+aY1QWCk3Cedj/Gdt08= github.com/ugorji/go/codec v1.2.9 h1:rmenucSohSTiyL09Y+l2OCk+FrMxGMzho2+tjr5ticU= github.com/ugorji/go/codec v1.2.9/go.mod h1:UNopzCgEMSXjBc6AOMqYvWC1ktqTAfzJZUZgYf6w6lg= github.com/ulikunitz/xz v0.5.10/go.mod h1:nbz6k7qbPmH4IRqmfOplQw/tblSgqTqBwxkY0oWt/14= github.com/ulikunitz/xz v0.5.11 h1:kpFauv27b6ynzBNT/Xy+1k+fK4WswhN/6PN5WhFAGw8= github.com/ulikunitz/xz v0.5.11/go.mod h1:nbz6k7qbPmH4IRqmfOplQw/tblSgqTqBwxkY0oWt/14= github.com/urfave/cli v1.20.0/go.mod h1:70zkFmudgCuE/ngEzBv17Jvp/497gISqfk5gWijbERA= github.com/urfave/cli v1.22.1/go.mod h1:Gos4lmkARVdJ6EkW0WaNv/tZAAMe9V7XWyB60NtXRu0= github.com/xiang90/probing v0.0.0-20190116061207-43a291ad63a2/go.mod h1:UETIi67q53MR2AWcXfiuqkDkRtnGDLqkBTpCHuJHxtU= github.com/yuin/goldmark v1.1.25/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.1.32/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.3.5/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k= github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY= github.com/zondax/hid v0.9.2 h1:WCJFnEDMiqGF64nlZz28E9qLVZ0KSJ7xpc5DLEyma2U= github.com/zondax/hid v0.9.2/go.mod h1:l5wttcP0jwtdLjqjMMWFVEE7d1zO0jvSPA9OPZxWpEM= github.com/zondax/ledger-go v0.14.3 h1:wEpJt2CEcBJ428md/5MgSLsXLBos98sBOyxNmCjfUCw= github.com/zondax/ledger-go v0.14.3/go.mod h1:IKKaoxupuB43g4NxeQmbLXv7T9AlQyie1UpHb342ycI= go.etcd.io/bbolt v1.3.3/go.mod h1:IbVyRI1SCnLcuJnV2u8VeU0CEYM7e686BmAb1XKL+uU= go.etcd.io/bbolt v1.4.0-alpha.0.0.20240404170359-43604f3112c5 h1:qxen9oVGzDdIRP6ejyAJc760RwW4SnVDiTYTzwnXuxo= go.etcd.io/bbolt v1.4.0-alpha.0.0.20240404170359-43604f3112c5/go.mod h1:eW0HG9/oHQhvRCvb1/pIXW4cOvtDqeQK+XSi3TnwaXY= go.etcd.io/etcd v0.0.0-20191023171146-3cf2f69b5738/go.mod h1:dnLIgRNXwCJa5e+c6mIZCrds/GIG4ncV9HhK5PX7jPg= go.opencensus.io v0.20.1/go.mod h1:6WKK9ahsWS3RSO+PY9ZHZUfv2irvY6gN279GOPZjmmk= go.opencensus.io v0.20.2/go.mod h1:6WKK9ahsWS3RSO+PY9ZHZUfv2irvY6gN279GOPZjmmk= go.opencensus.io v0.21.0/go.mod h1:mSImk1erAIZhrmZN+AvHh14ztQfjbGwt4TtuofqLduU= go.opencensus.io v0.22.0/go.mod h1:+kGneAE2xo2IficOXnaByMWTGM9T73dGwxeWcUqIpI8= go.opencensus.io v0.22.2/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= go.opencensus.io v0.22.3/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= go.opencensus.io v0.22.4/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= go.opencensus.io v0.22.5/go.mod h1:5pWMHQbX5EPX2/62yrJeAkowc+lfs/XD7Uxpq3pI6kk= go.opencensus.io v0.23.0/go.mod h1:XItmlyltB5F7CS4xOC1DcqMoFqwtC6OG2xF7mCv7P7E= go.opencensus.io v0.24.0 h1:y73uSU6J157QMP2kn2r30vwW1A2W2WFwSCGnAVxeaD0= go.opencensus.io v0.24.0/go.mod h1:vNK8G9p7aAivkbmorf4v+7Hgx+Zs0yY+0fOtgBfjQKo= go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.49.0 h1:4Pp6oUg3+e/6M4C0A/3kJ2VYa++dsWVTtGgLVj5xtHg= go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.49.0/go.mod h1:Mjt1i1INqiaoZOMGR1RIUJN+i3ChKoFRqzrRQhlkbs0= go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.49.0 h1:jq9TW8u3so/bN+JPT166wjOI6/vQPF6Xe7nMNIltagk= go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.49.0/go.mod h1:p8pYQP+m5XfbZm9fxtSKAbM6oIllS7s2AfxrChvc7iw= go.opentelemetry.io/otel v1.24.0 h1:0LAOdjNmQeSTzGBzduGe/rU4tZhMwL5rWgtp9Ku5Jfo= go.opentelemetry.io/otel v1.24.0/go.mod h1:W7b9Ozg4nkF5tWI5zsXkaKKDjdVjpD4oAt9Qi/MArHo= go.opentelemetry.io/otel/metric v1.24.0 h1:6EhoGWWK28x1fbpA4tYTOWBkPefTDQnb8WSGXlc88kI= go.opentelemetry.io/otel/metric v1.24.0/go.mod h1:VYhLe1rFfxuTXLgj4CBiyz+9WYBA8pNGJgDcSFRKBco= go.opentelemetry.io/otel/sdk v1.22.0 h1:6coWHw9xw7EfClIC/+O31R8IY3/+EiRFHevmHafB2Gw= go.opentelemetry.io/otel/sdk v1.22.0/go.mod h1:iu7luyVGYovrRpe2fmj3CVKouQNdTOkxtLzPvPz1DOc= go.opentelemetry.io/otel/trace v1.24.0 h1:CsKnnL4dUAr/0llH9FKuc698G04IrpWV0MQA/Y1YELI= go.opentelemetry.io/otel/trace v1.24.0/go.mod h1:HPc3Xr/cOApsBI154IU0OI0HJexz+aw5uPdbs3UCjNU= go.opentelemetry.io/proto/otlp v0.7.0/go.mod h1:PqfVotwruBrMGOCsRd/89rSnXhoiJIqeYNgFYFoEGnI= go.uber.org/atomic v1.3.2/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= go.uber.org/atomic v1.5.0/go.mod h1:sABNBOSYdrvTF6hTgEIbc7YasKWGhgEQZyfxyTvoXHQ= go.uber.org/mock v0.4.0 h1:VcM4ZOtdbR4f6VXfiOpwpVJDL6lCReaZ6mw31wqh7KU= go.uber.org/mock v0.4.0/go.mod h1:a6FSlNadKUHUa9IP5Vyt1zh4fC7uAwxMutEAscFbkZc= go.uber.org/multierr v1.1.0/go.mod h1:wR5kodmAFQ0UK8QlbwjlSNy0Z68gJhDJUG5sjR94q/0= go.uber.org/multierr v1.3.0/go.mod h1:VgVr7evmIr6uPjLBxg28wmKNXyqE9akIJ5XnfpiKl+4= go.uber.org/multierr v1.10.0 h1:S0h4aNzvfcFsC3dRF1jLoaov7oRaKqRGC/pUEJ2yvPQ= go.uber.org/multierr v1.10.0/go.mod h1:20+QtiLqy0Nd6FdQB9TLXag12DsQkrbs3htMFfDN80Y= go.uber.org/tools v0.0.0-20190618225709-2cfd321de3ee/go.mod h1:vJERXedbb3MVM5f9Ejo0C68/HhF8uaILCdgjnY+goOA= go.uber.org/zap v1.10.0/go.mod h1:vwi/ZaCAaUcBkycHslxD9B2zi4UTXhF60s6SWpuDF0Q= go.uber.org/zap v1.13.0/go.mod h1:zwrFLgMcdUuIBviXEYEH1YKNaOBnKXsx2IPda5bBwHM= golang.org/x/arch v0.0.0-20210923205945-b76863e36670 h1:18EFjUmQOcUvxNYSkA6jO9VAiXCnxFY6NyDX0bHDmkU= golang.org/x/arch v0.0.0-20210923205945-b76863e36670/go.mod h1:5om86z9Hs0C8fWVUuoMHwpExlXzs5Tkyp9hOrfG7pp8= golang.org/x/crypto v0.0.0-20180904163835-0709b304e793/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= golang.org/x/crypto v0.0.0-20181029021203-45a5f77698d3/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/crypto v0.0.0-20190510104115-cbcb75029529/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20190605123033-f99c8df09eb5/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20190611184440-5c40567a22f8/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20200728195943-123391ffb6de/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.1.0/go.mod h1:RecgLatLF4+eUMCP1PoPZQb+cVrJcOPbHkTkbkB9sbw= golang.org/x/crypto v0.5.0/go.mod h1:NK/OQwhpMQP3MwtdjgLlYHnH9ebylxKWv3e0fK+mkQU= golang.org/x/crypto v0.31.0 h1:ihbySMvVjLAeSH1IbfcRTkD/iNscyz8rGzjF/E5hV6U= golang.org/x/crypto v0.31.0/go.mod h1:kDsLvtWBEx7MV9tJOj9bnXsPbxwJQ6csT/x4KIN4Ssk= golang.org/x/exp v0.0.0-20230711153332-06a737ee72cb h1:xIApU0ow1zwMa2uL1VDNeQlNVFTWMQxZUZCMDy0Q4Us= golang.org/x/exp v0.0.0-20230711153332-06a737ee72cb/go.mod h1:FXUEEKJgO7OQYeo8N01OfiKP8RXMtf6e8aTskBGqWdc= golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE= golang.org/x/lint v0.0.0-20190227174305-5b3e6a55c961/go.mod h1:wehouNa3lNwaWXcvxsM5YxQ5yQlVC4a0KAMCusXpPoU= golang.org/x/lint v0.0.0-20190301231843-5614ed5bae6f/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE= golang.org/x/lint v0.0.0-20190313153728-d0100b6bd8b3/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= golang.org/x/lint v0.0.0-20190409202823-959b441ac422/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= golang.org/x/lint v0.0.0-20190909230951-414d861bb4ac/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= golang.org/x/lint v0.0.0-20190930215403-16217165b5de/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= golang.org/x/lint v0.0.0-20191125180803-fdd1cda4f05f/go.mod h1:5qLYkcX4OjUUV8bRuDixDT3tpyyb+LUpUlRWLxfhWrs= golang.org/x/lint v0.0.0-20200130185559-910be7a94367/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY= golang.org/x/lint v0.0.0-20200302205851-738671d3881b/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY= golang.org/x/lint v0.0.0-20201208152925-83fdc39ff7b5/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY= golang.org/x/lint v0.0.0-20210508222113-6edffad5e616/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY= golang.org/x/mod v0.0.0-20190513183733-4bf6d317e70e/go.mod h1:mXi4GBBbnImb6dmsKGUJ2LatrhH/nqhxcFungHvyanc= golang.org/x/mod v0.1.1-0.20191105210325-c90efee705ee/go.mod h1:QqPTAvyqsEbceGzBzNggFXnrqF1CaUcvgkdR5Ot7KZg= golang.org/x/mod v0.2.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.1/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.2/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4/go.mod h1:jJ57K6gSWd91VN4djpZkiMVwK6gcyfeH4XE8wZrZaV4= golang.org/x/mod v0.6.0/go.mod h1:4mET923SAdbXp2ki8ey+zGs1SLqsuM2Y0uvdZR/fUNI= golang.org/x/mod v0.11.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= golang.org/x/mod v0.19.0 h1:fEdghXQSo20giMthA7cd28ZC+jts4amQ3YMXiP5oMQ8= golang.org/x/mod v0.19.0/go.mod h1:hTbmBsO62+eylJbnUtE2MGJUyE7QWk4xUqPFrRgJ+7c= golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20180906233101-161cd47e91fd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20181023162649-9b4f9f5ad519/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20181114220301-adae6a3d119a/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20181201002055-351d144fa1fc/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20181220203305-927f97764cc3/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20190108225652-1e06a53dbb7e/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20190125091013-d26f9f9a57f3/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20190213061140-3a22650c66bd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20190311183353-d8887717615a/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190501004415-9ce7a6920f09/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190503192946-f4e77d36d62c/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190603091049-60506f45cf65/go.mod h1:HSz+uSET+XFnRR8LxR5pz3Of3rY3CfYBVs4xY44aLks= golang.org/x/net v0.0.0-20190613194153-d28f0bde5980/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20190628185345-da137c7871d7/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20190724013045-ca1201d0de80/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20190813141303-74dc4d7220e7/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20191209160850-c0dbc17a3553/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20200114155413-6afb5195e5aa/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20200202094626-16171245cfb2/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20200222125558-5a598a2470a0/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20200226121028-0de0cce0169b/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20200301022130-244492dfa37a/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20200324143707-d3edc9973b7e/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A= golang.org/x/net v0.0.0-20200421231249-e086a090c8fd/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A= golang.org/x/net v0.0.0-20200501053045-e0ff5e5a1de5/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A= golang.org/x/net v0.0.0-20200506145744-7e3656a0809f/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A= golang.org/x/net v0.0.0-20200513185701-a91f0712d120/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A= golang.org/x/net v0.0.0-20200520004742-59133d7f0dd7/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A= golang.org/x/net v0.0.0-20200520182314-0ba52f642ac2/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A= golang.org/x/net v0.0.0-20200625001655-4c5254603344/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA= golang.org/x/net v0.0.0-20200707034311-ab3426394381/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA= golang.org/x/net v0.0.0-20200813134508-3edf25e44fcc/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA= golang.org/x/net v0.0.0-20200822124328-c89045814202/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA= golang.org/x/net v0.0.0-20201021035429-f5854403a974/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= golang.org/x/net v0.0.0-20201031054903-ff519b6c9102/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= golang.org/x/net v0.0.0-20201110031124-69a78807bb2b/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= golang.org/x/net v0.0.0-20201209123823-ac852fbbde11/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= golang.org/x/net v0.0.0-20210119194325-5f4716e94777/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= golang.org/x/net v0.0.0-20210316092652-d523dce5a7f4/go.mod h1:RBQZq4jEuRlivfhVLdyRGr576XBO4/greRjx4P4O3yc= golang.org/x/net v0.0.0-20210405180319-a5a99cb37ef4/go.mod h1:p54w0d4576C0XHj96bSt6lcn1PtDYWL6XObtHCRCNQM= golang.org/x/net v0.0.0-20210503060351-7fd8e65b6420/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= golang.org/x/net v0.0.0-20210805182204-aaa1db679c0d/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= golang.org/x/net v0.0.0-20220127200216-cd36cc0744dd/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= golang.org/x/net v0.0.0-20220225172249-27dd8689420f/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= golang.org/x/net v0.0.0-20220325170049-de3da57026de/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= golang.org/x/net v0.0.0-20220412020605-290c469a71a5/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= golang.org/x/net v0.0.0-20220425223048-2871e0cb64e4/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= golang.org/x/net v0.0.0-20220607020251-c690dde0001d/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= golang.org/x/net v0.0.0-20220617184016-355a448f1bc9/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= golang.org/x/net v0.0.0-20220624214902-1bab6f366d9e/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= golang.org/x/net v0.0.0-20220909164309-bea034e7d591/go.mod h1:YDH+HFinaLZZlnHAfSS6ZXJJ9M9t4Dl22yv3iI2vPwk= golang.org/x/net v0.0.0-20221014081412-f15817d10f9b/go.mod h1:YDH+HFinaLZZlnHAfSS6ZXJJ9M9t4Dl22yv3iI2vPwk= golang.org/x/net v0.1.0/go.mod h1:Cx3nUiGt4eDBEyega/BKRp+/AlGL8hYe7U9odMt2Cco= golang.org/x/net v0.5.0/go.mod h1:DivGGAXEgPSlEBzxGzZI+ZLohi+xUj054jfeKui00ws= golang.org/x/net v0.7.0/go.mod h1:2Tu9+aMcznHK/AK1HMvgo6xiTLG5rD5rZLDS+rp2Bjs= golang.org/x/net v0.33.0 h1:74SYHlV8BIgHIFC/LrYkOGIwL19eTYXQ5wc6TBuO36I= golang.org/x/net v0.33.0/go.mod h1:HXLR5J+9DxmrqMwG9qjGCxZ+zKXxBru04zlTvWlWuN4= golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= golang.org/x/oauth2 v0.0.0-20191202225959-858c2ad4c8b6/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= golang.org/x/oauth2 v0.0.0-20200107190931-bf48bf16ab8d/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= golang.org/x/oauth2 v0.0.0-20200902213428-5d25da1a8d43/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= golang.org/x/oauth2 v0.0.0-20201109201403-9fd604954f58/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= golang.org/x/oauth2 v0.0.0-20201208152858-08078c50e5b5/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= golang.org/x/oauth2 v0.0.0-20210218202405-ba52d332ba99/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= golang.org/x/oauth2 v0.0.0-20210220000619-9bb904979d93/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= golang.org/x/oauth2 v0.0.0-20210313182246-cd4f82c27b84/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= golang.org/x/oauth2 v0.0.0-20210514164344-f6687ab2804c/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= golang.org/x/oauth2 v0.0.0-20210628180205-a41e5a781914/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= golang.org/x/oauth2 v0.0.0-20210805134026-6f1e6394065a/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= golang.org/x/oauth2 v0.0.0-20210819190943-2bc19b11175f/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= golang.org/x/oauth2 v0.0.0-20211104180415-d3ed0bb246c8/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= golang.org/x/oauth2 v0.0.0-20220223155221-ee480838109b/go.mod h1:DAh4E804XQdzx2j+YRIaUnCqCV2RuMz24cGBJ5QYIrc= golang.org/x/oauth2 v0.0.0-20220309155454-6242fa91716a/go.mod h1:DAh4E804XQdzx2j+YRIaUnCqCV2RuMz24cGBJ5QYIrc= golang.org/x/oauth2 v0.0.0-20220411215720-9780585627b5/go.mod h1:DAh4E804XQdzx2j+YRIaUnCqCV2RuMz24cGBJ5QYIrc= golang.org/x/oauth2 v0.0.0-20220608161450-d0670ef3b1eb/go.mod h1:jaDAt6Dkxork7LmZnYtzbRWj0W47D86a3TGe0YHBvmE= golang.org/x/oauth2 v0.0.0-20220622183110-fd043fe589d2/go.mod h1:jaDAt6Dkxork7LmZnYtzbRWj0W47D86a3TGe0YHBvmE= golang.org/x/oauth2 v0.0.0-20220822191816-0ebed06d0094/go.mod h1:h4gKUeWbJ4rQPri7E0u6Gs4e9Ri2zaLxzw5DI5XGrYg= golang.org/x/oauth2 v0.0.0-20220909003341-f21342109be1/go.mod h1:h4gKUeWbJ4rQPri7E0u6Gs4e9Ri2zaLxzw5DI5XGrYg= golang.org/x/oauth2 v0.0.0-20221014153046-6fdb5e3db783/go.mod h1:h4gKUeWbJ4rQPri7E0u6Gs4e9Ri2zaLxzw5DI5XGrYg= golang.org/x/oauth2 v0.1.0/go.mod h1:G9FE4dLTsbXUu90h/Pf85g4w1D+SSAgR+q46nJZ8M4A= golang.org/x/oauth2 v0.23.0 h1:PbgcYx2W7i4LvjJWEbf0ngHV6qJYr86PkAV3bXdLEbs= golang.org/x/oauth2 v0.23.0/go.mod h1:XYTD2NtWslqkgxebSiOHnXEap4TF09sJSc7H1sXbhtI= golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20190227155943-e225da77a7e6/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20200317015054-43a5402ce75a/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20200625203802-6e8e738ad208/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20201207232520-09787c993a3a/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20220601150217-0de741cfad7f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20220929204114-8fcdb60fdcc0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.10.0 h1:3NQrjDixjgGwUOCaF8w2+VYHv0Ve/vGYSbdkTa98gmQ= golang.org/x/sync v0.10.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= golang.org/x/sys v0.0.0-20180823144017-11551d06cbcc/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20181026203630-95b1ffbd15a5/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20181107165924-66b7b1311ac8/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20181116152217-5ac8a444bdc5/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20181122145206-62eef0e2fa9b/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190422165155-953cdadca894/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190502145724-3ef323f4f1fd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190507160741-ecd444e8653b/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190606165138-5da285871e9c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190624142023-c5567b49c5d0/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190726091711-fc99dfbffb4e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190826190057-c7b8b68b1456/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190904154756-749cb33beabd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191005200804-aed5e4c7ecf9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191026070338-33540a1f6037/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191120155948-bd437916bb0e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191204072324-ce4227a45e2e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191220142924-d4481acd189f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191228213918-04cbcbbfeed8/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200106162015-b016eb3dc98e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200113162924-86b910548bc1/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200122134326-e047566fdf82/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200202164722-d101bd2416d5/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200212091648-12a6c2dcc1e4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200223170610-d5e6a3e2c0ae/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200302150141-5c8b2ff67527/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200323222414-85ca7c5b95cd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200331124033-c3d80250170d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200420163511-1957bb5e6d1f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200501052902-10377860bb8e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200511232937-7e40ca221e25/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200515095857-1151b9dac4a9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200519105757-fe76b779f299/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200523222454-059865788121/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200615200032-f1bc736245b1/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200625212154-ddb9806d33ae/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200803210538-64077c9b5642/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200814200057-3d37ad5750ed/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200905004654-be1d3432aa8f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20201201145000-ef89a241ccb3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210104204734-6f8348627aad/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210119212857-b64e53b001e4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210220050731-9a76102bfb43/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210305230114-8fe3ee5dd75b/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210315160823-c6e025ad8005/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210320140829-1e4c9ba3b0c4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210330210617-4fbd30eecc44/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210514084401-e8d321eab015/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210603125802-9665404d3644/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210616094352-59db8d763f22/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210806184541-e5e7981a1069/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210809222454-d867a43fc93e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210819135213-f52c844e1c1c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210823070655-63515b42dcdf/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210908233432-aa78b53d3365/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211124211545-fe61309f8881/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211210111614-af8b64212486/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220128215802-99c3d69c2c27/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220209214540-3681064d5158/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220227234510-4e6760a101f9/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220310020820-b874c991c1a5/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220315194320-039c03cc5b86/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220328115105-d36c6a25d886/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220412211240-33da011f77ad/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220502124256-b6088ccd6cba/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220503163025-988cb79eb6c6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220610221304-9f5ed59c137d/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220615213510-4f61da869c0c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220624220833-87e55d714810/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220728004956-3c1f35247d10/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20221010170243-090e33056c14/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.1.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.4.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.12.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.21.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/sys v0.28.0 h1:Fksou7UEQUWlKvIdsqzJmUmCX3cZuD2+P3XyyzwMhlA= golang.org/x/sys v0.28.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= golang.org/x/term v0.1.0/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= golang.org/x/term v0.4.0/go.mod h1:9P2UbLfCdcvo3p/nzKvsmas4TnlujnuoV9hGgYzW1lQ= golang.org/x/term v0.5.0/go.mod h1:jMB1sMXY+tzblOD4FWmEbocvup2/aLOaQEp7JmGp78k= golang.org/x/term v0.27.0 h1:WP60Sv1nlK1T6SupCHbXzSaN0b9wUmsPoRS9b61A23Q= golang.org/x/term v0.27.0/go.mod h1:iMsnZpn0cago0GOrHO2+Y7u7JPn5AylBrcoWkElMTSM= golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.4/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.5/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ= golang.org/x/text v0.3.8/go.mod h1:E6s5w1FMmriuDzIBO73fBruAKo1PCIq6d2Q6DHfQ8WQ= golang.org/x/text v0.4.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= golang.org/x/text v0.6.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= golang.org/x/text v0.7.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= golang.org/x/text v0.21.0 h1:zyQAAkrwaneQ066sspRyJaG9VNi/YJ1NfzcGB3hZ/qo= golang.org/x/text v0.21.0/go.mod h1:4IBbMaMmOPCJ8SecivzSH54+73PCFmPWxNTLm+vZkEQ= golang.org/x/time v0.0.0-20180412165947-fbb02b2291d2/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20191024005414-555d28b269f0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.5.0 h1:o7cqy6amK/52YcAKIPlM3a+Fpj35zvRj2TP+e1xFSfk= golang.org/x/time v0.5.0/go.mod h1:3BpzKBy/shNhVucY/MWOyx10tF3SFh9QdLuxbVysPQM= golang.org/x/tools v0.0.0-20180221164845-07fd8470d635/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20180828015842-6cd1fcedba52/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20181030221726-6c7e314b6563/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190114222345-bf090417da8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190226205152-f727befe758c/go.mod h1:9Yl7xja0Znq3iFh3HoIrodX9oNMXvdceNzlUR8zjMvY= golang.org/x/tools v0.0.0-20190311212946-11955173bddd/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= golang.org/x/tools v0.0.0-20190312170243-e65039ee4138/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= golang.org/x/tools v0.0.0-20190328211700-ab21143f2384/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= golang.org/x/tools v0.0.0-20190425150028-36563e24a262/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= golang.org/x/tools v0.0.0-20190506145303-2d16b83fe98c/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= golang.org/x/tools v0.0.0-20190524140312-2c0ae7006135/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= golang.org/x/tools v0.0.0-20190606124116-d0a3d012864b/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= golang.org/x/tools v0.0.0-20190621195816-6e04913cbbac/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= golang.org/x/tools v0.0.0-20190628153133-6cdbf07be9d0/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= golang.org/x/tools v0.0.0-20190911174233-4f2ddba30aff/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191029041327-9cc4af7d6b2c/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191029190741-b9c20aec41a5/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191113191852-77e3bb0ad9e7/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191115202509-3a792d9c32b2/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191125144606-a911d9008d1f/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191130070609-6e064ea0cf2d/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191216173652-a0e659d51361/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20191227053925-7b8e75db28f4/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20200103221440-774c71fcf114/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20200117161641-43d50277825c/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20200122220014-bf1340f18c4a/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20200130002326-2f3ba24bd6e7/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20200204074204-1cc6d1ef6c74/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20200212150539-ea181f53ac56/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20200224181240-023911ca70b2/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20200227222343-706bc42d1f0d/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= golang.org/x/tools v0.0.0-20200304193943-95d2e580d8eb/go.mod h1:o4KQGtdN14AW+yjsvvwRTJJuXz8XRtIHtEnmAXLyFUw= golang.org/x/tools v0.0.0-20200312045724-11d5b4c81c7d/go.mod h1:o4KQGtdN14AW+yjsvvwRTJJuXz8XRtIHtEnmAXLyFUw= golang.org/x/tools v0.0.0-20200331025713-a30bf2db82d4/go.mod h1:Sl4aGygMT6LrqrWclx+PTx3U+LnKx/seiNR+3G19Ar8= golang.org/x/tools v0.0.0-20200501065659-ab2804fb9c9d/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= golang.org/x/tools v0.0.0-20200512131952-2bc93b1c0c88/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= golang.org/x/tools v0.0.0-20200515010526-7d3b6ebf133d/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= golang.org/x/tools v0.0.0-20200618134242-20370b0cb4b2/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= golang.org/x/tools v0.0.0-20200619180055-7c47624df98f/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= golang.org/x/tools v0.0.0-20200729194436-6467de6f59a7/go.mod h1:njjCfa9FT2d7l9Bc6FUM5FLjQPp3cFF28FI3qnDFljA= golang.org/x/tools v0.0.0-20200804011535-6c149bb5ef0d/go.mod h1:njjCfa9FT2d7l9Bc6FUM5FLjQPp3cFF28FI3qnDFljA= golang.org/x/tools v0.0.0-20200825202427-b303f430e36d/go.mod h1:njjCfa9FT2d7l9Bc6FUM5FLjQPp3cFF28FI3qnDFljA= golang.org/x/tools v0.0.0-20200904185747-39188db58858/go.mod h1:Cj7w3i3Rnn0Xh82ur9kSqwfTHTeVxaDqrfMjpcNT6bE= golang.org/x/tools v0.0.0-20201110124207-079ba7bd75cd/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.0.0-20201201161351-ac6f37ff4c2a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.0.0-20201208233053-a543418bbed2/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.0.0-20210105154028-b0ab187a4818/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.1.0/go.mod h1:xkSsbof2nBLbhDlRMhhhyNLN/zl3eTqcnHD5viDpcZ0= golang.org/x/tools v0.1.1/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= golang.org/x/tools v0.1.2/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= golang.org/x/tools v0.1.3/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= golang.org/x/tools v0.1.4/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= golang.org/x/tools v0.1.5/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= golang.org/x/tools v0.1.12/go.mod h1:hNGJHUnrk76NpqgfD5Aqm5Crs+Hm0VOH/i9J2+nxYbc= golang.org/x/tools v0.2.0/go.mod h1:y4OqIKeOV/fWJetJ8bXPU1sEVniLMIyDAZWeHdV+NTA= golang.org/x/tools v0.23.0 h1:SGsXPZ+2l4JsgaCKkx+FQ9YZ5XEtA1GZYuoDjenLjvg= golang.org/x/tools v0.23.0/go.mod h1:pnu6ufv6vQkll6szChhK3C3L/ruaIv5eBeztNG8wtsI= golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20220411194840-2f41105eb62f/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20220517211312-f3a8303e98df/go.mod h1:K8+ghG5WaK9qNqU5K3HdILfMLy1f3aNYFI/wnl100a8= golang.org/x/xerrors v0.0.0-20220609144429-65e65417b02f/go.mod h1:K8+ghG5WaK9qNqU5K3HdILfMLy1f3aNYFI/wnl100a8= golang.org/x/xerrors v0.0.0-20220907171357-04be3eba64a2/go.mod h1:K8+ghG5WaK9qNqU5K3HdILfMLy1f3aNYFI/wnl100a8= golang.org/x/xerrors v0.0.0-20231012003039-104605ab7028 h1:+cNy6SZtPcJQH3LJVLOSmiC7MMxXNOb3PU/VUEz+EhU= golang.org/x/xerrors v0.0.0-20231012003039-104605ab7028/go.mod h1:NDW/Ps6MPRej6fsCIbMTohpP40sJ/P/vI1MoTEGwX90= google.golang.org/api v0.3.1/go.mod h1:6wY9I6uQWHQ8EM57III9mq/AjF+i8G65rmVagqKMtkk= google.golang.org/api v0.4.0/go.mod h1:8k5glujaEP+g9n7WNsDg8QP6cUVNI86fCNMcbazEtwE= google.golang.org/api v0.7.0/go.mod h1:WtwebWUNSVBH/HAw79HIFXZNqEvBhG+Ra+ax0hx3E3M= google.golang.org/api v0.8.0/go.mod h1:o4eAsZoiT+ibD93RtjEohWalFOjRDx6CVaqeizhEnKg= google.golang.org/api v0.9.0/go.mod h1:o4eAsZoiT+ibD93RtjEohWalFOjRDx6CVaqeizhEnKg= google.golang.org/api v0.13.0/go.mod h1:iLdEw5Ide6rF15KTC1Kkl0iskquN2gFfn9o9XIsbkAI= google.golang.org/api v0.14.0/go.mod h1:iLdEw5Ide6rF15KTC1Kkl0iskquN2gFfn9o9XIsbkAI= google.golang.org/api v0.15.0/go.mod h1:iLdEw5Ide6rF15KTC1Kkl0iskquN2gFfn9o9XIsbkAI= google.golang.org/api v0.17.0/go.mod h1:BwFmGc8tA3vsd7r/7kR8DY7iEEGSU04BFxCo5jP/sfE= google.golang.org/api v0.18.0/go.mod h1:BwFmGc8tA3vsd7r/7kR8DY7iEEGSU04BFxCo5jP/sfE= google.golang.org/api v0.19.0/go.mod h1:BwFmGc8tA3vsd7r/7kR8DY7iEEGSU04BFxCo5jP/sfE= google.golang.org/api v0.20.0/go.mod h1:BwFmGc8tA3vsd7r/7kR8DY7iEEGSU04BFxCo5jP/sfE= google.golang.org/api v0.22.0/go.mod h1:BwFmGc8tA3vsd7r/7kR8DY7iEEGSU04BFxCo5jP/sfE= google.golang.org/api v0.24.0/go.mod h1:lIXQywCXRcnZPGlsd8NbLnOjtAoL6em04bJ9+z0MncE= google.golang.org/api v0.28.0/go.mod h1:lIXQywCXRcnZPGlsd8NbLnOjtAoL6em04bJ9+z0MncE= google.golang.org/api v0.29.0/go.mod h1:Lcubydp8VUV7KeIHD9z2Bys/sm/vGKnG1UHuDBSrHWM= google.golang.org/api v0.30.0/go.mod h1:QGmEvQ87FHZNiUVJkT14jQNYJ4ZJjdRF23ZXz5138Fc= google.golang.org/api v0.35.0/go.mod h1:/XrVsuzM0rZmrsbjJutiuftIzeuTQcEeaYcSk/mQ1dg= google.golang.org/api v0.36.0/go.mod h1:+z5ficQTmoYpPn8LCUNVpK5I7hwkpjbcgqA7I34qYtE= google.golang.org/api v0.40.0/go.mod h1:fYKFpnQN0DsDSKRVRcQSDQNtqWPfM9i+zNPxepjRCQ8= google.golang.org/api v0.41.0/go.mod h1:RkxM5lITDfTzmyKFPt+wGrCJbVfniCr2ool8kTBzRTU= google.golang.org/api v0.43.0/go.mod h1:nQsDGjRXMo4lvh5hP0TKqF244gqhGcr/YSIykhUk/94= google.golang.org/api v0.47.0/go.mod h1:Wbvgpq1HddcWVtzsVLyfLp8lDg6AA241LmgIL59tHXo= google.golang.org/api v0.48.0/go.mod h1:71Pr1vy+TAZRPkPs/xlCf5SsU8WjuAWv1Pfjbtukyy4= google.golang.org/api v0.50.0/go.mod h1:4bNT5pAuq5ji4SRZm+5QIkjny9JAyVD/3gaSihNefaw= google.golang.org/api v0.51.0/go.mod h1:t4HdrdoNgyN5cbEfm7Lum0lcLDLiise1F8qDKX00sOU= google.golang.org/api v0.54.0/go.mod h1:7C4bFFOvVDGXjfDTAsgGwDgAxRDeQ4X8NvUedIt6z3k= google.golang.org/api v0.55.0/go.mod h1:38yMfeP1kfjsl8isn0tliTjIb1rJXcQi4UXlbqivdVE= google.golang.org/api v0.56.0/go.mod h1:38yMfeP1kfjsl8isn0tliTjIb1rJXcQi4UXlbqivdVE= google.golang.org/api v0.57.0/go.mod h1:dVPlbZyBo2/OjBpmvNdpn2GRm6rPy75jyU7bmhdrMgI= google.golang.org/api v0.61.0/go.mod h1:xQRti5UdCmoCEqFxcz93fTl338AVqDgyaDRuOZ3hg9I= google.golang.org/api v0.63.0/go.mod h1:gs4ij2ffTRXwuzzgJl/56BdwJaA194ijkfn++9tDuPo= google.golang.org/api v0.67.0/go.mod h1:ShHKP8E60yPsKNw/w8w+VYaj9H6buA5UqDp8dhbQZ6g= google.golang.org/api v0.70.0/go.mod h1:Bs4ZM2HGifEvXwd50TtW70ovgJffJYw2oRCOFU/SkfA= google.golang.org/api v0.71.0/go.mod h1:4PyU6e6JogV1f9eA4voyrTY2batOLdgZ5qZ5HOCc4j8= google.golang.org/api v0.74.0/go.mod h1:ZpfMZOVRMywNyvJFeqL9HRWBgAuRfSjJFpe9QtRRyDs= google.golang.org/api v0.75.0/go.mod h1:pU9QmyHLnzlpar1Mjt4IbapUCy8J+6HD6GeELN69ljA= google.golang.org/api v0.77.0/go.mod h1:pU9QmyHLnzlpar1Mjt4IbapUCy8J+6HD6GeELN69ljA= google.golang.org/api v0.78.0/go.mod h1:1Sg78yoMLOhlQTeF+ARBoytAcH1NNyyl390YMy6rKmw= google.golang.org/api v0.80.0/go.mod h1:xY3nI94gbvBrE0J6NHXhxOmW97HG7Khjkku6AFB3Hyg= google.golang.org/api v0.84.0/go.mod h1:NTsGnUFJMYROtiquksZHBWtHfeMC7iYthki7Eq3pa8o= google.golang.org/api v0.85.0/go.mod h1:AqZf8Ep9uZ2pyTvgL+x0D3Zt0eoT9b5E8fmzfu6FO2g= google.golang.org/api v0.90.0/go.mod h1:+Sem1dnrKlrXMR/X0bPnMWyluQe4RsNoYfmNLhOIkzw= google.golang.org/api v0.93.0/go.mod h1:+Sem1dnrKlrXMR/X0bPnMWyluQe4RsNoYfmNLhOIkzw= google.golang.org/api v0.95.0/go.mod h1:eADj+UBuxkh5zlrSntJghuNeg8HwQ1w5lTKkuqaETEI= google.golang.org/api v0.96.0/go.mod h1:w7wJQLTM+wvQpNf5JyEcBoxK0RH7EDrh/L4qfsuJ13s= google.golang.org/api v0.97.0/go.mod h1:w7wJQLTM+wvQpNf5JyEcBoxK0RH7EDrh/L4qfsuJ13s= google.golang.org/api v0.98.0/go.mod h1:w7wJQLTM+wvQpNf5JyEcBoxK0RH7EDrh/L4qfsuJ13s= google.golang.org/api v0.100.0/go.mod h1:ZE3Z2+ZOr87Rx7dqFsdRQkRBk36kDtp/h+QpHbB7a70= google.golang.org/api v0.171.0 h1:w174hnBPqut76FzW5Qaupt7zY8Kql6fiVjgys4f58sU= google.golang.org/api v0.171.0/go.mod h1:Hnq5AHm4OTMt2BUVjael2CWZFD6vksJdWCWiUAmjC9o= google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM= google.golang.org/appengine v1.2.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= google.golang.org/appengine v1.5.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= google.golang.org/appengine v1.6.1/go.mod h1:i06prIuMbXzDqacNJfV5OdTW448YApPu5ww/cMBSeb0= google.golang.org/appengine v1.6.5/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCIDZVag1xfc= google.golang.org/appengine v1.6.6/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCIDZVag1xfc= google.golang.org/appengine v1.6.7/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCIDZVag1xfc= google.golang.org/genproto v0.0.0-20180817151627-c66870c02cf8/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc= google.golang.org/genproto v0.0.0-20180831171423-11092d34479b/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc= google.golang.org/genproto v0.0.0-20190307195333-5fe7a883aa19/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE= google.golang.org/genproto v0.0.0-20190418145605-e7d98fc518a7/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE= google.golang.org/genproto v0.0.0-20190425155659-357c62f0e4bb/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE= google.golang.org/genproto v0.0.0-20190502173448-54afdca5d873/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE= google.golang.org/genproto v0.0.0-20190530194941-fb225487d101/go.mod h1:z3L6/3dTEVtUr6QSP8miRzeRqwQOioJ9I66odjN4I7s= google.golang.org/genproto v0.0.0-20190801165951-fa694d86fc64/go.mod h1:DMBHOl98Agz4BDEuKkezgsaosCRResVns1a3J2ZsMNc= google.golang.org/genproto v0.0.0-20190819201941-24fa4b261c55/go.mod h1:DMBHOl98Agz4BDEuKkezgsaosCRResVns1a3J2ZsMNc= google.golang.org/genproto v0.0.0-20190911173649-1774047e7e51/go.mod h1:IbNlFCBrqXvoKpeg0TB2l7cyZUmoaFKYIwrEpbDKLA8= google.golang.org/genproto v0.0.0-20191108220845-16a3f7862a1a/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc= google.golang.org/genproto v0.0.0-20191115194625-c23dd37a84c9/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc= google.golang.org/genproto v0.0.0-20191216164720-4f79533eabd1/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc= google.golang.org/genproto v0.0.0-20191230161307-f3c370f40bfb/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc= google.golang.org/genproto v0.0.0-20200115191322-ca5a22157cba/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc= google.golang.org/genproto v0.0.0-20200122232147-0452cf42e150/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc= google.golang.org/genproto v0.0.0-20200204135345-fa8e72b47b90/go.mod h1:GmwEX6Z4W5gMy59cAlVYjN9JhxgbQH6Gn+gFDQe2lzA= google.golang.org/genproto v0.0.0-20200212174721-66ed5ce911ce/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= google.golang.org/genproto v0.0.0-20200224152610-e50cd9704f63/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= google.golang.org/genproto v0.0.0-20200228133532-8c2c7df3a383/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= google.golang.org/genproto v0.0.0-20200305110556-506484158171/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= google.golang.org/genproto v0.0.0-20200312145019-da6875a35672/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= google.golang.org/genproto v0.0.0-20200331122359-1ee6d9798940/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= google.golang.org/genproto v0.0.0-20200423170343-7949de9c1215/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= google.golang.org/genproto v0.0.0-20200430143042-b979b6f78d84/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= google.golang.org/genproto v0.0.0-20200511104702-f5ebc3bea380/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= google.golang.org/genproto v0.0.0-20200513103714-09dca8ec2884/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= google.golang.org/genproto v0.0.0-20200515170657-fc4c6c6a6587/go.mod h1:YsZOwe1myG/8QRHRsmBRE1LrgQY60beZKjly0O1fX9U= google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo= google.golang.org/genproto v0.0.0-20200618031413-b414f8b61790/go.mod h1:jDfRM7FcilCzHH/e9qn6dsT145K34l5v+OpcnNgKAAA= google.golang.org/genproto v0.0.0-20200729003335-053ba62fc06f/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20200804131852-c06518451d9c/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20200825200019-8632dd797987/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20200904004341-0bd0a958aa1d/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20201109203340-2640f1f9cdfb/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20201201144952-b05cb90ed32e/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20201210142538-e3217bee35cc/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20201214200347-8c77b98c765d/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20210126160654-44e461bb6506/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20210222152913-aa3ee6e6a81c/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20210303154014-9728d6b83eeb/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20210310155132-4ce2db91004e/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20210319143718-93e7006c17a6/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20210329143202-679c6ae281ee/go.mod h1:9lPAdzaEmUacj36I+k7YKbEc5CXzPIeORRgDAUOu28A= google.golang.org/genproto v0.0.0-20210402141018-6c239bbf2bb1/go.mod h1:9lPAdzaEmUacj36I+k7YKbEc5CXzPIeORRgDAUOu28A= google.golang.org/genproto v0.0.0-20210513213006-bf773b8c8384/go.mod h1:P3QM42oQyzQSnHPnZ/vqoCdDmzH28fzWByN9asMeM8A= google.golang.org/genproto v0.0.0-20210602131652-f16073e35f0c/go.mod h1:UODoCrxHCcBojKKwX1terBiRUaqAsFqJiF615XL43r0= google.golang.org/genproto v0.0.0-20210604141403-392c879c8b08/go.mod h1:UODoCrxHCcBojKKwX1terBiRUaqAsFqJiF615XL43r0= google.golang.org/genproto v0.0.0-20210608205507-b6d2f5bf0d7d/go.mod h1:UODoCrxHCcBojKKwX1terBiRUaqAsFqJiF615XL43r0= google.golang.org/genproto v0.0.0-20210624195500-8bfb893ecb84/go.mod h1:SzzZ/N+nwJDaO1kznhnlzqS8ocJICar6hYhVyhi++24= google.golang.org/genproto v0.0.0-20210713002101-d411969a0d9a/go.mod h1:AxrInvYm1dci+enl5hChSFPOmmUF1+uAa/UsgNRWd7k= google.golang.org/genproto v0.0.0-20210716133855-ce7ef5c701ea/go.mod h1:AxrInvYm1dci+enl5hChSFPOmmUF1+uAa/UsgNRWd7k= google.golang.org/genproto v0.0.0-20210728212813-7823e685a01f/go.mod h1:ob2IJxKrgPT52GcgX759i1sleT07tiKowYBGbczaW48= google.golang.org/genproto v0.0.0-20210805201207-89edb61ffb67/go.mod h1:ob2IJxKrgPT52GcgX759i1sleT07tiKowYBGbczaW48= google.golang.org/genproto v0.0.0-20210813162853-db860fec028c/go.mod h1:cFeNkxwySK631ADgubI+/XFU/xp8FD5KIVV4rj8UC5w= google.golang.org/genproto v0.0.0-20210821163610-241b8fcbd6c8/go.mod h1:eFjDcFEctNawg4eG61bRv87N7iHBWyVhJu7u1kqDUXY= google.golang.org/genproto v0.0.0-20210828152312-66f60bf46e71/go.mod h1:eFjDcFEctNawg4eG61bRv87N7iHBWyVhJu7u1kqDUXY= google.golang.org/genproto v0.0.0-20210831024726-fe130286e0e2/go.mod h1:eFjDcFEctNawg4eG61bRv87N7iHBWyVhJu7u1kqDUXY= google.golang.org/genproto v0.0.0-20210903162649-d08c68adba83/go.mod h1:eFjDcFEctNawg4eG61bRv87N7iHBWyVhJu7u1kqDUXY= google.golang.org/genproto v0.0.0-20210909211513-a8c4777a87af/go.mod h1:eFjDcFEctNawg4eG61bRv87N7iHBWyVhJu7u1kqDUXY= google.golang.org/genproto v0.0.0-20210924002016-3dee208752a0/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= google.golang.org/genproto v0.0.0-20211118181313-81c1377c94b1/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= google.golang.org/genproto v0.0.0-20211206160659-862468c7d6e0/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= google.golang.org/genproto v0.0.0-20211208223120-3a66f561d7aa/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= google.golang.org/genproto v0.0.0-20211221195035-429b39de9b1c/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= google.golang.org/genproto v0.0.0-20220126215142-9970aeb2e350/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= google.golang.org/genproto v0.0.0-20220207164111-0872dc986b00/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= google.golang.org/genproto v0.0.0-20220218161850-94dd64e39d7c/go.mod h1:kGP+zUP2Ddo0ayMi4YuN7C3WZyJvGLZRh8Z5wnAqvEI= google.golang.org/genproto v0.0.0-20220222213610-43724f9ea8cf/go.mod h1:kGP+zUP2Ddo0ayMi4YuN7C3WZyJvGLZRh8Z5wnAqvEI= google.golang.org/genproto v0.0.0-20220304144024-325a89244dc8/go.mod h1:kGP+zUP2Ddo0ayMi4YuN7C3WZyJvGLZRh8Z5wnAqvEI= google.golang.org/genproto v0.0.0-20220310185008-1973136f34c6/go.mod h1:kGP+zUP2Ddo0ayMi4YuN7C3WZyJvGLZRh8Z5wnAqvEI= google.golang.org/genproto v0.0.0-20220314164441-57ef72a4c106/go.mod h1:hAL49I2IFola2sVEjAn7MEwsja0xp51I0tlGAf9hz4E= google.golang.org/genproto v0.0.0-20220324131243-acbaeb5b85eb/go.mod h1:hAL49I2IFola2sVEjAn7MEwsja0xp51I0tlGAf9hz4E= google.golang.org/genproto v0.0.0-20220407144326-9054f6ed7bac/go.mod h1:8w6bsBMX6yCPbAVTeqQHvzxW0EIFigd5lZyahWgyfDo= google.golang.org/genproto v0.0.0-20220413183235-5e96e2839df9/go.mod h1:8w6bsBMX6yCPbAVTeqQHvzxW0EIFigd5lZyahWgyfDo= google.golang.org/genproto v0.0.0-20220414192740-2d67ff6cf2b4/go.mod h1:8w6bsBMX6yCPbAVTeqQHvzxW0EIFigd5lZyahWgyfDo= google.golang.org/genproto v0.0.0-20220421151946-72621c1f0bd3/go.mod h1:8w6bsBMX6yCPbAVTeqQHvzxW0EIFigd5lZyahWgyfDo= google.golang.org/genproto v0.0.0-20220429170224-98d788798c3e/go.mod h1:8w6bsBMX6yCPbAVTeqQHvzxW0EIFigd5lZyahWgyfDo= google.golang.org/genproto v0.0.0-20220502173005-c8bf987b8c21/go.mod h1:RAyBrSAP7Fh3Nc84ghnVLDPuV51xc9agzmm4Ph6i0Q4= google.golang.org/genproto v0.0.0-20220505152158-f39f71e6c8f3/go.mod h1:RAyBrSAP7Fh3Nc84ghnVLDPuV51xc9agzmm4Ph6i0Q4= google.golang.org/genproto v0.0.0-20220518221133-4f43b3371335/go.mod h1:RAyBrSAP7Fh3Nc84ghnVLDPuV51xc9agzmm4Ph6i0Q4= google.golang.org/genproto v0.0.0-20220523171625-347a074981d8/go.mod h1:RAyBrSAP7Fh3Nc84ghnVLDPuV51xc9agzmm4Ph6i0Q4= google.golang.org/genproto v0.0.0-20220608133413-ed9918b62aac/go.mod h1:KEWEmljWE5zPzLBa/oHl6DaEt9LmfH6WtH1OHIvleBA= google.golang.org/genproto v0.0.0-20220616135557-88e70c0c3a90/go.mod h1:KEWEmljWE5zPzLBa/oHl6DaEt9LmfH6WtH1OHIvleBA= google.golang.org/genproto v0.0.0-20220617124728-180714bec0ad/go.mod h1:KEWEmljWE5zPzLBa/oHl6DaEt9LmfH6WtH1OHIvleBA= google.golang.org/genproto v0.0.0-20220624142145-8cd45d7dbd1f/go.mod h1:KEWEmljWE5zPzLBa/oHl6DaEt9LmfH6WtH1OHIvleBA= google.golang.org/genproto v0.0.0-20220628213854-d9e0b6570c03/go.mod h1:KEWEmljWE5zPzLBa/oHl6DaEt9LmfH6WtH1OHIvleBA= google.golang.org/genproto v0.0.0-20220722212130-b98a9ff5e252/go.mod h1:GkXuJDJ6aQ7lnJcRF+SJVgFdQhypqgl3LB1C9vabdRE= google.golang.org/genproto v0.0.0-20220801145646-83ce21fca29f/go.mod h1:iHe1svFLAZg9VWz891+QbRMwUv9O/1Ww+/mngYeThbc= google.golang.org/genproto v0.0.0-20220815135757-37a418bb8959/go.mod h1:dbqgFATTzChvnt+ujMdZwITVAJHFtfyN1qUhDqEiIlk= google.golang.org/genproto v0.0.0-20220817144833-d7fd3f11b9b1/go.mod h1:dbqgFATTzChvnt+ujMdZwITVAJHFtfyN1qUhDqEiIlk= google.golang.org/genproto v0.0.0-20220822174746-9e6da59bd2fc/go.mod h1:dbqgFATTzChvnt+ujMdZwITVAJHFtfyN1qUhDqEiIlk= google.golang.org/genproto v0.0.0-20220829144015-23454907ede3/go.mod h1:dbqgFATTzChvnt+ujMdZwITVAJHFtfyN1qUhDqEiIlk= google.golang.org/genproto v0.0.0-20220829175752-36a9c930ecbf/go.mod h1:dbqgFATTzChvnt+ujMdZwITVAJHFtfyN1qUhDqEiIlk= google.golang.org/genproto v0.0.0-20220913154956-18f8339a66a5/go.mod h1:0Nb8Qy+Sk5eDzHnzlStwW3itdNaWoZA5XeSG+R3JHSo= google.golang.org/genproto v0.0.0-20220914142337-ca0e39ece12f/go.mod h1:0Nb8Qy+Sk5eDzHnzlStwW3itdNaWoZA5XeSG+R3JHSo= google.golang.org/genproto v0.0.0-20220915135415-7fd63a7952de/go.mod h1:0Nb8Qy+Sk5eDzHnzlStwW3itdNaWoZA5XeSG+R3JHSo= google.golang.org/genproto v0.0.0-20220916172020-2692e8806bfa/go.mod h1:0Nb8Qy+Sk5eDzHnzlStwW3itdNaWoZA5XeSG+R3JHSo= google.golang.org/genproto v0.0.0-20220919141832-68c03719ef51/go.mod h1:0Nb8Qy+Sk5eDzHnzlStwW3itdNaWoZA5XeSG+R3JHSo= google.golang.org/genproto v0.0.0-20220920201722-2b89144ce006/go.mod h1:ht8XFiar2npT/g4vkk7O0WYS1sHOHbdujxbEp7CJWbw= google.golang.org/genproto v0.0.0-20220926165614-551eb538f295/go.mod h1:woMGP53BroOrRY3xTxlbr8Y3eB/nzAvvFM83q7kG2OI= google.golang.org/genproto v0.0.0-20220926220553-6981cbe3cfce/go.mod h1:woMGP53BroOrRY3xTxlbr8Y3eB/nzAvvFM83q7kG2OI= google.golang.org/genproto v0.0.0-20221010155953-15ba04fc1c0e/go.mod h1:3526vdqwhZAwq4wsRUaVG555sVgsNmIjRtO7t/JH29U= google.golang.org/genproto v0.0.0-20221014173430-6e2ab493f96b/go.mod h1:1vXfmgAz9N9Jx0QA82PqRVauvCz1SGSz739p0f183jM= google.golang.org/genproto v0.0.0-20221014213838-99cd37c6964a/go.mod h1:1vXfmgAz9N9Jx0QA82PqRVauvCz1SGSz739p0f183jM= google.golang.org/genproto v0.0.0-20221025140454-527a21cfbd71/go.mod h1:9qHF0xnpdSfF6knlcsnpzUu5y+rpwgbvsyGAZPBMg4s= google.golang.org/genproto v0.0.0-20240213162025-012b6fc9bca9 h1:9+tzLLstTlPTRyJTh+ah5wIMsBW5c4tQwGTN3thOW9Y= google.golang.org/genproto v0.0.0-20240213162025-012b6fc9bca9/go.mod h1:mqHbVIp48Muh7Ywss/AD6I5kNVKZMmAa/QEW58Gxp2s= google.golang.org/genproto/googleapis/api v0.0.0-20240903143218-8af14fe29dc1 h1:hjSy6tcFQZ171igDaN5QHOw2n6vx40juYbC/x67CEhc= google.golang.org/genproto/googleapis/api v0.0.0-20240903143218-8af14fe29dc1/go.mod h1:qpvKtACPCQhAdu3PyQgV4l3LMXZEtft7y8QcarRsp9I= google.golang.org/genproto/googleapis/rpc v0.0.0-20240903143218-8af14fe29dc1 h1:pPJltXNxVzT4pK9yD8vR9X75DaWYYmLGMsEvBfFQZzQ= google.golang.org/genproto/googleapis/rpc v0.0.0-20240903143218-8af14fe29dc1/go.mod h1:UqMtugtsSgubUsoxbuAoiCXvqvErP7Gf0so0mK9tHxU= google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.0/go.mod h1:chYK+tFQF0nDUGJgXMSgLCQk3phJEuONr2DCgLDdAQM= google.golang.org/grpc v1.20.1/go.mod h1:10oTOabMzJvdu6/UiuZezV6QK5dSlG84ov/aaiqXj38= google.golang.org/grpc v1.21.0/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM= google.golang.org/grpc v1.21.1/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM= google.golang.org/grpc v1.22.1/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg= google.golang.org/grpc v1.23.0/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg= google.golang.org/grpc v1.23.1/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg= google.golang.org/grpc v1.25.1/go.mod h1:c3i+UQWmh7LiEpx4sFZnkU36qjEYZ0imhYfXVyQciAY= google.golang.org/grpc v1.26.0/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk= google.golang.org/grpc v1.27.0/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk= google.golang.org/grpc v1.27.1/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk= google.golang.org/grpc v1.28.0/go.mod h1:rpkK4SK4GF4Ach/+MFLZUBavHOvF2JJB5uozKKal+60= google.golang.org/grpc v1.29.1/go.mod h1:itym6AZVZYACWQqET3MqgPpjcuV5QH3BxFS3IjizoKk= google.golang.org/grpc v1.30.0/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak= google.golang.org/grpc v1.31.0/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak= google.golang.org/grpc v1.31.1/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak= google.golang.org/grpc v1.32.0/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak= google.golang.org/grpc v1.33.1/go.mod h1:fr5YgcSWrqhRRxogOsw7RzIpsmvOZ6IcH4kBYTpR3n0= google.golang.org/grpc v1.33.2/go.mod h1:JMHMWHQWaTccqQQlmk3MJZS+GWXOdAesneDmEnv2fbc= google.golang.org/grpc v1.34.0/go.mod h1:WotjhfgOW/POjDeRt8vscBtXq+2VjORFy659qA51WJ8= google.golang.org/grpc v1.35.0/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= google.golang.org/grpc v1.36.0/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= google.golang.org/grpc v1.36.1/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= google.golang.org/grpc v1.37.0/go.mod h1:NREThFqKR1f3iQ6oBuvc5LadQuXVGo9rkm5ZGrQdJfM= google.golang.org/grpc v1.37.1/go.mod h1:NREThFqKR1f3iQ6oBuvc5LadQuXVGo9rkm5ZGrQdJfM= google.golang.org/grpc v1.38.0/go.mod h1:NREThFqKR1f3iQ6oBuvc5LadQuXVGo9rkm5ZGrQdJfM= google.golang.org/grpc v1.39.0/go.mod h1:PImNr+rS9TWYb2O4/emRugxiyHZ5JyHW5F+RPnDzfrE= google.golang.org/grpc v1.39.1/go.mod h1:PImNr+rS9TWYb2O4/emRugxiyHZ5JyHW5F+RPnDzfrE= google.golang.org/grpc v1.40.0/go.mod h1:ogyxbiOoUXAkP+4+xa6PZSE9DZgIHtSpzjDTB9KAK34= google.golang.org/grpc v1.40.1/go.mod h1:ogyxbiOoUXAkP+4+xa6PZSE9DZgIHtSpzjDTB9KAK34= google.golang.org/grpc v1.44.0/go.mod h1:k+4IHHFw41K8+bbowsex27ge2rCb65oeWqe4jJ590SU= google.golang.org/grpc v1.45.0/go.mod h1:lN7owxKUQEqMfSyQikvvk5tf/6zMPsrK+ONuO11+0rQ= google.golang.org/grpc v1.46.0/go.mod h1:vN9eftEi1UMyUsIF80+uQXhHjbXYbm0uXoFCACuMGWk= google.golang.org/grpc v1.46.2/go.mod h1:vN9eftEi1UMyUsIF80+uQXhHjbXYbm0uXoFCACuMGWk= google.golang.org/grpc v1.47.0/go.mod h1:vN9eftEi1UMyUsIF80+uQXhHjbXYbm0uXoFCACuMGWk= google.golang.org/grpc v1.48.0/go.mod h1:vN9eftEi1UMyUsIF80+uQXhHjbXYbm0uXoFCACuMGWk= google.golang.org/grpc v1.49.0/go.mod h1:ZgQEeidpAuNRZ8iRrlBKXZQP1ghovWIVhdJRyCDK+GI= google.golang.org/grpc v1.50.0/go.mod h1:ZgQEeidpAuNRZ8iRrlBKXZQP1ghovWIVhdJRyCDK+GI= google.golang.org/grpc v1.50.1/go.mod h1:ZgQEeidpAuNRZ8iRrlBKXZQP1ghovWIVhdJRyCDK+GI= google.golang.org/grpc v1.68.0 h1:aHQeeJbo8zAkAa3pRzrVjZlbz6uSfeOXlJNQM0RAbz0= google.golang.org/grpc v1.68.0/go.mod h1:fmSPC5AsjSBCK54MyHRx48kpOti1/jRfOlwEWywNjWA= google.golang.org/grpc/cmd/protoc-gen-go-grpc v1.1.0/go.mod h1:6Kw0yEErY5E/yWrBtf03jp27GLLJujG4z/JK95pnjjw= google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8= google.golang.org/protobuf v0.0.0-20200221191635-4d8936d0db64/go.mod h1:kwYJMbMJ01Woi6D6+Kah6886xMZcty6N08ah7+eCXa0= google.golang.org/protobuf v0.0.0-20200228230310-ab0ca4ff8a60/go.mod h1:cfTl7dwQJ+fmap5saPgwCLgHXTUD7jkjRqWcaiX5VyM= google.golang.org/protobuf v1.20.1-0.20200309200217-e05f789c0967/go.mod h1:A+miEFZTKqfCUM6K7xSMQL9OKL/b6hQv+e19PK+JZNE= google.golang.org/protobuf v1.21.0/go.mod h1:47Nbq4nVaFHyn7ilMalzfO3qCViNmqZ2kzikPIcrTAo= google.golang.org/protobuf v1.22.0/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU= google.golang.org/protobuf v1.23.0/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU= google.golang.org/protobuf v1.23.1-0.20200526195155-81db48ad09cc/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU= google.golang.org/protobuf v1.24.0/go.mod h1:r/3tXBNzIEhYS9I1OUVjXDlt8tc493IdKGjtUeSXeh4= google.golang.org/protobuf v1.25.0/go.mod h1:9JNX74DMeImyA3h4bdi1ymwjUzf21/xIlbajtzgsN7c= google.golang.org/protobuf v1.26.0-rc.1/go.mod h1:jlhhOSvTdKEhbULTjvd4ARK9grFBp09yW+WbY/TyQbw= google.golang.org/protobuf v1.26.0/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= google.golang.org/protobuf v1.27.1/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= google.golang.org/protobuf v1.28.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= google.golang.org/protobuf v1.28.1/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= google.golang.org/protobuf v1.36.1 h1:yBPeRvTftaleIgM3PZ/WBIZ7XM/eEYAaEyCwvyjq/gk= google.golang.org/protobuf v1.36.1/go.mod h1:9fA7Ob0pmnwhb644+1+CVWFRbNajQ6iRojtC/QF5bRE= gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20200902074654-038fdea0a05b/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q= gopkg.in/cheggaaa/pb.v1 v1.0.25/go.mod h1:V/YB90LKu/1FcN3WVnfiiE5oMCibMjukxqG/qStrOgw= gopkg.in/cheggaaa/pb.v1 v1.0.27/go.mod h1:V/YB90LKu/1FcN3WVnfiiE5oMCibMjukxqG/qStrOgw= gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI= gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys= gopkg.in/gcfg.v1 v1.2.3/go.mod h1:yesOnuUOFQAhST5vPY4nbZsb/huCgGGXlipJsBn0b3o= gopkg.in/ini.v1 v1.67.0 h1:Dgnx+6+nfE+IfzjUEISNeydPJh9AXNNsWbGP9KzCsOA= gopkg.in/ini.v1 v1.67.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= gopkg.in/resty.v1 v1.12.0/go.mod h1:mDo4pnntr5jdWRML875a/NmxYqAlA73dVijT2AXvQQo= gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 h1:uRGJdciOHaEIrze2W8Q3AKkepLTh2hOroT7a+7czfdQ= gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw= gopkg.in/warnings.v0 v0.1.2/go.mod h1:jksf8JmL6Qr/oQM2OXTHunEvvTAsrWBLb6OOjuVWRNI= gopkg.in/yaml.v2 v2.0.0-20170812160011-eb3733d160e7/go.mod h1:JAlM8MvJe8wmxCU4Bli9HhUf9+ttbYbLASfIpnQbh74= gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.3/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.4/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.5/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.3.0/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY= gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ= gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gotest.tools v2.2.0+incompatible h1:VsBPFP1AI068pPrMxtb/S8Zkgf9xEmTLJjfM+P5UIEo= gotest.tools/v3 v3.5.1 h1:EENdUnS3pdur5nybKYIh2Vfgc8IUNBjxDPSjtiJcOzU= gotest.tools/v3 v3.5.1/go.mod h1:isy3WKz7GK6uNw/sbHzfKBLvlvXwUyV06n6brMxxopU= honnef.co/go/tools v0.0.0-20180728063816-88497007e858/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190106161140-3f1c8253044a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190418001031-e561f6794a2a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.1-2019.2.3/go.mod h1:a3bituU0lyd329TUQxRnasdCoJDkEUEAqEt0JzvZhAg= honnef.co/go/tools v0.0.1-2020.1.3/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k= honnef.co/go/tools v0.0.1-2020.1.4/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k= nhooyr.io/websocket v1.8.6/go.mod h1:B70DZP8IakI65RVQ51MsWP/8jndNma26DVA/nFSCgW0= nhooyr.io/websocket v1.8.7 h1:usjR2uOr/zjjkVMy0lW+PPohFok7PCow5sDjLgX4P4g= nhooyr.io/websocket v1.8.7/go.mod h1:B70DZP8IakI65RVQ51MsWP/8jndNma26DVA/nFSCgW0= pgregory.net/rapid v1.1.0 h1:CMa0sjHSru3puNx+J0MIAuiiEV4N0qj8/cMWGBBCsjw= pgregory.net/rapid v1.1.0/go.mod h1:PY5XlDGj0+V1FCq0o192FdRhpKHGTRIWBgqjDBTrq04= rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8= rsc.io/pdf v0.1.1/go.mod h1:n8OzWcQ6Sp37PL01nO98y4iUCRdTGarVfzxY20ICaU4= rsc.io/quote/v3 v3.1.0/go.mod h1:yEA65RcK8LyAZtP9Kv3t0HmxON59tX3rD+tICJqUlj0= rsc.io/sampler v1.3.0/go.mod h1:T1hPZKmBbMNahiBKFy5HrXp6adAjACjK9JXDnKaTXpA= sigs.k8s.io/yaml v1.1.0/go.mod h1:UJmg0vDUVViEyp3mgSv9WPwZCDxu4rQW1olrI1uml+o= sigs.k8s.io/yaml v1.4.0 h1:Mk1wCc2gy/F0THH0TAp1QYyJNzRm2KCLy3o5ASXVI5E= sigs.k8s.io/yaml v1.4.0/go.mod h1:Ejl7/uTz7PSA4eKMyQCUTnhZYNmLIl+5c2lQPGR2BPY= sourcegraph.com/sourcegraph/appdash v0.0.0-20190731080439-ebfcffb1b5c0/go.mod h1:hI742Nqp5OhwiqlzhgfbWU4mW4yO10fP+LoT9WOswdU= ================================================ FILE: merkle/node.go ================================================ package merkle type Node struct { hash []byte parent *Node left *Node right *Node // first index of elements in this node subnodes (inclusive) firstIndex int // last index of elements in this node subnodes (inclusive) lastIndex int } func (n *Node) GetIndexProofs(i int) []Proof { proofs := make([]Proof, 0) if n.left != nil && i >= n.left.firstIndex && i <= n.left.lastIndex { proofs = n.left.GetIndexProofs(i) proofs = append(proofs, Proof{Hash: n.right.hash, LeftSide: false}) } if n.right != nil && i >= n.right.firstIndex && i <= n.right.lastIndex { proofs = n.right.GetIndexProofs(i) proofs = append(proofs, Proof{Hash: n.left.hash, LeftSide: true}) } return proofs } ================================================ FILE: merkle/proof.go ================================================ package merkle import ( "hash" ) type Proof struct { LeftSide bool `json:"leftSide"` // where proof should be placed to sum with hash (left or right side) Hash []byte `json:"hash"` } // calculate sum hash func (p *Proof) SumWith(hashF hash.Hash, hash []byte) []byte { if p.LeftSide { return sum(hashF, p.Hash, hash) } return sum(hashF, hash, p.Hash) } ================================================ FILE: merkle/subtree.go ================================================ package merkle import "hash" // subtrees always should have power of 2 number of elements. // tree could contain few of subtrees. // root hash calculates from right to left by summing subtree roots hashes. type Subtree struct { root *Node // root node left *Subtree // left subtree from this one right *Subtree // right subtree from this one height int // height of subtree // hash function to hash sum nodes and hash data hashF hash.Hash } // get proofs for root of this subtree func (t *Subtree) GetRootProofs() []Proof { proofs := make([]Proof, 0) proofs = append(proofs, t.getRightSubtreesProof()...) proofs = append(proofs, t.getLeftSubtreesProof()...) return proofs } func (t *Subtree) getLeftSubtreesProof() []Proof { proofs := make([]Proof, 0) current := t.left for current != nil { proofs = append(proofs, Proof{Hash: current.root.hash, LeftSide: false}) current = current.left } return proofs } // right proof is only one cause we have to sum all right subtrees // we have to sum hashes from right to left func (t *Subtree) getRightSubtreesProof() []Proof { if t.right == nil { return make([]Proof, 0) } hashesToSum := make([][]byte, 0) rightTree := t.right for rightTree != nil { hashesToSum = append(hashesToSum, rightTree.root.hash) rightTree = rightTree.right } n := len(hashesToSum) - 1 proofHash := hashesToSum[n] for i := n - 1; i >= 0; i-- { proofHash = sum(t.hashF, proofHash, hashesToSum[i]) } return []Proof{{Hash: proofHash, LeftSide: true}} } ================================================ FILE: merkle/tree.go ================================================ package merkle import ( "bytes" "encoding/binary" "hash" "math" ) // Merkle tree data structure based on RFC-6962 standard (https://tools.ietf.org/html/rfc6962#section-2.1) // we separate whole tree to subtrees where nodes count equal power of 2 // root hash calculates from right to left by summing subtree roots hashes. type Tree struct { // this tree subtrees start from lowest height (extreme right subtree) subTree *Subtree // subtrees total count (for convenience) subTreesCount int // last index of elements in this tree (exclusive) lastIndex int // DON'T USE IT FOR PARALLEL CALCULATION (results in errors) hashF hash.Hash // if false then store only roots of subtrees (no proofs available => suitable for consensus only) // for 1,099,511,627,775 links tree would contain only 40 root hashes. full bool } func NewTree(hashF hash.Hash, full bool) *Tree { return &Tree{hashF: hashF, full: full} } func (t *Tree) joinAllSubtrees() { for t.subTree.left != nil && t.subTree.height == t.subTree.left.height { newSubtreeRoot := &Node{ hash: sum(t.hashF, t.subTree.left.root.hash, t.subTree.root.hash), firstIndex: t.subTree.left.root.firstIndex, lastIndex: t.subTree.root.lastIndex, } // for full tree we should keep all nodes if t.full { newSubtreeRoot.left = t.subTree.left.root newSubtreeRoot.right = t.subTree.root newSubtreeRoot.left.parent = newSubtreeRoot newSubtreeRoot.right.parent = newSubtreeRoot } t.subTree = &Subtree{ root: newSubtreeRoot, right: nil, left: t.subTree.left.left, height: t.subTree.height + 1, hashF: t.hashF, } if t.subTree.left != nil { t.subTree.left.right = t.subTree } t.subTreesCount-- } } func (t *Tree) Reset() { t.lastIndex = 0 t.subTree = nil t.subTreesCount = 0 } // build completely new tree with data // works the same (by time) as using Push method one by one func (t *Tree) BuildNew(data [][]byte) { t.Reset() itemsLeft := int64(len(data)) nextSubtreeLen := int64(math.Pow(2, float64(int64(math.Log2(float64(itemsLeft)))))) startIndex := int64(0) endIndex := startIndex + nextSubtreeLen for nextSubtreeLen != 0 { nextSubtree := buildSubTree(t.hashF, t.full, int(startIndex), data[startIndex:endIndex]) if t.subTree != nil { t.subTree.right = nextSubtree nextSubtree.left = t.subTree t.subTree = nextSubtree } else { t.subTree = nextSubtree } t.subTreesCount++ itemsLeft -= nextSubtreeLen nextSubtreeLen = int64(math.Pow(2, float64(int64(math.Log2(float64(itemsLeft)))))) startIndex = endIndex endIndex = startIndex + nextSubtreeLen } t.lastIndex = int(endIndex) } // n*log(n) func (t *Tree) Push(data []byte) { newSubtreeRoot := &Node{ hash: sum(t.hashF, data), parent: nil, left: nil, right: nil, firstIndex: t.lastIndex, lastIndex: t.lastIndex, } t.lastIndex++ t.subTree = &Subtree{ root: newSubtreeRoot, right: nil, left: t.subTree, height: 0, hashF: t.hashF, } if t.subTree.left != nil { t.subTree.left.right = t.subTree } t.subTreesCount++ t.joinAllSubtrees() } // going from right trees to left func (t *Tree) GetIndexProofs(i int) []Proof { // we cannot build proofs with not full tree if !t.full { return nil } proofs := make([]Proof, 0, int64(math.Log2(float64(t.lastIndex)))) for current := t.subTree; current != nil; { if i >= current.root.firstIndex && i <= current.root.lastIndex { proofs = append(proofs, current.root.GetIndexProofs(i)...) proofs = append(proofs, current.GetRootProofs()...) return proofs } current = current.left } return proofs } func (t *Tree) ValidateIndex(i int, data []byte) bool { if !t.full { return false } return t.ValidateIndexByProofs(i, data, t.GetIndexProofs(i)) } func (t *Tree) ValidateIndexByProofs(i int, data []byte, proofs []Proof) bool { rootHash := sum(t.hashF, data) for _, proof := range proofs { rootHash = proof.SumWith(t.hashF, rootHash) } return bytes.Equal(rootHash, t.RootHash()) } // root hash calculates from right to left by summing subtrees root hashes. func (t *Tree) RootHash() []byte { if t.subTree == nil { return sum(t.hashF) // zero hash } rootHash := t.subTree.root.hash current := t.subTree.left for current != nil { rootHash = sum(t.hashF, rootHash, current.root.hash) current = current.left } return rootHash } // from right to left // we need to export root hash and height of tree // from those bytes we could restore it later and use for consensus func (t *Tree) ExportSubtreesRoots() []byte { if t.subTree == nil { return make([]byte, 0) } hashSize := t.hashF.Size() heightSize := 8 // using 8 byte integer result := make([]byte, 0, (hashSize+heightSize)*t.subTreesCount) current := t.subTree for current != nil { heightBytes := make([]byte, 8) binary.LittleEndian.PutUint64(heightBytes, uint64(current.height)) result = append(result, current.root.hash...) result = append(result, heightBytes...) current = current.left } return result } // from right to left // after import we loosing indices (actually they don't need for consensus and pushing) func (t *Tree) ImportSubtreesRoots(subTreesRoots []byte) { t.Reset() t.full = false hashSize := t.hashF.Size() heightSize := 8 t.subTreesCount = len(subTreesRoots) / (hashSize + heightSize) start := 0 var first *Subtree var current *Subtree for i := 0; i < t.subTreesCount; i++ { end := start + hashSize rootHash := subTreesRoots[start:end] height := binary.LittleEndian.Uint64(subTreesRoots[end : end+heightSize]) nextSubtree := &Subtree{ root: &Node{ hash: rootHash, }, height: int(height), } if current != nil { nextSubtree.right = current current.left = nextSubtree current = nextSubtree } else { current = nextSubtree first = nextSubtree } start = end + heightSize } t.subTree = first } ================================================ FILE: merkle/tree_test.go ================================================ package merkle import ( "crypto/sha256" "encoding/binary" "testing" "github.com/stretchr/testify/require" ) func TestPushAndProofs(t *testing.T) { tree := NewTree(sha256.New(), true) data := make([]byte, 8) for i := 0; i < 31; i++ { binary.LittleEndian.PutUint64(data, uint64(i)) tree.Push(data) } // Check all proofs for i := 0; i < 31; i++ { proofs := tree.GetIndexProofs(i) binary.LittleEndian.PutUint64(data, uint64(i)) require.Equal(t, true, tree.ValidateIndexByProofs(i, data, proofs)) } } func TestBuildNewAndProofs(t *testing.T) { tree := NewTree(sha256.New(), true) allData := make([][]byte, 0, 31) for i := 0; i < 31; i++ { data := make([]byte, 8) binary.LittleEndian.PutUint64(data, uint64(i)) allData = append(allData, data) } tree.BuildNew(allData) // Check all proofs for i := 0; i < 31; i++ { proofs := tree.GetIndexProofs(i) data := make([]byte, 8) binary.LittleEndian.PutUint64(data, uint64(i)) require.Equal(t, true, tree.ValidateIndexByProofs(i, data, proofs)) } } func TestEqualityOfBuildNewAndPush(t *testing.T) { tree1 := NewTree(sha256.New(), true) data := make([]byte, 8) for i := 0; i < 31; i++ { binary.LittleEndian.PutUint64(data, uint64(i)) tree1.Push(data) } tree2 := NewTree(sha256.New(), true) allData := make([][]byte, 0, 31) for i := 0; i < 31; i++ { data := make([]byte, 8) binary.LittleEndian.PutUint64(data, uint64(i)) allData = append(allData, data) } tree2.BuildNew(allData) require.Equal(t, tree1.RootHash(), tree2.RootHash()) } func TestNotFull(t *testing.T) { tree1 := NewTree(sha256.New(), true) data := make([]byte, 8) for i := 0; i < 31; i++ { binary.LittleEndian.PutUint64(data, uint64(i)) tree1.Push(data) } tree2 := NewTree(sha256.New(), false) for i := 0; i < 31; i++ { binary.LittleEndian.PutUint64(data, uint64(i)) tree2.Push(data) } tree3 := NewTree(sha256.New(), false) allData := make([][]byte, 0, 31) for i := 0; i < 31; i++ { data := make([]byte, 8) binary.LittleEndian.PutUint64(data, uint64(i)) allData = append(allData, data) } tree3.BuildNew(allData) require.Equal(t, tree1.RootHash(), tree2.RootHash()) require.Equal(t, tree1.RootHash(), tree3.RootHash()) } func TestExportImport(t *testing.T) { tree1 := NewTree(sha256.New(), true) data := make([]byte, 8) for i := 0; i < 31; i++ { binary.LittleEndian.PutUint64(data, uint64(i)) tree1.Push(data) } subtreeRoots := tree1.ExportSubtreesRoots() tree2 := NewTree(sha256.New(), false) tree2.ImportSubtreesRoots(subtreeRoots) require.Equal(t, tree1.RootHash(), tree2.RootHash()) binary.LittleEndian.PutUint64(data, uint64(31)) tree1.Push(data) tree2.Push(data) require.Equal(t, tree1.RootHash(), tree2.RootHash()) } ================================================ FILE: merkle/util.go ================================================ package merkle import ( "hash" "math" ) func sum(h hash.Hash, data ...[]byte) []byte { h.Reset() for _, d := range data { // the Hash interface specifies that Write never returns an error _, _ = h.Write(d) } return h.Sum(nil) } // number of data elements should be power of 2 // not suitable for parallel calculations cause using same hash.Hash func buildSubTree(h hash.Hash, full bool, startIndex int, data [][]byte) *Subtree { nodes := make([]*Node, len(data)) for i := 0; i < len(data); i++ { nodes[i] = &Node{ hash: sum(h, data[i]), firstIndex: startIndex + i, lastIndex: startIndex + i, } } root := sumNodes(h, full, nodes)[0] return &Subtree{ root: root, left: nil, right: nil, height: int(math.Log2(float64(len(data)))), hashF: h, } } func sumNodes(h hash.Hash, full bool, nodes []*Node) []*Node { if len(nodes) == 1 { return nodes } newNodes := make([]*Node, len(nodes)/2) for i := 0; i < len(nodes); i += 2 { newNodes[i/2] = joinNodes(h, full, nodes[i], nodes[i+1]) } return sumNodes(h, full, newNodes) } func joinNodes(h hash.Hash, full bool, left *Node, right *Node) *Node { newNode := &Node{ firstIndex: left.firstIndex, lastIndex: right.lastIndex, hash: sum(h, left.hash, right.hash), } if full { newNode.left = left newNode.right = right left.parent = newNode right.parent = newNode } return newNode } ================================================ FILE: networks/bostrom/cyberfrey-upgrade-guide.md ================================================ # How to prepare your node for Cyberfrey upgrade This guide includes all the steps you need to get ready for the `Cyberfrey` upgrade in Bostrom. Hereby we assume that you run your node in docker with the cyber ["official"](https://hub.docker.com/layers/cyber/cyberd/cyber/bostrom-1/images/sha256-6383de3e4562690907b0dbb99b752f53ef2d41f44a7d452a903d24397e49911b?context=explore) image, otherwise this guide will not suit your node. ## Step 1: Pull new docker image The new cyber binary is wrapped in the new docker image, so we have to pull it first: ```js docker pull cyberd/cyber:bostrom-2 ``` It may take few minutes to pull the new image. When complete, check that you have it with: ```js docker images ``` ## Step 2: Replace docker image for Bostrom container *At this stage you will have to operate quickly in order to reduce your node downtime, so please read all the sub-steps first!* Stop your current docker container with Bostrom: ```js docker stop bostrom ``` Remove Bostrom container (do not worry, files will stay untouched): ```js docker rm bostrom ``` Create Bostrom container from new image (note: if you have custom ports set, please adjust accordingly): ```sh docker run -d --gpus all --name=bostrom --restart always -p 26656:26656 -p 26657:26657 -p 1317:1317 -e ALLOW_SEARCH=true -v $HOME/.cyber:/root/.cyber cyberd/cyber:bostrom-2 ``` Check logs. Block production should restore after startup: ```sh docker logs bostrom -f --tail 20 ``` ## Step 3: Verify that everything is OK After the container lauch, the new cyber binary should appear inside the `$HOME/.cyber/cosmovisor/` folder. Check that you have a similar folder layout: ```sh cd $HOME/.cyber/cosmovisor/ tree ``` You should have a similar layout of files and folders: ```sh root@node:~/.cyber/cosmovisor# tree . ├── current -> /root/.cyber/cosmovisor/genesis/bin ├── genesis │   └── bin │   └── cyber └── upgrades └── cyberfrey └── bin    └── cyber 6 directories, 2 files ``` ## You are done! What's next? Now is a good time to go and vote for prop #7. If you havent done this yet, report that you have completed preparation for the upgrade in our [Hall of Fame](https://t.me/fameofcyber) and chill until the upgrade block 3098000, which should come around 9:00am UTC Friday 03.06.2022 (proposal says 04.06.2022 but that's incorrect). You may also track the countdown to upgrade at `cybernode.ai`, actual block time is used there so the estimate is more or less correct. What will happen at the block 3098000: - chain will halt with message `CONSENSUS FAILURE!!! err="UPGRADE \"cyberfrey\" NEEDED at height: 3098000:` - Cosmovisor inside the container will catch this event and change symlink inside `.cyber/cosmovisor/` folder - node will start and as soon as 66%+ of voting power is online, blocks will resume ## Crisis protocol The process of upgrading should go pretty smoothly and should not require any direct action, but in case something goes wrong, cyber devs may consider certain ways to recover. Simply check your node at the time of the upgrade and consult the [Hall of Fame](https://t.me/fameofcyber) chat for possible coordination. ================================================ FILE: networks/bostrom/deploy_node_from_snapshot.md ================================================ # Deploy bostrom node from snapshot ## Download snapshot First, go to [Cyber Snapshot Robot](https://cyb.ai/network/bostrom/contract/bostrom137p3ll78yrlw3gtfltgwhdkz0qxke4z6mt9qe6) page Latest post will show you available snapsot: ![](https://ipfs.io/ipfs/QmWjcgseTj5GmGSC8z1X6wzD5Eh1wQv1RfBfChmafqcwvm) Сlick on the link with the block and you will see two results: ![](https://ipfs.io/ipfs/QmQvZegg39JnQ5EESgA3t9seCYSAF7nZyDZGRo1iUXLemi) We typicaly store only latest snashot, older might be available only in IPFS if someone stored them. The first one is a hash of the current snapshot that can be downloaded directly from ipfs (to use this way, you need an ipfs [client](https://docs.ipfs.tech/install/command-line/) installed) ``` ipfs get --output bostrom_pruned.tar.gz ``` The second hash contains url that can be downloaded directly: ``` wget https:// ``` ## Unpack snapshot Single thread: ``` tar -xvzf bostrom_pruned_.tar.gz ``` Multiple threads (much faster and require pigz installation): ``` apt install pigz ``` ``` tar -I pigz -xf bostrom_pruned_.tar.gz -C ./ ``` ## Stop Cyber ``` docker stop bostrom ``` ## Remove old data from home directory **Dont forget to use correct path if your node is not in $HOME of your user.** ``` rm -rf ~/.cyber/data ~/.cyber/wasm ``` ## Move unpacked folders into home directory ``` cd bostrom_pruned_ ``` ``` mv data/ ~/.cyber/ ``` ``` mv wasm/ ~/.cyber/ ``` ## Set up your pruning strategy to everything To save the space ont the disk consumed by the node set pruning to everything (lightest one) and set snapshot-interval to 0 in `.cyber/config/app.toml`: ``` pruning = "everything" ``` ``` snapshot-interval = 0 ``` ## Start Cyber container and check logs ``` docker start bostrom ``` ``` docker logs bostrom -f --tail 10 ``` You will see node started sync from the snapshot block. ## When done dont forget to remove folder and archive to save some space ``` rm -rf bostrom_pruned_ bostrom_pruned_.tar.gz ``` ================================================ FILE: networks/bostrom/genesis-validator.md ================================================ # Setting up cyber Genesis Validator This guide will provide detailed instructions on how to submit gentx for the bostrom chain! The primary point of communication for the whole gentx and lauch ceremonies will be our [Cyber Hall of Fame](https://t.me/fameofcyber) telegram chat. Some important notices about joining the genesis validator set: 1. **GenTx must be submited by 0:00 UTC 1st November** 2. We recommend only highly experienced validators who have run on past Cosmos SDK chains and have participated in a genesis ceremony before become genesis validators on Cyber. 3. Being a Genesis validator for a Supercomputer is an honor, so we expect all participants to treat this opportunity accordingly. We want our validators to be pro-active, maintain good uptime, communicate and act professionally during chain upgrades, and respectfully participate in governance. 4. To become a Genesis validator, you must have boot tokens on your account in Genesis. That might've happened if you participated in one of our previous testnets or Game of Links, or some other kind of incentivized activity. ## Hardware setup Recommended hardware setup stays the same as it was for the last Bostrom-testnets: ```js CPU: 6 cores RAM: 32 GB SSD: 1 TB Connection: 50+Mbps, Stable and low-latency connection GPU: Nvidia GeForce (or Tesla/Titan/Quadro) with CUDA-cores; 4+ Gb of video memory* Software: Ubuntu 18.04 LTS / 20.04 LTS ``` The blockchain is always growing. Therefore, in the future, hardware requirements might increase. Also, the specs above are not mandatory and may differ, but it always implies that the node might be powerful and reliable. ## Instructions All instructions provided are for the Ubuntu 20.04 system and may vary for other versions\OS. ### Install GO 1.17+ Cyber is written in `go`, and we'll need the version 1.17+ to compile it. Check which version you currently have with ```bash go version ``` If you need to update or install 'go' we'd recommend to use the handy go version manager called [g](https://github.com/stefanmaric/g). To install 'go' with it use: ```bash curl -sSL https://git.io/g-install | sh -s source ~/.bashrc ``` Agree to install latest version, or manually install specific version: ```bash g install 1.17.2 g set 1.17.2 go version ``` You might see something like that: ```bash go version go1.17.2 linux/amd64 ``` ### Install cyber Download source files from github: ```bash git clone https://github.com/cybercongress/go-cyber.git cd go-cyber git checkout bostrom-dev ``` Then install `cyber` daemon. Running the following command will install the executable cyber to your GOPATH: ```bash make install ``` Verify your installation by running: ```bash cyber version --long ``` Result must look like this: ```bash name: cyber server_name: cyber version: 0.2.0-rc2 commit: ....... build_tags: netgo ledger, go: go version go1.17.2 linux/amd64 build_deps: - filippo.io/edwards25519@v1.0.0-beta.2 - github.com/99designs/keyring@v1.1.6 ... - gopkg.in/yaml.v3@v3.0.0-20210107192922-496545a6307b - nhooyr.io/websocket@v1.8.6 cosmos_sdk_version: v0.44.2 ``` If your `cyber` version does not match - please verify that you dont have any other daemons laying somewhere else in `/usr/local/bin`. ### Initialize your node Before you proceed verify that you don't have any old\test nodes initialized in that machine, check and remove folders inside `~/.cyber/`. If you have the testnet node running, stop it and remove `~/.cyber/` folder (do not forget to backup your seeds before you remove anything): ```bash ls -la ~/ rm -rf .cyber/ ``` Then run the following to init fresh one(replace with something, for example `web2_destroyer`): ```bash cyber init ``` This will create a new `.cyber` folder in your HOME directory. ### Download Pregenesis File You can now download the "pregenesis" file for the chain. This is a genesis file with the chain-id and all balances. ```sh cd $HOME/.cyber/config/ wget -O $HOME/.cyber/config/genesis.json https://gateway.ipfs.cybernode.ai/ipfs/QmQAd2SBwypsz5ZqkYgeSTFLq3peGV9xGE3i1gW5oPjcYT ``` ### Import Validator Key To create a gentx, you will need the private key to an address that has some tokens in Genesis. There are a couple options for how to import a key into `cyber`. You can import such a key into via a mnemonic or add one from the Ledger. ```bash cyber keys add --recover ``` You could use your **ledger** device with the Cosmos app installed on it to sign transactions. Add address from Ledger: ```bash cyber keys add --ledger ``` **** is any name you pick to represent this key pair. You have to refer to that name later when you use cli to sign transactions. *Note* If you got an error saying ```js Error: No such interface “org.freedesktop.DBus.Properties” on object at path / ``` during key import, please use file keyring with all cli key commands: ```bash cyber keys add --recover --keyring-backend file ``` ### Create GenTx Now that you have your key imported you are able to use it to create your gentx. To create the Genesis transaction, you will have to choose the following parameters for your validator: - moniker - commission-rate - commission-max-rate - commission-max-change-rate - min-self-delegation (must be >10000boot) - website (optional) - details (optional) - identity (keybase key hash, this is used to get validator logos in block explorers. optional) - pubkey (will be pulled automatically) Note that your gentx will be rejected if you use an amount greater than what you have on you balance in Genesis. An example Genesis command would look like this: ```bash cyber gentx 10000000000boot \\ --min-self-delegation "1000000000" \ --pubkey=$(cyber tendermint show-validator) \ --moniker= \ --commission-rate="0.05" \ --commission-max-rate="0.10" \ --commission-max-change-rate="0.01" \ --chain-id=bostrom ``` *add `--keyring-backend file` if you used it during key import.* Output will look similar to this: ```sh Genesis transaction written to "/root/.cyber/config/gentx/gentx-445e04520cef1116faab9900e2edadcb8164477c.json" ``` File content must look similar to this [sample-gentx](https://github.com/cybercongress/networks/blob/main/bostrom/gentxs/gentx-SAMPLE.json) ### Submit Your GenTx To submit your GenTx for inclusion in the chain, please upload it to the [github.com/cybercongress/networks](https://github.com/cybercongress/networks/tree/main/bostrom) repo by `0:00 UTC 1st November`. To upload the your Genesis file, please follow these steps: 1. Rename the gentx file located in your `$HOME/.cyber/config/gentx/` to gentx-{your-moniker}.json (please do not have any spaces or special characters in the file name) 2. Fork this repo by going to https://github.com/cybercongress/networks, clicking on fork, and choose your account (if multiple). 3. Clone your copy of the fork to your local machine ```sh git clone https://github.com//networks ``` 4. Copy the gentx to the networks repo (ensure that it is in the correct folder) ```sh cp ~/.cyber/config/gentx/gentx-.json networks/bostrom/gentxs/ ``` 5. Commit and push to your repo. ```sh cd networks git add bostrom/gentxs/* git commit -m " gentx" git push origin master ``` 6. Create a pull request from your fork to master on this repo. 7. Let us know in [Cyber Hall of Fame](https://t.me/fameofcyber) when you've completed this process! 8. Stay tuned, further steps will be provided soon! ### Back-up validator keys (!) Your identity as validator consists of two things: - your account (to sign transactions) - your validator private key (to sign stuff on the chain consensus layer) Please back up `$HOME/.cyber/config/priv_validator_key.json` along with your seed phrase. In case of occasional folder loss you would be able to restore you validator. Those things should not be changed, otherwise, your validator won't start on Genesis. ## Prepare node for chain start Ok, so here is it, the final genesis for the bostrom network - [QmYubyVNfghD4xCrTFj26zBwrF9s5GJhi1TmxvrwmJCipr](https://gateway.ipfs.cybernode.ai/ipfs/QmYubyVNfghD4xCrTFj26zBwrF9s5GJhi1TmxvrwmJCipr). We have 33 valid genesis transactions submitted! Now only a few steps left to finalize the validator node setup for bostrom launch: - Clear out old containers - Download final genesis, and place it to working directory `$HOME/.cyber` - Pull and deploy new Docker container - Configure persistent peers, seeds, and some other stuff from `config.toml` - Verify the correctness of the keys and files on the node ### Cleaning up If you somehow still have old containers like `bostrom-testnet-6` or `bostrom-testnet-7` sitting on your node - it is a good time to remove them now. Check which docker containers you have: ```bash docker ps -a ``` And stop\delete all unnecessary: ```bash docker stop old-container-name docker rm old-container-name ``` Check and remove older images to save some space ```bash docker images docker rmi image_name ``` If you have older nodes on your server, **please remove the `cosmovisor`** directory from .cyber, so it will be updated with the latest version of binaries during docker startup: ```bash rm -rf $HOME/.cyber/cosmovisor/ ``` ### Obtain signed genesis file Hereby we mean that you already have your cyber node initialized in $HOME directory. Remove pre-genesis from .cyber: ```bash rm $HOME/.cyber/config/genesis.json ``` Download genesis file for bostrom: ```bash wget -O $HOME/.cyber/config/genesis.json https://gateway.ipfs.cybernode.ai/ipfs/QmYubyVNfghD4xCrTFj26zBwrF9s5GJhi1TmxvrwmJCipr ``` Also, it is **required** to remove old chain data and reset the home directory to state of signed genesis: ```bash cyber unsafe-reset-all --home $HOME/.cyber/ ``` ### Deploy docker container To pull and deploy docker container for the `bostrom` chain use the following command: ```bash docker run -d --gpus all --name=bostrom --restart always -p 26656:26656 -p 26657:26657 -p 1317:1317 -e ALLOW_SEARCH=false -v $HOME/.cyber:/root/.cyber cyberd/cyber:bostrom-1 ``` ### Setup config.toml Add correct seeds and persistent peers nodes. You may find some [here](https://github.com/cybercongress/networks/blob/main/bostrom/peers.md) Insert them into lines 185 and 188 of $HOME/.cyber/config/config.toml: ```bash nano $HOME/.cyber/config/config.toml ``` ```bash # Comma separated list of seed nodes to connect to seeds = "" # Comma separated list of nodes to keep persistent connections to persistent_peers = "" ``` For better network stability please update your `.cyber/config/config.toml` lines as follows: ``` addr_book_strict = false max_num_inbound_peers = 60 max_num_outbound_peers = 30 persistent_peers_max_dial_period = "500s" ``` ### Verify validator keys Verify that your `priv_validator_key.json` from $HOME/.cyber/config/ directory matches the one you used to create gentx. Check that `pub key value` section is similar to the one corresponding your validator name below: ```bash cat $HOME/.cyber/config/priv_validator_key.json ``` ```bash sta FVs7R89ToDtCaYNZHrRF8MWCQ4d3uxytQSMg4OMleW8= blue 110HUJd7XFqWhXbE/nF1D4pFcM/vQ8D9yOJbyQF6gsc= Node_masters hkaRWuE3BNBVmeqv70qJ++iyYs7THerZyOhNa7E2gVM= Citizen Cosmos hzZZ1s5Q2R0Qhbax0Hf7xS9m+kMxbc6FVUihIIoa35c= 0base.vc 9EtOO5q/eUiQ1VtdFegl46fyhJ2tkzm2TDLkdm+zRm0= Space 0O20CW17q7chWZGHayK+SlEzCXfJaqTlshkE1xujQCg= Citadel.one 96vbjWw9jbyO8Krl9Rjbt8SU9tVuBiPhtVAxx28arcU= Developer KdT8GK9d81xvkDzuNjM3nwi3mijxRfq2YWnM++SAIw4= qwertys318 r3NIqDgCKwxfTIdvsUYruUSv+ExKI/dyL9UxRt3uuHQ= web34ever Kry59s/u3vENIsWu+4ssFqsnECWTxA8iOFSXPbIQmsU= POSTHUMAN lWEU7pJSRroGTFMa5O6JKRC1JnGsupKTC88i3uAtxu0= papsan YV4dJbW6TrErmwcs0VxFiAJUio+6Yh5shQ+hwlMveN8= P2P.ORG 4KsAoQUaZNVyA0Tc02Gw3GYxkuMdgtf+aXTOqKDNbgE= Nett ChguMkmpTQCnekerrNnAnyFePLY3C1jacudM3SYOrdg= Godzilla BncD9wiS2MKpBJw1t9PLoIeqQ9pTccPoGBx9cRNoZak= Kerman 0nAyxxNGDv3s2miDdJWibOEoWVre8jadmJiA7BSEugk= cyberG uMw2XjXqICe1CvEbYCwN3GEXm5r1CBhc0TacHucheyw= Adorid AK7c305pBQkAz05OE8rw5JkwSx+nhcvna6Tz9RXhE+Q= DemonKing XXul+cFAn6BK4S/aZlMABb9h+jsqFi7/GgZ01JTfhnE= DragonBall SmngMSNxQ7TnildgcI5OzZYJxWbwAH2C0UJj3M+J+Fw= StakeAngle qOE+qVo9giTu6cypXg6zN3ZT9MitNBHfTYfLL2ADVGo= spectrum ZxG1y2GSwb/HuBi8BFZLoYYUMyuvboplTa1DDuMGnG0= kiwi 823dliApVbj5vUsXFYViaOB6hI8/P7ul0zmZpHmW+80= PLap 2VHfckjdelAwGj8b3gw+kq7U0ni9aB9S3rNQx054iVU= dobry ZxYmxQPGdPYaBJA8IY4Jg3h/Cs0wVRmPIippypxPrsU= goto5k TVfJZnq2vaHv1XI49n7nPn1wVQxurVL3JDVVUUo/Ijo= alinode JKHQ2Gg/+wWDMcvLwHoEHFccRVZYuGCBSTD/fnIi2vg= Hailbiafra triXPhJGBlAduyzF6oF0PKHM9H2sXz9+TWY5gb9lkNI= csaxial lB5R6K7wY2G4a3Aus+NWAwYiFga5Cc2WxvwZG3Ga3yk= NodeMarsel fIbK0sEsisgCoXnWmrfApLX7SdvuhltzU1llq+jiV8k= MindPool RPBRQHcurf6ZOoar9DWoncHbcEGmaceT0zdalDYsobo= Bro_n_Bro SEiFL2BSD9TOUsPIaBKx5xZU+ijry95DdZ44u9mwd3Y= bloqhub aIG2z/l2N3K6WslUGA8u5kZnqcvqyKEXQpoiiICLKa4= ``` ## Launch When all above are checked and completed please go ahead and restart the container: ```bash docker restart bostrom ``` Check the logs. ```bash docker logs bostrom ``` They have to contain the following: ```bash 1:42AM INF Starting Node service impl=Node 1:42AM INF Genesis time is in the future. Sleeping until then... genTime=2021-11-05T13:22:42Z ``` If you got that message - congrats, you set everything up! The chain will start at `5th November 13:22UTC`. Please track [Cyber Hall of Fame](https://t.me/fameofcyber) telegram chat, all coordination will be done there. Also, watch the bostrom genesis at `https://cyb.ai/genesis`, you can find something beautiful and interesting there! See you in the Cyber Era! ================================================ FILE: networks/bostrom/genesis.json ================================================ { "genesis_time": "2021-11-05T13:22:42Z", "chain_id": "bostrom", "initial_height": "1", "consensus_params": { "block": { "max_bytes": "4194304", "max_gas": "25000000", "time_iota_ms": "1000" }, "evidence": { "max_age_num_blocks": "100000", "max_age_duration": "172800000000000", "max_bytes": "1048576" }, "validator": { "pub_key_types": [ "ed25519" ] }, "version": {} }, "app_hash": "", "app_state": { "auth": { "params": { "max_memo_characters": "1024", "tx_sig_limit": "7", "tx_size_cost_per_byte": "20", "sig_verify_cost_ed25519": "590", "sig_verify_cost_secp256k1": "1000" }, "accounts": [ { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "0", "address": "bostrom1xszmhkfjs3s00z2nvtn7evqxw3dtus6yr8e4pw", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "1", "address": "bostrom16230lc9r27vrxlzd4wlvcz2l66quzj84vlkxc5", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "2", "address": "bostrom1gxhs5wzam5rlgf6cs0lkme400ut64d4ncpfs2h", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "3", "address": "bostrom1qs9w7ry45axfxjgxa4jmuhjthzfvj78sxh5p6e", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "4", "address": "bostrom1ha4pw9w2qgc2ce9jwfrwrmaft5fneus58nqwev", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "5", "address": "bostrom1qn8sr2hzmktlecusdtxj9hwj0upnm0jft9snar", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "6", "address": "bostrom1d8754xqa9245pctlfcyv8eah468neqzn3a0y0t", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "7", "address": "bostrom1ttd4h585vgy29gj0xe0p338drvw9w4m4hzwj9p", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "8", "address": "bostrom1ngd5w7j4u5ar5xh7vzuwqqznnhhcjmnz0s6kpu", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "9", "address": "bostrom10c8znaj94y900syues06dz50hw6y9qpkhunn25", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.ModuleAccount", "base_account": { "account_number": "10", "address": "bostrom1jv65s3grqf6v6jl3dp4t6c9t9rk99cd8yvs0hc", "pub_key": null, "sequence": "0" }, "name": "distribution", "permissions": [] }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "11", "address": "bostrom1pntx8ql2v7cqxu05etg8c4v0r2vz7qnq9uqmpy", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "12", "address": "bostrom17a7xxqa4drnalvv7pkxrkxqer953fdke3ulwx4", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "13", "address": "bostrom1s4czxghmh29aw2ldynk8r9lnkfccw5ph8rjpxa", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "14", "address": "bostrom1s4wntr9selfaznc2ezjkwnwt2y0terx9tqpda3", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "15", "address": "bostrom1qwzsnnuk2u6avvh059c9p50gqqquvcu5svvwrs", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "16", "address": "bostrom1g07gj9ph0r2hjx6ffqn8vl38u4agd5mpqx9m7f", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "17", "address": "bostrom10e3rqclgjz4m4fnx2c23jupcjpyuvyx3x4k7qj", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "18", "address": "bostrom1t3222ju7ssu58xsm3m2xw445p94cqn2qrex3vy", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "19", "address": "bostrom1edlrze5f48jjaw0wxcve4asqqf2tcjdl59ln8q", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "20", "address": "bostrom1m8yf3g2m9p7danjvt4ga6vzewy380pk52kcu9z", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "21", "address": "bostrom1fe5mspz9jsq6p9hqqet86dwp276635l6gacspa", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "22", "address": "bostrom14nzyt8wmx4g6zkeluelukamgsh5v4xgnc25k6j", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "23", "address": "bostrom1mcslqq8ghtuf6xu987qtk64shy6rd86a2xtwu8", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "24", "address": "bostrom1sng0f47cuvx6edxaujh24wc3dvk94q0w6r6smh", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "25", "address": "bostrom194pp2whvqynxnfyw5tqy8fzy2kxsugyrwsaynk", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "26", "address": "bostrom14d92r4svhl4qa3g6q48tjekarw2kt67ngqn4lr", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "27", "address": "bostrom1hmkqhy8ygl6tnl5g8tc503rwrmmrkjcq3lduwj", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "28", "address": "bostrom12psudf4rpaw4jwhuyx3y8sejhsynae7gv53hn6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "29", "address": "bostrom178q202gz0093uke0jy96psyya452rt8apl4has", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "30", "address": "bostrom1kr6udadsvdjymq6m75un4khg27t25st2jn8sag", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "31", "address": "bostrom1ymprf45c44rp9k0g2r84w2tjhsq7kalv98rgpt", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "32", "address": "bostrom1w8ap0ns4d5fagjfwvph6t99uet0cwv6y6r03un", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "33", "address": "bostrom1svm5wl5jf4p7dwemj7wh0p4egr3js6rqtlnefu", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "34", "address": "bostrom1gnnd2eaeqpp6lsd34tnp6j0m85h6r9qg0wh3vr", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "35", "address": "bostrom1t0hmc79ht0qja92p6qgxn3ee3a3rzqutv7thqn", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "36", "address": "bostrom12q68xfj4r00nxnjrqk742rf0z2w6jmwaeppvr0", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "37", "address": "bostrom1ggc9sqvj0uhnzwxu5dyzcr05shwd2vv2guqmas", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "38", "address": "bostrom177y7sqkxmvl22j632haf8y9gv0j3wedssq5m50", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "39", "address": "bostrom1zhy7l8phhpsm2c6xl9c5arcu0z90clynluwrw5", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "40", "address": "bostrom1k60sfzh3ecyqfv36f7zav0089077e4zk4g6mxa", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "41", "address": "bostrom1kpep8dl93ud4wgpws3tcew6as2s36c9v3csw89", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "42", "address": "bostrom16lvsv3w7rnhcm079v6j9eah3xd0p3pd37hl48j", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "43", "address": "bostrom1mnrwpdlnglhtqwa55fa66va0j3fv72nvkz4e2x", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "44", "address": "bostrom1dt9lwmuq8rkngm5gajxchqhpcnavgp7md9v929", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "45", "address": "bostrom12xsg4qm4k5z48s79zdsz84jlhv56kmta3vyfvl", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "46", "address": "bostrom1dxpm2ne0jflzr2hy9j5has6u2dvfv68calunqy", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "47", "address": "bostrom1my32szlwazg9x56xqvsvtp0hqvpzm0r4u3k4ae", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "48", "address": "bostrom1g0ap9fvex93yzzj69uzl74942vjvq8e4f8xtyr", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "49", "address": "bostrom16zms8r32vad3z8hl2vc6wrcnanwmxf0dgh25yp", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "50", "address": "bostrom1d3zlsrjyl3tzp3aly7vjduhrtrtvkvkeaqpdku", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "51", "address": "bostrom18jwk949jqgq3j2du2dgscqxqkkqw5rsjfuucf3", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "52", "address": "bostrom13fwhvawke6867s6raqux25fd24t89j5h8wf2v0", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "53", "address": "bostrom18z9vsjffvggluxcxfqwsmrz02v37hx2e3auyn2", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "54", "address": "bostrom1lnkg57t7mvg5mcl7kdkevtgr9wlf6f9qtp86sk", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "55", "address": "bostrom1dl5df5g2xwj02e93k547etw2ergvc3a20v5ekz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "56", "address": "bostrom13ume6mqte5h9ngx2hh6ngc8aham7x0k6stuvkm", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "57", "address": "bostrom1ldjugf3uj2gwkmmsf5japfknf96zv6hw7xw7v4", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "58", "address": "bostrom1y9zkl7uqjev899swng4eqfuurwaxpchwppewyc", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "59", "address": "bostrom16lf2hvzy4n4gvtx37pgkkdw2e2psfjjdpej53p", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "60", "address": "bostrom15zs0cjct43xs4z4sesxcrynar5mxm82f0ykhl3", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "61", "address": "bostrom1v5jqg6k7mszmchhz8kyfml5h4e2txct9jz3am4", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "62", "address": "bostrom19ys53t55r725j882gjcrnf7s449gdrds3h2hu4", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "63", "address": "bostrom1en69twaxmv7xupy8lq7y539dpecx7yz8g0k8ft", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "64", "address": "bostrom1kgq82m6z2jttytv7fvwy2rklhq5k03gc2h9sej", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "65", "address": "bostrom1hvk6s053m6qdlz9kwllgldwf4qp2c3mrlh9s2q", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "66", "address": "bostrom1ch6nukdgj55c9sk4h5t8spzhahuuvn86gqvarm", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "67", "address": "bostrom1rqudjcrdwqedffxufmqgsleuguhm7pkaq0alce", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "68", "address": "bostrom1qgqkc9t3pfsp6yxjwds70e4r9y0p6resmfnymc", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "69", "address": "bostrom12kd8w45rqxuwpwqvpmdyvvdey9ezeqhav4nn85", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "70", "address": "bostrom152kqs8p7d3jy6kn4uk87ve3alkuqjgewt3cmvz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "71", "address": "bostrom1dn09uyhwmv3ratntc7c603vczgrec32c2fylpj", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "72", "address": "bostrom1qezgmksavgdvcvf9ckhazfy3jfw8whhzfrvtlz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "73", "address": "bostrom1d552nfgekkugdgxw3zl242qpxapl67jfkz76tp", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "74", "address": "bostrom10vpygn9ftv85ra7j7qpewuq5jdgvpjmehlds0g", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "75", "address": "bostrom18naxcfp2s397a2ucav2m53f003uylk3qz9fvr7", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "76", "address": "bostrom18t3kx877vyvstcvn50cgn5w6hppe8ce0pq72m2", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "77", "address": "bostrom1kfqv2fzzu6dgwnf6snql2jslwdws07fl2gz37u", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "78", "address": "bostrom1ggayl03vvv763az6eez66jzwuunyqkcusk8fwj", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "79", "address": "bostrom1fjeq0urgk4x0s6pl2p2fes8c95426amp7lv4dv", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "80", "address": "bostrom1jgh7ghrcr47tuahawzvg3svv2hxkxfx5u9lzr2", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "81", "address": "bostrom19y467lyhqlpa52y6snq9cxw47xhwq0th3p05r0", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "82", "address": "bostrom16ge9uqpqf78jdt0uz58ycalhtg59w77qm9t7d2", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "83", "address": "bostrom1463la66ac89tmlwgvx20c4d2jv84ekzs8kzh87", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "84", "address": "bostrom164k2s2s2td6a30d3rvnv93scy3v29psw4j3ndm", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "85", "address": "bostrom1rya5547x4lrwc2npd63s89ny2dvhamv9dfx9x9", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "86", "address": "bostrom18wn5kyxewwk6qh97493xtj9gufpmqserfahc37", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "87", "address": "bostrom1lljcf37yxh24l3v4kwqsyghwz4ywlg6urg4kte", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "88", "address": "bostrom1d7n8znqg635yxnzlsycnt6kut8z5du5yftutrf", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "89", "address": "bostrom16pdckvu70ufzvm8avd9anga6k35nu7axym02wp", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "90", "address": "bostrom18txzlmkqf264a2awhey6lmeq0dtv5ex69d2fcy", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "91", "address": "bostrom1mmtt0cnsgwx3t90vs4tn9k08kw8xn4v3pggfu7", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "92", "address": "bostrom1mryr27k3h8kqr5ahj82v0ym2xexdewfc9rmng8", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "93", "address": "bostrom1gg73t0eyrkqf953waqxh6uqah62p46jyg82ulr", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "94", "address": "bostrom1jx0az02ccnt4mgj2r9vhvycsdjsztrrgdkwzr3", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "95", "address": "bostrom1r90j4656xsug2hkj57a3knqcs9huh3ea88ykhp", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "96", "address": "bostrom1f7nx65pmayfenpfwzwaamwas4ygmvalq2q2ayq", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "97", "address": "bostrom1zl0t5703q42qx7drxsgl9thjwlul5x6unjhwgn", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "98", "address": "bostrom13q0m4hw6pmajqdqn4g464vzmst78sf55ktrp05", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "99", "address": "bostrom1cjyv02cja896rr5y5lks79enk2nretn3mqyc69", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "100", "address": "bostrom16qu2ymnzzjn05xc6yszjy50caaahcahdvmex5e", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "101", "address": "bostrom1jst67u54vquzvun3dawpmpwyx5ar8mayaak5j7", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "102", "address": "bostrom16s7gwc944patdynnfnvac0jh5u76wsnflty377", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "103", "address": "bostrom1s3lgc3mgy4ltwr796qk6j73xmau4njueds0mgu", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "104", "address": "bostrom10556xtnp39nvx3ec3yjafug662pyt6af84n477", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "105", "address": "bostrom1ffve0zx389ffl80ae9t8jmghcjuzdlqr5eayfd", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "106", "address": "bostrom1ftah3e558ww7xutn5w8h7vrqa9v69pntztnr3p", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "107", "address": "bostrom1wnpak7sfawsfv9c8vqe7naxfa4g99lv77d7c0z", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "108", "address": "bostrom1sgy27lctdrc5egpvc8f02rgzml6hmmvh5wu6xk", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "109", "address": "bostrom1cg79pj70mgl8xlum0rw5yy6enk9jszsrzvwysn", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "110", "address": "bostrom13dpy00jest96g7h5vdgvg9zpxq6xnclh5hzw5l", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "111", "address": "bostrom1mdq5r6az6z8su68zj6px88j2ukr78ea4ggkzt6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "112", "address": "bostrom1lepnu7nt05g79jtmfp2pgrpys3fjc4p74sc0l2", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "113", "address": "bostrom1d5lu67hu3lhqtw6zyv7uy4gkfpdtfnzxdu6mrq", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "114", "address": "bostrom16jttzjgks48kqrhk5e68yv0gv6dt0rpw2f5pwn", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "115", "address": "bostrom1e20hw2pqcgxvumkwn2qeeavcrswzskzjhr2aq0", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "116", "address": "bostrom17z2fywzrdld7qmwzpsq0atxfwcns8rp833rgxy", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "117", "address": "bostrom1tu0e0ggvjtv4gvzcranjnrykac0umnf8y8fm0r", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "118", "address": "bostrom1sltcfypwms38jjj3g38rg7ldx3e6uqrzrnkf9y", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "119", "address": "bostrom1zy553za8nenzukmv65240323jhuvxzym4pl6w9", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "120", "address": "bostrom1lpfs6xv765u4yxr8rlyn5ux0g2a8tyt90hsnas", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "121", "address": "bostrom1smqr5tp684g07aekcn0w852wqlme5mn6dmsny3", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "122", "address": "bostrom1eqkdzfcjnu20ywju35rf3nutxzjxjaqnxqfyyz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "123", "address": "bostrom1waac73cpffx7suhpkvnn8w0a8s2cgzn66x2aka", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "124", "address": "bostrom16macu2qtc0jmqc7txvf0wkz84cycsx728ah0xc", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "125", "address": "bostrom1fapqgamx3c8za8d3z56sydjtjygyu0ly752j8g", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "126", "address": "bostrom1w4548vrnvc7t9j2ly55nvkjvhwqt9thnfcvuw6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "127", "address": "bostrom133t8m00w7llsslnf05zdhehharntly8dqzpfs8", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "128", "address": "bostrom1smtmk8fe3qhlwj3h7nynl6p42946qydzvgj9va", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "129", "address": "bostrom1csf3up94qheqz88fvvlwjl7vc5sdymarktrvpw", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "130", "address": "bostrom1tr3eyy9l480pxjk0ygudwpfus7j8pgdljn09jm", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "131", "address": "bostrom16ahkkv0jzhtp73z83qlhqrypss6jpjm8eekpwv", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "132", "address": "bostrom1htq7u8gy9muv4fk6st04524tdzy8rv04528gys", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "133", "address": "bostrom1kk9clwd4eva7ww95gn4rw3xzuwfs0983sl5cwt", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "134", "address": "bostrom1k7cl9ya9qq30c7m4rvg3823hrc8k80eetqvhj8", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "135", "address": "bostrom16d69u47km5vqdvf6fr8qyhktlacgka7fdvazr8", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "136", "address": "bostrom1njsr8tngxtygsc73mrtn5738ztkzqy7c7y7h3t", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "137", "address": "bostrom1kf0d64nuwsf2zeul5wkx78fsznplnlpsfh7fqw", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "138", "address": "bostrom18ghjkwygsvjcsh20tc5zzhfttxxuex7a9lq8ps", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "139", "address": "bostrom1s2a7rckcky6jmhncxwy0xtwf2ymg87puk6jpzz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "140", "address": "bostrom1679yrs8dmska7wcsawgy2m25kwucm3z0hwr74y", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "141", "address": "bostrom15gk8edxtvvp372flljk884fav55y8ehwru4u8w", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "142", "address": "bostrom1jz57cgfr248y9w6sn76l7pugjkr6e7zh6y2grp", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "143", "address": "bostrom1gw5kdey7fs9wdh05w66s0h4s24tjdvtc9v6vpe", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "144", "address": "bostrom1kajt7sxfpnfujm7ptj90654lmwz4sftpc9mp9a", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "145", "address": "bostrom1t575qeee3qgshuf964qal057z77vljqef9tlck", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "146", "address": "bostrom105zy26ze9gean4qukqlvhkv4mtcndc9t2xaydz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "147", "address": "bostrom1a30w6j4m6g3s2c6zt02z56xynnuaqmn3ahwxuq", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "148", "address": "bostrom1pmaltcu0x97x8j5klc8xluaapkzcvztcn2vkmw", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "149", "address": "bostrom1n3mhyp9fvcmuu8l0q8qvjy07x0rql8q4uwev5z", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "150", "address": "bostrom1u3ap2d4ytcqrr6jlsjf380g3lvgldq4m64s7dg", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "151", "address": "bostrom1keny4peq77drtcdj6fscd9eknqcqyjmxqcr8t8", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "152", "address": "bostrom1kk79xcsuah7ckvunku78094gyh7900ehkllkur", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "153", "address": "bostrom137eezcxcyqgt6kshfdfuvnsdgwpujyje2l8qdz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "154", "address": "bostrom1uz39kh64w8p5df034fh6g5hwpdq8m0h5rx58he", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "155", "address": "bostrom1kz6s2mp4rg7plj8p4qqe2wkegn4ldw3ak2a7qc", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "156", "address": "bostrom1quchyywzdxp62dq3rwan8fg35v6j58sjwnfpuu", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "157", "address": "bostrom1x95keq9l9y9p7hjdt6xd8wnknrpnjsqrqhpwc9", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "158", "address": "bostrom1z98eg2ztdp2glyla62629nrlvczg8s7fvc0znp", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "159", "address": "bostrom1xvssufw8ke03halg8wgu8m994ktxz0y9vm6tqn", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "160", "address": "bostrom1vxxfhd8txmrq76jx3gj7sdrvg0vvqret6kxpgd", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "161", "address": "bostrom1vtu55cc7m6yz9zfg5vqdk80f2g68petgzj9fv4", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "162", "address": "bostrom16yf94eecl6h44l5w7zp75skh3rg0k4veavx762", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "163", "address": "bostrom1gxyf6tsjamnavmkfk43mwfzwscn4tgfkz8k85n", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "164", "address": "bostrom1w4tvyvf3hhpcwv9d4axa8n0mmj5d6ypvpq5mj6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "165", "address": "bostrom1xk4a2u2rjt7mqu5eg8xtxk37l28r3cugkqk9lp", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "166", "address": "bostrom143x4d5wx50204zyreqg8ekgq3n3fcaxucacztp", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "167", "address": "bostrom1y83nga220nfjt9zz0mmqc90cd705az95n5cfwj", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "168", "address": "bostrom1hyjhy0tp6geral2g9vj9nyteglf8t5q42gfq3j", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "169", "address": "bostrom1d8mq46wt2yxsgwrmh6hhfgycl0537w8gggn47f", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "170", "address": "bostrom1p0r7uxstcw8ehrwuj4kn8qzzs0yypsjwxgd445", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "171", "address": "bostrom1duc9gthaeg82lx9pdf642g043xqhgxgxmfvwsz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "172", "address": "bostrom1a4mzr2y2g0cc9f0uhyeh3ftmsfxzqwxfdqtd7c", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "173", "address": "bostrom1xpl2sx64ra5san4su0r0hj8z9eh5cf5dcv48qa", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "174", "address": "bostrom1hem3076xmat8ttr0cg0nnn2lghtc2p7xtzpj8s", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "175", "address": "bostrom1402rpwdquxxkgvl740f6w69l65eau5vkqcvrax", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "176", "address": "bostrom1z8mlsd42eaguaqf5gexy5a7jxgpwpgvz99qzft", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "177", "address": "bostrom1v2n3hg6s4resacgpemfyrd5hul2ntk7tftnk6u", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "178", "address": "bostrom1ufpz4dlnfawg0pr5dcq4hkrf9gs30mu0272p9w", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "179", "address": "bostrom1mkhugmqg9c0qe27stz3m4my9xq7e9pct0jyr3p", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "180", "address": "bostrom1argjwgcplguenq4l92ggn06wadnfrz0ecqrmqs", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "181", "address": "bostrom1ke7kxdn29w2lrxt9dzusa6shvmwd8xm9gxm2zf", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "182", "address": "bostrom1fpl40sref5vp8kfm7xkqlq5qc0v4xrjvk89kwa", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "183", "address": "bostrom1g2d9xyuf7ddgaj4llxvg50pfhlsr9ehf2r8dr6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "184", "address": "bostrom152m9xcx0ht7yxr5834ju7qjcyvetw8amd04apw", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "185", "address": "bostrom15n3t80p7eseld809f7fu3s9tlcezlymkfeu59n", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "186", "address": "bostrom1ke6pp2kq2wx74tlh5fxqgp7af6jtsna3kktuh6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "187", "address": "bostrom1daxxqs56f6j5qxxtjrjkexghsmnaj66tejshc8", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "188", "address": "bostrom1nywu6z26tpcrr2kcqe8z7t235wrfkhfcfhlzmk", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "189", "address": "bostrom1mnqlcc7mslzxcf798acp80u2fxudsuzdn0px6s", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "190", "address": "bostrom1ccvpcq9ffy0qd2ca8nmmpzfamtyjfc9znwak8m", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "191", "address": "bostrom1w4tk9lj8qtx2x4xf4emgrnq950hnlajsxlnl3u", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "192", "address": "bostrom1s8l0akn79kk74g32kf86stfsa08ck9qmm4v6ws", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "193", "address": "bostrom10aqelwndkz9k8uawp26elxep64ayc5rgn24h7p", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "194", "address": "bostrom1ap7zhu5gxlk7n3g97dqehm9nnt3mje3nr5jecs", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "195", "address": "bostrom1j6he98h8xwnt2yp9eczhhuff3k3hvk98gr27ee", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "196", "address": "bostrom1mskldfjlnup46adzss7lukfh3emm6z4lmqhk7z", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "197", "address": "bostrom12ysvrknuwdr6737fnc06v875whfh52xj3ewaf2", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "198", "address": "bostrom10trdf5eyfcmc9graltx4hmpgznhrm7hdz82k2n", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "199", "address": "bostrom1nvr4qa7szsd3e7xfysn946gcqv5wyemlcxmxpw", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "200", "address": "bostrom1wm4026rxqcrkh09k806m6y4lys942etx5cjz9z", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "201", "address": "bostrom1zeg2k7kd8qadmwd3kslwmag3erq7hqxt5aajjz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "202", "address": "bostrom16h7tyj5p69t3r7qasunf938cx2elp38fhqc7zr", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "203", "address": "bostrom1jdmfxzpnqqlhjsju3mz7qsgvvdparw5acx7t62", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "204", "address": "bostrom1smsn8u0h5tlvt3jazf78nnrv54aspged9h2nl9", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "205", "address": "bostrom15kl5tv0smz5h8eewu5hs9mtnusz4dereyqxxtw", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "206", "address": "bostrom1uew6fawa3ahu60tj5kspmr4u0zvljj69q4s3ps", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "207", "address": "bostrom1ezpth4mp3eeqdt49kgqd5ctr69xev6v2gykpur", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "208", "address": "bostrom1avvkajdvmj9d8jpl0ga4scftjykeuhjpsa9kf5", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "209", "address": "bostrom1gd9r9uhd8a5k2naudq4hua3vf3lkwhfrm63qhq", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "210", "address": "bostrom1vrym7t34gs9t2dkd8z849zcymkj54kgq7pdf8z", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "211", "address": "bostrom1lk3yjcn0lvwj9f2dj75m8y3smpq5s5zsnnj3nz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "212", "address": "bostrom1hk49ws6ded79xmwehv7yrw3q6mfj7kulafxqhr", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "213", "address": "bostrom1vx9qctuxswd6ydcv4z5pcuuvct7y9l0nqq799x", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "214", "address": "bostrom1ydc5fy9fjdygvgw36u49yj39fr67pd9mv67ety", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "215", "address": "bostrom1wkjn2nc4v5g3tpjj043wxtmeda90ql3yqqddav", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "216", "address": "bostrom1gh09lmm8flkuu3w38mr4axvunnu6qqlapuwzrv", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "217", "address": "bostrom1m0tjgkrh4td9fcp8nnssu3rfdahzfgdshsall9", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "218", "address": "bostrom1mnfalar08dsvtwutmh43lnhx2zzmq7xhdulemj", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "219", "address": "bostrom1g36u05ehktgw5h5udj8hyudd9057d9tx9r6zef", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "220", "address": "bostrom175tm6fucmk0e29cfgzaud6kqgksy25p884kjx0", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "221", "address": "bostrom1v46pz6ddetfc3tnvdr28ss0l48jhazgynvp3c7", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "222", "address": "bostrom1stfw0z5nf2ncxxtrk7zndpf2dla3nh379egwcy", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "223", "address": "bostrom147rnn0rxqkythj4j9ccq0kytmh7f005rn0a3zj", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "224", "address": "bostrom1pswgrf5ap0kld3lpun5z4x08wh7nmgamd8mgex", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "225", "address": "bostrom1wt9h9wm3zf7yzsy68x7v8p973w02kw8yyurh55", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "226", "address": "bostrom1ucl2c39dpwqm9pp6cvmlazn2tkwavszhs27j96", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "227", "address": "bostrom16w2xwdzf6tzucpwcjjqtg9656a4kkv7g2f6vk9", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "228", "address": "bostrom1hmrxmc27fu4ggdpvpxqtahn6uvtj38vuu77a02", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "229", "address": "bostrom1uwfk6h06w8vnhmyp48vwcpgwncsec8yv3z0xyg", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "230", "address": "bostrom1nuc82t22xgp09rs2tdnlxxgm95pjg5matjwwye", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "231", "address": "bostrom15kdrahda8qcyfa9xe8kt2f737m22x2sleslj5l", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "232", "address": "bostrom1n89a8avc4j7cv75lfsyynx5kazlk80ar5qcdx6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "233", "address": "bostrom19vgwu99fdawejnedgsfx8dmxuc0z4emjf7a044", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "234", "address": "bostrom1s6v5ragv9gg3sq7j3aeqtyy82uaxv3y05hzhh8", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "235", "address": "bostrom1y6huw3naar38u4rtgqmlh9smfu93gszst9tawp", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "236", "address": "bostrom1hqeqy4s039q0qcpayqcyaq5hyyvmph97t79m9n", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "237", "address": "bostrom14h099ukgvp4fm9qs0xnmljzhevrmneq6m6cltv", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "238", "address": "bostrom1xhk0s2ynz2sq3ak3lr4u5gg0da4vyaxkfjhg7l", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "239", "address": "bostrom14z6glatrayal5j53632kcefskyge6ujmgshqfv", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "240", "address": "bostrom14n625exc6ftee3t6tez3hj47lv49amjzan5pkr", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "241", "address": "bostrom1fhj7pkuvwflr7z7ngp2v9tj7g58aq2tjgvqfaj", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "242", "address": "bostrom1l4krahjfp87exsmumzpnrfeaer2gsghpuwhfp6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "243", "address": "bostrom1udal5nr3lz7mg7j7k79se4rz0tsjj8lur45q99", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "244", "address": "bostrom1n55zyf6wlvh8jp4wxqgx4ta283jx0e2n2tutgm", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "245", "address": "bostrom1glgevt43557u6s7a2q9q40kzt8myw4ngcv6wr6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "246", "address": "bostrom1mj0sj4eaar5qnjn3l05ep5wgq3l6agtvvqwvyk", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "247", "address": "bostrom1sm9sq4wnn62tk5yz0x3fvvx2ea9efguqwvdu64", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "248", "address": "bostrom190y8vwhmyjdnk7cfutcm7u8haw80xyejdwxsql", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "249", "address": "bostrom1rfh303jsl5297sxgs5txpt97lvxpjt4he3yy5r", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "250", "address": "bostrom12u6qgyrdsy4xmw04vfkkkh9a9tqzw66g59hudt", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "251", "address": "bostrom1pjvkddp4fmx8ym5j7s7su8kn3zuqj255djzpja", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "252", "address": "bostrom13nrdf490fsuv4rwjp02hlyvalqjkn5u6xxqvqz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "253", "address": "bostrom1fp9q2t9zn9gr5qjh9wljxuavtcsc4h8uqgnm2e", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "254", "address": "bostrom1u2s32xsws9y2sskz6zvn7lawepdqxad5dcsyy6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "255", "address": "bostrom158mysantvvk7x65tfhhuu8q2va4ls34r54hk78", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "256", "address": "bostrom1clalfxmsrqdgnqq5uxlx0mc983pyp3wq4xl03c", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "257", "address": "bostrom1wf8alywyvlxy2dqfe38efdpdmuscfpf4jxvg6r", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "258", "address": "bostrom13zf8kghx7h5fyttk6xdnjqn9c87z0rd36sfqjw", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "259", "address": "bostrom1cc43k76udpd3xvpn6md76zz3ru6nvcnreeg2eq", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "260", "address": "bostrom1l5x6kerswths5xl0d6672y9yyn9mg2vw8yz59q", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "261", "address": "bostrom1qe4sguqg8ztlyy7psf7lzwr4ahph9j36k5hltz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "262", "address": "bostrom1mn8ev805fde2xswght0snwfayfj9tn54dt24zg", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "263", "address": "bostrom16vc2mjjfxx2h5m6jpdp4nqfu5095qaeeq27qxj", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "264", "address": "bostrom1jmhqgld7luvuhh42wac24z6nlggjvkc7fzgs62", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "265", "address": "bostrom1qjknpllzp6w6qsxxjx52zxald29wpyzljznzdv", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "266", "address": "bostrom1eq2h9enjxsg5s08scr69lzwde8fl79snw20dc8", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "267", "address": "bostrom1dx8mvxfu6mpfnjehvdkp9lsvu78ek2gjr7r766", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "268", "address": "bostrom19uryr2zuxcfdevfq429jng9a2evxwadlsky04c", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "269", "address": "bostrom16862syzdtc6h0sxz92jhnjjas5yhhjgzvyewwd", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "270", "address": "bostrom1teuan269feyw4ax94jfp4pcgrhqnn28gxxz8mw", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "271", "address": "bostrom1yvlp9gzqaufwz02swp5wqsqhlmfcrcl8m22gzm", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "272", "address": "bostrom1latzme6xf6s8tsrymuu6laf2ks2humqvfcz7m6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "273", "address": "bostrom1ec9da8avgv7tnvsx3v8g8veqrhlqq26lnncg5t", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "274", "address": "bostrom1c7pv6zyza76f3yhv0zvjc042e8m7w796qmvkse", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "275", "address": "bostrom1yslufs9kq762qty0wh62c8qtlpm2202ejmw4ef", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "276", "address": "bostrom1y935ede6znmcvqdmn6mnl2aa5zxcqvvracsczu", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "277", "address": "bostrom1y675phjdvw576ahlcmlamrzr28rjht9mx709lg", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "278", "address": "bostrom1kjhdx3nkh6krdhryvjzkq33xwh6wsyy7y8ark6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "279", "address": "bostrom1jxpe7neu764uasz5y5u4lrr5jtltv430gjm9dw", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "280", "address": "bostrom1hq8d6pu2l6wkrwu9jxcqjcu55g8l43zxmrd6dk", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "281", "address": "bostrom1c4h647a9rj8n9zye5ttmh9chpg66f3ffdvdds0", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "282", "address": "bostrom14ysuwg6p4fzfaa6tg4s3hazu86pfevsw4cegce", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "283", "address": "bostrom1x7wp0u877dkw7m84jv54c9g6zpd5r8t2nm47gn", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "284", "address": "bostrom1gss7y04dky2fykck4dyp0pe39wxawlxm2l0yj2", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "285", "address": "bostrom1cerh237zd5rdexptjw8ryhwdf2tc9eupz7sfn0", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "286", "address": "bostrom1fz799u9jc0umceng3nkjt0njxy6y3550uq06jn", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "287", "address": "bostrom1wzqyjejz5px38vgqsegafrcexl3963q9dsgqh9", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "288", "address": "bostrom1evz2xfd6sam0kzz5qc5lje4s90vcgyyrzz47pm", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "289", "address": "bostrom1mzmzlzk4xpm6zy68c43e6hen98w07yhfedumgg", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "290", "address": "bostrom184dur4s6pldvhvcyputu6yshsm09s6wmvylt8k", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "291", "address": "bostrom1gyhwacrpqwues05pkavw7xwehcqsmgruy34zps", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "292", "address": "bostrom19wtkh935tx2ut2n4m6tjvkfvew4shaeezfl7em", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "293", "address": "bostrom1a2kn43nquua6gmr4n42htmjpceqj7fzushe28h", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "294", "address": "bostrom1u74s0z4ft63c6zz7g8xs62esdtdjkzuk4zf0rt", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "295", "address": "bostrom1d9en5u0cfaucavx848qeq4k6ywqd3z5d5a778h", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "296", "address": "bostrom1edwwsevuywe3sx82sustvyx3f3cvjt44ugccgy", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "297", "address": "bostrom1gcy4f6f2sc73aegd9r68rt2q6teekl6swjva3p", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "298", "address": "bostrom1d6nkeqxmme3564wd889kr6cjed3asxqzjve0wl", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "299", "address": "bostrom1djdfq5mn3dzm9whpznczxz77s8ep2qggc5w5xn", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "300", "address": "bostrom1z8fyzv3mjfccvrxhckr2u3lnc0hrgrlm4zkf8c", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "301", "address": "bostrom1tcnlvf6qhlc3x7ax2vk3vzhxhf8wy8xrnjl72d", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "302", "address": "bostrom17ud38eyfkd800kvw3c9kl3zpvgvj296nfszelr", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "303", "address": "bostrom19rtverjn8kw7dzwzch2elktxgcmak6dlqugxfw", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "304", "address": "bostrom1mlqakhlxplhlezk80lph99wcy377j9dk2qx3gg", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "305", "address": "bostrom1ssu4wqtzvvmwcukcv7l8zxny647mdx03e0t57j", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "306", "address": "bostrom12reh000lje8y20wshqmgl8tg70qggt2ac7qz45", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "307", "address": "bostrom150svyax8m8dwljwenc8xxtsg0avud07m5frlrz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "308", "address": "bostrom14tjwqqyha0c9r0s29dm0n0zdpdc4hfrvn7jqsq", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "309", "address": "bostrom1x8r0ktn36dsxsadnp3863txyd9pksrp6awcuaa", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "310", "address": "bostrom19lsruwa85k93ahzkdwaydyrl6ehz9dmmkava0y", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "311", "address": "bostrom1tyzmkpn0axquu4jlht3lllsmq03um8kn5cu5pt", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "312", "address": "bostrom10a9mqy8cu04nyz3nj934ck39p6u9ddjt9y5fve", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "313", "address": "bostrom1f2uslv6udnjwyqkdngc7rswp5vkmgavzgy952g", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "314", "address": "bostrom1t7gw3d2jz4qc6k6umgkazvfyeydjv7l6nym265", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "315", "address": "bostrom1rc2647d9nftgwwh9n5vaw26lnjdrewc4dum68g", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "316", "address": "bostrom1zejjt25xw9gwvhave95ykkvgqjtk7j56fe9cwh", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "317", "address": "bostrom1vesdfkzd36m08clhvkpusq4gv0dnqm28rm2hey", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "318", "address": "bostrom1ypvt8rf8md7qedvnk0p8cvd6mnffepst8f05p7", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "319", "address": "bostrom167hs9ma63wd02xym0vjw80uqlekt0cs54ass6v", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "320", "address": "bostrom17tksas9e4nkp25vgwcsd7z6y83pa6u7sddyyez", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "321", "address": "bostrom14thj9udwenk5q8c5ey2urude2j54xud2a26rp3", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "322", "address": "bostrom1y7ku6vf9vq53pv4y6lw2zjn4d5ul3javm92whz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "323", "address": "bostrom1mzn966mlprxgkvayrqu209069px0qwz7gzn799", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "324", "address": "bostrom1cjeg60652ueyu5222l3atmm8vrhlq4tfusnswk", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "325", "address": "bostrom13855g4d5pfhtnqemgp700qs36qpjdnaz0dx2m5", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "326", "address": "bostrom1ueywgan39tj27pdysq0d54cqvcwyggf6eves07", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "327", "address": "bostrom197h938dvw52kzf2l7gke2u5tcz3grvlexeaq0y", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "328", "address": "bostrom1pkxtd9xwmqwg08kjgz9xqyee3aw7j8upd89ah6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "329", "address": "bostrom12arnsa069zhad0e40mlgy034n7aq77e2nxdven", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "330", "address": "bostrom1m3yh7j0jefp9dl26cz8fqexfg8tds39lh957jw", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "331", "address": "bostrom1ysn8jyjv464fv4wpt40vezh7d5tw05tc9v858t", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "332", "address": "bostrom1gh8tenvx2sf9kj2c359ey6s5k0vzlrl7z4t59z", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "333", "address": "bostrom1svwchckmrrkfl7py7l2fz3esla7lwmalld4yr2", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "334", "address": "bostrom1hmdjgtv3yq4qzyuk3ynyt42sjntma8hqarepjd", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "335", "address": "bostrom1wr0mqeyea45u9av63srtvgr553nyg6l9p57ezr", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "336", "address": "bostrom1e20dl8se4v2ev79qcay3ag7uf5t98gampz0d48", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "337", "address": "bostrom12c8kh7aaz2gg0l4nkd73t58nhurdaren55atua", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "338", "address": "bostrom1ftyx5guwf39fz4nc5n5nc9fua36cq344rm2d43", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "339", "address": "bostrom17jq8ev7n4e3zv8zdek5mccvxcgxxtkwva5vwtx", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "340", "address": "bostrom123wttw3lu62m7lcg23rkwr88cvv8apjmvkuj9f", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "341", "address": "bostrom1j5wpswepyxva5vupvg05pq6jzqh7ttdvepkhp3", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "342", "address": "bostrom1wh5gfxyz8x95qyjlc2s24h3czr60vfehwt49xa", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "343", "address": "bostrom1z3u9w3vyq6sw7ndxcdpjkgvlj0qaqm6spc3jmp", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "344", "address": "bostrom1pzyt3y68zcnvl7hkvuffqfedccaptf6nt2x8ya", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "345", "address": "bostrom1pzxnpyvxr6x9z64y6w3ctv0cvcx9sp90ehj960", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "346", "address": "bostrom1pvu65ccqw3fmgq88j2j485wc6qm96nx7h7ln4f", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "347", "address": "bostrom1nqxwnut0hdgsn3l9zaladaft5xt9c6ex9qquza", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "348", "address": "bostrom1njpfrygstn6r5awzp77keyhkl3wfhzmvdz2pug", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "349", "address": "bostrom1ke9xxd3d6y0ttduac062zvv3r0jtakvhkvqcjz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "350", "address": "bostrom15ak23s0usm36hv2e4kajhe0yx592hw474p3gkq", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "351", "address": "bostrom1gffprg0nuvj9ve39s9rjhjp04u7k8xwan2tzff", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "352", "address": "bostrom1yq5h0gjxuup83hdz53utukwhkkz684mk3lx7cr", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "353", "address": "bostrom19rfaqnnz5fy3qct8qxzany94t2p7h0rrc75lmz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "354", "address": "bostrom15y8g5ggq2lslncdnlcscqygyesefmjy0t4cae3", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "355", "address": "bostrom1gfkztltd789py02jcd79dnkl252uej7x8pnx4p", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "356", "address": "bostrom1h9k38zr5a532jzl0hsker9qz785m822zmqw974", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "357", "address": "bostrom18ghdg8y5hx6esxm6ndw3ywgtalvkmz48zeyc6z", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "358", "address": "bostrom1zy3nxgwtw9hr99tzfaxasgwklm9ev843fju9zl", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "359", "address": "bostrom1vmfs06hv80gc8jcpzu93ld4494azendxfalh2g", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "360", "address": "bostrom1d66wegxpllcsnrzv9saqugpk2dausa836qlqaz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "361", "address": "bostrom15njl9exppdfms5fg4zz9wafn4a95lfj30ftx58", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "362", "address": "bostrom1v2fzs3a8mvm4nhsfcpk85gt3d8rdacv6zggl9r", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "363", "address": "bostrom1fm842pq6zxaqs86fm30xv459gx7hm7f0ufujvz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "364", "address": "bostrom1rzr7gnkm3kdqmzqya7ky98m8tnnmtet58deav0", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "365", "address": "bostrom16gtt4cmrvg2us2rgecym9zt65zet7qq2euzvdf", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "366", "address": "bostrom1jsdfjw0pjjj5thg7z2tpm30njusrlsagtac7rs", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "367", "address": "bostrom1z33aen2znsmgy7wwzavwh2q0u7cu4e9xhky379", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "368", "address": "bostrom10r2sn7sasanc0tuw5wzupxvlpht5uv267her62", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "369", "address": "bostrom1gtma98yjsx43zc30j99t7t0tmdjt2gyp9e7g0r", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "370", "address": "bostrom185y3kgv3e6t4sue0a55jyq88hv76th3urnca4c", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "371", "address": "bostrom1xc6jdlqd8gd9e6p73xdc2yw7ad3tnl8w7j4wsl", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "372", "address": "bostrom1wdk6rndatlj8dpxq799vmu50zft7xk5768ej2v", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "373", "address": "bostrom1uz3xp4au0rxawmct6ffj0u3le7uglyza43appc", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "374", "address": "bostrom1uym8hd4pum4zz2mpkf93y8435u725k97e2c38p", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "375", "address": "bostrom1u8yt9tvnwvvvlm36w97nyg27ue797hrvkz6eux", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "376", "address": "bostrom1u4427txgc9pulkuu0wk4v9cjxqa0dxee5az972", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "377", "address": "bostrom1epcd5upewwa7s20u6kgf9uywa2f7c3yj6zaeg0", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "378", "address": "bostrom1tx6dnqh0nnj05uuell7rhnwhennscehlnjylxv", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "379", "address": "bostrom1ypzhtfsyuejekw0w0z207wyedqm3xqafc8nu7g", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "380", "address": "bostrom1s4ytylknecgkp7sp3jgf2f5lj7mm2xxz0f9rl3", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "381", "address": "bostrom1s05hsv6fxhkpclwxzgnlfjjk7qdm78nmpchj08", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "382", "address": "bostrom176q2gvutyk63dzknylcvdhp6lyjwu5w9fdmmev", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "383", "address": "bostrom1e08w7wrjn05gl06xkwnlfmud5f6trdkrf0drg5", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "384", "address": "bostrom1pzp9nadejsjzfkpfl9k7ktu2cfhprw4r7qvd5p", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "385", "address": "bostrom1pt3a6xk432vs8lp0z6ya3qhqhxks99xe4sxxqq", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "386", "address": "bostrom1damlfdlp8yynjvrmv6pd3t33f4currrhe4cm4z", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "387", "address": "bostrom1cmhrs08sqv0823mj057svp8jerp6avne6xmtrc", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "388", "address": "bostrom19wlc6vms3qkuy48wgg2dl06veahgxl47s8859j", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "389", "address": "bostrom1h9zrqgwcjtul3s9qxf0hk0ym9alm44ztywkfyj", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "390", "address": "bostrom18fudz7p6ah9yvdr4p9aflp8pgzngx84cem5lra", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "391", "address": "bostrom1e8dsx8yx9mjn8v8egz2n5vafkymqw98wy4z6re", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "392", "address": "bostrom189tpr8vg4qvwn7fgs6szkqr25yrammvvlzx0zr", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "393", "address": "bostrom1xvsukg4tltfzduw0lsvgqyrhe6rzrlp472ln92", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "394", "address": "bostrom1w7f07762zelhx4spzkndmygh2dz58g3nn58v7q", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "395", "address": "bostrom1808q4nv5qafkk8ec9h56wwth6sl5a5yd0elve6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "396", "address": "bostrom15a8z9l8ufw8v8zdddfhesnmfzwwhua7axrmfxl", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "397", "address": "bostrom1undz2328av9agfhaguqs8zxzejv5zqcc9grdmv", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "398", "address": "bostrom17vw0qcu9j8t6jhh83sjrzj07nwg9nndfcpw9g0", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "399", "address": "bostrom1evnwfeuqsgkjwe5qwe5acyy6m4w5ch03m3e7a6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "400", "address": "bostrom1t5r4uhu0tscqw380t6hqmvrgyhlrj3u43vsm43", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "401", "address": "bostrom17kwvcuvar02ldacltr48373rm74z8lfkcq80vj", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "402", "address": "bostrom1r7grd2sazgzsy8y0c8wlsnjyhdc0sq4npr0v4q", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "403", "address": "bostrom1pfwja2fu2qcqvdws6rcdr9y6za46dklaxc83fh", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "404", "address": "bostrom1p4uyyk8sc2arl4n9egw3xrn9g7rpkzlerf4nlc", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "405", "address": "bostrom16gxdwa79rsvkjaawpcpswthgahm56p4mpu8fe9", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "406", "address": "bostrom13nef2p2g48kmj83m7f0ey76q6p9cdyrn03x4tz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "407", "address": "bostrom1m9x4gg6frezyeqldxdz4dvegxpcytxnapgykwu", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "408", "address": "bostrom1kfz37afuxfyajrzk7xv6937xc0jsq4zd0ce7dz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "409", "address": "bostrom1kae5k3nnzs3q7tar4ec3w29w4avd8saqujpjk5", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "410", "address": "bostrom1hjjsjgv7sx88mxfq9y44ql24xs76jj3w7y9ff8", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "411", "address": "bostrom130avjyegx7glgnqvraetqj6ztacrqv9kdwawkj", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "412", "address": "bostrom104rtaftr9xmx6dcakempk590tfxx4ytddqcj97", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "413", "address": "bostrom1f6tmyjffs0p7f6xeh25esjhawxu2kll9j00a47", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "414", "address": "bostrom105c5jk0xwzlk4pexgaeqkxq0xadtqchc4lmev6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "415", "address": "bostrom185tek8r0ptelug0erducctzc4d83q5np3339k5", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "416", "address": "bostrom1z0m5tcv4jde5acv0w4dms537wvntgj7x47zmeu", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "417", "address": "bostrom1fzkp5pux48ux72wsgls9lhxp5cq2tqsy32hfec", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "418", "address": "bostrom1nsffk0nt927vn7pdsk8epzjeqch3yfzkzq57pl", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "419", "address": "bostrom1e4cnw86pl73k2sfv7uwauflfl42qzncn4akyv7", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "420", "address": "bostrom1jlu5u2sj0afddmcj7lxfy0ng466s8l2qdjz24v", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "421", "address": "bostrom1y9tvvunr7uaqjjw8u6xn5muypq6pheyz5gygm3", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "422", "address": "bostrom1qsm0ujra4vdwymc5vrtey2rvalyq8392h75nr4", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "423", "address": "bostrom1jgvy2vr96auye3er6n3tkhlu9hnxs6h3a38rpp", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "424", "address": "bostrom1jcj0w0e2khy0asm7dz8883xnepzmaxylwez7j2", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "425", "address": "bostrom1q22fvnhna2zg2g2xm6s5587w8fvsh2zzfeey68", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "426", "address": "bostrom1amletsu7926696dpeay8wrewqgww5s7yunjjxr", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "427", "address": "bostrom1qkltelhy5zsr4kfrefvwsupxyt6y9skwjpd7h4", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "428", "address": "bostrom1nfdyvvjy5hum8gpgmt29d0m5y4te3ekpfyz7pw", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "429", "address": "bostrom1hjz37u09vws084cvwjlr5t27wmsrzm9tmfspu5", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "430", "address": "bostrom16zykdjnfjdy5cy3phuymmcghh8x24eah2cmmpu", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "431", "address": "bostrom15pax03gsgw84lsygpxyyvtthd8fswrqp7wjs7m", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "432", "address": "bostrom124ll3q05an955eh26ygn34u5gtm9287arjrgj9", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "433", "address": "bostrom1teyn0utv6yhnwux44ycfvqh6z888pvjaz9cz6l", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "434", "address": "bostrom10905rstxf5tzj0w6gguaa76ma7s32v48um4w9z", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "435", "address": "bostrom1m7y6qezuemqe6n535z7s80ee8zw4zg486vr53u", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "436", "address": "bostrom1pkhgpslggp3t0nrwskvgczxmavg7yejfullesx", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "437", "address": "bostrom1zyws7rajm9f3ql6jqqpzvnml0aym9vspd7tjxk", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "438", "address": "bostrom1pa0rcdua5v9d4vf09ksnnl7t96nfkf3w37k4dc", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "439", "address": "bostrom1durjade4he9l23rw38azruzfttpmc8223n6r87", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "440", "address": "bostrom16jvmfza0q60umemx2pv8s5kle2h8g9x6jj9fkq", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "441", "address": "bostrom1gywad2frusetg26dyh83cfaevacravashyjwg6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "442", "address": "bostrom16kqpk5jg9e5ucxv3e003mf48yuamw4ce5ww4la", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "443", "address": "bostrom1zr9urr3m42w7pu5h5xn7rvghcdk5vtrtmfw7wf", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "444", "address": "bostrom1jet9jf456dja8vqlhk407l06yvfehwzuvjaynv", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "445", "address": "bostrom1q8ajen3vu5v5uu4czkvqasqvw827dz2nqq6d0s", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "446", "address": "bostrom12w56mhf4nsfchquw0sgzwn72qkzvfvquxhg6dn", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "447", "address": "bostrom10v8qjj6haddx7wmnr65mcsllu8xunkee7zg3z5", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "448", "address": "bostrom1hy8dexwz6ynlnnaj8ge7jvmzs4c6qmz6yh97lc", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "449", "address": "bostrom1vpp9vy0fnxxw8yk5t2cctutpfv8pprvyhnjw90", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "450", "address": "bostrom1w0u83ty3nmflg9846zmh28u0hweccs3fzfpx0f", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "451", "address": "bostrom1z6lhk6u25fceqylmgv65t5py0c8kclgkszmqyx", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "452", "address": "bostrom1zcf0ph3k4p2q2pl32zqspy5f7jkgxd5s4kcd66", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "453", "address": "bostrom13s4egz6pqg6a88dunme3esuee5w7qlkjttcs08", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "454", "address": "bostrom12w37894jf7rt2ck709rk8xa23lz3lg9tv93tlz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "455", "address": "bostrom1sntt4y34tghn45vw97az7mz4vkcw8kgregkph7", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "456", "address": "bostrom1pa0lcssmjkkycdvrhhzey5h94v34wuf9u4ths6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "457", "address": "bostrom1l9yx676futn4h28rxupsvk7evl9s68hrufetdw", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "458", "address": "bostrom1knpgev72f2empt8j8gcn24my8kdasy2lcezjea", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "459", "address": "bostrom1clr05sms7eklm509ger6jdzhgheafskv4wwxrg", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "460", "address": "bostrom186tpdptavhzz7fg83vnm4r2y85cfqyg6sntmun", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "461", "address": "bostrom1qc4t2q45f826cfc7k0y45ma8f5qrrfv2nkly33", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "462", "address": "bostrom1n0wkta56ktj93nzpe9amkgrzq7rhzt3gy6m8uh", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "463", "address": "bostrom1exul86z68fzck5jra7jp8xdwvmfz5p9qyuh8um", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "464", "address": "bostrom1melp9r22clnjzzudd0thvs5zzveqfjyl9xfw54", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "465", "address": "bostrom1zx70t5xqc8h4kmvrssdc2w82v9ksw0r82a99av", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "466", "address": "bostrom17ssaukj47urfj6c8cgywyz9xhgqz3tnpy7n5kv", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "467", "address": "bostrom1znt56em2psvx8ylfpplcmpy5esrea08g2psvxm", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "468", "address": "bostrom1tz4yrvqlw87e74n783n0da4pttay2ypsfq6668", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "469", "address": "bostrom1prrtyfgrw2tzj9kua5eu7tnctt474m36eygux2", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "470", "address": "bostrom1ftkw5j528j94cajk4rvqum3k7mhhmpvyc8k7yg", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "471", "address": "bostrom1pe42d4gkg7smf9na6dvh5twq9hgczsag4elx84", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "472", "address": "bostrom1nscf69wvc0wkgqm8ma79qv8cr6j6zq3dt0t898", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "473", "address": "bostrom1exv982mrkyfd967xv7fam7lq8h3ce3dvcnd4s3", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "474", "address": "bostrom14q65nd2ft893dagpln4fq39wutv2xmpe3kc4w0", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "475", "address": "bostrom17llhhwjmglhhqumz72e4jap5cj39r8rwar7zzv", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "476", "address": "bostrom15k9z24v0thrxffetjp97493ec89zlz7re07pjj", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "477", "address": "bostrom1y795vkzvczrauey63vmvvcjr84l3fjheqd8f38", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "478", "address": "bostrom1qf560sekun7kjsu4r0puey5u4fn90025f4q2p2", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "479", "address": "bostrom1v9p7ukxpw2yjk7eqm8720vkgqq5qlk7w3jqgzu", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "480", "address": "bostrom1a57rc9cnhdn4l843ca4990aqldh5wmq0uuetzg", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "481", "address": "bostrom1q2ajajyu0t544tudcnvk7xcznerhylz36p5vtc", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "482", "address": "bostrom1ayc0pueqve9a3xjpgwh3p4l6hjlyvfpvclvldm", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "483", "address": "bostrom1jmdtfuxag0deeuyxmj4ge2mqhvc200hlmzyztf", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "484", "address": "bostrom1k24kf4reet2lstvmkx9a4j0r87xfuqeqh2lprz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "485", "address": "bostrom1e0c3ehnfzvcxvwh9fgzyfc2vqshy9w53du7hnv", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "486", "address": "bostrom178nsekn4qcdkqqmv95qlmp68kaqpga3zpsdnf4", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "487", "address": "bostrom13uz23f4stcg8esqvvc7d2w9psxv0dya5xaq5ne", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "488", "address": "bostrom19trgcp8uldtc5xtnpf0u7x7dk3t3jcp4y7cusm", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "489", "address": "bostrom1fn4ep44ud3edyh304ta38f55xd6pxswsw9e23z", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "490", "address": "bostrom143dfs4ur5gjvwgx8l54jjz27rq57us0zz3hqj0", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "491", "address": "bostrom1e3je4h3vkxywt2sf7mudelhf6zrx405yfgczkf", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "492", "address": "bostrom180upuj8yp0326px2uys9r60xrlhpsa6fwryf80", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "493", "address": "bostrom1jdypscylf6hjlrlva03tx5vqqkcdnllg6rpza7", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "494", "address": "bostrom1r85972mwrka5w9ct6km58ww9jl9sh46fx559fu", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "495", "address": "bostrom1xz2dkqrnrvq0ezc0vxtcvhwy39xr63vxzfedsr", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "496", "address": "bostrom134llrhdus60n7853fn3ulmx6uy7evsx3ltzstt", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "497", "address": "bostrom1pv5clfxxfpqvuerquue2vgr2ndgh0h50jx898c", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "498", "address": "bostrom107v45crxqedhmf4yqa9y98v99wm2078fwtklsq", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "499", "address": "bostrom1959r3zp37k9yuz8kjtc4feayyfkkxpcv43mu0w", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "500", "address": "bostrom1qh6eavdzp5ffks2rvd5mjt3rdmjxg3qm5l4pw2", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "501", "address": "bostrom1lk7m28npegzy0sz5s06sy95n27yzrj4d3rytdg", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "502", "address": "bostrom1clk49u6rvv8c40udn9qgp0s8hv5uvfcgxqptky", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "503", "address": "bostrom1gws6ulm3u23txc6p8kv6ew6e2zn45udrwjkdqm", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "504", "address": "bostrom17rg7cldfsqfmv53n6r7qmjmcge7ucxx2hhum0q", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "505", "address": "bostrom1kkwwsk0v4h7tmccr4sdmpyl2j2gvfah6jzw7n8", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "506", "address": "bostrom1ggh3zff5paq5c3r2j34mquq9lrcc7s0nvfnuwz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "507", "address": "bostrom1gp5s4tetnk7ng49g58uhn2znfpmgs4cfdq4ns3", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "508", "address": "bostrom1ejkkddkuw63zn557l0lvqq3gmjcra53ealmy2x", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "509", "address": "bostrom1jrp04lvvpzkyylr4l7e5xp256l9yd4hdhrpmls", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "510", "address": "bostrom14c8rllqzmgyrkt8aeyanprl7g3adrlc2flq57a", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "511", "address": "bostrom1j39uxls4clq76ej7mk2tdskvql2tdp2zek8g89", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "512", "address": "bostrom1qcy673rd8a27t48ry6evmv6as7fuetd8cyhnjn", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "513", "address": "bostrom12d3klseftxsfs5xmvjju339enk8xcvg5y55qvl", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "514", "address": "bostrom148g7gmqvw5gfj7dmpjymtsw3j7gvasflqrsyx5", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "515", "address": "bostrom1eur22ds9gn06lgg9j3raqlzj8j2qzxx6vuje4x", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "516", "address": "bostrom1809klqrjjrs8ch2gtf5hmmfhysspkrr894rmhm", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "517", "address": "bostrom1f9nx8jrlx9pvns70edanu37mxtm359k606qyds", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "518", "address": "bostrom1qgkdm2asr0qey7jafqyqlnarvgndjws23fpkrh", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "519", "address": "bostrom1r5gvlzt03a0a9rks3s57cppmfqx2lzjrquh3d0", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "520", "address": "bostrom1yaastlp99jvqta2x5fngdzw6zur7khctd9gk3x", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "521", "address": "bostrom14jhjmhm2xmx6wyefju30auqvrs35hmnn2m8ewl", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "522", "address": "bostrom10pqp6py9pqtagyde9tnkkvakg3gqsnq7lgzxnp", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "523", "address": "bostrom1spndx95pckqnmjss6emff6fyylasg66qzdfv6v", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "524", "address": "bostrom17qkfq2uwags5pzplrfqg2elhn9s0pfwja4mgeu", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "525", "address": "bostrom194097avwy9a6h0cvznev232z28h96rp2q3w3uc", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "526", "address": "bostrom1l8hx9jxul439uyjve4zn45nujtx9gmrw3za3vs", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "527", "address": "bostrom12zmexhujvw7j82la9uslzfl5g29erpysqt555s", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "528", "address": "bostrom12vexhfe4m9p9szsqvzsalssf8sxluj6pqx8gr3", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "529", "address": "bostrom1ukgaegxryydqckt6fgrt60dajxq758x9pntmhh", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "530", "address": "bostrom1756xr3jtsdve6vuwqgqdtmt6ws3td49gq7vc77", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "531", "address": "bostrom1fn5cutfgat9s9z6nz5ucnnq9aec82wvqpevsn5", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "532", "address": "bostrom1e63p9zdn5xks5ge9gj2y9gfkl5u0jgkvfrnhzl", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "533", "address": "bostrom1zq9f4eczclr5cexrxdusfxxr6eumn2rlg2h4hs", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "534", "address": "bostrom1sjtl9n7fqszta6p4w5y5yl7d4xqth26d8z2gjj", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "535", "address": "bostrom1a4krl6m7jg7ckczk94hh0wdlcezvpgwcwkrpcg", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "536", "address": "bostrom17lzmvgnahdncwnsx3dr7mss65qv6l9md2hy2qq", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "537", "address": "bostrom1pljwxmmkhfrkzkdpmdjv29t6959sa77mjt0xz4", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "538", "address": "bostrom1t9xfg2kurjlvnw86repcpte3shpgasdjge6a7t", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "539", "address": "bostrom1erxn6kmz3xhfrv40m7lyp88v43qahqn8fy2xhn", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "540", "address": "bostrom1k879z65mwwwu4jause7galz0hlsqqj4rtah7r6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "541", "address": "bostrom16dsvdl4jer9jyplelgz4x68hjvg5k647nrnc8z", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "542", "address": "bostrom12pafl09rqzcw7d77qs63pg2nlsgvc3dsfxyzum", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "543", "address": "bostrom15cq4l7d6v43rtv493cps3c7tpsf26d83pseqwn", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "544", "address": "bostrom1wrtzl04mxs2en94ysc5p8mvqc5p0culr9w9m0n", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "545", "address": "bostrom1a2zr8qx60sl3srh982hjduse0l7pdcnhtl7juy", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "546", "address": "bostrom1r82whjffalh2hgmrayywc9g53es96n9e9893yv", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "547", "address": "bostrom15884n6qmrwq8gjuwtqh6q8z7vx500n5s3djcv6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "548", "address": "bostrom1nhkl9r84zjucmjswhddwq8zgpun5yks5mjk7xc", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "549", "address": "bostrom12cq4xxcr6pmjz320aj7j8pn9l8vjeed63slcz5", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "550", "address": "bostrom1fwx3u5w8qyzp8msv2n9umajgst86dnuqrsft0g", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "551", "address": "bostrom1zg3xqymyrvlu5fmmyx8htdm84kqt50t7xdfmuj", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "552", "address": "bostrom152xtf7tvw60tyhls32wwc9ypehqzf366zjkeeg", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "553", "address": "bostrom1uspnj6pvq0u78d8qux8lz6p24dzm998phldqgv", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "554", "address": "bostrom1ppzvqc7yf9lfs8cljqu6w992gct6d5h9jx5wsn", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "555", "address": "bostrom1jn8cp663fl0mv6k55xvy2lr6s0r57zg0v6gzr3", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "556", "address": "bostrom1fmpuldfmgj0a4dlkn0cdlap4h3qs7nljyph4rj", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "557", "address": "bostrom10mja0qpcq6ze2nrchhh7w3n7g589sdktfu7p9m", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "558", "address": "bostrom1kaaxhzud2ev7v69kwkf8vuvhst9a36wz5l424q", "pub_key": null, "sequence": "0" } ] }, "authz": { "authorization": [] }, "bandwidth": { "params": { "recovery_period": "16000", "adjust_price_period": "5", "base_price": "0.250000000000000000", "max_block_bandwidth": "25000", "base_load": "0.100000000000000000" } }, "bank": { "params": { "send_enabled": [], "default_send_enabled": true }, "balances": [ { "address": "bostrom1xszmhkfjs3s00z2nvtn7evqxw3dtus6yr8e4pw", "coins": [ { "amount": "115880796057845", "denom": "boot" }, { "amount": "115880796057845", "denom": "tocyb" } ] }, { "address": "bostrom16230lc9r27vrxlzd4wlvcz2l66quzj84vlkxc5", "coins": [ { "amount": "10000000000000", "denom": "boot" }, { "amount": "10000000000000", "denom": "tocyb" } ] }, { "address": "bostrom1gxhs5wzam5rlgf6cs0lkme400ut64d4ncpfs2h", "coins": [ { "amount": "10000000000000", "denom": "boot" }, { "amount": "10000000000000", "denom": "tocyb" } ] }, { "address": "bostrom1qs9w7ry45axfxjgxa4jmuhjthzfvj78sxh5p6e", "coins": [ { "amount": "700000000000000", "denom": "boot" }, { "amount": "700000000000000", "denom": "tocyb" } ] }, { "address": "bostrom1ha4pw9w2qgc2ce9jwfrwrmaft5fneus58nqwev", "coins": [ { "amount": "50000000000000", "denom": "boot" }, { "amount": "50000000000000", "denom": "tocyb" } ] }, { "address": "bostrom1qn8sr2hzmktlecusdtxj9hwj0upnm0jft9snar", "coins": [ { "amount": "10152301267211", "denom": "boot" }, { "amount": "10152301267211", "denom": "tocyb" } ] }, { "address": "bostrom1d8754xqa9245pctlfcyv8eah468neqzn3a0y0t", "coins": [ { "amount": "360239818444", "denom": "boot" }, { "amount": "360239818444", "denom": "tocyb" } ] }, { "address": "bostrom1ttd4h585vgy29gj0xe0p338drvw9w4m4hzwj9p", "coins": [ { "amount": "4000000000000", "denom": "boot" }, { "amount": "4000000000000", "denom": "tocyb" } ] }, { "address": "bostrom1ngd5w7j4u5ar5xh7vzuwqqznnhhcjmnz0s6kpu", "coins": [ { "amount": "1000000000000", "denom": "boot" }, { "amount": "1000000000000", "denom": "tocyb" } ] }, { "address": "bostrom10c8znaj94y900syues06dz50hw6y9qpkhunn25", "coins": [ { "amount": "1400000000000", "denom": "boot" }, { "amount": "1400000000000", "denom": "tocyb" } ] }, { "address": "bostrom1jv65s3grqf6v6jl3dp4t6c9t9rk99cd8yvs0hc", "coins": [ { "amount": "50726497621325", "denom": "boot" }, { "amount": "50726497621325", "denom": "tocyb" } ] }, { "address": "bostrom1pntx8ql2v7cqxu05etg8c4v0r2vz7qnq9uqmpy", "coins": [ { "amount": "4000000000000", "denom": "boot" }, { "amount": "4000000000000", "denom": "tocyb" } ] }, { "address": "bostrom17a7xxqa4drnalvv7pkxrkxqer953fdke3ulwx4", "coins": [ { "amount": "1000000000000", "denom": "boot" }, { "amount": "1000000000000", "denom": "tocyb" } ] }, { "address": "bostrom1s4czxghmh29aw2ldynk8r9lnkfccw5ph8rjpxa", "coins": [ { "amount": "4000000000000", "denom": "boot" }, { "amount": "4000000000000", "denom": "tocyb" } ] }, { "address": "bostrom1s4wntr9selfaznc2ezjkwnwt2y0terx9tqpda3", "coins": [ { "amount": "1000000000000", "denom": "boot" }, { "amount": "1000000000000", "denom": "tocyb" } ] }, { "address": "bostrom1qwzsnnuk2u6avvh059c9p50gqqquvcu5svvwrs", "coins": [ { "amount": "4000000000000", "denom": "boot" }, { "amount": "4000000000000", "denom": "tocyb" } ] }, { "address": "bostrom1g07gj9ph0r2hjx6ffqn8vl38u4agd5mpqx9m7f", "coins": [ { "amount": "4000000000000", "denom": "boot" }, { "amount": "4000000000000", "denom": "tocyb" } ] }, { "address": "bostrom10e3rqclgjz4m4fnx2c23jupcjpyuvyx3x4k7qj", "coins": [ { "amount": "1000000000000", "denom": "boot" }, { "amount": "1000000000000", "denom": "tocyb" } ] }, { "address": "bostrom1t3222ju7ssu58xsm3m2xw445p94cqn2qrex3vy", "coins": [ { "amount": "2000000000000", "denom": "boot" }, { "amount": "2000000000000", "denom": "tocyb" } ] }, { "address": "bostrom1edlrze5f48jjaw0wxcve4asqqf2tcjdl59ln8q", "coins": [ { "amount": "2000000000000", "denom": "boot" }, { "amount": "2000000000000", "denom": "tocyb" } ] }, { "address": "bostrom1m8yf3g2m9p7danjvt4ga6vzewy380pk52kcu9z", "coins": [ { "amount": "4000000000000", "denom": "boot" }, { "amount": "4000000000000", "denom": "tocyb" } ] }, { "address": "bostrom1fe5mspz9jsq6p9hqqet86dwp276635l6gacspa", "coins": [ { "amount": "1000200000000", "denom": "boot" }, { "amount": "1000200000000", "denom": "tocyb" } ] }, { "address": "bostrom14nzyt8wmx4g6zkeluelukamgsh5v4xgnc25k6j", "coins": [ { "amount": "508729659282", "denom": "boot" }, { "amount": "508729659282", "denom": "tocyb" } ] }, { "address": "bostrom1mcslqq8ghtuf6xu987qtk64shy6rd86a2xtwu8", "coins": [ { "amount": "400000000000", "denom": "boot" }, { "amount": "400000000000", "denom": "tocyb" } ] }, { "address": "bostrom1sng0f47cuvx6edxaujh24wc3dvk94q0w6r6smh", "coins": [ { "amount": "474221734944", "denom": "boot" }, { "amount": "474221734944", "denom": "tocyb" } ] }, { "address": "bostrom194pp2whvqynxnfyw5tqy8fzy2kxsugyrwsaynk", "coins": [ { "amount": "1000000000000", "denom": "boot" }, { "amount": "1000000000000", "denom": "tocyb" } ] }, { "address": "bostrom14d92r4svhl4qa3g6q48tjekarw2kt67ngqn4lr", "coins": [ { "amount": "40000000000", "denom": "boot" }, { "amount": "40000000000", "denom": "tocyb" } ] }, { "address": "bostrom1hmkqhy8ygl6tnl5g8tc503rwrmmrkjcq3lduwj", "coins": [ { "amount": "386336649906", "denom": "boot" }, { "amount": "386336649906", "denom": "tocyb" } ] }, { "address": "bostrom12psudf4rpaw4jwhuyx3y8sejhsynae7gv53hn6", "coins": [ { "amount": "320106862931", "denom": "boot" }, { "amount": "320106862931", "denom": "tocyb" } ] }, { "address": "bostrom178q202gz0093uke0jy96psyya452rt8apl4has", "coins": [ { "amount": "285239999451", "denom": "boot" }, { "amount": "285239999451", "denom": "tocyb" } ] }, { "address": "bostrom1kr6udadsvdjymq6m75un4khg27t25st2jn8sag", "coins": [ { "amount": "255496772589", "denom": "boot" }, { "amount": "255496772589", "denom": "tocyb" } ] }, { "address": "bostrom1ymprf45c44rp9k0g2r84w2tjhsq7kalv98rgpt", "coins": [ { "amount": "369099401568", "denom": "boot" }, { "amount": "369099401568", "denom": "tocyb" } ] }, { "address": "bostrom1w8ap0ns4d5fagjfwvph6t99uet0cwv6y6r03un", "coins": [ { "amount": "200997782490", "denom": "boot" }, { "amount": "200997782490", "denom": "tocyb" } ] }, { "address": "bostrom1svm5wl5jf4p7dwemj7wh0p4egr3js6rqtlnefu", "coins": [ { "amount": "197153970492", "denom": "boot" }, { "amount": "197153970492", "denom": "tocyb" } ] }, { "address": "bostrom1gnnd2eaeqpp6lsd34tnp6j0m85h6r9qg0wh3vr", "coins": [ { "amount": "194917719034", "denom": "boot" }, { "amount": "194917719034", "denom": "tocyb" } ] }, { "address": "bostrom1t0hmc79ht0qja92p6qgxn3ee3a3rzqutv7thqn", "coins": [ { "amount": "188630461585", "denom": "boot" }, { "amount": "188630461585", "denom": "tocyb" } ] }, { "address": "bostrom12q68xfj4r00nxnjrqk742rf0z2w6jmwaeppvr0", "coins": [ { "amount": "183750995527", "denom": "boot" }, { "amount": "183750995527", "denom": "tocyb" } ] }, { "address": "bostrom1ggc9sqvj0uhnzwxu5dyzcr05shwd2vv2guqmas", "coins": [ { "amount": "188148534837", "denom": "boot" }, { "amount": "188148534837", "denom": "tocyb" } ] }, { "address": "bostrom177y7sqkxmvl22j632haf8y9gv0j3wedssq5m50", "coins": [ { "amount": "227878425830", "denom": "boot" }, { "amount": "227878425830", "denom": "tocyb" } ] }, { "address": "bostrom1zhy7l8phhpsm2c6xl9c5arcu0z90clynluwrw5", "coins": [ { "amount": "161481707259", "denom": "boot" }, { "amount": "161481707259", "denom": "tocyb" } ] }, { "address": "bostrom1k60sfzh3ecyqfv36f7zav0089077e4zk4g6mxa", "coins": [ { "amount": "146840247453", "denom": "boot" }, { "amount": "146840247453", "denom": "tocyb" } ] }, { "address": "bostrom1kpep8dl93ud4wgpws3tcew6as2s36c9v3csw89", "coins": [ { "amount": "140997260087", "denom": "boot" }, { "amount": "140997260087", "denom": "tocyb" } ] }, { "address": "bostrom16lvsv3w7rnhcm079v6j9eah3xd0p3pd37hl48j", "coins": [ { "amount": "122742180846", "denom": "boot" }, { "amount": "122742180846", "denom": "tocyb" } ] }, { "address": "bostrom1mnrwpdlnglhtqwa55fa66va0j3fv72nvkz4e2x", "coins": [ { "amount": "114829832854", "denom": "boot" }, { "amount": "114829832854", "denom": "tocyb" } ] }, { "address": "bostrom1dt9lwmuq8rkngm5gajxchqhpcnavgp7md9v929", "coins": [ { "amount": "115117293353", "denom": "boot" }, { "amount": "115117293353", "denom": "tocyb" } ] }, { "address": "bostrom12xsg4qm4k5z48s79zdsz84jlhv56kmta3vyfvl", "coins": [ { "amount": "74772629353", "denom": "boot" }, { "amount": "74772629353", "denom": "tocyb" } ] }, { "address": "bostrom1dxpm2ne0jflzr2hy9j5has6u2dvfv68calunqy", "coins": [ { "amount": "99815252312", "denom": "boot" }, { "amount": "99815252312", "denom": "tocyb" } ] }, { "address": "bostrom1my32szlwazg9x56xqvsvtp0hqvpzm0r4u3k4ae", "coins": [ { "amount": "70271964895", "denom": "boot" }, { "amount": "70271964895", "denom": "tocyb" } ] }, { "address": "bostrom1g0ap9fvex93yzzj69uzl74942vjvq8e4f8xtyr", "coins": [ { "amount": "67992083477", "denom": "boot" }, { "amount": "67992083477", "denom": "tocyb" } ] }, { "address": "bostrom16zms8r32vad3z8hl2vc6wrcnanwmxf0dgh25yp", "coins": [ { "amount": "67229160818", "denom": "boot" }, { "amount": "67229160818", "denom": "tocyb" } ] }, { "address": "bostrom1d3zlsrjyl3tzp3aly7vjduhrtrtvkvkeaqpdku", "coins": [ { "amount": "63422106566", "denom": "boot" }, { "amount": "63422106566", "denom": "tocyb" } ] }, { "address": "bostrom18jwk949jqgq3j2du2dgscqxqkkqw5rsjfuucf3", "coins": [ { "amount": "61558395847", "denom": "boot" }, { "amount": "61558395847", "denom": "tocyb" } ] }, { "address": "bostrom13fwhvawke6867s6raqux25fd24t89j5h8wf2v0", "coins": [ { "amount": "60883067675", "denom": "boot" }, { "amount": "60883067675", "denom": "tocyb" } ] }, { "address": "bostrom18z9vsjffvggluxcxfqwsmrz02v37hx2e3auyn2", "coins": [ { "amount": "63671664821", "denom": "boot" }, { "amount": "63671664821", "denom": "tocyb" } ] }, { "address": "bostrom1lnkg57t7mvg5mcl7kdkevtgr9wlf6f9qtp86sk", "coins": [ { "amount": "70907190105", "denom": "boot" }, { "amount": "70907190105", "denom": "tocyb" } ] }, { "address": "bostrom1dl5df5g2xwj02e93k547etw2ergvc3a20v5ekz", "coins": [ { "amount": "46480474242", "denom": "boot" }, { "amount": "46480474242", "denom": "tocyb" } ] }, { "address": "bostrom13ume6mqte5h9ngx2hh6ngc8aham7x0k6stuvkm", "coins": [ { "amount": "41813199988", "denom": "boot" }, { "amount": "41813199988", "denom": "tocyb" } ] }, { "address": "bostrom1ldjugf3uj2gwkmmsf5japfknf96zv6hw7xw7v4", "coins": [ { "amount": "43229857071", "denom": "boot" }, { "amount": "43229857071", "denom": "tocyb" } ] }, { "address": "bostrom1y9zkl7uqjev899swng4eqfuurwaxpchwppewyc", "coins": [ { "amount": "40330418998", "denom": "boot" }, { "amount": "40330418998", "denom": "tocyb" } ] }, { "address": "bostrom16lf2hvzy4n4gvtx37pgkkdw2e2psfjjdpej53p", "coins": [ { "amount": "37988147654", "denom": "boot" }, { "amount": "37988147654", "denom": "tocyb" } ] }, { "address": "bostrom15zs0cjct43xs4z4sesxcrynar5mxm82f0ykhl3", "coins": [ { "amount": "111131994342", "denom": "boot" }, { "amount": "111131994342", "denom": "tocyb" } ] }, { "address": "bostrom1v5jqg6k7mszmchhz8kyfml5h4e2txct9jz3am4", "coins": [ { "amount": "37418729590", "denom": "boot" }, { "amount": "37418729590", "denom": "tocyb" } ] }, { "address": "bostrom19ys53t55r725j882gjcrnf7s449gdrds3h2hu4", "coins": [ { "amount": "38253993813", "denom": "boot" }, { "amount": "38253993813", "denom": "tocyb" } ] }, { "address": "bostrom1en69twaxmv7xupy8lq7y539dpecx7yz8g0k8ft", "coins": [ { "amount": "88440007493", "denom": "boot" }, { "amount": "88440007493", "denom": "tocyb" } ] }, { "address": "bostrom1kgq82m6z2jttytv7fvwy2rklhq5k03gc2h9sej", "coins": [ { "amount": "30494554808", "denom": "boot" }, { "amount": "30494554808", "denom": "tocyb" } ] }, { "address": "bostrom1hvk6s053m6qdlz9kwllgldwf4qp2c3mrlh9s2q", "coins": [ { "amount": "29370149824", "denom": "boot" }, { "amount": "29370149824", "denom": "tocyb" } ] }, { "address": "bostrom1ch6nukdgj55c9sk4h5t8spzhahuuvn86gqvarm", "coins": [ { "amount": "27485323135", "denom": "boot" }, { "amount": "27485323135", "denom": "tocyb" } ] }, { "address": "bostrom1rqudjcrdwqedffxufmqgsleuguhm7pkaq0alce", "coins": [ { "amount": "27363284437", "denom": "boot" }, { "amount": "27363284437", "denom": "tocyb" } ] }, { "address": "bostrom1qgqkc9t3pfsp6yxjwds70e4r9y0p6resmfnymc", "coins": [ { "amount": "26376882296", "denom": "boot" }, { "amount": "26376882296", "denom": "tocyb" } ] }, { "address": "bostrom12kd8w45rqxuwpwqvpmdyvvdey9ezeqhav4nn85", "coins": [ { "amount": "26208333897", "denom": "boot" }, { "amount": "26208333897", "denom": "tocyb" } ] }, { "address": "bostrom152kqs8p7d3jy6kn4uk87ve3alkuqjgewt3cmvz", "coins": [ { "amount": "28921406054", "denom": "boot" }, { "amount": "28921406054", "denom": "tocyb" } ] }, { "address": "bostrom1dn09uyhwmv3ratntc7c603vczgrec32c2fylpj", "coins": [ { "amount": "24175157388", "denom": "boot" }, { "amount": "24175157388", "denom": "tocyb" } ] }, { "address": "bostrom1qezgmksavgdvcvf9ckhazfy3jfw8whhzfrvtlz", "coins": [ { "amount": "21979059507", "denom": "boot" }, { "amount": "21979059507", "denom": "tocyb" } ] }, { "address": "bostrom1d552nfgekkugdgxw3zl242qpxapl67jfkz76tp", "coins": [ { "amount": "21555502893", "denom": "boot" }, { "amount": "21555502893", "denom": "tocyb" } ] }, { "address": "bostrom10vpygn9ftv85ra7j7qpewuq5jdgvpjmehlds0g", "coins": [ { "amount": "20335729382", "denom": "boot" }, { "amount": "20335729382", "denom": "tocyb" } ] }, { "address": "bostrom18naxcfp2s397a2ucav2m53f003uylk3qz9fvr7", "coins": [ { "amount": "95514429798", "denom": "boot" }, { "amount": "95514429798", "denom": "tocyb" } ] }, { "address": "bostrom18t3kx877vyvstcvn50cgn5w6hppe8ce0pq72m2", "coins": [ { "amount": "18546327724", "denom": "boot" }, { "amount": "18546327724", "denom": "tocyb" } ] }, { "address": "bostrom1kfqv2fzzu6dgwnf6snql2jslwdws07fl2gz37u", "coins": [ { "amount": "17879700159", "denom": "boot" }, { "amount": "17879700159", "denom": "tocyb" } ] }, { "address": "bostrom1ggayl03vvv763az6eez66jzwuunyqkcusk8fwj", "coins": [ { "amount": "17754934798", "denom": "boot" }, { "amount": "17754934798", "denom": "tocyb" } ] }, { "address": "bostrom1fjeq0urgk4x0s6pl2p2fes8c95426amp7lv4dv", "coins": [ { "amount": "17601345097", "denom": "boot" }, { "amount": "17601345097", "denom": "tocyb" } ] }, { "address": "bostrom1jgh7ghrcr47tuahawzvg3svv2hxkxfx5u9lzr2", "coins": [ { "amount": "17333444802", "denom": "boot" }, { "amount": "17333444802", "denom": "tocyb" } ] }, { "address": "bostrom19y467lyhqlpa52y6snq9cxw47xhwq0th3p05r0", "coins": [ { "amount": "14256149914", "denom": "boot" }, { "amount": "14256149914", "denom": "tocyb" } ] }, { "address": "bostrom16ge9uqpqf78jdt0uz58ycalhtg59w77qm9t7d2", "coins": [ { "amount": "14222312706", "denom": "boot" }, { "amount": "14222312706", "denom": "tocyb" } ] }, { "address": "bostrom1463la66ac89tmlwgvx20c4d2jv84ekzs8kzh87", "coins": [ { "amount": "13368713572", "denom": "boot" }, { "amount": "13368713572", "denom": "tocyb" } ] }, { "address": "bostrom164k2s2s2td6a30d3rvnv93scy3v29psw4j3ndm", "coins": [ { "amount": "12701785716", "denom": "boot" }, { "amount": "12701785716", "denom": "tocyb" } ] }, { "address": "bostrom1rya5547x4lrwc2npd63s89ny2dvhamv9dfx9x9", "coins": [ { "amount": "12090950492", "denom": "boot" }, { "amount": "12090950492", "denom": "tocyb" } ] }, { "address": "bostrom18wn5kyxewwk6qh97493xtj9gufpmqserfahc37", "coins": [ { "amount": "12063356572", "denom": "boot" }, { "amount": "12063356572", "denom": "tocyb" } ] }, { "address": "bostrom1lljcf37yxh24l3v4kwqsyghwz4ywlg6urg4kte", "coins": [ { "amount": "13616553392", "denom": "boot" }, { "amount": "13616553392", "denom": "tocyb" } ] }, { "address": "bostrom1d7n8znqg635yxnzlsycnt6kut8z5du5yftutrf", "coins": [ { "amount": "10958899451", "denom": "boot" }, { "amount": "10958899451", "denom": "tocyb" } ] }, { "address": "bostrom16pdckvu70ufzvm8avd9anga6k35nu7axym02wp", "coins": [ { "amount": "9792986284", "denom": "boot" }, { "amount": "9792986284", "denom": "tocyb" } ] }, { "address": "bostrom18txzlmkqf264a2awhey6lmeq0dtv5ex69d2fcy", "coins": [ { "amount": "9333557553", "denom": "boot" }, { "amount": "9333557553", "denom": "tocyb" } ] }, { "address": "bostrom1mmtt0cnsgwx3t90vs4tn9k08kw8xn4v3pggfu7", "coins": [ { "amount": "6701991111", "denom": "boot" }, { "amount": "6701991111", "denom": "tocyb" } ] }, { "address": "bostrom1mryr27k3h8kqr5ahj82v0ym2xexdewfc9rmng8", "coins": [ { "amount": "6310270182", "denom": "boot" }, { "amount": "6310270182", "denom": "tocyb" } ] }, { "address": "bostrom1gg73t0eyrkqf953waqxh6uqah62p46jyg82ulr", "coins": [ { "amount": "5787292447", "denom": "boot" }, { "amount": "5787292447", "denom": "tocyb" } ] }, { "address": "bostrom1jx0az02ccnt4mgj2r9vhvycsdjsztrrgdkwzr3", "coins": [ { "amount": "4220671315", "denom": "boot" }, { "amount": "4220671315", "denom": "tocyb" } ] }, { "address": "bostrom1r90j4656xsug2hkj57a3knqcs9huh3ea88ykhp", "coins": [ { "amount": "3475567070", "denom": "boot" }, { "amount": "3475567070", "denom": "tocyb" } ] }, { "address": "bostrom1f7nx65pmayfenpfwzwaamwas4ygmvalq2q2ayq", "coins": [ { "amount": "73338027208", "denom": "boot" }, { "amount": "73338027208", "denom": "tocyb" } ] }, { "address": "bostrom1zl0t5703q42qx7drxsgl9thjwlul5x6unjhwgn", "coins": [ { "amount": "2742969308", "denom": "boot" }, { "amount": "2742969308", "denom": "tocyb" } ] }, { "address": "bostrom13q0m4hw6pmajqdqn4g464vzmst78sf55ktrp05", "coins": [ { "amount": "2064986311", "denom": "boot" }, { "amount": "2064986311", "denom": "tocyb" } ] }, { "address": "bostrom1cjyv02cja896rr5y5lks79enk2nretn3mqyc69", "coins": [ { "amount": "13447758288", "denom": "boot" }, { "amount": "13447758288", "denom": "tocyb" } ] }, { "address": "bostrom16qu2ymnzzjn05xc6yszjy50caaahcahdvmex5e", "coins": [ { "amount": "1362390306", "denom": "boot" }, { "amount": "1362390306", "denom": "tocyb" } ] }, { "address": "bostrom1jst67u54vquzvun3dawpmpwyx5ar8mayaak5j7", "coins": [ { "amount": "181160067", "denom": "boot" }, { "amount": "181160067", "denom": "tocyb" } ] }, { "address": "bostrom16s7gwc944patdynnfnvac0jh5u76wsnflty377", "coins": [ { "amount": "77674844", "denom": "boot" }, { "amount": "77674844", "denom": "tocyb" } ] }, { "address": "bostrom1s3lgc3mgy4ltwr796qk6j73xmau4njueds0mgu", "coins": [ { "amount": "1340337491769", "denom": "boot" }, { "amount": "1340337491769", "denom": "tocyb" } ] }, { "address": "bostrom10556xtnp39nvx3ec3yjafug662pyt6af84n477", "coins": [ { "amount": "1304153455839", "denom": "boot" }, { "amount": "1304153455839", "denom": "tocyb" } ] }, { "address": "bostrom1ffve0zx389ffl80ae9t8jmghcjuzdlqr5eayfd", "coins": [ { "amount": "701778551659", "denom": "boot" }, { "amount": "701778551659", "denom": "tocyb" } ] }, { "address": "bostrom1ftah3e558ww7xutn5w8h7vrqa9v69pntztnr3p", "coins": [ { "amount": "622444466499", "denom": "boot" }, { "amount": "622444466499", "denom": "tocyb" } ] }, { "address": "bostrom1wnpak7sfawsfv9c8vqe7naxfa4g99lv77d7c0z", "coins": [ { "amount": "517421971282", "denom": "boot" }, { "amount": "517421971282", "denom": "tocyb" } ] }, { "address": "bostrom1sgy27lctdrc5egpvc8f02rgzml6hmmvh5wu6xk", "coins": [ { "amount": "359172486938", "denom": "boot" }, { "amount": "359172486938", "denom": "tocyb" } ] }, { "address": "bostrom1cg79pj70mgl8xlum0rw5yy6enk9jszsrzvwysn", "coins": [ { "amount": "279430823965", "denom": "boot" }, { "amount": "279430823965", "denom": "tocyb" } ] }, { "address": "bostrom13dpy00jest96g7h5vdgvg9zpxq6xnclh5hzw5l", "coins": [ { "amount": "258229369437", "denom": "boot" }, { "amount": "258229369437", "denom": "tocyb" } ] }, { "address": "bostrom1mdq5r6az6z8su68zj6px88j2ukr78ea4ggkzt6", "coins": [ { "amount": "237448433882", "denom": "boot" }, { "amount": "237448433882", "denom": "tocyb" } ] }, { "address": "bostrom1lepnu7nt05g79jtmfp2pgrpys3fjc4p74sc0l2", "coins": [ { "amount": "182911039870", "denom": "boot" }, { "amount": "182911039870", "denom": "tocyb" } ] }, { "address": "bostrom1d5lu67hu3lhqtw6zyv7uy4gkfpdtfnzxdu6mrq", "coins": [ { "amount": "157995617348", "denom": "boot" }, { "amount": "157995617348", "denom": "tocyb" } ] }, { "address": "bostrom16jttzjgks48kqrhk5e68yv0gv6dt0rpw2f5pwn", "coins": [ { "amount": "141302079887", "denom": "boot" }, { "amount": "141302079887", "denom": "tocyb" } ] }, { "address": "bostrom1e20hw2pqcgxvumkwn2qeeavcrswzskzjhr2aq0", "coins": [ { "amount": "119454359990", "denom": "boot" }, { "amount": "119454359990", "denom": "tocyb" } ] }, { "address": "bostrom17z2fywzrdld7qmwzpsq0atxfwcns8rp833rgxy", "coins": [ { "amount": "95223358775", "denom": "boot" }, { "amount": "95223358775", "denom": "tocyb" } ] }, { "address": "bostrom1tu0e0ggvjtv4gvzcranjnrykac0umnf8y8fm0r", "coins": [ { "amount": "92010985676", "denom": "boot" }, { "amount": "92010985676", "denom": "tocyb" } ] }, { "address": "bostrom1sltcfypwms38jjj3g38rg7ldx3e6uqrzrnkf9y", "coins": [ { "amount": "91965450766", "denom": "boot" }, { "amount": "91965450766", "denom": "tocyb" } ] }, { "address": "bostrom1zy553za8nenzukmv65240323jhuvxzym4pl6w9", "coins": [ { "amount": "154293211852", "denom": "boot" }, { "amount": "154293211852", "denom": "tocyb" } ] }, { "address": "bostrom1lpfs6xv765u4yxr8rlyn5ux0g2a8tyt90hsnas", "coins": [ { "amount": "59256843788", "denom": "boot" }, { "amount": "59256843788", "denom": "tocyb" } ] }, { "address": "bostrom1smqr5tp684g07aekcn0w852wqlme5mn6dmsny3", "coins": [ { "amount": "47098839942", "denom": "boot" }, { "amount": "47098839942", "denom": "tocyb" } ] }, { "address": "bostrom1eqkdzfcjnu20ywju35rf3nutxzjxjaqnxqfyyz", "coins": [ { "amount": "44081312892", "denom": "boot" }, { "amount": "44081312892", "denom": "tocyb" } ] }, { "address": "bostrom1waac73cpffx7suhpkvnn8w0a8s2cgzn66x2aka", "coins": [ { "amount": "42415701749", "denom": "boot" }, { "amount": "42415701749", "denom": "tocyb" } ] }, { "address": "bostrom16macu2qtc0jmqc7txvf0wkz84cycsx728ah0xc", "coins": [ { "amount": "97996176301", "denom": "boot" }, { "amount": "97996176301", "denom": "tocyb" } ] }, { "address": "bostrom1fapqgamx3c8za8d3z56sydjtjygyu0ly752j8g", "coins": [ { "amount": "37850807372", "denom": "boot" }, { "amount": "37850807372", "denom": "tocyb" } ] }, { "address": "bostrom1w4548vrnvc7t9j2ly55nvkjvhwqt9thnfcvuw6", "coins": [ { "amount": "33395512349", "denom": "boot" }, { "amount": "33395512349", "denom": "tocyb" } ] }, { "address": "bostrom133t8m00w7llsslnf05zdhehharntly8dqzpfs8", "coins": [ { "amount": "31992273571", "denom": "boot" }, { "amount": "31992273571", "denom": "tocyb" } ] }, { "address": "bostrom1smtmk8fe3qhlwj3h7nynl6p42946qydzvgj9va", "coins": [ { "amount": "29390986364", "denom": "boot" }, { "amount": "29390986364", "denom": "tocyb" } ] }, { "address": "bostrom1csf3up94qheqz88fvvlwjl7vc5sdymarktrvpw", "coins": [ { "amount": "18442151620", "denom": "boot" }, { "amount": "18442151620", "denom": "tocyb" } ] }, { "address": "bostrom1tr3eyy9l480pxjk0ygudwpfus7j8pgdljn09jm", "coins": [ { "amount": "17537519175", "denom": "boot" }, { "amount": "17537519175", "denom": "tocyb" } ] }, { "address": "bostrom16ahkkv0jzhtp73z83qlhqrypss6jpjm8eekpwv", "coins": [ { "amount": "17375703563", "denom": "boot" }, { "amount": "17375703563", "denom": "tocyb" } ] }, { "address": "bostrom1htq7u8gy9muv4fk6st04524tdzy8rv04528gys", "coins": [ { "amount": "16744189104", "denom": "boot" }, { "amount": "16744189104", "denom": "tocyb" } ] }, { "address": "bostrom1kk9clwd4eva7ww95gn4rw3xzuwfs0983sl5cwt", "coins": [ { "amount": "16191669541", "denom": "boot" }, { "amount": "16191669541", "denom": "tocyb" } ] }, { "address": "bostrom1k7cl9ya9qq30c7m4rvg3823hrc8k80eetqvhj8", "coins": [ { "amount": "14797976623", "denom": "boot" }, { "amount": "14797976623", "denom": "tocyb" } ] }, { "address": "bostrom16d69u47km5vqdvf6fr8qyhktlacgka7fdvazr8", "coins": [ { "amount": "14751375909", "denom": "boot" }, { "amount": "14751375909", "denom": "tocyb" } ] }, { "address": "bostrom1njsr8tngxtygsc73mrtn5738ztkzqy7c7y7h3t", "coins": [ { "amount": "51066633718", "denom": "boot" }, { "amount": "51066633718", "denom": "tocyb" } ] }, { "address": "bostrom1kf0d64nuwsf2zeul5wkx78fsznplnlpsfh7fqw", "coins": [ { "amount": "11673069511", "denom": "boot" }, { "amount": "11673069511", "denom": "tocyb" } ] }, { "address": "bostrom18ghjkwygsvjcsh20tc5zzhfttxxuex7a9lq8ps", "coins": [ { "amount": "9561458741", "denom": "boot" }, { "amount": "9561458741", "denom": "tocyb" } ] }, { "address": "bostrom1s2a7rckcky6jmhncxwy0xtwf2ymg87puk6jpzz", "coins": [ { "amount": "14991446142", "denom": "boot" }, { "amount": "14991446142", "denom": "tocyb" } ] }, { "address": "bostrom1679yrs8dmska7wcsawgy2m25kwucm3z0hwr74y", "coins": [ { "amount": "388969016352", "denom": "boot" }, { "amount": "388969016352", "denom": "tocyb" } ] }, { "address": "bostrom15gk8edxtvvp372flljk884fav55y8ehwru4u8w", "coins": [ { "amount": "2279889403", "denom": "boot" }, { "amount": "2279889403", "denom": "tocyb" } ] }, { "address": "bostrom1jz57cgfr248y9w6sn76l7pugjkr6e7zh6y2grp", "coins": [ { "amount": "2378739020", "denom": "boot" }, { "amount": "2378739020", "denom": "tocyb" } ] }, { "address": "bostrom1gw5kdey7fs9wdh05w66s0h4s24tjdvtc9v6vpe", "coins": [ { "amount": "1799479675", "denom": "boot" }, { "amount": "1799479675", "denom": "tocyb" } ] }, { "address": "bostrom1kajt7sxfpnfujm7ptj90654lmwz4sftpc9mp9a", "coins": [ { "amount": "1743792737", "denom": "boot" }, { "amount": "1743792737", "denom": "tocyb" } ] }, { "address": "bostrom1t575qeee3qgshuf964qal057z77vljqef9tlck", "coins": [ { "amount": "1099995800", "denom": "boot" }, { "amount": "1099995800", "denom": "tocyb" } ] }, { "address": "bostrom105zy26ze9gean4qukqlvhkv4mtcndc9t2xaydz", "coins": [ { "amount": "1006206924", "denom": "boot" }, { "amount": "1006206924", "denom": "tocyb" } ] }, { "address": "bostrom1a30w6j4m6g3s2c6zt02z56xynnuaqmn3ahwxuq", "coins": [ { "amount": "974688373", "denom": "boot" }, { "amount": "974688373", "denom": "tocyb" } ] }, { "address": "bostrom1pmaltcu0x97x8j5klc8xluaapkzcvztcn2vkmw", "coins": [ { "amount": "736741030", "denom": "boot" }, { "amount": "736741030", "denom": "tocyb" } ] }, { "address": "bostrom1n3mhyp9fvcmuu8l0q8qvjy07x0rql8q4uwev5z", "coins": [ { "amount": "704276829", "denom": "boot" }, { "amount": "704276829", "denom": "tocyb" } ] }, { "address": "bostrom1u3ap2d4ytcqrr6jlsjf380g3lvgldq4m64s7dg", "coins": [ { "amount": "675487504", "denom": "boot" }, { "amount": "675487504", "denom": "tocyb" } ] }, { "address": "bostrom1keny4peq77drtcdj6fscd9eknqcqyjmxqcr8t8", "coins": [ { "amount": "647527281", "denom": "boot" }, { "amount": "647527281", "denom": "tocyb" } ] }, { "address": "bostrom1kk79xcsuah7ckvunku78094gyh7900ehkllkur", "coins": [ { "amount": "173703544", "denom": "boot" }, { "amount": "173703544", "denom": "tocyb" } ] }, { "address": "bostrom137eezcxcyqgt6kshfdfuvnsdgwpujyje2l8qdz", "coins": [ { "amount": "73708712", "denom": "boot" }, { "amount": "73708712", "denom": "tocyb" } ] }, { "address": "bostrom1uz39kh64w8p5df034fh6g5hwpdq8m0h5rx58he", "coins": [ { "amount": "49997750", "denom": "boot" }, { "amount": "49997750", "denom": "tocyb" } ] }, { "address": "bostrom1kz6s2mp4rg7plj8p4qqe2wkegn4ldw3ak2a7qc", "coins": [ { "amount": "233827", "denom": "boot" }, { "amount": "233827", "denom": "tocyb" } ] }, { "address": "bostrom1quchyywzdxp62dq3rwan8fg35v6j58sjwnfpuu", "coins": [ { "amount": "432771825520", "denom": "boot" }, { "amount": "432771825520", "denom": "tocyb" } ] }, { "address": "bostrom1x95keq9l9y9p7hjdt6xd8wnknrpnjsqrqhpwc9", "coins": [ { "amount": "150000000000", "denom": "boot" }, { "amount": "150000000000", "denom": "tocyb" } ] }, { "address": "bostrom1z98eg2ztdp2glyla62629nrlvczg8s7fvc0znp", "coins": [ { "amount": "100000000000", "denom": "boot" }, { "amount": "100000000000", "denom": "tocyb" } ] }, { "address": "bostrom1xvssufw8ke03halg8wgu8m994ktxz0y9vm6tqn", "coins": [ { "amount": "100000000000", "denom": "boot" }, { "amount": "100000000000", "denom": "tocyb" } ] }, { "address": "bostrom1vxxfhd8txmrq76jx3gj7sdrvg0vvqret6kxpgd", "coins": [ { "amount": "100000000000", "denom": "boot" }, { "amount": "100000000000", "denom": "tocyb" } ] }, { "address": "bostrom1vtu55cc7m6yz9zfg5vqdk80f2g68petgzj9fv4", "coins": [ { "amount": "100000000000", "denom": "boot" }, { "amount": "100000000000", "denom": "tocyb" } ] }, { "address": "bostrom16yf94eecl6h44l5w7zp75skh3rg0k4veavx762", "coins": [ { "amount": "25185396846", "denom": "boot" }, { "amount": "25185396846", "denom": "tocyb" } ] }, { "address": "bostrom1gxyf6tsjamnavmkfk43mwfzwscn4tgfkz8k85n", "coins": [ { "amount": "5000000000", "denom": "boot" }, { "amount": "5000000000", "denom": "tocyb" } ] }, { "address": "bostrom1w4tvyvf3hhpcwv9d4axa8n0mmj5d6ypvpq5mj6", "coins": [ { "amount": "278432605496", "denom": "boot" }, { "amount": "278432605496", "denom": "tocyb" } ] }, { "address": "bostrom1xk4a2u2rjt7mqu5eg8xtxk37l28r3cugkqk9lp", "coins": [ { "amount": "233157212646", "denom": "boot" }, { "amount": "233157212646", "denom": "tocyb" } ] }, { "address": "bostrom143x4d5wx50204zyreqg8ekgq3n3fcaxucacztp", "coins": [ { "amount": "9826875134", "denom": "boot" }, { "amount": "9826875134", "denom": "tocyb" } ] }, { "address": "bostrom1y83nga220nfjt9zz0mmqc90cd705az95n5cfwj", "coins": [ { "amount": "9608859331", "denom": "boot" }, { "amount": "9608859331", "denom": "tocyb" } ] }, { "address": "bostrom1hyjhy0tp6geral2g9vj9nyteglf8t5q42gfq3j", "coins": [ { "amount": "2388890839", "denom": "boot" }, { "amount": "2388890839", "denom": "tocyb" } ] }, { "address": "bostrom1d8mq46wt2yxsgwrmh6hhfgycl0537w8gggn47f", "coins": [ { "amount": "2182283065", "denom": "boot" }, { "amount": "2182283065", "denom": "tocyb" } ] }, { "address": "bostrom1p0r7uxstcw8ehrwuj4kn8qzzs0yypsjwxgd445", "coins": [ { "amount": "2018839163", "denom": "boot" }, { "amount": "2018839163", "denom": "tocyb" } ] }, { "address": "bostrom1duc9gthaeg82lx9pdf642g043xqhgxgxmfvwsz", "coins": [ { "amount": "994320008", "denom": "boot" }, { "amount": "994320008", "denom": "tocyb" } ] }, { "address": "bostrom1a4mzr2y2g0cc9f0uhyeh3ftmsfxzqwxfdqtd7c", "coins": [ { "amount": "7092669793", "denom": "boot" }, { "amount": "7092669793", "denom": "tocyb" } ] }, { "address": "bostrom1xpl2sx64ra5san4su0r0hj8z9eh5cf5dcv48qa", "coins": [ { "amount": "970654649", "denom": "boot" }, { "amount": "970654649", "denom": "tocyb" } ] }, { "address": "bostrom1hem3076xmat8ttr0cg0nnn2lghtc2p7xtzpj8s", "coins": [ { "amount": "951329198", "denom": "boot" }, { "amount": "951329198", "denom": "tocyb" } ] }, { "address": "bostrom1402rpwdquxxkgvl740f6w69l65eau5vkqcvrax", "coins": [ { "amount": "16533932739", "denom": "boot" }, { "amount": "16533932739", "denom": "tocyb" } ] }, { "address": "bostrom1z8mlsd42eaguaqf5gexy5a7jxgpwpgvz99qzft", "coins": [ { "amount": "218609970", "denom": "boot" }, { "amount": "218609970", "denom": "tocyb" } ] }, { "address": "bostrom1v2n3hg6s4resacgpemfyrd5hul2ntk7tftnk6u", "coins": [ { "amount": "218382779", "denom": "boot" }, { "amount": "218382779", "denom": "tocyb" } ] }, { "address": "bostrom1ufpz4dlnfawg0pr5dcq4hkrf9gs30mu0272p9w", "coins": [ { "amount": "218341548", "denom": "boot" }, { "amount": "218341548", "denom": "tocyb" } ] }, { "address": "bostrom1mkhugmqg9c0qe27stz3m4my9xq7e9pct0jyr3p", "coins": [ { "amount": "218115192", "denom": "boot" }, { "amount": "218115192", "denom": "tocyb" } ] }, { "address": "bostrom1argjwgcplguenq4l92ggn06wadnfrz0ecqrmqs", "coins": [ { "amount": "50591836687", "denom": "boot" }, { "amount": "50591836687", "denom": "tocyb" } ] }, { "address": "bostrom1ke7kxdn29w2lrxt9dzusa6shvmwd8xm9gxm2zf", "coins": [ { "amount": "120588855018", "denom": "boot" }, { "amount": "120588855018", "denom": "tocyb" } ] }, { "address": "bostrom1fpl40sref5vp8kfm7xkqlq5qc0v4xrjvk89kwa", "coins": [ { "amount": "11118481031", "denom": "boot" }, { "amount": "11118481031", "denom": "tocyb" } ] }, { "address": "bostrom1g2d9xyuf7ddgaj4llxvg50pfhlsr9ehf2r8dr6", "coins": [ { "amount": "5689509530", "denom": "boot" }, { "amount": "5689509530", "denom": "tocyb" } ] }, { "address": "bostrom152m9xcx0ht7yxr5834ju7qjcyvetw8amd04apw", "coins": [ { "amount": "71337787640", "denom": "boot" }, { "amount": "71337787640", "denom": "tocyb" } ] }, { "address": "bostrom15n3t80p7eseld809f7fu3s9tlcezlymkfeu59n", "coins": [ { "amount": "4294256393", "denom": "boot" }, { "amount": "4294256393", "denom": "tocyb" } ] }, { "address": "bostrom1ke6pp2kq2wx74tlh5fxqgp7af6jtsna3kktuh6", "coins": [ { "amount": "11975798321", "denom": "boot" }, { "amount": "11975798321", "denom": "tocyb" } ] }, { "address": "bostrom1daxxqs56f6j5qxxtjrjkexghsmnaj66tejshc8", "coins": [ { "amount": "72921262872", "denom": "boot" }, { "amount": "72921262872", "denom": "tocyb" } ] }, { "address": "bostrom1nywu6z26tpcrr2kcqe8z7t235wrfkhfcfhlzmk", "coins": [ { "amount": "10932888406", "denom": "boot" }, { "amount": "10932888406", "denom": "tocyb" } ] }, { "address": "bostrom1mnqlcc7mslzxcf798acp80u2fxudsuzdn0px6s", "coins": [ { "amount": "12677003041", "denom": "boot" }, { "amount": "12677003041", "denom": "tocyb" } ] }, { "address": "bostrom1ccvpcq9ffy0qd2ca8nmmpzfamtyjfc9znwak8m", "coins": [ { "amount": "32639852509", "denom": "boot" }, { "amount": "32639852509", "denom": "tocyb" } ] }, { "address": "bostrom1w4tk9lj8qtx2x4xf4emgrnq950hnlajsxlnl3u", "coins": [ { "amount": "3420409835", "denom": "boot" }, { "amount": "3420409835", "denom": "tocyb" } ] }, { "address": "bostrom1s8l0akn79kk74g32kf86stfsa08ck9qmm4v6ws", "coins": [ { "amount": "3409436625", "denom": "boot" }, { "amount": "3409436625", "denom": "tocyb" } ] }, { "address": "bostrom10aqelwndkz9k8uawp26elxep64ayc5rgn24h7p", "coins": [ { "amount": "3389782351", "denom": "boot" }, { "amount": "3389782351", "denom": "tocyb" } ] }, { "address": "bostrom1ap7zhu5gxlk7n3g97dqehm9nnt3mje3nr5jecs", "coins": [ { "amount": "3368708754", "denom": "boot" }, { "amount": "3368708754", "denom": "tocyb" } ] }, { "address": "bostrom1j6he98h8xwnt2yp9eczhhuff3k3hvk98gr27ee", "coins": [ { "amount": "3326309936", "denom": "boot" }, { "amount": "3326309936", "denom": "tocyb" } ] }, { "address": "bostrom1mskldfjlnup46adzss7lukfh3emm6z4lmqhk7z", "coins": [ { "amount": "3275155354", "denom": "boot" }, { "amount": "3275155354", "denom": "tocyb" } ] }, { "address": "bostrom12ysvrknuwdr6737fnc06v875whfh52xj3ewaf2", "coins": [ { "amount": "2961579452", "denom": "boot" }, { "amount": "2961579452", "denom": "tocyb" } ] }, { "address": "bostrom10trdf5eyfcmc9graltx4hmpgznhrm7hdz82k2n", "coins": [ { "amount": "2941697143", "denom": "boot" }, { "amount": "2941697143", "denom": "tocyb" } ] }, { "address": "bostrom1nvr4qa7szsd3e7xfysn946gcqv5wyemlcxmxpw", "coins": [ { "amount": "10653917696", "denom": "boot" }, { "amount": "10653917696", "denom": "tocyb" } ] }, { "address": "bostrom1wm4026rxqcrkh09k806m6y4lys942etx5cjz9z", "coins": [ { "amount": "2128629825", "denom": "boot" }, { "amount": "2128629825", "denom": "tocyb" } ] }, { "address": "bostrom1zeg2k7kd8qadmwd3kslwmag3erq7hqxt5aajjz", "coins": [ { "amount": "13163031473", "denom": "boot" }, { "amount": "13163031473", "denom": "tocyb" } ] }, { "address": "bostrom16h7tyj5p69t3r7qasunf938cx2elp38fhqc7zr", "coins": [ { "amount": "14451060685", "denom": "boot" }, { "amount": "14451060685", "denom": "tocyb" } ] }, { "address": "bostrom1jdmfxzpnqqlhjsju3mz7qsgvvdparw5acx7t62", "coins": [ { "amount": "1664373777", "denom": "boot" }, { "amount": "1664373777", "denom": "tocyb" } ] }, { "address": "bostrom1smsn8u0h5tlvt3jazf78nnrv54aspged9h2nl9", "coins": [ { "amount": "1654337644", "denom": "boot" }, { "amount": "1654337644", "denom": "tocyb" } ] }, { "address": "bostrom15kl5tv0smz5h8eewu5hs9mtnusz4dereyqxxtw", "coins": [ { "amount": "1408569410", "denom": "boot" }, { "amount": "1408569410", "denom": "tocyb" } ] }, { "address": "bostrom1uew6fawa3ahu60tj5kspmr4u0zvljj69q4s3ps", "coins": [ { "amount": "1380580057", "denom": "boot" }, { "amount": "1380580057", "denom": "tocyb" } ] }, { "address": "bostrom1ezpth4mp3eeqdt49kgqd5ctr69xev6v2gykpur", "coins": [ { "amount": "1351419074", "denom": "boot" }, { "amount": "1351419074", "denom": "tocyb" } ] }, { "address": "bostrom1avvkajdvmj9d8jpl0ga4scftjykeuhjpsa9kf5", "coins": [ { "amount": "1334996609", "denom": "boot" }, { "amount": "1334996609", "denom": "tocyb" } ] }, { "address": "bostrom1gd9r9uhd8a5k2naudq4hua3vf3lkwhfrm63qhq", "coins": [ { "amount": "1301510822", "denom": "boot" }, { "amount": "1301510822", "denom": "tocyb" } ] }, { "address": "bostrom1vrym7t34gs9t2dkd8z849zcymkj54kgq7pdf8z", "coins": [ { "amount": "1231063676", "denom": "boot" }, { "amount": "1231063676", "denom": "tocyb" } ] }, { "address": "bostrom1lk3yjcn0lvwj9f2dj75m8y3smpq5s5zsnnj3nz", "coins": [ { "amount": "1202315516", "denom": "boot" }, { "amount": "1202315516", "denom": "tocyb" } ] }, { "address": "bostrom1hk49ws6ded79xmwehv7yrw3q6mfj7kulafxqhr", "coins": [ { "amount": "1108262797", "denom": "boot" }, { "amount": "1108262797", "denom": "tocyb" } ] }, { "address": "bostrom1vx9qctuxswd6ydcv4z5pcuuvct7y9l0nqq799x", "coins": [ { "amount": "1083041319", "denom": "boot" }, { "amount": "1083041319", "denom": "tocyb" } ] }, { "address": "bostrom1ydc5fy9fjdygvgw36u49yj39fr67pd9mv67ety", "coins": [ { "amount": "894267502", "denom": "boot" }, { "amount": "894267502", "denom": "tocyb" } ] }, { "address": "bostrom1wkjn2nc4v5g3tpjj043wxtmeda90ql3yqqddav", "coins": [ { "amount": "814730401", "denom": "boot" }, { "amount": "814730401", "denom": "tocyb" } ] }, { "address": "bostrom1gh09lmm8flkuu3w38mr4axvunnu6qqlapuwzrv", "coins": [ { "amount": "760249650", "denom": "boot" }, { "amount": "760249650", "denom": "tocyb" } ] }, { "address": "bostrom1m0tjgkrh4td9fcp8nnssu3rfdahzfgdshsall9", "coins": [ { "amount": "682238027", "denom": "boot" }, { "amount": "682238027", "denom": "tocyb" } ] }, { "address": "bostrom1mnfalar08dsvtwutmh43lnhx2zzmq7xhdulemj", "coins": [ { "amount": "15592862337", "denom": "boot" }, { "amount": "15592862337", "denom": "tocyb" } ] }, { "address": "bostrom1g36u05ehktgw5h5udj8hyudd9057d9tx9r6zef", "coins": [ { "amount": "303617054", "denom": "boot" }, { "amount": "303617054", "denom": "tocyb" } ] }, { "address": "bostrom175tm6fucmk0e29cfgzaud6kqgksy25p884kjx0", "coins": [ { "amount": "26259431", "denom": "boot" }, { "amount": "26259431", "denom": "tocyb" } ] }, { "address": "bostrom1v46pz6ddetfc3tnvdr28ss0l48jhazgynvp3c7", "coins": [ { "amount": "14979552", "denom": "boot" }, { "amount": "14979552", "denom": "tocyb" } ] }, { "address": "bostrom1stfw0z5nf2ncxxtrk7zndpf2dla3nh379egwcy", "coins": [ { "amount": "61678847673", "denom": "boot" }, { "amount": "61678847673", "denom": "tocyb" } ] }, { "address": "bostrom147rnn0rxqkythj4j9ccq0kytmh7f005rn0a3zj", "coins": [ { "amount": "55311848847", "denom": "boot" }, { "amount": "55311848847", "denom": "tocyb" } ] }, { "address": "bostrom1pswgrf5ap0kld3lpun5z4x08wh7nmgamd8mgex", "coins": [ { "amount": "8641145058", "denom": "boot" }, { "amount": "8641145058", "denom": "tocyb" } ] }, { "address": "bostrom1wt9h9wm3zf7yzsy68x7v8p973w02kw8yyurh55", "coins": [ { "amount": "10537454450", "denom": "boot" }, { "amount": "10537454450", "denom": "tocyb" } ] }, { "address": "bostrom1ucl2c39dpwqm9pp6cvmlazn2tkwavszhs27j96", "coins": [ { "amount": "9691549420", "denom": "boot" }, { "amount": "9691549420", "denom": "tocyb" } ] }, { "address": "bostrom16w2xwdzf6tzucpwcjjqtg9656a4kkv7g2f6vk9", "coins": [ { "amount": "458125791", "denom": "boot" }, { "amount": "458125791", "denom": "tocyb" } ] }, { "address": "bostrom1hmrxmc27fu4ggdpvpxqtahn6uvtj38vuu77a02", "coins": [ { "amount": "1854496759", "denom": "boot" }, { "amount": "1854496759", "denom": "tocyb" } ] }, { "address": "bostrom1uwfk6h06w8vnhmyp48vwcpgwncsec8yv3z0xyg", "coins": [ { "amount": "1502715615", "denom": "boot" }, { "amount": "1502715615", "denom": "tocyb" } ] }, { "address": "bostrom1nuc82t22xgp09rs2tdnlxxgm95pjg5matjwwye", "coins": [ { "amount": "3573424538", "denom": "boot" }, { "amount": "3573424538", "denom": "tocyb" } ] }, { "address": "bostrom15kdrahda8qcyfa9xe8kt2f737m22x2sleslj5l", "coins": [ { "amount": "1631606648", "denom": "boot" }, { "amount": "1631606648", "denom": "tocyb" } ] }, { "address": "bostrom1n89a8avc4j7cv75lfsyynx5kazlk80ar5qcdx6", "coins": [ { "amount": "41000576", "denom": "boot" }, { "amount": "41000576", "denom": "tocyb" } ] }, { "address": "bostrom19vgwu99fdawejnedgsfx8dmxuc0z4emjf7a044", "coins": [ { "amount": "5014404214", "denom": "boot" }, { "amount": "5014404214", "denom": "tocyb" } ] }, { "address": "bostrom1s6v5ragv9gg3sq7j3aeqtyy82uaxv3y05hzhh8", "coins": [ { "amount": "4273801138", "denom": "boot" }, { "amount": "4273801138", "denom": "tocyb" } ] }, { "address": "bostrom1y6huw3naar38u4rtgqmlh9smfu93gszst9tawp", "coins": [ { "amount": "1688512495", "denom": "boot" }, { "amount": "1688512495", "denom": "tocyb" } ] }, { "address": "bostrom1hqeqy4s039q0qcpayqcyaq5hyyvmph97t79m9n", "coins": [ { "amount": "1190379955", "denom": "boot" }, { "amount": "1190379955", "denom": "tocyb" } ] }, { "address": "bostrom14h099ukgvp4fm9qs0xnmljzhevrmneq6m6cltv", "coins": [ { "amount": "978084362", "denom": "boot" }, { "amount": "978084362", "denom": "tocyb" } ] }, { "address": "bostrom1xhk0s2ynz2sq3ak3lr4u5gg0da4vyaxkfjhg7l", "coins": [ { "amount": "924447759", "denom": "boot" }, { "amount": "924447759", "denom": "tocyb" } ] }, { "address": "bostrom14z6glatrayal5j53632kcefskyge6ujmgshqfv", "coins": [ { "amount": "327466267", "denom": "boot" }, { "amount": "327466267", "denom": "tocyb" } ] }, { "address": "bostrom14n625exc6ftee3t6tez3hj47lv49amjzan5pkr", "coins": [ { "amount": "236797768", "denom": "boot" }, { "amount": "236797768", "denom": "tocyb" } ] }, { "address": "bostrom1fhj7pkuvwflr7z7ngp2v9tj7g58aq2tjgvqfaj", "coins": [ { "amount": "135097195", "denom": "boot" }, { "amount": "135097195", "denom": "tocyb" } ] }, { "address": "bostrom1l4krahjfp87exsmumzpnrfeaer2gsghpuwhfp6", "coins": [ { "amount": "112519320", "denom": "boot" }, { "amount": "112519320", "denom": "tocyb" } ] }, { "address": "bostrom1udal5nr3lz7mg7j7k79se4rz0tsjj8lur45q99", "coins": [ { "amount": "9724669100", "denom": "boot" }, { "amount": "9724669100", "denom": "tocyb" } ] }, { "address": "bostrom1n55zyf6wlvh8jp4wxqgx4ta283jx0e2n2tutgm", "coins": [ { "amount": "1099456389", "denom": "boot" }, { "amount": "1099456389", "denom": "tocyb" } ] }, { "address": "bostrom1glgevt43557u6s7a2q9q40kzt8myw4ngcv6wr6", "coins": [ { "amount": "309112576", "denom": "boot" }, { "amount": "309112576", "denom": "tocyb" } ] }, { "address": "bostrom1mj0sj4eaar5qnjn3l05ep5wgq3l6agtvvqwvyk", "coins": [ { "amount": "1178234463", "denom": "boot" }, { "amount": "1178234463", "denom": "tocyb" } ] }, { "address": "bostrom1sm9sq4wnn62tk5yz0x3fvvx2ea9efguqwvdu64", "coins": [ { "amount": "722135415", "denom": "boot" }, { "amount": "722135415", "denom": "tocyb" } ] }, { "address": "bostrom190y8vwhmyjdnk7cfutcm7u8haw80xyejdwxsql", "coins": [ { "amount": "56952126", "denom": "boot" }, { "amount": "56952126", "denom": "tocyb" } ] }, { "address": "bostrom1rfh303jsl5297sxgs5txpt97lvxpjt4he3yy5r", "coins": [ { "amount": "54988260", "denom": "boot" }, { "amount": "54988260", "denom": "tocyb" } ] }, { "address": "bostrom12u6qgyrdsy4xmw04vfkkkh9a9tqzw66g59hudt", "coins": [ { "amount": "27886903", "denom": "boot" }, { "amount": "27886903", "denom": "tocyb" } ] }, { "address": "bostrom1pjvkddp4fmx8ym5j7s7su8kn3zuqj255djzpja", "coins": [ { "amount": "4022780851", "denom": "boot" }, { "amount": "4022780851", "denom": "tocyb" } ] }, { "address": "bostrom13nrdf490fsuv4rwjp02hlyvalqjkn5u6xxqvqz", "coins": [ { "amount": "14925385", "denom": "boot" }, { "amount": "14925385", "denom": "tocyb" } ] }, { "address": "bostrom1fp9q2t9zn9gr5qjh9wljxuavtcsc4h8uqgnm2e", "coins": [ { "amount": "12175972", "denom": "boot" }, { "amount": "12175972", "denom": "tocyb" } ] }, { "address": "bostrom1u2s32xsws9y2sskz6zvn7lawepdqxad5dcsyy6", "coins": [ { "amount": "330695020", "denom": "boot" }, { "amount": "330695020", "denom": "tocyb" } ] }, { "address": "bostrom158mysantvvk7x65tfhhuu8q2va4ls34r54hk78", "coins": [ { "amount": "9819332", "denom": "boot" }, { "amount": "9819332", "denom": "tocyb" } ] }, { "address": "bostrom1clalfxmsrqdgnqq5uxlx0mc983pyp3wq4xl03c", "coins": [ { "amount": "4713279", "denom": "boot" }, { "amount": "4713279", "denom": "tocyb" } ] }, { "address": "bostrom1wf8alywyvlxy2dqfe38efdpdmuscfpf4jxvg6r", "coins": [ { "amount": "4320506", "denom": "boot" }, { "amount": "4320506", "denom": "tocyb" } ] }, { "address": "bostrom13zf8kghx7h5fyttk6xdnjqn9c87z0rd36sfqjw", "coins": [ { "amount": "4320506", "denom": "boot" }, { "amount": "4320506", "denom": "tocyb" } ] }, { "address": "bostrom1cc43k76udpd3xvpn6md76zz3ru6nvcnreeg2eq", "coins": [ { "amount": "3927733", "denom": "boot" }, { "amount": "3927733", "denom": "tocyb" } ] }, { "address": "bostrom1l5x6kerswths5xl0d6672y9yyn9mg2vw8yz59q", "coins": [ { "amount": "3142186", "denom": "boot" }, { "amount": "3142186", "denom": "tocyb" } ] }, { "address": "bostrom1qe4sguqg8ztlyy7psf7lzwr4ahph9j36k5hltz", "coins": [ { "amount": "2749413", "denom": "boot" }, { "amount": "2749413", "denom": "tocyb" } ] }, { "address": "bostrom1mn8ev805fde2xswght0snwfayfj9tn54dt24zg", "coins": [ { "amount": "2749413", "denom": "boot" }, { "amount": "2749413", "denom": "tocyb" } ] }, { "address": "bostrom16vc2mjjfxx2h5m6jpdp4nqfu5095qaeeq27qxj", "coins": [ { "amount": "2749413", "denom": "boot" }, { "amount": "2749413", "denom": "tocyb" } ] }, { "address": "bostrom1jmhqgld7luvuhh42wac24z6nlggjvkc7fzgs62", "coins": [ { "amount": "2356640", "denom": "boot" }, { "amount": "2356640", "denom": "tocyb" } ] }, { "address": "bostrom1qjknpllzp6w6qsxxjx52zxald29wpyzljznzdv", "coins": [ { "amount": "1571093", "denom": "boot" }, { "amount": "1571093", "denom": "tocyb" } ] }, { "address": "bostrom1eq2h9enjxsg5s08scr69lzwde8fl79snw20dc8", "coins": [ { "amount": "1571093", "denom": "boot" }, { "amount": "1571093", "denom": "tocyb" } ] }, { "address": "bostrom1dx8mvxfu6mpfnjehvdkp9lsvu78ek2gjr7r766", "coins": [ { "amount": "1571093", "denom": "boot" }, { "amount": "1571093", "denom": "tocyb" } ] }, { "address": "bostrom19uryr2zuxcfdevfq429jng9a2evxwadlsky04c", "coins": [ { "amount": "198757551", "denom": "boot" }, { "amount": "198757551", "denom": "tocyb" } ] }, { "address": "bostrom16862syzdtc6h0sxz92jhnjjas5yhhjgzvyewwd", "coins": [ { "amount": "1571093", "denom": "boot" }, { "amount": "1571093", "denom": "tocyb" } ] }, { "address": "bostrom1teuan269feyw4ax94jfp4pcgrhqnn28gxxz8mw", "coins": [ { "amount": "20201178320", "denom": "boot" }, { "amount": "20201178320", "denom": "tocyb" } ] }, { "address": "bostrom1yvlp9gzqaufwz02swp5wqsqhlmfcrcl8m22gzm", "coins": [ { "amount": "200785547", "denom": "boot" }, { "amount": "200785547", "denom": "tocyb" } ] }, { "address": "bostrom1latzme6xf6s8tsrymuu6laf2ks2humqvfcz7m6", "coins": [ { "amount": "785547", "denom": "boot" }, { "amount": "785547", "denom": "tocyb" } ] }, { "address": "bostrom1ec9da8avgv7tnvsx3v8g8veqrhlqq26lnncg5t", "coins": [ { "amount": "785547", "denom": "boot" }, { "amount": "785547", "denom": "tocyb" } ] }, { "address": "bostrom1c7pv6zyza76f3yhv0zvjc042e8m7w796qmvkse", "coins": [ { "amount": "785547", "denom": "boot" }, { "amount": "785547", "denom": "tocyb" } ] }, { "address": "bostrom1yslufs9kq762qty0wh62c8qtlpm2202ejmw4ef", "coins": [ { "amount": "392773", "denom": "boot" }, { "amount": "392773", "denom": "tocyb" } ] }, { "address": "bostrom1y935ede6znmcvqdmn6mnl2aa5zxcqvvracsczu", "coins": [ { "amount": "392773", "denom": "boot" }, { "amount": "392773", "denom": "tocyb" } ] }, { "address": "bostrom1y675phjdvw576ahlcmlamrzr28rjht9mx709lg", "coins": [ { "amount": "392773", "denom": "boot" }, { "amount": "392773", "denom": "tocyb" } ] }, { "address": "bostrom1kjhdx3nkh6krdhryvjzkq33xwh6wsyy7y8ark6", "coins": [ { "amount": "392773", "denom": "boot" }, { "amount": "392773", "denom": "tocyb" } ] }, { "address": "bostrom1jxpe7neu764uasz5y5u4lrr5jtltv430gjm9dw", "coins": [ { "amount": "392773", "denom": "boot" }, { "amount": "392773", "denom": "tocyb" } ] }, { "address": "bostrom1hq8d6pu2l6wkrwu9jxcqjcu55g8l43zxmrd6dk", "coins": [ { "amount": "392773", "denom": "boot" }, { "amount": "392773", "denom": "tocyb" } ] }, { "address": "bostrom1c4h647a9rj8n9zye5ttmh9chpg66f3ffdvdds0", "coins": [ { "amount": "392773", "denom": "boot" }, { "amount": "392773", "denom": "tocyb" } ] }, { "address": "bostrom14ysuwg6p4fzfaa6tg4s3hazu86pfevsw4cegce", "coins": [ { "amount": "392773", "denom": "boot" }, { "amount": "392773", "denom": "tocyb" } ] }, { "address": "bostrom1x7wp0u877dkw7m84jv54c9g6zpd5r8t2nm47gn", "coins": [ { "amount": "33812731064", "denom": "boot" }, { "amount": "33812731064", "denom": "tocyb" } ] }, { "address": "bostrom1gss7y04dky2fykck4dyp0pe39wxawlxm2l0yj2", "coins": [ { "amount": "28704261935", "denom": "boot" }, { "amount": "28704261935", "denom": "tocyb" } ] }, { "address": "bostrom1cerh237zd5rdexptjw8ryhwdf2tc9eupz7sfn0", "coins": [ { "amount": "20918517127", "denom": "boot" }, { "amount": "20918517127", "denom": "tocyb" } ] }, { "address": "bostrom1fz799u9jc0umceng3nkjt0njxy6y3550uq06jn", "coins": [ { "amount": "14973655085", "denom": "boot" }, { "amount": "14973655085", "denom": "tocyb" } ] }, { "address": "bostrom1wzqyjejz5px38vgqsegafrcexl3963q9dsgqh9", "coins": [ { "amount": "13098969682", "denom": "boot" }, { "amount": "13098969682", "denom": "tocyb" } ] }, { "address": "bostrom1evz2xfd6sam0kzz5qc5lje4s90vcgyyrzz47pm", "coins": [ { "amount": "11323309556", "denom": "boot" }, { "amount": "11323309556", "denom": "tocyb" } ] }, { "address": "bostrom1mzmzlzk4xpm6zy68c43e6hen98w07yhfedumgg", "coins": [ { "amount": "10780033350", "denom": "boot" }, { "amount": "10780033350", "denom": "tocyb" } ] }, { "address": "bostrom184dur4s6pldvhvcyputu6yshsm09s6wmvylt8k", "coins": [ { "amount": "5728639830", "denom": "boot" }, { "amount": "5728639830", "denom": "tocyb" } ] }, { "address": "bostrom1gyhwacrpqwues05pkavw7xwehcqsmgruy34zps", "coins": [ { "amount": "564067516", "denom": "boot" }, { "amount": "564067516", "denom": "tocyb" } ] }, { "address": "bostrom19wtkh935tx2ut2n4m6tjvkfvew4shaeezfl7em", "coins": [ { "amount": "59855356", "denom": "boot" }, { "amount": "59855356", "denom": "tocyb" } ] }, { "address": "bostrom1a2kn43nquua6gmr4n42htmjpceqj7fzushe28h", "coins": [ { "amount": "52853070", "denom": "boot" }, { "amount": "52853070", "denom": "tocyb" } ] }, { "address": "bostrom1u74s0z4ft63c6zz7g8xs62esdtdjkzuk4zf0rt", "coins": [ { "amount": "42282456", "denom": "boot" }, { "amount": "42282456", "denom": "tocyb" } ] }, { "address": "bostrom1d9en5u0cfaucavx848qeq4k6ywqd3z5d5a778h", "coins": [ { "amount": "20000000000", "denom": "boot" }, { "amount": "20000000000", "denom": "tocyb" } ] }, { "address": "bostrom1edwwsevuywe3sx82sustvyx3f3cvjt44ugccgy", "coins": [ { "amount": "20000000000", "denom": "boot" }, { "amount": "20000000000", "denom": "tocyb" } ] }, { "address": "bostrom1gcy4f6f2sc73aegd9r68rt2q6teekl6swjva3p", "coins": [ { "amount": "20000000000", "denom": "boot" }, { "amount": "20000000000", "denom": "tocyb" } ] }, { "address": "bostrom1d6nkeqxmme3564wd889kr6cjed3asxqzjve0wl", "coins": [ { "amount": "20000000000", "denom": "boot" }, { "amount": "20000000000", "denom": "tocyb" } ] }, { "address": "bostrom1djdfq5mn3dzm9whpznczxz77s8ep2qggc5w5xn", "coins": [ { "amount": "20000000000", "denom": "boot" }, { "amount": "20000000000", "denom": "tocyb" } ] }, { "address": "bostrom1z8fyzv3mjfccvrxhckr2u3lnc0hrgrlm4zkf8c", "coins": [ { "amount": "20000000000", "denom": "boot" }, { "amount": "20000000000", "denom": "tocyb" } ] }, { "address": "bostrom1tcnlvf6qhlc3x7ax2vk3vzhxhf8wy8xrnjl72d", "coins": [ { "amount": "20000000000", "denom": "boot" }, { "amount": "20000000000", "denom": "tocyb" } ] }, { "address": "bostrom17ud38eyfkd800kvw3c9kl3zpvgvj296nfszelr", "coins": [ { "amount": "20000000000", "denom": "boot" }, { "amount": "20000000000", "denom": "tocyb" } ] }, { "address": "bostrom19rtverjn8kw7dzwzch2elktxgcmak6dlqugxfw", "coins": [ { "amount": "20000000000", "denom": "boot" }, { "amount": "20000000000", "denom": "tocyb" } ] }, { "address": "bostrom1mlqakhlxplhlezk80lph99wcy377j9dk2qx3gg", "coins": [ { "amount": "4000000000", "denom": "boot" }, { "amount": "4000000000", "denom": "tocyb" } ] }, { "address": "bostrom1ssu4wqtzvvmwcukcv7l8zxny647mdx03e0t57j", "coins": [ { "amount": "2001189000", "denom": "boot" }, { "amount": "2001189000", "denom": "tocyb" } ] }, { "address": "bostrom12reh000lje8y20wshqmgl8tg70qggt2ac7qz45", "coins": [ { "amount": "2000000000", "denom": "boot" }, { "amount": "2000000000", "denom": "tocyb" } ] }, { "address": "bostrom150svyax8m8dwljwenc8xxtsg0avud07m5frlrz", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom14tjwqqyha0c9r0s29dm0n0zdpdc4hfrvn7jqsq", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1x8r0ktn36dsxsadnp3863txyd9pksrp6awcuaa", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom19lsruwa85k93ahzkdwaydyrl6ehz9dmmkava0y", "coins": [ { "amount": "400000000", "denom": "boot" }, { "amount": "400000000", "denom": "tocyb" } ] }, { "address": "bostrom1tyzmkpn0axquu4jlht3lllsmq03um8kn5cu5pt", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom10a9mqy8cu04nyz3nj934ck39p6u9ddjt9y5fve", "coins": [ { "amount": "400000000", "denom": "boot" }, { "amount": "400000000", "denom": "tocyb" } ] }, { "address": "bostrom1f2uslv6udnjwyqkdngc7rswp5vkmgavzgy952g", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1t7gw3d2jz4qc6k6umgkazvfyeydjv7l6nym265", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1rc2647d9nftgwwh9n5vaw26lnjdrewc4dum68g", "coins": [ { "amount": "400000000", "denom": "boot" }, { "amount": "400000000", "denom": "tocyb" } ] }, { "address": "bostrom1zejjt25xw9gwvhave95ykkvgqjtk7j56fe9cwh", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1vesdfkzd36m08clhvkpusq4gv0dnqm28rm2hey", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1ypvt8rf8md7qedvnk0p8cvd6mnffepst8f05p7", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom167hs9ma63wd02xym0vjw80uqlekt0cs54ass6v", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom17tksas9e4nkp25vgwcsd7z6y83pa6u7sddyyez", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom14thj9udwenk5q8c5ey2urude2j54xud2a26rp3", "coins": [ { "amount": "400000000", "denom": "boot" }, { "amount": "400000000", "denom": "tocyb" } ] }, { "address": "bostrom1y7ku6vf9vq53pv4y6lw2zjn4d5ul3javm92whz", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1mzn966mlprxgkvayrqu209069px0qwz7gzn799", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1cjeg60652ueyu5222l3atmm8vrhlq4tfusnswk", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom13855g4d5pfhtnqemgp700qs36qpjdnaz0dx2m5", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1ueywgan39tj27pdysq0d54cqvcwyggf6eves07", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom197h938dvw52kzf2l7gke2u5tcz3grvlexeaq0y", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1pkxtd9xwmqwg08kjgz9xqyee3aw7j8upd89ah6", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom12arnsa069zhad0e40mlgy034n7aq77e2nxdven", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1m3yh7j0jefp9dl26cz8fqexfg8tds39lh957jw", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1ysn8jyjv464fv4wpt40vezh7d5tw05tc9v858t", "coins": [ { "amount": "400000000", "denom": "boot" }, { "amount": "400000000", "denom": "tocyb" } ] }, { "address": "bostrom1gh8tenvx2sf9kj2c359ey6s5k0vzlrl7z4t59z", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1svwchckmrrkfl7py7l2fz3esla7lwmalld4yr2", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1hmdjgtv3yq4qzyuk3ynyt42sjntma8hqarepjd", "coins": [ { "amount": "400000000", "denom": "boot" }, { "amount": "400000000", "denom": "tocyb" } ] }, { "address": "bostrom1wr0mqeyea45u9av63srtvgr553nyg6l9p57ezr", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1e20dl8se4v2ev79qcay3ag7uf5t98gampz0d48", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom12c8kh7aaz2gg0l4nkd73t58nhurdaren55atua", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1ftyx5guwf39fz4nc5n5nc9fua36cq344rm2d43", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom17jq8ev7n4e3zv8zdek5mccvxcgxxtkwva5vwtx", "coins": [ { "amount": "400000000", "denom": "boot" }, { "amount": "400000000", "denom": "tocyb" } ] }, { "address": "bostrom123wttw3lu62m7lcg23rkwr88cvv8apjmvkuj9f", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1j5wpswepyxva5vupvg05pq6jzqh7ttdvepkhp3", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1wh5gfxyz8x95qyjlc2s24h3czr60vfehwt49xa", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1z3u9w3vyq6sw7ndxcdpjkgvlj0qaqm6spc3jmp", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1pzyt3y68zcnvl7hkvuffqfedccaptf6nt2x8ya", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1pzxnpyvxr6x9z64y6w3ctv0cvcx9sp90ehj960", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1pvu65ccqw3fmgq88j2j485wc6qm96nx7h7ln4f", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1nqxwnut0hdgsn3l9zaladaft5xt9c6ex9qquza", "coins": [ { "amount": "400000000", "denom": "boot" }, { "amount": "400000000", "denom": "tocyb" } ] }, { "address": "bostrom1njpfrygstn6r5awzp77keyhkl3wfhzmvdz2pug", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1ke9xxd3d6y0ttduac062zvv3r0jtakvhkvqcjz", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom15ak23s0usm36hv2e4kajhe0yx592hw474p3gkq", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1gffprg0nuvj9ve39s9rjhjp04u7k8xwan2tzff", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1yq5h0gjxuup83hdz53utukwhkkz684mk3lx7cr", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom19rfaqnnz5fy3qct8qxzany94t2p7h0rrc75lmz", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom15y8g5ggq2lslncdnlcscqygyesefmjy0t4cae3", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1gfkztltd789py02jcd79dnkl252uej7x8pnx4p", "coins": [ { "amount": "400000000", "denom": "boot" }, { "amount": "400000000", "denom": "tocyb" } ] }, { "address": "bostrom1h9k38zr5a532jzl0hsker9qz785m822zmqw974", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom18ghdg8y5hx6esxm6ndw3ywgtalvkmz48zeyc6z", "coins": [ { "amount": "400000000", "denom": "boot" }, { "amount": "400000000", "denom": "tocyb" } ] }, { "address": "bostrom1zy3nxgwtw9hr99tzfaxasgwklm9ev843fju9zl", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1vmfs06hv80gc8jcpzu93ld4494azendxfalh2g", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1d66wegxpllcsnrzv9saqugpk2dausa836qlqaz", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom15njl9exppdfms5fg4zz9wafn4a95lfj30ftx58", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1v2fzs3a8mvm4nhsfcpk85gt3d8rdacv6zggl9r", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1fm842pq6zxaqs86fm30xv459gx7hm7f0ufujvz", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1rzr7gnkm3kdqmzqya7ky98m8tnnmtet58deav0", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom16gtt4cmrvg2us2rgecym9zt65zet7qq2euzvdf", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1jsdfjw0pjjj5thg7z2tpm30njusrlsagtac7rs", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1z33aen2znsmgy7wwzavwh2q0u7cu4e9xhky379", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom10r2sn7sasanc0tuw5wzupxvlpht5uv267her62", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1gtma98yjsx43zc30j99t7t0tmdjt2gyp9e7g0r", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom185y3kgv3e6t4sue0a55jyq88hv76th3urnca4c", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1xc6jdlqd8gd9e6p73xdc2yw7ad3tnl8w7j4wsl", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1wdk6rndatlj8dpxq799vmu50zft7xk5768ej2v", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1uz3xp4au0rxawmct6ffj0u3le7uglyza43appc", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1uym8hd4pum4zz2mpkf93y8435u725k97e2c38p", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1u8yt9tvnwvvvlm36w97nyg27ue797hrvkz6eux", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1u4427txgc9pulkuu0wk4v9cjxqa0dxee5az972", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1epcd5upewwa7s20u6kgf9uywa2f7c3yj6zaeg0", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1tx6dnqh0nnj05uuell7rhnwhennscehlnjylxv", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1ypzhtfsyuejekw0w0z207wyedqm3xqafc8nu7g", "coins": [ { "amount": "400000000", "denom": "boot" }, { "amount": "400000000", "denom": "tocyb" } ] }, { "address": "bostrom1s4ytylknecgkp7sp3jgf2f5lj7mm2xxz0f9rl3", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1s05hsv6fxhkpclwxzgnlfjjk7qdm78nmpchj08", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom176q2gvutyk63dzknylcvdhp6lyjwu5w9fdmmev", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1e08w7wrjn05gl06xkwnlfmud5f6trdkrf0drg5", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1pzp9nadejsjzfkpfl9k7ktu2cfhprw4r7qvd5p", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1pt3a6xk432vs8lp0z6ya3qhqhxks99xe4sxxqq", "coins": [ { "amount": "400000000", "denom": "boot" }, { "amount": "400000000", "denom": "tocyb" } ] }, { "address": "bostrom1damlfdlp8yynjvrmv6pd3t33f4currrhe4cm4z", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1cmhrs08sqv0823mj057svp8jerp6avne6xmtrc", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom19wlc6vms3qkuy48wgg2dl06veahgxl47s8859j", "coins": [ { "amount": "400000000", "denom": "boot" }, { "amount": "400000000", "denom": "tocyb" } ] }, { "address": "bostrom1h9zrqgwcjtul3s9qxf0hk0ym9alm44ztywkfyj", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom18fudz7p6ah9yvdr4p9aflp8pgzngx84cem5lra", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1e8dsx8yx9mjn8v8egz2n5vafkymqw98wy4z6re", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom189tpr8vg4qvwn7fgs6szkqr25yrammvvlzx0zr", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1xvsukg4tltfzduw0lsvgqyrhe6rzrlp472ln92", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1w7f07762zelhx4spzkndmygh2dz58g3nn58v7q", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1808q4nv5qafkk8ec9h56wwth6sl5a5yd0elve6", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom15a8z9l8ufw8v8zdddfhesnmfzwwhua7axrmfxl", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1undz2328av9agfhaguqs8zxzejv5zqcc9grdmv", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom17vw0qcu9j8t6jhh83sjrzj07nwg9nndfcpw9g0", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1evnwfeuqsgkjwe5qwe5acyy6m4w5ch03m3e7a6", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1t5r4uhu0tscqw380t6hqmvrgyhlrj3u43vsm43", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom17kwvcuvar02ldacltr48373rm74z8lfkcq80vj", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1r7grd2sazgzsy8y0c8wlsnjyhdc0sq4npr0v4q", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1pfwja2fu2qcqvdws6rcdr9y6za46dklaxc83fh", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1p4uyyk8sc2arl4n9egw3xrn9g7rpkzlerf4nlc", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom16gxdwa79rsvkjaawpcpswthgahm56p4mpu8fe9", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom13nef2p2g48kmj83m7f0ey76q6p9cdyrn03x4tz", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1m9x4gg6frezyeqldxdz4dvegxpcytxnapgykwu", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1kfz37afuxfyajrzk7xv6937xc0jsq4zd0ce7dz", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1kae5k3nnzs3q7tar4ec3w29w4avd8saqujpjk5", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1hjjsjgv7sx88mxfq9y44ql24xs76jj3w7y9ff8", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom130avjyegx7glgnqvraetqj6ztacrqv9kdwawkj", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom104rtaftr9xmx6dcakempk590tfxx4ytddqcj97", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1f6tmyjffs0p7f6xeh25esjhawxu2kll9j00a47", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom105c5jk0xwzlk4pexgaeqkxq0xadtqchc4lmev6", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom185tek8r0ptelug0erducctzc4d83q5np3339k5", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1z0m5tcv4jde5acv0w4dms537wvntgj7x47zmeu", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1fzkp5pux48ux72wsgls9lhxp5cq2tqsy32hfec", "coins": [ { "amount": "400000000", "denom": "boot" }, { "amount": "400000000", "denom": "tocyb" } ] }, { "address": "bostrom1nsffk0nt927vn7pdsk8epzjeqch3yfzkzq57pl", "coins": [ { "amount": "400000000", "denom": "boot" }, { "amount": "400000000", "denom": "tocyb" } ] }, { "address": "bostrom1e4cnw86pl73k2sfv7uwauflfl42qzncn4akyv7", "coins": [ { "amount": "400000000", "denom": "boot" }, { "amount": "400000000", "denom": "tocyb" } ] }, { "address": "bostrom1jlu5u2sj0afddmcj7lxfy0ng466s8l2qdjz24v", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1y9tvvunr7uaqjjw8u6xn5muypq6pheyz5gygm3", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1qsm0ujra4vdwymc5vrtey2rvalyq8392h75nr4", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1jgvy2vr96auye3er6n3tkhlu9hnxs6h3a38rpp", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1jcj0w0e2khy0asm7dz8883xnepzmaxylwez7j2", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1q22fvnhna2zg2g2xm6s5587w8fvsh2zzfeey68", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1amletsu7926696dpeay8wrewqgww5s7yunjjxr", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1qkltelhy5zsr4kfrefvwsupxyt6y9skwjpd7h4", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1nfdyvvjy5hum8gpgmt29d0m5y4te3ekpfyz7pw", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1hjz37u09vws084cvwjlr5t27wmsrzm9tmfspu5", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom16zykdjnfjdy5cy3phuymmcghh8x24eah2cmmpu", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom15pax03gsgw84lsygpxyyvtthd8fswrqp7wjs7m", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom124ll3q05an955eh26ygn34u5gtm9287arjrgj9", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1teyn0utv6yhnwux44ycfvqh6z888pvjaz9cz6l", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom10905rstxf5tzj0w6gguaa76ma7s32v48um4w9z", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1m7y6qezuemqe6n535z7s80ee8zw4zg486vr53u", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1pkhgpslggp3t0nrwskvgczxmavg7yejfullesx", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1zyws7rajm9f3ql6jqqpzvnml0aym9vspd7tjxk", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1pa0rcdua5v9d4vf09ksnnl7t96nfkf3w37k4dc", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1durjade4he9l23rw38azruzfttpmc8223n6r87", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom16jvmfza0q60umemx2pv8s5kle2h8g9x6jj9fkq", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1gywad2frusetg26dyh83cfaevacravashyjwg6", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom16kqpk5jg9e5ucxv3e003mf48yuamw4ce5ww4la", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1zr9urr3m42w7pu5h5xn7rvghcdk5vtrtmfw7wf", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1jet9jf456dja8vqlhk407l06yvfehwzuvjaynv", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1q8ajen3vu5v5uu4czkvqasqvw827dz2nqq6d0s", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom12w56mhf4nsfchquw0sgzwn72qkzvfvquxhg6dn", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom10v8qjj6haddx7wmnr65mcsllu8xunkee7zg3z5", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1hy8dexwz6ynlnnaj8ge7jvmzs4c6qmz6yh97lc", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1vpp9vy0fnxxw8yk5t2cctutpfv8pprvyhnjw90", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1w0u83ty3nmflg9846zmh28u0hweccs3fzfpx0f", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1z6lhk6u25fceqylmgv65t5py0c8kclgkszmqyx", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1zcf0ph3k4p2q2pl32zqspy5f7jkgxd5s4kcd66", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom13s4egz6pqg6a88dunme3esuee5w7qlkjttcs08", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom12w37894jf7rt2ck709rk8xa23lz3lg9tv93tlz", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1sntt4y34tghn45vw97az7mz4vkcw8kgregkph7", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1pa0lcssmjkkycdvrhhzey5h94v34wuf9u4ths6", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1l9yx676futn4h28rxupsvk7evl9s68hrufetdw", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1knpgev72f2empt8j8gcn24my8kdasy2lcezjea", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1clr05sms7eklm509ger6jdzhgheafskv4wwxrg", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom186tpdptavhzz7fg83vnm4r2y85cfqyg6sntmun", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1qc4t2q45f826cfc7k0y45ma8f5qrrfv2nkly33", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1n0wkta56ktj93nzpe9amkgrzq7rhzt3gy6m8uh", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1exul86z68fzck5jra7jp8xdwvmfz5p9qyuh8um", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1melp9r22clnjzzudd0thvs5zzveqfjyl9xfw54", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1zx70t5xqc8h4kmvrssdc2w82v9ksw0r82a99av", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom17ssaukj47urfj6c8cgywyz9xhgqz3tnpy7n5kv", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1znt56em2psvx8ylfpplcmpy5esrea08g2psvxm", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1tz4yrvqlw87e74n783n0da4pttay2ypsfq6668", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1prrtyfgrw2tzj9kua5eu7tnctt474m36eygux2", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1ftkw5j528j94cajk4rvqum3k7mhhmpvyc8k7yg", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1pe42d4gkg7smf9na6dvh5twq9hgczsag4elx84", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1nscf69wvc0wkgqm8ma79qv8cr6j6zq3dt0t898", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1exv982mrkyfd967xv7fam7lq8h3ce3dvcnd4s3", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom14q65nd2ft893dagpln4fq39wutv2xmpe3kc4w0", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom17llhhwjmglhhqumz72e4jap5cj39r8rwar7zzv", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom15k9z24v0thrxffetjp97493ec89zlz7re07pjj", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1y795vkzvczrauey63vmvvcjr84l3fjheqd8f38", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1qf560sekun7kjsu4r0puey5u4fn90025f4q2p2", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1v9p7ukxpw2yjk7eqm8720vkgqq5qlk7w3jqgzu", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1a57rc9cnhdn4l843ca4990aqldh5wmq0uuetzg", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1q2ajajyu0t544tudcnvk7xcznerhylz36p5vtc", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1ayc0pueqve9a3xjpgwh3p4l6hjlyvfpvclvldm", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1jmdtfuxag0deeuyxmj4ge2mqhvc200hlmzyztf", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1k24kf4reet2lstvmkx9a4j0r87xfuqeqh2lprz", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1e0c3ehnfzvcxvwh9fgzyfc2vqshy9w53du7hnv", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom178nsekn4qcdkqqmv95qlmp68kaqpga3zpsdnf4", "coins": [ { "amount": "1000000000", "denom": "boot" }, { "amount": "1000000000", "denom": "tocyb" } ] }, { "address": "bostrom13uz23f4stcg8esqvvc7d2w9psxv0dya5xaq5ne", "coins": [ { "amount": "1000000000", "denom": "boot" }, { "amount": "1000000000", "denom": "tocyb" } ] }, { "address": "bostrom19trgcp8uldtc5xtnpf0u7x7dk3t3jcp4y7cusm", "coins": [ { "amount": "1000000000", "denom": "boot" }, { "amount": "1000000000", "denom": "tocyb" } ] }, { "address": "bostrom1fn4ep44ud3edyh304ta38f55xd6pxswsw9e23z", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom143dfs4ur5gjvwgx8l54jjz27rq57us0zz3hqj0", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1e3je4h3vkxywt2sf7mudelhf6zrx405yfgczkf", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom180upuj8yp0326px2uys9r60xrlhpsa6fwryf80", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1jdypscylf6hjlrlva03tx5vqqkcdnllg6rpza7", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1r85972mwrka5w9ct6km58ww9jl9sh46fx559fu", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1xz2dkqrnrvq0ezc0vxtcvhwy39xr63vxzfedsr", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom134llrhdus60n7853fn3ulmx6uy7evsx3ltzstt", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1pv5clfxxfpqvuerquue2vgr2ndgh0h50jx898c", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom107v45crxqedhmf4yqa9y98v99wm2078fwtklsq", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1959r3zp37k9yuz8kjtc4feayyfkkxpcv43mu0w", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1qh6eavdzp5ffks2rvd5mjt3rdmjxg3qm5l4pw2", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1lk7m28npegzy0sz5s06sy95n27yzrj4d3rytdg", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1clk49u6rvv8c40udn9qgp0s8hv5uvfcgxqptky", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1gws6ulm3u23txc6p8kv6ew6e2zn45udrwjkdqm", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom17rg7cldfsqfmv53n6r7qmjmcge7ucxx2hhum0q", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1kkwwsk0v4h7tmccr4sdmpyl2j2gvfah6jzw7n8", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1ggh3zff5paq5c3r2j34mquq9lrcc7s0nvfnuwz", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1gp5s4tetnk7ng49g58uhn2znfpmgs4cfdq4ns3", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1ejkkddkuw63zn557l0lvqq3gmjcra53ealmy2x", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1jrp04lvvpzkyylr4l7e5xp256l9yd4hdhrpmls", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom14c8rllqzmgyrkt8aeyanprl7g3adrlc2flq57a", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1j39uxls4clq76ej7mk2tdskvql2tdp2zek8g89", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1qcy673rd8a27t48ry6evmv6as7fuetd8cyhnjn", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom12d3klseftxsfs5xmvjju339enk8xcvg5y55qvl", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom148g7gmqvw5gfj7dmpjymtsw3j7gvasflqrsyx5", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1eur22ds9gn06lgg9j3raqlzj8j2qzxx6vuje4x", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1809klqrjjrs8ch2gtf5hmmfhysspkrr894rmhm", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1f9nx8jrlx9pvns70edanu37mxtm359k606qyds", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1qgkdm2asr0qey7jafqyqlnarvgndjws23fpkrh", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1r5gvlzt03a0a9rks3s57cppmfqx2lzjrquh3d0", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1yaastlp99jvqta2x5fngdzw6zur7khctd9gk3x", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom14jhjmhm2xmx6wyefju30auqvrs35hmnn2m8ewl", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom10pqp6py9pqtagyde9tnkkvakg3gqsnq7lgzxnp", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1spndx95pckqnmjss6emff6fyylasg66qzdfv6v", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom17qkfq2uwags5pzplrfqg2elhn9s0pfwja4mgeu", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom194097avwy9a6h0cvznev232z28h96rp2q3w3uc", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1l8hx9jxul439uyjve4zn45nujtx9gmrw3za3vs", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom12zmexhujvw7j82la9uslzfl5g29erpysqt555s", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom12vexhfe4m9p9szsqvzsalssf8sxluj6pqx8gr3", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1ukgaegxryydqckt6fgrt60dajxq758x9pntmhh", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1756xr3jtsdve6vuwqgqdtmt6ws3td49gq7vc77", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1fn5cutfgat9s9z6nz5ucnnq9aec82wvqpevsn5", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1e63p9zdn5xks5ge9gj2y9gfkl5u0jgkvfrnhzl", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1zq9f4eczclr5cexrxdusfxxr6eumn2rlg2h4hs", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1sjtl9n7fqszta6p4w5y5yl7d4xqth26d8z2gjj", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1a4krl6m7jg7ckczk94hh0wdlcezvpgwcwkrpcg", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom17lzmvgnahdncwnsx3dr7mss65qv6l9md2hy2qq", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1pljwxmmkhfrkzkdpmdjv29t6959sa77mjt0xz4", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1t9xfg2kurjlvnw86repcpte3shpgasdjge6a7t", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1erxn6kmz3xhfrv40m7lyp88v43qahqn8fy2xhn", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1k879z65mwwwu4jause7galz0hlsqqj4rtah7r6", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom16dsvdl4jer9jyplelgz4x68hjvg5k647nrnc8z", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom12pafl09rqzcw7d77qs63pg2nlsgvc3dsfxyzum", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom15cq4l7d6v43rtv493cps3c7tpsf26d83pseqwn", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1wrtzl04mxs2en94ysc5p8mvqc5p0culr9w9m0n", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1a2zr8qx60sl3srh982hjduse0l7pdcnhtl7juy", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1r82whjffalh2hgmrayywc9g53es96n9e9893yv", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom15884n6qmrwq8gjuwtqh6q8z7vx500n5s3djcv6", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1nhkl9r84zjucmjswhddwq8zgpun5yks5mjk7xc", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom12cq4xxcr6pmjz320aj7j8pn9l8vjeed63slcz5", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1fwx3u5w8qyzp8msv2n9umajgst86dnuqrsft0g", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1zg3xqymyrvlu5fmmyx8htdm84kqt50t7xdfmuj", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom152xtf7tvw60tyhls32wwc9ypehqzf366zjkeeg", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1uspnj6pvq0u78d8qux8lz6p24dzm998phldqgv", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1ppzvqc7yf9lfs8cljqu6w992gct6d5h9jx5wsn", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1jn8cp663fl0mv6k55xvy2lr6s0r57zg0v6gzr3", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1fmpuldfmgj0a4dlkn0cdlap4h3qs7nljyph4rj", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom10mja0qpcq6ze2nrchhh7w3n7g589sdktfu7p9m", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1kaaxhzud2ev7v69kwkf8vuvhst9a36wz5l424q", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] } ], "supply": [ { "amount": "1000000000000000", "denom": "boot" }, { "amount": "1000000000000000", "denom": "tocyb" } ], "denom_metadata": [ { "description": "The staking token of Bostrom", "base": "boot", "display": "boot", "name": "Bostrom Boot", "symbol": "BOOT", "denom_units": [ { "denom": "boot", "exponent": 0, "aliases": [ "BOOT" ] } ] }, { "description": "The liquid staking token of Bostrom", "base": "hydrogen", "display": "hydrogen", "name": "Bostrom Hydrogen", "symbol": "HYDROGEN", "denom_units": [ { "denom": "hydrogen", "exponent": 0, "aliases": [ "HYDROGEN" ] } ] }, { "description": "The power token of Bostrom", "base": "milliampere", "display": "ampere", "name": "Bostrom Ampere", "symbol": "AMPERE", "denom_units": [ { "denom": "milliampere", "exponent": 0, "aliases": [] }, { "denom": "ampere", "exponent": 3, "aliases": [ "AMPERE" ] } ] }, { "description": "The bandwidth token of Bostrom", "base": "millivolt", "display": "volt", "name": "Bostrom Volt", "symbol": "VOLT", "denom_units": [ { "denom": "millivolt", "exponent": 0, "aliases": [] }, { "denom": "volt", "exponent": 3, "aliases": [ "VOLT" ] } ] } ] }, "capability": { "index": "1", "owners": [] }, "crisis": { "constant_fee": { "denom": "boot", "amount": "10000000" } }, "cyberbank": null, "distribution": { "params": { "community_tax": "0.000000000000000000", "base_proposer_reward": "0.010000000000000000", "bonus_proposer_reward": "0.030000000000000000", "withdraw_addr_enabled": true }, "fee_pool": { "community_pool": [ { "amount": "50726497621325", "denom": "boot" }, { "amount": "50726497621325", "denom": "tocyb" } ] }, "delegator_withdraw_infos": [], "previous_proposer": "", "outstanding_rewards": [], "validator_accumulated_commissions": [], "validator_historical_rewards": [], "validator_current_rewards": [], "delegator_starting_infos": [], "validator_slash_events": [] }, "dmn": { "params": { "max_slots": 4, "max_gas": 2500000, "fee_ttl": 50 } }, "evidence": { "evidence": [] }, "feegrant": { "allowances": [] }, "genutil": { "gen_txs": [ { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "bloqhub", "identity": "", "website": "https://bloqhub.io", "security_contact": "", "details": "" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.100000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "600000000", "delegator_address": "bostrom1gh09lmm8flkuu3w38mr4axvunnu6qqlapuwzrv", "validator_address": "bostromvaloper1gh09lmm8flkuu3w38mr4axvunnu6qqlaexfan0", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "aIG2z/l2N3K6WslUGA8u5kZnqcvqyKEXQpoiiICLKa4=" }, "value": { "denom": "boot", "amount": "700000000" } } ], "memo": "dd22cffccafaece970cfa9e7eb3c8468f6fa1c84@46.166.165.14:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "AjOqctJGZMZLaRwwrzZyuaTuXp1UL3End4PQVB7vC2J+" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "rNmSw3X53arQwmmH/n1QdrsedZ6DQFKmZL2cN2wmKZ8C9WeXRdYRo2pWtMukcHUSk4dzZGOkhaewxN2I794tqw==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "0base.vc", "identity": "67A577430DBBCEE0", "website": "https://0base.vc", "security_contact": "0@0base.vc", "details": "0base.vc is a validator who doesn't trust any blockchain; we validate it ourselves." }, "commission": { "rate": "0.000000000000000000", "max_rate": "0.250000000000000000", "max_change_rate": "0.100000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "bostrom152m9xcx0ht7yxr5834ju7qjcyvetw8amd04apw", "validator_address": "bostromvaloper152m9xcx0ht7yxr5834ju7qjcyvetw8am44jz3d", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "9EtOO5q/eUiQ1VtdFegl46fyhJ2tkzm2TDLkdm+zRm0=" }, "value": { "denom": "boot", "amount": "71000000000" } } ], "memo": "d669803c3234f0a5f9db9883bd0a51fba90f9421@192.168.2.238:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "Alq7kX/SxB3TsTDBtPfiQYcDZmnt/JA1ND7bYbR601xM" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "PrHcAs1tDMNC081gnzm+4Pka/X3Xut6JJKuOIq9olYZU41MpEjt/K6ZDmOZrQzw+ySPHb/9+mlzZqPxo3nFR8Q==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "cyberG", "identity": "", "website": "", "security_contact": "", "details": "" }, "commission": { "rate": "0.100000000000000000", "max_rate": "1.000000000000000000", "max_change_rate": "0.880000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "bostrom1en69twaxmv7xupy8lq7y539dpecx7yz8g0k8ft", "validator_address": "bostromvaloper1en69twaxmv7xupy8lq7y539dpecx7yz8s43ceg", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "uMw2XjXqICe1CvEbYCwN3GEXm5r1CBhc0TacHucheyw=" }, "value": { "denom": "boot", "amount": "10000000000" } } ], "memo": "39a20a7d84c6e91c6638f5a685a13f655e050ee0@192.168.1.2:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "A+/XPH/eRzCGPv+gabj4eialveLzwRrPvTUy6I/v5eMp" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "RQ+jbCPTw6d7dHpPs+ysuFBmj+BTFx2GJ/ZEK4Cyk34T+uM+PciG/DcycTd9VHCnYT4n35s3RmgHGUKX5YVhkA==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "Citadel.one", "identity": "EBB03EB4BB4CFCA7", "website": "https://citadel.one", "security_contact": "", "details": "Citadel.one is a multi-asset non-custodial staking platform that lets anyone become a part of decentralized infrastructure and earn passive income. Stake with our nodes or any other validator across multiple networks in a few clicks" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.200000000000000000", "max_change_rate": "0.030000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "bostrom1argjwgcplguenq4l92ggn06wadnfrz0ecqrmqs", "validator_address": "bostromvaloper1argjwgcplguenq4l92ggn06wadnfrz0eq6yysn", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "96vbjWw9jbyO8Krl9Rjbt8SU9tVuBiPhtVAxx28arcU=" }, "value": { "denom": "boot", "amount": "40000000000" } } ], "memo": "5b59d7daadd971a9613b2efcc3c6eab0777f5f29@10.129.0.24:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "A/w52L7lXEuf+bzBuq08IEbrypuMpW5Gff9zGU4uYyMD" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "dgUZukDKCaztxabLHQru1+clM8wS+zTHOA4lp7YYt7pHTBCO3YBY5EMKJTEei+Nz8wJX0h8WkFBZYA+YtfGp4g==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "web34ever", "identity": "", "website": "", "security_contact": "", "details": "" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.200000000000000000", "max_change_rate": "0.100000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "bostrom15zs0cjct43xs4z4sesxcrynar5mxm82f0ykhl3", "validator_address": "bostromvaloper15zs0cjct43xs4z4sesxcrynar5mxm82fh73g0j", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "Kry59s/u3vENIsWu+4ssFqsnECWTxA8iOFSXPbIQmsU=" }, "value": { "denom": "boot", "amount": "10000000000" } } ], "memo": "5e8522bef5ceca507e05aa0d5f67f37a70222c73@192.168.0.107:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "AoeGMAMQligEwocz8uo93DOcNQFIRDPD6MFJgCnd6mgc" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "bRNyFymF6LFfac+9DwnXRYCKCvZpIcc+O18gMVt2OB44tRCH3bS1m4dlnHHy2H8TMMJ021SSNkaaGBv7SuBTuA==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "Developer", "identity": "", "website": "", "security_contact": "", "details": "" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.300000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "bostrom19ys53t55r725j882gjcrnf7s449gdrds3h2hu4", "validator_address": "bostromvaloper19ys53t55r725j882gjcrnf7s449gdrdsfddgvk", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "KdT8GK9d81xvkDzuNjM3nwi3mijxRfq2YWnM++SAIw4=" }, "value": { "denom": "boot", "amount": "38252993813" } } ], "memo": "77d27615009fc703ece46901792cc8750cccd0de@185.230.90.71:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "Aic66jxbwijTVJe5LugB2hOLnVUkEXAgQFAHF0B0a2HS" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "CAmQZPBhI6415XsNQC4FLN63kg9rwgoWkBeuhz4CQ8F3HS9LL2nDJJb5/OGNeLifrHsc02Fu+WQhuEhD6Bq2wA==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "Kerman", "identity": "", "website": "", "security_contact": "", "details": "" }, "commission": { "rate": "0.030000000000000000", "max_rate": "0.500000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "bostrom1ke6pp2kq2wx74tlh5fxqgp7af6jtsna3kktuh6", "validator_address": "bostromvaloper1ke6pp2kq2wx74tlh5fxqgp7af6jtsna3wvvr8e", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "0nAyxxNGDv3s2miDdJWibOEoWVre8jadmJiA7BSEugk=" }, "value": { "denom": "boot", "amount": "10000000000" } } ], "memo": "822b374bf2ca56c49fd565d149cd7cb6d175d8cb@192.168.0.67:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "A2SWKzAFJLvVQEi/X1HDzFjJ5/1eC42xmaLzg/gs3xkk" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "vGtxVMDxclLZ+BgXsg9dggfOF439ccvs9gWxWQ5osCdKgj0QZSslJqgPs9RwGwxeeZHIHDLFztG0TzEcKQpUmw==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "papsan", "identity": "", "website": "", "security_contact": "", "details": "" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.300000000000000000", "max_change_rate": "0.100000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "bostrom18naxcfp2s397a2ucav2m53f003uylk3qz9fvr7", "validator_address": "bostromvaloper18naxcfp2s397a2ucav2m53f003uylk3q6lwnna", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "YV4dJbW6TrErmwcs0VxFiAJUio+6Yh5shQ+hwlMveN8=" }, "value": { "denom": "boot", "amount": "10000000000" } } ], "memo": "902fb751851e474133ee4ba1e646f49237b50edf@192.168.0.161:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "A5+dz3ZHelKjHTo31eZ2na4pKdlll/blg09/wBgoqzCx" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "6qgMlfzKEN+EM4lQi//6D6QI92wQPdOXGBy1l1MRigQ+uqdS5QfWIH2DJDpg/0gLSV1yJHj1ENhJAlh6wHN7YA==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "Godzilla", "identity": "", "website": "", "security_contact": "", "details": "" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.050000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "bostrom1dxpm2ne0jflzr2hy9j5has6u2dvfv68calunqy", "validator_address": "bostromvaloper1dxpm2ne0jflzr2hy9j5has6u2dvfv68c99mvs8", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "BncD9wiS2MKpBJw1t9PLoIeqQ9pTccPoGBx9cRNoZak=" }, "value": { "denom": "boot", "amount": "10000000000" } } ], "memo": "0c4296d5d591bdf7fc8a16ab316a0fefed245ed0@192.168.0.104:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "AhP0Psq9i0nwuprL3XwQpDE4AuCi+hSgDg/YtQV0ks93" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "mq2msMfWEra01A3cNxUFG8+4yd0ttgRM5xRjA0JMBS9l3AfNXoCYMTdFA7iPrKBblkNR8Yg8Ztrulc3UCGDrLw==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "Bro_n_Bro", "identity": "A57DAB9B09C7215D", "website": "monitor.bronbro.io", "security_contact": "", "details": "We building for decentralization. Until it comes follow our progress on Github github.com/bro-n-bro, join twitter.com/Bro_n_Bro and rank us at cyb.ai/search/Bro_n_Bro" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.150000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "500000000", "delegator_address": "bostrom1ydc5fy9fjdygvgw36u49yj39fr67pd9mv67ety", "validator_address": "bostromvaloper1ydc5fy9fjdygvgw36u49yj39fr67pd9m5qexm8", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "SEiFL2BSD9TOUsPIaBKx5xZU+ijry95DdZ44u9mwd3Y=" }, "value": { "denom": "boot", "amount": "850000000" } } ], "memo": "74b6fc649a41cb1d21201a440b16a1e478706a78@192.168.100.8:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "AjOKnmLV/8qlph6bINrTw3USPl8YVfwqMwY1xlT2+2nV" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "sctX7B6LKkBJ6XdwuLyohNipyg2PSMT9npqNc4rHYaBzlaTZCTv1loPmJW8rurKA4kiGCuU58kxR4X7m7gffhA==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "Hailbiafra", "identity": "", "website": "", "security_contact": "", "details": "" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.100000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "bostrom1smsn8u0h5tlvt3jazf78nnrv54aspged9h2nl9", "validator_address": "bostromvaloper1smsn8u0h5tlvt3jazf78nnrv54aspgedaddv0x", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "triXPhJGBlAduyzF6oF0PKHM9H2sXz9+TWY5gb9lkNI=" }, "value": { "denom": "boot", "amount": "1500000000" } } ], "memo": "082ec921427c35a5aeaa8576c5ba2a0513994c4d@192.168.0.21:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "A8ht9IthhnJlqSqkOyPUOuA5I0bhEu//8V17Wvi5nDX0" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "jGWq0dtKzBLIVuY/s/Fk2eZjPy8CsOF9PhZj8iaHSM5Fpy0518Bqt0KYJ47/d2KAL8Zw3Zcw0n82UojxzZLhJw==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "MindPool", "identity": "", "website": "", "security_contact": "", "details": "" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.100000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "bostrom1gd9r9uhd8a5k2naudq4hua3vf3lkwhfrm63qhq", "validator_address": "bostromvaloper1gd9r9uhd8a5k2naudq4hua3vf3lkwhfrrqkl8r", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "RPBRQHcurf6ZOoar9DWoncHbcEGmaceT0zdalDYsobo=" }, "value": { "denom": "boot", "amount": "1100000000" } } ], "memo": "615e772ebe444a7bff0078b12ba0c445f56c9fea@31.14.40.221:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "AlR8VrZk5703owY5iA0M9Dhdf1pMBCk4bXg5KawbDG8g" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "FoLuebxVDbQJwDQ1Gv+klkFBIhCo/L87btLU/IMYofYA8KQ3iRnqxGuS15chFOv2z+SNVWc9uKQjDrpUKfLdLw==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "Nett", "identity": "", "website": "", "security_contact": "", "details": "" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.100000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "bostrom1njsr8tngxtygsc73mrtn5738ztkzqy7c7y7h3t", "validator_address": "bostromvaloper1njsr8tngxtygsc73mrtn5738ztkzqy7cx7egpg", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "ChguMkmpTQCnekerrNnAnyFePLY3C1jacudM3SYOrdg=" }, "value": { "denom": "boot", "amount": "10000000000" } } ], "memo": "6bc53131a0acdd7ffaaaad3f0bd2e13a0cf4544c@31.14.40.252:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "Ak/h9AX2Pl5aIvaC9wcEnj7QDU/pr0YU6WQfbbStR34V" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "fsdilaUl8FMkjptEUgPslypkGHlWUgYSdCTHrfeTkR4npA/1Aunx56J46bgVifKza/9KeHaFMn5sVSUO1rxLwA==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "NodeMarsel", "identity": "", "website": "", "security_contact": "", "details": "" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.100000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "bostrom1vrym7t34gs9t2dkd8z849zcymkj54kgq7pdf8z", "validator_address": "bostromvaloper1vrym7t34gs9t2dkd8z849zcymkj54kgqxm2khp", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "fIbK0sEsisgCoXnWmrfApLX7SdvuhltzU1llq+jiV8k=" }, "value": { "denom": "boot", "amount": "1200000000" } } ], "memo": "4a194e60d748fe7407aef58a22957d1d4d1327fd@213.108.130.224:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "AjDkMSMwESOWvRQGEtP/j09Iyul2827V83zhitE60tSm" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "ZD4QxpojQ5tlkW1ydaiwGAPL15olannbLDXjj0DBV3VJKVz/+TLAR4zW0MG5AQORrd5IksT6zHeTRHnfrjxNYg==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "Node_masters", "identity": "", "website": "", "security_contact": "", "details": "" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.100000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "bostrom1zy553za8nenzukmv65240323jhuvxzym4pl6w9", "validator_address": "bostromvaloper1zy553za8nenzukmv65240323jhuvxzymdmc97x", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "hkaRWuE3BNBVmeqv70qJ++iyYs7THerZyOhNa7E2gVM=" }, "value": { "denom": "boot", "amount": "150000000000" } } ], "memo": "4baf7d265d7524543bebc2322089bca4a3980b54@176.9.0.254:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "A6ugL0vd+03w9K+27qpls79V265kl7xpIxkeFWxjAxos" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "eXqb2zaAjXsqUeeFlxLLhgd4ToUlbpz/ysg+tqFSossEmXknpoJB8hpwVOZeUC82zyNgV1VPNmwk+jxvqiLvdg==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "P2P.ORG - P2P Validator", "identity": "", "website": "", "security_contact": "", "details": "" }, "commission": { "rate": "0.100000000000000000", "max_rate": "1.000000000000000000", "max_change_rate": "0.100000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "bostrom1daxxqs56f6j5qxxtjrjkexghsmnaj66tejshc8", "validator_address": "bostromvaloper1daxxqs56f6j5qxxtjrjkexghsmnaj66tpghggy", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "4KsAoQUaZNVyA0Tc02Gw3GYxkuMdgtf+aXTOqKDNbgE=" }, "value": { "denom": "boot", "amount": "10000000000" } } ], "memo": "c08e42e2c61b42647f5d0f9179ecf71cc5b91983@85.10.204.155:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "AlJhCdxE6tlLq6sH2feIUpV5tjpqFTfdN/d727m7QFJo" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "ZoFtA2JHo7ENKp4zw360+sObHPimRgECdSAM7zF586YSXeUXRGiZ9j6MnsnbgHfqFg32jeRSG07ayY1RYYNY3w==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "PLap", "identity": "", "website": "", "security_contact": "", "details": "" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.100000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "bostrom1wm4026rxqcrkh09k806m6y4lys942etx5cjz9z", "validator_address": "bostromvaloper1wm4026rxqcrkh09k806m6y4lys942etxvz4a4p", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "2VHfckjdelAwGj8b3gw+kq7U0ni9aB9S3rNQx054iVU=" }, "value": { "denom": "boot", "amount": "2008629825" } } ], "memo": "d8783bd0a78777503143d90f55c6ce68bd5b53d3@178.170.46.52:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "AoWKUnsu5koT3S90SK96fnKcuzd5myJs6HsYbHskkoFc" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "HAeMOhN4PVUKZSmYzf23Rf4eNUlInL03YTbYaf+sAT8kPtSyA4UGffu6DZekLDWPDNf1fXypWnxXpxkaUvOJfQ==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "POSTHUMAN", "identity": "8A9FC930E1A980D6", "website": "https://posthuman.digital", "security_contact": "", "details": "full-time enthusiast" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.131200000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "bostrom1ccvpcq9ffy0qd2ca8nmmpzfamtyjfc9znwak8m", "validator_address": "bostromvaloper1ccvpcq9ffy0qd2ca8nmmpzfamtyjfc9zt56fhc", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "lWEU7pJSRroGTFMa5O6JKRC1JnGsupKTC88i3uAtxu0=" }, "value": { "denom": "boot", "amount": "10000000000" } } ], "memo": "55937c36959ea3984cc6e6ebd3354d73bbbdbcda@192.168.1.65:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "A5khg0rKhMayAuU6AK2To44nGX7wjOz3kKgvjHQkgOpm" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "pZi8OR9mNdIliit7mNKp3Wvtt9RGSE0hvqkq8wgdOQ4oc2qZZdSFD7eu6YBBdMNhMxlQKt9GcXEZuIpXQ2C+Jg==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "StakeAngle", "identity": "0C2EBFF70582B725", "website": "https://stakeangle.com/", "security_contact": "", "details": "Non-custodial staking provider" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.100000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000", "delegator_address": "bostrom1g2d9xyuf7ddgaj4llxvg50pfhlsr9ehf2r8dr6", "validator_address": "bostromvaloper1g2d9xyuf7ddgaj4llxvg50pfhlsr9ehfjeqjne", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "qOE+qVo9giTu6cypXg6zN3ZT9MitNBHfTYfLL2ADVGo=" }, "value": { "denom": "boot", "amount": "5000000000" } } ], "memo": "0fc5cfc9c383223ab2b4b0811bc43c7123653ade@192.168.1.38:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "AzuPqiLKy2Y7g87DO43xNI19pSbQPsSKFh1XPR2AKFiA" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "nXsiARFuivsTpMNogfTiNJZDZIOik+koTMY9qyt0jJgPXxf90mDXCjgSuB9UQywawAe7cuko+bXuwg1egZ6tpA==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "DragonBall", "identity": "", "website": "", "security_contact": "", "details": "" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.200000000000000000", "max_change_rate": "0.100000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "bostrom1dt9lwmuq8rkngm5gajxchqhpcnavgp7md9v929", "validator_address": "bostromvaloper1dt9lwmuq8rkngm5gajxchqhpcnavgp7m4lt66x", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "SmngMSNxQ7TnildgcI5OzZYJxWbwAH2C0UJj3M+J+Fw=" }, "value": { "denom": "boot", "amount": "10000000000" } } ], "memo": "a99b8bcb07d027895bcc2abe6baa866174b5ec23@192.168.7.14:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "AtjlOQ83TD6uUs4FUqmVOPgjGp+JgYxk8P6SjUrCbxEn" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "6O7hkhSmqLOUp+/c95I9M1drzkdulcRoJETFpZaSPvEu/wQmTyW0V6Yg3LIJ6KR2U6sbs/e0kfBRHrYfY4OGkA==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "alinode", "identity": "", "website": "", "security_contact": "", "details": "" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.100000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "bostrom1jdmfxzpnqqlhjsju3mz7qsgvvdparw5acx7t62", "validator_address": "bostromvaloper1jdmfxzpnqqlhjsju3mz7qsgvvdparw5aque52f", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "JKHQ2Gg/+wWDMcvLwHoEHFccRVZYuGCBSTD/fnIi2vg=" }, "value": { "denom": "boot", "amount": "1500000000" } } ], "memo": "963ce143862bdad29c2707302ad4afa21bc1a48e@213.246.39.35:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "A8zFftObCKT2prwqRKuY052meDr9PMCXpbpJdmO3EBty" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "arNRkETkLTBPGYIWi5tYkqeFolCmfn7160BPg5NvL7pW/0g/1T/d52zEUnD7J1CxvHjU7gCF7sIcKkxasLxF4A==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "blue", "identity": "4815E34CD44A9BCC", "website": "cyb.ai", "security_contact": "", "details": "May cyber be with you!" }, "commission": { "rate": "0.077000000000000000", "max_rate": "1.000000000000000000", "max_change_rate": "0.100000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "bostrom1ymprf45c44rp9k0g2r84w2tjhsq7kalv98rgpt", "validator_address": "bostromvaloper1ymprf45c44rp9k0g2r84w2tjhsq7kalvaayh3g", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "110HUJd7XFqWhXbE/nF1D4pFcM/vQ8D9yOJbyQF6gsc=" }, "value": { "denom": "boot", "amount": "150000000000" } } ], "memo": "d647c9f7f8a50de3fa75504dec5c6943e2f97297@192.168.1.22:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "AhhWC3Vm5nl0W46/gk07bObIRYKLpShYyPjKwyfZpbjE" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "7triW+S9rwnFEZVh57sgHHfvoYH7SHXYwu2rrCTxRbMPWhDhcv35L45NSq4izsWTRUDZXc4ECyXiPtzXPCcQiw==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "Citizen Cosmos", "identity": "DF0280597A20ACFE", "website": "", "security_contact": "", "details": "" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.100000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "bostrom1f7nx65pmayfenpfwzwaamwas4ygmvalq2q2ayq", "validator_address": "bostromvaloper1f7nx65pmayfenpfwzwaamwas4ygmvalqj6dz5r", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "hzZZ1s5Q2R0Qhbax0Hf7xS9m+kMxbc6FVUihIIoa35c=" }, "value": { "denom": "boot", "amount": "73000000000" } } ], "memo": "f1f24eb30de7a1874eb9f11b07bfc87304bd1e51@192.168.1.8:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "A4YPXp3wQTKE8f6dWNPWhxbgMre2cPmN3XNkK+qa0bcM" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "rl6sgn+j7weVYnzBnkhnOg0ubuxUfhEgCqEncgY59p9JWsAqNCxB88bQf2cKDLTrwS7fb/0nNfxGNKp17D9Drw==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "csaxial", "identity": "", "website": "", "security_contact": "", "details": "" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.100000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "bostrom1ezpth4mp3eeqdt49kgqd5ctr69xev6v2gykpur", "validator_address": "bostromvaloper1ezpth4mp3eeqdt49kgqd5ctr69xev6v2s737vq", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "lB5R6K7wY2G4a3Aus+NWAwYiFga5Cc2WxvwZG3Ga3yk=" }, "value": { "denom": "boot", "amount": "1321419074" } } ], "memo": "142ac0545728f8c6ebdbb0c0c7bceb9037ac8500@213.246.45.11:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "AyZAyFNW/2s83BGnyEWcYQXRRrygMQCo9o/XDAZCP8oZ" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "TScK3vVqEZ7+i0xUFPvD0LMN1rTyfGgQuhdAcuzyFMVdMUme1i7MvIPCMZW6g1Arj70kNjl6qxO/Q1gHhM+mRg==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "Space", "identity": "", "website": "", "security_contact": "", "details": "" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.200000000000000000", "max_change_rate": "0.050000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "bostrom1lnkg57t7mvg5mcl7kdkevtgr9wlf6f9qtp86sk", "validator_address": "bostromvaloper1lnkg57t7mvg5mcl7kdkevtgr9wlf6f9qnmq9q4", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "0O20CW17q7chWZGHayK+SlEzCXfJaqTlshkE1xujQCg=" }, "value": { "denom": "boot", "amount": "70000000000" } } ], "memo": "dd4dd317f85209964232cbbe772c242c50bbbe58@88.218.191.79:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "AwvyyDlWja87ZwpT/pvNYBXXUGxNnLKA9MvWXij5gIts" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "vagsGgO+zNfHY6f75cwxxY2eF2Z/118v2Yo6okBeaAtnz9uJsy15r9gpi3xheAhd6fas4Cdm6StytC9k5zL3Fw==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "dobry", "identity": "", "website": "", "security_contact": "", "details": "" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.100000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "bostrom1fpl40sref5vp8kfm7xkqlq5qc0v4xrjvk89kwa", "validator_address": "bostromvaloper1fpl40sref5vp8kfm7xkqlq5qc0v4xrjvwazf77", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "ZxYmxQPGdPYaBJA8IY4Jg3h/Cs0wVRmPIippypxPrsU=" }, "value": { "denom": "boot", "amount": "2000000000" } } ], "memo": "6922a88c66cbfeea0831cc38c2f3485a78b29b46@192.168.88.9:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "A61usxgHwcBypbZ2FaByVOGvL0sScEfE7qNDDvrxIkrx" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "MPUXshgRvcj2kIQRrZ4TvzzGL0+9XLwPKPuauNIZhTo0m8fAdtEGS6BKe1RuUHsmObju6dgWVEn5He8Nyi67ww==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "DemonKing", "identity": "", "website": "", "security_contact": "", "details": "" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.220000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "bostrom1nvr4qa7szsd3e7xfysn946gcqv5wyemlcxmxpw", "validator_address": "bostromvaloper1nvr4qa7szsd3e7xfysn946gcqv5wyemlquue3d", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "XXul+cFAn6BK4S/aZlMABb9h+jsqFi7/GgZ01JTfhnE=" }, "value": { "denom": "boot", "amount": "10000000000" } } ], "memo": "f1b4b596730ed81d33dbcf051870f0b7b50d6306@185.230.88.227:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "Ahz880YLBAqIp/nXoLLBkhirFgfKcBWd9AH5apprRUg5" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "CJ40V9iORA1e4XJI8DmTKf8i0JqUTNSweDaUpqPboRkek8eP9kzFY9B5wMwQyarUUTCiahBNGmYuw0aO9g5DNA==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "goto5k", "identity": "1B0142FC46D30561", "website": "https://validator.goto5k.com", "security_contact": "", "details": "validator goto5k" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.100000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "20000", "delegator_address": "bostrom10trdf5eyfcmc9graltx4hmpgznhrm7hdz82k2n", "validator_address": "bostromvaloper10trdf5eyfcmc9graltx4hmpgznhrm7hd6adf6s", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "TVfJZnq2vaHv1XI49n7nPn1wVQxurVL3JDVVUUo/Ijo=" }, "value": { "denom": "boot", "amount": "1941697143" } } ], "memo": "9715ea8afc6ba882fbb91cc389e4ca6174433e40@192.168.100.4:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "A2y3DqIjyeTqoFiojpJh5eJmLxcROK/zw3fOVj87KvVf" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "h2WNVfwTvJt9q2qoIAPoI0RCCTxrKo5NBNA7jsSYS9JN80d7zIBhDsOZ8PKnS3WwtyAFkdV3nvULJ7+BzHdpiQ==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "kiwi", "identity": "", "website": "", "security_contact": "", "details": "" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.100000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "100000", "delegator_address": "bostrom1w4tk9lj8qtx2x4xf4emgrnq950hnlajsxlnl3u", "validator_address": "bostromvaloper1w4tk9lj8qtx2x4xf4emgrnq950hnlajs795qpl", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "823dliApVbj5vUsXFYViaOB6hI8/P7ul0zmZpHmW+80=" }, "value": { "denom": "boot", "amount": "3000000000" } } ], "memo": "1874c04a8cfffa6b47e37fe2255158abb7c69e8b@213.246.42.130:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "A2qM2nYkdvgGaKEoEIvohiHgbux/4tdRFhQveYbUmHnp" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "XZeX3P3qL2YI2FAtJSkPZNdzpN4aKZK1OFic6UEzkSthNHl4gVyydwgjsIlS55A0pfMfatiimIOPNJlVdclS5g==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "qwertys318", "identity": "", "website": "", "security_contact": "", "details": "" }, "commission": { "rate": "0.100000000000000000", "max_rate": "0.200000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "bostrom1402rpwdquxxkgvl740f6w69l65eau5vkqcvrax", "validator_address": "bostromvaloper1402rpwdquxxkgvl740f6w69l65eau5vkcztud9", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "r3NIqDgCKwxfTIdvsUYruUSv+ExKI/dyL9UxRt3uuHQ=" }, "value": { "denom": "boot", "amount": "10000000000" } } ], "memo": "afa472f8880ce4ef3f7e83a446b6846456c7627a@62.182.82.18:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "AgHfo2wAJPHXlA0p+hez3PySR0siNykr4236MLZVwDwH" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "R9ueed1u83kC6eJSKQg79TYQhxN6bmOFgNQp0pa51kQVIaq8CloXymUbgYO0iN9L7CTUfeiSCJvR0ReKncmTiA==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "spectrum", "identity": "715E454ACF0C537C", "website": "https://spectrumstaking.net", "security_contact": "", "details": "" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.100000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "bostrom15n3t80p7eseld809f7fu3s9tlcezlymkfeu59n", "validator_address": "bostromvaloper15n3t80p7eseld809f7fu3s9tlcezlymk3rmt4s", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "ZxG1y2GSwb/HuBi8BFZLoYYUMyuvboplTa1DDuMGnG0=" }, "value": { "denom": "boot", "amount": "3000000000" } } ], "memo": "8285e7ddaa2bc545de9c6720f746c0d3cd48e782@192.168.1.105:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "A+E8waurHOB4l8ab8C8TG3YhYKDC6S3T8SED22kpAHFy" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "1BG5B1EpwYyqJnrSk5xME9EoQnbk4KboqWGzk59L0AkKcrtOCsNoFf0npEBxVQp+Ag6tI+DNVwrtK4UtKF40/g==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "sta", "identity": "60507CCEB00F6CBD", "website": "https://cyb.ai/network/bostrom/hero/bostromvaloper1hmkqhy8ygl6tnl5g8tc503rwrmmrkjcqf92r73", "security_contact": "60507CCEB00F6CBD", "details": "a Great Web believer" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.200000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "bostrom1hmkqhy8ygl6tnl5g8tc503rwrmmrkjcq3lduwj", "validator_address": "bostromvaloper1hmkqhy8ygl6tnl5g8tc503rwrmmrkjcqf92r73", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "FVs7R89ToDtCaYNZHrRF8MWCQ4d3uxytQSMg4OMleW8=" }, "value": { "denom": "boot", "amount": "150000000000" } } ], "memo": "416aa82d0ab4c0fc379426fcedadc947d84afc50@192.168.1.18:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "A2VNyRXHdKHqT3mosH+sPHFhvCglaCEnK6wLgG8yN8WO" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "tqyQRTpdfMkwClnRQghUOaeD+x8sobxcYVRFT0rr1YR37A1ONih5w1h1ZKPD7mIjF+ydSwM1JYGs/of/nUbdlg==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "Adorid", "identity": "", "website": "", "security_contact": "", "details": "" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.100000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "bostrom1mnfalar08dsvtwutmh43lnhx2zzmq7xhdulemj", "validator_address": "bostromvaloper1mnfalar08dsvtwutmh43lnhx2zzmq7xh4xcxt3", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "AK7c305pBQkAz05OE8rw5JkwSx+nhcvna6Tz9RXhE+Q=" }, "value": { "denom": "boot", "amount": "10000000000" } } ], "memo": "bd272d32665caea2d80127bb930a92e8bb563202@192.168.88.56:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "A7vpgS7DhWrPcDfGh9fzTUXxutVYlAgEK3idq0kTSK7k" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "DSoWS3oAswZIEiruKCAF0cP4LGcp+l1dAA0EMYu4xE9zHN6xI3hLgAieIHtfxfS9vk6H+/sLYtmM5C6+mdhpdQ==" ] } ] }, "gov": { "starting_proposal_id": "1", "deposits": [], "votes": [], "proposals": [], "deposit_params": { "min_deposit": [ { "denom": "boot", "amount": "1000000000" } ], "max_deposit_period": "604800s" }, "voting_params": { "voting_period": "604800s" }, "tally_params": { "quorum": "0.250000000000000000", "threshold": "0.500000000000000000", "veto_threshold": "0.250000000000000000" } }, "graph": null, "grid": { "params": { "max_routes": 16 }, "routes": [] }, "ibc": { "client_genesis": { "clients": [], "clients_consensus": [], "clients_metadata": [], "params": { "allowed_clients": [ "06-solomachine", "07-tendermint" ] }, "create_localhost": false, "next_client_sequence": "0" }, "connection_genesis": { "connections": [], "client_connection_paths": [], "next_connection_sequence": "0", "params": { "max_expected_time_per_block": "30000000000" } }, "channel_genesis": { "channels": [], "acknowledgements": [], "commitments": [], "receipts": [], "send_sequences": [], "recv_sequences": [], "ack_sequences": [], "next_channel_sequence": "0" } }, "liquidity": { "params": { "pool_types": [ { "id": 1, "name": "StandardLiquidityPool", "min_reserve_coin_num": 2, "max_reserve_coin_num": 2, "description": "Standard liquidity pool with pool price function X/Y, ESPM constraint, and two kinds of reserve coins" } ], "min_init_deposit_amount": "1000000", "init_pool_coin_mint_amount": "1000000000000", "max_reserve_coin_amount": "0", "pool_creation_fee": [ { "denom": "boot", "amount": "1000000000" } ], "swap_fee_rate": "0.003000000000000000", "withdraw_fee_rate": "0.003000000000000000", "max_order_amount_ratio": "0.100000000000000000", "unit_batch_height": 1, "circuit_breaker_enabled": false }, "pool_records": [] }, "mint": { "minter": { "inflation": "0.050000000000000000", "annual_provisions": "0.000000000000000000" }, "params": { "mint_denom": "boot", "inflation_rate_change": "0.200000000000000000", "inflation_max": "0.150000000000000000", "inflation_min": "0.030000000000000000", "goal_bonded": "0.800000000000000000", "blocks_per_year": "6311520" } }, "params": null, "rank": { "params": { "calculation_period": "5", "damping_factor": "0.800000000000000000", "tolerance": "0.001000000000000000" } }, "resources": { "params": { "max_slots": 8, "halving_period_volt_blocks": 9000000, "halving_period_ampere_blocks": 9000000, "base_investmint_period_volt": 2592000, "base_investmint_period_ampere": 2592000, "min_investmint_period": 86400, "base_investmint_amount_volt": { "denom": "hydrogen", "amount": "1000000000" }, "base_investmint_amount_ampere": { "denom": "hydrogen", "amount": "100000000" } } }, "slashing": { "params": { "signed_blocks_window": "8000", "min_signed_per_window": "0.750000000000000000", "downtime_jail_duration": "600s", "slash_fraction_double_sign": "0.050000000000000000", "slash_fraction_downtime": "0.000100000000000000" }, "signing_infos": [], "missed_blocks": [] }, "staking": { "params": { "unbonding_time": "345600s", "max_validators": 92, "max_entries": 10, "historical_entries": 10000, "bond_denom": "boot" }, "last_total_power": "0", "last_validator_powers": [], "validators": [], "delegations": [], "unbonding_delegations": [], "redelegations": [], "exported": false }, "transfer": { "port_id": "transfer", "denom_traces": [], "params": { "send_enabled": false, "receive_enabled": false } }, "upgrade": {}, "vesting": {}, "wasm": { "params": { "code_upload_access": { "permission": "Everybody", "address": "" }, "instantiate_default_permission": "Everybody", "max_wasm_code_size": "1228800" }, "codes": [], "contracts": [], "sequences": [], "gen_msgs": [] } } } ================================================ FILE: networks/bostrom/gentxs/bloqhub.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"bloqhub","identity":"","website":"https://bloqhub.io","security_contact":"","details":""},"commission":{"rate":"0.050000000000000000","max_rate":"0.100000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"600000000","delegator_address":"bostrom1gh09lmm8flkuu3w38mr4axvunnu6qqlapuwzrv","validator_address":"bostromvaloper1gh09lmm8flkuu3w38mr4axvunnu6qqlaexfan0","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"aIG2z/l2N3K6WslUGA8u5kZnqcvqyKEXQpoiiICLKa4="},"value":{"denom":"boot","amount":"700000000"}}],"memo":"dd22cffccafaece970cfa9e7eb3c8468f6fa1c84@46.166.165.14:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"AjOqctJGZMZLaRwwrzZyuaTuXp1UL3End4PQVB7vC2J+"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["rNmSw3X53arQwmmH/n1QdrsedZ6DQFKmZL2cN2wmKZ8C9WeXRdYRo2pWtMukcHUSk4dzZGOkhaewxN2I794tqw=="]} ================================================ FILE: networks/bostrom/gentxs/gentx-0base.vc.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"0base.vc","identity":"67A577430DBBCEE0","website":"https://0base.vc","security_contact":"0@0base.vc","details":"0base.vc is a validator who doesn't trust any blockchain; we validate it ourselves."},"commission":{"rate":"0.000000000000000000","max_rate":"0.250000000000000000","max_change_rate":"0.100000000000000000"},"min_self_delegation":"1000000000","delegator_address":"bostrom152m9xcx0ht7yxr5834ju7qjcyvetw8amd04apw","validator_address":"bostromvaloper152m9xcx0ht7yxr5834ju7qjcyvetw8am44jz3d","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"9EtOO5q/eUiQ1VtdFegl46fyhJ2tkzm2TDLkdm+zRm0="},"value":{"denom":"boot","amount":"71000000000"}}],"memo":"d669803c3234f0a5f9db9883bd0a51fba90f9421@192.168.2.238:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"Alq7kX/SxB3TsTDBtPfiQYcDZmnt/JA1ND7bYbR601xM"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["PrHcAs1tDMNC081gnzm+4Pka/X3Xut6JJKuOIq9olYZU41MpEjt/K6ZDmOZrQzw+ySPHb/9+mlzZqPxo3nFR8Q=="]} ================================================ FILE: networks/bostrom/gentxs/gentx-39a20a7d84c6e91c6638f5a685a13f655e050ee0.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"cyberG","identity":"","website":"","security_contact":"","details":""},"commission":{"rate":"0.100000000000000000","max_rate":"1.000000000000000000","max_change_rate":"0.880000000000000000"},"min_self_delegation":"1000000000","delegator_address":"bostrom1en69twaxmv7xupy8lq7y539dpecx7yz8g0k8ft","validator_address":"bostromvaloper1en69twaxmv7xupy8lq7y539dpecx7yz8s43ceg","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"uMw2XjXqICe1CvEbYCwN3GEXm5r1CBhc0TacHucheyw="},"value":{"denom":"boot","amount":"10000000000"}}],"memo":"39a20a7d84c6e91c6638f5a685a13f655e050ee0@192.168.1.2:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"A+/XPH/eRzCGPv+gabj4eialveLzwRrPvTUy6I/v5eMp"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["RQ+jbCPTw6d7dHpPs+ysuFBmj+BTFx2GJ/ZEK4Cyk34T+uM+PciG/DcycTd9VHCnYT4n35s3RmgHGUKX5YVhkA=="]} ================================================ FILE: networks/bostrom/gentxs/gentx-5b59d7daadd971a9613b2efcc3c6eab0777f5f29.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"Citadel.one","identity":"EBB03EB4BB4CFCA7","website":"https://citadel.one","security_contact":"","details":"Citadel.one is a multi-asset non-custodial staking platform that lets anyone become a part of decentralized infrastructure and earn passive income. Stake with our nodes or any other validator across multiple networks in a few clicks"},"commission":{"rate":"0.050000000000000000","max_rate":"0.200000000000000000","max_change_rate":"0.030000000000000000"},"min_self_delegation":"1000000000","delegator_address":"bostrom1argjwgcplguenq4l92ggn06wadnfrz0ecqrmqs","validator_address":"bostromvaloper1argjwgcplguenq4l92ggn06wadnfrz0eq6yysn","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"96vbjWw9jbyO8Krl9Rjbt8SU9tVuBiPhtVAxx28arcU="},"value":{"denom":"boot","amount":"40000000000"}}],"memo":"5b59d7daadd971a9613b2efcc3c6eab0777f5f29@10.129.0.24:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"A/w52L7lXEuf+bzBuq08IEbrypuMpW5Gff9zGU4uYyMD"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["dgUZukDKCaztxabLHQru1+clM8wS+zTHOA4lp7YYt7pHTBCO3YBY5EMKJTEei+Nz8wJX0h8WkFBZYA+YtfGp4g=="]} ================================================ FILE: networks/bostrom/gentxs/gentx-5e8522bef5ceca507e05aa0d5f67f37a70222c73.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"web34ever","identity":"","website":"","security_contact":"","details":""},"commission":{"rate":"0.050000000000000000","max_rate":"0.200000000000000000","max_change_rate":"0.100000000000000000"},"min_self_delegation":"1000000000","delegator_address":"bostrom15zs0cjct43xs4z4sesxcrynar5mxm82f0ykhl3","validator_address":"bostromvaloper15zs0cjct43xs4z4sesxcrynar5mxm82fh73g0j","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"Kry59s/u3vENIsWu+4ssFqsnECWTxA8iOFSXPbIQmsU="},"value":{"denom":"boot","amount":"10000000000"}}],"memo":"5e8522bef5ceca507e05aa0d5f67f37a70222c73@192.168.0.107:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"AoeGMAMQligEwocz8uo93DOcNQFIRDPD6MFJgCnd6mgc"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["bRNyFymF6LFfac+9DwnXRYCKCvZpIcc+O18gMVt2OB44tRCH3bS1m4dlnHHy2H8TMMJ021SSNkaaGBv7SuBTuA=="]} ================================================ FILE: networks/bostrom/gentxs/gentx-77d27615009fc703ece46901792cc8750cccd0de.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"Developer","identity":"","website":"","security_contact":"","details":""},"commission":{"rate":"0.050000000000000000","max_rate":"0.300000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"bostrom19ys53t55r725j882gjcrnf7s449gdrds3h2hu4","validator_address":"bostromvaloper19ys53t55r725j882gjcrnf7s449gdrdsfddgvk","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"KdT8GK9d81xvkDzuNjM3nwi3mijxRfq2YWnM++SAIw4="},"value":{"denom":"boot","amount":"38252993813"}}],"memo":"77d27615009fc703ece46901792cc8750cccd0de@185.230.90.71:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"Aic66jxbwijTVJe5LugB2hOLnVUkEXAgQFAHF0B0a2HS"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["CAmQZPBhI6415XsNQC4FLN63kg9rwgoWkBeuhz4CQ8F3HS9LL2nDJJb5/OGNeLifrHsc02Fu+WQhuEhD6Bq2wA=="]} ================================================ FILE: networks/bostrom/gentxs/gentx-822b374bf2ca56c49fd565d149cd7cb6d175d8cb.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"Kerman","identity":"","website":"","security_contact":"","details":""},"commission":{"rate":"0.030000000000000000","max_rate":"0.500000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"bostrom1ke6pp2kq2wx74tlh5fxqgp7af6jtsna3kktuh6","validator_address":"bostromvaloper1ke6pp2kq2wx74tlh5fxqgp7af6jtsna3wvvr8e","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"0nAyxxNGDv3s2miDdJWibOEoWVre8jadmJiA7BSEugk="},"value":{"denom":"boot","amount":"10000000000"}}],"memo":"822b374bf2ca56c49fd565d149cd7cb6d175d8cb@192.168.0.67:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"A2SWKzAFJLvVQEi/X1HDzFjJ5/1eC42xmaLzg/gs3xkk"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["vGtxVMDxclLZ+BgXsg9dggfOF439ccvs9gWxWQ5osCdKgj0QZSslJqgPs9RwGwxeeZHIHDLFztG0TzEcKQpUmw=="]} ================================================ FILE: networks/bostrom/gentxs/gentx-902fb751851e474133ee4ba1e646f49237b50edf.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"papsan","identity":"","website":"","security_contact":"","details":""},"commission":{"rate":"0.050000000000000000","max_rate":"0.300000000000000000","max_change_rate":"0.100000000000000000"},"min_self_delegation":"1000000000","delegator_address":"bostrom18naxcfp2s397a2ucav2m53f003uylk3qz9fvr7","validator_address":"bostromvaloper18naxcfp2s397a2ucav2m53f003uylk3q6lwnna","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"YV4dJbW6TrErmwcs0VxFiAJUio+6Yh5shQ+hwlMveN8="},"value":{"denom":"boot","amount":"10000000000"}}],"memo":"902fb751851e474133ee4ba1e646f49237b50edf@192.168.0.161:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"A5+dz3ZHelKjHTo31eZ2na4pKdlll/blg09/wBgoqzCx"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["6qgMlfzKEN+EM4lQi//6D6QI92wQPdOXGBy1l1MRigQ+uqdS5QfWIH2DJDpg/0gLSV1yJHj1ENhJAlh6wHN7YA=="]} ================================================ FILE: networks/bostrom/gentxs/gentx-Amber.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"Godzilla","identity":"","website":"","security_contact":"","details":""},"commission":{"rate":"0.050000000000000000","max_rate":"0.050000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"bostrom1dxpm2ne0jflzr2hy9j5has6u2dvfv68calunqy","validator_address":"bostromvaloper1dxpm2ne0jflzr2hy9j5has6u2dvfv68c99mvs8","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"BncD9wiS2MKpBJw1t9PLoIeqQ9pTccPoGBx9cRNoZak="},"value":{"denom":"boot","amount":"10000000000"}}],"memo":"0c4296d5d591bdf7fc8a16ab316a0fefed245ed0@192.168.0.104:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"AhP0Psq9i0nwuprL3XwQpDE4AuCi+hSgDg/YtQV0ks93"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["mq2msMfWEra01A3cNxUFG8+4yd0ttgRM5xRjA0JMBS9l3AfNXoCYMTdFA7iPrKBblkNR8Yg8Ztrulc3UCGDrLw=="]} ================================================ FILE: networks/bostrom/gentxs/gentx-Bro_n_Bro.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"Bro_n_Bro","identity":"A57DAB9B09C7215D","website":"monitor.bronbro.io","security_contact":"","details":"We building for decentralization. Until it comes follow our progress on Github github.com/bro-n-bro, join twitter.com/Bro_n_Bro and rank us at cyb.ai/search/Bro_n_Bro"},"commission":{"rate":"0.050000000000000000","max_rate":"0.150000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"500000000","delegator_address":"bostrom1ydc5fy9fjdygvgw36u49yj39fr67pd9mv67ety","validator_address":"bostromvaloper1ydc5fy9fjdygvgw36u49yj39fr67pd9m5qexm8","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"SEiFL2BSD9TOUsPIaBKx5xZU+ijry95DdZ44u9mwd3Y="},"value":{"denom":"boot","amount":"850000000"}}],"memo":"74b6fc649a41cb1d21201a440b16a1e478706a78@192.168.100.8:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"AjOKnmLV/8qlph6bINrTw3USPl8YVfwqMwY1xlT2+2nV"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["sctX7B6LKkBJ6XdwuLyohNipyg2PSMT9npqNc4rHYaBzlaTZCTv1loPmJW8rurKA4kiGCuU58kxR4X7m7gffhA=="]} ================================================ FILE: networks/bostrom/gentxs/gentx-Hailbiafra.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"Hailbiafra","identity":"","website":"","security_contact":"","details":""},"commission":{"rate":"0.050000000000000000","max_rate":"0.100000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"bostrom1smsn8u0h5tlvt3jazf78nnrv54aspged9h2nl9","validator_address":"bostromvaloper1smsn8u0h5tlvt3jazf78nnrv54aspgedaddv0x","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"triXPhJGBlAduyzF6oF0PKHM9H2sXz9+TWY5gb9lkNI="},"value":{"denom":"boot","amount":"1500000000"}}],"memo":"082ec921427c35a5aeaa8576c5ba2a0513994c4d@192.168.0.21:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"A8ht9IthhnJlqSqkOyPUOuA5I0bhEu//8V17Wvi5nDX0"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["jGWq0dtKzBLIVuY/s/Fk2eZjPy8CsOF9PhZj8iaHSM5Fpy0518Bqt0KYJ47/d2KAL8Zw3Zcw0n82UojxzZLhJw=="]} ================================================ FILE: networks/bostrom/gentxs/gentx-MindPool.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"MindPool","identity":"","website":"","security_contact":"","details":""},"commission":{"rate":"0.050000000000000000","max_rate":"0.100000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"bostrom1gd9r9uhd8a5k2naudq4hua3vf3lkwhfrm63qhq","validator_address":"bostromvaloper1gd9r9uhd8a5k2naudq4hua3vf3lkwhfrrqkl8r","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"RPBRQHcurf6ZOoar9DWoncHbcEGmaceT0zdalDYsobo="},"value":{"denom":"boot","amount":"1100000000"}}],"memo":"615e772ebe444a7bff0078b12ba0c445f56c9fea@31.14.40.221:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"AlR8VrZk5703owY5iA0M9Dhdf1pMBCk4bXg5KawbDG8g"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["FoLuebxVDbQJwDQ1Gv+klkFBIhCo/L87btLU/IMYofYA8KQ3iRnqxGuS15chFOv2z+SNVWc9uKQjDrpUKfLdLw=="]} ================================================ FILE: networks/bostrom/gentxs/gentx-Nett.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"Nett","identity":"","website":"","security_contact":"","details":""},"commission":{"rate":"0.050000000000000000","max_rate":"0.100000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"bostrom1njsr8tngxtygsc73mrtn5738ztkzqy7c7y7h3t","validator_address":"bostromvaloper1njsr8tngxtygsc73mrtn5738ztkzqy7cx7egpg","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"ChguMkmpTQCnekerrNnAnyFePLY3C1jacudM3SYOrdg="},"value":{"denom":"boot","amount":"10000000000"}}],"memo":"6bc53131a0acdd7ffaaaad3f0bd2e13a0cf4544c@31.14.40.252:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"Ak/h9AX2Pl5aIvaC9wcEnj7QDU/pr0YU6WQfbbStR34V"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["fsdilaUl8FMkjptEUgPslypkGHlWUgYSdCTHrfeTkR4npA/1Aunx56J46bgVifKza/9KeHaFMn5sVSUO1rxLwA=="]} ================================================ FILE: networks/bostrom/gentxs/gentx-NodeMarsel.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"NodeMarsel","identity":"","website":"","security_contact":"","details":""},"commission":{"rate":"0.050000000000000000","max_rate":"0.100000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"bostrom1vrym7t34gs9t2dkd8z849zcymkj54kgq7pdf8z","validator_address":"bostromvaloper1vrym7t34gs9t2dkd8z849zcymkj54kgqxm2khp","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"fIbK0sEsisgCoXnWmrfApLX7SdvuhltzU1llq+jiV8k="},"value":{"denom":"boot","amount":"1200000000"}}],"memo":"4a194e60d748fe7407aef58a22957d1d4d1327fd@213.108.130.224:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"AjDkMSMwESOWvRQGEtP/j09Iyul2827V83zhitE60tSm"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["ZD4QxpojQ5tlkW1ydaiwGAPL15olannbLDXjj0DBV3VJKVz/+TLAR4zW0MG5AQORrd5IksT6zHeTRHnfrjxNYg=="]} ================================================ FILE: networks/bostrom/gentxs/gentx-Node_masters.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"Node_masters","identity":"","website":"","security_contact":"","details":""},"commission":{"rate":"0.050000000000000000","max_rate":"0.100000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"bostrom1zy553za8nenzukmv65240323jhuvxzym4pl6w9","validator_address":"bostromvaloper1zy553za8nenzukmv65240323jhuvxzymdmc97x","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"hkaRWuE3BNBVmeqv70qJ++iyYs7THerZyOhNa7E2gVM="},"value":{"denom":"boot","amount":"150000000000"}}],"memo":"4baf7d265d7524543bebc2322089bca4a3980b54@176.9.0.254:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"A6ugL0vd+03w9K+27qpls79V265kl7xpIxkeFWxjAxos"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["eXqb2zaAjXsqUeeFlxLLhgd4ToUlbpz/ysg+tqFSossEmXknpoJB8hpwVOZeUC82zyNgV1VPNmwk+jxvqiLvdg=="]} ================================================ FILE: networks/bostrom/gentxs/gentx-P2P.ORG.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"P2P.ORG - P2P Validator","identity":"","website":"","security_contact":"","details":""},"commission":{"rate":"0.100000000000000000","max_rate":"1.000000000000000000","max_change_rate":"0.100000000000000000"},"min_self_delegation":"1000000000","delegator_address":"bostrom1daxxqs56f6j5qxxtjrjkexghsmnaj66tejshc8","validator_address":"bostromvaloper1daxxqs56f6j5qxxtjrjkexghsmnaj66tpghggy","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"4KsAoQUaZNVyA0Tc02Gw3GYxkuMdgtf+aXTOqKDNbgE="},"value":{"denom":"boot","amount":"10000000000"}}],"memo":"c08e42e2c61b42647f5d0f9179ecf71cc5b91983@85.10.204.155:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"AlJhCdxE6tlLq6sH2feIUpV5tjpqFTfdN/d727m7QFJo"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["ZoFtA2JHo7ENKp4zw360+sObHPimRgECdSAM7zF586YSXeUXRGiZ9j6MnsnbgHfqFg32jeRSG07ayY1RYYNY3w=="]} ================================================ FILE: networks/bostrom/gentxs/gentx-PLap.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"PLap","identity":"","website":"","security_contact":"","details":""},"commission":{"rate":"0.050000000000000000","max_rate":"0.100000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"bostrom1wm4026rxqcrkh09k806m6y4lys942etx5cjz9z","validator_address":"bostromvaloper1wm4026rxqcrkh09k806m6y4lys942etxvz4a4p","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"2VHfckjdelAwGj8b3gw+kq7U0ni9aB9S3rNQx054iVU="},"value":{"denom":"boot","amount":"2008629825"}}],"memo":"d8783bd0a78777503143d90f55c6ce68bd5b53d3@178.170.46.52:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"AoWKUnsu5koT3S90SK96fnKcuzd5myJs6HsYbHskkoFc"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["HAeMOhN4PVUKZSmYzf23Rf4eNUlInL03YTbYaf+sAT8kPtSyA4UGffu6DZekLDWPDNf1fXypWnxXpxkaUvOJfQ=="]} ================================================ FILE: networks/bostrom/gentxs/gentx-POSTHUMAN.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"POSTHUMAN","identity":"8A9FC930E1A980D6","website":"https://posthuman.digital","security_contact":"","details":"full-time enthusiast"},"commission":{"rate":"0.050000000000000000","max_rate":"0.131200000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"bostrom1ccvpcq9ffy0qd2ca8nmmpzfamtyjfc9znwak8m","validator_address":"bostromvaloper1ccvpcq9ffy0qd2ca8nmmpzfamtyjfc9zt56fhc","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"lWEU7pJSRroGTFMa5O6JKRC1JnGsupKTC88i3uAtxu0="},"value":{"denom":"boot","amount":"10000000000"}}],"memo":"55937c36959ea3984cc6e6ebd3354d73bbbdbcda@192.168.1.65:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"A5khg0rKhMayAuU6AK2To44nGX7wjOz3kKgvjHQkgOpm"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["pZi8OR9mNdIliit7mNKp3Wvtt9RGSE0hvqkq8wgdOQ4oc2qZZdSFD7eu6YBBdMNhMxlQKt9GcXEZuIpXQ2C+Jg=="]} ================================================ FILE: networks/bostrom/gentxs/gentx-StakeAngle.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"StakeAngle","identity":"0C2EBFF70582B725","website":"https://stakeangle.com/","security_contact":"","details":"Non-custodial staking provider"},"commission":{"rate":"0.050000000000000000","max_rate":"0.100000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000","delegator_address":"bostrom1g2d9xyuf7ddgaj4llxvg50pfhlsr9ehf2r8dr6","validator_address":"bostromvaloper1g2d9xyuf7ddgaj4llxvg50pfhlsr9ehfjeqjne","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"qOE+qVo9giTu6cypXg6zN3ZT9MitNBHfTYfLL2ADVGo="},"value":{"denom":"boot","amount":"5000000000"}}],"memo":"0fc5cfc9c383223ab2b4b0811bc43c7123653ade@192.168.1.38:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"AzuPqiLKy2Y7g87DO43xNI19pSbQPsSKFh1XPR2AKFiA"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["nXsiARFuivsTpMNogfTiNJZDZIOik+koTMY9qyt0jJgPXxf90mDXCjgSuB9UQywawAe7cuko+bXuwg1egZ6tpA=="]} ================================================ FILE: networks/bostrom/gentxs/gentx-a99b8bcb07d027895bcc2abe6baa866174b5ec23.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"DragonBall","identity":"","website":"","security_contact":"","details":""},"commission":{"rate":"0.050000000000000000","max_rate":"0.200000000000000000","max_change_rate":"0.100000000000000000"},"min_self_delegation":"1000000000","delegator_address":"bostrom1dt9lwmuq8rkngm5gajxchqhpcnavgp7md9v929","validator_address":"bostromvaloper1dt9lwmuq8rkngm5gajxchqhpcnavgp7m4lt66x","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"SmngMSNxQ7TnildgcI5OzZYJxWbwAH2C0UJj3M+J+Fw="},"value":{"denom":"boot","amount":"10000000000"}}],"memo":"a99b8bcb07d027895bcc2abe6baa866174b5ec23@192.168.7.14:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"AtjlOQ83TD6uUs4FUqmVOPgjGp+JgYxk8P6SjUrCbxEn"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["6O7hkhSmqLOUp+/c95I9M1drzkdulcRoJETFpZaSPvEu/wQmTyW0V6Yg3LIJ6KR2U6sbs/e0kfBRHrYfY4OGkA=="]} ================================================ FILE: networks/bostrom/gentxs/gentx-alinode.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"alinode","identity":"","website":"","security_contact":"","details":""},"commission":{"rate":"0.050000000000000000","max_rate":"0.100000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"bostrom1jdmfxzpnqqlhjsju3mz7qsgvvdparw5acx7t62","validator_address":"bostromvaloper1jdmfxzpnqqlhjsju3mz7qsgvvdparw5aque52f","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"JKHQ2Gg/+wWDMcvLwHoEHFccRVZYuGCBSTD/fnIi2vg="},"value":{"denom":"boot","amount":"1500000000"}}],"memo":"963ce143862bdad29c2707302ad4afa21bc1a48e@213.246.39.35:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"A8zFftObCKT2prwqRKuY052meDr9PMCXpbpJdmO3EBty"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["arNRkETkLTBPGYIWi5tYkqeFolCmfn7160BPg5NvL7pW/0g/1T/d52zEUnD7J1CxvHjU7gCF7sIcKkxasLxF4A=="]} ================================================ FILE: networks/bostrom/gentxs/gentx-blue.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"blue","identity":"4815E34CD44A9BCC","website":"cyb.ai","security_contact":"","details":"May cyber be with you!"},"commission":{"rate":"0.077000000000000000","max_rate":"1.000000000000000000","max_change_rate":"0.100000000000000000"},"min_self_delegation":"1000000000","delegator_address":"bostrom1ymprf45c44rp9k0g2r84w2tjhsq7kalv98rgpt","validator_address":"bostromvaloper1ymprf45c44rp9k0g2r84w2tjhsq7kalvaayh3g","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"110HUJd7XFqWhXbE/nF1D4pFcM/vQ8D9yOJbyQF6gsc="},"value":{"denom":"boot","amount":"150000000000"}}],"memo":"d647c9f7f8a50de3fa75504dec5c6943e2f97297@192.168.1.22:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"AhhWC3Vm5nl0W46/gk07bObIRYKLpShYyPjKwyfZpbjE"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["7triW+S9rwnFEZVh57sgHHfvoYH7SHXYwu2rrCTxRbMPWhDhcv35L45NSq4izsWTRUDZXc4ECyXiPtzXPCcQiw=="]} ================================================ FILE: networks/bostrom/gentxs/gentx-citizen-cosmos.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"Citizen Cosmos","identity":"DF0280597A20ACFE","website":"","security_contact":"","details":""},"commission":{"rate":"0.050000000000000000","max_rate":"0.100000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"bostrom1f7nx65pmayfenpfwzwaamwas4ygmvalq2q2ayq","validator_address":"bostromvaloper1f7nx65pmayfenpfwzwaamwas4ygmvalqj6dz5r","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"hzZZ1s5Q2R0Qhbax0Hf7xS9m+kMxbc6FVUihIIoa35c="},"value":{"denom":"boot","amount":"73000000000"}}],"memo":"f1f24eb30de7a1874eb9f11b07bfc87304bd1e51@192.168.1.8:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"A4YPXp3wQTKE8f6dWNPWhxbgMre2cPmN3XNkK+qa0bcM"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["rl6sgn+j7weVYnzBnkhnOg0ubuxUfhEgCqEncgY59p9JWsAqNCxB88bQf2cKDLTrwS7fb/0nNfxGNKp17D9Drw=="]} ================================================ FILE: networks/bostrom/gentxs/gentx-csaxial.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"csaxial","identity":"","website":"","security_contact":"","details":""},"commission":{"rate":"0.050000000000000000","max_rate":"0.100000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"bostrom1ezpth4mp3eeqdt49kgqd5ctr69xev6v2gykpur","validator_address":"bostromvaloper1ezpth4mp3eeqdt49kgqd5ctr69xev6v2s737vq","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"lB5R6K7wY2G4a3Aus+NWAwYiFga5Cc2WxvwZG3Ga3yk="},"value":{"denom":"boot","amount":"1321419074"}}],"memo":"142ac0545728f8c6ebdbb0c0c7bceb9037ac8500@213.246.45.11:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"AyZAyFNW/2s83BGnyEWcYQXRRrygMQCo9o/XDAZCP8oZ"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["TScK3vVqEZ7+i0xUFPvD0LMN1rTyfGgQuhdAcuzyFMVdMUme1i7MvIPCMZW6g1Arj70kNjl6qxO/Q1gHhM+mRg=="]} ================================================ FILE: networks/bostrom/gentxs/gentx-dd4dd317f85209964232cbbe772c242c50bbbe58.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"Space","identity":"","website":"","security_contact":"","details":""},"commission":{"rate":"0.050000000000000000","max_rate":"0.200000000000000000","max_change_rate":"0.050000000000000000"},"min_self_delegation":"1000000000","delegator_address":"bostrom1lnkg57t7mvg5mcl7kdkevtgr9wlf6f9qtp86sk","validator_address":"bostromvaloper1lnkg57t7mvg5mcl7kdkevtgr9wlf6f9qnmq9q4","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"0O20CW17q7chWZGHayK+SlEzCXfJaqTlshkE1xujQCg="},"value":{"denom":"boot","amount":"70000000000"}}],"memo":"dd4dd317f85209964232cbbe772c242c50bbbe58@88.218.191.79:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"AwvyyDlWja87ZwpT/pvNYBXXUGxNnLKA9MvWXij5gIts"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["vagsGgO+zNfHY6f75cwxxY2eF2Z/118v2Yo6okBeaAtnz9uJsy15r9gpi3xheAhd6fas4Cdm6StytC9k5zL3Fw=="]} ================================================ FILE: networks/bostrom/gentxs/gentx-dobry.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"dobry","identity":"","website":"","security_contact":"","details":""},"commission":{"rate":"0.050000000000000000","max_rate":"0.100000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"bostrom1fpl40sref5vp8kfm7xkqlq5qc0v4xrjvk89kwa","validator_address":"bostromvaloper1fpl40sref5vp8kfm7xkqlq5qc0v4xrjvwazf77","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"ZxYmxQPGdPYaBJA8IY4Jg3h/Cs0wVRmPIippypxPrsU="},"value":{"denom":"boot","amount":"2000000000"}}],"memo":"6922a88c66cbfeea0831cc38c2f3485a78b29b46@192.168.88.9:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"A61usxgHwcBypbZ2FaByVOGvL0sScEfE7qNDDvrxIkrx"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["MPUXshgRvcj2kIQRrZ4TvzzGL0+9XLwPKPuauNIZhTo0m8fAdtEGS6BKe1RuUHsmObju6dgWVEn5He8Nyi67ww=="]} ================================================ FILE: networks/bostrom/gentxs/gentx-f1b4b596730ed81d33dbcf051870f0b7b50d6306.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"DemonKing","identity":"","website":"","security_contact":"","details":""},"commission":{"rate":"0.050000000000000000","max_rate":"0.220000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"bostrom1nvr4qa7szsd3e7xfysn946gcqv5wyemlcxmxpw","validator_address":"bostromvaloper1nvr4qa7szsd3e7xfysn946gcqv5wyemlquue3d","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"XXul+cFAn6BK4S/aZlMABb9h+jsqFi7/GgZ01JTfhnE="},"value":{"denom":"boot","amount":"10000000000"}}],"memo":"f1b4b596730ed81d33dbcf051870f0b7b50d6306@185.230.88.227:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"Ahz880YLBAqIp/nXoLLBkhirFgfKcBWd9AH5apprRUg5"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["CJ40V9iORA1e4XJI8DmTKf8i0JqUTNSweDaUpqPboRkek8eP9kzFY9B5wMwQyarUUTCiahBNGmYuw0aO9g5DNA=="]} ================================================ FILE: networks/bostrom/gentxs/gentx-goto5k.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"goto5k","identity":"1B0142FC46D30561","website":"https://validator.goto5k.com","security_contact":"","details":"validator goto5k"},"commission":{"rate":"0.050000000000000000","max_rate":"0.100000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"20000","delegator_address":"bostrom10trdf5eyfcmc9graltx4hmpgznhrm7hdz82k2n","validator_address":"bostromvaloper10trdf5eyfcmc9graltx4hmpgznhrm7hd6adf6s","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"TVfJZnq2vaHv1XI49n7nPn1wVQxurVL3JDVVUUo/Ijo="},"value":{"denom":"boot","amount":"1941697143"}}],"memo":"9715ea8afc6ba882fbb91cc389e4ca6174433e40@192.168.100.4:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"A2y3DqIjyeTqoFiojpJh5eJmLxcROK/zw3fOVj87KvVf"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["h2WNVfwTvJt9q2qoIAPoI0RCCTxrKo5NBNA7jsSYS9JN80d7zIBhDsOZ8PKnS3WwtyAFkdV3nvULJ7+BzHdpiQ=="]} ================================================ FILE: networks/bostrom/gentxs/gentx-kiwi.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"kiwi","identity":"","website":"","security_contact":"","details":""},"commission":{"rate":"0.050000000000000000","max_rate":"0.100000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"100000","delegator_address":"bostrom1w4tk9lj8qtx2x4xf4emgrnq950hnlajsxlnl3u","validator_address":"bostromvaloper1w4tk9lj8qtx2x4xf4emgrnq950hnlajs795qpl","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"823dliApVbj5vUsXFYViaOB6hI8/P7ul0zmZpHmW+80="},"value":{"denom":"boot","amount":"3000000000"}}],"memo":"1874c04a8cfffa6b47e37fe2255158abb7c69e8b@213.246.42.130:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"A2qM2nYkdvgGaKEoEIvohiHgbux/4tdRFhQveYbUmHnp"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["XZeX3P3qL2YI2FAtJSkPZNdzpN4aKZK1OFic6UEzkSthNHl4gVyydwgjsIlS55A0pfMfatiimIOPNJlVdclS5g=="]} ================================================ FILE: networks/bostrom/gentxs/gentx-qwertys318.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"qwertys318","identity":"","website":"","security_contact":"","details":""},"commission":{"rate":"0.100000000000000000","max_rate":"0.200000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"bostrom1402rpwdquxxkgvl740f6w69l65eau5vkqcvrax","validator_address":"bostromvaloper1402rpwdquxxkgvl740f6w69l65eau5vkcztud9","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"r3NIqDgCKwxfTIdvsUYruUSv+ExKI/dyL9UxRt3uuHQ="},"value":{"denom":"boot","amount":"10000000000"}}],"memo":"afa472f8880ce4ef3f7e83a446b6846456c7627a@62.182.82.18:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"AgHfo2wAJPHXlA0p+hez3PySR0siNykr4236MLZVwDwH"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["R9ueed1u83kC6eJSKQg79TYQhxN6bmOFgNQp0pa51kQVIaq8CloXymUbgYO0iN9L7CTUfeiSCJvR0ReKncmTiA=="]} ================================================ FILE: networks/bostrom/gentxs/gentx-spectrum.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"spectrum","identity":"715E454ACF0C537C","website":"https://spectrumstaking.net","security_contact":"","details":""},"commission":{"rate":"0.050000000000000000","max_rate":"0.100000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"bostrom15n3t80p7eseld809f7fu3s9tlcezlymkfeu59n","validator_address":"bostromvaloper15n3t80p7eseld809f7fu3s9tlcezlymk3rmt4s","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"ZxG1y2GSwb/HuBi8BFZLoYYUMyuvboplTa1DDuMGnG0="},"value":{"denom":"boot","amount":"3000000000"}}],"memo":"8285e7ddaa2bc545de9c6720f746c0d3cd48e782@192.168.1.105:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"A+E8waurHOB4l8ab8C8TG3YhYKDC6S3T8SED22kpAHFy"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["1BG5B1EpwYyqJnrSk5xME9EoQnbk4KboqWGzk59L0AkKcrtOCsNoFf0npEBxVQp+Ag6tI+DNVwrtK4UtKF40/g=="]} ================================================ FILE: networks/bostrom/gentxs/gentx-sta.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"sta","identity":"60507CCEB00F6CBD","website":"https://cyb.ai/network/bostrom/hero/bostromvaloper1hmkqhy8ygl6tnl5g8tc503rwrmmrkjcqf92r73","security_contact":"60507CCEB00F6CBD","details":"a Great Web believer"},"commission":{"rate":"0.050000000000000000","max_rate":"0.200000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"bostrom1hmkqhy8ygl6tnl5g8tc503rwrmmrkjcq3lduwj","validator_address":"bostromvaloper1hmkqhy8ygl6tnl5g8tc503rwrmmrkjcqf92r73","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"FVs7R89ToDtCaYNZHrRF8MWCQ4d3uxytQSMg4OMleW8="},"value":{"denom":"boot","amount":"150000000000"}}],"memo":"416aa82d0ab4c0fc379426fcedadc947d84afc50@192.168.1.18:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"A2VNyRXHdKHqT3mosH+sPHFhvCglaCEnK6wLgG8yN8WO"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["tqyQRTpdfMkwClnRQghUOaeD+x8sobxcYVRFT0rr1YR37A1ONih5w1h1ZKPD7mIjF+ydSwM1JYGs/of/nUbdlg=="]} ================================================ FILE: networks/bostrom/gentxs/gentx.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"Adorid","identity":"","website":"","security_contact":"","details":""},"commission":{"rate":"0.050000000000000000","max_rate":"0.100000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"bostrom1mnfalar08dsvtwutmh43lnhx2zzmq7xhdulemj","validator_address":"bostromvaloper1mnfalar08dsvtwutmh43lnhx2zzmq7xh4xcxt3","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"AK7c305pBQkAz05OE8rw5JkwSx+nhcvna6Tz9RXhE+Q="},"value":{"denom":"boot","amount":"10000000000"}}],"memo":"bd272d32665caea2d80127bb930a92e8bb563202@192.168.88.56:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"A7vpgS7DhWrPcDfGh9fzTUXxutVYlAgEK3idq0kTSK7k"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["DSoWS3oAswZIEiruKCAF0cP4LGcp+l1dAA0EMYu4xE9zHN6xI3hLgAieIHtfxfS9vk6H+/sLYtmM5C6+mdhpdQ=="]} ================================================ FILE: networks/bostrom/peers.md ================================================ # Here you may fing peers and seeds to hop on bostrom chain ## Seeds: cybercongress ```bash d0518ce9881a4b0c5872e5e9b7c4ea8d760dad3f@85.10.207.173:26656 ``` notional ```bash 9ccf246720ba68f22c32548159fbe7cc5fc2f429@provider.xeon.computer:32199 ``` ## Peers: cyberongress: ```bash 5d542c0eb40ae48dc2cac0c140aedb605ded77dc@195.201.105.229:26656 c72de1e20beed51b779d89b1cf08d8146016eec4@185.186.208.37:26656 ``` Bro_n_Bro validator ```bash f995433a0b09666c3ced97a912726ab5f747a4d0@95.216.241.52:26656 5e96c2a8d92b09a35da6e31838134ad306d79149@93.159.134.158:26656 ``` cyberG ```bash 39a20a7d84c6e91c6638f5a685a13f655e050ee0@176.37.214.146:26656 ``` Developer ```bash 77d27615009fc703ece46901792cc8750cccd0de@185.230.90.71:26656 ``` Bloqhub ```bash dd22cffccafaece970cfa9e7eb3c8468f6fa1c84@46.166.165.14:26656 ``` web34ever ```bash 5e8522bef5ceca507e05aa0d5f67f37a70222c73@88.218.191.79:26656 ``` POSTHUMAN ```bash 55937c36959ea3984cc6e6ebd3354d73bbbdbcda@95.165.24.115:26656 ``` ## Run a seed on akash ```yaml --- version: "2.0" services: osmosis: image: ghcr.io/notional-labs/tinyseed:latest env: - ID=bostrom - SEEDS=d0518ce9881a4b0c5872e5e9b7c4ea8d760dad3f@85.10.207.173:26656 expose: - port: 8080 to: - global: true - port: 6969 to: - global: true profiles: compute: osmosis: resources: cpu: units: 1 memory: size: 100Mi storage: size: 100Mi placement: dcloud: pricing: osmosis: denom: uakt amount: 10 deployment: osmosis: dcloud: profile: osmosis count: 1 ``` ================================================ FILE: networks/bostrom/unsigned-genesis.json ================================================ { "genesis_time": "2021-11-05T13:22:42Z", "chain_id": "bostrom", "initial_height": "1", "consensus_params": { "block": { "max_bytes": "4194304", "max_gas": "25000000", "time_iota_ms": "1000" }, "evidence": { "max_age_num_blocks": "100000", "max_age_duration": "172800000000000", "max_bytes": "1048576" }, "validator": { "pub_key_types": [ "ed25519" ] }, "version": {} }, "app_hash": "", "app_state": { "auth": { "params": { "max_memo_characters": "1024", "tx_sig_limit": "7", "tx_size_cost_per_byte": "20", "sig_verify_cost_ed25519": "590", "sig_verify_cost_secp256k1": "1000" }, "accounts": [ { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "0", "address": "bostrom1xszmhkfjs3s00z2nvtn7evqxw3dtus6yr8e4pw", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "1", "address": "bostrom16230lc9r27vrxlzd4wlvcz2l66quzj84vlkxc5", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "2", "address": "bostrom1gxhs5wzam5rlgf6cs0lkme400ut64d4ncpfs2h", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "3", "address": "bostrom1qs9w7ry45axfxjgxa4jmuhjthzfvj78sxh5p6e", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "4", "address": "bostrom1ha4pw9w2qgc2ce9jwfrwrmaft5fneus58nqwev", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "5", "address": "bostrom1qn8sr2hzmktlecusdtxj9hwj0upnm0jft9snar", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "6", "address": "bostrom1d8754xqa9245pctlfcyv8eah468neqzn3a0y0t", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "7", "address": "bostrom1ttd4h585vgy29gj0xe0p338drvw9w4m4hzwj9p", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "8", "address": "bostrom1ngd5w7j4u5ar5xh7vzuwqqznnhhcjmnz0s6kpu", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "9", "address": "bostrom10c8znaj94y900syues06dz50hw6y9qpkhunn25", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.ModuleAccount", "base_account": { "account_number": "10", "address": "bostrom1jv65s3grqf6v6jl3dp4t6c9t9rk99cd8yvs0hc", "pub_key": null, "sequence": "0" }, "name": "distribution", "permissions": [] }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "11", "address": "bostrom1pntx8ql2v7cqxu05etg8c4v0r2vz7qnq9uqmpy", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "12", "address": "bostrom17a7xxqa4drnalvv7pkxrkxqer953fdke3ulwx4", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "13", "address": "bostrom1s4czxghmh29aw2ldynk8r9lnkfccw5ph8rjpxa", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "14", "address": "bostrom1s4wntr9selfaznc2ezjkwnwt2y0terx9tqpda3", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "15", "address": "bostrom1qwzsnnuk2u6avvh059c9p50gqqquvcu5svvwrs", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "16", "address": "bostrom1g07gj9ph0r2hjx6ffqn8vl38u4agd5mpqx9m7f", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "17", "address": "bostrom10e3rqclgjz4m4fnx2c23jupcjpyuvyx3x4k7qj", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "18", "address": "bostrom1t3222ju7ssu58xsm3m2xw445p94cqn2qrex3vy", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "19", "address": "bostrom1edlrze5f48jjaw0wxcve4asqqf2tcjdl59ln8q", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "20", "address": "bostrom1m8yf3g2m9p7danjvt4ga6vzewy380pk52kcu9z", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "21", "address": "bostrom1fe5mspz9jsq6p9hqqet86dwp276635l6gacspa", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "22", "address": "bostrom14nzyt8wmx4g6zkeluelukamgsh5v4xgnc25k6j", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "23", "address": "bostrom1mcslqq8ghtuf6xu987qtk64shy6rd86a2xtwu8", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "24", "address": "bostrom1sng0f47cuvx6edxaujh24wc3dvk94q0w6r6smh", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "25", "address": "bostrom194pp2whvqynxnfyw5tqy8fzy2kxsugyrwsaynk", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "26", "address": "bostrom14d92r4svhl4qa3g6q48tjekarw2kt67ngqn4lr", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "27", "address": "bostrom1hmkqhy8ygl6tnl5g8tc503rwrmmrkjcq3lduwj", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "28", "address": "bostrom12psudf4rpaw4jwhuyx3y8sejhsynae7gv53hn6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "29", "address": "bostrom178q202gz0093uke0jy96psyya452rt8apl4has", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "30", "address": "bostrom1kr6udadsvdjymq6m75un4khg27t25st2jn8sag", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "31", "address": "bostrom1ymprf45c44rp9k0g2r84w2tjhsq7kalv98rgpt", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "32", "address": "bostrom1w8ap0ns4d5fagjfwvph6t99uet0cwv6y6r03un", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "33", "address": "bostrom1svm5wl5jf4p7dwemj7wh0p4egr3js6rqtlnefu", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "34", "address": "bostrom1gnnd2eaeqpp6lsd34tnp6j0m85h6r9qg0wh3vr", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "35", "address": "bostrom1t0hmc79ht0qja92p6qgxn3ee3a3rzqutv7thqn", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "36", "address": "bostrom12q68xfj4r00nxnjrqk742rf0z2w6jmwaeppvr0", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "37", "address": "bostrom1ggc9sqvj0uhnzwxu5dyzcr05shwd2vv2guqmas", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "38", "address": "bostrom177y7sqkxmvl22j632haf8y9gv0j3wedssq5m50", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "39", "address": "bostrom1zhy7l8phhpsm2c6xl9c5arcu0z90clynluwrw5", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "40", "address": "bostrom1k60sfzh3ecyqfv36f7zav0089077e4zk4g6mxa", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "41", "address": "bostrom1kpep8dl93ud4wgpws3tcew6as2s36c9v3csw89", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "42", "address": "bostrom16lvsv3w7rnhcm079v6j9eah3xd0p3pd37hl48j", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "43", "address": "bostrom1mnrwpdlnglhtqwa55fa66va0j3fv72nvkz4e2x", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "44", "address": "bostrom1dt9lwmuq8rkngm5gajxchqhpcnavgp7md9v929", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "45", "address": "bostrom12xsg4qm4k5z48s79zdsz84jlhv56kmta3vyfvl", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "46", "address": "bostrom1dxpm2ne0jflzr2hy9j5has6u2dvfv68calunqy", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "47", "address": "bostrom1my32szlwazg9x56xqvsvtp0hqvpzm0r4u3k4ae", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "48", "address": "bostrom1g0ap9fvex93yzzj69uzl74942vjvq8e4f8xtyr", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "49", "address": "bostrom16zms8r32vad3z8hl2vc6wrcnanwmxf0dgh25yp", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "50", "address": "bostrom1d3zlsrjyl3tzp3aly7vjduhrtrtvkvkeaqpdku", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "51", "address": "bostrom18jwk949jqgq3j2du2dgscqxqkkqw5rsjfuucf3", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "52", "address": "bostrom13fwhvawke6867s6raqux25fd24t89j5h8wf2v0", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "53", "address": "bostrom18z9vsjffvggluxcxfqwsmrz02v37hx2e3auyn2", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "54", "address": "bostrom1lnkg57t7mvg5mcl7kdkevtgr9wlf6f9qtp86sk", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "55", "address": "bostrom1dl5df5g2xwj02e93k547etw2ergvc3a20v5ekz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "56", "address": "bostrom13ume6mqte5h9ngx2hh6ngc8aham7x0k6stuvkm", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "57", "address": "bostrom1ldjugf3uj2gwkmmsf5japfknf96zv6hw7xw7v4", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "58", "address": "bostrom1y9zkl7uqjev899swng4eqfuurwaxpchwppewyc", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "59", "address": "bostrom16lf2hvzy4n4gvtx37pgkkdw2e2psfjjdpej53p", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "60", "address": "bostrom15zs0cjct43xs4z4sesxcrynar5mxm82f0ykhl3", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "61", "address": "bostrom1v5jqg6k7mszmchhz8kyfml5h4e2txct9jz3am4", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "62", "address": "bostrom19ys53t55r725j882gjcrnf7s449gdrds3h2hu4", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "63", "address": "bostrom1en69twaxmv7xupy8lq7y539dpecx7yz8g0k8ft", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "64", "address": "bostrom1kgq82m6z2jttytv7fvwy2rklhq5k03gc2h9sej", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "65", "address": "bostrom1hvk6s053m6qdlz9kwllgldwf4qp2c3mrlh9s2q", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "66", "address": "bostrom1ch6nukdgj55c9sk4h5t8spzhahuuvn86gqvarm", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "67", "address": "bostrom1rqudjcrdwqedffxufmqgsleuguhm7pkaq0alce", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "68", "address": "bostrom1qgqkc9t3pfsp6yxjwds70e4r9y0p6resmfnymc", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "69", "address": "bostrom12kd8w45rqxuwpwqvpmdyvvdey9ezeqhav4nn85", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "70", "address": "bostrom152kqs8p7d3jy6kn4uk87ve3alkuqjgewt3cmvz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "71", "address": "bostrom1dn09uyhwmv3ratntc7c603vczgrec32c2fylpj", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "72", "address": "bostrom1qezgmksavgdvcvf9ckhazfy3jfw8whhzfrvtlz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "73", "address": "bostrom1d552nfgekkugdgxw3zl242qpxapl67jfkz76tp", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "74", "address": "bostrom10vpygn9ftv85ra7j7qpewuq5jdgvpjmehlds0g", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "75", "address": "bostrom18naxcfp2s397a2ucav2m53f003uylk3qz9fvr7", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "76", "address": "bostrom18t3kx877vyvstcvn50cgn5w6hppe8ce0pq72m2", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "77", "address": "bostrom1kfqv2fzzu6dgwnf6snql2jslwdws07fl2gz37u", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "78", "address": "bostrom1ggayl03vvv763az6eez66jzwuunyqkcusk8fwj", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "79", "address": "bostrom1fjeq0urgk4x0s6pl2p2fes8c95426amp7lv4dv", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "80", "address": "bostrom1jgh7ghrcr47tuahawzvg3svv2hxkxfx5u9lzr2", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "81", "address": "bostrom19y467lyhqlpa52y6snq9cxw47xhwq0th3p05r0", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "82", "address": "bostrom16ge9uqpqf78jdt0uz58ycalhtg59w77qm9t7d2", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "83", "address": "bostrom1463la66ac89tmlwgvx20c4d2jv84ekzs8kzh87", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "84", "address": "bostrom164k2s2s2td6a30d3rvnv93scy3v29psw4j3ndm", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "85", "address": "bostrom1rya5547x4lrwc2npd63s89ny2dvhamv9dfx9x9", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "86", "address": "bostrom18wn5kyxewwk6qh97493xtj9gufpmqserfahc37", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "87", "address": "bostrom1lljcf37yxh24l3v4kwqsyghwz4ywlg6urg4kte", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "88", "address": "bostrom1d7n8znqg635yxnzlsycnt6kut8z5du5yftutrf", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "89", "address": "bostrom16pdckvu70ufzvm8avd9anga6k35nu7axym02wp", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "90", "address": "bostrom18txzlmkqf264a2awhey6lmeq0dtv5ex69d2fcy", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "91", "address": "bostrom1mmtt0cnsgwx3t90vs4tn9k08kw8xn4v3pggfu7", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "92", "address": "bostrom1mryr27k3h8kqr5ahj82v0ym2xexdewfc9rmng8", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "93", "address": "bostrom1gg73t0eyrkqf953waqxh6uqah62p46jyg82ulr", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "94", "address": "bostrom1jx0az02ccnt4mgj2r9vhvycsdjsztrrgdkwzr3", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "95", "address": "bostrom1r90j4656xsug2hkj57a3knqcs9huh3ea88ykhp", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "96", "address": "bostrom1f7nx65pmayfenpfwzwaamwas4ygmvalq2q2ayq", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "97", "address": "bostrom1zl0t5703q42qx7drxsgl9thjwlul5x6unjhwgn", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "98", "address": "bostrom13q0m4hw6pmajqdqn4g464vzmst78sf55ktrp05", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "99", "address": "bostrom1cjyv02cja896rr5y5lks79enk2nretn3mqyc69", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "100", "address": "bostrom16qu2ymnzzjn05xc6yszjy50caaahcahdvmex5e", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "101", "address": "bostrom1jst67u54vquzvun3dawpmpwyx5ar8mayaak5j7", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "102", "address": "bostrom16s7gwc944patdynnfnvac0jh5u76wsnflty377", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "103", "address": "bostrom1s3lgc3mgy4ltwr796qk6j73xmau4njueds0mgu", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "104", "address": "bostrom10556xtnp39nvx3ec3yjafug662pyt6af84n477", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "105", "address": "bostrom1ffve0zx389ffl80ae9t8jmghcjuzdlqr5eayfd", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "106", "address": "bostrom1ftah3e558ww7xutn5w8h7vrqa9v69pntztnr3p", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "107", "address": "bostrom1wnpak7sfawsfv9c8vqe7naxfa4g99lv77d7c0z", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "108", "address": "bostrom1sgy27lctdrc5egpvc8f02rgzml6hmmvh5wu6xk", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "109", "address": "bostrom1cg79pj70mgl8xlum0rw5yy6enk9jszsrzvwysn", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "110", "address": "bostrom13dpy00jest96g7h5vdgvg9zpxq6xnclh5hzw5l", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "111", "address": "bostrom1mdq5r6az6z8su68zj6px88j2ukr78ea4ggkzt6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "112", "address": "bostrom1lepnu7nt05g79jtmfp2pgrpys3fjc4p74sc0l2", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "113", "address": "bostrom1d5lu67hu3lhqtw6zyv7uy4gkfpdtfnzxdu6mrq", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "114", "address": "bostrom16jttzjgks48kqrhk5e68yv0gv6dt0rpw2f5pwn", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "115", "address": "bostrom1e20hw2pqcgxvumkwn2qeeavcrswzskzjhr2aq0", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "116", "address": "bostrom17z2fywzrdld7qmwzpsq0atxfwcns8rp833rgxy", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "117", "address": "bostrom1tu0e0ggvjtv4gvzcranjnrykac0umnf8y8fm0r", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "118", "address": "bostrom1sltcfypwms38jjj3g38rg7ldx3e6uqrzrnkf9y", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "119", "address": "bostrom1zy553za8nenzukmv65240323jhuvxzym4pl6w9", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "120", "address": "bostrom1lpfs6xv765u4yxr8rlyn5ux0g2a8tyt90hsnas", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "121", "address": "bostrom1smqr5tp684g07aekcn0w852wqlme5mn6dmsny3", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "122", "address": "bostrom1eqkdzfcjnu20ywju35rf3nutxzjxjaqnxqfyyz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "123", "address": "bostrom1waac73cpffx7suhpkvnn8w0a8s2cgzn66x2aka", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "124", "address": "bostrom16macu2qtc0jmqc7txvf0wkz84cycsx728ah0xc", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "125", "address": "bostrom1fapqgamx3c8za8d3z56sydjtjygyu0ly752j8g", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "126", "address": "bostrom1w4548vrnvc7t9j2ly55nvkjvhwqt9thnfcvuw6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "127", "address": "bostrom133t8m00w7llsslnf05zdhehharntly8dqzpfs8", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "128", "address": "bostrom1smtmk8fe3qhlwj3h7nynl6p42946qydzvgj9va", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "129", "address": "bostrom1csf3up94qheqz88fvvlwjl7vc5sdymarktrvpw", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "130", "address": "bostrom1tr3eyy9l480pxjk0ygudwpfus7j8pgdljn09jm", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "131", "address": "bostrom16ahkkv0jzhtp73z83qlhqrypss6jpjm8eekpwv", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "132", "address": "bostrom1htq7u8gy9muv4fk6st04524tdzy8rv04528gys", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "133", "address": "bostrom1kk9clwd4eva7ww95gn4rw3xzuwfs0983sl5cwt", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "134", "address": "bostrom1k7cl9ya9qq30c7m4rvg3823hrc8k80eetqvhj8", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "135", "address": "bostrom16d69u47km5vqdvf6fr8qyhktlacgka7fdvazr8", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "136", "address": "bostrom1njsr8tngxtygsc73mrtn5738ztkzqy7c7y7h3t", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "137", "address": "bostrom1kf0d64nuwsf2zeul5wkx78fsznplnlpsfh7fqw", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "138", "address": "bostrom18ghjkwygsvjcsh20tc5zzhfttxxuex7a9lq8ps", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "139", "address": "bostrom1s2a7rckcky6jmhncxwy0xtwf2ymg87puk6jpzz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "140", "address": "bostrom1679yrs8dmska7wcsawgy2m25kwucm3z0hwr74y", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "141", "address": "bostrom15gk8edxtvvp372flljk884fav55y8ehwru4u8w", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "142", "address": "bostrom1jz57cgfr248y9w6sn76l7pugjkr6e7zh6y2grp", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "143", "address": "bostrom1gw5kdey7fs9wdh05w66s0h4s24tjdvtc9v6vpe", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "144", "address": "bostrom1kajt7sxfpnfujm7ptj90654lmwz4sftpc9mp9a", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "145", "address": "bostrom1t575qeee3qgshuf964qal057z77vljqef9tlck", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "146", "address": "bostrom105zy26ze9gean4qukqlvhkv4mtcndc9t2xaydz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "147", "address": "bostrom1a30w6j4m6g3s2c6zt02z56xynnuaqmn3ahwxuq", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "148", "address": "bostrom1pmaltcu0x97x8j5klc8xluaapkzcvztcn2vkmw", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "149", "address": "bostrom1n3mhyp9fvcmuu8l0q8qvjy07x0rql8q4uwev5z", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "150", "address": "bostrom1u3ap2d4ytcqrr6jlsjf380g3lvgldq4m64s7dg", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "151", "address": "bostrom1keny4peq77drtcdj6fscd9eknqcqyjmxqcr8t8", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "152", "address": "bostrom1kk79xcsuah7ckvunku78094gyh7900ehkllkur", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "153", "address": "bostrom137eezcxcyqgt6kshfdfuvnsdgwpujyje2l8qdz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "154", "address": "bostrom1uz39kh64w8p5df034fh6g5hwpdq8m0h5rx58he", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "155", "address": "bostrom1kz6s2mp4rg7plj8p4qqe2wkegn4ldw3ak2a7qc", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "156", "address": "bostrom1quchyywzdxp62dq3rwan8fg35v6j58sjwnfpuu", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "157", "address": "bostrom1x95keq9l9y9p7hjdt6xd8wnknrpnjsqrqhpwc9", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "158", "address": "bostrom1z98eg2ztdp2glyla62629nrlvczg8s7fvc0znp", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "159", "address": "bostrom1xvssufw8ke03halg8wgu8m994ktxz0y9vm6tqn", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "160", "address": "bostrom1vxxfhd8txmrq76jx3gj7sdrvg0vvqret6kxpgd", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "161", "address": "bostrom1vtu55cc7m6yz9zfg5vqdk80f2g68petgzj9fv4", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "162", "address": "bostrom16yf94eecl6h44l5w7zp75skh3rg0k4veavx762", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "163", "address": "bostrom1gxyf6tsjamnavmkfk43mwfzwscn4tgfkz8k85n", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "164", "address": "bostrom1w4tvyvf3hhpcwv9d4axa8n0mmj5d6ypvpq5mj6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "165", "address": "bostrom1xk4a2u2rjt7mqu5eg8xtxk37l28r3cugkqk9lp", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "166", "address": "bostrom143x4d5wx50204zyreqg8ekgq3n3fcaxucacztp", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "167", "address": "bostrom1y83nga220nfjt9zz0mmqc90cd705az95n5cfwj", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "168", "address": "bostrom1hyjhy0tp6geral2g9vj9nyteglf8t5q42gfq3j", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "169", "address": "bostrom1d8mq46wt2yxsgwrmh6hhfgycl0537w8gggn47f", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "170", "address": "bostrom1p0r7uxstcw8ehrwuj4kn8qzzs0yypsjwxgd445", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "171", "address": "bostrom1duc9gthaeg82lx9pdf642g043xqhgxgxmfvwsz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "172", "address": "bostrom1a4mzr2y2g0cc9f0uhyeh3ftmsfxzqwxfdqtd7c", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "173", "address": "bostrom1xpl2sx64ra5san4su0r0hj8z9eh5cf5dcv48qa", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "174", "address": "bostrom1hem3076xmat8ttr0cg0nnn2lghtc2p7xtzpj8s", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "175", "address": "bostrom1402rpwdquxxkgvl740f6w69l65eau5vkqcvrax", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "176", "address": "bostrom1z8mlsd42eaguaqf5gexy5a7jxgpwpgvz99qzft", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "177", "address": "bostrom1v2n3hg6s4resacgpemfyrd5hul2ntk7tftnk6u", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "178", "address": "bostrom1ufpz4dlnfawg0pr5dcq4hkrf9gs30mu0272p9w", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "179", "address": "bostrom1mkhugmqg9c0qe27stz3m4my9xq7e9pct0jyr3p", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "180", "address": "bostrom1argjwgcplguenq4l92ggn06wadnfrz0ecqrmqs", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "181", "address": "bostrom1ke7kxdn29w2lrxt9dzusa6shvmwd8xm9gxm2zf", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "182", "address": "bostrom1fpl40sref5vp8kfm7xkqlq5qc0v4xrjvk89kwa", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "183", "address": "bostrom1g2d9xyuf7ddgaj4llxvg50pfhlsr9ehf2r8dr6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "184", "address": "bostrom152m9xcx0ht7yxr5834ju7qjcyvetw8amd04apw", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "185", "address": "bostrom15n3t80p7eseld809f7fu3s9tlcezlymkfeu59n", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "186", "address": "bostrom1ke6pp2kq2wx74tlh5fxqgp7af6jtsna3kktuh6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "187", "address": "bostrom1daxxqs56f6j5qxxtjrjkexghsmnaj66tejshc8", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "188", "address": "bostrom1nywu6z26tpcrr2kcqe8z7t235wrfkhfcfhlzmk", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "189", "address": "bostrom1mnqlcc7mslzxcf798acp80u2fxudsuzdn0px6s", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "190", "address": "bostrom1ccvpcq9ffy0qd2ca8nmmpzfamtyjfc9znwak8m", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "191", "address": "bostrom1w4tk9lj8qtx2x4xf4emgrnq950hnlajsxlnl3u", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "192", "address": "bostrom1s8l0akn79kk74g32kf86stfsa08ck9qmm4v6ws", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "193", "address": "bostrom10aqelwndkz9k8uawp26elxep64ayc5rgn24h7p", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "194", "address": "bostrom1ap7zhu5gxlk7n3g97dqehm9nnt3mje3nr5jecs", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "195", "address": "bostrom1j6he98h8xwnt2yp9eczhhuff3k3hvk98gr27ee", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "196", "address": "bostrom1mskldfjlnup46adzss7lukfh3emm6z4lmqhk7z", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "197", "address": "bostrom12ysvrknuwdr6737fnc06v875whfh52xj3ewaf2", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "198", "address": "bostrom10trdf5eyfcmc9graltx4hmpgznhrm7hdz82k2n", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "199", "address": "bostrom1nvr4qa7szsd3e7xfysn946gcqv5wyemlcxmxpw", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "200", "address": "bostrom1wm4026rxqcrkh09k806m6y4lys942etx5cjz9z", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "201", "address": "bostrom1zeg2k7kd8qadmwd3kslwmag3erq7hqxt5aajjz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "202", "address": "bostrom16h7tyj5p69t3r7qasunf938cx2elp38fhqc7zr", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "203", "address": "bostrom1jdmfxzpnqqlhjsju3mz7qsgvvdparw5acx7t62", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "204", "address": "bostrom1smsn8u0h5tlvt3jazf78nnrv54aspged9h2nl9", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "205", "address": "bostrom15kl5tv0smz5h8eewu5hs9mtnusz4dereyqxxtw", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "206", "address": "bostrom1uew6fawa3ahu60tj5kspmr4u0zvljj69q4s3ps", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "207", "address": "bostrom1ezpth4mp3eeqdt49kgqd5ctr69xev6v2gykpur", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "208", "address": "bostrom1avvkajdvmj9d8jpl0ga4scftjykeuhjpsa9kf5", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "209", "address": "bostrom1gd9r9uhd8a5k2naudq4hua3vf3lkwhfrm63qhq", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "210", "address": "bostrom1vrym7t34gs9t2dkd8z849zcymkj54kgq7pdf8z", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "211", "address": "bostrom1lk3yjcn0lvwj9f2dj75m8y3smpq5s5zsnnj3nz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "212", "address": "bostrom1hk49ws6ded79xmwehv7yrw3q6mfj7kulafxqhr", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "213", "address": "bostrom1vx9qctuxswd6ydcv4z5pcuuvct7y9l0nqq799x", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "214", "address": "bostrom1ydc5fy9fjdygvgw36u49yj39fr67pd9mv67ety", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "215", "address": "bostrom1wkjn2nc4v5g3tpjj043wxtmeda90ql3yqqddav", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "216", "address": "bostrom1gh09lmm8flkuu3w38mr4axvunnu6qqlapuwzrv", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "217", "address": "bostrom1m0tjgkrh4td9fcp8nnssu3rfdahzfgdshsall9", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "218", "address": "bostrom1mnfalar08dsvtwutmh43lnhx2zzmq7xhdulemj", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "219", "address": "bostrom1g36u05ehktgw5h5udj8hyudd9057d9tx9r6zef", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "220", "address": "bostrom175tm6fucmk0e29cfgzaud6kqgksy25p884kjx0", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "221", "address": "bostrom1v46pz6ddetfc3tnvdr28ss0l48jhazgynvp3c7", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "222", "address": "bostrom1stfw0z5nf2ncxxtrk7zndpf2dla3nh379egwcy", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "223", "address": "bostrom147rnn0rxqkythj4j9ccq0kytmh7f005rn0a3zj", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "224", "address": "bostrom1pswgrf5ap0kld3lpun5z4x08wh7nmgamd8mgex", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "225", "address": "bostrom1wt9h9wm3zf7yzsy68x7v8p973w02kw8yyurh55", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "226", "address": "bostrom1ucl2c39dpwqm9pp6cvmlazn2tkwavszhs27j96", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "227", "address": "bostrom16w2xwdzf6tzucpwcjjqtg9656a4kkv7g2f6vk9", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "228", "address": "bostrom1hmrxmc27fu4ggdpvpxqtahn6uvtj38vuu77a02", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "229", "address": "bostrom1uwfk6h06w8vnhmyp48vwcpgwncsec8yv3z0xyg", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "230", "address": "bostrom1nuc82t22xgp09rs2tdnlxxgm95pjg5matjwwye", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "231", "address": "bostrom15kdrahda8qcyfa9xe8kt2f737m22x2sleslj5l", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "232", "address": "bostrom1n89a8avc4j7cv75lfsyynx5kazlk80ar5qcdx6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "233", "address": "bostrom19vgwu99fdawejnedgsfx8dmxuc0z4emjf7a044", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "234", "address": "bostrom1s6v5ragv9gg3sq7j3aeqtyy82uaxv3y05hzhh8", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "235", "address": "bostrom1y6huw3naar38u4rtgqmlh9smfu93gszst9tawp", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "236", "address": "bostrom1hqeqy4s039q0qcpayqcyaq5hyyvmph97t79m9n", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "237", "address": "bostrom14h099ukgvp4fm9qs0xnmljzhevrmneq6m6cltv", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "238", "address": "bostrom1xhk0s2ynz2sq3ak3lr4u5gg0da4vyaxkfjhg7l", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "239", "address": "bostrom14z6glatrayal5j53632kcefskyge6ujmgshqfv", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "240", "address": "bostrom14n625exc6ftee3t6tez3hj47lv49amjzan5pkr", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "241", "address": "bostrom1fhj7pkuvwflr7z7ngp2v9tj7g58aq2tjgvqfaj", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "242", "address": "bostrom1l4krahjfp87exsmumzpnrfeaer2gsghpuwhfp6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "243", "address": "bostrom1udal5nr3lz7mg7j7k79se4rz0tsjj8lur45q99", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "244", "address": "bostrom1n55zyf6wlvh8jp4wxqgx4ta283jx0e2n2tutgm", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "245", "address": "bostrom1glgevt43557u6s7a2q9q40kzt8myw4ngcv6wr6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "246", "address": "bostrom1mj0sj4eaar5qnjn3l05ep5wgq3l6agtvvqwvyk", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "247", "address": "bostrom1sm9sq4wnn62tk5yz0x3fvvx2ea9efguqwvdu64", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "248", "address": "bostrom190y8vwhmyjdnk7cfutcm7u8haw80xyejdwxsql", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "249", "address": "bostrom1rfh303jsl5297sxgs5txpt97lvxpjt4he3yy5r", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "250", "address": "bostrom12u6qgyrdsy4xmw04vfkkkh9a9tqzw66g59hudt", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "251", "address": "bostrom1pjvkddp4fmx8ym5j7s7su8kn3zuqj255djzpja", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "252", "address": "bostrom13nrdf490fsuv4rwjp02hlyvalqjkn5u6xxqvqz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "253", "address": "bostrom1fp9q2t9zn9gr5qjh9wljxuavtcsc4h8uqgnm2e", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "254", "address": "bostrom1u2s32xsws9y2sskz6zvn7lawepdqxad5dcsyy6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "255", "address": "bostrom158mysantvvk7x65tfhhuu8q2va4ls34r54hk78", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "256", "address": "bostrom1clalfxmsrqdgnqq5uxlx0mc983pyp3wq4xl03c", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "257", "address": "bostrom1wf8alywyvlxy2dqfe38efdpdmuscfpf4jxvg6r", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "258", "address": "bostrom13zf8kghx7h5fyttk6xdnjqn9c87z0rd36sfqjw", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "259", "address": "bostrom1cc43k76udpd3xvpn6md76zz3ru6nvcnreeg2eq", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "260", "address": "bostrom1l5x6kerswths5xl0d6672y9yyn9mg2vw8yz59q", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "261", "address": "bostrom1qe4sguqg8ztlyy7psf7lzwr4ahph9j36k5hltz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "262", "address": "bostrom1mn8ev805fde2xswght0snwfayfj9tn54dt24zg", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "263", "address": "bostrom16vc2mjjfxx2h5m6jpdp4nqfu5095qaeeq27qxj", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "264", "address": "bostrom1jmhqgld7luvuhh42wac24z6nlggjvkc7fzgs62", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "265", "address": "bostrom1qjknpllzp6w6qsxxjx52zxald29wpyzljznzdv", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "266", "address": "bostrom1eq2h9enjxsg5s08scr69lzwde8fl79snw20dc8", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "267", "address": "bostrom1dx8mvxfu6mpfnjehvdkp9lsvu78ek2gjr7r766", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "268", "address": "bostrom19uryr2zuxcfdevfq429jng9a2evxwadlsky04c", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "269", "address": "bostrom16862syzdtc6h0sxz92jhnjjas5yhhjgzvyewwd", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "270", "address": "bostrom1teuan269feyw4ax94jfp4pcgrhqnn28gxxz8mw", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "271", "address": "bostrom1yvlp9gzqaufwz02swp5wqsqhlmfcrcl8m22gzm", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "272", "address": "bostrom1latzme6xf6s8tsrymuu6laf2ks2humqvfcz7m6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "273", "address": "bostrom1ec9da8avgv7tnvsx3v8g8veqrhlqq26lnncg5t", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "274", "address": "bostrom1c7pv6zyza76f3yhv0zvjc042e8m7w796qmvkse", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "275", "address": "bostrom1yslufs9kq762qty0wh62c8qtlpm2202ejmw4ef", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "276", "address": "bostrom1y935ede6znmcvqdmn6mnl2aa5zxcqvvracsczu", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "277", "address": "bostrom1y675phjdvw576ahlcmlamrzr28rjht9mx709lg", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "278", "address": "bostrom1kjhdx3nkh6krdhryvjzkq33xwh6wsyy7y8ark6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "279", "address": "bostrom1jxpe7neu764uasz5y5u4lrr5jtltv430gjm9dw", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "280", "address": "bostrom1hq8d6pu2l6wkrwu9jxcqjcu55g8l43zxmrd6dk", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "281", "address": "bostrom1c4h647a9rj8n9zye5ttmh9chpg66f3ffdvdds0", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "282", "address": "bostrom14ysuwg6p4fzfaa6tg4s3hazu86pfevsw4cegce", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "283", "address": "bostrom1x7wp0u877dkw7m84jv54c9g6zpd5r8t2nm47gn", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "284", "address": "bostrom1gss7y04dky2fykck4dyp0pe39wxawlxm2l0yj2", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "285", "address": "bostrom1cerh237zd5rdexptjw8ryhwdf2tc9eupz7sfn0", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "286", "address": "bostrom1fz799u9jc0umceng3nkjt0njxy6y3550uq06jn", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "287", "address": "bostrom1wzqyjejz5px38vgqsegafrcexl3963q9dsgqh9", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "288", "address": "bostrom1evz2xfd6sam0kzz5qc5lje4s90vcgyyrzz47pm", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "289", "address": "bostrom1mzmzlzk4xpm6zy68c43e6hen98w07yhfedumgg", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "290", "address": "bostrom184dur4s6pldvhvcyputu6yshsm09s6wmvylt8k", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "291", "address": "bostrom1gyhwacrpqwues05pkavw7xwehcqsmgruy34zps", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "292", "address": "bostrom19wtkh935tx2ut2n4m6tjvkfvew4shaeezfl7em", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "293", "address": "bostrom1a2kn43nquua6gmr4n42htmjpceqj7fzushe28h", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "294", "address": "bostrom1u74s0z4ft63c6zz7g8xs62esdtdjkzuk4zf0rt", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "295", "address": "bostrom1d9en5u0cfaucavx848qeq4k6ywqd3z5d5a778h", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "296", "address": "bostrom1edwwsevuywe3sx82sustvyx3f3cvjt44ugccgy", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "297", "address": "bostrom1gcy4f6f2sc73aegd9r68rt2q6teekl6swjva3p", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "298", "address": "bostrom1d6nkeqxmme3564wd889kr6cjed3asxqzjve0wl", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "299", "address": "bostrom1djdfq5mn3dzm9whpznczxz77s8ep2qggc5w5xn", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "300", "address": "bostrom1z8fyzv3mjfccvrxhckr2u3lnc0hrgrlm4zkf8c", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "301", "address": "bostrom1tcnlvf6qhlc3x7ax2vk3vzhxhf8wy8xrnjl72d", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "302", "address": "bostrom17ud38eyfkd800kvw3c9kl3zpvgvj296nfszelr", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "303", "address": "bostrom19rtverjn8kw7dzwzch2elktxgcmak6dlqugxfw", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "304", "address": "bostrom1mlqakhlxplhlezk80lph99wcy377j9dk2qx3gg", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "305", "address": "bostrom1ssu4wqtzvvmwcukcv7l8zxny647mdx03e0t57j", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "306", "address": "bostrom12reh000lje8y20wshqmgl8tg70qggt2ac7qz45", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "307", "address": "bostrom150svyax8m8dwljwenc8xxtsg0avud07m5frlrz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "308", "address": "bostrom14tjwqqyha0c9r0s29dm0n0zdpdc4hfrvn7jqsq", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "309", "address": "bostrom1x8r0ktn36dsxsadnp3863txyd9pksrp6awcuaa", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "310", "address": "bostrom19lsruwa85k93ahzkdwaydyrl6ehz9dmmkava0y", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "311", "address": "bostrom1tyzmkpn0axquu4jlht3lllsmq03um8kn5cu5pt", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "312", "address": "bostrom10a9mqy8cu04nyz3nj934ck39p6u9ddjt9y5fve", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "313", "address": "bostrom1f2uslv6udnjwyqkdngc7rswp5vkmgavzgy952g", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "314", "address": "bostrom1t7gw3d2jz4qc6k6umgkazvfyeydjv7l6nym265", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "315", "address": "bostrom1rc2647d9nftgwwh9n5vaw26lnjdrewc4dum68g", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "316", "address": "bostrom1zejjt25xw9gwvhave95ykkvgqjtk7j56fe9cwh", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "317", "address": "bostrom1vesdfkzd36m08clhvkpusq4gv0dnqm28rm2hey", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "318", "address": "bostrom1ypvt8rf8md7qedvnk0p8cvd6mnffepst8f05p7", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "319", "address": "bostrom167hs9ma63wd02xym0vjw80uqlekt0cs54ass6v", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "320", "address": "bostrom17tksas9e4nkp25vgwcsd7z6y83pa6u7sddyyez", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "321", "address": "bostrom14thj9udwenk5q8c5ey2urude2j54xud2a26rp3", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "322", "address": "bostrom1y7ku6vf9vq53pv4y6lw2zjn4d5ul3javm92whz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "323", "address": "bostrom1mzn966mlprxgkvayrqu209069px0qwz7gzn799", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "324", "address": "bostrom1cjeg60652ueyu5222l3atmm8vrhlq4tfusnswk", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "325", "address": "bostrom13855g4d5pfhtnqemgp700qs36qpjdnaz0dx2m5", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "326", "address": "bostrom1ueywgan39tj27pdysq0d54cqvcwyggf6eves07", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "327", "address": "bostrom197h938dvw52kzf2l7gke2u5tcz3grvlexeaq0y", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "328", "address": "bostrom1pkxtd9xwmqwg08kjgz9xqyee3aw7j8upd89ah6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "329", "address": "bostrom12arnsa069zhad0e40mlgy034n7aq77e2nxdven", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "330", "address": "bostrom1m3yh7j0jefp9dl26cz8fqexfg8tds39lh957jw", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "331", "address": "bostrom1ysn8jyjv464fv4wpt40vezh7d5tw05tc9v858t", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "332", "address": "bostrom1gh8tenvx2sf9kj2c359ey6s5k0vzlrl7z4t59z", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "333", "address": "bostrom1svwchckmrrkfl7py7l2fz3esla7lwmalld4yr2", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "334", "address": "bostrom1hmdjgtv3yq4qzyuk3ynyt42sjntma8hqarepjd", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "335", "address": "bostrom1wr0mqeyea45u9av63srtvgr553nyg6l9p57ezr", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "336", "address": "bostrom1e20dl8se4v2ev79qcay3ag7uf5t98gampz0d48", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "337", "address": "bostrom12c8kh7aaz2gg0l4nkd73t58nhurdaren55atua", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "338", "address": "bostrom1ftyx5guwf39fz4nc5n5nc9fua36cq344rm2d43", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "339", "address": "bostrom17jq8ev7n4e3zv8zdek5mccvxcgxxtkwva5vwtx", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "340", "address": "bostrom123wttw3lu62m7lcg23rkwr88cvv8apjmvkuj9f", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "341", "address": "bostrom1j5wpswepyxva5vupvg05pq6jzqh7ttdvepkhp3", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "342", "address": "bostrom1wh5gfxyz8x95qyjlc2s24h3czr60vfehwt49xa", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "343", "address": "bostrom1z3u9w3vyq6sw7ndxcdpjkgvlj0qaqm6spc3jmp", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "344", "address": "bostrom1pzyt3y68zcnvl7hkvuffqfedccaptf6nt2x8ya", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "345", "address": "bostrom1pzxnpyvxr6x9z64y6w3ctv0cvcx9sp90ehj960", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "346", "address": "bostrom1pvu65ccqw3fmgq88j2j485wc6qm96nx7h7ln4f", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "347", "address": "bostrom1nqxwnut0hdgsn3l9zaladaft5xt9c6ex9qquza", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "348", "address": "bostrom1njpfrygstn6r5awzp77keyhkl3wfhzmvdz2pug", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "349", "address": "bostrom1ke9xxd3d6y0ttduac062zvv3r0jtakvhkvqcjz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "350", "address": "bostrom15ak23s0usm36hv2e4kajhe0yx592hw474p3gkq", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "351", "address": "bostrom1gffprg0nuvj9ve39s9rjhjp04u7k8xwan2tzff", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "352", "address": "bostrom1yq5h0gjxuup83hdz53utukwhkkz684mk3lx7cr", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "353", "address": "bostrom19rfaqnnz5fy3qct8qxzany94t2p7h0rrc75lmz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "354", "address": "bostrom15y8g5ggq2lslncdnlcscqygyesefmjy0t4cae3", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "355", "address": "bostrom1gfkztltd789py02jcd79dnkl252uej7x8pnx4p", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "356", "address": "bostrom1h9k38zr5a532jzl0hsker9qz785m822zmqw974", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "357", "address": "bostrom18ghdg8y5hx6esxm6ndw3ywgtalvkmz48zeyc6z", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "358", "address": "bostrom1zy3nxgwtw9hr99tzfaxasgwklm9ev843fju9zl", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "359", "address": "bostrom1vmfs06hv80gc8jcpzu93ld4494azendxfalh2g", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "360", "address": "bostrom1d66wegxpllcsnrzv9saqugpk2dausa836qlqaz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "361", "address": "bostrom15njl9exppdfms5fg4zz9wafn4a95lfj30ftx58", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "362", "address": "bostrom1v2fzs3a8mvm4nhsfcpk85gt3d8rdacv6zggl9r", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "363", "address": "bostrom1fm842pq6zxaqs86fm30xv459gx7hm7f0ufujvz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "364", "address": "bostrom1rzr7gnkm3kdqmzqya7ky98m8tnnmtet58deav0", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "365", "address": "bostrom16gtt4cmrvg2us2rgecym9zt65zet7qq2euzvdf", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "366", "address": "bostrom1jsdfjw0pjjj5thg7z2tpm30njusrlsagtac7rs", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "367", "address": "bostrom1z33aen2znsmgy7wwzavwh2q0u7cu4e9xhky379", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "368", "address": "bostrom10r2sn7sasanc0tuw5wzupxvlpht5uv267her62", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "369", "address": "bostrom1gtma98yjsx43zc30j99t7t0tmdjt2gyp9e7g0r", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "370", "address": "bostrom185y3kgv3e6t4sue0a55jyq88hv76th3urnca4c", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "371", "address": "bostrom1xc6jdlqd8gd9e6p73xdc2yw7ad3tnl8w7j4wsl", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "372", "address": "bostrom1wdk6rndatlj8dpxq799vmu50zft7xk5768ej2v", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "373", "address": "bostrom1uz3xp4au0rxawmct6ffj0u3le7uglyza43appc", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "374", "address": "bostrom1uym8hd4pum4zz2mpkf93y8435u725k97e2c38p", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "375", "address": "bostrom1u8yt9tvnwvvvlm36w97nyg27ue797hrvkz6eux", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "376", "address": "bostrom1u4427txgc9pulkuu0wk4v9cjxqa0dxee5az972", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "377", "address": "bostrom1epcd5upewwa7s20u6kgf9uywa2f7c3yj6zaeg0", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "378", "address": "bostrom1tx6dnqh0nnj05uuell7rhnwhennscehlnjylxv", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "379", "address": "bostrom1ypzhtfsyuejekw0w0z207wyedqm3xqafc8nu7g", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "380", "address": "bostrom1s4ytylknecgkp7sp3jgf2f5lj7mm2xxz0f9rl3", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "381", "address": "bostrom1s05hsv6fxhkpclwxzgnlfjjk7qdm78nmpchj08", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "382", "address": "bostrom176q2gvutyk63dzknylcvdhp6lyjwu5w9fdmmev", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "383", "address": "bostrom1e08w7wrjn05gl06xkwnlfmud5f6trdkrf0drg5", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "384", "address": "bostrom1pzp9nadejsjzfkpfl9k7ktu2cfhprw4r7qvd5p", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "385", "address": "bostrom1pt3a6xk432vs8lp0z6ya3qhqhxks99xe4sxxqq", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "386", "address": "bostrom1damlfdlp8yynjvrmv6pd3t33f4currrhe4cm4z", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "387", "address": "bostrom1cmhrs08sqv0823mj057svp8jerp6avne6xmtrc", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "388", "address": "bostrom19wlc6vms3qkuy48wgg2dl06veahgxl47s8859j", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "389", "address": "bostrom1h9zrqgwcjtul3s9qxf0hk0ym9alm44ztywkfyj", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "390", "address": "bostrom18fudz7p6ah9yvdr4p9aflp8pgzngx84cem5lra", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "391", "address": "bostrom1e8dsx8yx9mjn8v8egz2n5vafkymqw98wy4z6re", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "392", "address": "bostrom189tpr8vg4qvwn7fgs6szkqr25yrammvvlzx0zr", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "393", "address": "bostrom1xvsukg4tltfzduw0lsvgqyrhe6rzrlp472ln92", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "394", "address": "bostrom1w7f07762zelhx4spzkndmygh2dz58g3nn58v7q", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "395", "address": "bostrom1808q4nv5qafkk8ec9h56wwth6sl5a5yd0elve6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "396", "address": "bostrom15a8z9l8ufw8v8zdddfhesnmfzwwhua7axrmfxl", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "397", "address": "bostrom1undz2328av9agfhaguqs8zxzejv5zqcc9grdmv", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "398", "address": "bostrom17vw0qcu9j8t6jhh83sjrzj07nwg9nndfcpw9g0", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "399", "address": "bostrom1evnwfeuqsgkjwe5qwe5acyy6m4w5ch03m3e7a6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "400", "address": "bostrom1t5r4uhu0tscqw380t6hqmvrgyhlrj3u43vsm43", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "401", "address": "bostrom17kwvcuvar02ldacltr48373rm74z8lfkcq80vj", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "402", "address": "bostrom1r7grd2sazgzsy8y0c8wlsnjyhdc0sq4npr0v4q", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "403", "address": "bostrom1pfwja2fu2qcqvdws6rcdr9y6za46dklaxc83fh", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "404", "address": "bostrom1p4uyyk8sc2arl4n9egw3xrn9g7rpkzlerf4nlc", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "405", "address": "bostrom16gxdwa79rsvkjaawpcpswthgahm56p4mpu8fe9", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "406", "address": "bostrom13nef2p2g48kmj83m7f0ey76q6p9cdyrn03x4tz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "407", "address": "bostrom1m9x4gg6frezyeqldxdz4dvegxpcytxnapgykwu", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "408", "address": "bostrom1kfz37afuxfyajrzk7xv6937xc0jsq4zd0ce7dz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "409", "address": "bostrom1kae5k3nnzs3q7tar4ec3w29w4avd8saqujpjk5", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "410", "address": "bostrom1hjjsjgv7sx88mxfq9y44ql24xs76jj3w7y9ff8", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "411", "address": "bostrom130avjyegx7glgnqvraetqj6ztacrqv9kdwawkj", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "412", "address": "bostrom104rtaftr9xmx6dcakempk590tfxx4ytddqcj97", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "413", "address": "bostrom1f6tmyjffs0p7f6xeh25esjhawxu2kll9j00a47", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "414", "address": "bostrom105c5jk0xwzlk4pexgaeqkxq0xadtqchc4lmev6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "415", "address": "bostrom185tek8r0ptelug0erducctzc4d83q5np3339k5", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "416", "address": "bostrom1z0m5tcv4jde5acv0w4dms537wvntgj7x47zmeu", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "417", "address": "bostrom1fzkp5pux48ux72wsgls9lhxp5cq2tqsy32hfec", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "418", "address": "bostrom1nsffk0nt927vn7pdsk8epzjeqch3yfzkzq57pl", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "419", "address": "bostrom1e4cnw86pl73k2sfv7uwauflfl42qzncn4akyv7", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "420", "address": "bostrom1jlu5u2sj0afddmcj7lxfy0ng466s8l2qdjz24v", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "421", "address": "bostrom1y9tvvunr7uaqjjw8u6xn5muypq6pheyz5gygm3", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "422", "address": "bostrom1qsm0ujra4vdwymc5vrtey2rvalyq8392h75nr4", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "423", "address": "bostrom1jgvy2vr96auye3er6n3tkhlu9hnxs6h3a38rpp", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "424", "address": "bostrom1jcj0w0e2khy0asm7dz8883xnepzmaxylwez7j2", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "425", "address": "bostrom1q22fvnhna2zg2g2xm6s5587w8fvsh2zzfeey68", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "426", "address": "bostrom1amletsu7926696dpeay8wrewqgww5s7yunjjxr", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "427", "address": "bostrom1qkltelhy5zsr4kfrefvwsupxyt6y9skwjpd7h4", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "428", "address": "bostrom1nfdyvvjy5hum8gpgmt29d0m5y4te3ekpfyz7pw", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "429", "address": "bostrom1hjz37u09vws084cvwjlr5t27wmsrzm9tmfspu5", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "430", "address": "bostrom16zykdjnfjdy5cy3phuymmcghh8x24eah2cmmpu", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "431", "address": "bostrom15pax03gsgw84lsygpxyyvtthd8fswrqp7wjs7m", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "432", "address": "bostrom124ll3q05an955eh26ygn34u5gtm9287arjrgj9", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "433", "address": "bostrom1teyn0utv6yhnwux44ycfvqh6z888pvjaz9cz6l", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "434", "address": "bostrom10905rstxf5tzj0w6gguaa76ma7s32v48um4w9z", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "435", "address": "bostrom1m7y6qezuemqe6n535z7s80ee8zw4zg486vr53u", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "436", "address": "bostrom1pkhgpslggp3t0nrwskvgczxmavg7yejfullesx", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "437", "address": "bostrom1zyws7rajm9f3ql6jqqpzvnml0aym9vspd7tjxk", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "438", "address": "bostrom1pa0rcdua5v9d4vf09ksnnl7t96nfkf3w37k4dc", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "439", "address": "bostrom1durjade4he9l23rw38azruzfttpmc8223n6r87", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "440", "address": "bostrom16jvmfza0q60umemx2pv8s5kle2h8g9x6jj9fkq", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "441", "address": "bostrom1gywad2frusetg26dyh83cfaevacravashyjwg6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "442", "address": "bostrom16kqpk5jg9e5ucxv3e003mf48yuamw4ce5ww4la", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "443", "address": "bostrom1zr9urr3m42w7pu5h5xn7rvghcdk5vtrtmfw7wf", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "444", "address": "bostrom1jet9jf456dja8vqlhk407l06yvfehwzuvjaynv", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "445", "address": "bostrom1q8ajen3vu5v5uu4czkvqasqvw827dz2nqq6d0s", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "446", "address": "bostrom12w56mhf4nsfchquw0sgzwn72qkzvfvquxhg6dn", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "447", "address": "bostrom10v8qjj6haddx7wmnr65mcsllu8xunkee7zg3z5", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "448", "address": "bostrom1hy8dexwz6ynlnnaj8ge7jvmzs4c6qmz6yh97lc", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "449", "address": "bostrom1vpp9vy0fnxxw8yk5t2cctutpfv8pprvyhnjw90", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "450", "address": "bostrom1w0u83ty3nmflg9846zmh28u0hweccs3fzfpx0f", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "451", "address": "bostrom1z6lhk6u25fceqylmgv65t5py0c8kclgkszmqyx", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "452", "address": "bostrom1zcf0ph3k4p2q2pl32zqspy5f7jkgxd5s4kcd66", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "453", "address": "bostrom13s4egz6pqg6a88dunme3esuee5w7qlkjttcs08", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "454", "address": "bostrom12w37894jf7rt2ck709rk8xa23lz3lg9tv93tlz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "455", "address": "bostrom1sntt4y34tghn45vw97az7mz4vkcw8kgregkph7", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "456", "address": "bostrom1pa0lcssmjkkycdvrhhzey5h94v34wuf9u4ths6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "457", "address": "bostrom1l9yx676futn4h28rxupsvk7evl9s68hrufetdw", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "458", "address": "bostrom1knpgev72f2empt8j8gcn24my8kdasy2lcezjea", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "459", "address": "bostrom1clr05sms7eklm509ger6jdzhgheafskv4wwxrg", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "460", "address": "bostrom186tpdptavhzz7fg83vnm4r2y85cfqyg6sntmun", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "461", "address": "bostrom1qc4t2q45f826cfc7k0y45ma8f5qrrfv2nkly33", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "462", "address": "bostrom1n0wkta56ktj93nzpe9amkgrzq7rhzt3gy6m8uh", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "463", "address": "bostrom1exul86z68fzck5jra7jp8xdwvmfz5p9qyuh8um", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "464", "address": "bostrom1melp9r22clnjzzudd0thvs5zzveqfjyl9xfw54", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "465", "address": "bostrom1zx70t5xqc8h4kmvrssdc2w82v9ksw0r82a99av", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "466", "address": "bostrom17ssaukj47urfj6c8cgywyz9xhgqz3tnpy7n5kv", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "467", "address": "bostrom1znt56em2psvx8ylfpplcmpy5esrea08g2psvxm", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "468", "address": "bostrom1tz4yrvqlw87e74n783n0da4pttay2ypsfq6668", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "469", "address": "bostrom1prrtyfgrw2tzj9kua5eu7tnctt474m36eygux2", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "470", "address": "bostrom1ftkw5j528j94cajk4rvqum3k7mhhmpvyc8k7yg", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "471", "address": "bostrom1pe42d4gkg7smf9na6dvh5twq9hgczsag4elx84", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "472", "address": "bostrom1nscf69wvc0wkgqm8ma79qv8cr6j6zq3dt0t898", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "473", "address": "bostrom1exv982mrkyfd967xv7fam7lq8h3ce3dvcnd4s3", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "474", "address": "bostrom14q65nd2ft893dagpln4fq39wutv2xmpe3kc4w0", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "475", "address": "bostrom17llhhwjmglhhqumz72e4jap5cj39r8rwar7zzv", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "476", "address": "bostrom15k9z24v0thrxffetjp97493ec89zlz7re07pjj", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "477", "address": "bostrom1y795vkzvczrauey63vmvvcjr84l3fjheqd8f38", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "478", "address": "bostrom1qf560sekun7kjsu4r0puey5u4fn90025f4q2p2", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "479", "address": "bostrom1v9p7ukxpw2yjk7eqm8720vkgqq5qlk7w3jqgzu", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "480", "address": "bostrom1a57rc9cnhdn4l843ca4990aqldh5wmq0uuetzg", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "481", "address": "bostrom1q2ajajyu0t544tudcnvk7xcznerhylz36p5vtc", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "482", "address": "bostrom1ayc0pueqve9a3xjpgwh3p4l6hjlyvfpvclvldm", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "483", "address": "bostrom1jmdtfuxag0deeuyxmj4ge2mqhvc200hlmzyztf", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "484", "address": "bostrom1k24kf4reet2lstvmkx9a4j0r87xfuqeqh2lprz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "485", "address": "bostrom1e0c3ehnfzvcxvwh9fgzyfc2vqshy9w53du7hnv", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "486", "address": "bostrom178nsekn4qcdkqqmv95qlmp68kaqpga3zpsdnf4", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "487", "address": "bostrom13uz23f4stcg8esqvvc7d2w9psxv0dya5xaq5ne", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "488", "address": "bostrom19trgcp8uldtc5xtnpf0u7x7dk3t3jcp4y7cusm", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "489", "address": "bostrom1fn4ep44ud3edyh304ta38f55xd6pxswsw9e23z", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "490", "address": "bostrom143dfs4ur5gjvwgx8l54jjz27rq57us0zz3hqj0", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "491", "address": "bostrom1e3je4h3vkxywt2sf7mudelhf6zrx405yfgczkf", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "492", "address": "bostrom180upuj8yp0326px2uys9r60xrlhpsa6fwryf80", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "493", "address": "bostrom1jdypscylf6hjlrlva03tx5vqqkcdnllg6rpza7", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "494", "address": "bostrom1r85972mwrka5w9ct6km58ww9jl9sh46fx559fu", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "495", "address": "bostrom1xz2dkqrnrvq0ezc0vxtcvhwy39xr63vxzfedsr", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "496", "address": "bostrom134llrhdus60n7853fn3ulmx6uy7evsx3ltzstt", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "497", "address": "bostrom1pv5clfxxfpqvuerquue2vgr2ndgh0h50jx898c", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "498", "address": "bostrom107v45crxqedhmf4yqa9y98v99wm2078fwtklsq", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "499", "address": "bostrom1959r3zp37k9yuz8kjtc4feayyfkkxpcv43mu0w", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "500", "address": "bostrom1qh6eavdzp5ffks2rvd5mjt3rdmjxg3qm5l4pw2", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "501", "address": "bostrom1lk7m28npegzy0sz5s06sy95n27yzrj4d3rytdg", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "502", "address": "bostrom1clk49u6rvv8c40udn9qgp0s8hv5uvfcgxqptky", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "503", "address": "bostrom1gws6ulm3u23txc6p8kv6ew6e2zn45udrwjkdqm", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "504", "address": "bostrom17rg7cldfsqfmv53n6r7qmjmcge7ucxx2hhum0q", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "505", "address": "bostrom1kkwwsk0v4h7tmccr4sdmpyl2j2gvfah6jzw7n8", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "506", "address": "bostrom1ggh3zff5paq5c3r2j34mquq9lrcc7s0nvfnuwz", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "507", "address": "bostrom1gp5s4tetnk7ng49g58uhn2znfpmgs4cfdq4ns3", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "508", "address": "bostrom1ejkkddkuw63zn557l0lvqq3gmjcra53ealmy2x", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "509", "address": "bostrom1jrp04lvvpzkyylr4l7e5xp256l9yd4hdhrpmls", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "510", "address": "bostrom14c8rllqzmgyrkt8aeyanprl7g3adrlc2flq57a", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "511", "address": "bostrom1j39uxls4clq76ej7mk2tdskvql2tdp2zek8g89", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "512", "address": "bostrom1qcy673rd8a27t48ry6evmv6as7fuetd8cyhnjn", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "513", "address": "bostrom12d3klseftxsfs5xmvjju339enk8xcvg5y55qvl", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "514", "address": "bostrom148g7gmqvw5gfj7dmpjymtsw3j7gvasflqrsyx5", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "515", "address": "bostrom1eur22ds9gn06lgg9j3raqlzj8j2qzxx6vuje4x", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "516", "address": "bostrom1809klqrjjrs8ch2gtf5hmmfhysspkrr894rmhm", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "517", "address": "bostrom1f9nx8jrlx9pvns70edanu37mxtm359k606qyds", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "518", "address": "bostrom1qgkdm2asr0qey7jafqyqlnarvgndjws23fpkrh", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "519", "address": "bostrom1r5gvlzt03a0a9rks3s57cppmfqx2lzjrquh3d0", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "520", "address": "bostrom1yaastlp99jvqta2x5fngdzw6zur7khctd9gk3x", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "521", "address": "bostrom14jhjmhm2xmx6wyefju30auqvrs35hmnn2m8ewl", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "522", "address": "bostrom10pqp6py9pqtagyde9tnkkvakg3gqsnq7lgzxnp", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "523", "address": "bostrom1spndx95pckqnmjss6emff6fyylasg66qzdfv6v", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "524", "address": "bostrom17qkfq2uwags5pzplrfqg2elhn9s0pfwja4mgeu", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "525", "address": "bostrom194097avwy9a6h0cvznev232z28h96rp2q3w3uc", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "526", "address": "bostrom1l8hx9jxul439uyjve4zn45nujtx9gmrw3za3vs", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "527", "address": "bostrom12zmexhujvw7j82la9uslzfl5g29erpysqt555s", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "528", "address": "bostrom12vexhfe4m9p9szsqvzsalssf8sxluj6pqx8gr3", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "529", "address": "bostrom1ukgaegxryydqckt6fgrt60dajxq758x9pntmhh", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "530", "address": "bostrom1756xr3jtsdve6vuwqgqdtmt6ws3td49gq7vc77", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "531", "address": "bostrom1fn5cutfgat9s9z6nz5ucnnq9aec82wvqpevsn5", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "532", "address": "bostrom1e63p9zdn5xks5ge9gj2y9gfkl5u0jgkvfrnhzl", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "533", "address": "bostrom1zq9f4eczclr5cexrxdusfxxr6eumn2rlg2h4hs", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "534", "address": "bostrom1sjtl9n7fqszta6p4w5y5yl7d4xqth26d8z2gjj", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "535", "address": "bostrom1a4krl6m7jg7ckczk94hh0wdlcezvpgwcwkrpcg", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "536", "address": "bostrom17lzmvgnahdncwnsx3dr7mss65qv6l9md2hy2qq", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "537", "address": "bostrom1pljwxmmkhfrkzkdpmdjv29t6959sa77mjt0xz4", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "538", "address": "bostrom1t9xfg2kurjlvnw86repcpte3shpgasdjge6a7t", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "539", "address": "bostrom1erxn6kmz3xhfrv40m7lyp88v43qahqn8fy2xhn", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "540", "address": "bostrom1k879z65mwwwu4jause7galz0hlsqqj4rtah7r6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "541", "address": "bostrom16dsvdl4jer9jyplelgz4x68hjvg5k647nrnc8z", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "542", "address": "bostrom12pafl09rqzcw7d77qs63pg2nlsgvc3dsfxyzum", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "543", "address": "bostrom15cq4l7d6v43rtv493cps3c7tpsf26d83pseqwn", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "544", "address": "bostrom1wrtzl04mxs2en94ysc5p8mvqc5p0culr9w9m0n", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "545", "address": "bostrom1a2zr8qx60sl3srh982hjduse0l7pdcnhtl7juy", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "546", "address": "bostrom1r82whjffalh2hgmrayywc9g53es96n9e9893yv", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "547", "address": "bostrom15884n6qmrwq8gjuwtqh6q8z7vx500n5s3djcv6", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "548", "address": "bostrom1nhkl9r84zjucmjswhddwq8zgpun5yks5mjk7xc", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "549", "address": "bostrom12cq4xxcr6pmjz320aj7j8pn9l8vjeed63slcz5", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "550", "address": "bostrom1fwx3u5w8qyzp8msv2n9umajgst86dnuqrsft0g", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "551", "address": "bostrom1zg3xqymyrvlu5fmmyx8htdm84kqt50t7xdfmuj", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "552", "address": "bostrom152xtf7tvw60tyhls32wwc9ypehqzf366zjkeeg", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "553", "address": "bostrom1uspnj6pvq0u78d8qux8lz6p24dzm998phldqgv", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "554", "address": "bostrom1ppzvqc7yf9lfs8cljqu6w992gct6d5h9jx5wsn", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "555", "address": "bostrom1jn8cp663fl0mv6k55xvy2lr6s0r57zg0v6gzr3", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "556", "address": "bostrom1fmpuldfmgj0a4dlkn0cdlap4h3qs7nljyph4rj", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "557", "address": "bostrom10mja0qpcq6ze2nrchhh7w3n7g589sdktfu7p9m", "pub_key": null, "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "account_number": "558", "address": "bostrom1kaaxhzud2ev7v69kwkf8vuvhst9a36wz5l424q", "pub_key": null, "sequence": "0" } ] }, "authz": { "authorization": [] }, "bandwidth": { "params": { "recovery_period": "16000", "adjust_price_period": "5", "base_price": "0.250000000000000000", "max_block_bandwidth": "25000", "base_load": "0.100000000000000000" } }, "bank": { "params": { "send_enabled": [], "default_send_enabled": true }, "balances": [ { "address": "bostrom1xszmhkfjs3s00z2nvtn7evqxw3dtus6yr8e4pw", "coins": [ { "amount": "115880796057845", "denom": "boot" }, { "amount": "115880796057845", "denom": "tocyb" } ] }, { "address": "bostrom16230lc9r27vrxlzd4wlvcz2l66quzj84vlkxc5", "coins": [ { "amount": "10000000000000", "denom": "boot" }, { "amount": "10000000000000", "denom": "tocyb" } ] }, { "address": "bostrom1gxhs5wzam5rlgf6cs0lkme400ut64d4ncpfs2h", "coins": [ { "amount": "10000000000000", "denom": "boot" }, { "amount": "10000000000000", "denom": "tocyb" } ] }, { "address": "bostrom1qs9w7ry45axfxjgxa4jmuhjthzfvj78sxh5p6e", "coins": [ { "amount": "700000000000000", "denom": "boot" }, { "amount": "700000000000000", "denom": "tocyb" } ] }, { "address": "bostrom1ha4pw9w2qgc2ce9jwfrwrmaft5fneus58nqwev", "coins": [ { "amount": "50000000000000", "denom": "boot" }, { "amount": "50000000000000", "denom": "tocyb" } ] }, { "address": "bostrom1qn8sr2hzmktlecusdtxj9hwj0upnm0jft9snar", "coins": [ { "amount": "10152301267211", "denom": "boot" }, { "amount": "10152301267211", "denom": "tocyb" } ] }, { "address": "bostrom1d8754xqa9245pctlfcyv8eah468neqzn3a0y0t", "coins": [ { "amount": "360239818444", "denom": "boot" }, { "amount": "360239818444", "denom": "tocyb" } ] }, { "address": "bostrom1ttd4h585vgy29gj0xe0p338drvw9w4m4hzwj9p", "coins": [ { "amount": "4000000000000", "denom": "boot" }, { "amount": "4000000000000", "denom": "tocyb" } ] }, { "address": "bostrom1ngd5w7j4u5ar5xh7vzuwqqznnhhcjmnz0s6kpu", "coins": [ { "amount": "1000000000000", "denom": "boot" }, { "amount": "1000000000000", "denom": "tocyb" } ] }, { "address": "bostrom10c8znaj94y900syues06dz50hw6y9qpkhunn25", "coins": [ { "amount": "1400000000000", "denom": "boot" }, { "amount": "1400000000000", "denom": "tocyb" } ] }, { "address": "bostrom1jv65s3grqf6v6jl3dp4t6c9t9rk99cd8yvs0hc", "coins": [ { "amount": "50726497621325", "denom": "boot" }, { "amount": "50726497621325", "denom": "tocyb" } ] }, { "address": "bostrom1pntx8ql2v7cqxu05etg8c4v0r2vz7qnq9uqmpy", "coins": [ { "amount": "4000000000000", "denom": "boot" }, { "amount": "4000000000000", "denom": "tocyb" } ] }, { "address": "bostrom17a7xxqa4drnalvv7pkxrkxqer953fdke3ulwx4", "coins": [ { "amount": "1000000000000", "denom": "boot" }, { "amount": "1000000000000", "denom": "tocyb" } ] }, { "address": "bostrom1s4czxghmh29aw2ldynk8r9lnkfccw5ph8rjpxa", "coins": [ { "amount": "4000000000000", "denom": "boot" }, { "amount": "4000000000000", "denom": "tocyb" } ] }, { "address": "bostrom1s4wntr9selfaznc2ezjkwnwt2y0terx9tqpda3", "coins": [ { "amount": "1000000000000", "denom": "boot" }, { "amount": "1000000000000", "denom": "tocyb" } ] }, { "address": "bostrom1qwzsnnuk2u6avvh059c9p50gqqquvcu5svvwrs", "coins": [ { "amount": "4000000000000", "denom": "boot" }, { "amount": "4000000000000", "denom": "tocyb" } ] }, { "address": "bostrom1g07gj9ph0r2hjx6ffqn8vl38u4agd5mpqx9m7f", "coins": [ { "amount": "4000000000000", "denom": "boot" }, { "amount": "4000000000000", "denom": "tocyb" } ] }, { "address": "bostrom10e3rqclgjz4m4fnx2c23jupcjpyuvyx3x4k7qj", "coins": [ { "amount": "1000000000000", "denom": "boot" }, { "amount": "1000000000000", "denom": "tocyb" } ] }, { "address": "bostrom1t3222ju7ssu58xsm3m2xw445p94cqn2qrex3vy", "coins": [ { "amount": "2000000000000", "denom": "boot" }, { "amount": "2000000000000", "denom": "tocyb" } ] }, { "address": "bostrom1edlrze5f48jjaw0wxcve4asqqf2tcjdl59ln8q", "coins": [ { "amount": "2000000000000", "denom": "boot" }, { "amount": "2000000000000", "denom": "tocyb" } ] }, { "address": "bostrom1m8yf3g2m9p7danjvt4ga6vzewy380pk52kcu9z", "coins": [ { "amount": "4000000000000", "denom": "boot" }, { "amount": "4000000000000", "denom": "tocyb" } ] }, { "address": "bostrom1fe5mspz9jsq6p9hqqet86dwp276635l6gacspa", "coins": [ { "amount": "1000200000000", "denom": "boot" }, { "amount": "1000200000000", "denom": "tocyb" } ] }, { "address": "bostrom14nzyt8wmx4g6zkeluelukamgsh5v4xgnc25k6j", "coins": [ { "amount": "508729659282", "denom": "boot" }, { "amount": "508729659282", "denom": "tocyb" } ] }, { "address": "bostrom1mcslqq8ghtuf6xu987qtk64shy6rd86a2xtwu8", "coins": [ { "amount": "400000000000", "denom": "boot" }, { "amount": "400000000000", "denom": "tocyb" } ] }, { "address": "bostrom1sng0f47cuvx6edxaujh24wc3dvk94q0w6r6smh", "coins": [ { "amount": "474221734944", "denom": "boot" }, { "amount": "474221734944", "denom": "tocyb" } ] }, { "address": "bostrom194pp2whvqynxnfyw5tqy8fzy2kxsugyrwsaynk", "coins": [ { "amount": "1000000000000", "denom": "boot" }, { "amount": "1000000000000", "denom": "tocyb" } ] }, { "address": "bostrom14d92r4svhl4qa3g6q48tjekarw2kt67ngqn4lr", "coins": [ { "amount": "40000000000", "denom": "boot" }, { "amount": "40000000000", "denom": "tocyb" } ] }, { "address": "bostrom1hmkqhy8ygl6tnl5g8tc503rwrmmrkjcq3lduwj", "coins": [ { "amount": "386336649906", "denom": "boot" }, { "amount": "386336649906", "denom": "tocyb" } ] }, { "address": "bostrom12psudf4rpaw4jwhuyx3y8sejhsynae7gv53hn6", "coins": [ { "amount": "320106862931", "denom": "boot" }, { "amount": "320106862931", "denom": "tocyb" } ] }, { "address": "bostrom178q202gz0093uke0jy96psyya452rt8apl4has", "coins": [ { "amount": "285239999451", "denom": "boot" }, { "amount": "285239999451", "denom": "tocyb" } ] }, { "address": "bostrom1kr6udadsvdjymq6m75un4khg27t25st2jn8sag", "coins": [ { "amount": "255496772589", "denom": "boot" }, { "amount": "255496772589", "denom": "tocyb" } ] }, { "address": "bostrom1ymprf45c44rp9k0g2r84w2tjhsq7kalv98rgpt", "coins": [ { "amount": "369099401568", "denom": "boot" }, { "amount": "369099401568", "denom": "tocyb" } ] }, { "address": "bostrom1w8ap0ns4d5fagjfwvph6t99uet0cwv6y6r03un", "coins": [ { "amount": "200997782490", "denom": "boot" }, { "amount": "200997782490", "denom": "tocyb" } ] }, { "address": "bostrom1svm5wl5jf4p7dwemj7wh0p4egr3js6rqtlnefu", "coins": [ { "amount": "197153970492", "denom": "boot" }, { "amount": "197153970492", "denom": "tocyb" } ] }, { "address": "bostrom1gnnd2eaeqpp6lsd34tnp6j0m85h6r9qg0wh3vr", "coins": [ { "amount": "194917719034", "denom": "boot" }, { "amount": "194917719034", "denom": "tocyb" } ] }, { "address": "bostrom1t0hmc79ht0qja92p6qgxn3ee3a3rzqutv7thqn", "coins": [ { "amount": "188630461585", "denom": "boot" }, { "amount": "188630461585", "denom": "tocyb" } ] }, { "address": "bostrom12q68xfj4r00nxnjrqk742rf0z2w6jmwaeppvr0", "coins": [ { "amount": "183750995527", "denom": "boot" }, { "amount": "183750995527", "denom": "tocyb" } ] }, { "address": "bostrom1ggc9sqvj0uhnzwxu5dyzcr05shwd2vv2guqmas", "coins": [ { "amount": "188148534837", "denom": "boot" }, { "amount": "188148534837", "denom": "tocyb" } ] }, { "address": "bostrom177y7sqkxmvl22j632haf8y9gv0j3wedssq5m50", "coins": [ { "amount": "227878425830", "denom": "boot" }, { "amount": "227878425830", "denom": "tocyb" } ] }, { "address": "bostrom1zhy7l8phhpsm2c6xl9c5arcu0z90clynluwrw5", "coins": [ { "amount": "161481707259", "denom": "boot" }, { "amount": "161481707259", "denom": "tocyb" } ] }, { "address": "bostrom1k60sfzh3ecyqfv36f7zav0089077e4zk4g6mxa", "coins": [ { "amount": "146840247453", "denom": "boot" }, { "amount": "146840247453", "denom": "tocyb" } ] }, { "address": "bostrom1kpep8dl93ud4wgpws3tcew6as2s36c9v3csw89", "coins": [ { "amount": "140997260087", "denom": "boot" }, { "amount": "140997260087", "denom": "tocyb" } ] }, { "address": "bostrom16lvsv3w7rnhcm079v6j9eah3xd0p3pd37hl48j", "coins": [ { "amount": "122742180846", "denom": "boot" }, { "amount": "122742180846", "denom": "tocyb" } ] }, { "address": "bostrom1mnrwpdlnglhtqwa55fa66va0j3fv72nvkz4e2x", "coins": [ { "amount": "114829832854", "denom": "boot" }, { "amount": "114829832854", "denom": "tocyb" } ] }, { "address": "bostrom1dt9lwmuq8rkngm5gajxchqhpcnavgp7md9v929", "coins": [ { "amount": "115117293353", "denom": "boot" }, { "amount": "115117293353", "denom": "tocyb" } ] }, { "address": "bostrom12xsg4qm4k5z48s79zdsz84jlhv56kmta3vyfvl", "coins": [ { "amount": "74772629353", "denom": "boot" }, { "amount": "74772629353", "denom": "tocyb" } ] }, { "address": "bostrom1dxpm2ne0jflzr2hy9j5has6u2dvfv68calunqy", "coins": [ { "amount": "99815252312", "denom": "boot" }, { "amount": "99815252312", "denom": "tocyb" } ] }, { "address": "bostrom1my32szlwazg9x56xqvsvtp0hqvpzm0r4u3k4ae", "coins": [ { "amount": "70271964895", "denom": "boot" }, { "amount": "70271964895", "denom": "tocyb" } ] }, { "address": "bostrom1g0ap9fvex93yzzj69uzl74942vjvq8e4f8xtyr", "coins": [ { "amount": "67992083477", "denom": "boot" }, { "amount": "67992083477", "denom": "tocyb" } ] }, { "address": "bostrom16zms8r32vad3z8hl2vc6wrcnanwmxf0dgh25yp", "coins": [ { "amount": "67229160818", "denom": "boot" }, { "amount": "67229160818", "denom": "tocyb" } ] }, { "address": "bostrom1d3zlsrjyl3tzp3aly7vjduhrtrtvkvkeaqpdku", "coins": [ { "amount": "63422106566", "denom": "boot" }, { "amount": "63422106566", "denom": "tocyb" } ] }, { "address": "bostrom18jwk949jqgq3j2du2dgscqxqkkqw5rsjfuucf3", "coins": [ { "amount": "61558395847", "denom": "boot" }, { "amount": "61558395847", "denom": "tocyb" } ] }, { "address": "bostrom13fwhvawke6867s6raqux25fd24t89j5h8wf2v0", "coins": [ { "amount": "60883067675", "denom": "boot" }, { "amount": "60883067675", "denom": "tocyb" } ] }, { "address": "bostrom18z9vsjffvggluxcxfqwsmrz02v37hx2e3auyn2", "coins": [ { "amount": "63671664821", "denom": "boot" }, { "amount": "63671664821", "denom": "tocyb" } ] }, { "address": "bostrom1lnkg57t7mvg5mcl7kdkevtgr9wlf6f9qtp86sk", "coins": [ { "amount": "70907190105", "denom": "boot" }, { "amount": "70907190105", "denom": "tocyb" } ] }, { "address": "bostrom1dl5df5g2xwj02e93k547etw2ergvc3a20v5ekz", "coins": [ { "amount": "46480474242", "denom": "boot" }, { "amount": "46480474242", "denom": "tocyb" } ] }, { "address": "bostrom13ume6mqte5h9ngx2hh6ngc8aham7x0k6stuvkm", "coins": [ { "amount": "41813199988", "denom": "boot" }, { "amount": "41813199988", "denom": "tocyb" } ] }, { "address": "bostrom1ldjugf3uj2gwkmmsf5japfknf96zv6hw7xw7v4", "coins": [ { "amount": "43229857071", "denom": "boot" }, { "amount": "43229857071", "denom": "tocyb" } ] }, { "address": "bostrom1y9zkl7uqjev899swng4eqfuurwaxpchwppewyc", "coins": [ { "amount": "40330418998", "denom": "boot" }, { "amount": "40330418998", "denom": "tocyb" } ] }, { "address": "bostrom16lf2hvzy4n4gvtx37pgkkdw2e2psfjjdpej53p", "coins": [ { "amount": "37988147654", "denom": "boot" }, { "amount": "37988147654", "denom": "tocyb" } ] }, { "address": "bostrom15zs0cjct43xs4z4sesxcrynar5mxm82f0ykhl3", "coins": [ { "amount": "111131994342", "denom": "boot" }, { "amount": "111131994342", "denom": "tocyb" } ] }, { "address": "bostrom1v5jqg6k7mszmchhz8kyfml5h4e2txct9jz3am4", "coins": [ { "amount": "37418729590", "denom": "boot" }, { "amount": "37418729590", "denom": "tocyb" } ] }, { "address": "bostrom19ys53t55r725j882gjcrnf7s449gdrds3h2hu4", "coins": [ { "amount": "38253993813", "denom": "boot" }, { "amount": "38253993813", "denom": "tocyb" } ] }, { "address": "bostrom1en69twaxmv7xupy8lq7y539dpecx7yz8g0k8ft", "coins": [ { "amount": "88440007493", "denom": "boot" }, { "amount": "88440007493", "denom": "tocyb" } ] }, { "address": "bostrom1kgq82m6z2jttytv7fvwy2rklhq5k03gc2h9sej", "coins": [ { "amount": "30494554808", "denom": "boot" }, { "amount": "30494554808", "denom": "tocyb" } ] }, { "address": "bostrom1hvk6s053m6qdlz9kwllgldwf4qp2c3mrlh9s2q", "coins": [ { "amount": "29370149824", "denom": "boot" }, { "amount": "29370149824", "denom": "tocyb" } ] }, { "address": "bostrom1ch6nukdgj55c9sk4h5t8spzhahuuvn86gqvarm", "coins": [ { "amount": "27485323135", "denom": "boot" }, { "amount": "27485323135", "denom": "tocyb" } ] }, { "address": "bostrom1rqudjcrdwqedffxufmqgsleuguhm7pkaq0alce", "coins": [ { "amount": "27363284437", "denom": "boot" }, { "amount": "27363284437", "denom": "tocyb" } ] }, { "address": "bostrom1qgqkc9t3pfsp6yxjwds70e4r9y0p6resmfnymc", "coins": [ { "amount": "26376882296", "denom": "boot" }, { "amount": "26376882296", "denom": "tocyb" } ] }, { "address": "bostrom12kd8w45rqxuwpwqvpmdyvvdey9ezeqhav4nn85", "coins": [ { "amount": "26208333897", "denom": "boot" }, { "amount": "26208333897", "denom": "tocyb" } ] }, { "address": "bostrom152kqs8p7d3jy6kn4uk87ve3alkuqjgewt3cmvz", "coins": [ { "amount": "28921406054", "denom": "boot" }, { "amount": "28921406054", "denom": "tocyb" } ] }, { "address": "bostrom1dn09uyhwmv3ratntc7c603vczgrec32c2fylpj", "coins": [ { "amount": "24175157388", "denom": "boot" }, { "amount": "24175157388", "denom": "tocyb" } ] }, { "address": "bostrom1qezgmksavgdvcvf9ckhazfy3jfw8whhzfrvtlz", "coins": [ { "amount": "21979059507", "denom": "boot" }, { "amount": "21979059507", "denom": "tocyb" } ] }, { "address": "bostrom1d552nfgekkugdgxw3zl242qpxapl67jfkz76tp", "coins": [ { "amount": "21555502893", "denom": "boot" }, { "amount": "21555502893", "denom": "tocyb" } ] }, { "address": "bostrom10vpygn9ftv85ra7j7qpewuq5jdgvpjmehlds0g", "coins": [ { "amount": "20335729382", "denom": "boot" }, { "amount": "20335729382", "denom": "tocyb" } ] }, { "address": "bostrom18naxcfp2s397a2ucav2m53f003uylk3qz9fvr7", "coins": [ { "amount": "95514429798", "denom": "boot" }, { "amount": "95514429798", "denom": "tocyb" } ] }, { "address": "bostrom18t3kx877vyvstcvn50cgn5w6hppe8ce0pq72m2", "coins": [ { "amount": "18546327724", "denom": "boot" }, { "amount": "18546327724", "denom": "tocyb" } ] }, { "address": "bostrom1kfqv2fzzu6dgwnf6snql2jslwdws07fl2gz37u", "coins": [ { "amount": "17879700159", "denom": "boot" }, { "amount": "17879700159", "denom": "tocyb" } ] }, { "address": "bostrom1ggayl03vvv763az6eez66jzwuunyqkcusk8fwj", "coins": [ { "amount": "17754934798", "denom": "boot" }, { "amount": "17754934798", "denom": "tocyb" } ] }, { "address": "bostrom1fjeq0urgk4x0s6pl2p2fes8c95426amp7lv4dv", "coins": [ { "amount": "17601345097", "denom": "boot" }, { "amount": "17601345097", "denom": "tocyb" } ] }, { "address": "bostrom1jgh7ghrcr47tuahawzvg3svv2hxkxfx5u9lzr2", "coins": [ { "amount": "17333444802", "denom": "boot" }, { "amount": "17333444802", "denom": "tocyb" } ] }, { "address": "bostrom19y467lyhqlpa52y6snq9cxw47xhwq0th3p05r0", "coins": [ { "amount": "14256149914", "denom": "boot" }, { "amount": "14256149914", "denom": "tocyb" } ] }, { "address": "bostrom16ge9uqpqf78jdt0uz58ycalhtg59w77qm9t7d2", "coins": [ { "amount": "14222312706", "denom": "boot" }, { "amount": "14222312706", "denom": "tocyb" } ] }, { "address": "bostrom1463la66ac89tmlwgvx20c4d2jv84ekzs8kzh87", "coins": [ { "amount": "13368713572", "denom": "boot" }, { "amount": "13368713572", "denom": "tocyb" } ] }, { "address": "bostrom164k2s2s2td6a30d3rvnv93scy3v29psw4j3ndm", "coins": [ { "amount": "12701785716", "denom": "boot" }, { "amount": "12701785716", "denom": "tocyb" } ] }, { "address": "bostrom1rya5547x4lrwc2npd63s89ny2dvhamv9dfx9x9", "coins": [ { "amount": "12090950492", "denom": "boot" }, { "amount": "12090950492", "denom": "tocyb" } ] }, { "address": "bostrom18wn5kyxewwk6qh97493xtj9gufpmqserfahc37", "coins": [ { "amount": "12063356572", "denom": "boot" }, { "amount": "12063356572", "denom": "tocyb" } ] }, { "address": "bostrom1lljcf37yxh24l3v4kwqsyghwz4ywlg6urg4kte", "coins": [ { "amount": "13616553392", "denom": "boot" }, { "amount": "13616553392", "denom": "tocyb" } ] }, { "address": "bostrom1d7n8znqg635yxnzlsycnt6kut8z5du5yftutrf", "coins": [ { "amount": "10958899451", "denom": "boot" }, { "amount": "10958899451", "denom": "tocyb" } ] }, { "address": "bostrom16pdckvu70ufzvm8avd9anga6k35nu7axym02wp", "coins": [ { "amount": "9792986284", "denom": "boot" }, { "amount": "9792986284", "denom": "tocyb" } ] }, { "address": "bostrom18txzlmkqf264a2awhey6lmeq0dtv5ex69d2fcy", "coins": [ { "amount": "9333557553", "denom": "boot" }, { "amount": "9333557553", "denom": "tocyb" } ] }, { "address": "bostrom1mmtt0cnsgwx3t90vs4tn9k08kw8xn4v3pggfu7", "coins": [ { "amount": "6701991111", "denom": "boot" }, { "amount": "6701991111", "denom": "tocyb" } ] }, { "address": "bostrom1mryr27k3h8kqr5ahj82v0ym2xexdewfc9rmng8", "coins": [ { "amount": "6310270182", "denom": "boot" }, { "amount": "6310270182", "denom": "tocyb" } ] }, { "address": "bostrom1gg73t0eyrkqf953waqxh6uqah62p46jyg82ulr", "coins": [ { "amount": "5787292447", "denom": "boot" }, { "amount": "5787292447", "denom": "tocyb" } ] }, { "address": "bostrom1jx0az02ccnt4mgj2r9vhvycsdjsztrrgdkwzr3", "coins": [ { "amount": "4220671315", "denom": "boot" }, { "amount": "4220671315", "denom": "tocyb" } ] }, { "address": "bostrom1r90j4656xsug2hkj57a3knqcs9huh3ea88ykhp", "coins": [ { "amount": "3475567070", "denom": "boot" }, { "amount": "3475567070", "denom": "tocyb" } ] }, { "address": "bostrom1f7nx65pmayfenpfwzwaamwas4ygmvalq2q2ayq", "coins": [ { "amount": "73338027208", "denom": "boot" }, { "amount": "73338027208", "denom": "tocyb" } ] }, { "address": "bostrom1zl0t5703q42qx7drxsgl9thjwlul5x6unjhwgn", "coins": [ { "amount": "2742969308", "denom": "boot" }, { "amount": "2742969308", "denom": "tocyb" } ] }, { "address": "bostrom13q0m4hw6pmajqdqn4g464vzmst78sf55ktrp05", "coins": [ { "amount": "2064986311", "denom": "boot" }, { "amount": "2064986311", "denom": "tocyb" } ] }, { "address": "bostrom1cjyv02cja896rr5y5lks79enk2nretn3mqyc69", "coins": [ { "amount": "13447758288", "denom": "boot" }, { "amount": "13447758288", "denom": "tocyb" } ] }, { "address": "bostrom16qu2ymnzzjn05xc6yszjy50caaahcahdvmex5e", "coins": [ { "amount": "1362390306", "denom": "boot" }, { "amount": "1362390306", "denom": "tocyb" } ] }, { "address": "bostrom1jst67u54vquzvun3dawpmpwyx5ar8mayaak5j7", "coins": [ { "amount": "181160067", "denom": "boot" }, { "amount": "181160067", "denom": "tocyb" } ] }, { "address": "bostrom16s7gwc944patdynnfnvac0jh5u76wsnflty377", "coins": [ { "amount": "77674844", "denom": "boot" }, { "amount": "77674844", "denom": "tocyb" } ] }, { "address": "bostrom1s3lgc3mgy4ltwr796qk6j73xmau4njueds0mgu", "coins": [ { "amount": "1340337491769", "denom": "boot" }, { "amount": "1340337491769", "denom": "tocyb" } ] }, { "address": "bostrom10556xtnp39nvx3ec3yjafug662pyt6af84n477", "coins": [ { "amount": "1304153455839", "denom": "boot" }, { "amount": "1304153455839", "denom": "tocyb" } ] }, { "address": "bostrom1ffve0zx389ffl80ae9t8jmghcjuzdlqr5eayfd", "coins": [ { "amount": "701778551659", "denom": "boot" }, { "amount": "701778551659", "denom": "tocyb" } ] }, { "address": "bostrom1ftah3e558ww7xutn5w8h7vrqa9v69pntztnr3p", "coins": [ { "amount": "622444466499", "denom": "boot" }, { "amount": "622444466499", "denom": "tocyb" } ] }, { "address": "bostrom1wnpak7sfawsfv9c8vqe7naxfa4g99lv77d7c0z", "coins": [ { "amount": "517421971282", "denom": "boot" }, { "amount": "517421971282", "denom": "tocyb" } ] }, { "address": "bostrom1sgy27lctdrc5egpvc8f02rgzml6hmmvh5wu6xk", "coins": [ { "amount": "359172486938", "denom": "boot" }, { "amount": "359172486938", "denom": "tocyb" } ] }, { "address": "bostrom1cg79pj70mgl8xlum0rw5yy6enk9jszsrzvwysn", "coins": [ { "amount": "279430823965", "denom": "boot" }, { "amount": "279430823965", "denom": "tocyb" } ] }, { "address": "bostrom13dpy00jest96g7h5vdgvg9zpxq6xnclh5hzw5l", "coins": [ { "amount": "258229369437", "denom": "boot" }, { "amount": "258229369437", "denom": "tocyb" } ] }, { "address": "bostrom1mdq5r6az6z8su68zj6px88j2ukr78ea4ggkzt6", "coins": [ { "amount": "237448433882", "denom": "boot" }, { "amount": "237448433882", "denom": "tocyb" } ] }, { "address": "bostrom1lepnu7nt05g79jtmfp2pgrpys3fjc4p74sc0l2", "coins": [ { "amount": "182911039870", "denom": "boot" }, { "amount": "182911039870", "denom": "tocyb" } ] }, { "address": "bostrom1d5lu67hu3lhqtw6zyv7uy4gkfpdtfnzxdu6mrq", "coins": [ { "amount": "157995617348", "denom": "boot" }, { "amount": "157995617348", "denom": "tocyb" } ] }, { "address": "bostrom16jttzjgks48kqrhk5e68yv0gv6dt0rpw2f5pwn", "coins": [ { "amount": "141302079887", "denom": "boot" }, { "amount": "141302079887", "denom": "tocyb" } ] }, { "address": "bostrom1e20hw2pqcgxvumkwn2qeeavcrswzskzjhr2aq0", "coins": [ { "amount": "119454359990", "denom": "boot" }, { "amount": "119454359990", "denom": "tocyb" } ] }, { "address": "bostrom17z2fywzrdld7qmwzpsq0atxfwcns8rp833rgxy", "coins": [ { "amount": "95223358775", "denom": "boot" }, { "amount": "95223358775", "denom": "tocyb" } ] }, { "address": "bostrom1tu0e0ggvjtv4gvzcranjnrykac0umnf8y8fm0r", "coins": [ { "amount": "92010985676", "denom": "boot" }, { "amount": "92010985676", "denom": "tocyb" } ] }, { "address": "bostrom1sltcfypwms38jjj3g38rg7ldx3e6uqrzrnkf9y", "coins": [ { "amount": "91965450766", "denom": "boot" }, { "amount": "91965450766", "denom": "tocyb" } ] }, { "address": "bostrom1zy553za8nenzukmv65240323jhuvxzym4pl6w9", "coins": [ { "amount": "154293211852", "denom": "boot" }, { "amount": "154293211852", "denom": "tocyb" } ] }, { "address": "bostrom1lpfs6xv765u4yxr8rlyn5ux0g2a8tyt90hsnas", "coins": [ { "amount": "59256843788", "denom": "boot" }, { "amount": "59256843788", "denom": "tocyb" } ] }, { "address": "bostrom1smqr5tp684g07aekcn0w852wqlme5mn6dmsny3", "coins": [ { "amount": "47098839942", "denom": "boot" }, { "amount": "47098839942", "denom": "tocyb" } ] }, { "address": "bostrom1eqkdzfcjnu20ywju35rf3nutxzjxjaqnxqfyyz", "coins": [ { "amount": "44081312892", "denom": "boot" }, { "amount": "44081312892", "denom": "tocyb" } ] }, { "address": "bostrom1waac73cpffx7suhpkvnn8w0a8s2cgzn66x2aka", "coins": [ { "amount": "42415701749", "denom": "boot" }, { "amount": "42415701749", "denom": "tocyb" } ] }, { "address": "bostrom16macu2qtc0jmqc7txvf0wkz84cycsx728ah0xc", "coins": [ { "amount": "97996176301", "denom": "boot" }, { "amount": "97996176301", "denom": "tocyb" } ] }, { "address": "bostrom1fapqgamx3c8za8d3z56sydjtjygyu0ly752j8g", "coins": [ { "amount": "37850807372", "denom": "boot" }, { "amount": "37850807372", "denom": "tocyb" } ] }, { "address": "bostrom1w4548vrnvc7t9j2ly55nvkjvhwqt9thnfcvuw6", "coins": [ { "amount": "33395512349", "denom": "boot" }, { "amount": "33395512349", "denom": "tocyb" } ] }, { "address": "bostrom133t8m00w7llsslnf05zdhehharntly8dqzpfs8", "coins": [ { "amount": "31992273571", "denom": "boot" }, { "amount": "31992273571", "denom": "tocyb" } ] }, { "address": "bostrom1smtmk8fe3qhlwj3h7nynl6p42946qydzvgj9va", "coins": [ { "amount": "29390986364", "denom": "boot" }, { "amount": "29390986364", "denom": "tocyb" } ] }, { "address": "bostrom1csf3up94qheqz88fvvlwjl7vc5sdymarktrvpw", "coins": [ { "amount": "18442151620", "denom": "boot" }, { "amount": "18442151620", "denom": "tocyb" } ] }, { "address": "bostrom1tr3eyy9l480pxjk0ygudwpfus7j8pgdljn09jm", "coins": [ { "amount": "17537519175", "denom": "boot" }, { "amount": "17537519175", "denom": "tocyb" } ] }, { "address": "bostrom16ahkkv0jzhtp73z83qlhqrypss6jpjm8eekpwv", "coins": [ { "amount": "17375703563", "denom": "boot" }, { "amount": "17375703563", "denom": "tocyb" } ] }, { "address": "bostrom1htq7u8gy9muv4fk6st04524tdzy8rv04528gys", "coins": [ { "amount": "16744189104", "denom": "boot" }, { "amount": "16744189104", "denom": "tocyb" } ] }, { "address": "bostrom1kk9clwd4eva7ww95gn4rw3xzuwfs0983sl5cwt", "coins": [ { "amount": "16191669541", "denom": "boot" }, { "amount": "16191669541", "denom": "tocyb" } ] }, { "address": "bostrom1k7cl9ya9qq30c7m4rvg3823hrc8k80eetqvhj8", "coins": [ { "amount": "14797976623", "denom": "boot" }, { "amount": "14797976623", "denom": "tocyb" } ] }, { "address": "bostrom16d69u47km5vqdvf6fr8qyhktlacgka7fdvazr8", "coins": [ { "amount": "14751375909", "denom": "boot" }, { "amount": "14751375909", "denom": "tocyb" } ] }, { "address": "bostrom1njsr8tngxtygsc73mrtn5738ztkzqy7c7y7h3t", "coins": [ { "amount": "51066633718", "denom": "boot" }, { "amount": "51066633718", "denom": "tocyb" } ] }, { "address": "bostrom1kf0d64nuwsf2zeul5wkx78fsznplnlpsfh7fqw", "coins": [ { "amount": "11673069511", "denom": "boot" }, { "amount": "11673069511", "denom": "tocyb" } ] }, { "address": "bostrom18ghjkwygsvjcsh20tc5zzhfttxxuex7a9lq8ps", "coins": [ { "amount": "9561458741", "denom": "boot" }, { "amount": "9561458741", "denom": "tocyb" } ] }, { "address": "bostrom1s2a7rckcky6jmhncxwy0xtwf2ymg87puk6jpzz", "coins": [ { "amount": "14991446142", "denom": "boot" }, { "amount": "14991446142", "denom": "tocyb" } ] }, { "address": "bostrom1679yrs8dmska7wcsawgy2m25kwucm3z0hwr74y", "coins": [ { "amount": "388969016352", "denom": "boot" }, { "amount": "388969016352", "denom": "tocyb" } ] }, { "address": "bostrom15gk8edxtvvp372flljk884fav55y8ehwru4u8w", "coins": [ { "amount": "2279889403", "denom": "boot" }, { "amount": "2279889403", "denom": "tocyb" } ] }, { "address": "bostrom1jz57cgfr248y9w6sn76l7pugjkr6e7zh6y2grp", "coins": [ { "amount": "2378739020", "denom": "boot" }, { "amount": "2378739020", "denom": "tocyb" } ] }, { "address": "bostrom1gw5kdey7fs9wdh05w66s0h4s24tjdvtc9v6vpe", "coins": [ { "amount": "1799479675", "denom": "boot" }, { "amount": "1799479675", "denom": "tocyb" } ] }, { "address": "bostrom1kajt7sxfpnfujm7ptj90654lmwz4sftpc9mp9a", "coins": [ { "amount": "1743792737", "denom": "boot" }, { "amount": "1743792737", "denom": "tocyb" } ] }, { "address": "bostrom1t575qeee3qgshuf964qal057z77vljqef9tlck", "coins": [ { "amount": "1099995800", "denom": "boot" }, { "amount": "1099995800", "denom": "tocyb" } ] }, { "address": "bostrom105zy26ze9gean4qukqlvhkv4mtcndc9t2xaydz", "coins": [ { "amount": "1006206924", "denom": "boot" }, { "amount": "1006206924", "denom": "tocyb" } ] }, { "address": "bostrom1a30w6j4m6g3s2c6zt02z56xynnuaqmn3ahwxuq", "coins": [ { "amount": "974688373", "denom": "boot" }, { "amount": "974688373", "denom": "tocyb" } ] }, { "address": "bostrom1pmaltcu0x97x8j5klc8xluaapkzcvztcn2vkmw", "coins": [ { "amount": "736741030", "denom": "boot" }, { "amount": "736741030", "denom": "tocyb" } ] }, { "address": "bostrom1n3mhyp9fvcmuu8l0q8qvjy07x0rql8q4uwev5z", "coins": [ { "amount": "704276829", "denom": "boot" }, { "amount": "704276829", "denom": "tocyb" } ] }, { "address": "bostrom1u3ap2d4ytcqrr6jlsjf380g3lvgldq4m64s7dg", "coins": [ { "amount": "675487504", "denom": "boot" }, { "amount": "675487504", "denom": "tocyb" } ] }, { "address": "bostrom1keny4peq77drtcdj6fscd9eknqcqyjmxqcr8t8", "coins": [ { "amount": "647527281", "denom": "boot" }, { "amount": "647527281", "denom": "tocyb" } ] }, { "address": "bostrom1kk79xcsuah7ckvunku78094gyh7900ehkllkur", "coins": [ { "amount": "173703544", "denom": "boot" }, { "amount": "173703544", "denom": "tocyb" } ] }, { "address": "bostrom137eezcxcyqgt6kshfdfuvnsdgwpujyje2l8qdz", "coins": [ { "amount": "73708712", "denom": "boot" }, { "amount": "73708712", "denom": "tocyb" } ] }, { "address": "bostrom1uz39kh64w8p5df034fh6g5hwpdq8m0h5rx58he", "coins": [ { "amount": "49997750", "denom": "boot" }, { "amount": "49997750", "denom": "tocyb" } ] }, { "address": "bostrom1kz6s2mp4rg7plj8p4qqe2wkegn4ldw3ak2a7qc", "coins": [ { "amount": "233827", "denom": "boot" }, { "amount": "233827", "denom": "tocyb" } ] }, { "address": "bostrom1quchyywzdxp62dq3rwan8fg35v6j58sjwnfpuu", "coins": [ { "amount": "432771825520", "denom": "boot" }, { "amount": "432771825520", "denom": "tocyb" } ] }, { "address": "bostrom1x95keq9l9y9p7hjdt6xd8wnknrpnjsqrqhpwc9", "coins": [ { "amount": "150000000000", "denom": "boot" }, { "amount": "150000000000", "denom": "tocyb" } ] }, { "address": "bostrom1z98eg2ztdp2glyla62629nrlvczg8s7fvc0znp", "coins": [ { "amount": "100000000000", "denom": "boot" }, { "amount": "100000000000", "denom": "tocyb" } ] }, { "address": "bostrom1xvssufw8ke03halg8wgu8m994ktxz0y9vm6tqn", "coins": [ { "amount": "100000000000", "denom": "boot" }, { "amount": "100000000000", "denom": "tocyb" } ] }, { "address": "bostrom1vxxfhd8txmrq76jx3gj7sdrvg0vvqret6kxpgd", "coins": [ { "amount": "100000000000", "denom": "boot" }, { "amount": "100000000000", "denom": "tocyb" } ] }, { "address": "bostrom1vtu55cc7m6yz9zfg5vqdk80f2g68petgzj9fv4", "coins": [ { "amount": "100000000000", "denom": "boot" }, { "amount": "100000000000", "denom": "tocyb" } ] }, { "address": "bostrom16yf94eecl6h44l5w7zp75skh3rg0k4veavx762", "coins": [ { "amount": "25185396846", "denom": "boot" }, { "amount": "25185396846", "denom": "tocyb" } ] }, { "address": "bostrom1gxyf6tsjamnavmkfk43mwfzwscn4tgfkz8k85n", "coins": [ { "amount": "5000000000", "denom": "boot" }, { "amount": "5000000000", "denom": "tocyb" } ] }, { "address": "bostrom1w4tvyvf3hhpcwv9d4axa8n0mmj5d6ypvpq5mj6", "coins": [ { "amount": "278432605496", "denom": "boot" }, { "amount": "278432605496", "denom": "tocyb" } ] }, { "address": "bostrom1xk4a2u2rjt7mqu5eg8xtxk37l28r3cugkqk9lp", "coins": [ { "amount": "233157212646", "denom": "boot" }, { "amount": "233157212646", "denom": "tocyb" } ] }, { "address": "bostrom143x4d5wx50204zyreqg8ekgq3n3fcaxucacztp", "coins": [ { "amount": "9826875134", "denom": "boot" }, { "amount": "9826875134", "denom": "tocyb" } ] }, { "address": "bostrom1y83nga220nfjt9zz0mmqc90cd705az95n5cfwj", "coins": [ { "amount": "9608859331", "denom": "boot" }, { "amount": "9608859331", "denom": "tocyb" } ] }, { "address": "bostrom1hyjhy0tp6geral2g9vj9nyteglf8t5q42gfq3j", "coins": [ { "amount": "2388890839", "denom": "boot" }, { "amount": "2388890839", "denom": "tocyb" } ] }, { "address": "bostrom1d8mq46wt2yxsgwrmh6hhfgycl0537w8gggn47f", "coins": [ { "amount": "2182283065", "denom": "boot" }, { "amount": "2182283065", "denom": "tocyb" } ] }, { "address": "bostrom1p0r7uxstcw8ehrwuj4kn8qzzs0yypsjwxgd445", "coins": [ { "amount": "2018839163", "denom": "boot" }, { "amount": "2018839163", "denom": "tocyb" } ] }, { "address": "bostrom1duc9gthaeg82lx9pdf642g043xqhgxgxmfvwsz", "coins": [ { "amount": "994320008", "denom": "boot" }, { "amount": "994320008", "denom": "tocyb" } ] }, { "address": "bostrom1a4mzr2y2g0cc9f0uhyeh3ftmsfxzqwxfdqtd7c", "coins": [ { "amount": "7092669793", "denom": "boot" }, { "amount": "7092669793", "denom": "tocyb" } ] }, { "address": "bostrom1xpl2sx64ra5san4su0r0hj8z9eh5cf5dcv48qa", "coins": [ { "amount": "970654649", "denom": "boot" }, { "amount": "970654649", "denom": "tocyb" } ] }, { "address": "bostrom1hem3076xmat8ttr0cg0nnn2lghtc2p7xtzpj8s", "coins": [ { "amount": "951329198", "denom": "boot" }, { "amount": "951329198", "denom": "tocyb" } ] }, { "address": "bostrom1402rpwdquxxkgvl740f6w69l65eau5vkqcvrax", "coins": [ { "amount": "16533932739", "denom": "boot" }, { "amount": "16533932739", "denom": "tocyb" } ] }, { "address": "bostrom1z8mlsd42eaguaqf5gexy5a7jxgpwpgvz99qzft", "coins": [ { "amount": "218609970", "denom": "boot" }, { "amount": "218609970", "denom": "tocyb" } ] }, { "address": "bostrom1v2n3hg6s4resacgpemfyrd5hul2ntk7tftnk6u", "coins": [ { "amount": "218382779", "denom": "boot" }, { "amount": "218382779", "denom": "tocyb" } ] }, { "address": "bostrom1ufpz4dlnfawg0pr5dcq4hkrf9gs30mu0272p9w", "coins": [ { "amount": "218341548", "denom": "boot" }, { "amount": "218341548", "denom": "tocyb" } ] }, { "address": "bostrom1mkhugmqg9c0qe27stz3m4my9xq7e9pct0jyr3p", "coins": [ { "amount": "218115192", "denom": "boot" }, { "amount": "218115192", "denom": "tocyb" } ] }, { "address": "bostrom1argjwgcplguenq4l92ggn06wadnfrz0ecqrmqs", "coins": [ { "amount": "50591836687", "denom": "boot" }, { "amount": "50591836687", "denom": "tocyb" } ] }, { "address": "bostrom1ke7kxdn29w2lrxt9dzusa6shvmwd8xm9gxm2zf", "coins": [ { "amount": "120588855018", "denom": "boot" }, { "amount": "120588855018", "denom": "tocyb" } ] }, { "address": "bostrom1fpl40sref5vp8kfm7xkqlq5qc0v4xrjvk89kwa", "coins": [ { "amount": "11118481031", "denom": "boot" }, { "amount": "11118481031", "denom": "tocyb" } ] }, { "address": "bostrom1g2d9xyuf7ddgaj4llxvg50pfhlsr9ehf2r8dr6", "coins": [ { "amount": "5689509530", "denom": "boot" }, { "amount": "5689509530", "denom": "tocyb" } ] }, { "address": "bostrom152m9xcx0ht7yxr5834ju7qjcyvetw8amd04apw", "coins": [ { "amount": "71337787640", "denom": "boot" }, { "amount": "71337787640", "denom": "tocyb" } ] }, { "address": "bostrom15n3t80p7eseld809f7fu3s9tlcezlymkfeu59n", "coins": [ { "amount": "4294256393", "denom": "boot" }, { "amount": "4294256393", "denom": "tocyb" } ] }, { "address": "bostrom1ke6pp2kq2wx74tlh5fxqgp7af6jtsna3kktuh6", "coins": [ { "amount": "11975798321", "denom": "boot" }, { "amount": "11975798321", "denom": "tocyb" } ] }, { "address": "bostrom1daxxqs56f6j5qxxtjrjkexghsmnaj66tejshc8", "coins": [ { "amount": "72921262872", "denom": "boot" }, { "amount": "72921262872", "denom": "tocyb" } ] }, { "address": "bostrom1nywu6z26tpcrr2kcqe8z7t235wrfkhfcfhlzmk", "coins": [ { "amount": "10932888406", "denom": "boot" }, { "amount": "10932888406", "denom": "tocyb" } ] }, { "address": "bostrom1mnqlcc7mslzxcf798acp80u2fxudsuzdn0px6s", "coins": [ { "amount": "12677003041", "denom": "boot" }, { "amount": "12677003041", "denom": "tocyb" } ] }, { "address": "bostrom1ccvpcq9ffy0qd2ca8nmmpzfamtyjfc9znwak8m", "coins": [ { "amount": "32639852509", "denom": "boot" }, { "amount": "32639852509", "denom": "tocyb" } ] }, { "address": "bostrom1w4tk9lj8qtx2x4xf4emgrnq950hnlajsxlnl3u", "coins": [ { "amount": "3420409835", "denom": "boot" }, { "amount": "3420409835", "denom": "tocyb" } ] }, { "address": "bostrom1s8l0akn79kk74g32kf86stfsa08ck9qmm4v6ws", "coins": [ { "amount": "3409436625", "denom": "boot" }, { "amount": "3409436625", "denom": "tocyb" } ] }, { "address": "bostrom10aqelwndkz9k8uawp26elxep64ayc5rgn24h7p", "coins": [ { "amount": "3389782351", "denom": "boot" }, { "amount": "3389782351", "denom": "tocyb" } ] }, { "address": "bostrom1ap7zhu5gxlk7n3g97dqehm9nnt3mje3nr5jecs", "coins": [ { "amount": "3368708754", "denom": "boot" }, { "amount": "3368708754", "denom": "tocyb" } ] }, { "address": "bostrom1j6he98h8xwnt2yp9eczhhuff3k3hvk98gr27ee", "coins": [ { "amount": "3326309936", "denom": "boot" }, { "amount": "3326309936", "denom": "tocyb" } ] }, { "address": "bostrom1mskldfjlnup46adzss7lukfh3emm6z4lmqhk7z", "coins": [ { "amount": "3275155354", "denom": "boot" }, { "amount": "3275155354", "denom": "tocyb" } ] }, { "address": "bostrom12ysvrknuwdr6737fnc06v875whfh52xj3ewaf2", "coins": [ { "amount": "2961579452", "denom": "boot" }, { "amount": "2961579452", "denom": "tocyb" } ] }, { "address": "bostrom10trdf5eyfcmc9graltx4hmpgznhrm7hdz82k2n", "coins": [ { "amount": "2941697143", "denom": "boot" }, { "amount": "2941697143", "denom": "tocyb" } ] }, { "address": "bostrom1nvr4qa7szsd3e7xfysn946gcqv5wyemlcxmxpw", "coins": [ { "amount": "10653917696", "denom": "boot" }, { "amount": "10653917696", "denom": "tocyb" } ] }, { "address": "bostrom1wm4026rxqcrkh09k806m6y4lys942etx5cjz9z", "coins": [ { "amount": "2128629825", "denom": "boot" }, { "amount": "2128629825", "denom": "tocyb" } ] }, { "address": "bostrom1zeg2k7kd8qadmwd3kslwmag3erq7hqxt5aajjz", "coins": [ { "amount": "13163031473", "denom": "boot" }, { "amount": "13163031473", "denom": "tocyb" } ] }, { "address": "bostrom16h7tyj5p69t3r7qasunf938cx2elp38fhqc7zr", "coins": [ { "amount": "14451060685", "denom": "boot" }, { "amount": "14451060685", "denom": "tocyb" } ] }, { "address": "bostrom1jdmfxzpnqqlhjsju3mz7qsgvvdparw5acx7t62", "coins": [ { "amount": "1664373777", "denom": "boot" }, { "amount": "1664373777", "denom": "tocyb" } ] }, { "address": "bostrom1smsn8u0h5tlvt3jazf78nnrv54aspged9h2nl9", "coins": [ { "amount": "1654337644", "denom": "boot" }, { "amount": "1654337644", "denom": "tocyb" } ] }, { "address": "bostrom15kl5tv0smz5h8eewu5hs9mtnusz4dereyqxxtw", "coins": [ { "amount": "1408569410", "denom": "boot" }, { "amount": "1408569410", "denom": "tocyb" } ] }, { "address": "bostrom1uew6fawa3ahu60tj5kspmr4u0zvljj69q4s3ps", "coins": [ { "amount": "1380580057", "denom": "boot" }, { "amount": "1380580057", "denom": "tocyb" } ] }, { "address": "bostrom1ezpth4mp3eeqdt49kgqd5ctr69xev6v2gykpur", "coins": [ { "amount": "1351419074", "denom": "boot" }, { "amount": "1351419074", "denom": "tocyb" } ] }, { "address": "bostrom1avvkajdvmj9d8jpl0ga4scftjykeuhjpsa9kf5", "coins": [ { "amount": "1334996609", "denom": "boot" }, { "amount": "1334996609", "denom": "tocyb" } ] }, { "address": "bostrom1gd9r9uhd8a5k2naudq4hua3vf3lkwhfrm63qhq", "coins": [ { "amount": "1301510822", "denom": "boot" }, { "amount": "1301510822", "denom": "tocyb" } ] }, { "address": "bostrom1vrym7t34gs9t2dkd8z849zcymkj54kgq7pdf8z", "coins": [ { "amount": "1231063676", "denom": "boot" }, { "amount": "1231063676", "denom": "tocyb" } ] }, { "address": "bostrom1lk3yjcn0lvwj9f2dj75m8y3smpq5s5zsnnj3nz", "coins": [ { "amount": "1202315516", "denom": "boot" }, { "amount": "1202315516", "denom": "tocyb" } ] }, { "address": "bostrom1hk49ws6ded79xmwehv7yrw3q6mfj7kulafxqhr", "coins": [ { "amount": "1108262797", "denom": "boot" }, { "amount": "1108262797", "denom": "tocyb" } ] }, { "address": "bostrom1vx9qctuxswd6ydcv4z5pcuuvct7y9l0nqq799x", "coins": [ { "amount": "1083041319", "denom": "boot" }, { "amount": "1083041319", "denom": "tocyb" } ] }, { "address": "bostrom1ydc5fy9fjdygvgw36u49yj39fr67pd9mv67ety", "coins": [ { "amount": "894267502", "denom": "boot" }, { "amount": "894267502", "denom": "tocyb" } ] }, { "address": "bostrom1wkjn2nc4v5g3tpjj043wxtmeda90ql3yqqddav", "coins": [ { "amount": "814730401", "denom": "boot" }, { "amount": "814730401", "denom": "tocyb" } ] }, { "address": "bostrom1gh09lmm8flkuu3w38mr4axvunnu6qqlapuwzrv", "coins": [ { "amount": "760249650", "denom": "boot" }, { "amount": "760249650", "denom": "tocyb" } ] }, { "address": "bostrom1m0tjgkrh4td9fcp8nnssu3rfdahzfgdshsall9", "coins": [ { "amount": "682238027", "denom": "boot" }, { "amount": "682238027", "denom": "tocyb" } ] }, { "address": "bostrom1mnfalar08dsvtwutmh43lnhx2zzmq7xhdulemj", "coins": [ { "amount": "15592862337", "denom": "boot" }, { "amount": "15592862337", "denom": "tocyb" } ] }, { "address": "bostrom1g36u05ehktgw5h5udj8hyudd9057d9tx9r6zef", "coins": [ { "amount": "303617054", "denom": "boot" }, { "amount": "303617054", "denom": "tocyb" } ] }, { "address": "bostrom175tm6fucmk0e29cfgzaud6kqgksy25p884kjx0", "coins": [ { "amount": "26259431", "denom": "boot" }, { "amount": "26259431", "denom": "tocyb" } ] }, { "address": "bostrom1v46pz6ddetfc3tnvdr28ss0l48jhazgynvp3c7", "coins": [ { "amount": "14979552", "denom": "boot" }, { "amount": "14979552", "denom": "tocyb" } ] }, { "address": "bostrom1stfw0z5nf2ncxxtrk7zndpf2dla3nh379egwcy", "coins": [ { "amount": "61678847673", "denom": "boot" }, { "amount": "61678847673", "denom": "tocyb" } ] }, { "address": "bostrom147rnn0rxqkythj4j9ccq0kytmh7f005rn0a3zj", "coins": [ { "amount": "55311848847", "denom": "boot" }, { "amount": "55311848847", "denom": "tocyb" } ] }, { "address": "bostrom1pswgrf5ap0kld3lpun5z4x08wh7nmgamd8mgex", "coins": [ { "amount": "8641145058", "denom": "boot" }, { "amount": "8641145058", "denom": "tocyb" } ] }, { "address": "bostrom1wt9h9wm3zf7yzsy68x7v8p973w02kw8yyurh55", "coins": [ { "amount": "10537454450", "denom": "boot" }, { "amount": "10537454450", "denom": "tocyb" } ] }, { "address": "bostrom1ucl2c39dpwqm9pp6cvmlazn2tkwavszhs27j96", "coins": [ { "amount": "9691549420", "denom": "boot" }, { "amount": "9691549420", "denom": "tocyb" } ] }, { "address": "bostrom16w2xwdzf6tzucpwcjjqtg9656a4kkv7g2f6vk9", "coins": [ { "amount": "458125791", "denom": "boot" }, { "amount": "458125791", "denom": "tocyb" } ] }, { "address": "bostrom1hmrxmc27fu4ggdpvpxqtahn6uvtj38vuu77a02", "coins": [ { "amount": "1854496759", "denom": "boot" }, { "amount": "1854496759", "denom": "tocyb" } ] }, { "address": "bostrom1uwfk6h06w8vnhmyp48vwcpgwncsec8yv3z0xyg", "coins": [ { "amount": "1502715615", "denom": "boot" }, { "amount": "1502715615", "denom": "tocyb" } ] }, { "address": "bostrom1nuc82t22xgp09rs2tdnlxxgm95pjg5matjwwye", "coins": [ { "amount": "3573424538", "denom": "boot" }, { "amount": "3573424538", "denom": "tocyb" } ] }, { "address": "bostrom15kdrahda8qcyfa9xe8kt2f737m22x2sleslj5l", "coins": [ { "amount": "1631606648", "denom": "boot" }, { "amount": "1631606648", "denom": "tocyb" } ] }, { "address": "bostrom1n89a8avc4j7cv75lfsyynx5kazlk80ar5qcdx6", "coins": [ { "amount": "41000576", "denom": "boot" }, { "amount": "41000576", "denom": "tocyb" } ] }, { "address": "bostrom19vgwu99fdawejnedgsfx8dmxuc0z4emjf7a044", "coins": [ { "amount": "5014404214", "denom": "boot" }, { "amount": "5014404214", "denom": "tocyb" } ] }, { "address": "bostrom1s6v5ragv9gg3sq7j3aeqtyy82uaxv3y05hzhh8", "coins": [ { "amount": "4273801138", "denom": "boot" }, { "amount": "4273801138", "denom": "tocyb" } ] }, { "address": "bostrom1y6huw3naar38u4rtgqmlh9smfu93gszst9tawp", "coins": [ { "amount": "1688512495", "denom": "boot" }, { "amount": "1688512495", "denom": "tocyb" } ] }, { "address": "bostrom1hqeqy4s039q0qcpayqcyaq5hyyvmph97t79m9n", "coins": [ { "amount": "1190379955", "denom": "boot" }, { "amount": "1190379955", "denom": "tocyb" } ] }, { "address": "bostrom14h099ukgvp4fm9qs0xnmljzhevrmneq6m6cltv", "coins": [ { "amount": "978084362", "denom": "boot" }, { "amount": "978084362", "denom": "tocyb" } ] }, { "address": "bostrom1xhk0s2ynz2sq3ak3lr4u5gg0da4vyaxkfjhg7l", "coins": [ { "amount": "924447759", "denom": "boot" }, { "amount": "924447759", "denom": "tocyb" } ] }, { "address": "bostrom14z6glatrayal5j53632kcefskyge6ujmgshqfv", "coins": [ { "amount": "327466267", "denom": "boot" }, { "amount": "327466267", "denom": "tocyb" } ] }, { "address": "bostrom14n625exc6ftee3t6tez3hj47lv49amjzan5pkr", "coins": [ { "amount": "236797768", "denom": "boot" }, { "amount": "236797768", "denom": "tocyb" } ] }, { "address": "bostrom1fhj7pkuvwflr7z7ngp2v9tj7g58aq2tjgvqfaj", "coins": [ { "amount": "135097195", "denom": "boot" }, { "amount": "135097195", "denom": "tocyb" } ] }, { "address": "bostrom1l4krahjfp87exsmumzpnrfeaer2gsghpuwhfp6", "coins": [ { "amount": "112519320", "denom": "boot" }, { "amount": "112519320", "denom": "tocyb" } ] }, { "address": "bostrom1udal5nr3lz7mg7j7k79se4rz0tsjj8lur45q99", "coins": [ { "amount": "9724669100", "denom": "boot" }, { "amount": "9724669100", "denom": "tocyb" } ] }, { "address": "bostrom1n55zyf6wlvh8jp4wxqgx4ta283jx0e2n2tutgm", "coins": [ { "amount": "1099456389", "denom": "boot" }, { "amount": "1099456389", "denom": "tocyb" } ] }, { "address": "bostrom1glgevt43557u6s7a2q9q40kzt8myw4ngcv6wr6", "coins": [ { "amount": "309112576", "denom": "boot" }, { "amount": "309112576", "denom": "tocyb" } ] }, { "address": "bostrom1mj0sj4eaar5qnjn3l05ep5wgq3l6agtvvqwvyk", "coins": [ { "amount": "1178234463", "denom": "boot" }, { "amount": "1178234463", "denom": "tocyb" } ] }, { "address": "bostrom1sm9sq4wnn62tk5yz0x3fvvx2ea9efguqwvdu64", "coins": [ { "amount": "722135415", "denom": "boot" }, { "amount": "722135415", "denom": "tocyb" } ] }, { "address": "bostrom190y8vwhmyjdnk7cfutcm7u8haw80xyejdwxsql", "coins": [ { "amount": "56952126", "denom": "boot" }, { "amount": "56952126", "denom": "tocyb" } ] }, { "address": "bostrom1rfh303jsl5297sxgs5txpt97lvxpjt4he3yy5r", "coins": [ { "amount": "54988260", "denom": "boot" }, { "amount": "54988260", "denom": "tocyb" } ] }, { "address": "bostrom12u6qgyrdsy4xmw04vfkkkh9a9tqzw66g59hudt", "coins": [ { "amount": "27886903", "denom": "boot" }, { "amount": "27886903", "denom": "tocyb" } ] }, { "address": "bostrom1pjvkddp4fmx8ym5j7s7su8kn3zuqj255djzpja", "coins": [ { "amount": "4022780851", "denom": "boot" }, { "amount": "4022780851", "denom": "tocyb" } ] }, { "address": "bostrom13nrdf490fsuv4rwjp02hlyvalqjkn5u6xxqvqz", "coins": [ { "amount": "14925385", "denom": "boot" }, { "amount": "14925385", "denom": "tocyb" } ] }, { "address": "bostrom1fp9q2t9zn9gr5qjh9wljxuavtcsc4h8uqgnm2e", "coins": [ { "amount": "12175972", "denom": "boot" }, { "amount": "12175972", "denom": "tocyb" } ] }, { "address": "bostrom1u2s32xsws9y2sskz6zvn7lawepdqxad5dcsyy6", "coins": [ { "amount": "330695020", "denom": "boot" }, { "amount": "330695020", "denom": "tocyb" } ] }, { "address": "bostrom158mysantvvk7x65tfhhuu8q2va4ls34r54hk78", "coins": [ { "amount": "9819332", "denom": "boot" }, { "amount": "9819332", "denom": "tocyb" } ] }, { "address": "bostrom1clalfxmsrqdgnqq5uxlx0mc983pyp3wq4xl03c", "coins": [ { "amount": "4713279", "denom": "boot" }, { "amount": "4713279", "denom": "tocyb" } ] }, { "address": "bostrom1wf8alywyvlxy2dqfe38efdpdmuscfpf4jxvg6r", "coins": [ { "amount": "4320506", "denom": "boot" }, { "amount": "4320506", "denom": "tocyb" } ] }, { "address": "bostrom13zf8kghx7h5fyttk6xdnjqn9c87z0rd36sfqjw", "coins": [ { "amount": "4320506", "denom": "boot" }, { "amount": "4320506", "denom": "tocyb" } ] }, { "address": "bostrom1cc43k76udpd3xvpn6md76zz3ru6nvcnreeg2eq", "coins": [ { "amount": "3927733", "denom": "boot" }, { "amount": "3927733", "denom": "tocyb" } ] }, { "address": "bostrom1l5x6kerswths5xl0d6672y9yyn9mg2vw8yz59q", "coins": [ { "amount": "3142186", "denom": "boot" }, { "amount": "3142186", "denom": "tocyb" } ] }, { "address": "bostrom1qe4sguqg8ztlyy7psf7lzwr4ahph9j36k5hltz", "coins": [ { "amount": "2749413", "denom": "boot" }, { "amount": "2749413", "denom": "tocyb" } ] }, { "address": "bostrom1mn8ev805fde2xswght0snwfayfj9tn54dt24zg", "coins": [ { "amount": "2749413", "denom": "boot" }, { "amount": "2749413", "denom": "tocyb" } ] }, { "address": "bostrom16vc2mjjfxx2h5m6jpdp4nqfu5095qaeeq27qxj", "coins": [ { "amount": "2749413", "denom": "boot" }, { "amount": "2749413", "denom": "tocyb" } ] }, { "address": "bostrom1jmhqgld7luvuhh42wac24z6nlggjvkc7fzgs62", "coins": [ { "amount": "2356640", "denom": "boot" }, { "amount": "2356640", "denom": "tocyb" } ] }, { "address": "bostrom1qjknpllzp6w6qsxxjx52zxald29wpyzljznzdv", "coins": [ { "amount": "1571093", "denom": "boot" }, { "amount": "1571093", "denom": "tocyb" } ] }, { "address": "bostrom1eq2h9enjxsg5s08scr69lzwde8fl79snw20dc8", "coins": [ { "amount": "1571093", "denom": "boot" }, { "amount": "1571093", "denom": "tocyb" } ] }, { "address": "bostrom1dx8mvxfu6mpfnjehvdkp9lsvu78ek2gjr7r766", "coins": [ { "amount": "1571093", "denom": "boot" }, { "amount": "1571093", "denom": "tocyb" } ] }, { "address": "bostrom19uryr2zuxcfdevfq429jng9a2evxwadlsky04c", "coins": [ { "amount": "198757551", "denom": "boot" }, { "amount": "198757551", "denom": "tocyb" } ] }, { "address": "bostrom16862syzdtc6h0sxz92jhnjjas5yhhjgzvyewwd", "coins": [ { "amount": "1571093", "denom": "boot" }, { "amount": "1571093", "denom": "tocyb" } ] }, { "address": "bostrom1teuan269feyw4ax94jfp4pcgrhqnn28gxxz8mw", "coins": [ { "amount": "20201178320", "denom": "boot" }, { "amount": "20201178320", "denom": "tocyb" } ] }, { "address": "bostrom1yvlp9gzqaufwz02swp5wqsqhlmfcrcl8m22gzm", "coins": [ { "amount": "200785547", "denom": "boot" }, { "amount": "200785547", "denom": "tocyb" } ] }, { "address": "bostrom1latzme6xf6s8tsrymuu6laf2ks2humqvfcz7m6", "coins": [ { "amount": "785547", "denom": "boot" }, { "amount": "785547", "denom": "tocyb" } ] }, { "address": "bostrom1ec9da8avgv7tnvsx3v8g8veqrhlqq26lnncg5t", "coins": [ { "amount": "785547", "denom": "boot" }, { "amount": "785547", "denom": "tocyb" } ] }, { "address": "bostrom1c7pv6zyza76f3yhv0zvjc042e8m7w796qmvkse", "coins": [ { "amount": "785547", "denom": "boot" }, { "amount": "785547", "denom": "tocyb" } ] }, { "address": "bostrom1yslufs9kq762qty0wh62c8qtlpm2202ejmw4ef", "coins": [ { "amount": "392773", "denom": "boot" }, { "amount": "392773", "denom": "tocyb" } ] }, { "address": "bostrom1y935ede6znmcvqdmn6mnl2aa5zxcqvvracsczu", "coins": [ { "amount": "392773", "denom": "boot" }, { "amount": "392773", "denom": "tocyb" } ] }, { "address": "bostrom1y675phjdvw576ahlcmlamrzr28rjht9mx709lg", "coins": [ { "amount": "392773", "denom": "boot" }, { "amount": "392773", "denom": "tocyb" } ] }, { "address": "bostrom1kjhdx3nkh6krdhryvjzkq33xwh6wsyy7y8ark6", "coins": [ { "amount": "392773", "denom": "boot" }, { "amount": "392773", "denom": "tocyb" } ] }, { "address": "bostrom1jxpe7neu764uasz5y5u4lrr5jtltv430gjm9dw", "coins": [ { "amount": "392773", "denom": "boot" }, { "amount": "392773", "denom": "tocyb" } ] }, { "address": "bostrom1hq8d6pu2l6wkrwu9jxcqjcu55g8l43zxmrd6dk", "coins": [ { "amount": "392773", "denom": "boot" }, { "amount": "392773", "denom": "tocyb" } ] }, { "address": "bostrom1c4h647a9rj8n9zye5ttmh9chpg66f3ffdvdds0", "coins": [ { "amount": "392773", "denom": "boot" }, { "amount": "392773", "denom": "tocyb" } ] }, { "address": "bostrom14ysuwg6p4fzfaa6tg4s3hazu86pfevsw4cegce", "coins": [ { "amount": "392773", "denom": "boot" }, { "amount": "392773", "denom": "tocyb" } ] }, { "address": "bostrom1x7wp0u877dkw7m84jv54c9g6zpd5r8t2nm47gn", "coins": [ { "amount": "33812731064", "denom": "boot" }, { "amount": "33812731064", "denom": "tocyb" } ] }, { "address": "bostrom1gss7y04dky2fykck4dyp0pe39wxawlxm2l0yj2", "coins": [ { "amount": "28704261935", "denom": "boot" }, { "amount": "28704261935", "denom": "tocyb" } ] }, { "address": "bostrom1cerh237zd5rdexptjw8ryhwdf2tc9eupz7sfn0", "coins": [ { "amount": "20918517127", "denom": "boot" }, { "amount": "20918517127", "denom": "tocyb" } ] }, { "address": "bostrom1fz799u9jc0umceng3nkjt0njxy6y3550uq06jn", "coins": [ { "amount": "14973655085", "denom": "boot" }, { "amount": "14973655085", "denom": "tocyb" } ] }, { "address": "bostrom1wzqyjejz5px38vgqsegafrcexl3963q9dsgqh9", "coins": [ { "amount": "13098969682", "denom": "boot" }, { "amount": "13098969682", "denom": "tocyb" } ] }, { "address": "bostrom1evz2xfd6sam0kzz5qc5lje4s90vcgyyrzz47pm", "coins": [ { "amount": "11323309556", "denom": "boot" }, { "amount": "11323309556", "denom": "tocyb" } ] }, { "address": "bostrom1mzmzlzk4xpm6zy68c43e6hen98w07yhfedumgg", "coins": [ { "amount": "10780033350", "denom": "boot" }, { "amount": "10780033350", "denom": "tocyb" } ] }, { "address": "bostrom184dur4s6pldvhvcyputu6yshsm09s6wmvylt8k", "coins": [ { "amount": "5728639830", "denom": "boot" }, { "amount": "5728639830", "denom": "tocyb" } ] }, { "address": "bostrom1gyhwacrpqwues05pkavw7xwehcqsmgruy34zps", "coins": [ { "amount": "564067516", "denom": "boot" }, { "amount": "564067516", "denom": "tocyb" } ] }, { "address": "bostrom19wtkh935tx2ut2n4m6tjvkfvew4shaeezfl7em", "coins": [ { "amount": "59855356", "denom": "boot" }, { "amount": "59855356", "denom": "tocyb" } ] }, { "address": "bostrom1a2kn43nquua6gmr4n42htmjpceqj7fzushe28h", "coins": [ { "amount": "52853070", "denom": "boot" }, { "amount": "52853070", "denom": "tocyb" } ] }, { "address": "bostrom1u74s0z4ft63c6zz7g8xs62esdtdjkzuk4zf0rt", "coins": [ { "amount": "42282456", "denom": "boot" }, { "amount": "42282456", "denom": "tocyb" } ] }, { "address": "bostrom1d9en5u0cfaucavx848qeq4k6ywqd3z5d5a778h", "coins": [ { "amount": "20000000000", "denom": "boot" }, { "amount": "20000000000", "denom": "tocyb" } ] }, { "address": "bostrom1edwwsevuywe3sx82sustvyx3f3cvjt44ugccgy", "coins": [ { "amount": "20000000000", "denom": "boot" }, { "amount": "20000000000", "denom": "tocyb" } ] }, { "address": "bostrom1gcy4f6f2sc73aegd9r68rt2q6teekl6swjva3p", "coins": [ { "amount": "20000000000", "denom": "boot" }, { "amount": "20000000000", "denom": "tocyb" } ] }, { "address": "bostrom1d6nkeqxmme3564wd889kr6cjed3asxqzjve0wl", "coins": [ { "amount": "20000000000", "denom": "boot" }, { "amount": "20000000000", "denom": "tocyb" } ] }, { "address": "bostrom1djdfq5mn3dzm9whpznczxz77s8ep2qggc5w5xn", "coins": [ { "amount": "20000000000", "denom": "boot" }, { "amount": "20000000000", "denom": "tocyb" } ] }, { "address": "bostrom1z8fyzv3mjfccvrxhckr2u3lnc0hrgrlm4zkf8c", "coins": [ { "amount": "20000000000", "denom": "boot" }, { "amount": "20000000000", "denom": "tocyb" } ] }, { "address": "bostrom1tcnlvf6qhlc3x7ax2vk3vzhxhf8wy8xrnjl72d", "coins": [ { "amount": "20000000000", "denom": "boot" }, { "amount": "20000000000", "denom": "tocyb" } ] }, { "address": "bostrom17ud38eyfkd800kvw3c9kl3zpvgvj296nfszelr", "coins": [ { "amount": "20000000000", "denom": "boot" }, { "amount": "20000000000", "denom": "tocyb" } ] }, { "address": "bostrom19rtverjn8kw7dzwzch2elktxgcmak6dlqugxfw", "coins": [ { "amount": "20000000000", "denom": "boot" }, { "amount": "20000000000", "denom": "tocyb" } ] }, { "address": "bostrom1mlqakhlxplhlezk80lph99wcy377j9dk2qx3gg", "coins": [ { "amount": "4000000000", "denom": "boot" }, { "amount": "4000000000", "denom": "tocyb" } ] }, { "address": "bostrom1ssu4wqtzvvmwcukcv7l8zxny647mdx03e0t57j", "coins": [ { "amount": "2001189000", "denom": "boot" }, { "amount": "2001189000", "denom": "tocyb" } ] }, { "address": "bostrom12reh000lje8y20wshqmgl8tg70qggt2ac7qz45", "coins": [ { "amount": "2000000000", "denom": "boot" }, { "amount": "2000000000", "denom": "tocyb" } ] }, { "address": "bostrom150svyax8m8dwljwenc8xxtsg0avud07m5frlrz", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom14tjwqqyha0c9r0s29dm0n0zdpdc4hfrvn7jqsq", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1x8r0ktn36dsxsadnp3863txyd9pksrp6awcuaa", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom19lsruwa85k93ahzkdwaydyrl6ehz9dmmkava0y", "coins": [ { "amount": "400000000", "denom": "boot" }, { "amount": "400000000", "denom": "tocyb" } ] }, { "address": "bostrom1tyzmkpn0axquu4jlht3lllsmq03um8kn5cu5pt", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom10a9mqy8cu04nyz3nj934ck39p6u9ddjt9y5fve", "coins": [ { "amount": "400000000", "denom": "boot" }, { "amount": "400000000", "denom": "tocyb" } ] }, { "address": "bostrom1f2uslv6udnjwyqkdngc7rswp5vkmgavzgy952g", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1t7gw3d2jz4qc6k6umgkazvfyeydjv7l6nym265", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1rc2647d9nftgwwh9n5vaw26lnjdrewc4dum68g", "coins": [ { "amount": "400000000", "denom": "boot" }, { "amount": "400000000", "denom": "tocyb" } ] }, { "address": "bostrom1zejjt25xw9gwvhave95ykkvgqjtk7j56fe9cwh", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1vesdfkzd36m08clhvkpusq4gv0dnqm28rm2hey", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1ypvt8rf8md7qedvnk0p8cvd6mnffepst8f05p7", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom167hs9ma63wd02xym0vjw80uqlekt0cs54ass6v", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom17tksas9e4nkp25vgwcsd7z6y83pa6u7sddyyez", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom14thj9udwenk5q8c5ey2urude2j54xud2a26rp3", "coins": [ { "amount": "400000000", "denom": "boot" }, { "amount": "400000000", "denom": "tocyb" } ] }, { "address": "bostrom1y7ku6vf9vq53pv4y6lw2zjn4d5ul3javm92whz", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1mzn966mlprxgkvayrqu209069px0qwz7gzn799", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1cjeg60652ueyu5222l3atmm8vrhlq4tfusnswk", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom13855g4d5pfhtnqemgp700qs36qpjdnaz0dx2m5", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1ueywgan39tj27pdysq0d54cqvcwyggf6eves07", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom197h938dvw52kzf2l7gke2u5tcz3grvlexeaq0y", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1pkxtd9xwmqwg08kjgz9xqyee3aw7j8upd89ah6", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom12arnsa069zhad0e40mlgy034n7aq77e2nxdven", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1m3yh7j0jefp9dl26cz8fqexfg8tds39lh957jw", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1ysn8jyjv464fv4wpt40vezh7d5tw05tc9v858t", "coins": [ { "amount": "400000000", "denom": "boot" }, { "amount": "400000000", "denom": "tocyb" } ] }, { "address": "bostrom1gh8tenvx2sf9kj2c359ey6s5k0vzlrl7z4t59z", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1svwchckmrrkfl7py7l2fz3esla7lwmalld4yr2", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1hmdjgtv3yq4qzyuk3ynyt42sjntma8hqarepjd", "coins": [ { "amount": "400000000", "denom": "boot" }, { "amount": "400000000", "denom": "tocyb" } ] }, { "address": "bostrom1wr0mqeyea45u9av63srtvgr553nyg6l9p57ezr", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1e20dl8se4v2ev79qcay3ag7uf5t98gampz0d48", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom12c8kh7aaz2gg0l4nkd73t58nhurdaren55atua", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1ftyx5guwf39fz4nc5n5nc9fua36cq344rm2d43", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom17jq8ev7n4e3zv8zdek5mccvxcgxxtkwva5vwtx", "coins": [ { "amount": "400000000", "denom": "boot" }, { "amount": "400000000", "denom": "tocyb" } ] }, { "address": "bostrom123wttw3lu62m7lcg23rkwr88cvv8apjmvkuj9f", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1j5wpswepyxva5vupvg05pq6jzqh7ttdvepkhp3", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1wh5gfxyz8x95qyjlc2s24h3czr60vfehwt49xa", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1z3u9w3vyq6sw7ndxcdpjkgvlj0qaqm6spc3jmp", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1pzyt3y68zcnvl7hkvuffqfedccaptf6nt2x8ya", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1pzxnpyvxr6x9z64y6w3ctv0cvcx9sp90ehj960", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1pvu65ccqw3fmgq88j2j485wc6qm96nx7h7ln4f", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1nqxwnut0hdgsn3l9zaladaft5xt9c6ex9qquza", "coins": [ { "amount": "400000000", "denom": "boot" }, { "amount": "400000000", "denom": "tocyb" } ] }, { "address": "bostrom1njpfrygstn6r5awzp77keyhkl3wfhzmvdz2pug", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1ke9xxd3d6y0ttduac062zvv3r0jtakvhkvqcjz", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom15ak23s0usm36hv2e4kajhe0yx592hw474p3gkq", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1gffprg0nuvj9ve39s9rjhjp04u7k8xwan2tzff", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1yq5h0gjxuup83hdz53utukwhkkz684mk3lx7cr", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom19rfaqnnz5fy3qct8qxzany94t2p7h0rrc75lmz", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom15y8g5ggq2lslncdnlcscqygyesefmjy0t4cae3", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1gfkztltd789py02jcd79dnkl252uej7x8pnx4p", "coins": [ { "amount": "400000000", "denom": "boot" }, { "amount": "400000000", "denom": "tocyb" } ] }, { "address": "bostrom1h9k38zr5a532jzl0hsker9qz785m822zmqw974", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom18ghdg8y5hx6esxm6ndw3ywgtalvkmz48zeyc6z", "coins": [ { "amount": "400000000", "denom": "boot" }, { "amount": "400000000", "denom": "tocyb" } ] }, { "address": "bostrom1zy3nxgwtw9hr99tzfaxasgwklm9ev843fju9zl", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1vmfs06hv80gc8jcpzu93ld4494azendxfalh2g", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1d66wegxpllcsnrzv9saqugpk2dausa836qlqaz", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom15njl9exppdfms5fg4zz9wafn4a95lfj30ftx58", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1v2fzs3a8mvm4nhsfcpk85gt3d8rdacv6zggl9r", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1fm842pq6zxaqs86fm30xv459gx7hm7f0ufujvz", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1rzr7gnkm3kdqmzqya7ky98m8tnnmtet58deav0", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom16gtt4cmrvg2us2rgecym9zt65zet7qq2euzvdf", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1jsdfjw0pjjj5thg7z2tpm30njusrlsagtac7rs", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1z33aen2znsmgy7wwzavwh2q0u7cu4e9xhky379", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom10r2sn7sasanc0tuw5wzupxvlpht5uv267her62", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1gtma98yjsx43zc30j99t7t0tmdjt2gyp9e7g0r", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom185y3kgv3e6t4sue0a55jyq88hv76th3urnca4c", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1xc6jdlqd8gd9e6p73xdc2yw7ad3tnl8w7j4wsl", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1wdk6rndatlj8dpxq799vmu50zft7xk5768ej2v", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1uz3xp4au0rxawmct6ffj0u3le7uglyza43appc", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1uym8hd4pum4zz2mpkf93y8435u725k97e2c38p", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1u8yt9tvnwvvvlm36w97nyg27ue797hrvkz6eux", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1u4427txgc9pulkuu0wk4v9cjxqa0dxee5az972", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1epcd5upewwa7s20u6kgf9uywa2f7c3yj6zaeg0", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1tx6dnqh0nnj05uuell7rhnwhennscehlnjylxv", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1ypzhtfsyuejekw0w0z207wyedqm3xqafc8nu7g", "coins": [ { "amount": "400000000", "denom": "boot" }, { "amount": "400000000", "denom": "tocyb" } ] }, { "address": "bostrom1s4ytylknecgkp7sp3jgf2f5lj7mm2xxz0f9rl3", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1s05hsv6fxhkpclwxzgnlfjjk7qdm78nmpchj08", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom176q2gvutyk63dzknylcvdhp6lyjwu5w9fdmmev", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1e08w7wrjn05gl06xkwnlfmud5f6trdkrf0drg5", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1pzp9nadejsjzfkpfl9k7ktu2cfhprw4r7qvd5p", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1pt3a6xk432vs8lp0z6ya3qhqhxks99xe4sxxqq", "coins": [ { "amount": "400000000", "denom": "boot" }, { "amount": "400000000", "denom": "tocyb" } ] }, { "address": "bostrom1damlfdlp8yynjvrmv6pd3t33f4currrhe4cm4z", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1cmhrs08sqv0823mj057svp8jerp6avne6xmtrc", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom19wlc6vms3qkuy48wgg2dl06veahgxl47s8859j", "coins": [ { "amount": "400000000", "denom": "boot" }, { "amount": "400000000", "denom": "tocyb" } ] }, { "address": "bostrom1h9zrqgwcjtul3s9qxf0hk0ym9alm44ztywkfyj", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom18fudz7p6ah9yvdr4p9aflp8pgzngx84cem5lra", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1e8dsx8yx9mjn8v8egz2n5vafkymqw98wy4z6re", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom189tpr8vg4qvwn7fgs6szkqr25yrammvvlzx0zr", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1xvsukg4tltfzduw0lsvgqyrhe6rzrlp472ln92", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1w7f07762zelhx4spzkndmygh2dz58g3nn58v7q", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1808q4nv5qafkk8ec9h56wwth6sl5a5yd0elve6", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom15a8z9l8ufw8v8zdddfhesnmfzwwhua7axrmfxl", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1undz2328av9agfhaguqs8zxzejv5zqcc9grdmv", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom17vw0qcu9j8t6jhh83sjrzj07nwg9nndfcpw9g0", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1evnwfeuqsgkjwe5qwe5acyy6m4w5ch03m3e7a6", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1t5r4uhu0tscqw380t6hqmvrgyhlrj3u43vsm43", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom17kwvcuvar02ldacltr48373rm74z8lfkcq80vj", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1r7grd2sazgzsy8y0c8wlsnjyhdc0sq4npr0v4q", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1pfwja2fu2qcqvdws6rcdr9y6za46dklaxc83fh", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1p4uyyk8sc2arl4n9egw3xrn9g7rpkzlerf4nlc", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom16gxdwa79rsvkjaawpcpswthgahm56p4mpu8fe9", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom13nef2p2g48kmj83m7f0ey76q6p9cdyrn03x4tz", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1m9x4gg6frezyeqldxdz4dvegxpcytxnapgykwu", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1kfz37afuxfyajrzk7xv6937xc0jsq4zd0ce7dz", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1kae5k3nnzs3q7tar4ec3w29w4avd8saqujpjk5", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1hjjsjgv7sx88mxfq9y44ql24xs76jj3w7y9ff8", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom130avjyegx7glgnqvraetqj6ztacrqv9kdwawkj", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom104rtaftr9xmx6dcakempk590tfxx4ytddqcj97", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1f6tmyjffs0p7f6xeh25esjhawxu2kll9j00a47", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom105c5jk0xwzlk4pexgaeqkxq0xadtqchc4lmev6", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom185tek8r0ptelug0erducctzc4d83q5np3339k5", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1z0m5tcv4jde5acv0w4dms537wvntgj7x47zmeu", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1fzkp5pux48ux72wsgls9lhxp5cq2tqsy32hfec", "coins": [ { "amount": "400000000", "denom": "boot" }, { "amount": "400000000", "denom": "tocyb" } ] }, { "address": "bostrom1nsffk0nt927vn7pdsk8epzjeqch3yfzkzq57pl", "coins": [ { "amount": "400000000", "denom": "boot" }, { "amount": "400000000", "denom": "tocyb" } ] }, { "address": "bostrom1e4cnw86pl73k2sfv7uwauflfl42qzncn4akyv7", "coins": [ { "amount": "400000000", "denom": "boot" }, { "amount": "400000000", "denom": "tocyb" } ] }, { "address": "bostrom1jlu5u2sj0afddmcj7lxfy0ng466s8l2qdjz24v", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1y9tvvunr7uaqjjw8u6xn5muypq6pheyz5gygm3", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1qsm0ujra4vdwymc5vrtey2rvalyq8392h75nr4", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1jgvy2vr96auye3er6n3tkhlu9hnxs6h3a38rpp", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1jcj0w0e2khy0asm7dz8883xnepzmaxylwez7j2", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1q22fvnhna2zg2g2xm6s5587w8fvsh2zzfeey68", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1amletsu7926696dpeay8wrewqgww5s7yunjjxr", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1qkltelhy5zsr4kfrefvwsupxyt6y9skwjpd7h4", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1nfdyvvjy5hum8gpgmt29d0m5y4te3ekpfyz7pw", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1hjz37u09vws084cvwjlr5t27wmsrzm9tmfspu5", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom16zykdjnfjdy5cy3phuymmcghh8x24eah2cmmpu", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom15pax03gsgw84lsygpxyyvtthd8fswrqp7wjs7m", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom124ll3q05an955eh26ygn34u5gtm9287arjrgj9", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1teyn0utv6yhnwux44ycfvqh6z888pvjaz9cz6l", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom10905rstxf5tzj0w6gguaa76ma7s32v48um4w9z", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1m7y6qezuemqe6n535z7s80ee8zw4zg486vr53u", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1pkhgpslggp3t0nrwskvgczxmavg7yejfullesx", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1zyws7rajm9f3ql6jqqpzvnml0aym9vspd7tjxk", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1pa0rcdua5v9d4vf09ksnnl7t96nfkf3w37k4dc", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1durjade4he9l23rw38azruzfttpmc8223n6r87", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom16jvmfza0q60umemx2pv8s5kle2h8g9x6jj9fkq", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1gywad2frusetg26dyh83cfaevacravashyjwg6", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom16kqpk5jg9e5ucxv3e003mf48yuamw4ce5ww4la", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1zr9urr3m42w7pu5h5xn7rvghcdk5vtrtmfw7wf", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1jet9jf456dja8vqlhk407l06yvfehwzuvjaynv", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1q8ajen3vu5v5uu4czkvqasqvw827dz2nqq6d0s", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom12w56mhf4nsfchquw0sgzwn72qkzvfvquxhg6dn", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom10v8qjj6haddx7wmnr65mcsllu8xunkee7zg3z5", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1hy8dexwz6ynlnnaj8ge7jvmzs4c6qmz6yh97lc", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1vpp9vy0fnxxw8yk5t2cctutpfv8pprvyhnjw90", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1w0u83ty3nmflg9846zmh28u0hweccs3fzfpx0f", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1z6lhk6u25fceqylmgv65t5py0c8kclgkszmqyx", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1zcf0ph3k4p2q2pl32zqspy5f7jkgxd5s4kcd66", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom13s4egz6pqg6a88dunme3esuee5w7qlkjttcs08", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom12w37894jf7rt2ck709rk8xa23lz3lg9tv93tlz", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1sntt4y34tghn45vw97az7mz4vkcw8kgregkph7", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1pa0lcssmjkkycdvrhhzey5h94v34wuf9u4ths6", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1l9yx676futn4h28rxupsvk7evl9s68hrufetdw", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1knpgev72f2empt8j8gcn24my8kdasy2lcezjea", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1clr05sms7eklm509ger6jdzhgheafskv4wwxrg", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom186tpdptavhzz7fg83vnm4r2y85cfqyg6sntmun", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1qc4t2q45f826cfc7k0y45ma8f5qrrfv2nkly33", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1n0wkta56ktj93nzpe9amkgrzq7rhzt3gy6m8uh", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1exul86z68fzck5jra7jp8xdwvmfz5p9qyuh8um", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1melp9r22clnjzzudd0thvs5zzveqfjyl9xfw54", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1zx70t5xqc8h4kmvrssdc2w82v9ksw0r82a99av", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom17ssaukj47urfj6c8cgywyz9xhgqz3tnpy7n5kv", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1znt56em2psvx8ylfpplcmpy5esrea08g2psvxm", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1tz4yrvqlw87e74n783n0da4pttay2ypsfq6668", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1prrtyfgrw2tzj9kua5eu7tnctt474m36eygux2", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1ftkw5j528j94cajk4rvqum3k7mhhmpvyc8k7yg", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1pe42d4gkg7smf9na6dvh5twq9hgczsag4elx84", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1nscf69wvc0wkgqm8ma79qv8cr6j6zq3dt0t898", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1exv982mrkyfd967xv7fam7lq8h3ce3dvcnd4s3", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom14q65nd2ft893dagpln4fq39wutv2xmpe3kc4w0", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom17llhhwjmglhhqumz72e4jap5cj39r8rwar7zzv", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom15k9z24v0thrxffetjp97493ec89zlz7re07pjj", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1y795vkzvczrauey63vmvvcjr84l3fjheqd8f38", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1qf560sekun7kjsu4r0puey5u4fn90025f4q2p2", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1v9p7ukxpw2yjk7eqm8720vkgqq5qlk7w3jqgzu", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1a57rc9cnhdn4l843ca4990aqldh5wmq0uuetzg", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1q2ajajyu0t544tudcnvk7xcznerhylz36p5vtc", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1ayc0pueqve9a3xjpgwh3p4l6hjlyvfpvclvldm", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1jmdtfuxag0deeuyxmj4ge2mqhvc200hlmzyztf", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1k24kf4reet2lstvmkx9a4j0r87xfuqeqh2lprz", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1e0c3ehnfzvcxvwh9fgzyfc2vqshy9w53du7hnv", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom178nsekn4qcdkqqmv95qlmp68kaqpga3zpsdnf4", "coins": [ { "amount": "1000000000", "denom": "boot" }, { "amount": "1000000000", "denom": "tocyb" } ] }, { "address": "bostrom13uz23f4stcg8esqvvc7d2w9psxv0dya5xaq5ne", "coins": [ { "amount": "1000000000", "denom": "boot" }, { "amount": "1000000000", "denom": "tocyb" } ] }, { "address": "bostrom19trgcp8uldtc5xtnpf0u7x7dk3t3jcp4y7cusm", "coins": [ { "amount": "1000000000", "denom": "boot" }, { "amount": "1000000000", "denom": "tocyb" } ] }, { "address": "bostrom1fn4ep44ud3edyh304ta38f55xd6pxswsw9e23z", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom143dfs4ur5gjvwgx8l54jjz27rq57us0zz3hqj0", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1e3je4h3vkxywt2sf7mudelhf6zrx405yfgczkf", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom180upuj8yp0326px2uys9r60xrlhpsa6fwryf80", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1jdypscylf6hjlrlva03tx5vqqkcdnllg6rpza7", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1r85972mwrka5w9ct6km58ww9jl9sh46fx559fu", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1xz2dkqrnrvq0ezc0vxtcvhwy39xr63vxzfedsr", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom134llrhdus60n7853fn3ulmx6uy7evsx3ltzstt", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1pv5clfxxfpqvuerquue2vgr2ndgh0h50jx898c", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom107v45crxqedhmf4yqa9y98v99wm2078fwtklsq", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1959r3zp37k9yuz8kjtc4feayyfkkxpcv43mu0w", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1qh6eavdzp5ffks2rvd5mjt3rdmjxg3qm5l4pw2", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1lk7m28npegzy0sz5s06sy95n27yzrj4d3rytdg", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1clk49u6rvv8c40udn9qgp0s8hv5uvfcgxqptky", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1gws6ulm3u23txc6p8kv6ew6e2zn45udrwjkdqm", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom17rg7cldfsqfmv53n6r7qmjmcge7ucxx2hhum0q", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1kkwwsk0v4h7tmccr4sdmpyl2j2gvfah6jzw7n8", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1ggh3zff5paq5c3r2j34mquq9lrcc7s0nvfnuwz", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1gp5s4tetnk7ng49g58uhn2znfpmgs4cfdq4ns3", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1ejkkddkuw63zn557l0lvqq3gmjcra53ealmy2x", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1jrp04lvvpzkyylr4l7e5xp256l9yd4hdhrpmls", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom14c8rllqzmgyrkt8aeyanprl7g3adrlc2flq57a", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1j39uxls4clq76ej7mk2tdskvql2tdp2zek8g89", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1qcy673rd8a27t48ry6evmv6as7fuetd8cyhnjn", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom12d3klseftxsfs5xmvjju339enk8xcvg5y55qvl", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom148g7gmqvw5gfj7dmpjymtsw3j7gvasflqrsyx5", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1eur22ds9gn06lgg9j3raqlzj8j2qzxx6vuje4x", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1809klqrjjrs8ch2gtf5hmmfhysspkrr894rmhm", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1f9nx8jrlx9pvns70edanu37mxtm359k606qyds", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1qgkdm2asr0qey7jafqyqlnarvgndjws23fpkrh", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1r5gvlzt03a0a9rks3s57cppmfqx2lzjrquh3d0", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1yaastlp99jvqta2x5fngdzw6zur7khctd9gk3x", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom14jhjmhm2xmx6wyefju30auqvrs35hmnn2m8ewl", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom10pqp6py9pqtagyde9tnkkvakg3gqsnq7lgzxnp", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1spndx95pckqnmjss6emff6fyylasg66qzdfv6v", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom17qkfq2uwags5pzplrfqg2elhn9s0pfwja4mgeu", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom194097avwy9a6h0cvznev232z28h96rp2q3w3uc", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1l8hx9jxul439uyjve4zn45nujtx9gmrw3za3vs", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom12zmexhujvw7j82la9uslzfl5g29erpysqt555s", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom12vexhfe4m9p9szsqvzsalssf8sxluj6pqx8gr3", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1ukgaegxryydqckt6fgrt60dajxq758x9pntmhh", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1756xr3jtsdve6vuwqgqdtmt6ws3td49gq7vc77", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1fn5cutfgat9s9z6nz5ucnnq9aec82wvqpevsn5", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1e63p9zdn5xks5ge9gj2y9gfkl5u0jgkvfrnhzl", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1zq9f4eczclr5cexrxdusfxxr6eumn2rlg2h4hs", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1sjtl9n7fqszta6p4w5y5yl7d4xqth26d8z2gjj", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1a4krl6m7jg7ckczk94hh0wdlcezvpgwcwkrpcg", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom17lzmvgnahdncwnsx3dr7mss65qv6l9md2hy2qq", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1pljwxmmkhfrkzkdpmdjv29t6959sa77mjt0xz4", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1t9xfg2kurjlvnw86repcpte3shpgasdjge6a7t", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1erxn6kmz3xhfrv40m7lyp88v43qahqn8fy2xhn", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1k879z65mwwwu4jause7galz0hlsqqj4rtah7r6", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom16dsvdl4jer9jyplelgz4x68hjvg5k647nrnc8z", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom12pafl09rqzcw7d77qs63pg2nlsgvc3dsfxyzum", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom15cq4l7d6v43rtv493cps3c7tpsf26d83pseqwn", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1wrtzl04mxs2en94ysc5p8mvqc5p0culr9w9m0n", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1a2zr8qx60sl3srh982hjduse0l7pdcnhtl7juy", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1r82whjffalh2hgmrayywc9g53es96n9e9893yv", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom15884n6qmrwq8gjuwtqh6q8z7vx500n5s3djcv6", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1nhkl9r84zjucmjswhddwq8zgpun5yks5mjk7xc", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom12cq4xxcr6pmjz320aj7j8pn9l8vjeed63slcz5", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1fwx3u5w8qyzp8msv2n9umajgst86dnuqrsft0g", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1zg3xqymyrvlu5fmmyx8htdm84kqt50t7xdfmuj", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom152xtf7tvw60tyhls32wwc9ypehqzf366zjkeeg", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1uspnj6pvq0u78d8qux8lz6p24dzm998phldqgv", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1ppzvqc7yf9lfs8cljqu6w992gct6d5h9jx5wsn", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1jn8cp663fl0mv6k55xvy2lr6s0r57zg0v6gzr3", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1fmpuldfmgj0a4dlkn0cdlap4h3qs7nljyph4rj", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom10mja0qpcq6ze2nrchhh7w3n7g589sdktfu7p9m", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] }, { "address": "bostrom1kaaxhzud2ev7v69kwkf8vuvhst9a36wz5l424q", "coins": [ { "amount": "200000000", "denom": "boot" }, { "amount": "200000000", "denom": "tocyb" } ] } ], "supply": [ { "amount": "1000000000000000", "denom": "boot" }, { "amount": "1000000000000000", "denom": "tocyb" } ], "denom_metadata": [ { "description": "The staking token of Bostrom", "base": "boot", "display": "boot", "name": "Bostrom Boot", "symbol": "BOOT", "denom_units": [ { "denom": "boot", "exponent": 0, "aliases": [ "BOOT" ] } ] }, { "description": "The liquid staking token of Bostrom", "base": "hydrogen", "display": "hydrogen", "name": "Bostrom Hydrogen", "symbol": "HYDROGEN", "denom_units": [ { "denom": "hydrogen", "exponent": 0, "aliases": [ "HYDROGEN" ] } ] }, { "description": "The power token of Bostrom", "base": "milliampere", "display": "ampere", "name": "Bostrom Ampere", "symbol": "AMPERE", "denom_units": [ { "denom": "milliampere", "exponent": 0, "aliases": [] }, { "denom": "ampere", "exponent": 3, "aliases": [ "AMPERE" ] } ] }, { "description": "The bandwidth token of Bostrom", "base": "millivolt", "display": "volt", "name": "Bostrom Volt", "symbol": "VOLT", "denom_units": [ { "denom": "millivolt", "exponent": 0, "aliases": [] }, { "denom": "volt", "exponent": 3, "aliases": [ "VOLT" ] } ] } ] }, "capability": { "index": "1", "owners": [] }, "crisis": { "constant_fee": { "denom": "boot", "amount": "10000000" } }, "cyberbank": null, "distribution": { "params": { "community_tax": "0.000000000000000000", "base_proposer_reward": "0.010000000000000000", "bonus_proposer_reward": "0.030000000000000000", "withdraw_addr_enabled": true }, "fee_pool": { "community_pool": [ { "amount": "50726497621325", "denom": "boot" }, { "amount": "50726497621325", "denom": "tocyb" } ] }, "delegator_withdraw_infos": [], "previous_proposer": "", "outstanding_rewards": [], "validator_accumulated_commissions": [], "validator_historical_rewards": [], "validator_current_rewards": [], "delegator_starting_infos": [], "validator_slash_events": [] }, "dmn": { "params": { "max_slots": 4, "max_gas": 2500000, "fee_ttl": 50 } }, "evidence": { "evidence": [] }, "feegrant": { "allowances": [] }, "genutil": { "gen_txs": [] }, "gov": { "starting_proposal_id": "1", "deposits": [], "votes": [], "proposals": [], "deposit_params": { "min_deposit": [ { "denom": "boot", "amount": "1000000000" } ], "max_deposit_period": "604800s" }, "voting_params": { "voting_period": "604800s" }, "tally_params": { "quorum": "0.250000000000000000", "threshold": "0.500000000000000000", "veto_threshold": "0.250000000000000000" } }, "graph": null, "grid": { "params": { "max_routes": 16 }, "routes": [] }, "ibc": { "client_genesis": { "clients": [], "clients_consensus": [], "clients_metadata": [], "params": { "allowed_clients": [ "06-solomachine", "07-tendermint" ] }, "create_localhost": false, "next_client_sequence": "0" }, "connection_genesis": { "connections": [], "client_connection_paths": [], "next_connection_sequence": "0", "params": { "max_expected_time_per_block": "30000000000" } }, "channel_genesis": { "channels": [], "acknowledgements": [], "commitments": [], "receipts": [], "send_sequences": [], "recv_sequences": [], "ack_sequences": [], "next_channel_sequence": "0" } }, "liquidity": { "params": { "pool_types": [ { "id": 1, "name": "StandardLiquidityPool", "min_reserve_coin_num": 2, "max_reserve_coin_num": 2, "description": "Standard liquidity pool with pool price function X/Y, ESPM constraint, and two kinds of reserve coins" } ], "min_init_deposit_amount": "1000000", "init_pool_coin_mint_amount": "1000000000000", "max_reserve_coin_amount": "0", "pool_creation_fee": [ { "denom": "boot", "amount": "1000000000" } ], "swap_fee_rate": "0.003000000000000000", "withdraw_fee_rate": "0.003000000000000000", "max_order_amount_ratio": "0.100000000000000000", "unit_batch_height": 1, "circuit_breaker_enabled": false }, "pool_records": [] }, "mint": { "minter": { "inflation": "0.050000000000000000", "annual_provisions": "0.000000000000000000" }, "params": { "mint_denom": "boot", "inflation_rate_change": "0.200000000000000000", "inflation_max": "0.150000000000000000", "inflation_min": "0.030000000000000000", "goal_bonded": "0.800000000000000000", "blocks_per_year": "6311520" } }, "params": null, "rank": { "params": { "calculation_period": "5", "damping_factor": "0.800000000000000000", "tolerance": "0.001000000000000000" } }, "resources": { "params": { "max_slots": 8, "halving_period_volt_blocks": 9000000, "halving_period_ampere_blocks": 9000000, "base_investmint_period_volt": 2592000, "base_investmint_period_ampere": 2592000, "min_investmint_period": 86400, "base_investmint_amount_volt": { "denom": "hydrogen", "amount": "1000000000" }, "base_investmint_amount_ampere": { "denom": "hydrogen", "amount": "100000000" } } }, "slashing": { "params": { "signed_blocks_window": "8000", "min_signed_per_window": "0.750000000000000000", "downtime_jail_duration": "600s", "slash_fraction_double_sign": "0.050000000000000000", "slash_fraction_downtime": "0.000100000000000000" }, "signing_infos": [], "missed_blocks": [] }, "staking": { "params": { "unbonding_time": "345600s", "max_validators": 92, "max_entries": 10, "historical_entries": 10000, "bond_denom": "boot" }, "last_total_power": "0", "last_validator_powers": [], "validators": [], "delegations": [], "unbonding_delegations": [], "redelegations": [], "exported": false }, "transfer": { "port_id": "transfer", "denom_traces": [], "params": { "send_enabled": false, "receive_enabled": false } }, "upgrade": {}, "vesting": {}, "wasm": { "params": { "code_upload_access": { "permission": "Everybody", "address": "" }, "instantiate_default_permission": "Everybody", "max_wasm_code_size": "1228800" }, "codes": [], "contracts": [], "sequences": [], "gen_msgs": [] } } } ================================================ FILE: networks/bostrom/v3-upgrade-guide.md ================================================ # How to prepare your node for v3 upgrade This guide includes all the steps you need to get ready for the `v3` upgrade in Bostrom. Hereby we assume that you run your node in docker with the cyber ["official"](https://hub.docker.com/layers/cyber/cyberd/cyber/bostrom-1/images/sha256-6383de3e4562690907b0dbb99b752f53ef2d41f44a7d452a903d24397e49911b?context=explore) image, otherwise, this guide will not suit you. ## Step 1: Pull a new docker image The new cyber binary is wrapped in the new docker image, so we have to pull it first: ```js docker pull cyberd/bostrom:v3.0.0-cuda11.4 ``` It may take a few minutes. When complete, check that you have it: ```js docker images ``` ## Step 2: Replace the docker image for the Bostrom container *At this stage you will have to operate quickly to reduce your node downtime, so please read all the sub-steps first!* Stop your docker container with Bostrom: ```js docker stop bostrom ``` Remove Bostrom container (do not worry, files will stay intact): ```js docker rm bostrom ``` Create Bostrom container from new image (note: if you have custom ports set, please adjust accordingly): ```sh docker run -d --gpus all --name=bostrom --restart always -p 26656:26656 -p 26657:26657 -p 1317:1317 -e ALLOW_SEARCH=true -v $HOME/.cyber:/root/.cyber cyberd/bostrom:v3.0.0-cuda11.4 ``` Check logs. Block production should be restored after startup: ```sh docker logs bostrom -f --tail 20 ``` ## Step 3: Verify that everything is OK After the container launch, the new cyber binary should appear inside the `$HOME/.cyber/cosmovisor/` folder. Check that you have a similar folder layout: ```sh cd $HOME/.cyber/cosmovisor/ tree ``` You should have a similar layout of files and folders: ```sh root@node:~/.cyber/cosmovisor# tree . ├── current -> /root/.cyber/cosmovisor/upgrades/cyberfrey ├── genesis │ └── bin │ └── cyber └── upgrades ├── cyberfrey │ ├── bin │ │ └── cyber │ └── upgrade-info.json └── v3 └── bin └── cyber ``` ## You are done! What's next? Now is a good time to go and vote for prop #41. If you haven't done this yet, report that you have completed preparation for the upgrade in our [Hall of Fame](https://t.me/fameofcyber) and chill until the upgrade block 13078000, which should come around 12:00am UTC Wednesday 17.04.2024 ([ping.pub timer](https://ping.pub/bostrom/block/13078000)). What will happen at the block 13078000: - the chain will halt with the message `CONSENSUS FAILURE!!! err="UPGRADE \"v3\" NEEDED at height: 13078000:` - Cosmovisor inside the container will catch this event and change symlink inside `.cyber/cosmovisor/` folder - node will start and as soon as 66%+ of voting power is online, blocks will resume ## Crisis protocol The process of upgrading should go pretty smoothly and should not require any direct action, but in case something goes wrong, cyber devs may consider certain ways to recover. Simply check your node at the time of the upgrade and consult the [Hall of Fame](https://t.me/fameofcyber) chat for possible coordination. ================================================ FILE: networks/bostrom/v4-upgrade-guide.md ================================================ # How to prepare your node for v4 upgrade This guide describes all the steps you need to get ready for the `v4` upgrade in Bostrom. Hereby we assume that you run your node in docker with the cyber ["official"](https://hub.docker.com/layers/cyber/cyberd/cyber/bostrom-1/images/sha256-6383de3e4562690907b0dbb99b752f53ef2d41f44a7d452a903d24397e49911b?context=explore) image, otherwise, this guide will not suit you. ## Step 1: Pull a new docker image & prepare The new cyber binary is wrapped in the new docker image, so we have to pull it first: ```js docker pull cyberd/bostrom:v4.0.0-cuda11.4 ``` It may take a few minutes. When complete, check that you have it: ```js docker images ``` Make sure that in `config/app.toml` you have `minimum-gas-prices` valuet set: ```bash minimum-gas-prices = "0boot" ``` ## Step 2: Replace the docker image for the Bostrom container *At this stage you will have to operate quickly to reduce your node downtime, so please read all the sub-steps first!* Stop your docker container with Bostrom: ```js docker stop bostrom ``` Remove Bostrom container (do not worry, files will stay intact): ```js docker rm bostrom ``` Create Bostrom container from new image (note: if you have custom ports set, please adjust accordingly): ```sh docker run -d --gpus all --name=bostrom --restart always -p 26656:26656 -p 26657:26657 -p 1317:1317 -e ALLOW_SEARCH=true -v $HOME/.cyber:/root/.cyber cyberd/bostrom:v4.0.0-cuda11.4 ``` Check logs. Block production should be restored after startup: ```sh docker logs bostrom -f --tail 20 ``` ## Step 3: Verify that everything is OK After the container launch, the new cyber binary should appear inside the `$HOME/.cyber/cosmovisor/` folder. Check that you have a similar folder layout: ```sh cd $HOME/.cyber/cosmovisor/ tree ``` You should have a similar layout of files and folders: ```sh root@node:~/.cyber/cosmovisor# tree . ├── current -> /root/.cyber/cosmovisor/upgrades/v3 ├── genesis │   └── bin │   └── cyber └── upgrades ├── cyber ├── cyberfrey │   ├── bin │   │   └── cyber │   ├── cyber │   └── upgrade-info.json ├── v3 │   ├── bin │   │   └── cyber │   └── upgrade-info.json └── v4 └── bin └── cyber ``` ## You are done! What's next? Now is a good time to go and vote for prop [#45](https://cyb.ai/senate/45). If you haven't done this yet, report that you have completed preparation for the upgrade in our [Hall of Fame](https://t.me/fameofcyber) and chill until the upgrade block 15515000, which should come around ~9:00am UTC Friday 04.10.2024 ([ping.pub timer](https://ping.pub/bostrom/block/15515000)). What will happen at the block 15515000: - the chain will halt with the message `CONSENSUS FAILURE!!! err="UPGRADE \"v4\" NEEDED at height: 15515000:` - Cosmovisor inside the container will catch this event and change symlink inside `.cyber/cosmovisor/` folder - node will start and as soon as 66%+ of voting power is online, blocks will resume ## Crisis protocol The process of upgrading should go pretty smoothly and should not require any direct action, but in case something goes wrong, cyber devs may consider certain ways to recover. Simply check your node at the time of the upgrade and consult the [Hall of Fame](https://t.me/fameofcyber) chat for possible coordination. ## Note: Keys format upgrade In the v4 release cyber is being updated to the cometbft consensus engine, which leads to keystore migration to the cometbft compatible version. That will mean that after the upgrade and first signed TX using the new version of CLI, the keystore would be migrated and no longer compatible with the old CLI versions. Everything would work smoothly if you use `docker exec -ti bostrom cyber tx ...` for transaction casting, however, if you have CLI installed separately - make sure to upgrade it as well to [v4.0.0](https://github.com/cybercongress/go-cyber/releases/tag/v4.0.0). ================================================ FILE: networks/space-pussy/deploy_node_from_snapshot.md ================================================ # Deploy bostrom node from snapshot ## Download snapshot First, go to [Cyber Snapshot Robot](https://cyb.ai/network/bostrom/contract/bostrom137p3ll78yrlw3gtfltgwhdkz0qxke4z6mt9qe6) page Latest post will show you available snapsot: ![](https://ipfs.io/ipfs/QmWjcgseTj5GmGSC8z1X6wzD5Eh1wQv1RfBfChmafqcwvm) Сlick on the link with the block and you will see two results: ![](https://ipfs.io/ipfs/QmQvZegg39JnQ5EESgA3t9seCYSAF7nZyDZGRo1iUXLemi) We typicaly store only latest snashot, older might be available only in IPFS if someone stored them. The first one is a hash of the current snapshot that can be downloaded directly from ipfs (to use this way, you need an ipfs [client](https://docs.ipfs.tech/install/command-line/) installed) ``` ipfs get --output bostrom_pruned.tar.gz ``` The second hash contains url that can be downloaded directly: ``` wget https://link_from_above ``` ## Unpack snapshot Single thread: ``` tar -xvzf bostrom_pruned_.tar.gz ``` Multiple threads (much faster and require pigz installation): ``` apt install pigz ``` ``` tar -I pigz -xf bostrom_pruned_.tar.gz -C ./ ``` ## Stop Cyber ``` docker stop bostrom ``` ## Remove old data from home directory **Dont forget to use correct path if your node is not in $HOME of your user.** ``` rm -rf ~/.cyber/data ~/.cyber/wasm ``` ## Move unpacked folders into home directory ``` cd bostrom_pruned_ ``` ``` mv data/ ~/.cyber/ ``` ``` mv wasm/ ~/.cyber/ ``` ## Set up your pruning strategy to everything To save the space ont the disk consumed by the node set pruning to everything (lightest one) and set snapshot-interval to 0 in `.cyber/config/app.toml`: ``` pruning = "everything" ``` ``` snapshot-interval = 0 ``` ## Start Cyber container and check logs ``` docker start bostrom ``` ``` docker logs bostrom -f --tail 10 ``` You will see node started sync from the snapshot block. ## When done dont forget to remove folder and archive to save some space ``` rm -rf bostrom_pruned_ bostrom_pruned_.tar.gz ``` ================================================ FILE: networks/space-pussy/genesis-validator.md ================================================ # Setting up space-pussy Genesis Validator This guide will provide detailed instructions on how to submit gentx for the Space-pussy chain! The primary point of communication for the whole gentx and lauch ceremonies will be our [Cyber Hall of Fame](https://t.me/fameofcyber) telegram chat. Some important notices about joining the genesis validator set: 1. **GenTx must be submited by 17:00 UTC 3rd October** 2. We recommend only highly experienced validators who have run on past Cosmos SDK chains and have participated in a genesis ceremony before become genesis validators on Cyber. 3. Being a Genesis validator for a Supercomputer is an honor, so we expect all participants to treat this opportunity accordingly. We want our validators to be pro-active, maintain good uptime, communicate and act professionally during chain upgrades, and respectfully participate in governance. 4. To become a Genesis validator, you must have pussy tokens on your account in Genesis. ## Hardware setup Recommended hardware setup stays the same as it was for the Bostrom: ```js CPU: 6 cores RAM: 32 GB SSD: 1 TB Connection: 50+Mbps, Stable and low-latency connection GPU: Nvidia GeForce (or Tesla/Titan/Quadro) with CUDA-cores; 4+ Gb of video memory* Software: Ubuntu 18.04 LTS / 20.04 LTS ``` The blockchain is always growing. Therefore, in the future, hardware requirements might increase. Also, the specs above are not mandatory and may differ, but it always implies that the node might be powerful and reliable. ## Instructions All instructions provided are for the Ubuntu 20.04 system and may vary for other versions\OS. ### Install GO 1.17+ Cyber is written in `go`, and we'll need the version 1.17+ to compile it. Check which version you currently have with ```bash go version ``` If you need to update or install 'go' we'd recommend to use the handy go version manager called [g](https://github.com/stefanmaric/g). To install 'go' with it use: ```bash curl -sSL https://git.io/g-install | sh -s source ~/.bashrc ``` Agree to install latest version, or manually install specific version: ```bash g install 1.19.1 g set 1.19.1 go version ``` You might see something like that: ```bash go version go1.19.1 linux/amd64 ``` ### Install pussy Download source files from github: ```bash git clone https://github.com/joinresistance/space-pussy.git cd space-pussy ``` Then install `pussy` daemon. Running the following command will install the executable pussy to your GOPATH: ```bash make install CUDA_ENABLED=false ``` If your `pussy` version does not match - please verify that you dont have any other daemons laying somewhere else in `/usr/local/bin`. ### Initialize your node Before you proceed verify that you don't have any old\test nodes initialized in that machine, check and remove folders inside `~/.pussy/`. If you have the testnet node running, stop it and remove `~/.pussy/` folder (do not forget to backup your seeds before you remove anything): ```bash ls -la ~/ rm -rf .pussy/ ``` Then run the following to init fresh one(replace with something, for example `web2_destroyer`): ```bash pussy init ``` This will create a new `.pussy` folder in your HOME directory. ### Download Pre-genesis File You can now download the "pregenesis" file for the chain. This is a genesis file with the chain-id and all balances. ```sh cd $HOME/.pussy/config/ wget -O $HOME/.pussy/config/genesis.json https://raw.githubusercontent.com/joinresistance/networks/main/space-pussy/unsigned-genesis.json ``` ### Import Validator Key To create a gentx, you will need the private key to an address that has some tokens in Genesis. There are a couple options for how to import a key into `pussy`. You can import such a key into via a mnemonic or add one from the Ledger. ```bash pussy keys add --recover ``` You could use your **ledger** device with the Cosmos app installed on it to sign transactions. Add address from Ledger: ```bash pussy keys add --ledger ``` **** is any name you pick to represent this key pair. You have to refer to that name later when you use cli to sign transactions. *Note* If you got an error saying ```js Error: No such interface “org.freedesktop.DBus.Properties” on object at path / ``` during key import, please use file keyring with all cli key commands: ```bash pussy keys add --recover --keyring-backend file ``` ### Create GenTx Now that you have your key imported you are able to use it to create your gentx. To create the Genesis transaction, you will have to choose the following parameters for your validator: - moniker - commission-rate - commission-max-rate - commission-max-change-rate - min-self-delegation (must be >10000pussy) - website (optional) - details (optional) - identity (keybase key hash, this is used to get validator logos in block explorers. optional) - pubkey (will be pulled automatically) Note that your gentx will be rejected if you use an amount greater than what you have on you balance in Genesis. An example Genesis command would look like this: ```bash pussy gentx 1000000000000pussy \ --min-self-delegation "1000000000" \ --pubkey=$(pussy tendermint show-validator) \ --moniker= \ --commission-rate="0.05" \ --commission-max-rate="0.10" \ --commission-max-change-rate="0.01" \ --chain-id=space-pussy ``` *add `--keyring-backend file` if you used it during key import.* Output will look similar to this: ```sh Genesis transaction written to "/root/.pussy/config/gentx/gentx-445e04520cef1116faab9900e2edadcb8164477c.json" ``` File content must look similar to this [sample-gentx](https://github.com/joinresistance/networks/blob/main/space-pussy/gentxs/gentx-SAMPLE.json) ### Submit Your GenTx To submit your GenTx for inclusion in the chain, please upload it to the [[github.com/joinresistance/networks](https://github.com/joinresistance/networks)](https://github.com/joinresistance/networks/blob/main/space-pussy/gentxs) repo by `18:00 UTC 3rd October`. To upload the your Genesis file, please follow these steps: 1. Rename the gentx file located in your `$HOME/.pussy/config/gentx/` to gentx-{your-moniker}.json (please do not put any spaces or special characters in the file name) 2. Fork this repo by going to https://github.com/joinresistance/networks, clicking on fork, and choose your account (if multiple). 3. Clone your copy of the fork to your local machine ```sh git clone https://github.com//networks ``` 4. Copy the gentx to the networks repo (ensure that it is in the correct folder) ```sh cp ~/.pussy/config/gentx/gentx-.json networks/space-pussy/gentxs/ ``` 5. Commit and push to your repo. ```sh cd networks git add space-pussy/gentxs/* git commit -m " gentx" git push origin master ``` 6. Create a pull request from your fork to master on this repo. 7. Let us know in [Cyber Hall of Fame](https://t.me/fameofcyber) when you've completed this process! 8. Stay tuned, further steps will be provided soon! ### Back-up validator keys (!) Your identity as validator consists of two things: - your account (to sign transactions) - your validator private key (to sign stuff on the chain consensus layer) Please back up `$HOME/.pussy/config/priv_validator_key.json` along with your seed phrase. In case of occasional folder loss you would be able to restore you validator. Those things should not be changed, otherwise, your validator won't start on Genesis. ## Prepare node for chain start Ok, so here is it, the final genesis for the space-pussy `TBA`. Now only a few steps left to finalize the validator node setup for space-pussy launch: - Clear out old containers - Download final genesis, and place it to working directory `$HOME/.cyber` - Pull and deploy new Docker container - Configure persistent peers, seeds, and some other stuff from `config.toml` - Verify the correctness of the keys and files on the node ### Obtain signed genesis file Hereby we mean that you already have your pussy node initialized in $HOME directory. Remove pre-genesis from .pussy: ```bash rm $HOME/.pussy/config/genesis.json ``` Download genesis file for space-pussy: ```bash wget -O $HOME/.pussy/config/genesis.json https://gateway.ipfs.cybernode.ai/ipfs/TBA ``` Also, it is **required** to remove old chain data and reset the home directory to state of signed genesis: ```bash pussy tendermint unsafe-reset-all --home $HOME/.pussy/ ``` ### Deploy docker container To pull and deploy docker container for the `space-pussy` chain use the following command: ```bash docker run -d --gpus all --name=space-pussy --restart always -p 26656:26656 -p 26657:26657 -p 1317:1317 -e ALLOW_SEARCH=true -e COMPUTE_GPU=true -v $HOME/.pussy:/root/.pussy cyberd/space-pussy:v0.0.1-cuda11.4 ``` ### Setup config.toml Add correct seeds and persistent peers nodes. You may find some [here](https://github.com/joinresistance/networks/blob/main/space-pussy/peers.md) Insert them into lines 185 and 188 of $HOME/.pussy/config/config.toml: ```bash nano $HOME/.pussy/config/config.toml ``` ```bash # Comma separated list of seed nodes to connect to seeds = "" # Comma separated list of nodes to keep persistent connections to persistent_peers = "" ``` For better network stability please update your `.pussy/config/config.toml` lines as follows: ``` addr_book_strict = false max_num_inbound_peers = 100 max_num_outbound_peers = 80 persistent_peers_max_dial_period = "500s" ``` ## Launch When all above are checked and completed please go ahead and restart the container: ```bash docker restart space-pussy ``` Check the logs. ```bash docker logs space-pussy ``` They have to contain the following: ```bash 1:42AM INF Starting Node service impl=Node 1:42AM INF Genesis time is in the future. Sleeping until then... genTime=2022-09-03T22:55:42Z ``` If you got that message - congrats, you set everything up! The chain will start at `3rd October 19:55UTC`. Please track [Cyber Hall of Fame](https://t.me/fameofcyber) telegram chat, all coordination will be done there. ================================================ FILE: networks/space-pussy/genesis.json ================================================ { "genesis_time": "2022-10-03T19:55:00Z", "chain_id": "space-pussy", "initial_height": "1", "consensus_params": { "block": { "max_bytes": "4194304", "max_gas": "25000000", "time_iota_ms": "1000" }, "evidence": { "max_age_num_blocks": "100000", "max_age_duration": "172800000000000", "max_bytes": "1048576" }, "validator": { "pub_key_types": [ "ed25519" ] }, "version": {} }, "app_hash": "", "app_state": { "auth": { "params": { "max_memo_characters": "1024", "tx_sig_limit": "7", "tx_size_cost_per_byte": "20", "sig_verify_cost_ed25519": "590", "sig_verify_cost_secp256k1": "1000" }, "accounts": [ { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1d8754xqa9245pctlfcyv8eah468neqznm33fvz", "pub_key": null, "account_number": "0", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1gxhs5wzam5rlgf6cs0lkme400ut64d4njdhaf7", "pub_key": null, "account_number": "1", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1j3w0aa7s6665puyls9lwx9ej6cz2afysuy0v80", "pub_key": null, "account_number": "2", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy13hepw93y8mjcew7mfra5z7ju7k658534dpd39u", "pub_key": null, "account_number": "3", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1m5rf5fvhrl76s3xkvh3kde0p4dpwzewurch92s", "pub_key": null, "account_number": "4", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1gdpk4xeyeqzdkdwc0c2zrd8ltrthnze3a42c0n", "pub_key": null, "account_number": "5", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1zaefvwrgk2g45k68a3ngahgq0xky5zged294fr", "pub_key": null, "account_number": "6", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1ke3aflev7cr75gxa54k6qwrajfc53vqh4yfjj0", "pub_key": null, "account_number": "7", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1e8238v24qccht9mqc2w0r4luq462yxttjjv5pq", "pub_key": null, "account_number": "8", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1956s252r7du0jfeskaauep4lm6a9wn2pktntq0", "pub_key": null, "account_number": "9", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1r28nhrkwcvqs4qss2l7zqdvc2qfdl8ar6f4gqe", "pub_key": null, "account_number": "10", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy12kpw3e9ypjal6upmju9smwgjhwefpt7v0smhkt", "pub_key": null, "account_number": "11", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1qkw8dtdansmvayk2jxfkpel9q4d20rvfazxykl", "pub_key": null, "account_number": "12", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1rj7zt2pzuzwhjlr24u0prnqqxm3xexavpd7xp0", "pub_key": null, "account_number": "13", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy17zdyl3gfssc3vzzyxptnr0xl8z0pnte9a8zjjx", "pub_key": null, "account_number": "14", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1vg8lh3dsp7023kz79mlk642dux9vu038pmp4ma", "pub_key": null, "account_number": "15", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy10trdf5eyfcmc9graltx4hmpgznhrm7hdgt5mf6", "pub_key": null, "account_number": "16", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1v46pz6ddetfc3tnvdr28ss0l48jhazgyeqlumh", "pub_key": null, "account_number": "17", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1fnwevu5z89qd5tx6qdpfxh6u3dttc6kc6hfa9y", "pub_key": null, "account_number": "18", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy14hrqklee0tx6asycyfj357keql2jr5rdq9h34a", "pub_key": null, "account_number": "19", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1r8d26xgfxr80v3slu8r6z7wkl4h7f99qa4hhqg", "pub_key": null, "account_number": "20", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1r7q209q5yeh9d37pftdsm2eqtrl45ry8lmrfet", "pub_key": null, "account_number": "21", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy13jnp8uk4xnqcvdejcnq9rphm9actc90pf2r4ka", "pub_key": null, "account_number": "22", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1hyrtrdqnayvvtznddczjymjcj2jagcqugfp2rl", "pub_key": null, "account_number": "23", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1kfqme88c6vq8mt0smw29z67k4zz2ykr6km5rck", "pub_key": null, "account_number": "24", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1u2kvnwxmmpru764l5ht3nxkfwwu6ytw4s3zzsr", "pub_key": null, "account_number": "25", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1d59yxkz9uem873a3nyt5j379hsa7tjpvej0xfh", "pub_key": null, "account_number": "26", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1uynj0jhl059u9t5h4ug9075jrepdz4cwasmeqa", "pub_key": null, "account_number": "27", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy14fwr9m4rf27r3txv5luvph98nrckyu2qkfsn0f", "pub_key": null, "account_number": "28", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1n8hu3cqsn3txf0ltdk3x0sff2s0yt96xyffz3m", "pub_key": null, "account_number": "29", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1p5sudrdkr9r8a84s7fh27tkhdrhujhqatztfqf", "pub_key": null, "account_number": "30", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1p74unan6vpp9frdcz2nhv8z59jx295njwzfmc0", "pub_key": null, "account_number": "31", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1jxzpz4ggqefs5ps7veupd8zfy5a62cgyrm7rr8", "pub_key": null, "account_number": "32", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1ezpth4mp3eeqdt49kgqd5ctr69xev6v2zggvl2", "pub_key": null, "account_number": "33", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1wm4026rxqcrkh09k806m6y4lys942etx75v0xt", "pub_key": null, "account_number": "34", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1gwlqmqc9nrnuu8fanls76exyrzum9xjmdtlgnl", "pub_key": null, "account_number": "35", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1ezqvp6aga74ms7jqrfwhrm7266sn2m50afvapg", "pub_key": null, "account_number": "36", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1cwu6g93hnfm44zyl8cnkn58dsakxh2ac49m8c3", "pub_key": null, "account_number": "37", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1rxdzc0c80u9wympy8sgmx32ra0df5dztx0v7xh", "pub_key": null, "account_number": "38", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy10jmsqhf7mwquv0wa08hegxqaasvue5tnn7wn79", "pub_key": null, "account_number": "39", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1m0tjgkrh4td9fcp8nnssu3rfdahzfgdsaurjuv", "pub_key": null, "account_number": "40", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1g65rmjkeuy5rywx04s4fvwfylmlz98vq87mdq7", "pub_key": null, "account_number": "41", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.ModuleAccount", "base_account": { "account_number": "42", "address": "pussy1jv65s3grqf6v6jl3dp4t6c9t9rk99cd8wqwz53", "pub_key": null, "sequence": "0" }, "name": "distribution", "permissions": [] } ] }, "authz": { "authorization": [] }, "bandwidth": { "params": { "recovery_period": "16000", "adjust_price_period": "5", "base_price": "0.250000000000000000", "max_block_bandwidth": "25000", "base_load": "0.100000000000000000" } }, "bank": { "params": { "send_enabled": [], "default_send_enabled": true }, "balances": [ { "address": "pussy1d8754xqa9245pctlfcyv8eah468neqznm33fvz", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1gxhs5wzam5rlgf6cs0lkme400ut64d4njdhaf7", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1j3w0aa7s6665puyls9lwx9ej6cz2afysuy0v80", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy13hepw93y8mjcew7mfra5z7ju7k658534dpd39u", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1m5rf5fvhrl76s3xkvh3kde0p4dpwzewurch92s", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1gdpk4xeyeqzdkdwc0c2zrd8ltrthnze3a42c0n", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1zaefvwrgk2g45k68a3ngahgq0xky5zged294fr", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1ke3aflev7cr75gxa54k6qwrajfc53vqh4yfjj0", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1e8238v24qccht9mqc2w0r4luq462yxttjjv5pq", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1956s252r7du0jfeskaauep4lm6a9wn2pktntq0", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1r28nhrkwcvqs4qss2l7zqdvc2qfdl8ar6f4gqe", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy12kpw3e9ypjal6upmju9smwgjhwefpt7v0smhkt", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1qkw8dtdansmvayk2jxfkpel9q4d20rvfazxykl", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1rj7zt2pzuzwhjlr24u0prnqqxm3xexavpd7xp0", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy17zdyl3gfssc3vzzyxptnr0xl8z0pnte9a8zjjx", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1vg8lh3dsp7023kz79mlk642dux9vu038pmp4ma", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy10trdf5eyfcmc9graltx4hmpgznhrm7hdgt5mf6", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1v46pz6ddetfc3tnvdr28ss0l48jhazgyeqlumh", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1fnwevu5z89qd5tx6qdpfxh6u3dttc6kc6hfa9y", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy14hrqklee0tx6asycyfj357keql2jr5rdq9h34a", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1r8d26xgfxr80v3slu8r6z7wkl4h7f99qa4hhqg", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1r7q209q5yeh9d37pftdsm2eqtrl45ry8lmrfet", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy13jnp8uk4xnqcvdejcnq9rphm9actc90pf2r4ka", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1hyrtrdqnayvvtznddczjymjcj2jagcqugfp2rl", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1kfqme88c6vq8mt0smw29z67k4zz2ykr6km5rck", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1u2kvnwxmmpru764l5ht3nxkfwwu6ytw4s3zzsr", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1d59yxkz9uem873a3nyt5j379hsa7tjpvej0xfh", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1uynj0jhl059u9t5h4ug9075jrepdz4cwasmeqa", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy14fwr9m4rf27r3txv5luvph98nrckyu2qkfsn0f", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1n8hu3cqsn3txf0ltdk3x0sff2s0yt96xyffz3m", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1p5sudrdkr9r8a84s7fh27tkhdrhujhqatztfqf", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1p74unan6vpp9frdcz2nhv8z59jx295njwzfmc0", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1jxzpz4ggqefs5ps7veupd8zfy5a62cgyrm7rr8", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1ezpth4mp3eeqdt49kgqd5ctr69xev6v2zggvl2", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1wm4026rxqcrkh09k806m6y4lys942etx75v0xt", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1gwlqmqc9nrnuu8fanls76exyrzum9xjmdtlgnl", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1ezqvp6aga74ms7jqrfwhrm7266sn2m50afvapg", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1cwu6g93hnfm44zyl8cnkn58dsakxh2ac49m8c3", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1rxdzc0c80u9wympy8sgmx32ra0df5dztx0v7xh", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy10jmsqhf7mwquv0wa08hegxqaasvue5tnn7wn79", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1m0tjgkrh4td9fcp8nnssu3rfdahzfgdsaurjuv", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1g65rmjkeuy5rywx04s4fvwfylmlz98vq87mdq7", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1jv65s3grqf6v6jl3dp4t6c9t9rk99cd8wqwz53", "coins": [ { "amount": "958000000000000000", "denom": "pussy" } ] } ], "supply": [ { "amount": "1000000000000000000", "denom": "pussy" } ], "denom_metadata": [ { "description": "The staking token of space-pussy", "base": "pussy", "display": "pussy", "name": "Pussy token", "symbol": "PUSSY", "denom_units": [ { "denom": "pussy", "exponent": 0, "aliases": [ "PUSSY" ] } ] }, { "description": "The liquid staking token of Space-pussy", "base": "liquidpussy", "display": "liquidpussy", "name": "liquidpussy", "symbol": "LIQUIDPUSSY", "denom_units": [ { "denom": "liquidpussy", "exponent": 0, "aliases": [ "LIQUIDPUSSY" ] } ] }, { "description": "The power token of Space-pussy", "base": "milliampere", "display": "ampere", "name": "Space-pussy Ampere", "symbol": "AMPERE", "denom_units": [ { "denom": "milliampere", "exponent": 0, "aliases": [] }, { "denom": "ampere", "exponent": 3, "aliases": [ "AMPERE" ] } ] }, { "description": "The bandwidth token of Space-pussy", "base": "millivolt", "display": "volt", "name": "Space-pussy Volt", "symbol": "VOLT", "denom_units": [ { "denom": "millivolt", "exponent": 0, "aliases": [] }, { "denom": "volt", "exponent": 3, "aliases": [ "VOLT" ] } ] } ] }, "capability": { "index": "1", "owners": [] }, "crisis": { "constant_fee": { "denom": "pussy", "amount": "10000000" } }, "cyberbank": null, "distribution": { "params": { "community_tax": "0.000000000000000000", "base_proposer_reward": "0.010000000000000000", "bonus_proposer_reward": "0.030000000000000000", "withdraw_addr_enabled": true }, "fee_pool": { "community_pool": [ { "amount": "958000000000000000", "denom": "pussy" } ] }, "delegator_withdraw_infos": [], "previous_proposer": "", "outstanding_rewards": [], "validator_accumulated_commissions": [], "validator_historical_rewards": [], "validator_current_rewards": [], "delegator_starting_infos": [], "validator_slash_events": [] }, "dmn": { "params": { "max_slots": 4, "max_gas": 2500000, "fee_ttl": 50 } }, "evidence": { "evidence": [] }, "feegrant": { "allowances": [] }, "genutil": { "gen_txs": [ { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "Bloqhub", "identity": "", "website": "", "security_contact": "", "details": "" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.100000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "pussy1p5sudrdkr9r8a84s7fh27tkhdrhujhqatztfqf", "validator_address": "pussyvaloper1p5sudrdkr9r8a84s7fh27tkhdrhujhqau8du7t", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "dfy2Tjb24fytmLaTIqMRigVfwh7mX4gr2C3prhcBPd0=" }, "value": { "denom": "pussy", "amount": "1000000000000" } } ], "memo": "4913a219c47a83f843ec4be9d9440e96ca8eee92@192.167.254.10:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "A+k17mb2lLGBARPZ14gHuefCdUxn30ZLlsRrSVSxyzSf" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "OYred5zZU2KnUiVMtzB6Px9dGUTfc993VUay9+0CjlkstllhrRYQtl7NK7KIQB5uqEeqFu6V35LFlKpvkMv9Yg==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "Citizen Cosmos", "identity": "DF0280597A20ACFE", "website": "www.citizencosmos.space", "security_contact": "", "details": "Citizen Cosmos is a web3 brand and podcast" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.200000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "10000000000", "delegator_address": "pussy1uynj0jhl059u9t5h4ug9075jrepdz4cwasmeqa", "validator_address": "pussyvaloper1uynj0jhl059u9t5h4ug9075jrepdz4cw24av7l", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "gylED9s/yfWjaPUAsFUAQBVfZoYDTk8X+L0EjREk7l0=" }, "value": { "denom": "pussy", "amount": "850000000000000" } } ], "memo": "66eabcb6639163be65bdf88cde11732b9fe0a63c@195.201.81.239:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "ArhPmoTf9ioffBMf0WpkkuBKnv7vg0y7dRB1bbyzIwuL" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "SurtRcNVHVwlDYWaFeylQPA8dQLQD8PrBdSDnvEjW3ss/jEA5mK98NVdN+b353uGlwdOv7RioZaqB5i/0lCIFg==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "Developer", "identity": "", "website": "", "security_contact": "", "details": "" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.200000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "pussy1hyrtrdqnayvvtznddczjymjcj2jagcqugfp2rl", "validator_address": "pussyvaloper1hyrtrdqnayvvtznddczjymjcj2jagcqulv8laa", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "/unHhQAqM3i1KJ59PT0D5MEBJAmytPv8cutOhrPVQAg=" }, "value": { "denom": "pussy", "amount": "1000000000000" } } ], "memo": "6590ffaadab0384de9062bb5fa49ff5fb8d995a7@176.100.3.51:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "AtqUTtRprpb9K7bhAg1k24RKmkfab0wpZOiCfnZuOBi7" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "ucRhfid7DINBaCZzYhoZ0sPHAckFys5EPB3OoiQ3X7InkzQQwui77ZEQJsDlMTeHtrFvPm0vhOOzgeP5jh0h3A==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "Kerman", "identity": "", "website": "", "security_contact": "", "details": "" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.200000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "pussy1u2kvnwxmmpru764l5ht3nxkfwwu6ytw4s3zzsr", "validator_address": "pussyvaloper1u2kvnwxmmpru764l5ht3nxkfwwu6ytw485yhwp", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "k2FA9IN6wJTjF3MHUNy04IUUwhh3ssTHz7eOFM0CLuM=" }, "value": { "denom": "pussy", "amount": "1000000000000" } } ], "memo": "890bc056e5f5faaa0efa7fe55a72af09e45b398d@185.230.90.71:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "AimwqRc63WjLVIInJMb/X+IQq31ZG08CvqwEGjsTP8iC" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "t3y7E1He8WPNAkHZNMYRBwTKFv7eHFYXjMPlYSZVKg0/nYltESBZlxgemrzcMt7IO8yJiNxEU5Uw9pp2r6E5+w==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "MikeLitoris", "identity": "", "website": "", "security_contact": "", "details": "" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.100000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "pussy1rxdzc0c80u9wympy8sgmx32ra0df5dztx0v7xh", "validator_address": "pussyvaloper1rxdzc0c80u9wympy8sgmx32ra0df5dzt322tc4", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "Ed+EBKPAgjZhyG2uhcHDXEFpocSUpPpyJb5qLvhRfr4=" }, "value": { "denom": "pussy", "amount": "1000000000000" } } ], "memo": "ba5af23f90706c80230df6db9c2fa42e11678d54@167.235.150.1:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "As00LA0oJPNpisW/RdUboX1kGxN2l93PPyEpTdDu7vIO" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "RRYQJQFkTTwH/KjOBL+SY+hJSsgOpC6sE8F8izwzCoNoAgbPELTi3SoMfFABSB7dTOFdUKJamILl2TOtmfgrVQ==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "POSTHUMAN ꝏ DVS", "identity": "8A9FC930E1A980D6", "website": "https://posthuman.digital", "security_contact": "validator@posthuman.digital", "details": "100% refund in case of slashing ⚛️ MEꝏWE 🤲 Part of the profits goes to charity" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.100000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "pussy1e8238v24qccht9mqc2w0r4luq462yxttjjv5pq", "validator_address": "pussyvaloper1e8238v24qccht9mqc2w0r4luq462yxtt9h2plz", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "zEBYTxQrRDumdM1stwnTay9z52VkGh3iYIUIa+XPObU=" }, "value": { "denom": "pussy", "amount": "1000000000000" } } ], "memo": "c349c49922435fc0cfdf02ac51548be989fbd102@142.132.253.246:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "A+rHQzOD96xTzMUmBsuOCo7rbm5a4dEMA0bJJdhtXHDT" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "5GQwYr4ZwgSvRzlJ3xdBQ3p40mVShld0opOEjDzwz3hWouYojXUg/0OmN135sbosgNsRSiIpDW5e26H2W5QdHg==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "Papsan", "identity": "C3AAAE53B3BDAC3F", "website": "", "security_contact": "", "details": "" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.100000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "pussy1r7q209q5yeh9d37pftdsm2eqtrl45ry8lmrfet", "validator_address": "pussyvaloper1r7q209q5yeh9d37pftdsm2eqtrl45ry8g79u8f", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "cMynSZRzuNCrMFOenCcrkhldpIy3hfC6mOjBgmXmlpA=" }, "value": { "denom": "pussy", "amount": "1000000000000" } } ], "memo": "81f9706d4e9357e45bb2bafd4486b66ac6e58451@185.230.90.202:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "AvywWdD4SyRXjRvDZovKcEGxIUEJjHTjut0fingxl61X" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "XoTfuQy9+KYtW6FTQ/kGOP4pqNzT//9dlgSD+P6RDENKwFnTMGyDZSEx3WFOuKuYix6YEx/zntz/ENDkwBr3WQ==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "Stigga", "identity": "8A41E5318619A3ED", "website": "https://stigga.org/", "security_contact": "", "details": "Individual PoS validator in Cosmos Hub Ecosystem chains, Discord:alexmed#5188" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.100000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "pussy12kpw3e9ypjal6upmju9smwgjhwefpt7v0smhkt", "validator_address": "pussyvaloper12kpw3e9ypjal6upmju9smwgjhwefpt7vc4azgf", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "bNjOAI/PiehyuwYz+lCQDPpcrjlAF2i3Yvb3OSdmYAo=" }, "value": { "denom": "pussy", "amount": "1000000000000" } } ], "memo": "e932305e9a36c9423c1a38ebf408e250d0ddb5f7@89.38.97.150:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "A+2iJ2ufEo3cALGyEq8humzARIZk/G0WzdvmbEcjwUP0" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "1tY74vvbD7+ewFyrbp8kh1Z2PXzwz8I3zz1pqgh8/QoLMKLvOMvtiqGqFACBMjvOpuKYtYuMUAwrJZ4hVMHkFg==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "ToTheMars", "identity": "", "website": "", "security_contact": "", "details": "" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.100000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "pussy1vg8lh3dsp7023kz79mlk642dux9vu038pmp4ma", "validator_address": "pussyvaloper1vg8lh3dsp7023kz79mlk642dux9vu038k78q9l", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "fuRnTyscip2Lp29YngUSqhzqFuUYt//BhVKMdChqQno=" }, "value": { "denom": "pussy", "amount": "1000000000000" } } ], "memo": "a012320ef30581df99f505c449a4c42a0490e9a6@192.168.0.248:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "Ar1A0LR8koZLzQhovHBHVQ0XsWMDIL+NuA2VWfuHmYWp" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "ka2M/eQO3f0NpAqiXTei8tFi0O3eI8IIxkePC+CIdj5AzERAxCtRTnLC4H9OEMUkGWWoWE0Ysv3YEGdZVkbU9g==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "Bro_n_Bro", "identity": "A57DAB9B09C7215D", "website": "bronbro.io", "security_contact": "", "details": "" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.200000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "100000000000", "delegator_address": "pussy1j3w0aa7s6665puyls9lwx9ej6cz2afysuy0v80", "validator_address": "pussyvaloper1j3w0aa7s6665puyls9lwx9ej6cz2afystpfeed", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "evJq4xH5kUwUa4yy74j7nAd6qFHLTfSm5NwqJlSLYCE=" }, "value": { "denom": "pussy", "amount": "850000000000000" } } ], "memo": "2e51205853f88048ac2ccb0b830960bbead14996@93.159.133.250:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "AhHVVko1tNyG8GVIjpzBL/E1f1K+1dQ5ItheZLTkNLNz" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "1WKvnWn5iGXKcGxmKU9CEeJHGp8q1lfKcJv9hJvsB8or5OGb/N7acc117yIMIE7kWt6IuNfO2IiPtSIrpxh7nw==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "ChainManiacs | Real Solar\u0026Wind validator", "identity": "", "website": "", "security_contact": "", "details": "" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.100000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "pussy14fwr9m4rf27r3txv5luvph98nrckyu2qkfsn0f", "validator_address": "pussyvaloper14fwr9m4rf27r3txv5luvph98nrckyu2qpvkx3t", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "3x+1Cab1diHNXd2yXYRQ/b2hIA/iAqqyWDonG6mg9+o=" }, "value": { "denom": "pussy", "amount": "1000000000000" } } ], "memo": "59ab923bee54f5815b591d1d3d312931a3d4e89a@192.167.254.10:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "A99rSpuMJoCXa603FCfC8gqffxilbKZwAI30ygly5kwl" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "xtpx8B7rtTzgNGYSlTpCKU+JAdojbOAuA2eOXD+t7odem6l+AbQ67sc6PqKvt98yvwXwyJBgxFM351nYDBxoYw==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "cyberG", "identity": "", "website": "", "security_contact": "", "details": "" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.100000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "pussy17zdyl3gfssc3vzzyxptnr0xl8z0pnte9a8zjjx", "validator_address": "pussyvaloper17zdyl3gfssc3vzzyxptnr0xl8z0pnte92zy8vy", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "mH49uKT67SY4ODuXUGkqbKMYjZxzHc+UI6QbNGqWI+Y=" }, "value": { "denom": "pussy", "amount": "1000000000000" } } ], "memo": "472e953f82e3993614b93635307ca503b7fad812@192.168.0.188:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "A8HHUcU41AdJWAVryBu/fD7SG6s+3My2OPelPlLBHeWe" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "3neewRTs3pwwGtXinK+BMJ/TVMAxR8zf1Hgq5o/5tBgXUQBSBtTaHE73/gmMkmxqEJx2gFomX+zVW512O22yHQ==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "Denwer", "identity": "", "website": "", "security_contact": "", "details": "" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.100000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "pussy1n8hu3cqsn3txf0ltdk3x0sff2s0yt96xyffz3m", "validator_address": "pussyvaloper1n8hu3cqsn3txf0ltdk3x0sff2s0yt96xnv0h0e", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "HPovYK9BjXDpC/NUTdRufVpfCB23ewveyE7X8vHxUsg=" }, "value": { "denom": "pussy", "amount": "1000000000000" } } ], "memo": "a0b15d6721d13a91ce368b56cdad9991c76d4c86@46.211.3.216:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "AlsigW11Iogtfe1wf2NPbLR3qWMTVPLA5cOm9hCyW1Ro" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "R1dkYmTnOwAoHF0zABktAXnE4fiBJ7sJ2fUk0jYoaiQwdQ/z1TSWDnX8jk2F5WxtXnd0/9eAIjuCaAmAKnSJhA==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "goto5k", "identity": "1B0142FC46D30561", "website": "https://goto5k.com", "security_contact": "", "details": "Independent validator. Ambassador." }, "commission": { "rate": "0.100000000000000000", "max_rate": "0.100000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "pussy10trdf5eyfcmc9graltx4hmpgznhrm7hdgt5mf6", "validator_address": "pussyvaloper10trdf5eyfcmc9graltx4hmpgznhrm7hdlwjwhc", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "YPe0JNydv1qJDlvvGapbQxaRFp/rFswW0w3PdvKuaBw=" }, "value": { "denom": "pussy", "amount": "1000000000000" } } ], "memo": "659189a8e378833332ffd61f3495443359fb52a0@192.168.100.4:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "A2y3DqIjyeTqoFiojpJh5eJmLxcROK/zw3fOVj87KvVf" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "+IJUBzJisyJUFfP3kDmldQL85Ols8T2Ri3cOGmm4DSFY00E7XEgykHX3YLFxAPB/wS18NAScqM/07yANQJFzjg==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "Joy prophet", "identity": "", "website": "", "security_contact": "", "details": "" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.100000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "pussy14hrqklee0tx6asycyfj357keql2jr5rdq9h34a", "validator_address": "pussyvaloper14hrqklee0tx6asycyfj357keql2jr5rdhq3ytl", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "jSKJDVC/AGr6D+nnmdhMe+zmPinqrEMSlSsYja0FB7w=" }, "value": { "denom": "pussy", "amount": "1000000000000" } } ], "memo": "178f1f4f430d1052c78ab12a5132f37b5d2c654d@172.19.219.100:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "Aw5AOC6ECe3PnVisdqXhw65gPj8rDL68oyBmkI5a57la" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "KPsZI03UmKY8uovSr3NQ5EEAa+fwjCf4Yys6LOjwXl0/xiBOKFDptqWCK5XqQjClhaj/RVv7zHEU6/iUAJSppA==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "linak", "identity": "6F961E9B32E722ED", "website": "", "security_contact": "", "details": "" }, "commission": { "rate": "0.100000000000000000", "max_rate": "0.100000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "pussy1v46pz6ddetfc3tnvdr28ss0l48jhazgyeqlumh", "validator_address": "pussyvaloper1v46pz6ddetfc3tnvdr28ss0l48jhazgyw9ef94", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "lAPc3XVbfWl+WhIxup6ReXQ90UhQyKYi6yCUnvVv6L4=" }, "value": { "denom": "pussy", "amount": "1000000000000" } } ], "memo": "4d8e240bf3a4d3a13f627e1aba2ca0fffa8a1cd7@185.242.112.3:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "A6xdxbJ47TzrUdGG8SoVi/jPUH7x+x7jK5nlb3af+ILy" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "N0ll3hrLTFHbLFnriCCtZNcm/k3HJVdVSjpxuSEjFnYpOpaF8+uehIVsQfNTwbobatoAf10Iq+RldVrOpDZsyQ==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "lux8.net", "identity": "EBBAB54C972A579A", "website": "https://lux8.net", "security_contact": "", "details": "Fiat Lux. Infinite Lux." }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.100000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "pussy1m0tjgkrh4td9fcp8nnssu3rfdahzfgdsaurjuv", "validator_address": "pussyvaloper1m0tjgkrh4td9fcp8nnssu3rfdahzfgds2e98zw", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "zaSRRntTmScRxBexrH3Tjfsa23yulZ3iUdN4yHBoJt0=" }, "value": { "denom": "pussy", "amount": "1000000000000" } } ], "memo": "3630247f32b5b363825027546cbbaa27b2ee8886@194.190.169.129:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "AleLx6VDXm7sVYlwUwXCRpFMYKzIDaWuCVcXH5I0qji1" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "qztwtzDxA+p/4ZXMjBZMgScFsUbb5Q+u+7IE8Sfrj4g3fElhLRwmfatI1pyKOISQtF6MjYZBMDwPEkNMaqk0KQ==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "space", "identity": "B80D9AB4E8981B6A", "website": "", "security_contact": "andfat#4230", "details": "" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.200000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "pussy1kfqme88c6vq8mt0smw29z67k4zz2ykr6km5rck", "validator_address": "pussyvaloper1kfqme88c6vq8mt0smw29z67k4zz2ykr6p7jkx5", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "cElo/7UWLQYVKpqjHuyeDas1DKrS6D87jooPjjB4RSs=" }, "value": { "denom": "pussy", "amount": "1000000000000" } } ], "memo": "3d11aee6b074c4293d60fca7dfb1b12172a60fa3@88.218.191.78:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "A5cZnI4Nt6B8HGkkYarRt2/SIlETX/urxNHwYscYhwQK" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "I753eO+EW+HL34Unak35+jdPu3Ypv9uAcni5qrLx0NkeKBfThKno51soo2EcI87GARR00XaQqBlmRA/dh5r3fA==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "web34ever", "identity": "52D7E9C59B92F133", "website": "https://web3validator.info", "security_contact": "", "details": "" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.100000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "pussy1r8d26xgfxr80v3slu8r6z7wkl4h7f99qa4hhqg", "validator_address": "pussyvaloper1r8d26xgfxr80v3slu8r6z7wkl4h7f99q2s3z72", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "KDEt7qRMgauk8PosX+iB4l1ZJh4nuSPRFX6jqU16kuo=" }, "value": { "denom": "pussy", "amount": "1000000000000" } } ], "memo": "e2c4ea781c86ace81e895ac8a2c60f215138ed0f@88.218.191.79:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "Aoc7SC9kMjYyJCWL9SAvEbaTu9uPTz9hj/7wdDM4nTIl" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "fHLfEzSnf056+l1qKtly3BhNwkYVENgDxro4D8/uRq8DLn2L9glwCXQVzlCXCsSZVImUDu4hzjIRSIjYuYGIig==" ] }, { "body": { "messages": [ { "@type": "/cosmos.staking.v1beta1.MsgCreateValidator", "description": { "moniker": "Mimino", "identity": "", "website": "", "security_contact": "", "details": "" }, "commission": { "rate": "0.050000000000000000", "max_rate": "0.100000000000000000", "max_change_rate": "0.010000000000000000" }, "min_self_delegation": "1000000000", "delegator_address": "pussy1p74unan6vpp9frdcz2nhv8z59jx295njwzfmc0", "validator_address": "pussyvaloper1p74unan6vpp9frdcz2nhv8z59jx295nje80wxd", "pubkey": { "@type": "/cosmos.crypto.ed25519.PubKey", "key": "BMTtI0sCeGPqmAiKUsm4N7rstiKY6WFA1P2Il9wD5Eo=" }, "value": { "denom": "pussy", "amount": "1000000000000" } } ], "memo": "70e31b1f1f05cb4b262bb7f67119d08a0c3b58d5@46.221.13.16:26656", "timeout_height": "0", "extension_options": [], "non_critical_extension_options": [] }, "auth_info": { "signer_infos": [ { "public_key": { "@type": "/cosmos.crypto.secp256k1.PubKey", "key": "A+MSp7ZI8SK9IhpbUydvKExkSwjYkQoYy5Tubp26Jcat" }, "mode_info": { "single": { "mode": "SIGN_MODE_DIRECT" } }, "sequence": "0" } ], "fee": { "amount": [], "gas_limit": "200000", "payer": "", "granter": "" } }, "signatures": [ "Hv596QA/CfniTyB7h1ylgWmq2ki0nsA3h5+EOq9/Tw0+UxPsapZ11W6F4b4qdzvid3oWwQHEi2uTUe8nmnNURg==" ] } ] }, "gov": { "starting_proposal_id": "1", "deposits": [], "votes": [], "proposals": [], "deposit_params": { "min_deposit": [ { "denom": "pussy", "amount": "100000000000" } ], "max_deposit_period": "23650000s" }, "voting_params": { "voting_period": "345600s" }, "tally_params": { "quorum": "0.250000000000000000", "threshold": "0.500000000000000000", "veto_threshold": "0.250000000000000000" } }, "graph": null, "grid": { "params": { "max_routes": 16 }, "routes": [] }, "ibc": { "client_genesis": { "clients": [], "clients_consensus": [], "clients_metadata": [], "params": { "allowed_clients": [ "06-solomachine", "07-tendermint" ] }, "create_localhost": false, "next_client_sequence": "0" }, "connection_genesis": { "connections": [], "client_connection_paths": [], "next_connection_sequence": "0", "params": { "max_expected_time_per_block": "30000000000" } }, "channel_genesis": { "channels": [], "acknowledgements": [], "commitments": [], "receipts": [], "send_sequences": [], "recv_sequences": [], "ack_sequences": [], "next_channel_sequence": "0" } }, "liquidity": { "params": { "pool_types": [ { "id": 1, "name": "StandardLiquidityPool", "min_reserve_coin_num": 2, "max_reserve_coin_num": 2, "description": "Standard liquidity pool with pool price function X/Y, ESPM constraint, and two kinds of reserve coins" } ], "min_init_deposit_amount": "1000000", "init_pool_coin_mint_amount": "1000000000000", "max_reserve_coin_amount": "0", "pool_creation_fee": [ { "denom": "pussy", "amount": "1000000000" } ], "swap_fee_rate": "0.003000000000000000", "withdraw_fee_rate": "0.003000000000000000", "max_order_amount_ratio": "0.100000000000000000", "unit_batch_height": 1, "circuit_breaker_enabled": false }, "pool_records": [] }, "mint": { "minter": { "inflation": "0.050000000000000000", "annual_provisions": "0.000000000000000000" }, "params": { "mint_denom": "pussy", "inflation_rate_change": "0.030000000000000000", "inflation_max": "0.030000000000000000", "inflation_min": "0.010000000000000000", "goal_bonded": "0.100000000000000000", "blocks_per_year": "6311520" } }, "params": null, "rank": { "params": { "calculation_period": "5", "damping_factor": "0.800000000000000000", "tolerance": "0.001000000000000000" } }, "resources": { "params": { "max_slots": 8, "halving_period_volt_blocks": 6000000, "halving_period_ampere_blocks": 6000000, "base_investmint_period_volt": 2592000, "base_investmint_period_ampere": 2592000, "min_investmint_period": 86400, "base_investmint_amount_volt": { "denom": "liquidpussy", "amount": "1000000000" }, "base_investmint_amount_ampere": { "denom": "liquidpussy", "amount": "100000000" } } }, "slashing": { "params": { "signed_blocks_window": "10000", "min_signed_per_window": "0.050000000000000000", "downtime_jail_duration": "600s", "slash_fraction_double_sign": "0.050000000000000000", "slash_fraction_downtime": "0.000100000000000000" }, "signing_infos": [], "missed_blocks": [] }, "staking": { "params": { "unbonding_time": "2419200s", "max_validators": 69, "max_entries": 35, "historical_entries": 10000, "bond_denom": "pussy" }, "last_total_power": "0", "last_validator_powers": [], "validators": [], "delegations": [], "unbonding_delegations": [], "redelegations": [], "exported": false }, "transfer": { "port_id": "transfer", "denom_traces": [], "params": { "send_enabled": true, "receive_enabled": true } }, "upgrade": {}, "vesting": {}, "wasm": { "params": { "code_upload_access": { "permission": "Everybody", "address": "" }, "instantiate_default_permission": "Everybody" }, "codes": [], "contracts": [], "sequences": [], "gen_msgs": [] } } } ================================================ FILE: networks/space-pussy/gentxs/bloqhub.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"Bloqhub","identity":"","website":"","security_contact":"","details":""},"commission":{"rate":"0.050000000000000000","max_rate":"0.100000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"pussy1p5sudrdkr9r8a84s7fh27tkhdrhujhqatztfqf","validator_address":"pussyvaloper1p5sudrdkr9r8a84s7fh27tkhdrhujhqau8du7t","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"dfy2Tjb24fytmLaTIqMRigVfwh7mX4gr2C3prhcBPd0="},"value":{"denom":"pussy","amount":"1000000000000"}}],"memo":"4913a219c47a83f843ec4be9d9440e96ca8eee92@192.167.254.10:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"A+k17mb2lLGBARPZ14gHuefCdUxn30ZLlsRrSVSxyzSf"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["OYred5zZU2KnUiVMtzB6Px9dGUTfc993VUay9+0CjlkstllhrRYQtl7NK7KIQB5uqEeqFu6V35LFlKpvkMv9Yg=="]} ================================================ FILE: networks/space-pussy/gentxs/gentx-Citizen-Cosmos.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"Citizen Cosmos","identity":"DF0280597A20ACFE","website":"www.citizencosmos.space","security_contact":"","details":"Citizen Cosmos is a web3 brand and podcast"},"commission":{"rate":"0.050000000000000000","max_rate":"0.200000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"10000000000","delegator_address":"pussy1uynj0jhl059u9t5h4ug9075jrepdz4cwasmeqa","validator_address":"pussyvaloper1uynj0jhl059u9t5h4ug9075jrepdz4cw24av7l","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"gylED9s/yfWjaPUAsFUAQBVfZoYDTk8X+L0EjREk7l0="},"value":{"denom":"pussy","amount":"850000000000000"}}],"memo":"66eabcb6639163be65bdf88cde11732b9fe0a63c@195.201.81.239:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"ArhPmoTf9ioffBMf0WpkkuBKnv7vg0y7dRB1bbyzIwuL"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["SurtRcNVHVwlDYWaFeylQPA8dQLQD8PrBdSDnvEjW3ss/jEA5mK98NVdN+b353uGlwdOv7RioZaqB5i/0lCIFg=="]} ================================================ FILE: networks/space-pussy/gentxs/gentx-Developer.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"Developer","identity":"","website":"","security_contact":"","details":""},"commission":{"rate":"0.050000000000000000","max_rate":"0.200000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"pussy1hyrtrdqnayvvtznddczjymjcj2jagcqugfp2rl","validator_address":"pussyvaloper1hyrtrdqnayvvtznddczjymjcj2jagcqulv8laa","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"/unHhQAqM3i1KJ59PT0D5MEBJAmytPv8cutOhrPVQAg="},"value":{"denom":"pussy","amount":"1000000000000"}}],"memo":"6590ffaadab0384de9062bb5fa49ff5fb8d995a7@176.100.3.51:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"AtqUTtRprpb9K7bhAg1k24RKmkfab0wpZOiCfnZuOBi7"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["ucRhfid7DINBaCZzYhoZ0sPHAckFys5EPB3OoiQ3X7InkzQQwui77ZEQJsDlMTeHtrFvPm0vhOOzgeP5jh0h3A=="]} ================================================ FILE: networks/space-pussy/gentxs/gentx-Kerman.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"Kerman","identity":"","website":"","security_contact":"","details":""},"commission":{"rate":"0.050000000000000000","max_rate":"0.200000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"pussy1u2kvnwxmmpru764l5ht3nxkfwwu6ytw4s3zzsr","validator_address":"pussyvaloper1u2kvnwxmmpru764l5ht3nxkfwwu6ytw485yhwp","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"k2FA9IN6wJTjF3MHUNy04IUUwhh3ssTHz7eOFM0CLuM="},"value":{"denom":"pussy","amount":"1000000000000"}}],"memo":"890bc056e5f5faaa0efa7fe55a72af09e45b398d@185.230.90.71:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"AimwqRc63WjLVIInJMb/X+IQq31ZG08CvqwEGjsTP8iC"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["t3y7E1He8WPNAkHZNMYRBwTKFv7eHFYXjMPlYSZVKg0/nYltESBZlxgemrzcMt7IO8yJiNxEU5Uw9pp2r6E5+w=="]} ================================================ FILE: networks/space-pussy/gentxs/gentx-MikeLitoris.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"MikeLitoris","identity":"","website":"","security_contact":"","details":""},"commission":{"rate":"0.050000000000000000","max_rate":"0.100000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"pussy1rxdzc0c80u9wympy8sgmx32ra0df5dztx0v7xh","validator_address":"pussyvaloper1rxdzc0c80u9wympy8sgmx32ra0df5dzt322tc4","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"Ed+EBKPAgjZhyG2uhcHDXEFpocSUpPpyJb5qLvhRfr4="},"value":{"denom":"pussy","amount":"1000000000000"}}],"memo":"ba5af23f90706c80230df6db9c2fa42e11678d54@167.235.150.1:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"As00LA0oJPNpisW/RdUboX1kGxN2l93PPyEpTdDu7vIO"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["RRYQJQFkTTwH/KjOBL+SY+hJSsgOpC6sE8F8izwzCoNoAgbPELTi3SoMfFABSB7dTOFdUKJamILl2TOtmfgrVQ=="]} ================================================ FILE: networks/space-pussy/gentxs/gentx-POSTHUMAN.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"POSTHUMAN ꝏ DVS","identity":"8A9FC930E1A980D6","website":"https://posthuman.digital","security_contact":"validator@posthuman.digital","details":"100% refund in case of slashing ⚛️ MEꝏWE 🤲 Part of the profits goes to charity"},"commission":{"rate":"0.050000000000000000","max_rate":"0.100000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"pussy1e8238v24qccht9mqc2w0r4luq462yxttjjv5pq","validator_address":"pussyvaloper1e8238v24qccht9mqc2w0r4luq462yxtt9h2plz","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"zEBYTxQrRDumdM1stwnTay9z52VkGh3iYIUIa+XPObU="},"value":{"denom":"pussy","amount":"1000000000000"}}],"memo":"c349c49922435fc0cfdf02ac51548be989fbd102@142.132.253.246:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"A+rHQzOD96xTzMUmBsuOCo7rbm5a4dEMA0bJJdhtXHDT"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["5GQwYr4ZwgSvRzlJ3xdBQ3p40mVShld0opOEjDzwz3hWouYojXUg/0OmN135sbosgNsRSiIpDW5e26H2W5QdHg=="]} ================================================ FILE: networks/space-pussy/gentxs/gentx-Papsan.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"Papsan","identity":"C3AAAE53B3BDAC3F","website":"","security_contact":"","details":""},"commission":{"rate":"0.050000000000000000","max_rate":"0.100000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"pussy1r7q209q5yeh9d37pftdsm2eqtrl45ry8lmrfet","validator_address":"pussyvaloper1r7q209q5yeh9d37pftdsm2eqtrl45ry8g79u8f","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"cMynSZRzuNCrMFOenCcrkhldpIy3hfC6mOjBgmXmlpA="},"value":{"denom":"pussy","amount":"1000000000000"}}],"memo":"81f9706d4e9357e45bb2bafd4486b66ac6e58451@185.230.90.202:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"AvywWdD4SyRXjRvDZovKcEGxIUEJjHTjut0fingxl61X"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["XoTfuQy9+KYtW6FTQ/kGOP4pqNzT//9dlgSD+P6RDENKwFnTMGyDZSEx3WFOuKuYix6YEx/zntz/ENDkwBr3WQ=="]} ================================================ FILE: networks/space-pussy/gentxs/gentx-SAMPLE.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"hacker","identity":"","website":"","security_contact":"","details":""},"commission":{"rate":"0.100000000000000000","max_rate":"0.200000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1","delegator_address":"bostrom1cayzklulpvxvsw4742046609xp9k2arc5nyg6n","validator_address":"bostromvaloper1cayzklulpvxvsw4742046609xp9k2arcvfrh2s","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"YxN/kkQlXBwKNF4Cgi6tiqMh2ae8+tpo9VxENmFUhv8="},"value":{"denom":"boot","amount":"1000000000000"}}],"memo":"","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"A6oFVHXSAJ7GLvhKlBYcdFdBsYKYamgCAs11IWQCVAJi"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["x56LPJXVpBp9pLv7X9EAaDP1NrLV4HILQc/fv6oq6dkKwIaMW8Il77q0oVouZgAqsNmpyTTYLRxZybrWyxOCWQ=="]} ================================================ FILE: networks/space-pussy/gentxs/gentx-Stigga.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"Stigga","identity":"8A41E5318619A3ED","website":"https://stigga.org/","security_contact":"","details":"Individual PoS validator in Cosmos Hub Ecosystem chains, Discord:alexmed#5188"},"commission":{"rate":"0.050000000000000000","max_rate":"0.100000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"pussy12kpw3e9ypjal6upmju9smwgjhwefpt7v0smhkt","validator_address":"pussyvaloper12kpw3e9ypjal6upmju9smwgjhwefpt7vc4azgf","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"bNjOAI/PiehyuwYz+lCQDPpcrjlAF2i3Yvb3OSdmYAo="},"value":{"denom":"pussy","amount":"1000000000000"}}],"memo":"e932305e9a36c9423c1a38ebf408e250d0ddb5f7@89.38.97.150:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"A+2iJ2ufEo3cALGyEq8humzARIZk/G0WzdvmbEcjwUP0"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["1tY74vvbD7+ewFyrbp8kh1Z2PXzwz8I3zz1pqgh8/QoLMKLvOMvtiqGqFACBMjvOpuKYtYuMUAwrJZ4hVMHkFg=="]} ================================================ FILE: networks/space-pussy/gentxs/gentx-ToTheMars.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"ToTheMars","identity":"","website":"","security_contact":"","details":""},"commission":{"rate":"0.050000000000000000","max_rate":"0.100000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"pussy1vg8lh3dsp7023kz79mlk642dux9vu038pmp4ma","validator_address":"pussyvaloper1vg8lh3dsp7023kz79mlk642dux9vu038k78q9l","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"fuRnTyscip2Lp29YngUSqhzqFuUYt//BhVKMdChqQno="},"value":{"denom":"pussy","amount":"1000000000000"}}],"memo":"a012320ef30581df99f505c449a4c42a0490e9a6@192.168.0.248:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"Ar1A0LR8koZLzQhovHBHVQ0XsWMDIL+NuA2VWfuHmYWp"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["ka2M/eQO3f0NpAqiXTei8tFi0O3eI8IIxkePC+CIdj5AzERAxCtRTnLC4H9OEMUkGWWoWE0Ysv3YEGdZVkbU9g=="]} ================================================ FILE: networks/space-pussy/gentxs/gentx-Traneco.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","des cription":{"moniker":"Traneco","identity":"","website":"","security_contact":"" ,"details":""},"commission":{"rate":"0.050000000000000000","max_rate":"0.200000 000000000000","max_change_rate":"0.020000000000000000"},"min_self_delegation":" 1000000000","delegator_address":"pussy1fnwevu5z89qd5tx6qdpfxh6u3dttc6kc6hfa9y", "validator_address":"pussyvaloper1fnwevu5z89qd5tx6qdpfxh6u3dttc6kcdj0gmx","pubk ey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"aX3+3SxQaU5MiU8Mtxg8/koA9Hp rTLUL7JZbjWqlTpg="},"value":{"denom":"pussy","amount":"1000000000000"}}],"memo" :"61548477f8aab38eb12a0dea72c9ec53a8a1ba6f@192.168.0.163:26656","timeout_height ":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{ "signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key": "A4gVW7U+ROpfzvV5V3R2wBPrphVN3CswXTPllE/dsv9y"},"mode_info":{"single":{"mode":" SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","p ayer":"","granter":""}},"signatures":["dGhfFBjOAIw8+bqZ3+TcXDwq5/z8MPB/fidB4VNX 9PRd2DLKJdliXuGFPLEGlRrJzTRPHzEmkVKd9Jng7rN22Q=="]} ================================================ FILE: networks/space-pussy/gentxs/gentx-bro-n-bro.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"Bro_n_Bro","identity":"A57DAB9B09C7215D","website":"bronbro.io","security_contact":"","details":""},"commission":{"rate":"0.050000000000000000","max_rate":"0.200000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"100000000000","delegator_address":"pussy1j3w0aa7s6665puyls9lwx9ej6cz2afysuy0v80","validator_address":"pussyvaloper1j3w0aa7s6665puyls9lwx9ej6cz2afystpfeed","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"evJq4xH5kUwUa4yy74j7nAd6qFHLTfSm5NwqJlSLYCE="},"value":{"denom":"pussy","amount":"850000000000000"}}],"memo":"2e51205853f88048ac2ccb0b830960bbead14996@93.159.133.250:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"AhHVVko1tNyG8GVIjpzBL/E1f1K+1dQ5ItheZLTkNLNz"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["1WKvnWn5iGXKcGxmKU9CEeJHGp8q1lfKcJv9hJvsB8or5OGb/N7acc117yIMIE7kWt6IuNfO2IiPtSIrpxh7nw=="]} ================================================ FILE: networks/space-pussy/gentxs/gentx-chainmaniacs.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"ChainManiacs | Real Solar\u0026Wind validator","identity":"","website":"","security_contact":"","details":""},"commission":{"rate":"0.050000000000000000","max_rate":"0.100000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"pussy14fwr9m4rf27r3txv5luvph98nrckyu2qkfsn0f","validator_address":"pussyvaloper14fwr9m4rf27r3txv5luvph98nrckyu2qpvkx3t","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"3x+1Cab1diHNXd2yXYRQ/b2hIA/iAqqyWDonG6mg9+o="},"value":{"denom":"pussy","amount":"1000000000000"}}],"memo":"59ab923bee54f5815b591d1d3d312931a3d4e89a@192.167.254.10:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"A99rSpuMJoCXa603FCfC8gqffxilbKZwAI30ygly5kwl"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["xtpx8B7rtTzgNGYSlTpCKU+JAdojbOAuA2eOXD+t7odem6l+AbQ67sc6PqKvt98yvwXwyJBgxFM351nYDBxoYw=="]} ================================================ FILE: networks/space-pussy/gentxs/gentx-cyberG.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"cyberG","identity":"","website":"","security_contact":"","details":""},"commission":{"rate":"0.050000000000000000","max_rate":"0.100000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"pussy17zdyl3gfssc3vzzyxptnr0xl8z0pnte9a8zjjx","validator_address":"pussyvaloper17zdyl3gfssc3vzzyxptnr0xl8z0pnte92zy8vy","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"mH49uKT67SY4ODuXUGkqbKMYjZxzHc+UI6QbNGqWI+Y="},"value":{"denom":"pussy","amount":"1000000000000"}}],"memo":"472e953f82e3993614b93635307ca503b7fad812@192.168.0.188:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"A8HHUcU41AdJWAVryBu/fD7SG6s+3My2OPelPlLBHeWe"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["3neewRTs3pwwGtXinK+BMJ/TVMAxR8zf1Hgq5o/5tBgXUQBSBtTaHE73/gmMkmxqEJx2gFomX+zVW512O22yHQ=="]} ================================================ FILE: networks/space-pussy/gentxs/gentx-denwer.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"Denwer","identity":"","website":"","security_contact":"","details":""},"commission":{"rate":"0.050000000000000000","max_rate":"0.100000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"pussy1n8hu3cqsn3txf0ltdk3x0sff2s0yt96xyffz3m","validator_address":"pussyvaloper1n8hu3cqsn3txf0ltdk3x0sff2s0yt96xnv0h0e","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"HPovYK9BjXDpC/NUTdRufVpfCB23ewveyE7X8vHxUsg="},"value":{"denom":"pussy","amount":"1000000000000"}}],"memo":"a0b15d6721d13a91ce368b56cdad9991c76d4c86@46.211.3.216:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"AlsigW11Iogtfe1wf2NPbLR3qWMTVPLA5cOm9hCyW1Ro"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["R1dkYmTnOwAoHF0zABktAXnE4fiBJ7sJ2fUk0jYoaiQwdQ/z1TSWDnX8jk2F5WxtXnd0/9eAIjuCaAmAKnSJhA=="]} ================================================ FILE: networks/space-pussy/gentxs/gentx-goto5k.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"goto5k","identity":"1B0142FC46D30561","website":"https://goto5k.com","security_contact":"","details":"Independent validator. Ambassador."},"commission":{"rate":"0.100000000000000000","max_rate":"0.100000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"pussy10trdf5eyfcmc9graltx4hmpgznhrm7hdgt5mf6","validator_address":"pussyvaloper10trdf5eyfcmc9graltx4hmpgznhrm7hdlwjwhc","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"YPe0JNydv1qJDlvvGapbQxaRFp/rFswW0w3PdvKuaBw="},"value":{"denom":"pussy","amount":"1000000000000"}}],"memo":"659189a8e378833332ffd61f3495443359fb52a0@192.168.100.4:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"A2y3DqIjyeTqoFiojpJh5eJmLxcROK/zw3fOVj87KvVf"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["+IJUBzJisyJUFfP3kDmldQL85Ols8T2Ri3cOGmm4DSFY00E7XEgykHX3YLFxAPB/wS18NAScqM/07yANQJFzjg=="]} ================================================ FILE: networks/space-pussy/gentxs/gentx-joy_prophet.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"Joy prophet","identity":"","website":"","security_contact":"","details":""},"commission":{"rate":"0.050000000000000000","max_rate":"0.100000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"pussy14hrqklee0tx6asycyfj357keql2jr5rdq9h34a","validator_address":"pussyvaloper14hrqklee0tx6asycyfj357keql2jr5rdhq3ytl","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"jSKJDVC/AGr6D+nnmdhMe+zmPinqrEMSlSsYja0FB7w="},"value":{"denom":"pussy","amount":"1000000000000"}}],"memo":"178f1f4f430d1052c78ab12a5132f37b5d2c654d@172.19.219.100:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"Aw5AOC6ECe3PnVisdqXhw65gPj8rDL68oyBmkI5a57la"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["KPsZI03UmKY8uovSr3NQ5EEAa+fwjCf4Yys6LOjwXl0/xiBOKFDptqWCK5XqQjClhaj/RVv7zHEU6/iUAJSppA=="]} ================================================ FILE: networks/space-pussy/gentxs/gentx-linak.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"linak","identity":"6F961E9B32E722ED","website":"","security_contact":"","details":""},"commission":{"rate":"0.100000000000000000","max_rate":"0.100000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"pussy1v46pz6ddetfc3tnvdr28ss0l48jhazgyeqlumh","validator_address":"pussyvaloper1v46pz6ddetfc3tnvdr28ss0l48jhazgyw9ef94","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"lAPc3XVbfWl+WhIxup6ReXQ90UhQyKYi6yCUnvVv6L4="},"value":{"denom":"pussy","amount":"1000000000000"}}],"memo":"4d8e240bf3a4d3a13f627e1aba2ca0fffa8a1cd7@185.242.112.3:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"A6xdxbJ47TzrUdGG8SoVi/jPUH7x+x7jK5nlb3af+ILy"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["N0ll3hrLTFHbLFnriCCtZNcm/k3HJVdVSjpxuSEjFnYpOpaF8+uehIVsQfNTwbobatoAf10Iq+RldVrOpDZsyQ=="]} ================================================ FILE: networks/space-pussy/gentxs/gentx-lux8net.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"lux8.net","identity":"EBBAB54C972A579A","website":"https://lux8.net","security_contact":"","details":"Fiat Lux. Infinite Lux."},"commission":{"rate":"0.050000000000000000","max_rate":"0.100000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"pussy1m0tjgkrh4td9fcp8nnssu3rfdahzfgdsaurjuv","validator_address":"pussyvaloper1m0tjgkrh4td9fcp8nnssu3rfdahzfgds2e98zw","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"zaSRRntTmScRxBexrH3Tjfsa23yulZ3iUdN4yHBoJt0="},"value":{"denom":"pussy","amount":"1000000000000"}}],"memo":"3630247f32b5b363825027546cbbaa27b2ee8886@194.190.169.129:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"AleLx6VDXm7sVYlwUwXCRpFMYKzIDaWuCVcXH5I0qji1"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["qztwtzDxA+p/4ZXMjBZMgScFsUbb5Q+u+7IE8Sfrj4g3fElhLRwmfatI1pyKOISQtF6MjYZBMDwPEkNMaqk0KQ=="]} ================================================ FILE: networks/space-pussy/gentxs/gentx-space.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"space","identity":"B80D9AB4E8981B6A","website":"","security_contact":"andfat#4230","details":""},"commission":{"rate":"0.050000000000000000","max_rate":"0.200000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"pussy1kfqme88c6vq8mt0smw29z67k4zz2ykr6km5rck","validator_address":"pussyvaloper1kfqme88c6vq8mt0smw29z67k4zz2ykr6p7jkx5","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"cElo/7UWLQYVKpqjHuyeDas1DKrS6D87jooPjjB4RSs="},"value":{"denom":"pussy","amount":"1000000000000"}}],"memo":"3d11aee6b074c4293d60fca7dfb1b12172a60fa3@88.218.191.78:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"A5cZnI4Nt6B8HGkkYarRt2/SIlETX/urxNHwYscYhwQK"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["I753eO+EW+HL34Unak35+jdPu3Ypv9uAcni5qrLx0NkeKBfThKno51soo2EcI87GARR00XaQqBlmRA/dh5r3fA=="]} ================================================ FILE: networks/space-pussy/gentxs/gentx-web34ever.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"web34ever","identity":"52D7E9C59B92F133","website":"https://web3validator.info","security_contact":"","details":""},"commission":{"rate":"0.050000000000000000","max_rate":"0.100000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"pussy1r8d26xgfxr80v3slu8r6z7wkl4h7f99qa4hhqg","validator_address":"pussyvaloper1r8d26xgfxr80v3slu8r6z7wkl4h7f99q2s3z72","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"KDEt7qRMgauk8PosX+iB4l1ZJh4nuSPRFX6jqU16kuo="},"value":{"denom":"pussy","amount":"1000000000000"}}],"memo":"e2c4ea781c86ace81e895ac8a2c60f215138ed0f@88.218.191.79:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"Aoc7SC9kMjYyJCWL9SAvEbaTu9uPTz9hj/7wdDM4nTIl"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["fHLfEzSnf056+l1qKtly3BhNwkYVENgDxro4D8/uRq8DLn2L9glwCXQVzlCXCsSZVImUDu4hzjIRSIjYuYGIig=="]} ================================================ FILE: networks/space-pussy/gentxs/mimino.json ================================================ {"body":{"messages":[{"@type":"/cosmos.staking.v1beta1.MsgCreateValidator","description":{"moniker":"Mimino","identity":"","website":"","security_contact":"","details":""},"commission":{"rate":"0.050000000000000000","max_rate":"0.100000000000000000","max_change_rate":"0.010000000000000000"},"min_self_delegation":"1000000000","delegator_address":"pussy1p74unan6vpp9frdcz2nhv8z59jx295njwzfmc0","validator_address":"pussyvaloper1p74unan6vpp9frdcz2nhv8z59jx295nje80wxd","pubkey":{"@type":"/cosmos.crypto.ed25519.PubKey","key":"BMTtI0sCeGPqmAiKUsm4N7rstiKY6WFA1P2Il9wD5Eo="},"value":{"denom":"pussy","amount":"1000000000000"}}],"memo":"70e31b1f1f05cb4b262bb7f67119d08a0c3b58d5@46.221.13.16:26656","timeout_height":"0","extension_options":[],"non_critical_extension_options":[]},"auth_info":{"signer_infos":[{"public_key":{"@type":"/cosmos.crypto.secp256k1.PubKey","key":"A+MSp7ZI8SK9IhpbUydvKExkSwjYkQoYy5Tubp26Jcat"},"mode_info":{"single":{"mode":"SIGN_MODE_DIRECT"}},"sequence":"0"}],"fee":{"amount":[],"gas_limit":"200000","payer":"","granter":""}},"signatures":["Hv596QA/CfniTyB7h1ylgWmq2ki0nsA3h5+EOq9/Tw0+UxPsapZ11W6F4b4qdzvid3oWwQHEi2uTUe8nmnNURg=="]} ================================================ FILE: networks/space-pussy/get_peers/getpeers.nu ================================================ ## Script pull peers from RPC Node http get https ://rpc.space-pussy.cybernode.ai:443/net_info | get result.peers | each {|i| $i | get remote_ip node_info.id node_info.listen_addr} | each {|i| $'($i.1)@($i.0):($i.2 | split row ":" | last)'} | str join ',' | $'persistent_peers = "($in)"' ================================================ FILE: networks/space-pussy/get_peers/getpeers.sh ================================================ #!/bin/bash ## https://gist.github.com/Cordtus/87b147862627d3039f394695b78e4361 ## dump connected peers to comma separated persistent_peers list RED='\033[0;91m' GREEN='\033[0;32m' BLUE='\033[0;34m' NC='\033[0m' x=0 printf "\n${RED}rpc${NC} address?: " read -r RPC DATA=$(curl -s $RPC/net_info) if [ -z "$DATA" ] then printf "%b\n${RED}rpc%b${NC} error\n\n" exit fi NETWORK=$(echo $DATA | jq '.result | .peers | .[0] | .node_info | .network' | tr -d '"') COUNT=$(echo $DATA | jq '.result | .n_peers' | tr -d '"') while [ $x -lt $COUNT ] do if [ $(echo $DATA | jq ".result | .peers | .[$x] | .is_outbound") == 'true' ] then ID=$(echo $DATA | jq ".result | .peers | .[$x] | .node_info | .id" 2> /dev/null) ADDRESS=$(echo $DATA | jq ".result | .peers | .[$x] | .remote_ip" 2> /dev/null) PORT=$(echo $DATA | jq ".result | .peers | .[$x] | .node_info | .listen_addr" 2> /dev/null | tr -d '"') PEER=$(echo $ID | tr -d '"')@$(echo $ADDRESS | tr -d '"'):${PORT##*:} PEERS[${#PEERS[@]}]="$PEER" ((x++)) else ((x++)) fi done printf "\n${RED}$x${NC} outbound peers found" printf "\n${RED}number${NC} of peers to list? (1,3,10,all): " read -r NUMBER if [ -z $NUMBER ] then TOTAL="$x" elif [ $NUMBER == "all" ] || [ $NUMBER -ge $x ] then TOTAL="$x" else TOTAL="$NUMBER" fi while [[ $i -lt $TOTAL ]] do P_LIST="$P_LIST,$(echo ${PEERS[$i]} | tr -d '\n')" ((i++)) done printf "\npersistent_peers = \"${P_LIST:1}\"\n" ================================================ FILE: networks/space-pussy/peers.md ================================================ # Here you may fing peers and seeds to hop on bostrom chain ## Peers: cyberongress: ```bash 0b2689ae3b712adbaf4f3a124ca175725aa01fcd@95.216.76.211:26656 ``` Bro_n_Bro validator ```bash 6c8dc2888fc42b910c4bd34d7d51ee1d01946c76@93.159.134.158:36656 ``` Citizen Cosmos ```bash 66eabcb6639163be65bdf88cde11732b9fe0a63c@195.201.81.239:26656 ``` ================================================ FILE: networks/space-pussy/pussy_snapshot_deploy_guide.md ================================================ # ![](https://ipfs.io/ipfs/QmWeAd87fZm1pMYyX9BmhnTrXYKCZLoyzMJMcSwNHfB6gU) Deploy Pussy node from snapshot ## Download snapshot First, go to [Pussy Snapshot Robot](https://cyb.ai/network/bostrom/contract/pussy137p3ll78yrlw3gtfltgwhdkz0qxke4z638md6n) quitter page Latest post will show you available snapsot: ![](https://ipfs.io/ipfs/QmaFJ56SNwEvF2J1wsuKjdb1psYNSbFPiSRntPrjEcYoHa) Сlick on the link with the block and you will see three results: ![](https://ipfs.io/ipfs/QmaSj6avQZFs8Yn7ZbKNoR96TVqAng1Cov21ZukNoU2n7U) We typicaly store only latest snashot, older might be available only in IPFS if someone stored them. The first one is a hash of the current snapshot that can be downloaded directly from ipfs (to use this way, you need an ipfs [client](https://docs.ipfs.tech/install/command-line/) installed) ``` ipfs get --output space-pussy-pruned.tar.gz ``` The second hash contains url that can be downloaded directly: ``` wget https://jupiter.cybernode.ai/shared/space-pussy-pruned_.tar.gz ``` ## Unpack snapshot Single thread: ``` tar -xvzf space-pussy-pruned_.tar.gz ``` Multiple threads (much faster and require pigz installation): ``` apt install pigz tar -I pigz -xf space-pussy-pruned_.tar.gz -C ./ ``` ## Stop Pussy ``` docker stop space-pussy ``` ## Remove old data from home directory **Dont forget to use correct path if your node is not in $HOME of your user.** ``` rm -rf ~/.pussy/data ~/.pussy/wasm ``` ## Move unpacked folders into home directory ``` cd space-pussy-pruned_ mv data/ ~/.pussy/ mv wasm/ ~/.pussy/ ``` ## Set up your pruning strategy to everything To save the space ont the disk consumed by the node set pruning to everything (lightest one) and set snapshot-interval to 0 in `.pussy/config/app.toml`: ``` pruning = "everything" snapshot-interval = 0 ``` ## Start Pussy container and check logs ``` docker start space-pussy docker logs space-pussy -f --tail 10 ``` You will see node started sync from the snapshot block. ## When done dont forget to remove folder and archive to save some space ``` rm -rf space-pussy-pruned_ space-pussy-pruned_.tar.gz ``` ================================================ FILE: networks/space-pussy/unsigned-genesis.json ================================================ { "genesis_time": "2022-10-03T19:55:00Z", "chain_id": "space-pussy", "initial_height": "1", "consensus_params": { "block": { "max_bytes": "4194304", "max_gas": "25000000", "time_iota_ms": "1000" }, "evidence": { "max_age_num_blocks": "100000", "max_age_duration": "172800000000000", "max_bytes": "1048576" }, "validator": { "pub_key_types": [ "ed25519" ] }, "version": {} }, "app_hash": "", "app_state": { "auth": { "params": { "max_memo_characters": "1024", "tx_sig_limit": "7", "tx_size_cost_per_byte": "20", "sig_verify_cost_ed25519": "590", "sig_verify_cost_secp256k1": "1000" }, "accounts": [ { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1d8754xqa9245pctlfcyv8eah468neqznm33fvz", "pub_key": null, "account_number": "0", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1gxhs5wzam5rlgf6cs0lkme400ut64d4njdhaf7", "pub_key": null, "account_number": "1", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1j3w0aa7s6665puyls9lwx9ej6cz2afysuy0v80", "pub_key": null, "account_number": "2", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy13hepw93y8mjcew7mfra5z7ju7k658534dpd39u", "pub_key": null, "account_number": "3", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1m5rf5fvhrl76s3xkvh3kde0p4dpwzewurch92s", "pub_key": null, "account_number": "4", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1gdpk4xeyeqzdkdwc0c2zrd8ltrthnze3a42c0n", "pub_key": null, "account_number": "5", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1zaefvwrgk2g45k68a3ngahgq0xky5zged294fr", "pub_key": null, "account_number": "6", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1ke3aflev7cr75gxa54k6qwrajfc53vqh4yfjj0", "pub_key": null, "account_number": "7", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1e8238v24qccht9mqc2w0r4luq462yxttjjv5pq", "pub_key": null, "account_number": "8", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1956s252r7du0jfeskaauep4lm6a9wn2pktntq0", "pub_key": null, "account_number": "9", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1r28nhrkwcvqs4qss2l7zqdvc2qfdl8ar6f4gqe", "pub_key": null, "account_number": "10", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy12kpw3e9ypjal6upmju9smwgjhwefpt7v0smhkt", "pub_key": null, "account_number": "11", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1qkw8dtdansmvayk2jxfkpel9q4d20rvfazxykl", "pub_key": null, "account_number": "12", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1rj7zt2pzuzwhjlr24u0prnqqxm3xexavpd7xp0", "pub_key": null, "account_number": "13", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy17zdyl3gfssc3vzzyxptnr0xl8z0pnte9a8zjjx", "pub_key": null, "account_number": "14", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1vg8lh3dsp7023kz79mlk642dux9vu038pmp4ma", "pub_key": null, "account_number": "15", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy10trdf5eyfcmc9graltx4hmpgznhrm7hdgt5mf6", "pub_key": null, "account_number": "16", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1v46pz6ddetfc3tnvdr28ss0l48jhazgyeqlumh", "pub_key": null, "account_number": "17", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1fnwevu5z89qd5tx6qdpfxh6u3dttc6kc6hfa9y", "pub_key": null, "account_number": "18", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy14hrqklee0tx6asycyfj357keql2jr5rdq9h34a", "pub_key": null, "account_number": "19", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1r8d26xgfxr80v3slu8r6z7wkl4h7f99qa4hhqg", "pub_key": null, "account_number": "20", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1r7q209q5yeh9d37pftdsm2eqtrl45ry8lmrfet", "pub_key": null, "account_number": "21", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy13jnp8uk4xnqcvdejcnq9rphm9actc90pf2r4ka", "pub_key": null, "account_number": "22", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1hyrtrdqnayvvtznddczjymjcj2jagcqugfp2rl", "pub_key": null, "account_number": "23", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1kfqme88c6vq8mt0smw29z67k4zz2ykr6km5rck", "pub_key": null, "account_number": "24", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1u2kvnwxmmpru764l5ht3nxkfwwu6ytw4s3zzsr", "pub_key": null, "account_number": "25", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1d59yxkz9uem873a3nyt5j379hsa7tjpvej0xfh", "pub_key": null, "account_number": "26", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1uynj0jhl059u9t5h4ug9075jrepdz4cwasmeqa", "pub_key": null, "account_number": "27", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy14fwr9m4rf27r3txv5luvph98nrckyu2qkfsn0f", "pub_key": null, "account_number": "28", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1n8hu3cqsn3txf0ltdk3x0sff2s0yt96xyffz3m", "pub_key": null, "account_number": "29", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1p5sudrdkr9r8a84s7fh27tkhdrhujhqatztfqf", "pub_key": null, "account_number": "30", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1p74unan6vpp9frdcz2nhv8z59jx295njwzfmc0", "pub_key": null, "account_number": "31", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1jxzpz4ggqefs5ps7veupd8zfy5a62cgyrm7rr8", "pub_key": null, "account_number": "32", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1ezpth4mp3eeqdt49kgqd5ctr69xev6v2zggvl2", "pub_key": null, "account_number": "33", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1wm4026rxqcrkh09k806m6y4lys942etx75v0xt", "pub_key": null, "account_number": "34", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1gwlqmqc9nrnuu8fanls76exyrzum9xjmdtlgnl", "pub_key": null, "account_number": "35", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1ezqvp6aga74ms7jqrfwhrm7266sn2m50afvapg", "pub_key": null, "account_number": "36", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1cwu6g93hnfm44zyl8cnkn58dsakxh2ac49m8c3", "pub_key": null, "account_number": "37", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1rxdzc0c80u9wympy8sgmx32ra0df5dztx0v7xh", "pub_key": null, "account_number": "38", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy10jmsqhf7mwquv0wa08hegxqaasvue5tnn7wn79", "pub_key": null, "account_number": "39", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1m0tjgkrh4td9fcp8nnssu3rfdahzfgdsaurjuv", "pub_key": null, "account_number": "40", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.BaseAccount", "address": "pussy1g65rmjkeuy5rywx04s4fvwfylmlz98vq87mdq7", "pub_key": null, "account_number": "41", "sequence": "0" }, { "@type": "/cosmos.auth.v1beta1.ModuleAccount", "base_account": { "account_number": "42", "address": "pussy1jv65s3grqf6v6jl3dp4t6c9t9rk99cd8wqwz53", "pub_key": null, "sequence": "0" }, "name": "distribution", "permissions": [] } ] }, "authz": { "authorization": [] }, "bandwidth": { "params": { "recovery_period": "16000", "adjust_price_period": "5", "base_price": "0.250000000000000000", "max_block_bandwidth": "25000", "base_load": "0.100000000000000000" } }, "bank": { "params": { "send_enabled": [], "default_send_enabled": true }, "balances": [ { "address": "pussy1d8754xqa9245pctlfcyv8eah468neqznm33fvz", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1gxhs5wzam5rlgf6cs0lkme400ut64d4njdhaf7", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1j3w0aa7s6665puyls9lwx9ej6cz2afysuy0v80", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy13hepw93y8mjcew7mfra5z7ju7k658534dpd39u", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1m5rf5fvhrl76s3xkvh3kde0p4dpwzewurch92s", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1gdpk4xeyeqzdkdwc0c2zrd8ltrthnze3a42c0n", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1zaefvwrgk2g45k68a3ngahgq0xky5zged294fr", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1ke3aflev7cr75gxa54k6qwrajfc53vqh4yfjj0", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1e8238v24qccht9mqc2w0r4luq462yxttjjv5pq", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1956s252r7du0jfeskaauep4lm6a9wn2pktntq0", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1r28nhrkwcvqs4qss2l7zqdvc2qfdl8ar6f4gqe", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy12kpw3e9ypjal6upmju9smwgjhwefpt7v0smhkt", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1qkw8dtdansmvayk2jxfkpel9q4d20rvfazxykl", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1rj7zt2pzuzwhjlr24u0prnqqxm3xexavpd7xp0", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy17zdyl3gfssc3vzzyxptnr0xl8z0pnte9a8zjjx", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1vg8lh3dsp7023kz79mlk642dux9vu038pmp4ma", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy10trdf5eyfcmc9graltx4hmpgznhrm7hdgt5mf6", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1v46pz6ddetfc3tnvdr28ss0l48jhazgyeqlumh", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1fnwevu5z89qd5tx6qdpfxh6u3dttc6kc6hfa9y", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy14hrqklee0tx6asycyfj357keql2jr5rdq9h34a", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1r8d26xgfxr80v3slu8r6z7wkl4h7f99qa4hhqg", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1r7q209q5yeh9d37pftdsm2eqtrl45ry8lmrfet", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy13jnp8uk4xnqcvdejcnq9rphm9actc90pf2r4ka", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1hyrtrdqnayvvtznddczjymjcj2jagcqugfp2rl", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1kfqme88c6vq8mt0smw29z67k4zz2ykr6km5rck", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1u2kvnwxmmpru764l5ht3nxkfwwu6ytw4s3zzsr", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1d59yxkz9uem873a3nyt5j379hsa7tjpvej0xfh", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1uynj0jhl059u9t5h4ug9075jrepdz4cwasmeqa", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy14fwr9m4rf27r3txv5luvph98nrckyu2qkfsn0f", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1n8hu3cqsn3txf0ltdk3x0sff2s0yt96xyffz3m", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1p5sudrdkr9r8a84s7fh27tkhdrhujhqatztfqf", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1p74unan6vpp9frdcz2nhv8z59jx295njwzfmc0", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1jxzpz4ggqefs5ps7veupd8zfy5a62cgyrm7rr8", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1ezpth4mp3eeqdt49kgqd5ctr69xev6v2zggvl2", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1wm4026rxqcrkh09k806m6y4lys942etx75v0xt", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1gwlqmqc9nrnuu8fanls76exyrzum9xjmdtlgnl", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1ezqvp6aga74ms7jqrfwhrm7266sn2m50afvapg", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1cwu6g93hnfm44zyl8cnkn58dsakxh2ac49m8c3", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1rxdzc0c80u9wympy8sgmx32ra0df5dztx0v7xh", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy10jmsqhf7mwquv0wa08hegxqaasvue5tnn7wn79", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1m0tjgkrh4td9fcp8nnssu3rfdahzfgdsaurjuv", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1g65rmjkeuy5rywx04s4fvwfylmlz98vq87mdq7", "coins": [ { "denom": "pussy", "amount": "1000000000000000" } ] }, { "address": "pussy1jv65s3grqf6v6jl3dp4t6c9t9rk99cd8wqwz53", "coins": [ { "amount": "958000000000000000", "denom": "pussy" } ] } ], "supply": [ { "amount": "1000000000000000000", "denom": "pussy" } ], "denom_metadata": [ { "description": "The staking token of space-pussy", "base": "pussy", "display": "pussy", "name": "Pussy token", "symbol": "PUSSY", "denom_units": [ { "denom": "pussy", "exponent": 0, "aliases": [ "PUSSY" ] } ] }, { "description": "The liquid staking token of Space-pussy", "base": "liquidpussy", "display": "liquidpussy", "name": "liquidpussy", "symbol": "LIQUIDPUSSY", "denom_units": [ { "denom": "liquidpussy", "exponent": 0, "aliases": [ "LIQUIDPUSSY" ] } ] }, { "description": "The power token of Space-pussy", "base": "milliampere", "display": "ampere", "name": "Space-pussy Ampere", "symbol": "AMPERE", "denom_units": [ { "denom": "milliampere", "exponent": 0, "aliases": [] }, { "denom": "ampere", "exponent": 3, "aliases": [ "AMPERE" ] } ] }, { "description": "The bandwidth token of Space-pussy", "base": "millivolt", "display": "volt", "name": "Space-pussy Volt", "symbol": "VOLT", "denom_units": [ { "denom": "millivolt", "exponent": 0, "aliases": [] }, { "denom": "volt", "exponent": 3, "aliases": [ "VOLT" ] } ] } ] }, "capability": { "index": "1", "owners": [] }, "crisis": { "constant_fee": { "denom": "pussy", "amount": "10000000" } }, "cyberbank": null, "distribution": { "params": { "community_tax": "0.000000000000000000", "base_proposer_reward": "0.010000000000000000", "bonus_proposer_reward": "0.030000000000000000", "withdraw_addr_enabled": true }, "fee_pool": { "community_pool": [ { "amount": "958000000000000000", "denom": "pussy" } ] }, "delegator_withdraw_infos": [], "previous_proposer": "", "outstanding_rewards": [], "validator_accumulated_commissions": [], "validator_historical_rewards": [], "validator_current_rewards": [], "delegator_starting_infos": [], "validator_slash_events": [] }, "dmn": { "params": { "max_slots": 4, "max_gas": 2500000, "fee_ttl": 50 } }, "evidence": { "evidence": [] }, "feegrant": { "allowances": [] }, "genutil": { "gen_txs": [] }, "gov": { "starting_proposal_id": "1", "deposits": [], "votes": [], "proposals": [], "deposit_params": { "min_deposit": [ { "denom": "pussy", "amount": "100000000000" } ], "max_deposit_period": "23650000s" }, "voting_params": { "voting_period": "345600s" }, "tally_params": { "quorum": "0.250000000000000000", "threshold": "0.500000000000000000", "veto_threshold": "0.250000000000000000" } }, "graph": null, "grid": { "params": { "max_routes": 16 }, "routes": [] }, "ibc": { "client_genesis": { "clients": [], "clients_consensus": [], "clients_metadata": [], "params": { "allowed_clients": [ "06-solomachine", "07-tendermint" ] }, "create_localhost": false, "next_client_sequence": "0" }, "connection_genesis": { "connections": [], "client_connection_paths": [], "next_connection_sequence": "0", "params": { "max_expected_time_per_block": "30000000000" } }, "channel_genesis": { "channels": [], "acknowledgements": [], "commitments": [], "receipts": [], "send_sequences": [], "recv_sequences": [], "ack_sequences": [], "next_channel_sequence": "0" } }, "liquidity": { "params": { "pool_types": [ { "id": 1, "name": "StandardLiquidityPool", "min_reserve_coin_num": 2, "max_reserve_coin_num": 2, "description": "Standard liquidity pool with pool price function X/Y, ESPM constraint, and two kinds of reserve coins" } ], "min_init_deposit_amount": "1000000", "init_pool_coin_mint_amount": "1000000000000", "max_reserve_coin_amount": "0", "pool_creation_fee": [ { "denom": "pussy", "amount": "1000000000" } ], "swap_fee_rate": "0.003000000000000000", "withdraw_fee_rate": "0.003000000000000000", "max_order_amount_ratio": "0.100000000000000000", "unit_batch_height": 1, "circuit_breaker_enabled": false }, "pool_records": [] }, "mint": { "minter": { "inflation": "0.050000000000000000", "annual_provisions": "0.000000000000000000" }, "params": { "mint_denom": "pussy", "inflation_rate_change": "0.030000000000000000", "inflation_max": "0.030000000000000000", "inflation_min": "0.010000000000000000", "goal_bonded": "0.100000000000000000", "blocks_per_year": "6311520" } }, "params": null, "rank": { "params": { "calculation_period": "5", "damping_factor": "0.800000000000000000", "tolerance": "0.001000000000000000" } }, "resources": { "params": { "max_slots": 8, "halving_period_volt_blocks": 6000000, "halving_period_ampere_blocks": 6000000, "base_investmint_period_volt": 2592000, "base_investmint_period_ampere": 2592000, "min_investmint_period": 86400, "base_investmint_amount_volt": { "denom": "liquidpussy", "amount": "1000000000" }, "base_investmint_amount_ampere": { "denom": "liquidpussy", "amount": "100000000" } } }, "slashing": { "params": { "signed_blocks_window": "10000", "min_signed_per_window": "0.050000000000000000", "downtime_jail_duration": "600s", "slash_fraction_double_sign": "0.050000000000000000", "slash_fraction_downtime": "0.000100000000000000" }, "signing_infos": [], "missed_blocks": [] }, "staking": { "params": { "unbonding_time": "2419200s", "max_validators": 69, "max_entries": 35, "historical_entries": 10000, "bond_denom": "pussy" }, "last_total_power": "0", "last_validator_powers": [], "validators": [], "delegations": [], "unbonding_delegations": [], "redelegations": [], "exported": false }, "transfer": { "port_id": "transfer", "denom_traces": [], "params": { "send_enabled": true, "receive_enabled": true } }, "upgrade": {}, "vesting": {}, "wasm": { "params": { "code_upload_access": { "permission": "Everybody", "address": "" }, "instantiate_default_permission": "Everybody" }, "codes": [], "contracts": [], "sequences": [], "gen_msgs": [] } } } ================================================ FILE: plugins/types/custom_querier.go ================================================ package types import ( errorsmod "cosmossdk.io/errors" "encoding/json" "errors" wasmvmtypes "github.com/CosmWasm/wasmvm/types" sdk "github.com/cosmos/cosmos-sdk/types" bankkeeper "github.com/cosmos/cosmos-sdk/x/bank/keeper" bandwidthkeeper "github.com/cybercongress/go-cyber/v7/x/bandwidth/keeper" bandwidthtypes "github.com/cybercongress/go-cyber/v7/x/bandwidth/types" dmnkeeper "github.com/cybercongress/go-cyber/v7/x/dmn/keeper" dmntypes "github.com/cybercongress/go-cyber/v7/x/dmn/types" graphkeeper "github.com/cybercongress/go-cyber/v7/x/graph/keeper" graphtypes "github.com/cybercongress/go-cyber/v7/x/graph/types" gridkeeper "github.com/cybercongress/go-cyber/v7/x/grid/keeper" gridtypes "github.com/cybercongress/go-cyber/v7/x/grid/types" rankkeeper "github.com/cybercongress/go-cyber/v7/x/rank/keeper" ranktypes "github.com/cybercongress/go-cyber/v7/x/rank/types" tokenfactorykeeper "github.com/cybercongress/go-cyber/v7/x/tokenfactory/keeper" tokenfactorytypes "github.com/cybercongress/go-cyber/v7/x/tokenfactory/types" ) type ModuleQuerier interface { HandleQuery(ctx sdk.Context, query CyberQuery) ([]byte, error) } var ErrHandleQuery = errors.New("error handle query") type QueryPlugin struct { moduleQueriers map[string]ModuleQuerier rankKeeper *rankkeeper.StateKeeper graphKeeper *graphkeeper.GraphKeeper dmnKeeper *dmnkeeper.Keeper gridKeeper *gridkeeper.Keeper bandwidthMeter *bandwidthkeeper.BandwidthMeter bankKeeper *bankkeeper.Keeper tokenFactoryKeeper *tokenfactorykeeper.Keeper } func NewQueryPlugin( moduleQueriers map[string]ModuleQuerier, rank *rankkeeper.StateKeeper, graph *graphkeeper.GraphKeeper, dmn *dmnkeeper.Keeper, grid *gridkeeper.Keeper, bandwidth *bandwidthkeeper.BandwidthMeter, bank *bankkeeper.Keeper, tokenFactory *tokenfactorykeeper.Keeper, ) *QueryPlugin { return &QueryPlugin{ moduleQueriers: moduleQueriers, rankKeeper: rank, graphKeeper: graph, dmnKeeper: dmn, gridKeeper: grid, bandwidthMeter: bandwidth, bankKeeper: bank, tokenFactoryKeeper: tokenFactory, } } func CustomQuerier(qp *QueryPlugin) func(ctx sdk.Context, request json.RawMessage) ([]byte, error) { return func(ctx sdk.Context, request json.RawMessage) ([]byte, error) { var contractQuery CyberQuery if err := json.Unmarshal(request, &contractQuery); err != nil { return nil, errorsmod.Wrap(err, "cyber query error") } switch { case contractQuery.ParticleRank != nil: return qp.moduleQueriers[ranktypes.ModuleName].HandleQuery(ctx, contractQuery) case contractQuery.GraphStats != nil: return qp.moduleQueriers[graphtypes.ModuleName].HandleQuery(ctx, contractQuery) case contractQuery.Thought != nil: return qp.moduleQueriers[dmntypes.ModuleName].HandleQuery(ctx, contractQuery) case contractQuery.ThoughtStats != nil: return qp.moduleQueriers[dmntypes.ModuleName].HandleQuery(ctx, contractQuery) case contractQuery.ThoughtsFees != nil: return qp.moduleQueriers[dmntypes.ModuleName].HandleQuery(ctx, contractQuery) case contractQuery.SourceRoutes != nil: return qp.moduleQueriers[gridtypes.ModuleName].HandleQuery(ctx, contractQuery) case contractQuery.SourceRoutedEnergy != nil: return qp.moduleQueriers[gridtypes.ModuleName].HandleQuery(ctx, contractQuery) case contractQuery.DestinationRoutedEnergy != nil: return qp.moduleQueriers[gridtypes.ModuleName].HandleQuery(ctx, contractQuery) case contractQuery.Route != nil: return qp.moduleQueriers[gridtypes.ModuleName].HandleQuery(ctx, contractQuery) case contractQuery.BandwidthLoad != nil: return qp.moduleQueriers[bandwidthtypes.ModuleName].HandleQuery(ctx, contractQuery) case contractQuery.BandwidthPrice != nil: return qp.moduleQueriers[bandwidthtypes.ModuleName].HandleQuery(ctx, contractQuery) case contractQuery.TotalBandwidth != nil: return qp.moduleQueriers[bandwidthtypes.ModuleName].HandleQuery(ctx, contractQuery) case contractQuery.NeuronBandwidth != nil: return qp.moduleQueriers[bandwidthtypes.ModuleName].HandleQuery(ctx, contractQuery) //case contractQuery.TokenFactory != nil: // return qp.moduleQueriers[tokenfactorytypes.ModuleName].HandleQuery(ctx, contractQuery) case contractQuery.FullDenom != nil: return qp.moduleQueriers[tokenfactorytypes.ModuleName].HandleQuery(ctx, contractQuery) case contractQuery.Admin != nil: return qp.moduleQueriers[tokenfactorytypes.ModuleName].HandleQuery(ctx, contractQuery) case contractQuery.Metadata != nil: return qp.moduleQueriers[tokenfactorytypes.ModuleName].HandleQuery(ctx, contractQuery) case contractQuery.DenomsByCreator != nil: return qp.moduleQueriers[tokenfactorytypes.ModuleName].HandleQuery(ctx, contractQuery) case contractQuery.Params != nil: return qp.moduleQueriers[tokenfactorytypes.ModuleName].HandleQuery(ctx, contractQuery) default: return nil, wasmvmtypes.UnsupportedRequest{Kind: "unknown cyber query variant"} } // Iterate over the module queriers and dispatch to the appropriate one //for _, querier := range qp.moduleQueriers { // resp, err := querier.HandleQuery(ctx, contractQuery) // if err != nil { // if err == ErrHandleQuery { // // This querier cannot handle the query, try the next one // continue // } // // Some other error occurred, return it // return nil, err // } // // Query was handled successfully, return the response // return resp, nil //} // //// If no querier could handle the query, return an error //return nil, wasmvmtypes.UnsupportedRequest{Kind: "unknown cyber query variant"} } } ================================================ FILE: plugins/types/dispatch_msg.go ================================================ package types import ( "encoding/json" "errors" bankkeeper "github.com/cosmos/cosmos-sdk/x/bank/keeper" dmnkeeper "github.com/cybercongress/go-cyber/v7/x/dmn/keeper" dmntypes "github.com/cybercongress/go-cyber/v7/x/dmn/types" graphkeeper "github.com/cybercongress/go-cyber/v7/x/graph/keeper" graphtypes "github.com/cybercongress/go-cyber/v7/x/graph/types" gridkeeper "github.com/cybercongress/go-cyber/v7/x/grid/keeper" gridtypes "github.com/cybercongress/go-cyber/v7/x/grid/types" resourceskeeper "github.com/cybercongress/go-cyber/v7/x/resources/keeper" resourcestypes "github.com/cybercongress/go-cyber/v7/x/resources/types" tokenfactorykeeper "github.com/cybercongress/go-cyber/v7/x/tokenfactory/keeper" tokenfactorytypes "github.com/cybercongress/go-cyber/v7/x/tokenfactory/types" errorsmod "cosmossdk.io/errors" wasmkeeper "github.com/CosmWasm/wasmd/x/wasm/keeper" wasmvmtypes "github.com/CosmWasm/wasmvm/types" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" ) var _ wasmkeeper.Messenger = (*CustomMessenger)(nil) var ErrHandleMsg = errors.New("error handle message") type ModuleMessenger interface { HandleMsg(ctx sdk.Context, contractAddr sdk.AccAddress, contractIBCPortID string, msg CyberMsg) ([]sdk.Event, [][]byte, error) } type CustomMessenger struct { wrapped wasmkeeper.Messenger moduleMessengers map[string]ModuleMessenger graphKeeper *graphkeeper.GraphKeeper dmnKeeper *dmnkeeper.Keeper gridKeeper *gridkeeper.Keeper resourcesKeeper *resourceskeeper.Keeper bankKeeper *bankkeeper.Keeper tokenFactoryKeeper *tokenfactorykeeper.Keeper } func CustomMessageDecorator( moduleMessengers map[string]ModuleMessenger, graph *graphkeeper.GraphKeeper, dmn *dmnkeeper.Keeper, grid *gridkeeper.Keeper, resources *resourceskeeper.Keeper, bank *bankkeeper.Keeper, tokenFactory *tokenfactorykeeper.Keeper, ) func(wasmkeeper.Messenger) wasmkeeper.Messenger { return func(old wasmkeeper.Messenger) wasmkeeper.Messenger { return &CustomMessenger{ wrapped: old, moduleMessengers: moduleMessengers, graphKeeper: graph, dmnKeeper: dmn, gridKeeper: grid, resourcesKeeper: resources, bankKeeper: bank, tokenFactoryKeeper: tokenFactory, } } } func (m *CustomMessenger) DispatchMsg(ctx sdk.Context, contractAddr sdk.AccAddress, contractIBCPortID string, msg wasmvmtypes.CosmosMsg) ([]sdk.Event, [][]byte, error) { // Return early if msg.Custom is nil if msg.Custom == nil { return m.wrapped.DispatchMsg(ctx, contractAddr, contractIBCPortID, msg) } var contractMsg CyberMsg if err := json.Unmarshal(msg.Custom, &contractMsg); err != nil { ctx.Logger().Debug("json.Unmarshal: failed to decode incoming custom cosmos message", "from_address", contractAddr.String(), "message", string(msg.Custom), "error", err, ) return nil, nil, errorsmod.Wrap(err, "cyber msg error") } switch { case contractMsg.Cyberlink != nil: return m.moduleMessengers[graphtypes.ModuleName].HandleMsg(ctx, contractAddr, contractIBCPortID, contractMsg) case contractMsg.Investmint != nil: return m.moduleMessengers[resourcestypes.ModuleName].HandleMsg(ctx, contractAddr, contractIBCPortID, contractMsg) case contractMsg.CreateEnergyRoute != nil: return m.moduleMessengers[gridtypes.ModuleName].HandleMsg(ctx, contractAddr, contractIBCPortID, contractMsg) case contractMsg.EditEnergyRoute != nil: return m.moduleMessengers[gridtypes.ModuleName].HandleMsg(ctx, contractAddr, contractIBCPortID, contractMsg) case contractMsg.EditEnergyRouteName != nil: return m.moduleMessengers[gridtypes.ModuleName].HandleMsg(ctx, contractAddr, contractIBCPortID, contractMsg) case contractMsg.DeleteEnergyRoute != nil: return m.moduleMessengers[gridtypes.ModuleName].HandleMsg(ctx, contractAddr, contractIBCPortID, contractMsg) case contractMsg.CreateThought != nil: return m.moduleMessengers[dmntypes.ModuleName].HandleMsg(ctx, contractAddr, contractIBCPortID, contractMsg) case contractMsg.ForgetThought != nil: return m.moduleMessengers[dmntypes.ModuleName].HandleMsg(ctx, contractAddr, contractIBCPortID, contractMsg) case contractMsg.ChangeThoughtInput != nil: return m.moduleMessengers[dmntypes.ModuleName].HandleMsg(ctx, contractAddr, contractIBCPortID, contractMsg) case contractMsg.ChangeThoughtPeriod != nil: return m.moduleMessengers[dmntypes.ModuleName].HandleMsg(ctx, contractAddr, contractIBCPortID, contractMsg) case contractMsg.ChangeThoughtBlock != nil: return m.moduleMessengers[dmntypes.ModuleName].HandleMsg(ctx, contractAddr, contractIBCPortID, contractMsg) case contractMsg.ChangeThoughtGasPrice != nil: return m.moduleMessengers[dmntypes.ModuleName].HandleMsg(ctx, contractAddr, contractIBCPortID, contractMsg) case contractMsg.ChangeThoughtParticle != nil: return m.moduleMessengers[dmntypes.ModuleName].HandleMsg(ctx, contractAddr, contractIBCPortID, contractMsg) case contractMsg.ChangeThoughtName != nil: return m.moduleMessengers[dmntypes.ModuleName].HandleMsg(ctx, contractAddr, contractIBCPortID, contractMsg) case contractMsg.TokenFactory != nil: return m.moduleMessengers[tokenfactorytypes.ModuleName].HandleMsg(ctx, contractAddr, contractIBCPortID, contractMsg) default: // If no handler could handle the message, return an error return nil, nil, errorsmod.Wrap(sdkerrors.ErrUnknownRequest, "unknown cyber message type") } // Iterate over the module message handlers and dispatch to the appropriate one //for _, handler := range m.moduleMessengers { // event, resp, err := handler.HandleMsg(ctx, contractAddr, contractIBCPortID, contractMsg) // if err != nil { // if err == ErrHandleMsg { // // This handler cannot handle the message, try the next one // continue // } // // Some other error occurred, return it // return nil, nil, err // } // // Message was handled successfully, return the result // return event, resp, nil //} // //// If no handler could handle the message, return an error //return nil, nil, errorsmod.Wrap(sdkerrors.ErrUnknownRequest, "unknown cyber message type") } ================================================ FILE: plugins/types/stargate_querier.go ================================================ package types import ( "fmt" wasmvmtypes "github.com/CosmWasm/wasmvm/types" abci "github.com/cometbft/cometbft/abci/types" "github.com/cosmos/cosmos-sdk/baseapp" "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" ) // StargateQuerier dispatches whitelisted stargate queries func StargateQuerier(queryRouter baseapp.GRPCQueryRouter, cdc codec.Codec) func(ctx sdk.Context, request *wasmvmtypes.StargateQuery) ([]byte, error) { return func(ctx sdk.Context, request *wasmvmtypes.StargateQuery) ([]byte, error) { protoResponseType, err := GetWhitelistedQuery(request.Path) if err != nil { return nil, err } // no matter what happens after this point, we must return // the response type to prevent sync.Pool from leaking. defer ReturnStargateResponseToPool(request.Path, protoResponseType) route := queryRouter.Route(request.Path) if route == nil { return nil, wasmvmtypes.UnsupportedRequest{Kind: fmt.Sprintf("No route to query '%s'", request.Path)} } res, err := route(ctx, abci.RequestQuery{ Data: request.Data, Path: request.Path, }) if err != nil { return nil, err } if res.Value == nil { return nil, fmt.Errorf("Res returned from abci query route is nil") } bz, err := ConvertProtoToJSONMarshal(protoResponseType, res.Value, cdc) if err != nil { return nil, err } return bz, nil } } // ConvertProtoToJSONMarshal unmarshals the given bytes into a proto message and then marshals it to json. // This is done so that clients calling stargate queries do not need to define their own proto unmarshalers, // being able to use response directly by json marshalling, which is supported in cosmwasm. func ConvertProtoToJSONMarshal(protoResponseType codec.ProtoMarshaler, bz []byte, cdc codec.Codec) ([]byte, error) { // unmarshal binary into stargate response data structure err := cdc.Unmarshal(bz, protoResponseType) if err != nil { return nil, wasmvmtypes.Unknown{} } bz, err = cdc.MarshalJSON(protoResponseType) if err != nil { return nil, wasmvmtypes.Unknown{} } protoResponseType.Reset() return bz, nil } ================================================ FILE: plugins/types/stargate_queries.go ================================================ package types import ( "fmt" wasmvmtypes "github.com/CosmWasm/wasmvm/types" "github.com/cosmos/cosmos-sdk/codec" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" distributiontypes "github.com/cosmos/cosmos-sdk/x/distribution/types" govtypesv1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1" slashingtypes "github.com/cosmos/cosmos-sdk/x/slashing/types" stakingtypes "github.com/cosmos/cosmos-sdk/x/staking/types" ibctransfertypes "github.com/cosmos/ibc-go/v7/modules/apps/transfer/types" tokenfactorytypes "github.com/cybercongress/go-cyber/v7/x/tokenfactory/types" "sync" ) // stargateResponsePools keeps whitelist and its deterministic // response binding for stargate queries. // CONTRACT: since results of queries go into blocks, queries being added here should always be // deterministic or can cause non-determinism in the state machine. // // The query is multi-threaded so we're using a sync.Pool // to manage the allocation and de-allocation of newly created // pb objects. var stargateResponsePools = make(map[string]*sync.Pool) // Note: When adding a migration here, we should also add it to the Async ICQ params in the upgrade. // In the future we may want to find a better way to keep these in sync //nolint:staticcheck func init() { // ibc queries setWhitelistedQuery("/ibc.applications.transfer.v1.Query/DenomTrace", &ibctransfertypes.QueryDenomTraceResponse{}) // cosmos-sdk queries // auth setWhitelistedQuery("/cosmos.auth.v1beta1.Query/Account", &authtypes.QueryAccountResponse{}) setWhitelistedQuery("/cosmos.auth.v1beta1.Query/Params", &authtypes.QueryParamsResponse{}) setWhitelistedQuery("/cosmos.auth.v1beta1.Query/ModuleAccounts", &authtypes.QueryModuleAccountsResponse{}) // bank setWhitelistedQuery("/cosmos.bank.v1beta1.Query/Balance", &banktypes.QueryBalanceResponse{}) setWhitelistedQuery("/cosmos.bank.v1beta1.Query/DenomMetadata", &banktypes.QueryDenomMetadataResponse{}) setWhitelistedQuery("/cosmos.bank.v1beta1.Query/DenomsMetadata", &banktypes.QueryDenomsMetadataResponse{}) setWhitelistedQuery("/cosmos.bank.v1beta1.Query/Params", &banktypes.QueryParamsResponse{}) setWhitelistedQuery("/cosmos.bank.v1beta1.Query/SupplyOf", &banktypes.QuerySupplyOfResponse{}) // distribution setWhitelistedQuery("/cosmos.distribution.v1beta1.Query/Params", &distributiontypes.QueryParamsResponse{}) setWhitelistedQuery("/cosmos.distribution.v1beta1.Query/DelegatorWithdrawAddress", &distributiontypes.QueryDelegatorWithdrawAddressResponse{}) setWhitelistedQuery("/cosmos.distribution.v1beta1.Query/ValidatorCommission", &distributiontypes.QueryValidatorCommissionResponse{}) // gov setWhitelistedQuery("/cosmos.gov.v1beta1.Query/Deposit", &govtypesv1.QueryDepositResponse{}) setWhitelistedQuery("/cosmos.gov.v1beta1.Query/Params", &govtypesv1.QueryParamsResponse{}) setWhitelistedQuery("/cosmos.gov.v1beta1.Query/Vote", &govtypesv1.QueryVoteResponse{}) // slashing setWhitelistedQuery("/cosmos.slashing.v1beta1.Query/Params", &slashingtypes.QueryParamsResponse{}) setWhitelistedQuery("/cosmos.slashing.v1beta1.Query/SigningInfo", &slashingtypes.QuerySigningInfoResponse{}) // staking setWhitelistedQuery("/cosmos.staking.v1beta1.Query/Delegation", &stakingtypes.QueryDelegationResponse{}) setWhitelistedQuery("/cosmos.staking.v1beta1.Query/Params", &stakingtypes.QueryParamsResponse{}) setWhitelistedQuery("/cosmos.staking.v1beta1.Query/Validator", &stakingtypes.QueryValidatorResponse{}) // tokenfactory setWhitelistedQuery("/osmosis.tokenfactory.v1beta1.Query/Params", &tokenfactorytypes.QueryParamsResponse{}) setWhitelistedQuery("/osmosis.tokenfactory.v1beta1.Query/DenomAuthorityMetadata", &tokenfactorytypes.QueryDenomAuthorityMetadataResponse{}) // Does not include denoms_from_creator, TBD if this is the index we want contracts to use instead of admin } // IsWhitelistedQuery returns if the query is not whitelisted. func IsWhitelistedQuery(queryPath string) error { _, isWhitelisted := stargateResponsePools[queryPath] if !isWhitelisted { return wasmvmtypes.UnsupportedRequest{Kind: fmt.Sprintf("'%s' path is not allowed from the contract", queryPath)} } return nil } // GetWhitelistedQuery returns the whitelisted query at the provided path. // If the query does not exist, or it was setup wrong by the chain, this returns an error. // CONTRACT: must call returnStargateResponseToPool in order to avoid pointless allocs. func GetWhitelistedQuery(queryPath string) (codec.ProtoMarshaler, error) { protoResponseAny, isWhitelisted := stargateResponsePools[queryPath] if !isWhitelisted { return nil, wasmvmtypes.UnsupportedRequest{Kind: fmt.Sprintf("'%s' path is not allowed from the contract", queryPath)} } protoMarshaler, ok := protoResponseAny.Get().(codec.ProtoMarshaler) if !ok { return nil, fmt.Errorf("failed to assert type to codec.ProtoMarshaler") } return protoMarshaler, nil } type protoTypeG[T any] interface { *T codec.ProtoMarshaler } // setWhitelistedQuery sets the whitelisted query at the provided path. // This method also creates a sync.Pool for the provided protoMarshaler. // We use generics so we can properly instantiate an object that the // queryPath expects as a response. func setWhitelistedQuery[T any, PT protoTypeG[T]](queryPath string, _ PT) { stargateResponsePools[queryPath] = &sync.Pool{ New: func() any { return PT(new(T)) }, } } // ReturnStargateResponseToPool returns the provided protoMarshaler to the appropriate pool based on it's query path. func ReturnStargateResponseToPool(queryPath string, pb codec.ProtoMarshaler) { stargateResponsePools[queryPath].Put(pb) } func GetStargateWhitelistedPaths() (keys []string) { // Iterate over the map and collect the keys keys = make([]string, 0, len(stargateResponsePools)) for k := range stargateResponsePools { keys = append(keys, k) } return keys } ================================================ FILE: plugins/types/types.go ================================================ package types import ( bandwidthtypes "github.com/cybercongress/go-cyber/v7/x/bandwidth/types" dmntypes "github.com/cybercongress/go-cyber/v7/x/dmn/types" graphtypes "github.com/cybercongress/go-cyber/v7/x/graph/types" gridtypes "github.com/cybercongress/go-cyber/v7/x/grid/types" ranktypes "github.com/cybercongress/go-cyber/v7/x/rank/types" resourcestypes "github.com/cybercongress/go-cyber/v7/x/resources/types" tokenfactorytypes "github.com/cybercongress/go-cyber/v7/x/tokenfactory/wasm/types" ) type CyberQuery struct { // rankKeeper queries ParticleRank *ranktypes.QueryRankRequest `json:"particle_rank,omitempty"` // TODO add IsLinkExist, IsAnyLinkExist // graph queries GraphStats *graphtypes.QueryGraphStatsRequest `json:"graph_stats,omitempty"` // dmn queries Thought *dmntypes.QueryThoughtParamsRequest `json:"thought,omitempty"` ThoughtStats *dmntypes.QueryThoughtParamsRequest `json:"thought_stats,omitempty"` ThoughtsFees *dmntypes.QueryThoughtsFeesRequest `json:"thoughts_fees,omitempty"` // grid queries SourceRoutes *gridtypes.QuerySourceRequest `json:"source_routes,omitempty"` SourceRoutedEnergy *gridtypes.QuerySourceRequest `json:"source_routed_energy,omitempty"` DestinationRoutedEnergy *gridtypes.QueryDestinationRequest `json:"destination_routed_energy,omitempty"` Route *gridtypes.QueryRouteRequest `json:"route,omitempty"` // bandwidth queries BandwidthLoad *bandwidthtypes.QueryLoadRequest `json:"bandwidth_load,omitempty"` BandwidthPrice *bandwidthtypes.QueryPriceRequest `json:"bandwidth_price,omitempty"` TotalBandwidth *bandwidthtypes.QueryTotalBandwidthRequest `json:"total_bandwidth,omitempty"` NeuronBandwidth *bandwidthtypes.QueryNeuronBandwidthRequest `json:"neuron_bandwidth,omitempty"` // token factory queries //TokenFactory *types.TokenFactoryQuery `json:"token_factory,omitempty"` FullDenom *tokenfactorytypes.FullDenom `json:"full_denom,omitempty"` Admin *tokenfactorytypes.DenomAdmin `json:"admin,omitempty"` Metadata *tokenfactorytypes.GetMetadata `json:"metadata,omitempty"` DenomsByCreator *tokenfactorytypes.DenomsByCreator `json:"denoms_by_creator,omitempty"` Params *tokenfactorytypes.GetParams `json:"params,omitempty"` } type CyberMsg struct { // graph messages Cyberlink *graphtypes.MsgCyberlink `json:"cyberlink,omitempty"` // dmn messages CreateThought *dmntypes.MsgCreateThought `json:"create_thought,omitempty"` ForgetThought *dmntypes.MsgForgetThought `json:"forget_thought,omitempty"` ChangeThoughtInput *dmntypes.MsgChangeThoughtInput `json:"change_thought_input,omitempty"` ChangeThoughtPeriod *dmntypes.MsgChangeThoughtPeriod `json:"change_thought_period,omitempty"` ChangeThoughtBlock *dmntypes.MsgChangeThoughtBlock `json:"change_thought_block,omitempty"` ChangeThoughtGasPrice *dmntypes.MsgChangeThoughtGasPrice `json:"change_thought_gas_price,omitempty"` ChangeThoughtParticle *dmntypes.MsgChangeThoughtParticle `json:"change_thought_particle,omitempty"` ChangeThoughtName *dmntypes.MsgChangeThoughtName `json:"change_thought_name,omitempty"` // grid messages CreateEnergyRoute *gridtypes.MsgCreateRoute `json:"create_energy_route,omitempty"` EditEnergyRoute *gridtypes.MsgEditRoute `json:"edit_energy_route,omitempty"` EditEnergyRouteName *gridtypes.MsgEditRouteName `json:"edit_energy_route_name,omitempty"` DeleteEnergyRoute *gridtypes.MsgDeleteRoute `json:"delete_energy_route,omitempty"` // resources messages Investmint *resourcestypes.MsgInvestmint `json:"investmint,omitempty"` // token factory messages TokenFactory *tokenfactorytypes.TokenFactoryMsg `json:"token_factory,omitempty"` } ================================================ FILE: plugins/wasm.go ================================================ package plugins import ( "github.com/CosmWasm/wasmd/x/wasm" wasmkeeper "github.com/CosmWasm/wasmd/x/wasm/keeper" "github.com/cosmos/cosmos-sdk/baseapp" "github.com/cosmos/cosmos-sdk/codec" authkeeper "github.com/cosmos/cosmos-sdk/x/auth/keeper" bankkeeper "github.com/cosmos/cosmos-sdk/x/bank/keeper" bandwidthtypes "github.com/cybercongress/go-cyber/v7/x/bandwidth/types" dmntypes "github.com/cybercongress/go-cyber/v7/x/dmn/types" graphtypes "github.com/cybercongress/go-cyber/v7/x/graph/types" gridtypes "github.com/cybercongress/go-cyber/v7/x/grid/types" ranktypes "github.com/cybercongress/go-cyber/v7/x/rank/types" resourcestypes "github.com/cybercongress/go-cyber/v7/x/resources/types" tokenfactorykeeper "github.com/cybercongress/go-cyber/v7/x/tokenfactory/keeper" tokenfactorytypes "github.com/cybercongress/go-cyber/v7/x/tokenfactory/types" "github.com/cybercongress/go-cyber/v7/plugins/types" cyberbankkeeper "github.com/cybercongress/go-cyber/v7/x/cyberbank/keeper" dmnwasm "github.com/cybercongress/go-cyber/v7/x/dmn/wasm" resourceskeeper "github.com/cybercongress/go-cyber/v7/x/resources/keeper" pluginstypes "github.com/cybercongress/go-cyber/v7/plugins/types" bandwidthkeeper "github.com/cybercongress/go-cyber/v7/x/bandwidth/keeper" bandwidthwasm "github.com/cybercongress/go-cyber/v7/x/bandwidth/wasm" dmnkeeper "github.com/cybercongress/go-cyber/v7/x/dmn/keeper" graphkeeper "github.com/cybercongress/go-cyber/v7/x/graph/keeper" graphwasm "github.com/cybercongress/go-cyber/v7/x/graph/wasm" gridkeeper "github.com/cybercongress/go-cyber/v7/x/grid/keeper" gridwasm "github.com/cybercongress/go-cyber/v7/x/grid/wasm" rankkeeper "github.com/cybercongress/go-cyber/v7/x/rank/keeper" rankwasm "github.com/cybercongress/go-cyber/v7/x/rank/wasm" resourceswasm "github.com/cybercongress/go-cyber/v7/x/resources/wasm" tokenfactorywasm "github.com/cybercongress/go-cyber/v7/x/tokenfactory/wasm" ) func RegisterCustomPlugins( rank *rankkeeper.StateKeeper, graph *graphkeeper.GraphKeeper, dmn *dmnkeeper.Keeper, grid *gridkeeper.Keeper, bandwidth *bandwidthkeeper.BandwidthMeter, resources *resourceskeeper.Keeper, graphIndex *graphkeeper.IndexKeeper, account *authkeeper.AccountKeeper, cyberbank *cyberbankkeeper.IndexedKeeper, bank *bankkeeper.Keeper, tokenFactory *tokenfactorykeeper.Keeper, ) []wasmkeeper.Option { rankQuerier := rankwasm.NewWasmQuerier(rank) graphQuerier := graphwasm.NewWasmQuerier(graph) dmnQuerier := dmnwasm.NewWasmQuerier(dmn) gridQuerier := gridwasm.NewWasmQuerier(grid) bandwidthQuerier := bandwidthwasm.NewWasmQuerier(bandwidth) tokenFactoryQuerier := tokenfactorywasm.NewWasmQuerier(*bank, tokenFactory) graphMessenger := graphwasm.NewMessenger(graph, graphIndex, account, cyberbank, bandwidth) dmnMessenger := dmnwasm.NewMessenger(dmn) gridMessenger := gridwasm.NewMessenger(grid) resourcesMessenger := resourceswasm.NewMessenger(resources) tokenFactoryMessenger := tokenfactorywasm.NewMessenger(*bank, tokenFactory) moduleQueriers := map[string]types.ModuleQuerier{ ranktypes.ModuleName: rankQuerier, graphtypes.ModuleName: graphQuerier, dmntypes.ModuleName: dmnQuerier, gridtypes.ModuleName: gridQuerier, bandwidthtypes.ModuleName: bandwidthQuerier, tokenfactorytypes.ModuleName: tokenFactoryQuerier, } wasmQueryPlugin := types.NewQueryPlugin( moduleQueriers, rank, graph, dmn, grid, bandwidth, bank, tokenFactory, ) queryPluginOpt := wasmkeeper.WithQueryPlugins(&wasmkeeper.QueryPlugins{ Custom: types.CustomQuerier(wasmQueryPlugin), }) moduleMessengers := map[string]types.ModuleMessenger{ graphtypes.ModuleName: graphMessenger, dmntypes.ModuleName: dmnMessenger, gridtypes.ModuleName: gridMessenger, resourcestypes.ModuleName: resourcesMessenger, tokenfactorytypes.ModuleName: tokenFactoryMessenger, } messengerDecoratorOpt := wasmkeeper.WithMessageHandlerDecorator( types.CustomMessageDecorator( moduleMessengers, graph, dmn, grid, resources, bank, tokenFactory, ), ) return []wasm.Option{ queryPluginOpt, messengerDecoratorOpt, } } func RegisterStargateQueries(queryRouter baseapp.GRPCQueryRouter, codec codec.Codec) []wasmkeeper.Option { queryPluginOpt := wasmkeeper.WithQueryPlugins(&wasmkeeper.QueryPlugins{ Stargate: pluginstypes.StargateQuerier(queryRouter, codec), }) return []wasmkeeper.Option{ queryPluginOpt, } } ================================================ FILE: proto/buf.gen.doc.yaml ================================================ version: v1 plugins: - name: doc out: ../docs/proto opt: ../docs/proto/protodoc-markdown.tmpl,proto-docs.md strategy: all ================================================ FILE: proto/buf.gen.gogo.yaml ================================================ version: v1 plugins: - name: gocosmos out: .. opt: plugins=grpc,Mgoogle/protobuf/any.proto=github.com/cosmos/cosmos-sdk/codec/types - name: grpc-gateway out: .. opt: logtostderr=true,allow_colon_final_segments=true ================================================ FILE: proto/buf.gen.swagger.yaml ================================================ version: v1 plugins: - name: swagger out: ../tmp-swagger-gen opt: logtostderr=true,fqn_for_swagger_name=true,simple_operation_ids=true ================================================ FILE: proto/buf.yaml ================================================ # Generated by "buf config migrate-v1beta1". Edit as necessary, and # remove this comment when you're finished. # # This module represents the "proto" root found in # the previous configuration. version: v1 name: buf.build/cybercongress/go-cyber deps: - buf.build/cosmos/cosmos-sdk:v0.47.0 - buf.build/cosmos/cosmos-proto:1935555c206d4afb9e94615dfd0fad31 - buf.build/cosmos/gogo-proto:a14993478f40695898ed8a86931094b6656e8a5d - buf.build/googleapis/googleapis:8d7204855ec14631a499bd7393ce1970 - buf.build/cosmos/ics23:b1abd8678aab07165efd453c96796a179eb3131f breaking: use: - FILE lint: use: - DEFAULT except: - UNARY_RPC - COMMENT_FIELD - SERVICE_SUFFIX - PACKAGE_VERSION_SUFFIX - COMMENTS - RPC_RESPONSE_STANDARD_NAME - RPC_REQUEST_RESPONSE_UNIQUE - RPC_REQUEST_STANDARD_NAME - PACKAGE_DIRECTORY_MATCH - RPC_REQUEST_RESPONSE_UNIQUE - COMMENTS - RPC_RESPONSE_STANDARD_NAME - FIELD_LOWER_SNAKE_CASE ================================================ FILE: proto/cyber/bandwidth/v1beta1/genesis.proto ================================================ syntax = "proto3"; package cyber.bandwidth.v1beta1; import "gogoproto/gogo.proto"; import "cyber/bandwidth/v1beta1/types.proto"; option go_package = "github.com/cybercongress/go-cyber/x/bandwidth/types"; message GenesisState { Params params = 1 [ (gogoproto.nullable) = false ]; } ================================================ FILE: proto/cyber/bandwidth/v1beta1/query.proto ================================================ syntax = "proto3"; package cyber.bandwidth.v1beta1; import "gogoproto/gogo.proto"; import "google/api/annotations.proto"; import "cyber/bandwidth/v1beta1/types.proto"; option go_package = "github.com/cybercongress/go-cyber/x/bandwidth/types"; service Query { rpc Load(QueryLoadRequest) returns (QueryLoadResponse) { option (google.api.http).get = "/cyber/bandwidth/v1beta1/bandwidth/load"; } rpc Price(QueryPriceRequest) returns (QueryPriceResponse) { option (google.api.http).get = "/cyber/bandwidth/v1beta1/bandwidth/price"; } rpc TotalBandwidth(QueryTotalBandwidthRequest) returns (QueryTotalBandwidthResponse) { option (google.api.http).get = "/cyber/bandwidth/v1beta1/bandwidth/total"; } rpc NeuronBandwidth(QueryNeuronBandwidthRequest) returns (QueryNeuronBandwidthResponse) { option (google.api.http).get = "/cyber/bandwidth/v1beta1/bandwidth/neuron/{neuron}"; } rpc Params(QueryParamsRequest) returns (QueryParamsResponse) { option (google.api.http).get = "/cyber/bandwidth/v1beta1/bandwidth/params"; } } message QueryLoadRequest {} message QueryLoadResponse { string load = 1 [ (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", (gogoproto.nullable) = false ]; } message QueryPriceRequest {} message QueryPriceResponse { string price = 1 [ (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", (gogoproto.nullable) = false ]; } message QueryTotalBandwidthRequest {} message QueryTotalBandwidthResponse { uint64 total_bandwidth = 1; } message QueryNeuronBandwidthRequest { string neuron = 1; } message QueryNeuronBandwidthResponse { NeuronBandwidth neuron_bandwidth = 1 [ (gogoproto.nullable) = false ]; } message QueryParamsRequest {} message QueryParamsResponse { Params params = 1 [ (gogoproto.nullable) = false ]; } ================================================ FILE: proto/cyber/bandwidth/v1beta1/tx.proto ================================================ syntax = "proto3"; package cyber.bandwidth.v1beta1; import "gogoproto/gogo.proto"; import "cosmos/msg/v1/msg.proto"; import "cosmos_proto/cosmos.proto"; import "cyber/bandwidth/v1beta1/types.proto"; option go_package = "github.com/cybercongress/go-cyber/x/bandwidth/types"; service Msg { rpc UpdateParams(MsgUpdateParams) returns (MsgUpdateParamsResponse); } message MsgUpdateParams { option (cosmos.msg.v1.signer) = "authority"; string authority = 1 [ (cosmos_proto.scalar) = "cosmos.AddressString" ]; Params params = 2 [ (gogoproto.nullable) = false ]; } message MsgUpdateParamsResponse {} ================================================ FILE: proto/cyber/bandwidth/v1beta1/types.proto ================================================ syntax = "proto3"; package cyber.bandwidth.v1beta1; import "gogoproto/gogo.proto"; option go_package = "github.com/cybercongress/go-cyber/x/bandwidth/types"; message Params { option (gogoproto.equal) = true; uint64 recovery_period = 1; uint64 adjust_price_period = 2; string base_price = 3 [ (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", (gogoproto.nullable) = false ]; string base_load = 4 [ (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", (gogoproto.nullable) = false ]; uint64 max_block_bandwidth = 5; } message NeuronBandwidth { option (gogoproto.equal) = false; option (gogoproto.goproto_getters) = false; string neuron = 1; uint64 remained_value = 2; uint64 last_updated_block = 3; uint64 max_value = 4; } message Price { option (gogoproto.equal) = false; option (gogoproto.goproto_getters) = false; string price = 1 [ (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", (gogoproto.nullable) = false ]; } ================================================ FILE: proto/cyber/clock/v1/clock.proto ================================================ syntax = "proto3"; package cyber.clock.v1; option go_package = "github.com/cybercongress/go-cyber/x/clock/types"; // This object is used to store the contract address and the // jail status of the contract. message ClockContract { // The address of the contract. string contract_address = 1; // The jail status of the contract. bool is_jailed = 2; } ================================================ FILE: proto/cyber/clock/v1/genesis.proto ================================================ syntax = "proto3"; package cyber.clock.v1; import "gogoproto/gogo.proto"; option go_package = "github.com/cybercongress/go-cyber/x/clock/types"; // GenesisState - initial state of module message GenesisState { // Params of this module Params params = 1 [ (gogoproto.nullable) = false, (gogoproto.jsontag) = "params,omitempty" ]; } // Params defines the set of module parameters. message Params { // contract_gas_limit defines the maximum amount of gas that can be used by a // contract. uint64 contract_gas_limit = 1 [ (gogoproto.jsontag) = "contract_gas_limit,omitempty", (gogoproto.moretags) = "yaml:\"contract_gas_limit\"" ]; } ================================================ FILE: proto/cyber/clock/v1/query.proto ================================================ syntax = "proto3"; package cyber.clock.v1; import "cosmos/base/query/v1beta1/pagination.proto"; import "gogoproto/gogo.proto"; import "google/api/annotations.proto"; import "cyber/clock/v1/genesis.proto"; import "cyber/clock/v1/clock.proto"; option go_package = "github.com/cybercongress/go-cyber/x/clock/types"; // Query defines the gRPC querier service. service Query { // ClockContracts rpc ClockContracts(QueryClockContracts) returns (QueryClockContractsResponse) { option (google.api.http).get = "/cyber/clock/v1/contracts"; } // ClockContract rpc ClockContract(QueryClockContract) returns (QueryClockContractResponse) { option (google.api.http).get = "/cyber/clock/v1/contracts/{contract_address}"; } // Params rpc Params(QueryParamsRequest) returns (QueryParamsResponse) { option (google.api.http).get = "/cyber/clock/v1/params"; } } // QueryClockContracts is the request type to get all contracts. message QueryClockContracts { // pagination defines an optional pagination for the request. cosmos.base.query.v1beta1.PageRequest pagination = 1; } // QueryClockContractsResponse is the response type for the Query/ClockContracts // RPC method. message QueryClockContractsResponse { // clock_contracts are the clock contracts. repeated ClockContract clock_contracts = 1 [ (gogoproto.nullable) = false ]; // pagination defines the pagination in the response. cosmos.base.query.v1beta1.PageResponse pagination = 2; } // QueryClockContract is the request type to get a single contract. message QueryClockContract { // contract_address is the address of the contract to query. string contract_address = 1; } // QueryClockContractResponse is the response type for the Query/ClockContract // RPC method. message QueryClockContractResponse { // contract is the clock contract. ClockContract clock_contract = 1 [ (gogoproto.nullable) = false ]; } // QueryParams is the request type to get all module params. message QueryParamsRequest {} // QueryClockContractsResponse is the response type for the Query/ClockContracts // RPC method. message QueryParamsResponse { Params params = 1 [ (gogoproto.jsontag) = "params", (gogoproto.moretags) = "yaml:\"params\"" ]; } ================================================ FILE: proto/cyber/clock/v1/tx.proto ================================================ syntax = "proto3"; package cyber.clock.v1; option go_package = "github.com/cybercongress/go-cyber/x/clock/types"; import "google/api/annotations.proto"; import "cosmos/msg/v1/msg.proto"; import "cyber/clock/v1/genesis.proto"; import "gogoproto/gogo.proto"; import "cosmos_proto/cosmos.proto"; // Msg defines the Msg service. service Msg { // RegisterClockContract defines the endpoint for // registering a new clock contract. rpc RegisterClockContract(MsgRegisterClockContract) returns (MsgRegisterClockContractResponse) { option (google.api.http).post = "/cyber/clock/v1/tx/register"; }; // UnregisterClockContract defines the endpoint for // unregistering a clock contract. rpc UnregisterClockContract(MsgUnregisterClockContract) returns (MsgUnregisterClockContractResponse) { option (google.api.http).post = "/cyber/clock/v1/tx/unregister"; }; // UnjailClockContract defines the endpoint for // unjailing a clock contract. rpc UnjailClockContract(MsgUnjailClockContract) returns (MsgUnjailClockContractResponse) { option (google.api.http).post = "/cyber/clock/v1/tx/unjail"; }; // UpdateParams defines a governance operation for updating the x/clock module // parameters. The authority is hard-coded to the x/gov module account. // // Since: cosmos-sdk 0.47 rpc UpdateParams(MsgUpdateParams) returns (MsgUpdateParamsResponse); } // MsgRegisterClockContract is the Msg/RegisterClockContract request type. message MsgRegisterClockContract { // The address of the sender. string sender_address = 1; // The address of the contract to register. string contract_address = 2; } // MsgRegisterClockContractResponse defines the response structure for executing // a MsgRegisterClockContract message. message MsgRegisterClockContractResponse {} // MsgUnregisterClockContract is the Msg/UnregisterClockContract request type. message MsgUnregisterClockContract { // The address of the sender. string sender_address = 1; // The address of the contract to unregister. string contract_address = 2; } // MsgUnregisterClockContractResponse defines the response structure for // executing a MsgUnregisterClockContract message. message MsgUnregisterClockContractResponse {} // MsgUnjailClockContract is the Msg/UnjailClockContract request type. message MsgUnjailClockContract { // The address of the sender. string sender_address = 1; // The address of the contract to unjail. string contract_address = 2; } // MsgUnjailClockContractResponse defines the response structure for executing a // MsgUnjailClockContract message. message MsgUnjailClockContractResponse {} // MsgUpdateParams is the Msg/UpdateParams request type. // // Since: cosmos-sdk 0.47 message MsgUpdateParams { option (cosmos.msg.v1.signer) = "authority"; // authority is the address of the governance account. string authority = 1 [ (cosmos_proto.scalar) = "cosmos.AddressString" ]; // params defines the x/clock parameters to update. // // NOTE: All parameters must be supplied. Params params = 2 [ (gogoproto.nullable) = false ]; } // MsgUpdateParamsResponse defines the response structure for executing a // MsgUpdateParams message. // // Since: cosmos-sdk 0.47 message MsgUpdateParamsResponse {} ================================================ FILE: proto/cyber/dmn/v1beta1/genesis.proto ================================================ syntax = "proto3"; package cyber.dmn.v1beta1; import "gogoproto/gogo.proto"; import "cyber/dmn/v1beta1/types.proto"; option go_package = "github.com/cybercongress/go-cyber/x/dmn/types"; message GenesisState { Params params = 1 [ (gogoproto.nullable) = false ]; } ================================================ FILE: proto/cyber/dmn/v1beta1/query.proto ================================================ syntax = "proto3"; package cyber.dmn.v1beta1; import "gogoproto/gogo.proto"; import "google/api/annotations.proto"; import "cosmos/base/v1beta1/coin.proto"; import "cyber/dmn/v1beta1/types.proto"; option go_package = "github.com/cybercongress/go-cyber/x/dmn/types"; service Query { rpc Params(QueryParamsRequest) returns (QueryParamsResponse) { option (google.api.http).get = "/cyber/dmn/v1beta1/dmn/params"; } rpc Thought(QueryThoughtParamsRequest) returns (QueryThoughtResponse) { option (google.api.http).get = "/cyber/dmn/v1beta1/dmn/thought"; } rpc ThoughtStats(QueryThoughtParamsRequest) returns (QueryThoughtStatsResponse) { option (google.api.http).get = "/cyber/dmn/v1beta1/dmn/thought_stats"; } rpc Thoughts(QueryThoughtsRequest) returns (QueryThoughtsResponse) { option (google.api.http).get = "/cyber/dmn/v1beta1/dmn/thoughts"; } rpc ThoughtsStats(QueryThoughtsStatsRequest) returns (QueryThoughtsStatsResponse) { option (google.api.http).get = "/cyber/dmn/v1beta1/dmn/thoughts_stats"; } rpc ThoughtsFees(QueryThoughtsFeesRequest) returns (QueryThoughtsFeesResponse) { option (google.api.http).get = "/cyber/dmn/v1beta1/dmn/thoughts_fees"; } } message QueryParamsRequest {} message QueryParamsResponse { Params params = 1 [ (gogoproto.nullable) = false ]; } message QueryThoughtParamsRequest { string program = 1; string name = 2; } message QueryThoughtResponse { Thought thought = 1 [ (gogoproto.nullable) = false ]; } message QueryThoughtStatsResponse { ThoughtStats thought_stats = 1 [ (gogoproto.nullable) = false ]; } message QueryThoughtsRequest {} message QueryThoughtsResponse { repeated Thought thoughts = 1 [ (gogoproto.nullable) = false, (gogoproto.castrepeated) = "Thoughts" ]; } message QueryThoughtsStatsRequest {} message QueryThoughtsStatsResponse { repeated ThoughtStats thoughts_stats = 1 [ (gogoproto.nullable) = false, (gogoproto.castrepeated) = "ThoughtsStats" ]; } message QueryThoughtsFeesRequest {} message QueryThoughtsFeesResponse { repeated cosmos.base.v1beta1.Coin fees = 3 [ (gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" ]; } ================================================ FILE: proto/cyber/dmn/v1beta1/tx.proto ================================================ syntax = "proto3"; package cyber.dmn.v1beta1; import "gogoproto/gogo.proto"; import "cosmos/msg/v1/msg.proto"; import "cosmos_proto/cosmos.proto"; import "cyber/dmn/v1beta1/types.proto"; import "cosmos/base/v1beta1/coin.proto"; option go_package = "github.com/cybercongress/go-cyber/x/dmn/types"; service Msg { rpc CreateThought(MsgCreateThought) returns (MsgCreateThoughtResponse); rpc ForgetThought(MsgForgetThought) returns (MsgForgetThoughtResponse); rpc ChangeThoughtParticle(MsgChangeThoughtParticle) returns (MsgChangeThoughtParticleResponse); rpc ChangeThoughtName(MsgChangeThoughtName) returns (MsgChangeThoughtNameResponse); rpc ChangeThoughtInput(MsgChangeThoughtInput) returns (MsgChangeThoughtInputResponse); rpc ChangeThoughtGasPrice(MsgChangeThoughtGasPrice) returns (MsgChangeThoughtGasPriceResponse); rpc ChangeThoughtPeriod(MsgChangeThoughtPeriod) returns (MsgChangeThoughtPeriodResponse); rpc ChangeThoughtBlock(MsgChangeThoughtBlock) returns (MsgChangeThoughtBlockResponse); rpc UpdateParams(MsgUpdateParams) returns (MsgUpdateParamsResponse); } message MsgCreateThought { string program = 1; Trigger trigger = 2 [ (gogoproto.nullable) = false ]; Load load = 3 [ (gogoproto.nullable) = false ]; string name = 4; string particle = 5; } message MsgForgetThought { string program = 1; string name = 2; } message MsgChangeThoughtParticle { string program = 1; string name = 2; string particle = 3; } message MsgChangeThoughtName { string program = 1; string name = 2; string new_name = 3; } message MsgChangeThoughtInput { string program = 1; string name = 2; string input = 3; } message MsgChangeThoughtGasPrice { string program = 1; string name = 2; cosmos.base.v1beta1.Coin gas_price = 3 [ (gogoproto.nullable) = false, (gogoproto.casttype) = "github.com/cosmos/cosmos-sdk/types.Coin" ]; } message MsgChangeThoughtPeriod { string program = 1; string name = 2; uint64 period = 3; } message MsgChangeThoughtBlock { string program = 1; string name = 2; uint64 block = 3; } message MsgUpdateParams { option (cosmos.msg.v1.signer) = "authority"; string authority = 1 [ (cosmos_proto.scalar) = "cosmos.AddressString" ]; Params params = 2 [ (gogoproto.nullable) = false ]; } message MsgCreateThoughtResponse {} message MsgForgetThoughtResponse {} message MsgChangeThoughtParticleResponse {} message MsgChangeThoughtNameResponse {} message MsgChangeThoughtInputResponse {} message MsgChangeThoughtGasPriceResponse {} message MsgChangeThoughtPeriodResponse {} message MsgChangeThoughtBlockResponse {} message MsgUpdateParamsResponse {} ================================================ FILE: proto/cyber/dmn/v1beta1/types.proto ================================================ syntax = "proto3"; package cyber.dmn.v1beta1; import "gogoproto/gogo.proto"; import "cosmos/base/v1beta1/coin.proto"; option go_package = "github.com/cybercongress/go-cyber/x/dmn/types"; message Params { option (gogoproto.equal) = true; uint32 max_slots = 1; uint32 max_gas = 2; uint32 fee_ttl = 3; } message Thought { option (gogoproto.equal) = false; option (gogoproto.goproto_getters) = false; string program = 1; Trigger trigger = 2 [ (gogoproto.nullable) = false ]; Load load = 3 [ (gogoproto.nullable) = false ]; string name = 4; string particle = 5; } message Trigger { option (gogoproto.equal) = false; option (gogoproto.goproto_getters) = false; uint64 period = 1; uint64 block = 2; } message Load { option (gogoproto.equal) = false; option (gogoproto.goproto_getters) = false; string input = 1; cosmos.base.v1beta1.Coin gas_price = 2 [ (gogoproto.casttype) = "github.com/cosmos/cosmos-sdk/types.Coin", (gogoproto.nullable) = false ]; } message ThoughtStats { option (gogoproto.equal) = false; option (gogoproto.goproto_getters) = false; string program = 1; string name = 2; uint64 calls = 3; uint64 fees = 4; uint64 gas = 5; uint64 last_block = 6; } ================================================ FILE: proto/cyber/graph/v1beta1/query.proto ================================================ syntax = "proto3"; package cyber.graph.v1beta1; import "google/api/annotations.proto"; option go_package = "github.com/cybercongress/go-cyber/x/graph/types"; service Query { rpc GraphStats(QueryGraphStatsRequest) returns (QueryGraphStatsResponse) { option (google.api.http).get = "/cyber/graph/v1beta1/graph_stats"; } rpc BurnStats(QueryBurnStatsRequest) returns (QueryBurnStatsResponse) { option (google.api.http).get = "/cyber/graph/v1beta1/burn_stats"; } } message QueryGraphStatsRequest {} message QueryGraphStatsResponse { uint64 cyberlinks = 1; uint64 particles = 2; } message QueryBurnStatsRequest {} message QueryBurnStatsResponse { uint64 millivolt = 1; uint64 milliampere = 2; } ================================================ FILE: proto/cyber/graph/v1beta1/tx.proto ================================================ syntax = "proto3"; package cyber.graph.v1beta1; import "gogoproto/gogo.proto"; import "cyber/graph/v1beta1/types.proto"; option go_package = "github.com/cybercongress/go-cyber/x/graph/types"; service Msg { rpc Cyberlink(MsgCyberlink) returns (MsgCyberlinkResponse); } message MsgCyberlink { option (gogoproto.equal) = false; option (gogoproto.goproto_getters) = false; string neuron = 1; repeated cyber.graph.v1beta1.Link links = 2 [ (gogoproto.nullable) = false ]; } message MsgCyberlinkResponse {} ================================================ FILE: proto/cyber/graph/v1beta1/types.proto ================================================ syntax = "proto3"; package cyber.graph.v1beta1; import "gogoproto/gogo.proto"; option go_package = "github.com/cybercongress/go-cyber/x/graph/types"; message Link { option (gogoproto.equal) = false; option (gogoproto.goproto_getters) = false; string from = 1; string to = 2; } ================================================ FILE: proto/cyber/grid/v1beta1/genesis.proto ================================================ syntax = "proto3"; package cyber.grid.v1beta1; import "gogoproto/gogo.proto"; import "cyber/grid/v1beta1/types.proto"; option go_package = "github.com/cybercongress/go-cyber/x/grid/types"; message GenesisState { Params params = 1 [ (gogoproto.nullable) = false ]; repeated Route routes = 2 [ (gogoproto.nullable) = false, (gogoproto.castrepeated) = "Routes" ]; } ================================================ FILE: proto/cyber/grid/v1beta1/query.proto ================================================ syntax = "proto3"; package cyber.grid.v1beta1; import "gogoproto/gogo.proto"; import "google/api/annotations.proto"; import "cyber/grid/v1beta1/types.proto"; import "cosmos/base/v1beta1/coin.proto"; import "cosmos/base/query/v1beta1/pagination.proto"; option go_package = "github.com/cybercongress/go-cyber/x/grid/types"; service Query { rpc Params(QueryParamsRequest) returns (QueryParamsResponse) { option (google.api.http).get = "/cyber/grid/v1beta1/grid/params"; } rpc SourceRoutes(QuerySourceRequest) returns (QueryRoutesResponse) { option (google.api.http).get = "/cyber/grid/v1beta1/grid/source_routes"; } rpc DestinationRoutes(QueryDestinationRequest) returns (QueryRoutesResponse) { option (google.api.http).get = "/cyber/grid/v1beta1/grid/destination_routes"; } rpc DestinationRoutedEnergy(QueryDestinationRequest) returns (QueryRoutedEnergyResponse) { option (google.api.http).get = "/cyber/grid/v1beta1/grid/destination_routed_energy"; } rpc SourceRoutedEnergy(QuerySourceRequest) returns (QueryRoutedEnergyResponse) { option (google.api.http).get = "/cyber/grid/v1beta1/grid/source_routed_energy"; } rpc Route(QueryRouteRequest) returns (QueryRouteResponse) { option (google.api.http).get = "/cyber/grid/v1beta1/grid/route"; } rpc Routes(QueryRoutesRequest) returns (QueryRoutesResponse) { option (google.api.http).get = "/cyber/grid/v1beta1/grid/routes"; } } message QueryParamsRequest {} message QueryParamsResponse { Params params = 1 [ (gogoproto.nullable) = false ]; } message QuerySourceRequest { string source = 1; } message QueryDestinationRequest { string destination = 1; } message QueryRoutedEnergyResponse { repeated cosmos.base.v1beta1.Coin value = 1 [ (gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" ]; } message QueryRouteRequest { string source = 1; string destination = 2; } message QueryRouteResponse { Route route = 1 [ (gogoproto.nullable) = false ]; } message QueryRoutesRequest { cosmos.base.query.v1beta1.PageRequest pagination = 1; } message QueryRoutesResponse { repeated Route routes = 1 [ (gogoproto.nullable) = false, (gogoproto.castrepeated) = "Routes" ]; cosmos.base.query.v1beta1.PageResponse pagination = 2; } ================================================ FILE: proto/cyber/grid/v1beta1/tx.proto ================================================ syntax = "proto3"; package cyber.grid.v1beta1; import "gogoproto/gogo.proto"; import "cosmos/msg/v1/msg.proto"; import "cosmos_proto/cosmos.proto"; import "cyber/grid/v1beta1/types.proto"; import "cosmos/base/v1beta1/coin.proto"; option go_package = "github.com/cybercongress/go-cyber/x/grid/types"; service Msg { rpc CreateRoute(MsgCreateRoute) returns (MsgCreateRouteResponse); rpc EditRoute(MsgEditRoute) returns (MsgEditRouteResponse); rpc DeleteRoute(MsgDeleteRoute) returns (MsgDeleteRouteResponse); rpc EditRouteName(MsgEditRouteName) returns (MsgEditRouteNameResponse); rpc UpdateParams(MsgUpdateParams) returns (MsgUpdateParamsResponse); } message MsgCreateRoute { string source = 1; string destination = 2; string name = 3; } message MsgEditRoute { string source = 1; string destination = 2; cosmos.base.v1beta1.Coin value = 3 [ (gogoproto.nullable) = false, (gogoproto.casttype) = "github.com/cosmos/cosmos-sdk/types.Coin" ]; } message MsgDeleteRoute { string source = 1; string destination = 2; } message MsgEditRouteName { string source = 1; string destination = 2; string name = 3; } message MsgUpdateParams { option (cosmos.msg.v1.signer) = "authority"; string authority = 1 [ (cosmos_proto.scalar) = "cosmos.AddressString" ]; Params params = 2 [ (gogoproto.nullable) = false ]; } message MsgCreateRouteResponse {} message MsgEditRouteResponse {} message MsgDeleteRouteResponse {} message MsgEditRouteNameResponse {} message MsgUpdateParamsResponse {} ================================================ FILE: proto/cyber/grid/v1beta1/types.proto ================================================ syntax = "proto3"; package cyber.grid.v1beta1; import "gogoproto/gogo.proto"; import "cosmos/base/v1beta1/coin.proto"; option go_package = "github.com/cybercongress/go-cyber/x/grid/types"; message Params { option (gogoproto.equal) = true; uint32 max_routes = 1; } message Route { option (gogoproto.equal) = false; option (gogoproto.goproto_getters) = false; string source = 1; string destination = 2; string name = 3; repeated cosmos.base.v1beta1.Coin value = 4 [ (gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" ]; } message Value { option (gogoproto.equal) = false; option (gogoproto.goproto_getters) = false; repeated cosmos.base.v1beta1.Coin value = 1 [ (gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" ]; } ================================================ FILE: proto/cyber/liquidity/v1beta1/genesis.proto ================================================ syntax = "proto3"; package cyber.liquidity.v1beta1; import "cyber/liquidity/v1beta1/liquidity.proto"; import "gogoproto/gogo.proto"; option go_package = "github.com/cybercongress/go-cyber/x/liquidity/types"; // records the state of each pool after genesis export or import, used to check // variables message PoolRecord { Pool pool = 1 [ (gogoproto.nullable) = false, (gogoproto.moretags) = "yaml:\"pool\"" ]; PoolMetadata pool_metadata = 2 [ (gogoproto.nullable) = false, (gogoproto.moretags) = "yaml:\"pool_metadata\"" ]; PoolBatch pool_batch = 3 [ (gogoproto.nullable) = false, (gogoproto.moretags) = "yaml:\"pool_batch\"" ]; repeated DepositMsgState deposit_msg_states = 4 [ (gogoproto.nullable) = false, (gogoproto.moretags) = "yaml:\"deposit_msg_states\"" ]; repeated WithdrawMsgState withdraw_msg_states = 5 [ (gogoproto.nullable) = false, (gogoproto.moretags) = "yaml:\"withdraw_msg_states\"" ]; repeated SwapMsgState swap_msg_states = 6 [ (gogoproto.nullable) = false, (gogoproto.moretags) = "yaml:\"swap_msg_states\"" ]; } // GenesisState defines the liquidity module's genesis state. message GenesisState { option (gogoproto.equal) = false; option (gogoproto.goproto_getters) = false; // params defines all the parameters for the liquidity module. Params params = 1 [ (gogoproto.nullable) = false ]; repeated PoolRecord pool_records = 2 [ (gogoproto.nullable) = false, (gogoproto.moretags) = "yaml:\"pools\"" ]; } ================================================ FILE: proto/cyber/liquidity/v1beta1/liquidity.proto ================================================ syntax = "proto3"; package cyber.liquidity.v1beta1; import "cyber/liquidity/v1beta1/tx.proto"; import "gogoproto/gogo.proto"; import "cosmos/base/v1beta1/coin.proto"; // import "google/api/annotations.proto"; import "cosmos_proto/cosmos.proto"; option go_package = "github.com/cybercongress/go-cyber/x/liquidity/types"; option (gogoproto.goproto_getters_all) = false; // Structure for the pool type to distinguish the characteristics of the reserve // pools. message PoolType { option (gogoproto.equal) = true; // This is the id of the pool_type that is used as pool_type_id for pool // creation. In this version, only pool-type-id 1 is supported. // {"id":1,"name":"ConstantProductLiquidityPool","min_reserve_coin_num":2,"max_reserve_coin_num":2,"description":""} uint32 id = 1 [ (gogoproto.moretags) = "yaml:\"id\"" ]; // name of the pool type. string name = 2 [ (gogoproto.moretags) = "yaml:\"name\"" ]; // minimum number of reserveCoins for LiquidityPoolType, only 2 reserve coins // are supported. uint32 min_reserve_coin_num = 3 [ (gogoproto.moretags) = "yaml:\"min_reserve_coin_num\"" ]; // maximum number of reserveCoins for LiquidityPoolType, only 2 reserve coins // are supported. uint32 max_reserve_coin_num = 4 [ (gogoproto.moretags) = "yaml:\"max_reserve_coin_num\"" ]; // description of the pool type. string description = 5 [ (gogoproto.moretags) = "yaml:\"description\"" ]; } // Params defines the parameters for the liquidity module. message Params { option (gogoproto.equal) = true; option (gogoproto.goproto_stringer) = false; // list of available pool types repeated PoolType pool_types = 1 [ (gogoproto.moretags) = "yaml:\"pool_types\"", (gogoproto.nullable) = false ]; // Minimum number of coins to be deposited to the liquidity pool on pool // creation. string min_init_deposit_amount = 2 [ (gogoproto.moretags) = "yaml:\"min_init_deposit_amount\"", (cosmos_proto.scalar) = "cosmos.Int", (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", (gogoproto.nullable) = false ]; // Initial mint amount of pool coins upon pool creation. string init_pool_coin_mint_amount = 3 [ (gogoproto.moretags) = "yaml:\"init_pool_coin_mint_amount\"", (cosmos_proto.scalar) = "cosmos.Int", (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", (gogoproto.nullable) = false ]; // Limit the size of each liquidity pool to minimize risk. In development, set // to 0 for no limit. In production, set a limit. string max_reserve_coin_amount = 4 [ (gogoproto.moretags) = "yaml:\"max_reserve_coin_amount\"", (cosmos_proto.scalar) = "cosmos.Int", (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", (gogoproto.nullable) = false ]; // Fee paid to create a Liquidity Pool. Set a fee to prevent spamming. repeated cosmos.base.v1beta1.Coin pool_creation_fee = 5 [ (gogoproto.moretags) = "yaml:\"pool_creation_fee\"", (gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" ]; // Swap fee rate for every executed swap. string swap_fee_rate = 6 [ (gogoproto.moretags) = "yaml:\"swap_fee_rate\"", (cosmos_proto.scalar) = "cosmos.Dec", (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", (gogoproto.nullable) = false ]; // Reserve coin withdrawal with less proportion by withdrawFeeRate. string withdraw_fee_rate = 7 [ (gogoproto.moretags) = "yaml:\"withdraw_fee_rate\"", (cosmos_proto.scalar) = "cosmos.Dec", (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", (gogoproto.nullable) = false ]; // Maximum ratio of reserve coins that can be ordered at a swap order. string max_order_amount_ratio = 8 [ (gogoproto.moretags) = "yaml:\"max_order_amount_ratio\"", (cosmos_proto.scalar) = "cosmos.Dec", (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", (gogoproto.nullable) = false ]; // The smallest unit batch height for every liquidity pool. uint32 unit_batch_height = 9 [ (gogoproto.moretags) = "yaml:\"unit_batch_height\"" ]; // Circuit breaker enables or disables transaction messages in liquidity // module. bool circuit_breaker_enabled = 10 [ (gogoproto.moretags) = "yaml:\"circuit_breaker_enabled\"" ]; } // Pool defines the liquidity pool that contains pool information. message Pool { option (gogoproto.equal) = true; option (gogoproto.goproto_stringer) = true; // id of the pool uint64 id = 1 [ (gogoproto.moretags) = "yaml:\"id\"", (gogoproto.jsontag) = "id" ]; // id of the pool_type uint32 type_id = 2 [ (gogoproto.moretags) = "yaml:\"type_id\"" ]; // denoms of reserve coin pair of the pool repeated string reserve_coin_denoms = 3 [ (gogoproto.moretags) = "yaml:\"reserve_coin_denoms\"" ]; // reserve account address of the pool string reserve_account_address = 4 [ (gogoproto.moretags) = "yaml:\"reserve_account_address\"", (cosmos_proto.scalar) = "cosmos.AddressString" ]; // denom of pool coin of the pool string pool_coin_denom = 5 [ (gogoproto.moretags) = "yaml:\"pool_coin_denom\"" ]; } // Metadata for the state of each pool for invariant checking after genesis // export or import. message PoolMetadata { option (gogoproto.equal) = true; option (gogoproto.goproto_stringer) = true; // id of the pool uint64 pool_id = 1 [ (gogoproto.moretags) = "yaml:\"pool_id\"", (gogoproto.jsontag) = "pool_id" ]; // pool coin issued at the pool cosmos.base.v1beta1.Coin pool_coin_total_supply = 2 [ (gogoproto.moretags) = "yaml:\"pool_coin\"", (gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coin" ]; // reserve coins deposited in the pool repeated cosmos.base.v1beta1.Coin reserve_coins = 3 [ (gogoproto.moretags) = "yaml:\"deposit_coins\"", (gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" ]; } // PoolBatch defines the batch or batches of a given liquidity pool that // contains indexes of deposit, withdraw, and swap messages. Index param // increments by 1 if the pool id is same. message PoolBatch { option (gogoproto.equal) = true; option (gogoproto.goproto_stringer) = true; // id of the pool uint64 pool_id = 1 [ (gogoproto.moretags) = "yaml:\"pool_id\"", (gogoproto.jsontag) = "pool_id" ]; // index of this batch uint64 index = 2 [ (gogoproto.moretags) = "yaml:\"index\"" ]; // height where this batch is started int64 begin_height = 3 [ (gogoproto.moretags) = "yaml:\"begin_height\"" ]; // last index of DepositMsgStates uint64 deposit_msg_index = 4 [ (gogoproto.moretags) = "yaml:\"deposit_msg_index\"" ]; // last index of WithdrawMsgStates uint64 withdraw_msg_index = 5 [ (gogoproto.moretags) = "yaml:\"withdraw_msg_index\"" ]; // last index of SwapMsgStates uint64 swap_msg_index = 6 [ (gogoproto.moretags) = "yaml:\"swap_msg_index\"" ]; // true if executed, false if not executed bool executed = 7 [ (gogoproto.moretags) = "yaml:\"executed\"" ]; } // DepositMsgState defines the state of deposit message that contains state // information as it is processed in the next batch or batches. message DepositMsgState { // height where this message is appended to the batch int64 msg_height = 1 [ (gogoproto.moretags) = "yaml:\"msg_height\"" ]; // index of this deposit message in this liquidity pool uint64 msg_index = 2 [ (gogoproto.moretags) = "yaml:\"msg_index\"" ]; // true if executed on this batch, false if not executed bool executed = 3 [ (gogoproto.moretags) = "yaml:\"executed\"" ]; // true if executed successfully on this batch, false if failed bool succeeded = 4 [ (gogoproto.moretags) = "yaml:\"succeeded\"" ]; // true if ready to be deleted on kvstore, false if not ready to be deleted bool to_be_deleted = 5 [ (gogoproto.moretags) = "yaml:\"to_be_deleted\"" ]; // MsgDepositWithinBatch MsgDepositWithinBatch msg = 6 [ (gogoproto.moretags) = "yaml:\"msg\"" ]; } // WithdrawMsgState defines the state of the withdraw message that contains // state information as the message is processed in the next batch or batches. message WithdrawMsgState { // height where this message is appended to the batch int64 msg_height = 1 [ (gogoproto.moretags) = "yaml:\"msg_height\"" ]; // index of this withdraw message in this liquidity pool uint64 msg_index = 2 [ (gogoproto.moretags) = "yaml:\"msg_index\"" ]; // true if executed on this batch, false if not executed bool executed = 3 [ (gogoproto.moretags) = "yaml:\"executed\"" ]; // true if executed successfully on this batch, false if failed bool succeeded = 4 [ (gogoproto.moretags) = "yaml:\"succeeded\"" ]; // true if ready to be deleted on kvstore, false if not ready to be deleted bool to_be_deleted = 5 [ (gogoproto.moretags) = "yaml:\"to_be_deleted\"" ]; // MsgWithdrawWithinBatch MsgWithdrawWithinBatch msg = 6 [ (gogoproto.moretags) = "yaml:\"msg\"" ]; } // SwapMsgState defines the state of the swap message that contains state // information as the message is processed in the next batch or batches. message SwapMsgState { // height where this message is appended to the batch int64 msg_height = 1 [ (gogoproto.moretags) = "yaml:\"msg_height\"" ]; // index of this swap message in this liquidity pool uint64 msg_index = 2 [ (gogoproto.moretags) = "yaml:\"msg_index\"" ]; // true if executed on this batch, false if not executed bool executed = 3 [ (gogoproto.moretags) = "yaml:\"executed\"" ]; // true if executed successfully on this batch, false if failed bool succeeded = 4 [ (gogoproto.moretags) = "yaml:\"succeeded\"" ]; // true if ready to be deleted on kvstore, false if not ready to be deleted bool to_be_deleted = 5 [ (gogoproto.moretags) = "yaml:\"to_be_deleted\"" ]; // swap orders are cancelled when current height is equal to or higher than // ExpiryHeight int64 order_expiry_height = 6 [ (gogoproto.moretags) = "yaml:\"order_expiry_height\"" ]; // offer coin exchanged until now cosmos.base.v1beta1.Coin exchanged_offer_coin = 7 [ (gogoproto.moretags) = "yaml:\"exchanged_offer_coin\"", (gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coin" ]; // offer coin currently remaining to be exchanged cosmos.base.v1beta1.Coin remaining_offer_coin = 8 [ (gogoproto.moretags) = "yaml:\"remaining_offer_coin\"", (gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coin" ]; // reserve fee for pays fee in half offer coin cosmos.base.v1beta1.Coin reserved_offer_coin_fee = 9 [ (gogoproto.moretags) = "yaml:\"reserved_offer_coin_fee\"", (gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coin" ]; // MsgSwapWithinBatch MsgSwapWithinBatch msg = 10 [ (gogoproto.moretags) = "yaml:\"msg\"" ]; } ================================================ FILE: proto/cyber/liquidity/v1beta1/query.proto ================================================ syntax = "proto3"; package cyber.liquidity.v1beta1; import "gogoproto/gogo.proto"; import "cyber/liquidity/v1beta1/liquidity.proto"; import "google/api/annotations.proto"; import "cosmos/base/query/v1beta1/pagination.proto"; option go_package = "github.com/cybercongress/go-cyber/x/liquidity/types"; // Query defines the gRPC query service for the liquidity module. service Query { // Get existing liquidity pools. rpc LiquidityPools(QueryLiquidityPoolsRequest) returns (QueryLiquidityPoolsResponse) { option (google.api.http).get = "/cosmos/liquidity/v1beta1/pools"; } // Get specific liquidity pool. rpc LiquidityPool(QueryLiquidityPoolRequest) returns (QueryLiquidityPoolResponse) { option (google.api.http).get = "/cosmos/liquidity/v1beta1/pools/{pool_id}"; } // Get specific liquidity pool corresponding to the pool_coin_denom. rpc LiquidityPoolByPoolCoinDenom(QueryLiquidityPoolByPoolCoinDenomRequest) returns (QueryLiquidityPoolResponse) { option (google.api.http).get = "/cosmos/liquidity/v1beta1/pools/pool_coin_denom/{pool_coin_denom}"; } // Get specific liquidity pool corresponding to the reserve account. rpc LiquidityPoolByReserveAcc(QueryLiquidityPoolByReserveAccRequest) returns (QueryLiquidityPoolResponse) { option (google.api.http).get = "/cosmos/liquidity/v1beta1/pools/reserve_acc/{reserve_acc}"; } // Get the pool's current batch. rpc LiquidityPoolBatch(QueryLiquidityPoolBatchRequest) returns (QueryLiquidityPoolBatchResponse) { option (google.api.http).get = "/cosmos/liquidity/v1beta1/pools/{pool_id}/batch"; } // Get all swap messages in the pool's current batch. rpc PoolBatchSwapMsgs(QueryPoolBatchSwapMsgsRequest) returns (QueryPoolBatchSwapMsgsResponse) { option (google.api.http).get = "/cosmos/liquidity/v1beta1/pools/{pool_id}/batch/swaps"; } // Get a specific swap message in the pool's current batch. rpc PoolBatchSwapMsg(QueryPoolBatchSwapMsgRequest) returns (QueryPoolBatchSwapMsgResponse) { option (google.api.http).get = "/cosmos/liquidity/v1beta1/pools/{pool_id}/batch/swaps/{msg_index}"; } // Get all deposit messages in the pool's current batch. rpc PoolBatchDepositMsgs(QueryPoolBatchDepositMsgsRequest) returns (QueryPoolBatchDepositMsgsResponse) { option (google.api.http).get = "/cosmos/liquidity/v1beta1/pools/{pool_id}/batch/deposits"; } // Get a specific deposit message in the pool's current batch. rpc PoolBatchDepositMsg(QueryPoolBatchDepositMsgRequest) returns (QueryPoolBatchDepositMsgResponse) { option (google.api.http).get = "/cosmos/liquidity/v1beta1/pools/{pool_id}/batch/deposits/{msg_index}"; } // Get all withdraw messages in the pool's current batch. rpc PoolBatchWithdrawMsgs(QueryPoolBatchWithdrawMsgsRequest) returns (QueryPoolBatchWithdrawMsgsResponse) { option (google.api.http).get = "/cosmos/liquidity/v1beta1/pools/{pool_id}/batch/withdraws"; } // Get a specific withdraw message in the pool's current batch. rpc PoolBatchWithdrawMsg(QueryPoolBatchWithdrawMsgRequest) returns (QueryPoolBatchWithdrawMsgResponse) { option (google.api.http).get = "/cosmos/liquidity/v1beta1/pools/{pool_id}/batch/withdraws/{msg_index}"; } // Get all parameters of the liquidity module. rpc Params(QueryParamsRequest) returns (QueryParamsResponse) { option (google.api.http).get = "/cosmos/liquidity/v1beta1/params"; } } // the request type for the QueryLiquidityPool RPC method. requestable specified // pool_id. message QueryLiquidityPoolRequest { uint64 pool_id = 1; } // the response type for the QueryLiquidityPoolResponse RPC method. Returns the // liquidity pool that corresponds to the requested pool_id. message QueryLiquidityPoolResponse { Pool pool = 1 [ (gogoproto.nullable) = false ]; } // the request type for the QueryLiquidityByPoolCoinDenomPool RPC method. // Requestable specified pool_coin_denom. message QueryLiquidityPoolByPoolCoinDenomRequest { string pool_coin_denom = 1; } // the request type for the QueryLiquidityByReserveAcc RPC method. Requestable // specified reserve_acc. message QueryLiquidityPoolByReserveAccRequest { string reserve_acc = 1; } // the request type for the QueryLiquidityPoolBatch RPC method. requestable // including specified pool_id. message QueryLiquidityPoolBatchRequest { // id of the target pool for query uint64 pool_id = 1; } // the response type for the QueryLiquidityPoolBatchResponse RPC method. Returns // the liquidity pool batch that corresponds to the requested pool_id. message QueryLiquidityPoolBatchResponse { PoolBatch batch = 1 [ (gogoproto.nullable) = false ]; } // the request type for the QueryLiquidityPools RPC method. Requestable // including pagination offset, limit, key. message QueryLiquidityPoolsRequest { // pagination defines an optional pagination for the request. cosmos.base.query.v1beta1.PageRequest pagination = 1; } // the response type for the QueryLiquidityPoolsResponse RPC method. This // includes a list of all existing liquidity pools and paging results that // contain next_key and total count. message QueryLiquidityPoolsResponse { repeated Pool pools = 1 [ (gogoproto.nullable) = false ]; // pagination defines the pagination in the response. not working on this // version. cosmos.base.query.v1beta1.PageResponse pagination = 2; } // QueryParamsRequest is request type for the QueryParams RPC method. message QueryParamsRequest {} // the response type for the QueryParamsResponse RPC method. This includes // current parameter of the liquidity module. message QueryParamsResponse { // params holds all the parameters of this module. Params params = 1 [ (gogoproto.nullable) = false ]; } // the request type for the QueryPoolBatchSwapMsgs RPC method. Requestable // including specified pool_id and pagination offset, limit, key. message QueryPoolBatchSwapMsgsRequest { // id of the target pool for query uint64 pool_id = 1; // pagination defines an optional pagination for the request. cosmos.base.query.v1beta1.PageRequest pagination = 2; } // the request type for the QueryPoolBatchSwap RPC method. Requestable including // specified pool_id and msg_index. message QueryPoolBatchSwapMsgRequest { // id of the target pool for query uint64 pool_id = 1; // target msg_index of the pool uint64 msg_index = 2; } // the response type for the QueryPoolBatchSwapMsgs RPC method. This includes // list of all currently existing swap messages of the batch and paging results // that contain next_key and total count. message QueryPoolBatchSwapMsgsResponse { repeated SwapMsgState swaps = 1 [ (gogoproto.nullable) = false ]; // pagination defines the pagination in the response. not working on this // version. cosmos.base.query.v1beta1.PageResponse pagination = 2; } // the response type for the QueryPoolBatchSwapMsg RPC method. This includes a // batch swap message of the batch. message QueryPoolBatchSwapMsgResponse { SwapMsgState swap = 1 [ (gogoproto.nullable) = false ]; } // the request type for the QueryPoolBatchDeposit RPC method. Requestable // including specified pool_id and pagination offset, limit, key. message QueryPoolBatchDepositMsgsRequest { // id of the target pool for query uint64 pool_id = 1; // pagination defines an optional pagination for the request. cosmos.base.query.v1beta1.PageRequest pagination = 2; } // the request type for the QueryPoolBatchDeposit RPC method. requestable // including specified pool_id and msg_index. message QueryPoolBatchDepositMsgRequest { // id of the target pool for query uint64 pool_id = 1; // target msg_index of the pool uint64 msg_index = 2; } // the response type for the QueryPoolBatchDeposit RPC method. This includes a // list of all currently existing deposit messages of the batch and paging // results that contain next_key and total count. message QueryPoolBatchDepositMsgsResponse { repeated DepositMsgState deposits = 1 [ (gogoproto.nullable) = false ]; // pagination defines the pagination in the response. not working on this // version. cosmos.base.query.v1beta1.PageResponse pagination = 2; } // the response type for the QueryPoolBatchDepositMsg RPC method. This includes // a batch swap message of the batch. message QueryPoolBatchDepositMsgResponse { DepositMsgState deposit = 1 [ (gogoproto.nullable) = false ]; } // the request type for the QueryPoolBatchWithdraw RPC method. Requestable // including specified pool_id and pagination offset, limit, key. message QueryPoolBatchWithdrawMsgsRequest { // id of the target pool for query uint64 pool_id = 1; // pagination defines an optional pagination for the request. cosmos.base.query.v1beta1.PageRequest pagination = 2; } // the request type for the QueryPoolBatchWithdraw RPC method. requestable // including specified pool_id and msg_index. message QueryPoolBatchWithdrawMsgRequest { // id of the target pool for query uint64 pool_id = 1; // target msg_index of the pool uint64 msg_index = 2; } // the response type for the QueryPoolBatchWithdraw RPC method. This includes a // list of all currently existing withdraw messages of the batch and paging // results that contain next_key and total count. message QueryPoolBatchWithdrawMsgsResponse { repeated WithdrawMsgState withdraws = 1 [ (gogoproto.nullable) = false ]; // pagination defines the pagination in the response. Not supported on this // version. cosmos.base.query.v1beta1.PageResponse pagination = 2; } // the response type for the QueryPoolBatchWithdrawMsg RPC method. This includes // a batch swap message of the batch. message QueryPoolBatchWithdrawMsgResponse { WithdrawMsgState withdraw = 1 [ (gogoproto.nullable) = false ]; } ================================================ FILE: proto/cyber/liquidity/v1beta1/tx.proto ================================================ syntax = "proto3"; package cyber.liquidity.v1beta1; import "gogoproto/gogo.proto"; import "cosmos/base/v1beta1/coin.proto"; // import "google/api/annotations.proto"; // import "cosmos/msg/v1/msg.proto"; import "cosmos_proto/cosmos.proto"; option go_package = "github.com/cybercongress/go-cyber/x/liquidity/types"; // Msg defines the liquidity Msg service. service Msg { // Submit a create liquidity pool message. rpc CreatePool(MsgCreatePool) returns (MsgCreatePoolResponse); // Submit a deposit to the liquidity pool batch. rpc DepositWithinBatch(MsgDepositWithinBatch) returns (MsgDepositWithinBatchResponse); // Submit a withdraw from the liquidity pool batch. rpc WithdrawWithinBatch(MsgWithdrawWithinBatch) returns (MsgWithdrawWithinBatchResponse); // Submit a swap to the liquidity pool batch. rpc Swap(MsgSwapWithinBatch) returns (MsgSwapWithinBatchResponse); // rpc UpdateParams(MsgUpdateParams) returns (MsgUpdateParamsResponse); } // MsgCreatePool defines an sdk.Msg type that supports submitting a create // liquidity pool tx. // // See: // https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md message MsgCreatePool { option (gogoproto.equal) = false; option (gogoproto.goproto_getters) = false; string pool_creator_address = 1 [ (gogoproto.moretags) = "yaml:\"pool_creator_address\"", (cosmos_proto.scalar) = "cosmos.AddressString" ]; // id of the target pool type, must match the value in the pool. Only // pool-type-id 1 is supported. uint32 pool_type_id = 2 [ (gogoproto.moretags) = "yaml:\"pool_type_id\"" ]; // reserve coin pair of the pool to deposit. repeated cosmos.base.v1beta1.Coin deposit_coins = 4 [ (gogoproto.moretags) = "yaml:\"deposit_coins\"", (gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" ]; } // MsgCreatePoolResponse defines the Msg/CreatePool response type. message MsgCreatePoolResponse {} // `MsgDepositWithinBatch defines` an `sdk.Msg` type that supports submitting // a deposit request to the batch of the liquidity pool. // Deposit is submitted to the batch of the Liquidity pool with the specified // `pool_id`, `deposit_coins` for reserve. // This request is stacked in the batch of the liquidity pool, is not processed // immediately, and is processed in the `endblock` at the same time as other // requests. // // See: // https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md message MsgDepositWithinBatch { option (gogoproto.equal) = false; option (gogoproto.goproto_getters) = false; string depositor_address = 1 [ (cosmos_proto.scalar) = "cosmos.AddressString", (gogoproto.moretags) = "yaml:\"depositor_address\"" ]; // id of the target pool uint64 pool_id = 2 [ (gogoproto.moretags) = "yaml:\"pool_id\"" ]; // reserve coin pair of the pool to deposit repeated cosmos.base.v1beta1.Coin deposit_coins = 3 [ (gogoproto.moretags) = "yaml:\"deposit_coins\"", (gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" ]; } // MsgDepositWithinBatchResponse defines the Msg/DepositWithinBatch response // type. message MsgDepositWithinBatchResponse {} // `MsgWithdrawWithinBatch` defines an `sdk.Msg` type that supports submitting // a withdraw request to the batch of the liquidity pool. // Withdraw is submitted to the batch from the Liquidity pool with the // specified `pool_id`, `pool_coin` of the pool. // This request is stacked in the batch of the liquidity pool, is not processed // immediately, and is processed in the `endblock` at the same time as other // requests. // // See: // https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md message MsgWithdrawWithinBatch { option (gogoproto.equal) = false; option (gogoproto.goproto_getters) = false; string withdrawer_address = 1 [ (gogoproto.moretags) = "yaml:\"withdrawer_address\"", (cosmos_proto.scalar) = "cosmos.AddressString" ]; // id of the target pool uint64 pool_id = 2 [ (gogoproto.moretags) = "yaml:\"pool_id\"" ]; cosmos.base.v1beta1.Coin pool_coin = 3 [ (gogoproto.moretags) = "yaml:\"pool_coin\"", (gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coin" ]; } // MsgWithdrawWithinBatchResponse defines the Msg/WithdrawWithinBatch response // type. message MsgWithdrawWithinBatchResponse {} // `MsgSwapWithinBatch` defines an sdk.Msg type that supports submitting a swap // offer request to the batch of the liquidity pool. Submit swap offer to the // liquidity pool batch with the specified the `pool_id`, `swap_type_id`, // `demand_coin_denom` with the coin and the price you're offering // and `offer_coin_fee` must be half of offer coin amount * current // `params.swap_fee_rate` and ceil for reservation to pay fees. This request is // stacked in the batch of the liquidity pool, is not processed immediately, and // is processed in the `endblock` at the same time as other requests. You must // request the same fields as the pool. Only the default `swap_type_id` 1 is // supported. // // See: https://github.com/gravity-devs/liquidity/tree/develop/doc // https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md message MsgSwapWithinBatch { option (gogoproto.equal) = false; option (gogoproto.goproto_getters) = false; // address of swap requester string swap_requester_address = 1 [ (gogoproto.moretags) = "yaml:\"swap_requester_address\"", (cosmos_proto.scalar) = "cosmos.AddressString" ]; // id of swap type, must match the value in the pool. Only `swap_type_id` 1 is // supported. uint64 pool_id = 2 [ (gogoproto.moretags) = "yaml:\"pool_id\"" ]; // id of swap type. Must match the value in the pool. uint32 swap_type_id = 3 [ (gogoproto.moretags) = "yaml:\"swap_type_id\"" ]; // offer sdk.coin for the swap request, must match the denom in the pool. cosmos.base.v1beta1.Coin offer_coin = 4 [ (gogoproto.moretags) = "yaml:\"offer_coin\"", (gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coin" ]; // denom of demand coin to be exchanged on the swap request, must match the // denom in the pool. string demand_coin_denom = 5 [ (gogoproto.moretags) = "yaml:\"demand_coin_denom\"" ]; // half of offer coin amount * params.swap_fee_rate and ceil for reservation // to pay fees. cosmos.base.v1beta1.Coin offer_coin_fee = 6 [ (gogoproto.moretags) = "yaml:\"offer_coin_fee\"", (gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coin" ]; // limit order price for the order, the price is the exchange ratio of X/Y // where X is the amount of the first coin and Y is the amount // of the second coin when their denoms are sorted alphabetically. string order_price = 7 [ (gogoproto.moretags) = "yaml:\"order_price\"", (cosmos_proto.scalar) = "cosmos.Dec", (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", (gogoproto.nullable) = false ]; } // MsgSwapWithinBatchResponse defines the Msg/Swap response type. message MsgSwapWithinBatchResponse {} // TODO revisit this and apply, there is issue with cyclic dependency with // Params import message MsgUpdateParams { // option (cosmos.msg.v1.signer) = "authority"; // // string authority = 1 [ (cosmos_proto.scalar) = "cosmos.AddressString" ]; // // Params params = 2 [ (gogoproto.nullable) = false ]; // } // // message MsgUpdateParamsResponse {} ================================================ FILE: proto/cyber/rank/v1beta1/genesis.proto ================================================ syntax = "proto3"; package cyber.rank.v1beta1; import "gogoproto/gogo.proto"; import "cyber/rank/v1beta1/types.proto"; option go_package = "github.com/cybercongress/go-cyber/x/rank/types"; message GenesisState { Params params = 1 [ (gogoproto.nullable) = false ]; } ================================================ FILE: proto/cyber/rank/v1beta1/pagination.proto ================================================ syntax = "proto3"; package cyber.rank.v1beta1; option go_package = "github.com/cybercongress/go-cyber/x/rank/types"; message PageRequest { uint32 page = 1; uint32 per_page = 2; } message PageResponse { uint32 total = 1; } ================================================ FILE: proto/cyber/rank/v1beta1/query.proto ================================================ syntax = "proto3"; package cyber.rank.v1beta1; import "gogoproto/gogo.proto"; import "google/api/annotations.proto"; import "cyber/rank/v1beta1/types.proto"; import "cyber/rank/v1beta1/pagination.proto"; option go_package = "github.com/cybercongress/go-cyber/x/rank/types"; service Query { rpc Params(QueryParamsRequest) returns (QueryParamsResponse) { option (google.api.http).get = "/cyber/rank/v1beta1/rank/params"; } rpc Rank(QueryRankRequest) returns (QueryRankResponse) { option (google.api.http).get = "/cyber/rank/v1beta1/rank/rank/{particle}"; } rpc Search(QuerySearchRequest) returns (QuerySearchResponse) { option (google.api.http).get = "/cyber/rank/v1beta1/rank/search/{particle}"; } rpc Backlinks(QuerySearchRequest) returns (QuerySearchResponse) { option (google.api.http).get = "/cyber/rank/v1beta1/rank/backlinks/{particle}"; } rpc Top(QueryTopRequest) returns (QuerySearchResponse) { option (google.api.http).get = "/cyber/rank/v1beta1/rank/top"; } rpc IsLinkExist(QueryIsLinkExistRequest) returns (QueryLinkExistResponse) { option (google.api.http).get = "/cyber/rank/v1beta1/is_link_exist"; } rpc IsAnyLinkExist(QueryIsAnyLinkExistRequest) returns (QueryLinkExistResponse) { option (google.api.http).get = "/cyber/rank/v1beta1/is_any_link_exist"; } // Per-particle focus entropy: -pi*log2(pi) from the rank distribution. // Computed at query time, no state stored. rpc ParticleNegentropy(QueryNegentropyPartilceRequest) returns (QueryNegentropyParticleResponse) { option (google.api.http).get = "/cyber/rank/v1beta1/negentropy/{particle}"; } // System-wide negentropy: J(pi) = log2(n) - H(pi). // Measures how far the focus distribution deviates from uniform. // Computed at query time from current rank values, no state stored. rpc Negentropy(QueryNegentropyRequest) returns (QueryNegentropyResponse) { option (google.api.http).get = "/cyber/rank/v1beta1/negentropy"; } // Deprecated: karma removed. Stub kept for wire compatibility. rpc Karma(QueryKarmaRequest) returns (QueryKarmaResponse) { option (google.api.http).get = "/cyber/rank/v1beta1/karma/{neuron}"; } } message QueryParamsRequest {} message QueryParamsResponse { cyber.rank.v1beta1.Params params = 1 [ (gogoproto.nullable) = false ]; } message QueryRankRequest { string particle = 1; } message QueryRankResponse { uint64 rank = 1; } message QuerySearchRequest { string particle = 1; cyber.rank.v1beta1.PageRequest pagination = 2; } message QuerySearchResponse { repeated RankedParticle result = 1 [ (gogoproto.nullable) = false ]; cyber.rank.v1beta1.PageResponse pagination = 2; } message QueryTopRequest { cyber.rank.v1beta1.PageRequest pagination = 1; } message QueryIsLinkExistRequest { string from = 1; string to = 2; string address = 3; } message QueryIsAnyLinkExistRequest { string from = 1; string to = 2; } message QueryLinkExistResponse { bool exist = 1; } message QueryNegentropyPartilceRequest { string particle = 1; } message QueryNegentropyParticleResponse { uint64 entropy = 1; } message QueryNegentropyRequest {} message QueryNegentropyResponse { uint64 negentropy = 1; } // Deprecated: karma removed message QueryKarmaRequest { string neuron = 1; } message QueryKarmaResponse { uint64 karma = 1; } ================================================ FILE: proto/cyber/rank/v1beta1/tx.proto ================================================ syntax = "proto3"; package cyber.rank.v1beta1; import "gogoproto/gogo.proto"; import "cosmos/msg/v1/msg.proto"; import "cosmos_proto/cosmos.proto"; import "cyber/rank/v1beta1/types.proto"; option go_package = "github.com/cybercongress/go-cyber/x/rank/types"; service Msg { rpc UpdateParams(MsgUpdateParams) returns (MsgUpdateParamsResponse); } message MsgUpdateParams { option (cosmos.msg.v1.signer) = "authority"; string authority = 1 [ (cosmos_proto.scalar) = "cosmos.AddressString" ]; Params params = 2 [ (gogoproto.nullable) = false ]; } message MsgUpdateParamsResponse {} ================================================ FILE: proto/cyber/rank/v1beta1/types.proto ================================================ syntax = "proto3"; package cyber.rank.v1beta1; import "gogoproto/gogo.proto"; option go_package = "github.com/cybercongress/go-cyber/x/rank/types"; message Params { int64 calculation_period = 1; string damping_factor = 2 [ (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", (gogoproto.nullable) = false ]; string tolerance = 3 [ (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", (gogoproto.nullable) = false ]; } message RankedParticle { string particle = 1; uint64 rank = 2; } ================================================ FILE: proto/cyber/resources/v1beta1/genesis.proto ================================================ syntax = "proto3"; package cyber.resources.v1beta1; import "gogoproto/gogo.proto"; import "cyber/resources/v1beta1/types.proto"; option go_package = "github.com/cybercongress/go-cyber/x/resources/types"; message GenesisState { Params params = 1 [ (gogoproto.nullable) = false ]; } ================================================ FILE: proto/cyber/resources/v1beta1/query.proto ================================================ syntax = "proto3"; package cyber.resources.v1beta1; import "gogoproto/gogo.proto"; import "google/api/annotations.proto"; import "cyber/resources/v1beta1/types.proto"; import "cosmos/base/v1beta1/coin.proto"; option go_package = "github.com/cybercongress/go-cyber/x/resources/types"; service Query { rpc Params(QueryParamsRequest) returns (QueryParamsResponse) { option (google.api.http).get = "/cyber/resources/v1beta1/resources/params"; } rpc Investmint(QueryInvestmintRequest) returns (QueryInvestmintResponse) { option (google.api.http).get = "/cyber/resources/v1beta1/resources/investmint"; } rpc AdjustedPrice(QueryAdjustedPriceRequest) returns (QueryAdjustedPriceResponse) { option (google.api.http).get = "/cyber/resources/v1beta1/resources/adjusted_price"; } } message QueryParamsRequest {} message QueryParamsResponse { Params params = 1 [ (gogoproto.nullable) = false ]; } message QueryInvestmintRequest { cosmos.base.v1beta1.Coin amount = 1 [ (gogoproto.nullable) = false ]; string resource = 2; uint64 length = 3; } message QueryInvestmintResponse { cosmos.base.v1beta1.Coin amount = 1 [ (gogoproto.nullable) = false ]; } message QueryAdjustedPriceRequest { cosmos.base.v1beta1.Coin base = 1 [ (gogoproto.nullable) = false ]; string resource = 2; } message QueryAdjustedPriceResponse { cosmos.base.v1beta1.Coin adjusted = 1 [ (gogoproto.nullable) = false ]; } ================================================ FILE: proto/cyber/resources/v1beta1/tx.proto ================================================ syntax = "proto3"; package cyber.resources.v1beta1; import "gogoproto/gogo.proto"; import "cosmos/msg/v1/msg.proto"; import "cosmos_proto/cosmos.proto"; import "cyber/resources/v1beta1/types.proto"; import "cosmos/base/v1beta1/coin.proto"; option go_package = "github.com/cybercongress/go-cyber/x/resources/types"; service Msg { rpc Investmint(MsgInvestmint) returns (MsgInvestmintResponse); rpc UpdateParams(MsgUpdateParams) returns (MsgUpdateParamsResponse); } message MsgInvestmint { option (gogoproto.equal) = false; option (gogoproto.goproto_getters) = false; string neuron = 1; cosmos.base.v1beta1.Coin amount = 2 [ (gogoproto.nullable) = false, (gogoproto.casttype) = "github.com/cosmos/cosmos-sdk/types.Coin" ]; string resource = 3; uint64 length = 4; } message MsgUpdateParams { option (cosmos.msg.v1.signer) = "authority"; string authority = 1 [ (cosmos_proto.scalar) = "cosmos.AddressString" ]; Params params = 2 [ (gogoproto.nullable) = false ]; } message MsgInvestmintResponse {} message MsgUpdateParamsResponse {} ================================================ FILE: proto/cyber/resources/v1beta1/types.proto ================================================ syntax = "proto3"; package cyber.resources.v1beta1; import "gogoproto/gogo.proto"; import "cosmos/base/v1beta1/coin.proto"; option go_package = "github.com/cybercongress/go-cyber/x/resources/types"; message Params { uint32 max_slots = 1; uint32 halving_period_volt_blocks = 2; uint32 halving_period_ampere_blocks = 3; uint32 base_investmint_period_volt = 4; uint32 base_investmint_period_ampere = 5; uint32 min_investmint_period = 6; cosmos.base.v1beta1.Coin base_investmint_amount_volt = 7 [ (gogoproto.casttype) = "github.com/cosmos/cosmos-sdk/types.Coin", (gogoproto.nullable) = false ]; cosmos.base.v1beta1.Coin base_investmint_amount_ampere = 8 [ (gogoproto.casttype) = "github.com/cosmos/cosmos-sdk/types.Coin", (gogoproto.nullable) = false ]; } ================================================ FILE: proto/osmosis/tokenfactory/v1beta1/authority_metadata.proto ================================================ syntax = "proto3"; package osmosis.tokenfactory.v1beta1; import "gogoproto/gogo.proto"; // import "cosmos/base/v1beta1/coin.proto"; option go_package = "github.com/CosmosContracts/juno/x/tokenfactory/types"; // DenomAuthorityMetadata specifies metadata for addresses that have specific // capabilities over a token factory denom. Right now there is only one Admin // permission, but is planned to be extended to the future. message DenomAuthorityMetadata { option (gogoproto.equal) = true; // Can be empty for no admin, or a valid osmosis address string admin = 1 [ (gogoproto.moretags) = "yaml:\"admin\"" ]; } ================================================ FILE: proto/osmosis/tokenfactory/v1beta1/genesis.proto ================================================ syntax = "proto3"; package osmosis.tokenfactory.v1beta1; import "gogoproto/gogo.proto"; import "osmosis/tokenfactory/v1beta1/authority_metadata.proto"; import "osmosis/tokenfactory/v1beta1/params.proto"; option go_package = "github.com/CosmosContracts/juno/x/tokenfactory/types"; // GenesisState defines the tokenfactory module's genesis state. message GenesisState { // params defines the parameters of the module. Params params = 1 [ (gogoproto.nullable) = false ]; repeated GenesisDenom factory_denoms = 2 [ (gogoproto.moretags) = "yaml:\"factory_denoms\"", (gogoproto.nullable) = false ]; } // GenesisDenom defines a tokenfactory denom that is defined within genesis // state. The structure contains DenomAuthorityMetadata which defines the // denom's admin. message GenesisDenom { option (gogoproto.equal) = true; string denom = 1 [ (gogoproto.moretags) = "yaml:\"denom\"" ]; DenomAuthorityMetadata authority_metadata = 2 [ (gogoproto.moretags) = "yaml:\"authority_metadata\"", (gogoproto.nullable) = false ]; } ================================================ FILE: proto/osmosis/tokenfactory/v1beta1/params.proto ================================================ syntax = "proto3"; package osmosis.tokenfactory.v1beta1; import "gogoproto/gogo.proto"; import "cosmos/base/v1beta1/coin.proto"; option go_package = "github.com/CosmosContracts/juno/x/tokenfactory/types"; // Params defines the parameters for the tokenfactory module. message Params { repeated cosmos.base.v1beta1.Coin denom_creation_fee = 1 [ (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins", (gogoproto.moretags) = "yaml:\"denom_creation_fee\"", (gogoproto.nullable) = false ]; // if denom_creation_fee is an empty array, then this field is used to add // more gas consumption to the base cost. // https://github.com/CosmWasm/token-factory/issues/11 uint64 denom_creation_gas_consume = 2 [ (gogoproto.moretags) = "yaml:\"denom_creation_gas_consume\"", (gogoproto.nullable) = true ]; } ================================================ FILE: proto/osmosis/tokenfactory/v1beta1/query.proto ================================================ syntax = "proto3"; package osmosis.tokenfactory.v1beta1; import "gogoproto/gogo.proto"; import "google/api/annotations.proto"; import "osmosis/tokenfactory/v1beta1/authority_metadata.proto"; import "osmosis/tokenfactory/v1beta1/params.proto"; option go_package = "github.com/CosmosContracts/juno/x/tokenfactory/types"; // Query defines the gRPC querier service. service Query { // Params defines a gRPC query method that returns the tokenfactory module's // parameters. rpc Params(QueryParamsRequest) returns (QueryParamsResponse) { option (google.api.http).get = "/osmosis/tokenfactory/v1beta1/params"; } // DenomAuthorityMetadata defines a gRPC query method for fetching // DenomAuthorityMetadata for a particular denom. rpc DenomAuthorityMetadata(QueryDenomAuthorityMetadataRequest) returns (QueryDenomAuthorityMetadataResponse) { option (google.api.http).get = "/osmosis/tokenfactory/v1beta1/denoms/{denom}/authority_metadata"; } // DenomsFromCreator defines a gRPC query method for fetching all // denominations created by a specific admin/creator. rpc DenomsFromCreator(QueryDenomsFromCreatorRequest) returns (QueryDenomsFromCreatorResponse) { option (google.api.http).get = "/osmosis/tokenfactory/v1beta1/denoms_from_creator/{creator}"; } } // QueryParamsRequest is the request type for the Query/Params RPC method. message QueryParamsRequest {} // QueryParamsResponse is the response type for the Query/Params RPC method. message QueryParamsResponse { // params defines the parameters of the module. Params params = 1 [ (gogoproto.nullable) = false ]; } // QueryDenomAuthorityMetadataRequest defines the request structure for the // DenomAuthorityMetadata gRPC query. message QueryDenomAuthorityMetadataRequest { string denom = 1 [ (gogoproto.moretags) = "yaml:\"denom\"" ]; } // QueryDenomAuthorityMetadataResponse defines the response structure for the // DenomAuthorityMetadata gRPC query. message QueryDenomAuthorityMetadataResponse { DenomAuthorityMetadata authority_metadata = 1 [ (gogoproto.moretags) = "yaml:\"authority_metadata\"", (gogoproto.nullable) = false ]; } // QueryDenomsFromCreatorRequest defines the request structure for the // DenomsFromCreator gRPC query. message QueryDenomsFromCreatorRequest { string creator = 1 [ (gogoproto.moretags) = "yaml:\"creator\"" ]; } // QueryDenomsFromCreatorRequest defines the response structure for the // DenomsFromCreator gRPC query. message QueryDenomsFromCreatorResponse { repeated string denoms = 1 [ (gogoproto.moretags) = "yaml:\"denoms\"" ]; } ================================================ FILE: proto/osmosis/tokenfactory/v1beta1/tx.proto ================================================ syntax = "proto3"; package osmosis.tokenfactory.v1beta1; import "gogoproto/gogo.proto"; import "cosmos/base/v1beta1/coin.proto"; import "cosmos/bank/v1beta1/bank.proto"; import "osmosis/tokenfactory/v1beta1/params.proto"; import "cosmos/msg/v1/msg.proto"; import "cosmos_proto/cosmos.proto"; option go_package = "github.com/CosmosContracts/juno/x/tokenfactory/types"; // Msg defines the tokefactory module's gRPC message service. service Msg { rpc CreateDenom(MsgCreateDenom) returns (MsgCreateDenomResponse); rpc Mint(MsgMint) returns (MsgMintResponse); rpc Burn(MsgBurn) returns (MsgBurnResponse); rpc ChangeAdmin(MsgChangeAdmin) returns (MsgChangeAdminResponse); rpc SetDenomMetadata(MsgSetDenomMetadata) returns (MsgSetDenomMetadataResponse); rpc ForceTransfer(MsgForceTransfer) returns (MsgForceTransferResponse); // UpdateParams defines a governance operation for updating the x/mint module // parameters. The authority is hard-coded to the x/gov module account. // // Since: cosmos-sdk 0.47 rpc UpdateParams(MsgUpdateParams) returns (MsgUpdateParamsResponse); } // MsgCreateDenom defines the message structure for the CreateDenom gRPC service // method. It allows an account to create a new denom. It requires a sender // address and a sub denomination. The (sender_address, sub_denomination) tuple // must be unique and cannot be re-used. // // The resulting denom created is defined as // . The resulting denom's admin is // originally set to be the creator, but this can be changed later. The token // denom does not indicate the current admin. message MsgCreateDenom { string sender = 1 [ (gogoproto.moretags) = "yaml:\"sender\"" ]; // subdenom can be up to 44 "alphanumeric" characters long. string subdenom = 2 [ (gogoproto.moretags) = "yaml:\"subdenom\"" ]; } // MsgCreateDenomResponse is the return value of MsgCreateDenom // It returns the full string of the newly created denom message MsgCreateDenomResponse { string new_token_denom = 1 [ (gogoproto.moretags) = "yaml:\"new_token_denom\"" ]; } // MsgMint is the sdk.Msg type for allowing an admin account to mint // more of a token. For now, we only support minting to the sender account message MsgMint { string sender = 1 [ (gogoproto.moretags) = "yaml:\"sender\"" ]; cosmos.base.v1beta1.Coin amount = 2 [ (gogoproto.moretags) = "yaml:\"amount\"", (gogoproto.nullable) = false ]; string mintToAddress = 3 [ (gogoproto.moretags) = "yaml:\"mint_to_address\"" ]; } message MsgMintResponse {} // MsgBurn is the sdk.Msg type for allowing an admin account to burn // a token. For now, we only support burning from the sender account. message MsgBurn { string sender = 1 [ (gogoproto.moretags) = "yaml:\"sender\"" ]; cosmos.base.v1beta1.Coin amount = 2 [ (gogoproto.moretags) = "yaml:\"amount\"", (gogoproto.nullable) = false ]; string burnFromAddress = 3 [ (gogoproto.moretags) = "yaml:\"burn_from_address\"" ]; } message MsgBurnResponse {} // MsgChangeAdmin is the sdk.Msg type for allowing an admin account to reassign // adminship of a denom to a new account message MsgChangeAdmin { string sender = 1 [ (gogoproto.moretags) = "yaml:\"sender\"" ]; string denom = 2 [ (gogoproto.moretags) = "yaml:\"denom\"" ]; string new_admin = 3 [ (gogoproto.moretags) = "yaml:\"new_admin\"" ]; } // MsgChangeAdminResponse defines the response structure for an executed // MsgChangeAdmin message. message MsgChangeAdminResponse {} // MsgSetDenomMetadata is the sdk.Msg type for allowing an admin account to set // the denom's bank metadata message MsgSetDenomMetadata { string sender = 1 [ (gogoproto.moretags) = "yaml:\"sender\"" ]; cosmos.bank.v1beta1.Metadata metadata = 2 [ (gogoproto.moretags) = "yaml:\"metadata\"", (gogoproto.nullable) = false ]; } // MsgSetDenomMetadataResponse defines the response structure for an executed // MsgSetDenomMetadata message. message MsgSetDenomMetadataResponse {} message MsgForceTransfer { string sender = 1 [ (gogoproto.moretags) = "yaml:\"sender\"" ]; cosmos.base.v1beta1.Coin amount = 2 [ (gogoproto.moretags) = "yaml:\"amount\"", (gogoproto.nullable) = false ]; string transferFromAddress = 3 [ (gogoproto.moretags) = "yaml:\"transfer_from_address\"" ]; string transferToAddress = 4 [ (gogoproto.moretags) = "yaml:\"transfer_to_address\"" ]; } message MsgForceTransferResponse {} // MsgUpdateParams is the Msg/UpdateParams request type. // // Since: cosmos-sdk 0.47 message MsgUpdateParams { option (cosmos.msg.v1.signer) = "authority"; // authority is the address of the governance account. string authority = 1 [ (cosmos_proto.scalar) = "cosmos.AddressString" ]; // params defines the x/mint parameters to update. // // NOTE: All parameters must be supplied. Params params = 2 [ (gogoproto.nullable) = false ]; } // MsgUpdateParamsResponse defines the response structure for executing a // MsgUpdateParams message. // // Since: cosmos-sdk 0.47 message MsgUpdateParamsResponse {} ================================================ FILE: scripts/install_cyber.sh ================================================ #!/bin/sh # Installation script for cyber. It tries to move $bin in one of the # directories stored in $binpaths. binpaths="/usr/local/bin /usr/bin" libpaths="/usr/lib /usr/local/lib" # This variable contains a nonzero length string in case the script fails # because of missing write permissions. is_write_perm_missing="" # Download archive with cyber binaries according to platform type PLATFORM=$(uname) case "$PLATFORM" in "Darwin") # macOS curl -OL https://github.com/cybercongress/go-cyber/releases/download/v0.2.0/cyber_v0.2.0_darwin-amd64.tar.gz tar -xzf cyber_v0.2.0_darwin-amd64.tar.gz for binpath in $binpaths; do if cp build_v0.2.0_darwin_amd64/cyber "$binpath"; then for libpath in $libpaths; do if cp build_v0.2.0_darwin_amd64/libwasmvm.dylib "$libpath"; then cp build_v0.2.0_darwin_amd64/libwasmvm.so "$libpath" echo "Moved libwasmvm to $libpath" break else if [ -d "$libpath" ] && [ ! -w "$libpath" ]; then is_write_perm_missing=1 fi fi done echo "Moved $bin to $binpath" echo "Enjoy your cyber experience!" rm cyber_v0.2.0_darwin-amd64.tar.gz rm -rf build_v0.2.0_darwin_amd64 exit 0 else if [ -d "$binpath" ] && [ ! -w "$binpath" ]; then is_write_perm_missing=1 rm cyber_v0.2.0_darwin-amd64.tar.gz rm -rf build_v0.2.0_darwin_amd64 fi fi done ;; "Linux") # Linux distro, curl -OL https://github.com/cybercongress/go-cyber/releases/download/v0.2.0/cyber_v0.2.0_linux-amd64.tar.gz tar -xzf cyber_v0.2.0_linux-amd64.tar.gz -C ./ for binpath in $binpaths; do if cp build_v0.2.0_linux_amd64/cyber "$binpath"; then for libpath in $libpaths; do if cp build_v0.2.0_linux_amd64/libwasmvm.dylib "$libpath"; then cp build_v0.2.0_linux_amd64/libwasmvm.so "$libpath" echo "Moved libwasmvm to $libpath" break else if [ -d "$libpath" ] && [ ! -w "$libpath" ]; then is_write_perm_missing=1 fi fi done echo "Moved $bin to $binpath" echo "Enjoy your cyber experience!" rm cyber_v0.2.0_linux-amd64.tar.gz rm -rf build_v0.2.0_linux_amd64 exit 0 else if [ -d "$binpath" ] && [ ! -w "$binpath" ]; then is_write_perm_missing=1 rm cyber_v0.2.0_linux-amd64.tar.gz rm -rf build_v0.2.0_linux_amd64 fi fi done ;; esac echo "We cannot install $bin in one of the directories $binpaths" if [ -n "$is_write_perm_missing" ]; then echo "It seems that we do not have the necessary write permissions." echo "Perhaps try running this script as a privileged user:" echo "Or check that you using default library path." echo " sudo $0" echo fi exit 1 ================================================ FILE: scripts/merge_protoc.py ================================================ #!/usr/bin/env python3 # Call this from the ./scripts/protoc_swagger_openapi_gen.sh script # merged protoc definitions together into 1 JSON file without duplicate keys # this is done AFTER swagger-merger has been run, merging the multiple name-#.json files into 1. import json import os import random import string current_dir = os.path.dirname(os.path.realpath(__file__)) project_root = os.path.dirname(current_dir) all_dir = os.path.join(project_root, "tmp-swagger-gen", "_all") # get the go.mod file Version version = "" with open(os.path.join(project_root, "go.mod"), "r") as f: for line in f.readlines(): if line.startswith("module"): version = line.split("/")[-1].strip() break if not version: print("Could not find version in go.mod") exit(1) # What we will save when all combined output: dict output = { "swagger": "2.0", "info": {"title": "Bostrom network", "version": version}, "consumes": ["application/json"], "produces": ["application/json"], "paths": {}, "definitions": {}, } # Combine all individual files calls into 1 massive file. for file in os.listdir(all_dir): if not file.endswith(".json"): continue # read file all_dir / file with open(os.path.join(all_dir, file), "r") as f: data = json.load(f) for key in data["paths"]: output["paths"][key] = data["paths"][key] for key in data["definitions"]: output["definitions"][key] = data["definitions"][key] # loop through all paths, then alter any keys which are "operationId" to be a random string of 20 characters # this is done to avoid duplicate keys in the final output (which opens 2 tabs in swagger-ui) # current-random for path in output["paths"]: for method in output["paths"][path]: if "operationId" in output["paths"][path][method]: output["paths"][path][method][ "operationId" ] = f'{output["paths"][path][method]["operationId"]}_' + "".join( random.choices(string.ascii_uppercase + string.digits, k=5) ) # save output into 1 big json file with open( os.path.join(project_root, "tmp-swagger-gen", "_all", "FINAL.json"), "w" ) as f: json.dump(output, f, indent=2) ================================================ FILE: scripts/protoc_swagger_openapi_gen.sh ================================================ #!/usr/bin/env bash # Run from the project root directory # This script generates the swagger & openapi.yaml documentation for the rest API on port 1317 # # Install the following:: # sudo npm install -g swagger2openapi swagger-merger swagger-combine # go install github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger@v1.16.0 set -eo pipefail mkdir -p ./tmp-swagger-gen cd proto cosmos_sdk_dir=$(go list -f '{{ .Dir }}' -m github.com/cosmos/cosmos-sdk) ibc_go=$(go list -f '{{ .Dir }}' -m github.com/cosmos/ibc-go/v7) wasmd=$(go list -f '{{ .Dir }}' -m github.com/CosmWasm/wasmd) proto_dirs=$(find ./cyber "$cosmos_sdk_dir"/proto "$ibc_go"/proto "$wasmd"/proto -path -prune -o -name '*.proto' -print0 | xargs -0 -n1 dirname | sort | uniq) for dir in $proto_dirs; do # generate swagger files (filter query files) query_file=$(find "${dir}" -maxdepth 1 \( -name 'query.proto' -o -name 'service.proto' \)) if [[ ! -z "$query_file" ]]; then buf generate --template buf.gen.swagger.yaml $query_file fi done cd .. # combine swagger files # uses nodejs package `swagger-combine`. # Fix circular definition in cosmos/tx/v1beta1/service.swagger.json jq 'del(.definitions["cosmos.tx.v1beta1.ModeInfo.Multi"].properties.mode_infos.items["$ref"])' ./tmp-swagger-gen/cosmos/tx/v1beta1/service.swagger.json > ./tmp-swagger-gen/cosmos/tx/v1beta1/fixed-service.swagger.json jq 'del(.definitions["cosmos.autocli."].properties.mode_infos.items["$ref"])' ./tmp-swagger-gen/cosmos/tx/v1beta1/fixed-service.swagger.json > ./tmp-swagger-gen/cosmos/tx/v1beta1/fixed-service2.swagger.json rm ./tmp-swagger-gen/cosmos/tx/v1beta1/service.swagger.json rm ./tmp-swagger-gen/cosmos/orm/query/v1alpha1/query.swagger.json rm ./tmp-swagger-gen/cosmos/nft/v1beta1/query.swagger.json # TODO enable later when nfts will be added rm ./tmp-swagger-gen/cosmos/group/v1/query.swagger.json rm ./tmp-swagger-gen/cosmos/autocli/v1/query.swagger.json # this one brokes the script rm ./tmp-swagger-gen/ibc/applications/interchain_accounts/host/v1/query.swagger.json rm ./tmp-swagger-gen/ibc/applications/interchain_accounts/controller/v1/query.swagger.json # Tag everything as "gRPC Gateway API" perl -i -pe 's/"(Query|Service)"/"gRPC Gateway API"/' $(find ./tmp-swagger-gen -name '*.swagger.json' -print0 | xargs -0) # Convert all *.swagger.json files into a single folder _all files=$(find ./tmp-swagger-gen -name '*.swagger.json' -print0 | xargs -0) mkdir -p ./tmp-swagger-gen/_all counter=0 for f in $files; do echo "[+] $f" if [[ "$f" =~ "cyber" ]]; then cp $f ./tmp-swagger-gen/_all/cyber-$counter.json elif [[ "$f" =~ "cosmwasm" ]]; then cp $f ./tmp-swagger-gen/_all/cosmwasm-$counter.json elif [[ "$f" =~ "cosmos" ]]; then cp $f ./tmp-swagger-gen/_all/cosmos-$counter.json else cp $f ./tmp-swagger-gen/_all/other-$counter.json fi ((counter++)) done # merges all the above into FINAL.json python3 ./scripts/merge_protoc.py # Makes a swagger temp file with reference pointers swagger-combine ./tmp-swagger-gen/_all/FINAL.json -o ./client/docs/_tmp_swagger.yaml -f yaml --continueOnConflictingPaths --includeDefinitions # extends out the *ref instances to their full value swagger-merger --input ./client/docs/_tmp_swagger.yaml -o ./client/docs/swagger.yaml # Derive openapi from swagger docs swagger2openapi --patch ./client/docs/swagger.yaml --outfile ./client/docs/static/openapi.yml --yaml # clean swagger tmp files rm ./client/docs/_tmp_swagger.yaml rm -rf ./tmp-swagger-gen ================================================ FILE: scripts/protocgen.sh ================================================ #!/usr/bin/env bash set -eo pipefail protoc_install_proto_gen_doc() { echo "Installing protobuf protoc-gen-doc plugin" (go install github.com/pseudomuto/protoc-gen-doc/cmd/protoc-gen-doc@latest 2> /dev/null) } echo "Generating gogo proto code" cd proto proto_dirs=$(find ./cyber -path -prune -o -name '*.proto' -print0 | xargs -0 -n1 dirname | sort | uniq) for dir in $proto_dirs; do echo ${dir} for file in $(find "${dir}" -maxdepth 1 -name '*.proto'); do if grep "option go_package" $file &> /dev/null ; then buf generate --template buf.gen.gogo.yaml $file fi done done protoc_install_proto_gen_doc echo "Generating proto docs" buf generate --template buf.gen.doc.yaml cd .. # move proto files to the right places cp -r github.com/cybercongress/go-cyber/* ./ rm -rf github.com ================================================ FILE: start_script.sh ================================================ #!/bin/sh ulimit -n 4096 & export DAEMON_LOG_BUFFER_SIZE=700 export DAEMON_HOME=/root/.cyber export DAEMON_NAME=cyber export DAEMON_ALLOW_DOWNLOAD_BINARIES=false export DAEMON_RESTART_AFTER_UPGRADE=true export UNSAFE_SKIP_BACKUP=true # Start cyber process /usr/bin/cosmovisor run start --compute-gpu true --search-api $ALLOW_SEARCH --home /root/.cyber ================================================ FILE: types/account.go ================================================ package types type AccNumber uint64 ================================================ FILE: types/coins.go ================================================ package types import sdk "github.com/cosmos/cosmos-sdk/types" const ( CYB = "boot" VOLT = "millivolt" AMPERE = "milliampere" SCYB = "hydrogen" ) const ( Deca int64 = 1 Kilo = Deca * 1000 Mega = Kilo * 1000 Giga = Mega * 1000 Tera = Giga * 1000 Peta = Tera * 1000 ) func NewCybCoin(amount int64) sdk.Coin { return sdk.NewInt64Coin(CYB, amount) } func NewSCybCoin(amount int64) sdk.Coin { return sdk.NewInt64Coin(SCYB, amount) } func NewVoltCoin(amount int64) sdk.Coin { return sdk.NewInt64Coin(VOLT, amount) } func NewAmpereCoin(amount int64) sdk.Coin { return sdk.NewInt64Coin(AMPERE, amount) } ================================================ FILE: utils/context.go ================================================ package utils import ( db "github.com/cometbft/cometbft-db" tmproto "github.com/cometbft/cometbft/proto/tendermint/types" "github.com/cosmos/cosmos-sdk/store" storetypes "github.com/cosmos/cosmos-sdk/store/types" sdk "github.com/cosmos/cosmos-sdk/types" consensustypes "github.com/cosmos/cosmos-sdk/x/consensus/types" crisistypes "github.com/cosmos/cosmos-sdk/x/crisis/types" "github.com/cosmos/cosmos-sdk/x/nft" packetforwardtypes "github.com/cosmos/ibc-apps/middleware/packet-forward-middleware/v7/packetforward/types" icqtypes "github.com/cosmos/ibc-apps/modules/async-icq/v7/types" ibchookstypes "github.com/cosmos/ibc-apps/modules/ibc-hooks/v7/types" icacontrollertypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/controller/types" icahosttypes "github.com/cosmos/ibc-go/v7/modules/apps/27-interchain-accounts/host/types" ibcfeetypes "github.com/cosmos/ibc-go/v7/modules/apps/29-fee/types" clocktypes "github.com/cybercongress/go-cyber/v7/x/clock/types" resourcestypes "github.com/cybercongress/go-cyber/v7/x/resources/types" tokenfactorytypes "github.com/cybercongress/go-cyber/v7/x/tokenfactory/types" ) func NewContextWithMSVersion(db db.DB, version int64, keys map[string]*storetypes.KVStoreKey) (sdk.Context, error) { ms := store.NewCommitMultiStore(db) delete(keys, ibcfeetypes.ModuleName) delete(keys, consensustypes.ModuleName) delete(keys, resourcestypes.ModuleName) delete(keys, crisistypes.ModuleName) delete(keys, tokenfactorytypes.ModuleName) delete(keys, clocktypes.ModuleName) delete(keys, nft.ModuleName) delete(keys, icahosttypes.StoreKey) delete(keys, icacontrollertypes.StoreKey) delete(keys, ibchookstypes.StoreKey) delete(keys, packetforwardtypes.StoreKey) delete(keys, icqtypes.StoreKey) for _, key := range keys { ms.MountStoreWithDB(key, storetypes.StoreTypeIAVL, nil) } err := ms.LoadVersion(version) if err != nil { // TODO put comment here because when added new module during migration this module have 0 store's version return sdk.Context{}, err } return sdk.NewContext(ms, tmproto.Header{Height: version}, false, nil), nil } ================================================ FILE: utils/io.go ================================================ package utils import ( "errors" "io" "path/filepath" "github.com/cometbft/cometbft/libs/cli" "github.com/spf13/viper" ) func RootifyPath(path string) string { if filepath.IsAbs(path) { return path } rootDir := viper.GetString(cli.HomeFlag) return filepath.Join(rootDir, path) } func ReadExactlyNBytes(reader io.Reader, n uint64) ([]byte, error) { data := make([]byte, n) currentlyReadedBytes := uint64(0) for currentlyReadedBytes < n { readedBytes, err := reader.Read(data[currentlyReadedBytes:n]) if err != nil { return nil, err } if readedBytes == 0 { return nil, errors.New("not enough bytes tor read") } currentlyReadedBytes += uint64(readedBytes) } return data, nil } ================================================ FILE: x/bandwidth/abci.go ================================================ package bandwidth import ( "time" "github.com/cosmos/cosmos-sdk/telemetry" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/bandwidth/keeper" "github.com/cybercongress/go-cyber/v7/x/bandwidth/types" ) func EndBlocker(ctx sdk.Context, bm *keeper.BandwidthMeter) { defer telemetry.ModuleMeasureSince(types.ModuleName, time.Now(), telemetry.MetricKeyEndBlocker) params := bm.GetParams(ctx) if ctx.BlockHeight() != 0 && uint64(ctx.BlockHeight())%params.AdjustPricePeriod == 0 { bm.AdjustPrice(ctx) // TODO Add block event for price and load } bm.CommitBlockBandwidth(ctx) // TODO add block event for committed bandwidth } ================================================ FILE: x/bandwidth/client/cli/query.go ================================================ package cli import ( "context" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" sdk "github.com/cosmos/cosmos-sdk/types" // sdk "github.com/cosmos/cosmos-sdk/types" "github.com/spf13/cobra" "github.com/cybercongress/go-cyber/v7/x/bandwidth/types" ) func GetQueryCmd() *cobra.Command { queryCmd := &cobra.Command{ Use: types.ModuleName, Short: "Querying commands for the bandwidth module", DisableFlagParsing: true, SuggestionsMinimumDistance: 2, RunE: client.ValidateCmd, } queryCmd.AddCommand( GetCmdQueryParams(), GetCmdQueryPrice(), GetCmdQueryLoad(), GetCmdQueryTotalBandwidth(), GetCmdQueryNeuron(), ) return queryCmd } func GetCmdQueryParams() *cobra.Command { cmd := &cobra.Command{ Use: "params", Short: "Query the current bandwidth module parameters information", Args: cobra.NoArgs, RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientQueryContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) res, err := queryClient.Params( context.Background(), &types.QueryParamsRequest{}, ) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } func GetCmdQueryLoad() *cobra.Command { cmd := &cobra.Command{ Use: "load", Short: "Query the bandwidth load", Args: cobra.NoArgs, RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientQueryContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) res, err := queryClient.Load( context.Background(), &types.QueryLoadRequest{}, ) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } func GetCmdQueryPrice() *cobra.Command { cmd := &cobra.Command{ Use: "price", Short: "Query the bandwidth price", Args: cobra.NoArgs, RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientQueryContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) res, err := queryClient.Price( context.Background(), &types.QueryPriceRequest{}, ) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } func GetCmdQueryTotalBandwidth() *cobra.Command { cmd := &cobra.Command{ Use: "total", Short: "Query the total bandwidth", Args: cobra.NoArgs, RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientQueryContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) res, err := queryClient.TotalBandwidth( context.Background(), &types.QueryTotalBandwidthRequest{}, ) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } func GetCmdQueryNeuron() *cobra.Command { cmd := &cobra.Command{ Use: "neuron [address]", Short: "Query the neuron bandwidth [address]", Args: cobra.ExactArgs(1), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientQueryContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) addr, err := sdk.AccAddressFromBech32(args[0]) if err != nil { return err } res, err := queryClient.NeuronBandwidth( context.Background(), &types.QueryNeuronBandwidthRequest{Neuron: addr.String()}, ) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } ================================================ FILE: x/bandwidth/exported/exported.go ================================================ package exported import ( sdk "github.com/cosmos/cosmos-sdk/types" paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" ) type ( ParamSet = paramtypes.ParamSet // Subspace defines an interface that implements the legacy x/params Subspace // type. // // NOTE: This is used solely for migration of x/params managed parameters. Subspace interface { GetParamSet(ctx sdk.Context, ps ParamSet) } ) ================================================ FILE: x/bandwidth/keeper/blocks.go ================================================ package keeper import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/bandwidth/types" ) func (bm BandwidthMeter) SetBlockBandwidth(ctx sdk.Context, blockNumber uint64, value uint64) { store := ctx.KVStore(bm.storeKey) store.Set(types.BlockStoreKey(blockNumber), sdk.Uint64ToBigEndian(value)) } func (bm BandwidthMeter) GetValuesForPeriod(ctx sdk.Context, period uint64) map[uint64]uint64 { store := ctx.KVStore(bm.storeKey) windowStart := ctx.BlockHeight() - int64(period) + 1 if windowStart <= 0 { windowStart = 1 } result := make(map[uint64]uint64) for blockNumber := uint64(windowStart); blockNumber <= uint64(ctx.BlockHeight()); blockNumber++ { result[blockNumber] = sdk.BigEndianToUint64(store.Get(types.BlockStoreKey(blockNumber))) } return result } ================================================ FILE: x/bandwidth/keeper/genesis.go ================================================ package keeper import ( sdk "github.com/cosmos/cosmos-sdk/types" authkeeper "github.com/cosmos/cosmos-sdk/x/auth/keeper" "github.com/cybercongress/go-cyber/v7/x/bandwidth/types" ) func InitGenesis(ctx sdk.Context, bm *BandwidthMeter, _ authkeeper.AccountKeeper, data types.GenesisState) { if err := bm.SetParams(ctx, data.Params); err != nil { panic(err) } bm.currentCreditPrice = bm.GetBandwidthPrice(ctx, data.Params.BasePrice) } func ExportGenesis(ctx sdk.Context, bm *BandwidthMeter) *types.GenesisState { return types.NewGenesisState(bm.GetParams(ctx)) } ================================================ FILE: x/bandwidth/keeper/grpc_query.go ================================================ package keeper import ( "context" sdk "github.com/cosmos/cosmos-sdk/types" "google.golang.org/grpc/codes" "google.golang.org/grpc/status" "github.com/cybercongress/go-cyber/v7/x/bandwidth/types" ) var _ types.QueryServer = &BandwidthMeter{} func (bm BandwidthMeter) Params(goCtx context.Context, request *types.QueryParamsRequest) (*types.QueryParamsResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) params := bm.GetParams(ctx) return &types.QueryParamsResponse{Params: params}, nil } func (bm *BandwidthMeter) Load(goCtx context.Context, request *types.QueryLoadRequest) (*types.QueryLoadResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) load := bm.GetCurrentNetworkLoad(ctx) return &types.QueryLoadResponse{Load: load}, nil } func (bm *BandwidthMeter) Price(_ context.Context, _ *types.QueryPriceRequest) (*types.QueryPriceResponse, error) { price := bm.GetCurrentCreditPrice() return &types.QueryPriceResponse{Price: price}, nil } func (bm *BandwidthMeter) TotalBandwidth(goCtx context.Context, _ *types.QueryTotalBandwidthRequest) (*types.QueryTotalBandwidthResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) totalBandwidth := bm.GetDesirableBandwidth(ctx) return &types.QueryTotalBandwidthResponse{TotalBandwidth: totalBandwidth}, nil } func (bm *BandwidthMeter) NeuronBandwidth(goCtx context.Context, request *types.QueryNeuronBandwidthRequest) (*types.QueryNeuronBandwidthResponse, error) { if request == nil { return nil, status.Errorf(codes.InvalidArgument, "empty request") } if request.Neuron == "" { return nil, status.Errorf(codes.InvalidArgument, "source address cannot be empty") } addr, err := sdk.AccAddressFromBech32(request.Neuron) if err != nil { return nil, err } ctx := sdk.UnwrapSDKContext(goCtx) neuronBandwidth := bm.GetCurrentVoltsAccountBandwidth(ctx, addr) return &types.QueryNeuronBandwidthResponse{NeuronBandwidth: neuronBandwidth}, nil } ================================================ FILE: x/bandwidth/keeper/keeper.go ================================================ package keeper import ( sdkmath "cosmossdk.io/math" "fmt" storetypes "github.com/cosmos/cosmos-sdk/store/types" ctypes "github.com/cybercongress/go-cyber/v7/types" "github.com/cometbft/cometbft/libs/log" "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/telemetry" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/bandwidth/types" gtypes "github.com/cybercongress/go-cyber/v7/x/graph/types" ) type BandwidthMeter struct { stakeProvider types.AccountStakeProvider cdc codec.BinaryCodec storeKey storetypes.StoreKey tkey *storetypes.TransientStoreKey currentCreditPrice sdk.Dec bandwidthSpentByBlock map[uint64]uint64 totalSpentForSlidingWindow uint64 authority string } func NewBandwidthMeter( cdc codec.BinaryCodec, key storetypes.StoreKey, tkey *storetypes.TransientStoreKey, asp types.AccountStakeProvider, authority string, ) *BandwidthMeter { return &BandwidthMeter{ cdc: cdc, storeKey: key, tkey: tkey, stakeProvider: asp, bandwidthSpentByBlock: make(map[uint64]uint64), authority: authority, } } func (bm BandwidthMeter) GetAuthority() string { return bm.authority } func (bm BandwidthMeter) Logger(ctx sdk.Context) log.Logger { return ctx.Logger().With("module", fmt.Sprintf("x/%s", types.ModuleName)) } func (bm BandwidthMeter) SetParams(ctx sdk.Context, p types.Params) error { if err := p.Validate(); err != nil { return err } store := ctx.KVStore(bm.storeKey) bz := bm.cdc.MustMarshal(&p) store.Set(types.ParamsKey, bz) return nil } func (bm BandwidthMeter) GetParams(ctx sdk.Context) (p types.Params) { store := ctx.KVStore(bm.storeKey) bz := store.Get(types.ParamsKey) if bz == nil { return p } bm.cdc.MustUnmarshal(bz, &p) return p } func (bm *BandwidthMeter) LoadState(ctx sdk.Context) { params := bm.GetParams(ctx) bm.totalSpentForSlidingWindow = 0 // TODO test case when period parameter is increased bm.bandwidthSpentByBlock = bm.GetValuesForPeriod(ctx, params.RecoveryPeriod) for _, spentBandwidth := range bm.bandwidthSpentByBlock { bm.totalSpentForSlidingWindow += spentBandwidth } bm.currentCreditPrice = bm.GetBandwidthPrice(ctx, params.BasePrice) } func (bm *BandwidthMeter) InitState() { bm.totalSpentForSlidingWindow = 0 window := make(map[uint64]uint64) window[1] = 0 bm.bandwidthSpentByBlock = window } func (bm BandwidthMeter) GetBandwidthPrice(ctx sdk.Context, basePrice sdk.Dec) sdk.Dec { store := ctx.KVStore(bm.storeKey) priceAsBytes := store.Get(types.LastBandwidthPrice) if priceAsBytes == nil { return basePrice } var price types.Price bm.cdc.MustUnmarshal(priceAsBytes, &price) return price.Price } func (bm BandwidthMeter) StoreBandwidthPrice(ctx sdk.Context, price sdk.Dec) { store := ctx.KVStore(bm.storeKey) store.Set(types.LastBandwidthPrice, bm.cdc.MustMarshal(&types.Price{Price: price})) } func (bm BandwidthMeter) GetDesirableBandwidth(ctx sdk.Context) uint64 { store := ctx.KVStore(bm.storeKey) bandwidthAsBytes := store.Get(types.TotalBandwidth) if bandwidthAsBytes == nil { return 0 } return sdk.BigEndianToUint64(bandwidthAsBytes) } func (bm BandwidthMeter) AddToDesirableBandwidth(ctx sdk.Context, toAdd uint64) { current := bm.GetDesirableBandwidth(ctx) store := ctx.KVStore(bm.storeKey) store.Set(types.TotalBandwidth, sdk.Uint64ToBigEndian(current+toAdd)) } func (bm BandwidthMeter) SetDesirableBandwidth(ctx sdk.Context, value uint64) { store := ctx.KVStore(bm.storeKey) store.Set(types.TotalBandwidth, sdk.Uint64ToBigEndian(value)) } func (bm *BandwidthMeter) AddToBlockBandwidth(ctx sdk.Context, value uint64) { store := ctx.TransientStore(bm.tkey) current := uint64(0) blockBandwidth := store.Get(types.BlockBandwidth) if blockBandwidth != nil { current = sdk.BigEndianToUint64(blockBandwidth) } store.Set(types.BlockBandwidth, sdk.Uint64ToBigEndian(current+value)) } // Here we move bandwidth window: // Remove first block of window and add new block to window end func (bm *BandwidthMeter) CommitBlockBandwidth(ctx sdk.Context) { params := bm.GetParams(ctx) tStore := ctx.TransientStore(bm.tkey) currentBlockSpentBandwidth := sdk.BigEndianToUint64(tStore.Get(types.BlockBandwidth)) defer func() { if currentBlockSpentBandwidth > 0 { bm.Logger(ctx).Info("Block", "bandwidth", currentBlockSpentBandwidth) bm.Logger(ctx).Info("Window", "bandwidth", bm.totalSpentForSlidingWindow) } telemetry.SetGauge(float32(currentBlockSpentBandwidth), types.ModuleName, "block_bandwidth") telemetry.SetGauge(float32(bm.totalSpentForSlidingWindow), types.ModuleName, "window_bandwidth") tStore.Set(types.BlockBandwidth, sdk.Uint64ToBigEndian(0)) }() bm.totalSpentForSlidingWindow += currentBlockSpentBandwidth newWindowEnd := ctx.BlockHeight() windowStart := newWindowEnd - int64(params.RecoveryPeriod) if windowStart < 0 { windowStart = 0 } // clean window slot in in-memory windowStartValue, exists := bm.bandwidthSpentByBlock[uint64(windowStart)] if exists { bm.totalSpentForSlidingWindow -= windowStartValue delete(bm.bandwidthSpentByBlock, uint64(windowStart)) } // clean window slot in storage // TODO will be removed, need to index blocks bandwidth store := ctx.KVStore(bm.storeKey) if store.Has(types.BlockStoreKey(uint64(windowStart))) { store.Delete(types.BlockStoreKey(uint64(windowStart))) } bm.SetBlockBandwidth(ctx, uint64(ctx.BlockHeight()), currentBlockSpentBandwidth) bm.bandwidthSpentByBlock[uint64(newWindowEnd)] = currentBlockSpentBandwidth } func (bm *BandwidthMeter) GetCurrentBlockSpentBandwidth(ctx sdk.Context) uint64 { tstore := ctx.TransientStore(bm.tkey) return sdk.BigEndianToUint64(tstore.Get(types.BlockBandwidth)) } func (bm *BandwidthMeter) GetCurrentNetworkLoad(ctx sdk.Context) sdk.Dec { return sdk.NewDec(int64(bm.totalSpentForSlidingWindow)).QuoInt64(int64(bm.GetDesirableBandwidth(ctx))) } func (bm *BandwidthMeter) GetMaxBlockBandwidth(ctx sdk.Context) uint64 { params := bm.GetParams(ctx) maxBlockBandwidth := params.MaxBlockBandwidth return maxBlockBandwidth } func (bm *BandwidthMeter) GetCurrentCreditPrice() sdk.Dec { return bm.currentCreditPrice } // Adjusting of bandwidth price is disabled after the upgrade to v6, set to base price and never changes func (bm *BandwidthMeter) AdjustPrice(ctx sdk.Context) { params := bm.GetParams(ctx) desirableBandwidth := bm.GetDesirableBandwidth(ctx) baseBandwidth := params.BaseLoad.MulInt64(int64(desirableBandwidth)).RoundInt64() if baseBandwidth != 0 { telemetry.SetGauge(float32(bm.totalSpentForSlidingWindow)/float32(baseBandwidth), types.ModuleName, "load") load := sdk.NewDec(int64(bm.totalSpentForSlidingWindow)).QuoInt64(baseBandwidth) bm.Logger(ctx).Info("Load", "value", load.String()) newPrice := params.BasePrice bm.Logger(ctx).Info("Price", "value", newPrice.String()) telemetry.SetGauge(float32(newPrice.MulInt64(1000).RoundInt64()), types.ModuleName, "price") bm.currentCreditPrice = newPrice bm.StoreBandwidthPrice(ctx, newPrice) } } func (bm *BandwidthMeter) GetTotalCyberlinksCost(ctx sdk.Context, tx sdk.Tx) uint64 { bandwidthForTx := uint64(0) for _, msg := range tx.GetMsgs() { linkMsg := msg.(*gtypes.MsgCyberlink) bandwidthForTx += uint64(len(linkMsg.Links)) * 1000 } return bandwidthForTx } func (bm *BandwidthMeter) BurnAccountBandwidthVolt(ctx sdk.Context, amt uint64, address sdk.AccAddress) error { coin := sdk.NewCoin(ctypes.VOLT, sdkmath.NewIntFromUint64(amt)) if err := bm.stakeProvider.SendCoinsFromAccountToModule(ctx, address, types.BandwidthName, sdk.NewCoins(coin)); err != nil { return err } if err := bm.stakeProvider.BurnCoins(ctx, types.BandwidthName, sdk.NewCoins(coin)); err != nil { return err } return nil } func (bm *BandwidthMeter) GetCurrentVoltsAccountBandwidth(ctx sdk.Context, address sdk.AccAddress) types.NeuronBandwidth { balance := bm.stakeProvider.GetAccountStakeVolt(ctx, address) return types.NeuronBandwidth{ Neuron: address.String(), RemainedValue: uint64(balance), MaxValue: uint64(balance), LastUpdatedBlock: uint64(ctx.BlockHeight()), } } func (bm *BandwidthMeter) SetZeroAccountBandwidth(ctx sdk.Context, address sdk.AccAddress) { bw := types.NeuronBandwidth{ Neuron: address.String(), RemainedValue: 0, MaxValue: 0, LastUpdatedBlock: uint64(ctx.BlockHeight()), } ctx.KVStore(bm.storeKey).Set(types.AccountStoreKey(bw.Neuron), bm.cdc.MustMarshal(&bw)) } func (bm *BandwidthMeter) HasEnoughAccountBandwidthVolt(ctx sdk.Context, toConsume uint64, address sdk.AccAddress) bool { return uint64(bm.stakeProvider.GetAccountStakeVolt(ctx, address)) >= toConsume } ================================================ FILE: x/bandwidth/keeper/migrator.go ================================================ package keeper import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/bandwidth/exported" v2 "github.com/cybercongress/go-cyber/v7/x/bandwidth/migrations/v2" ) // Migrator is a struct for handling in-place state migrations. type Migrator struct { meter BandwidthMeter legacySubspace exported.Subspace } func NewMigrator(bm BandwidthMeter, ss exported.Subspace) Migrator { return Migrator{ meter: bm, legacySubspace: ss, } } func (m Migrator) Migrate1to2(ctx sdk.Context) error { return v2.Migrate(ctx, ctx.KVStore(m.meter.storeKey), m.legacySubspace, m.meter.cdc) } ================================================ FILE: x/bandwidth/keeper/msg_server.go ================================================ package keeper import ( "context" govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" "cosmossdk.io/errors" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/bandwidth/types" ) type msgServer struct { BandwidthMeter } func NewMsgServerImpl(meter BandwidthMeter) types.MsgServer { return &msgServer{BandwidthMeter: meter} } var _ types.MsgServer = msgServer{} func (server msgServer) UpdateParams(goCtx context.Context, req *types.MsgUpdateParams) (*types.MsgUpdateParamsResponse, error) { if server.authority != req.Authority { return nil, errors.Wrapf(govtypes.ErrInvalidSigner, "invalid authority; expected %s, got %s", server.authority, req.Authority) } ctx := sdk.UnwrapSDKContext(goCtx) if err := server.SetParams(ctx, req.Params); err != nil { return nil, err } return &types.MsgUpdateParamsResponse{}, nil } ================================================ FILE: x/bandwidth/keeper/snapshotter.go ================================================ package keeper import ( "github.com/cometbft/cometbft/libs/log" tmproto "github.com/cometbft/cometbft/proto/tendermint/types" snapshot "github.com/cosmos/cosmos-sdk/snapshots/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/bandwidth/types" ) var _ snapshot.ExtensionSnapshotter = &BandwidthSnapshotter{} const SnapshotFormat = 1 type BandwidthSnapshotter struct { keeper *BandwidthMeter cms sdk.MultiStore } func NewBandwidthSnapshotter(cms sdk.MultiStore, keeper *BandwidthMeter) *BandwidthSnapshotter { return &BandwidthSnapshotter{ keeper: keeper, cms: cms, } } func (bs *BandwidthSnapshotter) SnapshotName() string { return types.ModuleName } func (bs *BandwidthSnapshotter) SnapshotFormat() uint32 { return SnapshotFormat } func (bs *BandwidthSnapshotter) SupportedFormats() []uint32 { // If we support older formats, add them here and handle them in Restore return []uint32{SnapshotFormat} } func (bs *BandwidthSnapshotter) SnapshotExtension(_ uint64, _ snapshot.ExtensionPayloadWriter) error { return nil } func (bs *BandwidthSnapshotter) RestoreExtension(height uint64, format uint32, _ snapshot.ExtensionPayloadReader) error { if format == SnapshotFormat { ctx := sdk.NewContext(bs.cms, tmproto.Header{Height: int64(height)}, false, log.NewNopLogger()) bs.keeper.LoadState(ctx) return nil } return snapshot.ErrUnknownFormat } ================================================ FILE: x/bandwidth/migrations/v2/migrate.go ================================================ package v2 import ( "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/bandwidth/exported" "github.com/cybercongress/go-cyber/v7/x/bandwidth/types" ) func Migrate( ctx sdk.Context, store sdk.KVStore, legacySubspace exported.Subspace, cdc codec.BinaryCodec, ) error { var currParams types.Params legacySubspace.GetParamSet(ctx, &currParams) if err := currParams.Validate(); err != nil { return err } bz := cdc.MustMarshal(&currParams) store.Set(types.ParamsKey, bz) return nil } ================================================ FILE: x/bandwidth/module.go ================================================ package bandwidth import ( "context" "encoding/json" "fmt" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/codec" codectypes "github.com/cosmos/cosmos-sdk/codec/types" "github.com/cosmos/cosmos-sdk/types/module" authkeeper "github.com/cosmos/cosmos-sdk/x/auth/keeper" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/spf13/cobra" "github.com/cybercongress/go-cyber/v7/x/bandwidth/client/cli" "github.com/cybercongress/go-cyber/v7/x/bandwidth/exported" "github.com/cybercongress/go-cyber/v7/x/bandwidth/keeper" "github.com/cybercongress/go-cyber/v7/x/bandwidth/types" abci "github.com/cometbft/cometbft/abci/types" sdk "github.com/cosmos/cosmos-sdk/types" ) var ( _ module.AppModule = AppModule{} _ module.AppModuleBasic = AppModuleBasic{} ) type AppModuleBasic struct { cdc codec.Codec } // Name returns the wasm module's name. func (AppModuleBasic) Name() string { return types.ModuleName } func (AppModuleBasic) RegisterLegacyAminoCodec(cdc *codec.LegacyAmino) { types.RegisterLegacyAminoCodec(cdc) } func (AppModuleBasic) DefaultGenesis(cdc codec.JSONCodec) json.RawMessage { return cdc.MustMarshalJSON(&types.GenesisState{ Params: types.DefaultParams(), }) } func (b AppModuleBasic) ValidateGenesis(marshaler codec.JSONCodec, _ client.TxEncodingConfig, message json.RawMessage) error { var data types.GenesisState err := marshaler.UnmarshalJSON(message, &data) if err != nil { return err } return types.ValidateGenesis(data) } func (b AppModuleBasic) RegisterGRPCGatewayRoutes(clientCtx client.Context, serveMux *runtime.ServeMux) { err := types.RegisterQueryHandlerClient(context.Background(), serveMux, types.NewQueryClient(clientCtx)) if err != nil { panic(err) } } func (AppModuleBasic) GetTxCmd() *cobra.Command { return nil } func (AppModuleBasic) GetQueryCmd() *cobra.Command { return cli.GetQueryCmd() } func (AppModuleBasic) RegisterInterfaces(registry codectypes.InterfaceRegistry) { types.RegisterInterfaces(registry) } type AppModule struct { AppModuleBasic cdc codec.Codec ak authkeeper.AccountKeeper bm *keeper.BandwidthMeter legacySubspace exported.Subspace } func NewAppModule( cdc codec.Codec, ak authkeeper.AccountKeeper, bm *keeper.BandwidthMeter, ss exported.Subspace, ) AppModule { return AppModule{ AppModuleBasic: AppModuleBasic{cdc: cdc}, cdc: cdc, ak: ak, bm: bm, legacySubspace: ss, } } func (AppModule) Name() string { return types.ModuleName } func (am AppModule) RegisterInvariants(_ sdk.InvariantRegistry) {} func (am AppModule) RegisterServices(cfg module.Configurator) { types.RegisterQueryServer(cfg.QueryServer(), am.bm) types.RegisterMsgServer(cfg.MsgServer(), keeper.NewMsgServerImpl(*am.bm)) m := keeper.NewMigrator(*am.bm, am.legacySubspace) if err := cfg.RegisterMigration(types.ModuleName, 1, m.Migrate1to2); err != nil { panic(fmt.Sprintf("failed to migrate x/%s from version 1 to 2: %v", types.ModuleName, err)) } } func (am AppModule) InitGenesis(ctx sdk.Context, cdc codec.JSONCodec, data json.RawMessage) []abci.ValidatorUpdate { var genesisState types.GenesisState cdc.MustUnmarshalJSON(data, &genesisState) keeper.InitGenesis(ctx, am.bm, am.ak, genesisState) return []abci.ValidatorUpdate{} } func (am AppModule) ExportGenesis(ctx sdk.Context, cdc codec.JSONCodec) json.RawMessage { gs := keeper.ExportGenesis(ctx, am.bm) return cdc.MustMarshalJSON(gs) } func (am AppModule) ConsensusVersion() uint64 { return 2 } func (am AppModule) BeginBlock(_ sdk.Context, _ abci.RequestBeginBlock) {} func (am AppModule) EndBlock(ctx sdk.Context, _ abci.RequestEndBlock) []abci.ValidatorUpdate { EndBlocker(ctx, am.bm) return []abci.ValidatorUpdate{} } ================================================ FILE: x/bandwidth/spec/00_concepts.md ================================================ ## Bandwidth model Bandwidth is used for billing for cyberlinks creation instead of fee billing based on gas. Using the bandwidth model removes the cognitive gap for cyberlinks creation because not force neurons to pay a fee. Holding 1 volt represents the possibility to create 1 cyberlinks per ```RecoveryPeriod``` blocks. (example 1 cyberlink per day holding 1 Volt) Total supply of VOLTs (volts' holdings of all neurons) it's desirable network bandwidth. By investminting of HYDROGEN to VOLT then neuron increase personal bandwidth and desirable bandwidth of network. If the network has low bandwidth consumption, then the network provides a discount using ```BasePrice``` multiplier for neurons. ## Personal Bandwidth The volt's stake of the given neuron are easy to understand as the size of his battery. The creation of cyberlinks will consume battery charge, and the battery will be fully recharged during ```RecoveryPeriod``` blocks period. If a neuron consumes half of its bandwidth, its battery will be fully charged in the ```RecoveryPeriod/2``` blocks period. If a neuron act when network bandwidth consumption is low, then he will consume less personal bandwidth. ## Bandwidth Load The network keeps track of total consumed bandwidth during ```RecoveryPeriod``` and weights this window aggregated value to desirable bandwidth. If the current load is more than ```BasePrice```, the price value will be set. ## Bandwidth Price Bandwidth price it's a multiplier for default bandwidth price. As 1 VOLT allows creating 1 cyberlink per given period, if the price is lower than 1, the network will consume less of bandwidth, allowing neurons to generate more cyberlinks. ## Accounting of bandwidth Internally 1 Volt represents 1000 millivolts, and 1 cyberlink cost is 1000 bandwidth units. Neurons holdings of 5 Volts means 5000 personal bandwidth units. When the current load is less than BasePrice amount (e.g 0.25), then the network will make the discount for bandwidth bill 4X allowing neurons to create 4X more cyberlinks, 20 cyberlinks in such case. ## Transaction's mempool For transactions that consist of cyberlinks, a fee check will not apply. But correct required gas amount should be provided. ## Network capacity The total amount of minted (with investmint) VOLTs represents the demand of bandwidth from neurons. Validators need to keep tracking investments in VOLTs resources to provide great service at scale. To dynamically adjust available peek load community may adjust maximum bandwidth ```MaxBlockBandwidth``` and gas ```MaxGas``` consumable at block. ================================================ FILE: x/bandwidth/spec/01_api.md ================================================ # API # REST | Path | Parameters | Description | | --------------------------------------| -------------------- | ------------------------------------------ | | /bandwidth/parameters | | get module params | | /bandwidth/load | | get bandwidth load | | /bandwidth/price | | get bandwidth price | | /bandwidth/desirable | | get desirable bandwidth | | /bandwidth/account/{address} | {address} | get bandwidth of give account address | # GRPC | Path | Parameters | Description | | ----------------------------------------------------- | -------------------- | ------------------------------------------ | | /cyber/bandwidth/v1beta1/bandwidth/parameters | | get module params | | /cyber/bandwidth/v1beta1/bandwidth/load | | get bandwidth load | | /cyber/bandwidth/v1beta1/bandwidth/price | | get bandwidth price | | /cyber/bandwidth/v1beta1/bandwidth/desirable | | get desirable bandwidth | | /cyber/bandwidth/v1beta1/bandwidth/account/{address} | {address} | get bandwidth of give account address | ================================================ FILE: x/bandwidth/spec/02_state.md ================================================ # State ## Account Bandwidth AccountBandwidth is used for tracking bandwidth of accounts in the network. AccountBandwidth type has the following structure: ``` type AccountBandwidth struct { address string // address of neuron remainedValue uint64 // current bandwidth value lastUpdatedBlock uint64 // last block when last time updated maxValue uint64 // max current bandwidth value of neuron } ``` ## Last price Value is used to store up-to-date price of bandwidth. ``` type Price struct { price sdk.Dec // current multiplier for bandwidth billing } ``` ## Block bandwidth Storing used bandwidth for each block. Used for calculation of load using sum of used bandwidth in blocks at recovery period window. Used for reverting transactions with cyberlinks if rise more than ```MaxBlockBandwidth``` ``` sdk.Uint64ToBigEndian(value) // where value is amount of bandwidth used by all neurons in given block ``` ## Desirable bandwidth Desirable bandwidth represents amount of cyberlinks that network would like to process. ``` sdk.Uint64ToBigEndian(value) // where value is total current supply of mvolt (uint64) ``` ------- ## Keys - Account bandwidth: `0x01 | []byte(address) -> ProtocolBuffer(AccountBandwidth)` - Block bandwidth: `0x02 | sdk.Uint64ToBigEndian(blockNumber) -> sdk.Uint64ToBigEndian(value)` - Last bandwidth price: `0x00 | []byte("lastBandwidthPrice") -> ProtocolBuffer(Price)` - Desirable bandwidth: `0x00 | []byte("desirableBandwidth") -> sdk.Uint64ToBigEndian(value)` - ModuleName, StoreKey: `bandwidth` ================================================ FILE: x/bandwidth/spec/03_state_transitions.md ================================================ # State Transitions [WIP] Bandwidth module doesn't have own messages that trigger state transition. State transition is happen in such cases: ## Processing of transaction with cyberlinks messages in transaction middleware (ante handler) 1. calculate total bandwidth amount for all cyberlinks messages in transaction using current price and consume neuron's bandwidth 2. add consumed bandwidth to block bandwidth (in-memory) ## Processing of cyberlink message created by VM contract (graph module) 1. calculate bandwidth for message using current price and consume neuron's bandwidth 2. add consumed bandwidth to block bandwidth (in-memory) Note: billing happens in the graph module for contracts because contracts creates messages not grouped into transactions (ante handler are not processing them) ## Transfers of Volts (EndBlocker) 1. Update account's bandwidth for an account with changed stake collected by ```CollectAddressesWithStakeChange``` hook (e.g transfer of investmint). Note: minting of new volts (using investmint) will trigger the account's bandwidth update with an increased max bandwidth value ## Save consumed bandwidth by block (EndBlocker) 1. Save the total amount (sum aggregated in-memory before) of consumed bandwidth by all neurons on a given block (to storage & in-memory). 2. Remove value for a block that is out of ```RecoveryWindow``` block period and not perform in bandwidth load calculation (to storage & in-memory). ## Adjust bandwidth price (EndBlocker) 1. If block height number's remainder of division by ```AdjustPrice``` parameter is equal to zero - calculate and save price based on current load (or apply ```BasePrice``` if load less than ```BasePrice```). ## Genesis 1. If neuron have volts in genesis - initialize and save account bandwidth with max value ================================================ FILE: x/bandwidth/spec/06_params.md ================================================ # Parameters The energy module contains the following parameters: | Key | Type | Example | | ----------------------- | -------------- | ---------------------- | | RecoveryPeriod | uint64 | 16000 | | AdjustPricePeriod | uint64 | 5 | | BasePrice | sdk.Dec | 0.25 | | MaxBlockBandwidth | uint64 | 100000 | ## Recovery Period Recovery period is amount of blocks that bandwidth of any neuron will be fully recovered (from zero to max value). ## Adjust Price Period Adjust price period is amount of blocks that form period of bandwidth price recalculation adapting to current load. ## Base Price Base price is multiplier for bandwidth billing, bandwidth discount for moments of low neurons' activity. If load rise more than value of base price than current price will be applied. ## Max Block Bandwidth Max block bandwidth is amount of bandwidth from neurons that network can process for one block. ================================================ FILE: x/bandwidth/spec/07_wasm.md ================================================ # WASM LINE In addition to the core CosmWasm functionality, the bandwidth module bindings include ## Query support - Price - Load - DesirableBandwidth - AccountBandwidth -------- Hack with [cw-cyber](https://github.com/cybercongress/cw-cyber) library ================================================ FILE: x/bandwidth/spec/08_errors.md ================================================ # Errors The bandwidth module may return the following errors: | Type | Code | Description | | ---------------------------- | ------| ------------------------------ | | ErrNotEnoughBandwidth | 2 | not enough personal bandwidth | | ErrExceededMaxBlockBandwidth | 3 | exceeded max block bandwidth | ================================================ FILE: x/bandwidth/spec/09_cli.md ================================================ # CLI ## Queries Query the current bandwidth module parameters information: ```bash cyber query bandwidth params ``` Query the bandwidth load: ```bash cyber query bandwidth load ``` Query the bandwidth price: ```bash cyber query bandwidth price ``` Query the desirable bandwidth: ```bash cyber query bandwidth desirable ``` Query the account's bandwidth: ```bash cyber query bandwidth account [address] ``` ================================================ FILE: x/bandwidth/spec/README.md ================================================ # `bandwidth` ## Abstract The bandwidth module process and stores neuron's bandwidth in the network, dynamically adjust bandwidth price to network load. Neurons use bandwidth to add cyberlinks to the network and not need to pay gas fees. ## Contents 1. **[Concepts](00_concepts.md)** 2. **[API](01_api.md)** 3. **[State](02_state.md)** 4. **[State Transitions](03_state_transitions.md)** 5. **[Parameters](06_params.md)** 6. **[WASM](07_wasm.md)** 7. **[Errors](08_errors.md)** 8. **[CLI](09_cli.md)** ================================================ FILE: x/bandwidth/types/codec.go ================================================ package types import ( "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/codec/legacy" "github.com/cosmos/cosmos-sdk/codec/types" cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/msgservice" authzcodec "github.com/cosmos/cosmos-sdk/x/authz/codec" govcodec "github.com/cosmos/cosmos-sdk/x/gov/codec" ) func RegisterLegacyAminoCodec(cdc *codec.LegacyAmino) { legacy.RegisterAminoMsg(cdc, &MsgUpdateParams{}, "cyber/bandwidth/MsgUpdateParams") cdc.RegisterConcrete(Params{}, "cyber/bandwidth/Params", nil) } func RegisterInterfaces(registry types.InterfaceRegistry) { registry.RegisterImplementations((*sdk.Msg)(nil), &MsgUpdateParams{}, ) msgservice.RegisterMsgServiceDesc(registry, &_Msg_serviceDesc) } var ( amino = codec.NewLegacyAmino() ModuleCdc = codec.NewAminoCodec(amino) ) func init() { RegisterLegacyAminoCodec(amino) cryptocodec.RegisterCrypto(amino) sdk.RegisterLegacyAminoCodec(amino) RegisterLegacyAminoCodec(authzcodec.Amino) RegisterLegacyAminoCodec(govcodec.Amino) } ================================================ FILE: x/bandwidth/types/errors.go ================================================ package types import ( errorsmod "cosmossdk.io/errors" ) var ( ErrNotEnoughBandwidth = errorsmod.Register(ModuleName, 2, "not enough personal bandwidth") ErrExceededMaxBlockBandwidth = errorsmod.Register(ModuleName, 3, "exceeded max block bandwidth") ) ================================================ FILE: x/bandwidth/types/expected_keepers.go ================================================ package types import ( sdk "github.com/cosmos/cosmos-sdk/types" ) type AccountStakeProvider interface { GetAccountStakeVolt(ctx sdk.Context, addr sdk.AccAddress) int64 SendCoinsFromAccountToModule(ctx sdk.Context, senderAddr sdk.AccAddress, recipientModule string, amt sdk.Coins) error BurnCoins(ctx sdk.Context, moduleName string, amt sdk.Coins) error } ================================================ FILE: x/bandwidth/types/genesis.go ================================================ package types func NewGenesisState(params Params) *GenesisState { return &GenesisState{ Params: params, } } func DefaultGenesisState() *GenesisState { return NewGenesisState(DefaultParams()) } func ValidateGenesis(data GenesisState) error { if err := data.Params.Validate(); err != nil { return err } return nil } ================================================ FILE: x/bandwidth/types/genesis.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: cyber/bandwidth/v1beta1/genesis.proto package types import ( fmt "fmt" io "io" math "math" math_bits "math/bits" _ "github.com/cosmos/gogoproto/gogoproto" proto "github.com/cosmos/gogoproto/proto" ) // Reference imports to suppress errors if they are not otherwise used. var ( _ = proto.Marshal _ = fmt.Errorf _ = math.Inf ) // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package type GenesisState struct { Params Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params"` } func (m *GenesisState) Reset() { *m = GenesisState{} } func (m *GenesisState) String() string { return proto.CompactTextString(m) } func (*GenesisState) ProtoMessage() {} func (*GenesisState) Descriptor() ([]byte, []int) { return fileDescriptor_3fe039025849c89e, []int{0} } func (m *GenesisState) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *GenesisState) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_GenesisState.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *GenesisState) XXX_Merge(src proto.Message) { xxx_messageInfo_GenesisState.Merge(m, src) } func (m *GenesisState) XXX_Size() int { return m.Size() } func (m *GenesisState) XXX_DiscardUnknown() { xxx_messageInfo_GenesisState.DiscardUnknown(m) } var xxx_messageInfo_GenesisState proto.InternalMessageInfo func (m *GenesisState) GetParams() Params { if m != nil { return m.Params } return Params{} } func init() { proto.RegisterType((*GenesisState)(nil), "cyber.bandwidth.v1beta1.GenesisState") } func init() { proto.RegisterFile("cyber/bandwidth/v1beta1/genesis.proto", fileDescriptor_3fe039025849c89e) } var fileDescriptor_3fe039025849c89e = []byte{ // 211 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x4d, 0xae, 0x4c, 0x4a, 0x2d, 0xd2, 0x4f, 0x4a, 0xcc, 0x4b, 0x29, 0xcf, 0x4c, 0x29, 0xc9, 0xd0, 0x2f, 0x33, 0x4c, 0x4a, 0x2d, 0x49, 0x34, 0xd4, 0x4f, 0x4f, 0xcd, 0x4b, 0x2d, 0xce, 0x2c, 0xd6, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x07, 0x2b, 0xd3, 0x83, 0x2b, 0xd3, 0x83, 0x2a, 0x93, 0x12, 0x49, 0xcf, 0x4f, 0xcf, 0x07, 0xab, 0xd1, 0x07, 0xb1, 0x20, 0xca, 0xa5, 0x94, 0x71, 0x99, 0x5a, 0x52, 0x59, 0x90, 0x0a, 0x35, 0x53, 0xc9, 0x97, 0x8b, 0xc7, 0x1d, 0x62, 0x49, 0x70, 0x49, 0x62, 0x49, 0xaa, 0x90, 0x2d, 0x17, 0x5b, 0x41, 0x62, 0x51, 0x62, 0x6e, 0xb1, 0x04, 0xa3, 0x02, 0xa3, 0x06, 0xb7, 0x91, 0xbc, 0x1e, 0x0e, 0x4b, 0xf5, 0x02, 0xc0, 0xca, 0x9c, 0x58, 0x4e, 0xdc, 0x93, 0x67, 0x08, 0x82, 0x6a, 0x72, 0xf2, 0x3d, 0xf1, 0x48, 0x8e, 0xf1, 0xc2, 0x23, 0x39, 0xc6, 0x07, 0x8f, 0xe4, 0x18, 0x27, 0x3c, 0x96, 0x63, 0xb8, 0xf0, 0x58, 0x8e, 0xe1, 0xc6, 0x63, 0x39, 0x86, 0x28, 0xe3, 0xf4, 0xcc, 0x92, 0x8c, 0xd2, 0x24, 0xbd, 0xe4, 0xfc, 0x5c, 0x7d, 0xb0, 0x91, 0xc9, 0xf9, 0x79, 0xe9, 0x45, 0xa9, 0xc5, 0xc5, 0xfa, 0xe9, 0xf9, 0xba, 0x10, 0x97, 0x56, 0x20, 0xb9, 0x15, 0xec, 0xc6, 0x24, 0x36, 0xb0, 0x23, 0x8d, 0x01, 0x01, 0x00, 0x00, 0xff, 0xff, 0xa3, 0xf4, 0x54, 0xd0, 0x21, 0x01, 0x00, 0x00, } func (m *GenesisState) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *GenesisState) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *GenesisState) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.Params.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintGenesis(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa return len(dAtA) - i, nil } func encodeVarintGenesis(dAtA []byte, offset int, v uint64) int { offset -= sovGenesis(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *GenesisState) Size() (n int) { if m == nil { return 0 } var l int _ = l l = m.Params.Size() n += 1 + l + sovGenesis(uint64(l)) return n } func sovGenesis(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozGenesis(x uint64) (n int) { return sovGenesis(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *GenesisState) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenesis } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: GenesisState: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: GenesisState: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenesis } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthGenesis } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenesis } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Params.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipGenesis(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthGenesis } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipGenesis(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowGenesis } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowGenesis } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowGenesis } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthGenesis } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupGenesis } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthGenesis } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthGenesis = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowGenesis = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupGenesis = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/bandwidth/types/keys.go ================================================ package types import ( sdk "github.com/cosmos/cosmos-sdk/types" ) const ( ModuleName = "bandwidth" StoreKey = ModuleName TStoreKey = "transient_bandwidth" BandwidthName = "bandwidth" ) var ( GlobalStoreKeyPrefix = []byte{0x00} AccountStoreKeyPrefix = []byte{0x01} BlockStoreKeyPrefix = []byte{0x02} ParamsKey = []byte{0x02} LastBandwidthPrice = append(GlobalStoreKeyPrefix, []byte("lastBandwidthPrice")...) TotalBandwidth = append(GlobalStoreKeyPrefix, []byte("totalBandwidth")...) BlockBandwidth = append(GlobalStoreKeyPrefix, []byte("blockBandwidth")...) ) func AccountStoreKey(addr string) []byte { return append(AccountStoreKeyPrefix, []byte(addr)...) } func BlockStoreKey(blockNumber uint64) []byte { return append(BlockStoreKeyPrefix, sdk.Uint64ToBigEndian(blockNumber)...) } ================================================ FILE: x/bandwidth/types/msgs.go ================================================ package types import ( errorsmod "cosmossdk.io/errors" sdk "github.com/cosmos/cosmos-sdk/types" ) var _ sdk.Msg = &MsgUpdateParams{} // GetSignBytes implements the LegacyMsg interface. func (m MsgUpdateParams) GetSignBytes() []byte { return sdk.MustSortJSON(ModuleCdc.MustMarshalJSON(&m)) } // GetSigners returns the expected signers for a MsgUpdateParams message. func (m *MsgUpdateParams) GetSigners() []sdk.AccAddress { addr, _ := sdk.AccAddressFromBech32(m.Authority) return []sdk.AccAddress{addr} } // ValidateBasic does a sanity check on the provided data. func (m *MsgUpdateParams) ValidateBasic() error { if _, err := sdk.AccAddressFromBech32(m.Authority); err != nil { return errorsmod.Wrap(err, "invalid authority address") } return m.Params.Validate() } ================================================ FILE: x/bandwidth/types/params.go ================================================ package types import ( "fmt" sdkmath "cosmossdk.io/math" sdk "github.com/cosmos/cosmos-sdk/types" ) func DefaultParams() Params { return Params{ RecoveryPeriod: uint64(100), AdjustPricePeriod: uint64(5), BasePrice: sdk.NewDecWithPrec(25, 2), BaseLoad: sdk.NewDecWithPrec(10, 2), MaxBlockBandwidth: uint64(10000), } } func NewParams( recoveryPeriod uint64, adjustPricePeriod uint64, basePrice sdkmath.LegacyDec, baseLoad sdkmath.LegacyDec, maxBlockBandwidth uint64, ) Params { return Params{ RecoveryPeriod: recoveryPeriod, AdjustPricePeriod: adjustPricePeriod, BasePrice: basePrice, BaseLoad: baseLoad, MaxBlockBandwidth: maxBlockBandwidth, } } func (p Params) Validate() error { if err := validateRecoveryPeriod(p.RecoveryPeriod); err != nil { return err } if err := validateAdjustPricePeriod(p.AdjustPricePeriod); err != nil { return err } if err := validateBasePrice(p.BasePrice); err != nil { return err } if err := validateBaseLoad(p.BaseLoad); err != nil { return err } if err := validateMaxBlockBandwidth(p.MaxBlockBandwidth); err != nil { return err } return nil } func validateRecoveryPeriod(i interface{}) error { v, ok := i.(uint64) if !ok { return fmt.Errorf("invalid parameter type: %T", i) } if v <= uint64(50) { return fmt.Errorf("recovery period is too low: %d", v) } return nil } func validateAdjustPricePeriod(i interface{}) error { v, ok := i.(uint64) if !ok { return fmt.Errorf("invalid parameter type: %T", i) } if v < uint64(5) { return fmt.Errorf("adjust price period is too low: %d", v) } return nil } func validateBasePrice(i interface{}) error { v, ok := i.(sdk.Dec) if !ok { return fmt.Errorf("invalid parameter type: %T", i) } if !v.IsPositive() { return fmt.Errorf("base price is not positive: %s", v) } if v.GT(sdk.OneDec()) { return fmt.Errorf("base price is more than one: %s", v) } return nil } func validateBaseLoad(i interface{}) error { v, ok := i.(sdk.Dec) if !ok { return fmt.Errorf("invalid parameter type: %T", i) } if !v.IsPositive() { return fmt.Errorf("base load is not positive: %s", v) } if v.GT(sdk.OneDec()) { return fmt.Errorf("base load is more than one: %s", v) } if v.LT(sdk.NewDecWithPrec(1, 2)) { return fmt.Errorf("base price is less than one hundredth: %s", v) } return nil } func validateMaxBlockBandwidth(i interface{}) error { v, ok := i.(uint64) if !ok { return fmt.Errorf("invalid parameter type: %T", i) } if v <= uint64(1000) { return fmt.Errorf("max block bandwidth is too low: %d", v) } return nil } ================================================ FILE: x/bandwidth/types/params_legacy.go ================================================ package types import paramstypes "github.com/cosmos/cosmos-sdk/x/params/types" var ( KeyRecoveryPeriod = []byte("RecoveryPeriod") KeyAdjustPricePeriod = []byte("AdjustPricePeriod") KeyBasePrice = []byte("BasePrice") KeyBaseLoad = []byte("BaseLoad") KeyMaxBlockBandwidth = []byte("MaxBlockBandwidth") ) // Deprecated: Type declaration for parameters func ParamKeyTable() paramstypes.KeyTable { return paramstypes.NewKeyTable().RegisterParamSet(&Params{}) } func (p *Params) ParamSetPairs() paramstypes.ParamSetPairs { return paramstypes.ParamSetPairs{ paramstypes.NewParamSetPair(KeyRecoveryPeriod, &p.RecoveryPeriod, validateRecoveryPeriod), paramstypes.NewParamSetPair(KeyAdjustPricePeriod, &p.AdjustPricePeriod, validateAdjustPricePeriod), paramstypes.NewParamSetPair(KeyBasePrice, &p.BasePrice, validateBasePrice), paramstypes.NewParamSetPair(KeyBaseLoad, &p.BaseLoad, validateBaseLoad), paramstypes.NewParamSetPair(KeyMaxBlockBandwidth, &p.MaxBlockBandwidth, validateMaxBlockBandwidth), } } ================================================ FILE: x/bandwidth/types/query.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: cyber/bandwidth/v1beta1/query.proto package types import ( context "context" fmt "fmt" io "io" math "math" math_bits "math/bits" github_com_cosmos_cosmos_sdk_types "github.com/cosmos/cosmos-sdk/types" _ "github.com/cosmos/gogoproto/gogoproto" grpc1 "github.com/cosmos/gogoproto/grpc" proto "github.com/cosmos/gogoproto/proto" _ "google.golang.org/genproto/googleapis/api/annotations" grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" ) // Reference imports to suppress errors if they are not otherwise used. var ( _ = proto.Marshal _ = fmt.Errorf _ = math.Inf ) // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package type QueryLoadRequest struct{} func (m *QueryLoadRequest) Reset() { *m = QueryLoadRequest{} } func (m *QueryLoadRequest) String() string { return proto.CompactTextString(m) } func (*QueryLoadRequest) ProtoMessage() {} func (*QueryLoadRequest) Descriptor() ([]byte, []int) { return fileDescriptor_bccaa873af5af46c, []int{0} } func (m *QueryLoadRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryLoadRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryLoadRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryLoadRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryLoadRequest.Merge(m, src) } func (m *QueryLoadRequest) XXX_Size() int { return m.Size() } func (m *QueryLoadRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryLoadRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryLoadRequest proto.InternalMessageInfo type QueryLoadResponse struct { Load github_com_cosmos_cosmos_sdk_types.Dec `protobuf:"bytes,1,opt,name=load,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Dec" json:"load"` } func (m *QueryLoadResponse) Reset() { *m = QueryLoadResponse{} } func (m *QueryLoadResponse) String() string { return proto.CompactTextString(m) } func (*QueryLoadResponse) ProtoMessage() {} func (*QueryLoadResponse) Descriptor() ([]byte, []int) { return fileDescriptor_bccaa873af5af46c, []int{1} } func (m *QueryLoadResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryLoadResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryLoadResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryLoadResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryLoadResponse.Merge(m, src) } func (m *QueryLoadResponse) XXX_Size() int { return m.Size() } func (m *QueryLoadResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryLoadResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryLoadResponse proto.InternalMessageInfo type QueryPriceRequest struct{} func (m *QueryPriceRequest) Reset() { *m = QueryPriceRequest{} } func (m *QueryPriceRequest) String() string { return proto.CompactTextString(m) } func (*QueryPriceRequest) ProtoMessage() {} func (*QueryPriceRequest) Descriptor() ([]byte, []int) { return fileDescriptor_bccaa873af5af46c, []int{2} } func (m *QueryPriceRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryPriceRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryPriceRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryPriceRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryPriceRequest.Merge(m, src) } func (m *QueryPriceRequest) XXX_Size() int { return m.Size() } func (m *QueryPriceRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryPriceRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryPriceRequest proto.InternalMessageInfo type QueryPriceResponse struct { Price github_com_cosmos_cosmos_sdk_types.Dec `protobuf:"bytes,1,opt,name=price,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Dec" json:"price"` } func (m *QueryPriceResponse) Reset() { *m = QueryPriceResponse{} } func (m *QueryPriceResponse) String() string { return proto.CompactTextString(m) } func (*QueryPriceResponse) ProtoMessage() {} func (*QueryPriceResponse) Descriptor() ([]byte, []int) { return fileDescriptor_bccaa873af5af46c, []int{3} } func (m *QueryPriceResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryPriceResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryPriceResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryPriceResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryPriceResponse.Merge(m, src) } func (m *QueryPriceResponse) XXX_Size() int { return m.Size() } func (m *QueryPriceResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryPriceResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryPriceResponse proto.InternalMessageInfo type QueryTotalBandwidthRequest struct{} func (m *QueryTotalBandwidthRequest) Reset() { *m = QueryTotalBandwidthRequest{} } func (m *QueryTotalBandwidthRequest) String() string { return proto.CompactTextString(m) } func (*QueryTotalBandwidthRequest) ProtoMessage() {} func (*QueryTotalBandwidthRequest) Descriptor() ([]byte, []int) { return fileDescriptor_bccaa873af5af46c, []int{4} } func (m *QueryTotalBandwidthRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryTotalBandwidthRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryTotalBandwidthRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryTotalBandwidthRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryTotalBandwidthRequest.Merge(m, src) } func (m *QueryTotalBandwidthRequest) XXX_Size() int { return m.Size() } func (m *QueryTotalBandwidthRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryTotalBandwidthRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryTotalBandwidthRequest proto.InternalMessageInfo type QueryTotalBandwidthResponse struct { TotalBandwidth uint64 `protobuf:"varint,1,opt,name=total_bandwidth,json=totalBandwidth,proto3" json:"total_bandwidth,omitempty"` } func (m *QueryTotalBandwidthResponse) Reset() { *m = QueryTotalBandwidthResponse{} } func (m *QueryTotalBandwidthResponse) String() string { return proto.CompactTextString(m) } func (*QueryTotalBandwidthResponse) ProtoMessage() {} func (*QueryTotalBandwidthResponse) Descriptor() ([]byte, []int) { return fileDescriptor_bccaa873af5af46c, []int{5} } func (m *QueryTotalBandwidthResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryTotalBandwidthResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryTotalBandwidthResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryTotalBandwidthResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryTotalBandwidthResponse.Merge(m, src) } func (m *QueryTotalBandwidthResponse) XXX_Size() int { return m.Size() } func (m *QueryTotalBandwidthResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryTotalBandwidthResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryTotalBandwidthResponse proto.InternalMessageInfo func (m *QueryTotalBandwidthResponse) GetTotalBandwidth() uint64 { if m != nil { return m.TotalBandwidth } return 0 } type QueryNeuronBandwidthRequest struct { Neuron string `protobuf:"bytes,1,opt,name=neuron,proto3" json:"neuron,omitempty"` } func (m *QueryNeuronBandwidthRequest) Reset() { *m = QueryNeuronBandwidthRequest{} } func (m *QueryNeuronBandwidthRequest) String() string { return proto.CompactTextString(m) } func (*QueryNeuronBandwidthRequest) ProtoMessage() {} func (*QueryNeuronBandwidthRequest) Descriptor() ([]byte, []int) { return fileDescriptor_bccaa873af5af46c, []int{6} } func (m *QueryNeuronBandwidthRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryNeuronBandwidthRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryNeuronBandwidthRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryNeuronBandwidthRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryNeuronBandwidthRequest.Merge(m, src) } func (m *QueryNeuronBandwidthRequest) XXX_Size() int { return m.Size() } func (m *QueryNeuronBandwidthRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryNeuronBandwidthRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryNeuronBandwidthRequest proto.InternalMessageInfo func (m *QueryNeuronBandwidthRequest) GetNeuron() string { if m != nil { return m.Neuron } return "" } type QueryNeuronBandwidthResponse struct { NeuronBandwidth NeuronBandwidth `protobuf:"bytes,1,opt,name=neuron_bandwidth,json=neuronBandwidth,proto3" json:"neuron_bandwidth"` } func (m *QueryNeuronBandwidthResponse) Reset() { *m = QueryNeuronBandwidthResponse{} } func (m *QueryNeuronBandwidthResponse) String() string { return proto.CompactTextString(m) } func (*QueryNeuronBandwidthResponse) ProtoMessage() {} func (*QueryNeuronBandwidthResponse) Descriptor() ([]byte, []int) { return fileDescriptor_bccaa873af5af46c, []int{7} } func (m *QueryNeuronBandwidthResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryNeuronBandwidthResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryNeuronBandwidthResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryNeuronBandwidthResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryNeuronBandwidthResponse.Merge(m, src) } func (m *QueryNeuronBandwidthResponse) XXX_Size() int { return m.Size() } func (m *QueryNeuronBandwidthResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryNeuronBandwidthResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryNeuronBandwidthResponse proto.InternalMessageInfo func (m *QueryNeuronBandwidthResponse) GetNeuronBandwidth() NeuronBandwidth { if m != nil { return m.NeuronBandwidth } return NeuronBandwidth{} } type QueryParamsRequest struct{} func (m *QueryParamsRequest) Reset() { *m = QueryParamsRequest{} } func (m *QueryParamsRequest) String() string { return proto.CompactTextString(m) } func (*QueryParamsRequest) ProtoMessage() {} func (*QueryParamsRequest) Descriptor() ([]byte, []int) { return fileDescriptor_bccaa873af5af46c, []int{8} } func (m *QueryParamsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryParamsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryParamsRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryParamsRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryParamsRequest.Merge(m, src) } func (m *QueryParamsRequest) XXX_Size() int { return m.Size() } func (m *QueryParamsRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryParamsRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryParamsRequest proto.InternalMessageInfo type QueryParamsResponse struct { Params Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params"` } func (m *QueryParamsResponse) Reset() { *m = QueryParamsResponse{} } func (m *QueryParamsResponse) String() string { return proto.CompactTextString(m) } func (*QueryParamsResponse) ProtoMessage() {} func (*QueryParamsResponse) Descriptor() ([]byte, []int) { return fileDescriptor_bccaa873af5af46c, []int{9} } func (m *QueryParamsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryParamsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryParamsResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryParamsResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryParamsResponse.Merge(m, src) } func (m *QueryParamsResponse) XXX_Size() int { return m.Size() } func (m *QueryParamsResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryParamsResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryParamsResponse proto.InternalMessageInfo func (m *QueryParamsResponse) GetParams() Params { if m != nil { return m.Params } return Params{} } func init() { proto.RegisterType((*QueryLoadRequest)(nil), "cyber.bandwidth.v1beta1.QueryLoadRequest") proto.RegisterType((*QueryLoadResponse)(nil), "cyber.bandwidth.v1beta1.QueryLoadResponse") proto.RegisterType((*QueryPriceRequest)(nil), "cyber.bandwidth.v1beta1.QueryPriceRequest") proto.RegisterType((*QueryPriceResponse)(nil), "cyber.bandwidth.v1beta1.QueryPriceResponse") proto.RegisterType((*QueryTotalBandwidthRequest)(nil), "cyber.bandwidth.v1beta1.QueryTotalBandwidthRequest") proto.RegisterType((*QueryTotalBandwidthResponse)(nil), "cyber.bandwidth.v1beta1.QueryTotalBandwidthResponse") proto.RegisterType((*QueryNeuronBandwidthRequest)(nil), "cyber.bandwidth.v1beta1.QueryNeuronBandwidthRequest") proto.RegisterType((*QueryNeuronBandwidthResponse)(nil), "cyber.bandwidth.v1beta1.QueryNeuronBandwidthResponse") proto.RegisterType((*QueryParamsRequest)(nil), "cyber.bandwidth.v1beta1.QueryParamsRequest") proto.RegisterType((*QueryParamsResponse)(nil), "cyber.bandwidth.v1beta1.QueryParamsResponse") } func init() { proto.RegisterFile("cyber/bandwidth/v1beta1/query.proto", fileDescriptor_bccaa873af5af46c) } var fileDescriptor_bccaa873af5af46c = []byte{ // 585 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x54, 0x41, 0x6b, 0x13, 0x4d, 0x18, 0xce, 0x7c, 0x24, 0x81, 0xef, 0x15, 0x9a, 0x3a, 0x2d, 0x2a, 0x6b, 0xd8, 0xc8, 0x0a, 0x36, 0x69, 0xed, 0x8e, 0x49, 0xda, 0x8b, 0xe0, 0x25, 0x14, 0x4f, 0x2a, 0x1a, 0x0a, 0x62, 0x2f, 0x32, 0xd9, 0x0c, 0xdb, 0x60, 0xb2, 0xb3, 0xdd, 0x99, 0xa8, 0x41, 0xbc, 0xf8, 0x03, 0x44, 0x14, 0xfc, 0x17, 0x9e, 0xbc, 0xf9, 0x0b, 0x7a, 0x2c, 0x78, 0x11, 0x0f, 0x45, 0x12, 0x7f, 0x88, 0xec, 0xcc, 0xa4, 0x6e, 0x42, 0xd6, 0x6c, 0x7b, 0xda, 0xe4, 0x9d, 0xe7, 0x7d, 0x9e, 0x67, 0xdf, 0x7d, 0xde, 0x81, 0x9b, 0xde, 0xa8, 0xc3, 0x22, 0xd2, 0xa1, 0x41, 0xf7, 0x55, 0xaf, 0x2b, 0x0f, 0xc9, 0xcb, 0x7a, 0x87, 0x49, 0x5a, 0x27, 0x47, 0x43, 0x16, 0x8d, 0xdc, 0x30, 0xe2, 0x92, 0xe3, 0xab, 0x0a, 0xe4, 0x9e, 0x81, 0x5c, 0x03, 0xb2, 0xd6, 0x7d, 0xee, 0x73, 0x85, 0x21, 0xf1, 0x2f, 0x0d, 0xb7, 0xca, 0x3e, 0xe7, 0x7e, 0x9f, 0x11, 0x1a, 0xf6, 0x08, 0x0d, 0x02, 0x2e, 0xa9, 0xec, 0xf1, 0x40, 0x98, 0xd3, 0x54, 0x45, 0x39, 0x0a, 0x99, 0x01, 0x39, 0x18, 0x56, 0x9f, 0xc4, 0x06, 0x1e, 0x70, 0xda, 0x6d, 0xb3, 0xa3, 0x21, 0x13, 0xd2, 0x79, 0x0a, 0x97, 0x13, 0x35, 0x11, 0xf2, 0x40, 0x30, 0xdc, 0x82, 0x7c, 0x9f, 0xd3, 0xee, 0x35, 0x74, 0x03, 0x55, 0xff, 0x6f, 0xb9, 0xc7, 0xa7, 0x95, 0xdc, 0xcf, 0xd3, 0xca, 0x2d, 0xbf, 0x27, 0x0f, 0x87, 0x1d, 0xd7, 0xe3, 0x03, 0xe2, 0x71, 0x31, 0xe0, 0xc2, 0x3c, 0xb6, 0x45, 0xf7, 0x85, 0x11, 0xda, 0x63, 0x5e, 0x5b, 0xf5, 0x3a, 0x6b, 0x86, 0xf8, 0x71, 0xd4, 0xf3, 0xd8, 0x54, 0xed, 0x00, 0x70, 0xb2, 0x68, 0xe4, 0xf6, 0xa0, 0x10, 0xc6, 0x85, 0x0b, 0xea, 0xe9, 0x66, 0xa7, 0x0c, 0x96, 0xe2, 0xde, 0xe7, 0x92, 0xf6, 0x5b, 0xd3, 0x41, 0x4c, 0x95, 0xef, 0xc3, 0xf5, 0x85, 0xa7, 0xc6, 0xc2, 0x06, 0x94, 0x64, 0x7c, 0xf2, 0xfc, 0x6c, 0x82, 0xca, 0x4c, 0xbe, 0xbd, 0x22, 0x67, 0x1a, 0x9c, 0x5d, 0xc3, 0xf3, 0x88, 0x0d, 0x23, 0x1e, 0xcc, 0xcb, 0xe0, 0x2b, 0x50, 0x0c, 0xd4, 0x89, 0x7e, 0x97, 0xb6, 0xf9, 0xe7, 0x8c, 0xa0, 0xbc, 0xb8, 0xcd, 0xe8, 0x3f, 0x83, 0x55, 0x8d, 0x9c, 0x33, 0x70, 0xa9, 0x51, 0x75, 0x53, 0x72, 0xe2, 0xce, 0x71, 0xb5, 0xf2, 0xf1, 0xdc, 0xda, 0xa5, 0x60, 0xb6, 0xec, 0xac, 0x4f, 0x67, 0x4e, 0x23, 0x3a, 0x10, 0xd3, 0x79, 0xec, 0xc3, 0xda, 0x4c, 0xd5, 0xf8, 0xb8, 0x07, 0xc5, 0x50, 0x55, 0x8c, 0x7a, 0x25, 0x55, 0x5d, 0x37, 0x1a, 0x51, 0xd3, 0xd4, 0xf8, 0x5a, 0x84, 0x82, 0xa2, 0xc5, 0xef, 0x11, 0xe4, 0xe3, 0x4c, 0xe1, 0x5a, 0x2a, 0xc3, 0x7c, 0x16, 0xad, 0xcd, 0x2c, 0x50, 0x6d, 0xd4, 0x21, 0xef, 0xbe, 0xff, 0xfe, 0xf4, 0x5f, 0x0d, 0x6f, 0x90, 0xb4, 0xe4, 0xff, 0xad, 0xc4, 0x79, 0xc4, 0x1f, 0x11, 0x14, 0x54, 0xec, 0xf0, 0x12, 0x99, 0x64, 0x60, 0xad, 0xad, 0x4c, 0x58, 0xe3, 0xe9, 0x8e, 0xf2, 0xb4, 0x89, 0xab, 0x19, 0x3c, 0xa9, 0xcc, 0xe2, 0x2f, 0x08, 0x56, 0x66, 0x13, 0x89, 0x9b, 0xff, 0x56, 0x5c, 0x98, 0x6e, 0x6b, 0xe7, 0x7c, 0x4d, 0x17, 0xf0, 0xab, 0xd6, 0x00, 0x7f, 0x43, 0x50, 0x9a, 0x8b, 0x1d, 0x5e, 0xa2, 0xbd, 0x78, 0x51, 0xac, 0xdd, 0x73, 0x76, 0x19, 0xcb, 0x77, 0x95, 0xe5, 0x1d, 0xdc, 0xc8, 0x60, 0x59, 0x2f, 0x02, 0x79, 0xa3, 0x9f, 0x6f, 0xf1, 0x67, 0x04, 0x45, 0x9d, 0x5a, 0xbc, 0xec, 0xb3, 0x26, 0x57, 0xc5, 0xba, 0x9d, 0x0d, 0x6c, 0x1c, 0xd6, 0x95, 0xc3, 0x2d, 0x5c, 0xcb, 0x12, 0x02, 0xbd, 0x43, 0x0f, 0x8f, 0xc7, 0x36, 0x3a, 0x19, 0xdb, 0xe8, 0xd7, 0xd8, 0x46, 0x1f, 0x26, 0x76, 0xee, 0x64, 0x62, 0xe7, 0x7e, 0x4c, 0xec, 0xdc, 0x41, 0x33, 0x79, 0x05, 0xc6, 0x74, 0x1e, 0x0f, 0xfc, 0x88, 0x09, 0x41, 0x7c, 0xbe, 0xad, 0xf9, 0x5f, 0x27, 0x3f, 0x52, 0x7c, 0x27, 0x76, 0x8a, 0xea, 0xb6, 0x6f, 0xfe, 0x09, 0x00, 0x00, 0xff, 0xff, 0xca, 0x34, 0x64, 0x66, 0x86, 0x06, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. var ( _ context.Context _ grpc.ClientConn ) // This is a compile-time assertion to ensure that this generated file // is compatible with the grpc package it is being compiled against. const _ = grpc.SupportPackageIsVersion4 // QueryClient is the client API for Query service. // // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. type QueryClient interface { Load(ctx context.Context, in *QueryLoadRequest, opts ...grpc.CallOption) (*QueryLoadResponse, error) Price(ctx context.Context, in *QueryPriceRequest, opts ...grpc.CallOption) (*QueryPriceResponse, error) TotalBandwidth(ctx context.Context, in *QueryTotalBandwidthRequest, opts ...grpc.CallOption) (*QueryTotalBandwidthResponse, error) NeuronBandwidth(ctx context.Context, in *QueryNeuronBandwidthRequest, opts ...grpc.CallOption) (*QueryNeuronBandwidthResponse, error) Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) } type queryClient struct { cc grpc1.ClientConn } func NewQueryClient(cc grpc1.ClientConn) QueryClient { return &queryClient{cc} } func (c *queryClient) Load(ctx context.Context, in *QueryLoadRequest, opts ...grpc.CallOption) (*QueryLoadResponse, error) { out := new(QueryLoadResponse) err := c.cc.Invoke(ctx, "/cyber.bandwidth.v1beta1.Query/Load", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) Price(ctx context.Context, in *QueryPriceRequest, opts ...grpc.CallOption) (*QueryPriceResponse, error) { out := new(QueryPriceResponse) err := c.cc.Invoke(ctx, "/cyber.bandwidth.v1beta1.Query/Price", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) TotalBandwidth(ctx context.Context, in *QueryTotalBandwidthRequest, opts ...grpc.CallOption) (*QueryTotalBandwidthResponse, error) { out := new(QueryTotalBandwidthResponse) err := c.cc.Invoke(ctx, "/cyber.bandwidth.v1beta1.Query/TotalBandwidth", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) NeuronBandwidth(ctx context.Context, in *QueryNeuronBandwidthRequest, opts ...grpc.CallOption) (*QueryNeuronBandwidthResponse, error) { out := new(QueryNeuronBandwidthResponse) err := c.cc.Invoke(ctx, "/cyber.bandwidth.v1beta1.Query/NeuronBandwidth", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) { out := new(QueryParamsResponse) err := c.cc.Invoke(ctx, "/cyber.bandwidth.v1beta1.Query/Params", in, out, opts...) if err != nil { return nil, err } return out, nil } // QueryServer is the server API for Query service. type QueryServer interface { Load(context.Context, *QueryLoadRequest) (*QueryLoadResponse, error) Price(context.Context, *QueryPriceRequest) (*QueryPriceResponse, error) TotalBandwidth(context.Context, *QueryTotalBandwidthRequest) (*QueryTotalBandwidthResponse, error) NeuronBandwidth(context.Context, *QueryNeuronBandwidthRequest) (*QueryNeuronBandwidthResponse, error) Params(context.Context, *QueryParamsRequest) (*QueryParamsResponse, error) } // UnimplementedQueryServer can be embedded to have forward compatible implementations. type UnimplementedQueryServer struct{} func (*UnimplementedQueryServer) Load(ctx context.Context, req *QueryLoadRequest) (*QueryLoadResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method Load not implemented") } func (*UnimplementedQueryServer) Price(ctx context.Context, req *QueryPriceRequest) (*QueryPriceResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method Price not implemented") } func (*UnimplementedQueryServer) TotalBandwidth(ctx context.Context, req *QueryTotalBandwidthRequest) (*QueryTotalBandwidthResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method TotalBandwidth not implemented") } func (*UnimplementedQueryServer) NeuronBandwidth(ctx context.Context, req *QueryNeuronBandwidthRequest) (*QueryNeuronBandwidthResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method NeuronBandwidth not implemented") } func (*UnimplementedQueryServer) Params(ctx context.Context, req *QueryParamsRequest) (*QueryParamsResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method Params not implemented") } func RegisterQueryServer(s grpc1.Server, srv QueryServer) { s.RegisterService(&_Query_serviceDesc, srv) } func _Query_Load_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryLoadRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).Load(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.bandwidth.v1beta1.Query/Load", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Load(ctx, req.(*QueryLoadRequest)) } return interceptor(ctx, in, info, handler) } func _Query_Price_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryPriceRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).Price(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.bandwidth.v1beta1.Query/Price", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Price(ctx, req.(*QueryPriceRequest)) } return interceptor(ctx, in, info, handler) } func _Query_TotalBandwidth_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryTotalBandwidthRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).TotalBandwidth(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.bandwidth.v1beta1.Query/TotalBandwidth", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).TotalBandwidth(ctx, req.(*QueryTotalBandwidthRequest)) } return interceptor(ctx, in, info, handler) } func _Query_NeuronBandwidth_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryNeuronBandwidthRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).NeuronBandwidth(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.bandwidth.v1beta1.Query/NeuronBandwidth", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).NeuronBandwidth(ctx, req.(*QueryNeuronBandwidthRequest)) } return interceptor(ctx, in, info, handler) } func _Query_Params_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryParamsRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).Params(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.bandwidth.v1beta1.Query/Params", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Params(ctx, req.(*QueryParamsRequest)) } return interceptor(ctx, in, info, handler) } var _Query_serviceDesc = grpc.ServiceDesc{ ServiceName: "cyber.bandwidth.v1beta1.Query", HandlerType: (*QueryServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "Load", Handler: _Query_Load_Handler, }, { MethodName: "Price", Handler: _Query_Price_Handler, }, { MethodName: "TotalBandwidth", Handler: _Query_TotalBandwidth_Handler, }, { MethodName: "NeuronBandwidth", Handler: _Query_NeuronBandwidth_Handler, }, { MethodName: "Params", Handler: _Query_Params_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "cyber/bandwidth/v1beta1/query.proto", } func (m *QueryLoadRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryLoadRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryLoadRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *QueryLoadResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryLoadResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryLoadResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size := m.Load.Size() i -= size if _, err := m.Load.MarshalTo(dAtA[i:]); err != nil { return 0, err } i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa return len(dAtA) - i, nil } func (m *QueryPriceRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryPriceRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryPriceRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *QueryPriceResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryPriceResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryPriceResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size := m.Price.Size() i -= size if _, err := m.Price.MarshalTo(dAtA[i:]); err != nil { return 0, err } i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa return len(dAtA) - i, nil } func (m *QueryTotalBandwidthRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryTotalBandwidthRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryTotalBandwidthRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *QueryTotalBandwidthResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryTotalBandwidthResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryTotalBandwidthResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.TotalBandwidth != 0 { i = encodeVarintQuery(dAtA, i, uint64(m.TotalBandwidth)) i-- dAtA[i] = 0x8 } return len(dAtA) - i, nil } func (m *QueryNeuronBandwidthRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryNeuronBandwidthRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryNeuronBandwidthRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.Neuron) > 0 { i -= len(m.Neuron) copy(dAtA[i:], m.Neuron) i = encodeVarintQuery(dAtA, i, uint64(len(m.Neuron))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *QueryNeuronBandwidthResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryNeuronBandwidthResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryNeuronBandwidthResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.NeuronBandwidth.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa return len(dAtA) - i, nil } func (m *QueryParamsRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryParamsRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryParamsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *QueryParamsResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryParamsResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryParamsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.Params.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa return len(dAtA) - i, nil } func encodeVarintQuery(dAtA []byte, offset int, v uint64) int { offset -= sovQuery(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *QueryLoadRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *QueryLoadResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l l = m.Load.Size() n += 1 + l + sovQuery(uint64(l)) return n } func (m *QueryPriceRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *QueryPriceResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l l = m.Price.Size() n += 1 + l + sovQuery(uint64(l)) return n } func (m *QueryTotalBandwidthRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *QueryTotalBandwidthResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.TotalBandwidth != 0 { n += 1 + sovQuery(uint64(m.TotalBandwidth)) } return n } func (m *QueryNeuronBandwidthRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Neuron) if l > 0 { n += 1 + l + sovQuery(uint64(l)) } return n } func (m *QueryNeuronBandwidthResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l l = m.NeuronBandwidth.Size() n += 1 + l + sovQuery(uint64(l)) return n } func (m *QueryParamsRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *QueryParamsResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l l = m.Params.Size() n += 1 + l + sovQuery(uint64(l)) return n } func sovQuery(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozQuery(x uint64) (n int) { return sovQuery(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *QueryLoadRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryLoadRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryLoadRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryLoadResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryLoadResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryLoadResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Load", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Load.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryPriceRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryPriceRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryPriceRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryPriceResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryPriceResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryPriceResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Price", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Price.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryTotalBandwidthRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryTotalBandwidthRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryTotalBandwidthRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryTotalBandwidthResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryTotalBandwidthResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryTotalBandwidthResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field TotalBandwidth", wireType) } m.TotalBandwidth = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.TotalBandwidth |= uint64(b&0x7F) << shift if b < 0x80 { break } } default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryNeuronBandwidthRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryNeuronBandwidthRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryNeuronBandwidthRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Neuron", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } m.Neuron = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryNeuronBandwidthResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryNeuronBandwidthResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryNeuronBandwidthResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field NeuronBandwidth", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.NeuronBandwidth.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryParamsRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryParamsRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryParamsRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryParamsResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryParamsResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryParamsResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Params.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipQuery(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowQuery } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowQuery } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowQuery } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthQuery } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupQuery } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthQuery } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthQuery = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowQuery = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupQuery = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/bandwidth/types/query.pb.gw.go ================================================ // Code generated by protoc-gen-grpc-gateway. DO NOT EDIT. // source: cyber/bandwidth/v1beta1/query.proto /* Package types is a reverse proxy. It translates gRPC into RESTful JSON APIs. */ package types import ( "context" "io" "net/http" "github.com/golang/protobuf/descriptor" "github.com/golang/protobuf/proto" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/grpc-ecosystem/grpc-gateway/utilities" "google.golang.org/grpc" "google.golang.org/grpc/codes" "google.golang.org/grpc/grpclog" "google.golang.org/grpc/metadata" "google.golang.org/grpc/status" ) // Suppress "imported and not used" errors var ( _ codes.Code _ io.Reader _ status.Status _ = runtime.String _ = utilities.NewDoubleArray _ = descriptor.ForMessage _ = metadata.Join ) func request_Query_Load_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryLoadRequest var metadata runtime.ServerMetadata msg, err := client.Load(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_Load_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryLoadRequest var metadata runtime.ServerMetadata msg, err := server.Load(ctx, &protoReq) return msg, metadata, err } func request_Query_Price_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryPriceRequest var metadata runtime.ServerMetadata msg, err := client.Price(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_Price_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryPriceRequest var metadata runtime.ServerMetadata msg, err := server.Price(ctx, &protoReq) return msg, metadata, err } func request_Query_TotalBandwidth_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryTotalBandwidthRequest var metadata runtime.ServerMetadata msg, err := client.TotalBandwidth(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_TotalBandwidth_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryTotalBandwidthRequest var metadata runtime.ServerMetadata msg, err := server.TotalBandwidth(ctx, &protoReq) return msg, metadata, err } func request_Query_NeuronBandwidth_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryNeuronBandwidthRequest var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["neuron"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "neuron") } protoReq.Neuron, err = runtime.String(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "neuron", err) } msg, err := client.NeuronBandwidth(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_NeuronBandwidth_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryNeuronBandwidthRequest var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["neuron"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "neuron") } protoReq.Neuron, err = runtime.String(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "neuron", err) } msg, err := server.NeuronBandwidth(ctx, &protoReq) return msg, metadata, err } func request_Query_Params_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryParamsRequest var metadata runtime.ServerMetadata msg, err := client.Params(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_Params_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryParamsRequest var metadata runtime.ServerMetadata msg, err := server.Params(ctx, &protoReq) return msg, metadata, err } // RegisterQueryHandlerServer registers the http handlers for service Query to "mux". // UnaryRPC :call QueryServer directly. // StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. // Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterQueryHandlerFromEndpoint instead. func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, server QueryServer) error { mux.Handle("GET", pattern_Query_Load_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_Load_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Load_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_Price_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_Price_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Price_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_TotalBandwidth_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_TotalBandwidth_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_TotalBandwidth_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_NeuronBandwidth_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_NeuronBandwidth_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_NeuronBandwidth_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_Params_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_Params_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Params_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) return nil } // RegisterQueryHandlerFromEndpoint is same as RegisterQueryHandler but // automatically dials to "endpoint" and closes the connection when "ctx" gets done. func RegisterQueryHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error) { conn, err := grpc.Dial(endpoint, opts...) if err != nil { return err } defer func() { if err != nil { if cerr := conn.Close(); cerr != nil { grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr) } return } go func() { <-ctx.Done() if cerr := conn.Close(); cerr != nil { grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr) } }() }() return RegisterQueryHandler(ctx, mux, conn) } // RegisterQueryHandler registers the http handlers for service Query to "mux". // The handlers forward requests to the grpc endpoint over "conn". func RegisterQueryHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error { return RegisterQueryHandlerClient(ctx, mux, NewQueryClient(conn)) } // RegisterQueryHandlerClient registers the http handlers for service Query // to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "QueryClient". // Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "QueryClient" // doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in // "QueryClient" to call the correct interceptors. func RegisterQueryHandlerClient(ctx context.Context, mux *runtime.ServeMux, client QueryClient) error { mux.Handle("GET", pattern_Query_Load_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_Load_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Load_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_Price_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_Price_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Price_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_TotalBandwidth_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_TotalBandwidth_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_TotalBandwidth_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_NeuronBandwidth_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_NeuronBandwidth_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_NeuronBandwidth_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_Params_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_Params_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Params_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) return nil } var ( pattern_Query_Load_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 1, 2, 3}, []string{"cyber", "bandwidth", "v1beta1", "load"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_Price_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 1, 2, 3}, []string{"cyber", "bandwidth", "v1beta1", "price"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_TotalBandwidth_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 1, 2, 3}, []string{"cyber", "bandwidth", "v1beta1", "total"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_NeuronBandwidth_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 1, 2, 3, 1, 0, 4, 1, 5, 3}, []string{"cyber", "bandwidth", "v1beta1", "neuron"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_Params_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 1, 2, 3}, []string{"cyber", "bandwidth", "v1beta1", "params"}, "", runtime.AssumeColonVerbOpt(false))) ) var ( forward_Query_Load_0 = runtime.ForwardResponseMessage forward_Query_Price_0 = runtime.ForwardResponseMessage forward_Query_TotalBandwidth_0 = runtime.ForwardResponseMessage forward_Query_NeuronBandwidth_0 = runtime.ForwardResponseMessage forward_Query_Params_0 = runtime.ForwardResponseMessage ) ================================================ FILE: x/bandwidth/types/tx.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: cyber/bandwidth/v1beta1/tx.proto package types import ( context "context" fmt "fmt" io "io" math "math" math_bits "math/bits" _ "github.com/cosmos/cosmos-proto" _ "github.com/cosmos/cosmos-sdk/types/msgservice" _ "github.com/cosmos/gogoproto/gogoproto" grpc1 "github.com/cosmos/gogoproto/grpc" proto "github.com/cosmos/gogoproto/proto" grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" ) // Reference imports to suppress errors if they are not otherwise used. var ( _ = proto.Marshal _ = fmt.Errorf _ = math.Inf ) // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package type MsgUpdateParams struct { Authority string `protobuf:"bytes,1,opt,name=authority,proto3" json:"authority,omitempty"` Params Params `protobuf:"bytes,2,opt,name=params,proto3" json:"params"` } func (m *MsgUpdateParams) Reset() { *m = MsgUpdateParams{} } func (m *MsgUpdateParams) String() string { return proto.CompactTextString(m) } func (*MsgUpdateParams) ProtoMessage() {} func (*MsgUpdateParams) Descriptor() ([]byte, []int) { return fileDescriptor_b2467dc10018517b, []int{0} } func (m *MsgUpdateParams) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgUpdateParams) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgUpdateParams.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgUpdateParams) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgUpdateParams.Merge(m, src) } func (m *MsgUpdateParams) XXX_Size() int { return m.Size() } func (m *MsgUpdateParams) XXX_DiscardUnknown() { xxx_messageInfo_MsgUpdateParams.DiscardUnknown(m) } var xxx_messageInfo_MsgUpdateParams proto.InternalMessageInfo func (m *MsgUpdateParams) GetAuthority() string { if m != nil { return m.Authority } return "" } func (m *MsgUpdateParams) GetParams() Params { if m != nil { return m.Params } return Params{} } type MsgUpdateParamsResponse struct{} func (m *MsgUpdateParamsResponse) Reset() { *m = MsgUpdateParamsResponse{} } func (m *MsgUpdateParamsResponse) String() string { return proto.CompactTextString(m) } func (*MsgUpdateParamsResponse) ProtoMessage() {} func (*MsgUpdateParamsResponse) Descriptor() ([]byte, []int) { return fileDescriptor_b2467dc10018517b, []int{1} } func (m *MsgUpdateParamsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgUpdateParamsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgUpdateParamsResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgUpdateParamsResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgUpdateParamsResponse.Merge(m, src) } func (m *MsgUpdateParamsResponse) XXX_Size() int { return m.Size() } func (m *MsgUpdateParamsResponse) XXX_DiscardUnknown() { xxx_messageInfo_MsgUpdateParamsResponse.DiscardUnknown(m) } var xxx_messageInfo_MsgUpdateParamsResponse proto.InternalMessageInfo func init() { proto.RegisterType((*MsgUpdateParams)(nil), "cyber.bandwidth.v1beta1.MsgUpdateParams") proto.RegisterType((*MsgUpdateParamsResponse)(nil), "cyber.bandwidth.v1beta1.MsgUpdateParamsResponse") } func init() { proto.RegisterFile("cyber/bandwidth/v1beta1/tx.proto", fileDescriptor_b2467dc10018517b) } var fileDescriptor_b2467dc10018517b = []byte{ // 327 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x48, 0xae, 0x4c, 0x4a, 0x2d, 0xd2, 0x4f, 0x4a, 0xcc, 0x4b, 0x29, 0xcf, 0x4c, 0x29, 0xc9, 0xd0, 0x2f, 0x33, 0x4c, 0x4a, 0x2d, 0x49, 0x34, 0xd4, 0x2f, 0xa9, 0xd0, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x07, 0xab, 0xd0, 0x83, 0xab, 0xd0, 0x83, 0xaa, 0x90, 0x12, 0x49, 0xcf, 0x4f, 0xcf, 0x07, 0xab, 0xd1, 0x07, 0xb1, 0x20, 0xca, 0xa5, 0xc4, 0x93, 0xf3, 0x8b, 0x73, 0xf3, 0x8b, 0xf5, 0x73, 0x8b, 0xd3, 0xf5, 0xcb, 0x0c, 0x41, 0x14, 0x54, 0x42, 0x12, 0x22, 0x11, 0x0f, 0xd1, 0x01, 0xe1, 0x40, 0xa5, 0x94, 0x71, 0x3a, 0xa2, 0xb2, 0x20, 0x15, 0xaa, 0x48, 0x69, 0x06, 0x23, 0x17, 0xbf, 0x6f, 0x71, 0x7a, 0x68, 0x41, 0x4a, 0x62, 0x49, 0x6a, 0x40, 0x62, 0x51, 0x62, 0x6e, 0xb1, 0x90, 0x19, 0x17, 0x67, 0x62, 0x69, 0x49, 0x46, 0x7e, 0x51, 0x66, 0x49, 0xa5, 0x04, 0xa3, 0x02, 0xa3, 0x06, 0xa7, 0x93, 0xc4, 0xa5, 0x2d, 0xba, 0x22, 0x50, 0xd3, 0x1d, 0x53, 0x52, 0x8a, 0x52, 0x8b, 0x8b, 0x83, 0x4b, 0x8a, 0x32, 0xf3, 0xd2, 0x83, 0x10, 0x4a, 0x85, 0x6c, 0xb9, 0xd8, 0x0a, 0xc0, 0x26, 0x48, 0x30, 0x29, 0x30, 0x6a, 0x70, 0x1b, 0xc9, 0xeb, 0xe1, 0xf0, 0xa4, 0x1e, 0xc4, 0x22, 0x27, 0x96, 0x13, 0xf7, 0xe4, 0x19, 0x82, 0xa0, 0x9a, 0xac, 0xf8, 0x9a, 0x9e, 0x6f, 0xd0, 0x42, 0x18, 0xa7, 0x24, 0xc9, 0x25, 0x8e, 0xe6, 0xb2, 0xa0, 0xd4, 0xe2, 0x82, 0xfc, 0xbc, 0xe2, 0x54, 0xa3, 0x42, 0x2e, 0x66, 0xdf, 0xe2, 0x74, 0xa1, 0x2c, 0x2e, 0x1e, 0x14, 0x87, 0x6b, 0xe0, 0xb4, 0x10, 0xcd, 0x20, 0x29, 0x03, 0x62, 0x55, 0xc2, 0xac, 0x74, 0xf2, 0x3d, 0xf1, 0x48, 0x8e, 0xf1, 0xc2, 0x23, 0x39, 0xc6, 0x07, 0x8f, 0xe4, 0x18, 0x27, 0x3c, 0x96, 0x63, 0xb8, 0xf0, 0x58, 0x8e, 0xe1, 0xc6, 0x63, 0x39, 0x86, 0x28, 0xe3, 0xf4, 0xcc, 0x92, 0x8c, 0xd2, 0x24, 0xbd, 0xe4, 0xfc, 0x5c, 0x7d, 0xb0, 0xa9, 0xc9, 0xf9, 0x79, 0xe9, 0xa0, 0x10, 0xd2, 0x4f, 0xcf, 0xd7, 0x85, 0xc4, 0x41, 0x05, 0x52, 0x2c, 0x80, 0x43, 0x3f, 0x89, 0x0d, 0x1c, 0xfc, 0xc6, 0x80, 0x00, 0x00, 0x00, 0xff, 0xff, 0xe5, 0xc3, 0xa3, 0xaa, 0x2a, 0x02, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. var ( _ context.Context _ grpc.ClientConn ) // This is a compile-time assertion to ensure that this generated file // is compatible with the grpc package it is being compiled against. const _ = grpc.SupportPackageIsVersion4 // MsgClient is the client API for Msg service. // // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. type MsgClient interface { UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) } type msgClient struct { cc grpc1.ClientConn } func NewMsgClient(cc grpc1.ClientConn) MsgClient { return &msgClient{cc} } func (c *msgClient) UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) { out := new(MsgUpdateParamsResponse) err := c.cc.Invoke(ctx, "/cyber.bandwidth.v1beta1.Msg/UpdateParams", in, out, opts...) if err != nil { return nil, err } return out, nil } // MsgServer is the server API for Msg service. type MsgServer interface { UpdateParams(context.Context, *MsgUpdateParams) (*MsgUpdateParamsResponse, error) } // UnimplementedMsgServer can be embedded to have forward compatible implementations. type UnimplementedMsgServer struct{} func (*UnimplementedMsgServer) UpdateParams(ctx context.Context, req *MsgUpdateParams) (*MsgUpdateParamsResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method UpdateParams not implemented") } func RegisterMsgServer(s grpc1.Server, srv MsgServer) { s.RegisterService(&_Msg_serviceDesc, srv) } func _Msg_UpdateParams_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgUpdateParams) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(MsgServer).UpdateParams(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.bandwidth.v1beta1.Msg/UpdateParams", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).UpdateParams(ctx, req.(*MsgUpdateParams)) } return interceptor(ctx, in, info, handler) } var _Msg_serviceDesc = grpc.ServiceDesc{ ServiceName: "cyber.bandwidth.v1beta1.Msg", HandlerType: (*MsgServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "UpdateParams", Handler: _Msg_UpdateParams_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "cyber/bandwidth/v1beta1/tx.proto", } func (m *MsgUpdateParams) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgUpdateParams) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgUpdateParams) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.Params.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintTx(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 if len(m.Authority) > 0 { i -= len(m.Authority) copy(dAtA[i:], m.Authority) i = encodeVarintTx(dAtA, i, uint64(len(m.Authority))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *MsgUpdateParamsResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgUpdateParamsResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgUpdateParamsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func encodeVarintTx(dAtA []byte, offset int, v uint64) int { offset -= sovTx(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *MsgUpdateParams) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Authority) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = m.Params.Size() n += 1 + l + sovTx(uint64(l)) return n } func (m *MsgUpdateParamsResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func sovTx(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozTx(x uint64) (n int) { return sovTx(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *MsgUpdateParams) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgUpdateParams: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgUpdateParams: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Authority", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Authority = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Params.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgUpdateParamsResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgUpdateParamsResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgUpdateParamsResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipTx(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTx } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTx } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTx } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthTx } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupTx } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthTx } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthTx = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowTx = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupTx = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/bandwidth/types/types.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: cyber/bandwidth/v1beta1/types.proto package types import ( fmt "fmt" io "io" math "math" math_bits "math/bits" github_com_cosmos_cosmos_sdk_types "github.com/cosmos/cosmos-sdk/types" _ "github.com/cosmos/gogoproto/gogoproto" proto "github.com/cosmos/gogoproto/proto" ) // Reference imports to suppress errors if they are not otherwise used. var ( _ = proto.Marshal _ = fmt.Errorf _ = math.Inf ) // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package type Params struct { RecoveryPeriod uint64 `protobuf:"varint,1,opt,name=recovery_period,json=recoveryPeriod,proto3" json:"recovery_period,omitempty"` AdjustPricePeriod uint64 `protobuf:"varint,2,opt,name=adjust_price_period,json=adjustPricePeriod,proto3" json:"adjust_price_period,omitempty"` BasePrice github_com_cosmos_cosmos_sdk_types.Dec `protobuf:"bytes,3,opt,name=base_price,json=basePrice,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Dec" json:"base_price"` BaseLoad github_com_cosmos_cosmos_sdk_types.Dec `protobuf:"bytes,4,opt,name=base_load,json=baseLoad,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Dec" json:"base_load"` MaxBlockBandwidth uint64 `protobuf:"varint,5,opt,name=max_block_bandwidth,json=maxBlockBandwidth,proto3" json:"max_block_bandwidth,omitempty"` } func (m *Params) Reset() { *m = Params{} } func (m *Params) String() string { return proto.CompactTextString(m) } func (*Params) ProtoMessage() {} func (*Params) Descriptor() ([]byte, []int) { return fileDescriptor_b76904de4f1717b1, []int{0} } func (m *Params) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *Params) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_Params.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *Params) XXX_Merge(src proto.Message) { xxx_messageInfo_Params.Merge(m, src) } func (m *Params) XXX_Size() int { return m.Size() } func (m *Params) XXX_DiscardUnknown() { xxx_messageInfo_Params.DiscardUnknown(m) } var xxx_messageInfo_Params proto.InternalMessageInfo func (m *Params) GetRecoveryPeriod() uint64 { if m != nil { return m.RecoveryPeriod } return 0 } func (m *Params) GetAdjustPricePeriod() uint64 { if m != nil { return m.AdjustPricePeriod } return 0 } func (m *Params) GetMaxBlockBandwidth() uint64 { if m != nil { return m.MaxBlockBandwidth } return 0 } type NeuronBandwidth struct { Neuron string `protobuf:"bytes,1,opt,name=neuron,proto3" json:"neuron,omitempty"` RemainedValue uint64 `protobuf:"varint,2,opt,name=remained_value,json=remainedValue,proto3" json:"remained_value,omitempty"` LastUpdatedBlock uint64 `protobuf:"varint,3,opt,name=last_updated_block,json=lastUpdatedBlock,proto3" json:"last_updated_block,omitempty"` MaxValue uint64 `protobuf:"varint,4,opt,name=max_value,json=maxValue,proto3" json:"max_value,omitempty"` } func (m *NeuronBandwidth) Reset() { *m = NeuronBandwidth{} } func (m *NeuronBandwidth) String() string { return proto.CompactTextString(m) } func (*NeuronBandwidth) ProtoMessage() {} func (*NeuronBandwidth) Descriptor() ([]byte, []int) { return fileDescriptor_b76904de4f1717b1, []int{1} } func (m *NeuronBandwidth) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *NeuronBandwidth) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_NeuronBandwidth.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *NeuronBandwidth) XXX_Merge(src proto.Message) { xxx_messageInfo_NeuronBandwidth.Merge(m, src) } func (m *NeuronBandwidth) XXX_Size() int { return m.Size() } func (m *NeuronBandwidth) XXX_DiscardUnknown() { xxx_messageInfo_NeuronBandwidth.DiscardUnknown(m) } var xxx_messageInfo_NeuronBandwidth proto.InternalMessageInfo type Price struct { Price github_com_cosmos_cosmos_sdk_types.Dec `protobuf:"bytes,1,opt,name=price,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Dec" json:"price"` } func (m *Price) Reset() { *m = Price{} } func (m *Price) String() string { return proto.CompactTextString(m) } func (*Price) ProtoMessage() {} func (*Price) Descriptor() ([]byte, []int) { return fileDescriptor_b76904de4f1717b1, []int{2} } func (m *Price) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *Price) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_Price.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *Price) XXX_Merge(src proto.Message) { xxx_messageInfo_Price.Merge(m, src) } func (m *Price) XXX_Size() int { return m.Size() } func (m *Price) XXX_DiscardUnknown() { xxx_messageInfo_Price.DiscardUnknown(m) } var xxx_messageInfo_Price proto.InternalMessageInfo func init() { proto.RegisterType((*Params)(nil), "cyber.bandwidth.v1beta1.Params") proto.RegisterType((*NeuronBandwidth)(nil), "cyber.bandwidth.v1beta1.NeuronBandwidth") proto.RegisterType((*Price)(nil), "cyber.bandwidth.v1beta1.Price") } func init() { proto.RegisterFile("cyber/bandwidth/v1beta1/types.proto", fileDescriptor_b76904de4f1717b1) } var fileDescriptor_b76904de4f1717b1 = []byte{ // 443 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x92, 0xb1, 0x6e, 0xd4, 0x30, 0x1c, 0xc6, 0xe3, 0x92, 0x3b, 0xdd, 0x59, 0xa2, 0x05, 0x83, 0x20, 0x02, 0x29, 0xa9, 0x0e, 0x01, 0x1d, 0x68, 0xa2, 0xaa, 0x5b, 0xc7, 0xa8, 0x1b, 0x14, 0x9d, 0x22, 0x01, 0x12, 0x4b, 0xe4, 0xd8, 0x56, 0x1a, 0x9a, 0xc4, 0x91, 0xed, 0x1c, 0xb9, 0x37, 0x60, 0xe4, 0x11, 0x6e, 0xe1, 0x09, 0x78, 0x89, 0x8e, 0x1d, 0x11, 0x43, 0x85, 0xee, 0x96, 0x3e, 0x06, 0xb2, 0x9d, 0x5c, 0x3b, 0x77, 0x4a, 0xfc, 0x7d, 0xbf, 0x7c, 0xf1, 0xff, 0xd3, 0x1f, 0xbe, 0x22, 0xcb, 0x8c, 0x89, 0x28, 0xc3, 0x35, 0xfd, 0x5e, 0x50, 0x75, 0x1e, 0x2d, 0x8e, 0x32, 0xa6, 0xf0, 0x51, 0xa4, 0x96, 0x0d, 0x93, 0x61, 0x23, 0xb8, 0xe2, 0xe8, 0xb9, 0x81, 0xc2, 0x2d, 0x14, 0xf6, 0xd0, 0x8b, 0xa7, 0x39, 0xcf, 0xb9, 0x61, 0x22, 0xfd, 0x66, 0xf1, 0xd9, 0xef, 0x1d, 0x38, 0x9e, 0x63, 0x81, 0x2b, 0x89, 0xde, 0xc2, 0x3d, 0xc1, 0x08, 0x5f, 0x30, 0xb1, 0x4c, 0x1b, 0x26, 0x0a, 0x4e, 0x3d, 0xb0, 0x0f, 0x0e, 0xdc, 0x64, 0x77, 0x90, 0xe7, 0x46, 0x45, 0x21, 0x7c, 0x82, 0xe9, 0xb7, 0x56, 0xaa, 0xb4, 0x11, 0x05, 0x61, 0x03, 0xbc, 0x63, 0xe0, 0xc7, 0xd6, 0x9a, 0x6b, 0xa7, 0xe7, 0xcf, 0x20, 0xcc, 0xb0, 0x64, 0x96, 0xf6, 0x1e, 0xec, 0x83, 0x83, 0x69, 0x1c, 0x5e, 0x5e, 0x07, 0xce, 0xdf, 0xeb, 0xe0, 0x4d, 0x5e, 0xa8, 0xf3, 0x36, 0x0b, 0x09, 0xaf, 0x22, 0xc2, 0x65, 0xc5, 0x65, 0xff, 0x38, 0x94, 0xf4, 0xa2, 0x1f, 0xec, 0x94, 0x91, 0x64, 0xaa, 0x13, 0x4c, 0x28, 0x7a, 0x0f, 0xcd, 0x21, 0x2d, 0x39, 0xa6, 0x9e, 0x7b, 0xaf, 0xb4, 0x89, 0x0e, 0xf8, 0xc0, 0xb1, 0x99, 0xa5, 0xc2, 0x5d, 0x9a, 0x95, 0x9c, 0x5c, 0xa4, 0xdb, 0xd2, 0xbc, 0x91, 0x9d, 0xa5, 0xc2, 0x5d, 0xac, 0x9d, 0x78, 0x30, 0x4e, 0xdc, 0x9b, 0x55, 0x00, 0x66, 0xbf, 0x00, 0xdc, 0xfb, 0xc8, 0x5a, 0xc1, 0xeb, 0xad, 0x83, 0x9e, 0xc1, 0x71, 0x6d, 0x24, 0xd3, 0xda, 0x34, 0xe9, 0x4f, 0xe8, 0x35, 0xdc, 0x15, 0xac, 0xc2, 0x45, 0xcd, 0x68, 0xba, 0xc0, 0x65, 0xcb, 0xfa, 0xa2, 0x1e, 0x0e, 0xea, 0x67, 0x2d, 0xa2, 0x77, 0x10, 0x95, 0x58, 0xaa, 0xb4, 0x6d, 0x28, 0x56, 0x8c, 0xda, 0x1b, 0x99, 0xb2, 0xdc, 0xe4, 0x91, 0x76, 0x3e, 0x59, 0xc3, 0xdc, 0x07, 0xbd, 0x84, 0x53, 0x7d, 0x6d, 0x9b, 0xe7, 0x1a, 0x68, 0x52, 0xe1, 0xce, 0x44, 0x9d, 0x4c, 0x7e, 0xac, 0x02, 0xe7, 0x66, 0x15, 0x38, 0xb3, 0x2f, 0x70, 0x64, 0x3b, 0x3b, 0x85, 0x23, 0xdb, 0x3e, 0xb8, 0x57, 0x5f, 0xf6, 0xe3, 0xdb, 0xe0, 0xf8, 0xec, 0x72, 0xed, 0x83, 0xab, 0xb5, 0x0f, 0xfe, 0xad, 0x7d, 0xf0, 0x73, 0xe3, 0x3b, 0x57, 0x1b, 0xdf, 0xf9, 0xb3, 0xf1, 0x9d, 0xaf, 0xc7, 0x77, 0x23, 0xf5, 0x2a, 0x12, 0x5e, 0xe7, 0x82, 0x49, 0x19, 0xe5, 0xfc, 0xd0, 0x2e, 0x70, 0x77, 0x67, 0x85, 0xcd, 0x3f, 0xb2, 0xb1, 0x59, 0xc6, 0xe3, 0xff, 0x01, 0x00, 0x00, 0xff, 0xff, 0x1d, 0x38, 0x0c, 0x71, 0xe2, 0x02, 0x00, 0x00, } func (this *Params) Equal(that interface{}) bool { if that == nil { return this == nil } that1, ok := that.(*Params) if !ok { that2, ok := that.(Params) if ok { that1 = &that2 } else { return false } } if that1 == nil { return this == nil } else if this == nil { return false } if this.RecoveryPeriod != that1.RecoveryPeriod { return false } if this.AdjustPricePeriod != that1.AdjustPricePeriod { return false } if !this.BasePrice.Equal(that1.BasePrice) { return false } if !this.BaseLoad.Equal(that1.BaseLoad) { return false } if this.MaxBlockBandwidth != that1.MaxBlockBandwidth { return false } return true } func (m *Params) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *Params) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *Params) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.MaxBlockBandwidth != 0 { i = encodeVarintTypes(dAtA, i, uint64(m.MaxBlockBandwidth)) i-- dAtA[i] = 0x28 } { size := m.BaseLoad.Size() i -= size if _, err := m.BaseLoad.MarshalTo(dAtA[i:]); err != nil { return 0, err } i = encodeVarintTypes(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x22 { size := m.BasePrice.Size() i -= size if _, err := m.BasePrice.MarshalTo(dAtA[i:]); err != nil { return 0, err } i = encodeVarintTypes(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x1a if m.AdjustPricePeriod != 0 { i = encodeVarintTypes(dAtA, i, uint64(m.AdjustPricePeriod)) i-- dAtA[i] = 0x10 } if m.RecoveryPeriod != 0 { i = encodeVarintTypes(dAtA, i, uint64(m.RecoveryPeriod)) i-- dAtA[i] = 0x8 } return len(dAtA) - i, nil } func (m *NeuronBandwidth) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *NeuronBandwidth) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *NeuronBandwidth) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.MaxValue != 0 { i = encodeVarintTypes(dAtA, i, uint64(m.MaxValue)) i-- dAtA[i] = 0x20 } if m.LastUpdatedBlock != 0 { i = encodeVarintTypes(dAtA, i, uint64(m.LastUpdatedBlock)) i-- dAtA[i] = 0x18 } if m.RemainedValue != 0 { i = encodeVarintTypes(dAtA, i, uint64(m.RemainedValue)) i-- dAtA[i] = 0x10 } if len(m.Neuron) > 0 { i -= len(m.Neuron) copy(dAtA[i:], m.Neuron) i = encodeVarintTypes(dAtA, i, uint64(len(m.Neuron))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *Price) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *Price) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *Price) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size := m.Price.Size() i -= size if _, err := m.Price.MarshalTo(dAtA[i:]); err != nil { return 0, err } i = encodeVarintTypes(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa return len(dAtA) - i, nil } func encodeVarintTypes(dAtA []byte, offset int, v uint64) int { offset -= sovTypes(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *Params) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.RecoveryPeriod != 0 { n += 1 + sovTypes(uint64(m.RecoveryPeriod)) } if m.AdjustPricePeriod != 0 { n += 1 + sovTypes(uint64(m.AdjustPricePeriod)) } l = m.BasePrice.Size() n += 1 + l + sovTypes(uint64(l)) l = m.BaseLoad.Size() n += 1 + l + sovTypes(uint64(l)) if m.MaxBlockBandwidth != 0 { n += 1 + sovTypes(uint64(m.MaxBlockBandwidth)) } return n } func (m *NeuronBandwidth) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Neuron) if l > 0 { n += 1 + l + sovTypes(uint64(l)) } if m.RemainedValue != 0 { n += 1 + sovTypes(uint64(m.RemainedValue)) } if m.LastUpdatedBlock != 0 { n += 1 + sovTypes(uint64(m.LastUpdatedBlock)) } if m.MaxValue != 0 { n += 1 + sovTypes(uint64(m.MaxValue)) } return n } func (m *Price) Size() (n int) { if m == nil { return 0 } var l int _ = l l = m.Price.Size() n += 1 + l + sovTypes(uint64(l)) return n } func sovTypes(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozTypes(x uint64) (n int) { return sovTypes(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *Params) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: Params: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: Params: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field RecoveryPeriod", wireType) } m.RecoveryPeriod = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.RecoveryPeriod |= uint64(b&0x7F) << shift if b < 0x80 { break } } case 2: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field AdjustPricePeriod", wireType) } m.AdjustPricePeriod = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.AdjustPricePeriod |= uint64(b&0x7F) << shift if b < 0x80 { break } } case 3: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field BasePrice", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTypes } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTypes } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.BasePrice.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 4: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field BaseLoad", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTypes } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTypes } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.BaseLoad.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 5: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field MaxBlockBandwidth", wireType) } m.MaxBlockBandwidth = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.MaxBlockBandwidth |= uint64(b&0x7F) << shift if b < 0x80 { break } } default: iNdEx = preIndex skippy, err := skipTypes(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTypes } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *NeuronBandwidth) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: NeuronBandwidth: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: NeuronBandwidth: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Neuron", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTypes } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTypes } if postIndex > l { return io.ErrUnexpectedEOF } m.Neuron = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field RemainedValue", wireType) } m.RemainedValue = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.RemainedValue |= uint64(b&0x7F) << shift if b < 0x80 { break } } case 3: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field LastUpdatedBlock", wireType) } m.LastUpdatedBlock = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.LastUpdatedBlock |= uint64(b&0x7F) << shift if b < 0x80 { break } } case 4: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field MaxValue", wireType) } m.MaxValue = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.MaxValue |= uint64(b&0x7F) << shift if b < 0x80 { break } } default: iNdEx = preIndex skippy, err := skipTypes(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTypes } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *Price) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: Price: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: Price: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Price", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTypes } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTypes } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Price.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTypes(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTypes } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipTypes(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTypes } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTypes } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTypes } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthTypes } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupTypes } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthTypes } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthTypes = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowTypes = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupTypes = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/bandwidth/wasm/interface.go ================================================ package wasm import ( "encoding/json" errorsmod "cosmossdk.io/errors" pluginstypes "github.com/cybercongress/go-cyber/v7/plugins/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/bandwidth/keeper" ) type Querier struct { *keeper.BandwidthMeter } func NewWasmQuerier(keeper *keeper.BandwidthMeter) *Querier { return &Querier{keeper} } func (querier *Querier) HandleQuery(ctx sdk.Context, query pluginstypes.CyberQuery) ([]byte, error) { switch { case query.BandwidthLoad != nil: res, err := querier.BandwidthMeter.Load(ctx, query.BandwidthLoad) if err != nil { return nil, errorsmod.Wrap(err, "failed to get bandwidth load") } responseBytes, err := json.Marshal(res) if err != nil { return nil, errorsmod.Wrap(err, "failed to serialize bandwidth load response") } return responseBytes, nil case query.BandwidthPrice != nil: res, err := querier.BandwidthMeter.Price(ctx, query.BandwidthPrice) if err != nil { return nil, errorsmod.Wrap(err, "failed to get bandwidth price") } responseBytes, err := json.Marshal(res) if err != nil { return nil, errorsmod.Wrap(err, "failed to serialize bandwidth price response") } return responseBytes, nil case query.TotalBandwidth != nil: res, err := querier.BandwidthMeter.TotalBandwidth(ctx, query.TotalBandwidth) if err != nil { return nil, errorsmod.Wrap(err, "failed to get total bandwidth") } responseBytes, err := json.Marshal(res) if err != nil { return nil, errorsmod.Wrap(err, "failed to serialize total bandwidth response") } return responseBytes, nil case query.NeuronBandwidth != nil: res, err := querier.BandwidthMeter.NeuronBandwidth(ctx, query.NeuronBandwidth) if err != nil { return nil, errorsmod.Wrap(err, "failed to get neuron bandwidth") } responseBytes, err := json.Marshal(res) if err != nil { return nil, errorsmod.Wrap(err, "failed to serialize neuron bandwidth response") } return responseBytes, nil default: return nil, pluginstypes.ErrHandleQuery } } ================================================ FILE: x/clock/README.md ================================================ # Clock This module allows smart contracts to execute logic at the end of every block without an external bot. [Clock Spec](./spec/README.md) ================================================ FILE: x/clock/abci.go ================================================ package clock import ( abci "github.com/cometbft/cometbft/abci/types" "github.com/cybercongress/go-cyber/v7/app/helpers" "time" "github.com/cometbft/cometbft/libs/log" "github.com/cosmos/cosmos-sdk/telemetry" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/clock/keeper" "github.com/cybercongress/go-cyber/v7/x/clock/types" ) var endBlockSudoMessage = []byte(types.EndBlockSudoMessage) var beginBlockSudoMessage = []byte(types.EndBlockSudoMessage) func BeginBlocker(ctx sdk.Context, k keeper.Keeper) { defer telemetry.ModuleMeasureSince(types.ModuleName, time.Now(), telemetry.MetricKeyBeginBlocker) CallContracts(ctx, k, beginBlockSudoMessage) } // EndBlocker executes on contracts at the end of the block. func EndBlocker(ctx sdk.Context, k keeper.Keeper) []abci.ValidatorUpdate { defer telemetry.ModuleMeasureSince(types.ModuleName, time.Now(), telemetry.MetricKeyEndBlocker) CallContracts(ctx, k, endBlockSudoMessage) return nil } func CallContracts(ctx sdk.Context, k keeper.Keeper, msg []byte) { logger := k.Logger(ctx) p := k.GetParams(ctx) // Get all contracts contracts, err := k.GetAllContracts(ctx) if err != nil { logger.Error("Failed to get contracts", "error", err) return } // Track errors errorExecs := make([]string, len(contracts)) errorExists := false // Execute all contracts that are not jailed for idx, contract := range contracts { // Skip jailed contracts if contract.IsJailed { continue } // Get sdk.AccAddress from contract address contractAddr := sdk.MustAccAddressFromBech32(contract.ContractAddress) if handleError(ctx, k, logger, errorExecs, &errorExists, err, idx, contract.ContractAddress, msg) { continue } // Create context with gas limit childCtx := ctx.WithGasMeter(sdk.NewGasMeter(p.ContractGasLimit)) // Execute contract helpers.ExecuteContract(k.GetContractKeeper(), childCtx, contractAddr, msg, &err) if handleError(ctx, k, logger, errorExecs, &errorExists, err, idx, contract.ContractAddress, msg) { continue } logger.Info( "abci callback to clock contract", "type", string(msg), "cause", err, "contract-address", contract.ContractAddress, ) } // Log errors if present if errorExists { logger.Error("Failed to execute contracts", "contracts", errorExecs) } } // Function to handle contract execution errors. Returns true if error is present, false otherwise. func handleError( ctx sdk.Context, k keeper.Keeper, logger log.Logger, errorExecs []string, errorExists *bool, err error, idx int, contractAddress string, msg []byte, ) bool { // Check if error is present if err != nil { // Flag error *errorExists = true errorExecs[idx] = contractAddress logger.Error( "abci callback to clock contract failed", "type", string(msg), "cause", err, "contract-address", contractAddress, ) // Attempt to jail contract, log error if present err := k.SetJailStatus(ctx, contractAddress, true) if err != nil { logger.Error("Failed to jail contract", "contract", contractAddress, "error", err) } } return err != nil } ================================================ FILE: x/clock/abci_test.go ================================================ package clock_test import ( "crypto/sha256" "encoding/json" "testing" "time" wasmtypes "github.com/CosmWasm/wasmd/x/wasm/types" "github.com/stretchr/testify/suite" _ "embed" tmproto "github.com/cometbft/cometbft/proto/tendermint/types" "github.com/cosmos/cosmos-sdk/testutil/testdata" sdk "github.com/cosmos/cosmos-sdk/types" minttypes "github.com/cosmos/cosmos-sdk/x/mint/types" "github.com/cybercongress/go-cyber/v7/app" clock "github.com/cybercongress/go-cyber/v7/x/clock" "github.com/cybercongress/go-cyber/v7/x/clock/types" ) type EndBlockerTestSuite struct { suite.Suite ctx sdk.Context app *app.App } func TestEndBlockerTestSuite(t *testing.T) { suite.Run(t, new(EndBlockerTestSuite)) } func (s *EndBlockerTestSuite) SetupTest() { app := app.Setup(s.T()) ctx := app.BaseApp.NewContext(false, tmproto.Header{ ChainID: "testing", Height: 10, Time: time.Now(), }) s.app = app s.ctx = ctx } //go:embed keeper/testdata/clock_example.wasm var clockContract []byte //go:embed keeper/testdata/cw_testburn.wasm var burnContract []byte func (s *EndBlockerTestSuite) StoreCode(wasmContract []byte) { _, _, sender := testdata.KeyTestPubAddr() msg := wasmtypes.MsgStoreCodeFixture(func(m *wasmtypes.MsgStoreCode) { m.WASMByteCode = wasmContract m.Sender = sender.String() }) rsp, err := s.app.MsgServiceRouter().Handler(msg)(s.ctx, msg) s.Require().NoError(err) var result wasmtypes.MsgStoreCodeResponse s.Require().NoError(s.app.AppCodec().Unmarshal(rsp.Data, &result)) s.Require().Equal(uint64(1), result.CodeID) expHash := sha256.Sum256(wasmContract) s.Require().Equal(expHash[:], result.Checksum) // and info := s.app.AppKeepers.WasmKeeper.GetCodeInfo(s.ctx, 1) s.Require().NotNil(info) s.Require().Equal(expHash[:], info.CodeHash) s.Require().Equal(sender.String(), info.Creator) s.Require().Equal(wasmtypes.DefaultParams().InstantiateDefaultPermission.With(sender), info.InstantiateConfig) } func (s *EndBlockerTestSuite) InstantiateContract(sender string, admin string) string { msgStoreCode := wasmtypes.MsgStoreCodeFixture(func(m *wasmtypes.MsgStoreCode) { m.WASMByteCode = clockContract m.Sender = sender }) _, err := s.app.MsgServiceRouter().Handler(msgStoreCode)(s.ctx, msgStoreCode) s.Require().NoError(err) msgInstantiate := wasmtypes.MsgInstantiateContractFixture(func(m *wasmtypes.MsgInstantiateContract) { m.Sender = sender m.Admin = admin m.Msg = []byte(`{}`) }) resp, err := s.app.MsgServiceRouter().Handler(msgInstantiate)(s.ctx, msgInstantiate) s.Require().NoError(err) var result wasmtypes.MsgInstantiateContractResponse s.Require().NoError(s.app.AppCodec().Unmarshal(resp.Data, &result)) contractInfo := s.app.AppKeepers.WasmKeeper.GetContractInfo(s.ctx, sdk.MustAccAddressFromBech32(result.Address)) s.Require().Equal(contractInfo.CodeID, uint64(1)) s.Require().Equal(contractInfo.Admin, admin) s.Require().Equal(contractInfo.Creator, sender) return result.Address } func (s *EndBlockerTestSuite) FundAccount(ctx sdk.Context, addr sdk.AccAddress, amounts sdk.Coins) error { if err := s.app.AppKeepers.BankKeeper.MintCoins(ctx, minttypes.ModuleName, amounts); err != nil { return err } return s.app.AppKeepers.BankKeeper.SendCoinsFromModuleToAccount(ctx, minttypes.ModuleName, addr, amounts) } // Register a contract. You must store the contract code before registering. func (s *EndBlockerTestSuite) registerContract() string { // Create & fund accounts _, _, sender := testdata.KeyTestPubAddr() _, _, admin := testdata.KeyTestPubAddr() _ = s.FundAccount(s.ctx, sender, sdk.NewCoins(sdk.NewCoin("stake", sdk.NewInt(1_000_000)))) _ = s.FundAccount(s.ctx, admin, sdk.NewCoins(sdk.NewCoin("stake", sdk.NewInt(1_000_000)))) // Instantiate contract contractAddress := s.InstantiateContract(sender.String(), admin.String()) // Register contract clockKeeper := s.app.AppKeepers.ClockKeeper err := clockKeeper.RegisterContract(s.ctx, admin.String(), contractAddress) s.Require().NoError(err) // Assert contract is registered contract, err := clockKeeper.GetClockContract(s.ctx, contractAddress) s.Require().NoError(err) s.Require().Equal(contractAddress, contract.ContractAddress) // Increment block height s.ctx = s.ctx.WithBlockHeight(11) return contract.ContractAddress } // Test the end blocker. This test registers a contract, executes it with enough gas, // too little gas, and also ensures the unjailing process functions. func (s *EndBlockerTestSuite) TestEndBlocker() { // Setup test clockKeeper := s.app.AppKeepers.ClockKeeper s.StoreCode(clockContract) contractAddress := s.registerContract() // Query contract val := s.queryContract(contractAddress) s.Require().Equal(int64(0), val) // Call end blocker s.callEndBlocker() // Query contract val = s.queryContract(contractAddress) s.Require().Equal(int64(1), val) // Update params with 10 gas limit s.updateGasLimit(65_000) // Call end blocker s.callEndBlocker() // Ensure contract is now jailed contract, err := clockKeeper.GetClockContract(s.ctx, contractAddress) s.Require().NoError(err) s.Require().True(contract.IsJailed) // Update params to regular s.updateGasLimit(types.DefaultParams().ContractGasLimit) // Call end blocker s.callEndBlocker() // Unjail contract err = clockKeeper.SetJailStatus(s.ctx, contractAddress, false) s.Require().NoError(err) // Ensure contract is no longer jailed contract, err = clockKeeper.GetClockContract(s.ctx, contractAddress) s.Require().NoError(err) s.Require().False(contract.IsJailed) // Call end blocker s.callEndBlocker() // Query contract val = s.queryContract(contractAddress) s.Require().Equal(int64(2), val) } // Test a contract which does not handle the sudo EndBlock msg. func (s *EndBlockerTestSuite) TestInvalidContract() { // Setup test clockKeeper := s.app.AppKeepers.ClockKeeper s.StoreCode(burnContract) contractAddress := s.registerContract() // Run the end blocker s.callEndBlocker() // Ensure contract is now jailed contract, err := clockKeeper.GetClockContract(s.ctx, contractAddress) s.Require().NoError(err) s.Require().True(contract.IsJailed) } // Test the endblocker with numerous contracts that all panic func (s *EndBlockerTestSuite) TestPerformance() { s.StoreCode(burnContract) numContracts := 1000 // Register numerous contracts for x := 0; x < numContracts; x++ { // Register contract _ = s.registerContract() } // Ensure contracts exist clockKeeper := s.app.AppKeepers.ClockKeeper contracts, err := clockKeeper.GetAllContracts(s.ctx) s.Require().NoError(err) s.Require().Len(contracts, numContracts) // Call end blocker s.callEndBlocker() // Ensure contracts are jailed contracts, err = clockKeeper.GetAllContracts(s.ctx) s.Require().NoError(err) for _, contract := range contracts { s.Require().True(contract.IsJailed) } } // Update the gas limit func (s *EndBlockerTestSuite) updateGasLimit(gasLimit uint64) { params := types.DefaultParams() params.ContractGasLimit = gasLimit k := s.app.AppKeepers.ClockKeeper store := s.ctx.KVStore(k.GetStore()) bz := k.GetCdc().MustMarshal(¶ms) store.Set(types.ParamsKey, bz) s.ctx = s.ctx.WithBlockHeight(s.ctx.BlockHeight() + 1) } // Call the end blocker, incrementing the block height func (s *EndBlockerTestSuite) callEndBlocker() { clock.EndBlocker(s.ctx, s.app.AppKeepers.ClockKeeper) s.ctx = s.ctx.WithBlockHeight(s.ctx.BlockHeight() + 1) } // Query the clock contract func (s *EndBlockerTestSuite) queryContract(contractAddress string) int64 { query := `{"get_config":{}}` output, err := s.app.AppKeepers.WasmKeeper.QuerySmart(s.ctx, sdk.MustAccAddressFromBech32(contractAddress), []byte(query)) s.Require().NoError(err) var val struct { Val int64 `json:"val"` } err = json.Unmarshal(output, &val) s.Require().NoError(err) return val.Val } ================================================ FILE: x/clock/client/cli/query.go ================================================ package cli import ( "github.com/spf13/cobra" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cybercongress/go-cyber/v7/x/clock/types" ) func GetQueryCmd() *cobra.Command { queryCmd := &cobra.Command{ Use: types.ModuleName, Short: "Querying commands for clock modules", DisableFlagParsing: true, SuggestionsMinimumDistance: 2, RunE: client.ValidateCmd, } queryCmd.AddCommand( GetCmdShowContracts(), GetCmdShowContract(), GetCmdParams(), ) return queryCmd } func GetCmdShowContracts() *cobra.Command { cmd := &cobra.Command{ Use: "contracts", Short: "Show addresses of all current clock contracts", Args: cobra.ExactArgs(0), RunE: func(cmd *cobra.Command, _ []string) error { clientCtx, err := client.GetClientQueryContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) pageReq, err := client.ReadPageRequest(cmd.Flags()) if err != nil { return err } res, err := queryClient.ClockContracts(cmd.Context(), &types.QueryClockContracts{ Pagination: pageReq, }) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) flags.AddPaginationFlagsToCmd(cmd, "contracts") return cmd } func GetCmdShowContract() *cobra.Command { cmd := &cobra.Command{ Use: "contract [contract_address]", Short: "Get contract by address", Args: cobra.ExactArgs(1), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientQueryContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) req := &types.QueryClockContract{ ContractAddress: args[0], } res, err := queryClient.ClockContract(cmd.Context(), req) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } func GetCmdParams() *cobra.Command { cmd := &cobra.Command{ Use: "params", Short: "Show all module params", Args: cobra.ExactArgs(0), RunE: func(cmd *cobra.Command, _ []string) error { clientCtx, err := client.GetClientQueryContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) res, err := queryClient.Params(cmd.Context(), &types.QueryParamsRequest{}) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } ================================================ FILE: x/clock/client/cli/tx.go ================================================ package cli import ( "github.com/spf13/cobra" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/client/tx" "github.com/cybercongress/go-cyber/v7/x/clock/types" ) // NewTxCmd returns a root CLI command handler for certain modules/Clock // transaction commands. func NewTxCmd() *cobra.Command { txCmd := &cobra.Command{ Use: types.ModuleName, Short: "Clock subcommands.", DisableFlagParsing: true, SuggestionsMinimumDistance: 2, RunE: client.ValidateCmd, } txCmd.AddCommand( NewRegisterClockContract(), NewUnregisterClockContract(), NewUnjailClockContract(), ) return txCmd } // NewRegisterClockContract returns a CLI command handler for registering a // contract for the clock module. func NewRegisterClockContract() *cobra.Command { cmd := &cobra.Command{ Use: "register [contract_bech32]", Short: "Register a clock contract.", Long: "Register a clock contract. Sender must be admin of the contract.", Args: cobra.ExactArgs(1), RunE: func(cmd *cobra.Command, args []string) error { cliCtx, err := client.GetClientTxContext(cmd) if err != nil { return err } senderAddress := cliCtx.GetFromAddress() contractAddress := args[0] msg := &types.MsgRegisterClockContract{ SenderAddress: senderAddress.String(), ContractAddress: contractAddress, } if err := msg.ValidateBasic(); err != nil { return err } return tx.GenerateOrBroadcastTxCLI(cliCtx, cmd.Flags(), msg) }, } flags.AddTxFlagsToCmd(cmd) return cmd } // NewUnregisterClockContract returns a CLI command handler for unregistering a // contract for the clock module. func NewUnregisterClockContract() *cobra.Command { cmd := &cobra.Command{ Use: "unregister [contract_bech32]", Short: "Unregister a clock contract.", Long: "Unregister a clock contract. Sender must be admin of the contract.", Args: cobra.ExactArgs(1), RunE: func(cmd *cobra.Command, args []string) error { cliCtx, err := client.GetClientTxContext(cmd) if err != nil { return err } senderAddress := cliCtx.GetFromAddress() contractAddress := args[0] msg := &types.MsgUnregisterClockContract{ SenderAddress: senderAddress.String(), ContractAddress: contractAddress, } if err := msg.ValidateBasic(); err != nil { return err } return tx.GenerateOrBroadcastTxCLI(cliCtx, cmd.Flags(), msg) }, } flags.AddTxFlagsToCmd(cmd) return cmd } // NewUnjailClockContract returns a CLI command handler for unjailing a // contract for the clock module. func NewUnjailClockContract() *cobra.Command { cmd := &cobra.Command{ Use: "unjail [contract_bech32]", Short: "Unjail a clock contract.", Long: "Unjail a clock contract. Sender must be admin of the contract.", Args: cobra.ExactArgs(1), RunE: func(cmd *cobra.Command, args []string) error { cliCtx, err := client.GetClientTxContext(cmd) if err != nil { return err } senderAddress := cliCtx.GetFromAddress() contractAddress := args[0] msg := &types.MsgUnjailClockContract{ SenderAddress: senderAddress.String(), ContractAddress: contractAddress, } if err := msg.ValidateBasic(); err != nil { return err } return tx.GenerateOrBroadcastTxCLI(cliCtx, cmd.Flags(), msg) }, } flags.AddTxFlagsToCmd(cmd) return cmd } ================================================ FILE: x/clock/genesis.go ================================================ package clock import ( "encoding/json" "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/clock/keeper" "github.com/cybercongress/go-cyber/v7/x/clock/types" ) // NewGenesisState - Create a new genesis state func NewGenesisState(params types.Params) *types.GenesisState { return &types.GenesisState{ Params: params, } } // DefaultGenesisState - Return a default genesis state func DefaultGenesisState() *types.GenesisState { return NewGenesisState(types.DefaultParams()) } // GetGenesisStateFromAppState returns x/auth GenesisState given raw application // genesis state. func GetGenesisStateFromAppState(cdc codec.Codec, appState map[string]json.RawMessage) *types.GenesisState { var genesisState types.GenesisState if appState[ModuleName] != nil { cdc.MustUnmarshalJSON(appState[ModuleName], &genesisState) } return &genesisState } func ValidateGenesis(data types.GenesisState) error { err := data.Params.Validate() if err != nil { return err } return nil } // InitGenesis import module genesis func InitGenesis( ctx sdk.Context, k keeper.Keeper, data types.GenesisState, ) { // Validate init contents if err := ValidateGenesis(data); err != nil { panic(err) } // Set params if err := k.SetParams(ctx, data.Params); err != nil { panic(err) } } // ExportGenesis export module state func ExportGenesis(ctx sdk.Context, k keeper.Keeper) *types.GenesisState { params := k.GetParams(ctx) return &types.GenesisState{ Params: params, } } ================================================ FILE: x/clock/genesis_test.go ================================================ package clock_test import ( "fmt" "testing" "github.com/stretchr/testify/suite" tmproto "github.com/cometbft/cometbft/proto/tendermint/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/app" clock "github.com/cybercongress/go-cyber/v7/x/clock" "github.com/cybercongress/go-cyber/v7/x/clock/types" ) type GenesisTestSuite struct { suite.Suite ctx sdk.Context app *app.App } func TestGenesisTestSuite(t *testing.T) { suite.Run(t, new(GenesisTestSuite)) } func (suite *GenesisTestSuite) SetupTest() { app := app.Setup(suite.T()) ctx := app.BaseApp.NewContext(false, tmproto.Header{ ChainID: "testing", }) suite.app = app suite.ctx = ctx } func (suite *GenesisTestSuite) TestClockInitGenesis() { testCases := []struct { name string genesis types.GenesisState success bool }{ { "Success - Default Genesis", *clock.DefaultGenesisState(), true, }, { "Success - Custom Genesis", types.GenesisState{ Params: types.Params{ ContractGasLimit: 500_000, }, }, true, }, { "Fail - Invalid Gas Amount", types.GenesisState{ Params: types.Params{ ContractGasLimit: 1, }, }, false, }, } for _, tc := range testCases { suite.Run(fmt.Sprintf("Case %s", tc.name), func() { suite.SetupTest() // reset if tc.success { suite.Require().NotPanics(func() { clock.InitGenesis(suite.ctx, suite.app.AppKeepers.ClockKeeper, tc.genesis) }) params := suite.app.AppKeepers.ClockKeeper.GetParams(suite.ctx) suite.Require().Equal(tc.genesis.Params, params) } else { suite.Require().Panics(func() { clock.InitGenesis(suite.ctx, suite.app.AppKeepers.ClockKeeper, tc.genesis) }) } }) } } ================================================ FILE: x/clock/keeper/clock.go ================================================ package keeper import ( "github.com/cosmos/cosmos-sdk/store/prefix" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/query" globalerrors "github.com/cybercongress/go-cyber/v7/app/helpers" "github.com/cybercongress/go-cyber/v7/x/clock/types" ) // Store Keys for clock contracts (both jailed and unjailed) var ( StoreKeyContracts = []byte("contracts") ) // Get the store for the clock contracts. func (k Keeper) getContractsStore(ctx sdk.Context) prefix.Store { return prefix.NewStore(ctx.KVStore(k.storeKey), StoreKeyContracts) } // Set a clock contract address in the KV store. func (k Keeper) SetClockContract(ctx sdk.Context, contract types.ClockContract) error { // Get store, marshal content store := k.getContractsStore(ctx) bz, err := k.cdc.Marshal(&contract) if err != nil { return err } // Set the contract store.Set([]byte(contract.ContractAddress), bz) return nil } // Check if a clock contract address is in the KV store. func (k Keeper) IsClockContract(ctx sdk.Context, contractAddress string) bool { store := k.getContractsStore(ctx) return store.Has([]byte(contractAddress)) } // Get a clock contract address from the KV store. func (k Keeper) GetClockContract(ctx sdk.Context, contractAddress string) (*types.ClockContract, error) { // Check if the contract is registered if !k.IsClockContract(ctx, contractAddress) { return nil, globalerrors.ErrContractNotRegistered } // Get the KV store store := k.getContractsStore(ctx) bz := store.Get([]byte(contractAddress)) // Unmarshal the contract var contract types.ClockContract err := k.cdc.Unmarshal(bz, &contract) if err != nil { return nil, err } // Return the contract return &contract, nil } // Get all clock contract addresses from the KV store. func (k Keeper) GetAllContracts(ctx sdk.Context) ([]types.ClockContract, error) { // Get the KV store store := k.getContractsStore(ctx) // Create iterator for contracts iterator := sdk.KVStorePrefixIterator(store, []byte(nil)) defer iterator.Close() // Iterate over all contracts contracts := []types.ClockContract{} for ; iterator.Valid(); iterator.Next() { // Unmarshal iterator var contract types.ClockContract err := k.cdc.Unmarshal(iterator.Value(), &contract) if err != nil { return nil, err } contracts = append(contracts, contract) } // Return array of contracts return contracts, nil } // Get all registered fee pay contracts func (k Keeper) GetPaginatedContracts(ctx sdk.Context, pag *query.PageRequest) (*types.QueryClockContractsResponse, error) { store := k.getContractsStore(ctx) // Filter and paginate all contracts results, pageRes, err := query.GenericFilteredPaginate( k.cdc, store, pag, func(_ []byte, value *types.ClockContract) (*types.ClockContract, error) { return value, nil }, func() *types.ClockContract { return &types.ClockContract{} }, ) if err != nil { return nil, err } // Dereference pointer array of contracts var contracts []types.ClockContract for _, contract := range results { contracts = append(contracts, *contract) } // Return paginated contracts return &types.QueryClockContractsResponse{ ClockContracts: contracts, Pagination: pageRes, }, nil } // Remove a clock contract address from the KV store. func (k Keeper) RemoveContract(ctx sdk.Context, contractAddress string) { store := k.getContractsStore(ctx) key := []byte(contractAddress) if store.Has(key) { store.Delete(key) } } // Register a clock contract address in the KV store. func (k Keeper) RegisterContract(ctx sdk.Context, senderAddress string, contractAddress string) error { // Check if the contract is already registered if k.IsClockContract(ctx, contractAddress) { return globalerrors.ErrContractAlreadyRegistered } // Ensure the sender is the contract admin or creator if ok, err := k.IsContractManager(ctx, senderAddress, contractAddress); !ok { return err } // Register contract return k.SetClockContract(ctx, types.ClockContract{ ContractAddress: contractAddress, IsJailed: false, }) } // Unregister a clock contract from either the jailed or unjailed KV store. func (k Keeper) UnregisterContract(ctx sdk.Context, senderAddress string, contractAddress string) error { // Check if the contract is registered in either store if !k.IsClockContract(ctx, contractAddress) { return globalerrors.ErrContractNotRegistered } // Ensure the sender is the contract admin or creator if ok, err := k.IsContractManager(ctx, senderAddress, contractAddress); !ok { return err } // Remove contract from both stores k.RemoveContract(ctx, contractAddress) return nil } // Set the jail status of a clock contract in the KV store. func (k Keeper) SetJailStatus(ctx sdk.Context, contractAddress string, isJailed bool) error { // Get the contract contract, err := k.GetClockContract(ctx, contractAddress) if err != nil { return err } // Check if the contract is already jailed or unjailed if contract.IsJailed == isJailed { if isJailed { return types.ErrContractAlreadyJailed } return types.ErrContractNotJailed } // Set the jail status contract.IsJailed = isJailed // Set the contract return k.SetClockContract(ctx, *contract) } // Set the jail status of a clock contract by the sender address. func (k Keeper) SetJailStatusBySender(ctx sdk.Context, senderAddress string, contractAddress string, jailStatus bool) error { // Ensure the sender is the contract admin or creator if ok, err := k.IsContractManager(ctx, senderAddress, contractAddress); !ok { return err } return k.SetJailStatus(ctx, contractAddress, jailStatus) } // Check if the sender is the designated contract manager for the FeePay contract. If // an admin is present, they are considered the manager. If there is no admin, the // contract creator is considered the manager. func (k Keeper) IsContractManager(ctx sdk.Context, senderAddress string, contractAddress string) (bool, error) { contractAddr := sdk.MustAccAddressFromBech32(contractAddress) // Ensure the contract is a cosm wasm contract if ok := k.wasmKeeper.HasContractInfo(ctx, contractAddr); !ok { return false, globalerrors.ErrInvalidCWContract } // Get the contract info contractInfo := k.wasmKeeper.GetContractInfo(ctx, contractAddr) // Flags for admin existence & sender being admin/creator adminExists := len(contractInfo.Admin) > 0 isSenderAdmin := contractInfo.Admin == senderAddress isSenderCreator := contractInfo.Creator == senderAddress // Check if the sender is the admin or creator if adminExists && !isSenderAdmin { return false, globalerrors.ErrContractNotAdmin } else if !adminExists && !isSenderCreator { return false, globalerrors.ErrContractNotCreator } return true, nil } ================================================ FILE: x/clock/keeper/keeper.go ================================================ package keeper import ( wasmkeeper "github.com/CosmWasm/wasmd/x/wasm/keeper" wasmtypes "github.com/CosmWasm/wasmd/x/wasm/types" "github.com/cometbft/cometbft/libs/log" "github.com/cosmos/cosmos-sdk/codec" storetypes "github.com/cosmos/cosmos-sdk/store/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/clock/types" ) // Keeper of the clock store type Keeper struct { storeKey storetypes.StoreKey cdc codec.BinaryCodec wasmKeeper wasmkeeper.Keeper contractKeeper wasmtypes.ContractOpsKeeper authority string } func NewKeeper( key storetypes.StoreKey, cdc codec.BinaryCodec, wasmKeeper wasmkeeper.Keeper, contractKeeper wasmtypes.ContractOpsKeeper, authority string, ) Keeper { return Keeper{ cdc: cdc, storeKey: key, wasmKeeper: wasmKeeper, contractKeeper: contractKeeper, authority: authority, } } // Logger returns a module-specific logger. func (k Keeper) Logger(ctx sdk.Context) log.Logger { return ctx.Logger().With("module", "x/"+types.ModuleName) } // GetAuthority returns the x/clock module's authority. func (k Keeper) GetAuthority() string { return k.authority } // SetParams sets the x/clock module parameters. func (k Keeper) SetParams(ctx sdk.Context, p types.Params) error { if err := p.Validate(); err != nil { return err } store := ctx.KVStore(k.storeKey) bz := k.cdc.MustMarshal(&p) store.Set(types.ParamsKey, bz) return nil } // GetParams returns the current x/clock module parameters. func (k Keeper) GetParams(ctx sdk.Context) (p types.Params) { store := ctx.KVStore(k.storeKey) bz := store.Get(types.ParamsKey) if bz == nil { return p } k.cdc.MustUnmarshal(bz, &p) return p } // GetContractKeeper returns the x/wasm module's contract keeper. func (k Keeper) GetContractKeeper() wasmtypes.ContractOpsKeeper { return k.contractKeeper } // GetCdc returns the x/clock module's codec. func (k Keeper) GetCdc() codec.BinaryCodec { return k.cdc } // GetStore returns the x/clock module's store key. func (k Keeper) GetStore() storetypes.StoreKey { return k.storeKey } ================================================ FILE: x/clock/keeper/keeper_test.go ================================================ package keeper_test import ( "crypto/sha256" "testing" "time" wasmtypes "github.com/CosmWasm/wasmd/x/wasm/types" "github.com/stretchr/testify/suite" _ "embed" tmproto "github.com/cometbft/cometbft/proto/tendermint/types" "github.com/cosmos/cosmos-sdk/baseapp" "github.com/cosmos/cosmos-sdk/testutil/testdata" sdk "github.com/cosmos/cosmos-sdk/types" bankkeeper "github.com/cosmos/cosmos-sdk/x/bank/keeper" minttypes "github.com/cosmos/cosmos-sdk/x/mint/types" "github.com/cybercongress/go-cyber/v7/app" "github.com/cybercongress/go-cyber/v7/x/clock/keeper" "github.com/cybercongress/go-cyber/v7/x/clock/types" ) type IntegrationTestSuite struct { suite.Suite ctx sdk.Context app *app.App bankKeeper bankkeeper.Keeper queryClient types.QueryClient clockMsgServer types.MsgServer } func (s *IntegrationTestSuite) SetupTest() { isCheckTx := false s.app = app.Setup(s.T()) s.ctx = s.app.BaseApp.NewContext(isCheckTx, tmproto.Header{ ChainID: "testing", Height: 1, Time: time.Now().UTC(), }) queryHelper := baseapp.NewQueryServerTestHelper(s.ctx, s.app.InterfaceRegistry()) types.RegisterQueryServer(queryHelper, keeper.NewQuerier(s.app.AppKeepers.ClockKeeper)) s.queryClient = types.NewQueryClient(queryHelper) s.bankKeeper = s.app.AppKeepers.BankKeeper s.clockMsgServer = keeper.NewMsgServerImpl(s.app.AppKeepers.ClockKeeper) } func (s *IntegrationTestSuite) FundAccount(ctx sdk.Context, addr sdk.AccAddress, amounts sdk.Coins) error { if err := s.bankKeeper.MintCoins(ctx, minttypes.ModuleName, amounts); err != nil { return err } return s.bankKeeper.SendCoinsFromModuleToAccount(ctx, minttypes.ModuleName, addr, amounts) } func TestKeeperTestSuite(t *testing.T) { suite.Run(t, new(IntegrationTestSuite)) } //go:embed testdata/clock_example.wasm var wasmContract []byte func (s *IntegrationTestSuite) StoreCode() { _, _, sender := testdata.KeyTestPubAddr() msg := wasmtypes.MsgStoreCodeFixture(func(m *wasmtypes.MsgStoreCode) { m.WASMByteCode = wasmContract m.Sender = sender.String() }) rsp, err := s.app.MsgServiceRouter().Handler(msg)(s.ctx, msg) s.Require().NoError(err) var result wasmtypes.MsgStoreCodeResponse s.Require().NoError(s.app.AppCodec().Unmarshal(rsp.Data, &result)) s.Require().Equal(uint64(1), result.CodeID) expHash := sha256.Sum256(wasmContract) s.Require().Equal(expHash[:], result.Checksum) // and info := s.app.AppKeepers.WasmKeeper.GetCodeInfo(s.ctx, 1) s.Require().NotNil(info) s.Require().Equal(expHash[:], info.CodeHash) s.Require().Equal(sender.String(), info.Creator) s.Require().Equal(wasmtypes.DefaultParams().InstantiateDefaultPermission.With(sender), info.InstantiateConfig) } func (s *IntegrationTestSuite) InstantiateContract(sender string, admin string) string { msgStoreCode := wasmtypes.MsgStoreCodeFixture(func(m *wasmtypes.MsgStoreCode) { m.WASMByteCode = wasmContract m.Sender = sender }) _, err := s.app.MsgServiceRouter().Handler(msgStoreCode)(s.ctx, msgStoreCode) s.Require().NoError(err) msgInstantiate := wasmtypes.MsgInstantiateContractFixture(func(m *wasmtypes.MsgInstantiateContract) { m.Sender = sender m.Admin = admin m.Msg = []byte(`{}`) }) resp, err := s.app.MsgServiceRouter().Handler(msgInstantiate)(s.ctx, msgInstantiate) s.Require().NoError(err) var result wasmtypes.MsgInstantiateContractResponse s.Require().NoError(s.app.AppCodec().Unmarshal(resp.Data, &result)) contractInfo := s.app.AppKeepers.WasmKeeper.GetContractInfo(s.ctx, sdk.MustAccAddressFromBech32(result.Address)) s.Require().Equal(contractInfo.CodeID, uint64(1)) s.Require().Equal(contractInfo.Admin, admin) s.Require().Equal(contractInfo.Creator, sender) return result.Address } // Helper method for quickly registering a clock contract func (s *IntegrationTestSuite) RegisterClockContract(senderAddress string, contractAddress string) { err := s.app.AppKeepers.ClockKeeper.RegisterContract(s.ctx, senderAddress, contractAddress) s.Require().NoError(err) } // Helper method for quickly unregistering a clock contract func (s *IntegrationTestSuite) UnregisterClockContract(senderAddress string, contractAddress string) { err := s.app.AppKeepers.ClockKeeper.UnregisterContract(s.ctx, senderAddress, contractAddress) s.Require().NoError(err) } // Helper method for quickly jailing a clock contract func (s *IntegrationTestSuite) JailClockContract(contractAddress string) { err := s.app.AppKeepers.ClockKeeper.SetJailStatus(s.ctx, contractAddress, true) s.Require().NoError(err) } // Helper method for quickly unjailing a clock contract func (s *IntegrationTestSuite) UnjailClockContract(senderAddress string, contractAddress string) { err := s.app.AppKeepers.ClockKeeper.SetJailStatusBySender(s.ctx, senderAddress, contractAddress, false) s.Require().NoError(err) } ================================================ FILE: x/clock/keeper/msg_server.go ================================================ package keeper import ( "context" errorsmod "cosmossdk.io/errors" sdk "github.com/cosmos/cosmos-sdk/types" govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" "github.com/cybercongress/go-cyber/v7/x/clock/types" ) var _ types.MsgServer = &msgServer{} // msgServer is a wrapper of Keeper. type msgServer struct { Keeper } // NewMsgServerImpl returns an implementation of the x/clock MsgServer interface. func NewMsgServerImpl(k Keeper) types.MsgServer { return &msgServer{ Keeper: k, } } // RegisterClockContract handles incoming transactions to register clock contracts. func (k msgServer) RegisterClockContract(goCtx context.Context, req *types.MsgRegisterClockContract) (*types.MsgRegisterClockContractResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) // Validate request if err := req.ValidateBasic(); err != nil { return nil, err } return &types.MsgRegisterClockContractResponse{}, k.RegisterContract(ctx, req.SenderAddress, req.ContractAddress) } // UnregisterClockContract handles incoming transactions to unregister clock contracts. func (k msgServer) UnregisterClockContract(goCtx context.Context, req *types.MsgUnregisterClockContract) (*types.MsgUnregisterClockContractResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) // Validate request if err := req.ValidateBasic(); err != nil { return nil, err } return &types.MsgUnregisterClockContractResponse{}, k.UnregisterContract(ctx, req.SenderAddress, req.ContractAddress) } // UnjailClockContract handles incoming transactions to unjail clock contracts. func (k msgServer) UnjailClockContract(goCtx context.Context, req *types.MsgUnjailClockContract) (*types.MsgUnjailClockContractResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) // Validate request if err := req.ValidateBasic(); err != nil { return nil, err } return &types.MsgUnjailClockContractResponse{}, k.SetJailStatusBySender(ctx, req.SenderAddress, req.ContractAddress, false) } func (k msgServer) UpdateParams(goCtx context.Context, req *types.MsgUpdateParams) (*types.MsgUpdateParamsResponse, error) { if k.authority != req.Authority { return nil, errorsmod.Wrapf(govtypes.ErrInvalidSigner, "invalid authority; expected %s, got %s", k.authority, req.Authority) } ctx := sdk.UnwrapSDKContext(goCtx) if err := k.SetParams(ctx, req.Params); err != nil { return nil, err } return &types.MsgUpdateParamsResponse{}, nil } ================================================ FILE: x/clock/keeper/msg_server_test.go ================================================ package keeper_test import ( _ "embed" "github.com/cosmos/cosmos-sdk/testutil/testdata" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/clock/types" ) // Test register clock contract. func (s *IntegrationTestSuite) TestRegisterClockContract() { _, _, addr := testdata.KeyTestPubAddr() _, _, addr2 := testdata.KeyTestPubAddr() _ = s.FundAccount(s.ctx, addr, sdk.NewCoins(sdk.NewCoin("stake", sdk.NewInt(1_000_000)))) // Store code s.StoreCode() contractAddress := s.InstantiateContract(addr.String(), "") contractAddressWithAdmin := s.InstantiateContract(addr.String(), addr2.String()) for _, tc := range []struct { desc string sender string contract string isJailed bool success bool }{ { desc: "Success - Register Contract", sender: addr.String(), contract: contractAddress, success: true, }, { desc: "Success - Register Contract With Admin", sender: addr2.String(), contract: contractAddressWithAdmin, success: true, }, { desc: "Fail - Register Contract With Admin, But With Creator Addr", sender: addr.String(), contract: contractAddressWithAdmin, success: false, }, { desc: "Error - Invalid Sender", sender: addr2.String(), contract: contractAddress, success: false, }, { desc: "Fail - Invalid Contract Address", sender: addr.String(), contract: "Invalid", success: false, }, { desc: "Fail - Invalid Sender Address", sender: "Invalid", contract: contractAddress, success: false, }, { desc: "Fail - Contract Already Jailed", sender: addr.String(), contract: contractAddress, isJailed: true, success: false, }, } { tc := tc s.Run(tc.desc, func() { // Set params params := types.DefaultParams() err := s.app.AppKeepers.ClockKeeper.SetParams(s.ctx, params) s.Require().NoError(err) // Jail contract if needed if tc.isJailed { s.RegisterClockContract(tc.sender, tc.contract) err := s.app.AppKeepers.ClockKeeper.SetJailStatus(s.ctx, tc.contract, true) s.Require().NoError(err) } // Try to register contract res, err := s.clockMsgServer.RegisterClockContract(s.ctx, &types.MsgRegisterClockContract{ SenderAddress: tc.sender, ContractAddress: tc.contract, }) if !tc.success { s.Require().Error(err) } else { s.Require().NoError(err) s.Require().Equal(res, &types.MsgRegisterClockContractResponse{}) } // Ensure contract is unregistered s.app.AppKeepers.ClockKeeper.RemoveContract(s.ctx, contractAddress) s.app.AppKeepers.ClockKeeper.RemoveContract(s.ctx, contractAddressWithAdmin) }) } } // Test standard unregistration of clock contracts. func (s *IntegrationTestSuite) TestUnregisterClockContract() { _, _, addr := testdata.KeyTestPubAddr() _, _, addr2 := testdata.KeyTestPubAddr() _ = s.FundAccount(s.ctx, addr, sdk.NewCoins(sdk.NewCoin("stake", sdk.NewInt(1_000_000)))) s.StoreCode() contractAddress := s.InstantiateContract(addr.String(), "") contractAddressWithAdmin := s.InstantiateContract(addr.String(), addr2.String()) for _, tc := range []struct { desc string sender string contract string success bool }{ { desc: "Success - Unregister Contract", sender: addr.String(), contract: contractAddress, success: true, }, { desc: "Success - Unregister Contract With Admin", sender: addr2.String(), contract: contractAddressWithAdmin, success: true, }, { desc: "Fail - Unregister Contract With Admin, But With Creator Addr", sender: addr.String(), contract: contractAddressWithAdmin, success: false, }, { desc: "Error - Invalid Sender", sender: addr2.String(), contract: contractAddress, success: false, }, { desc: "Fail - Invalid Contract Address", sender: addr.String(), contract: "Invalid", success: false, }, { desc: "Fail - Invalid Sender Address", sender: "Invalid", contract: contractAddress, success: false, }, } { tc := tc s.Run(tc.desc, func() { s.RegisterClockContract(addr.String(), contractAddress) s.RegisterClockContract(addr2.String(), contractAddressWithAdmin) // Set params params := types.DefaultParams() err := s.app.AppKeepers.ClockKeeper.SetParams(s.ctx, params) s.Require().NoError(err) // Try to register all contracts res, err := s.clockMsgServer.UnregisterClockContract(s.ctx, &types.MsgUnregisterClockContract{ SenderAddress: tc.sender, ContractAddress: tc.contract, }) if !tc.success { s.Require().Error(err) } else { s.Require().NoError(err) s.Require().Equal(res, &types.MsgUnregisterClockContractResponse{}) } // Ensure contract is unregistered s.app.AppKeepers.ClockKeeper.RemoveContract(s.ctx, contractAddress) s.app.AppKeepers.ClockKeeper.RemoveContract(s.ctx, contractAddressWithAdmin) }) } } // Test duplicate register/unregister clock contracts. func (s *IntegrationTestSuite) TestDuplicateRegistrationChecks() { _, _, addr := testdata.KeyTestPubAddr() _ = s.FundAccount(s.ctx, addr, sdk.NewCoins(sdk.NewCoin("stake", sdk.NewInt(1_000_000)))) s.StoreCode() contractAddress := s.InstantiateContract(addr.String(), "") // Test double register, first succeed, second fail _, err := s.clockMsgServer.RegisterClockContract(s.ctx, &types.MsgRegisterClockContract{ SenderAddress: addr.String(), ContractAddress: contractAddress, }) s.Require().NoError(err) _, err = s.clockMsgServer.RegisterClockContract(s.ctx, &types.MsgRegisterClockContract{ SenderAddress: addr.String(), ContractAddress: contractAddress, }) s.Require().Error(err) // Test double unregister, first succeed, second fail _, err = s.clockMsgServer.UnregisterClockContract(s.ctx, &types.MsgUnregisterClockContract{ SenderAddress: addr.String(), ContractAddress: contractAddress, }) s.Require().NoError(err) _, err = s.clockMsgServer.UnregisterClockContract(s.ctx, &types.MsgUnregisterClockContract{ SenderAddress: addr.String(), ContractAddress: contractAddress, }) s.Require().Error(err) } // Test unjailing clock contracts. func (s *IntegrationTestSuite) TestUnjailClockContract() { _, _, addr := testdata.KeyTestPubAddr() _, _, addr2 := testdata.KeyTestPubAddr() _ = s.FundAccount(s.ctx, addr, sdk.NewCoins(sdk.NewCoin("stake", sdk.NewInt(1_000_000)))) s.StoreCode() contractAddress := s.InstantiateContract(addr.String(), "") contractAddressWithAdmin := s.InstantiateContract(addr.String(), addr2.String()) for _, tc := range []struct { desc string sender string contract string unjail bool success bool }{ { desc: "Success - Unjail Contract", sender: addr.String(), contract: contractAddress, success: true, }, { desc: "Success - Unjail Contract With Admin", sender: addr2.String(), contract: contractAddressWithAdmin, success: true, }, { desc: "Fail - Unjail Contract With Admin, But With Creator Addr", sender: addr.String(), contract: contractAddressWithAdmin, success: false, }, { desc: "Error - Invalid Sender", sender: addr2.String(), contract: contractAddress, success: false, }, { desc: "Fail - Invalid Contract Address", sender: addr.String(), contract: "Invalid", success: false, }, { desc: "Fail - Invalid Sender Address", sender: "Invalid", contract: contractAddress, success: false, }, { desc: "Fail - Contract Not Jailed", sender: addr.String(), contract: contractAddress, unjail: true, success: false, }, } { tc := tc s.Run(tc.desc, func() { s.RegisterClockContract(addr.String(), contractAddress) s.JailClockContract(contractAddress) s.RegisterClockContract(addr2.String(), contractAddressWithAdmin) s.JailClockContract(contractAddressWithAdmin) // Unjail contract if needed if tc.unjail { s.UnjailClockContract(addr.String(), contractAddress) s.UnjailClockContract(addr2.String(), contractAddressWithAdmin) } // Set params params := types.DefaultParams() err := s.app.AppKeepers.ClockKeeper.SetParams(s.ctx, params) s.Require().NoError(err) // Try to register all contracts res, err := s.clockMsgServer.UnjailClockContract(s.ctx, &types.MsgUnjailClockContract{ SenderAddress: tc.sender, ContractAddress: tc.contract, }) if !tc.success { s.Require().Error(err) } else { s.Require().NoError(err) s.Require().Equal(res, &types.MsgUnjailClockContractResponse{}) } // Ensure contract is unregistered s.app.AppKeepers.ClockKeeper.RemoveContract(s.ctx, contractAddress) s.app.AppKeepers.ClockKeeper.RemoveContract(s.ctx, contractAddressWithAdmin) }) } } ================================================ FILE: x/clock/keeper/querier.go ================================================ package keeper import ( "context" sdk "github.com/cosmos/cosmos-sdk/types" globalerrors "github.com/cybercongress/go-cyber/v7/app/helpers" "github.com/cybercongress/go-cyber/v7/x/clock/types" ) var _ types.QueryServer = &Querier{} type Querier struct { keeper Keeper } func NewQuerier(k Keeper) Querier { return Querier{ keeper: k, } } // ContractModules returns contract addresses which are using the clock func (q Querier) ClockContracts(stdCtx context.Context, req *types.QueryClockContracts) (*types.QueryClockContractsResponse, error) { ctx := sdk.UnwrapSDKContext(stdCtx) contracts, err := q.keeper.GetPaginatedContracts(ctx, req.Pagination) if err != nil { return nil, err } return contracts, nil } // ClockContract returns the clock contract information func (q Querier) ClockContract(stdCtx context.Context, req *types.QueryClockContract) (*types.QueryClockContractResponse, error) { ctx := sdk.UnwrapSDKContext(stdCtx) // Ensure the contract address is valid if _, err := sdk.AccAddressFromBech32(req.ContractAddress); err != nil { return nil, globalerrors.ErrInvalidAddress } contract, err := q.keeper.GetClockContract(ctx, req.ContractAddress) if err != nil { return nil, err } return &types.QueryClockContractResponse{ ClockContract: *contract, }, nil } // Params returns the total set of clock parameters. func (q Querier) Params(stdCtx context.Context, _ *types.QueryParamsRequest) (*types.QueryParamsResponse, error) { ctx := sdk.UnwrapSDKContext(stdCtx) p := q.keeper.GetParams(ctx) return &types.QueryParamsResponse{ Params: &p, }, nil } ================================================ FILE: x/clock/keeper/querier_test.go ================================================ package keeper_test import ( "github.com/cosmos/cosmos-sdk/testutil/testdata" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/clock/types" ) // Query Clock Params func (s *IntegrationTestSuite) TestQueryClockParams() { for _, tc := range []struct { desc string params types.Params }{ { desc: "On default", params: types.DefaultParams(), }, { desc: "On 500_000", params: types.Params{ ContractGasLimit: 500_000, }, }, { desc: "On 1_000_000", params: types.Params{ ContractGasLimit: 1_000_000, }, }, } { tc := tc s.Run(tc.desc, func() { // Set params err := s.app.AppKeepers.ClockKeeper.SetParams(s.ctx, tc.params) s.Require().NoError(err) // Query params goCtx := sdk.WrapSDKContext(s.ctx) resp, err := s.queryClient.Params(goCtx, &types.QueryParamsRequest{}) // Response check s.Require().NoError(err) s.Require().NotNil(resp) s.Require().Equal(tc.params, *resp.Params) }) } } // Query Clock Contracts func (s *IntegrationTestSuite) TestQueryClockContracts() { _, _, addr := testdata.KeyTestPubAddr() _ = s.FundAccount(s.ctx, addr, sdk.NewCoins(sdk.NewCoin("stake", sdk.NewInt(1_000_000)))) s.StoreCode() for _, tc := range []struct { desc string contracts []string }{ { desc: "On empty", contracts: []string(nil), }, { desc: "On Single", contracts: []string{ s.InstantiateContract(addr.String(), ""), }, }, { desc: "On Multiple", contracts: []string{ s.InstantiateContract(addr.String(), ""), s.InstantiateContract(addr.String(), ""), s.InstantiateContract(addr.String(), ""), }, }, } { tc := tc s.Run(tc.desc, func() { // Loop through contracts & register for _, contract := range tc.contracts { s.RegisterClockContract(addr.String(), contract) } // Contracts check goCtx := sdk.WrapSDKContext(s.ctx) resp, err := s.queryClient.ClockContracts(goCtx, &types.QueryClockContracts{}) // Response check s.Require().NoError(err) s.Require().NotNil(resp) for _, contract := range resp.ClockContracts { s.Require().Contains(tc.contracts, contract.ContractAddress) s.Require().False(contract.IsJailed) } // Remove all contracts for _, contract := range tc.contracts { s.app.AppKeepers.ClockKeeper.RemoveContract(s.ctx, contract) } }) } } // Query Jailed Clock Contracts func (s *IntegrationTestSuite) TestQueryJailedClockContracts() { _, _, addr := testdata.KeyTestPubAddr() _ = s.FundAccount(s.ctx, addr, sdk.NewCoins(sdk.NewCoin("stake", sdk.NewInt(1_000_000)))) s.StoreCode() for _, tc := range []struct { desc string contracts []string }{ { desc: "On empty", contracts: []string(nil), }, { desc: "On Single", contracts: []string{ s.InstantiateContract(addr.String(), ""), }, }, { desc: "On Multiple", contracts: []string{ s.InstantiateContract(addr.String(), ""), s.InstantiateContract(addr.String(), ""), s.InstantiateContract(addr.String(), ""), }, }, } { tc := tc s.Run(tc.desc, func() { // Loop through contracts & register for _, contract := range tc.contracts { s.RegisterClockContract(addr.String(), contract) s.JailClockContract(contract) } // Contracts check goCtx := sdk.WrapSDKContext(s.ctx) resp, err := s.queryClient.ClockContracts(goCtx, &types.QueryClockContracts{}) // Response check s.Require().NoError(err) s.Require().NotNil(resp) for _, contract := range resp.ClockContracts { s.Require().Contains(tc.contracts, contract.ContractAddress) s.Require().True(contract.IsJailed) } // Remove all contracts for _, contract := range tc.contracts { s.app.AppKeepers.ClockKeeper.RemoveContract(s.ctx, contract) } }) } } // Query Clock Contract func (s *IntegrationTestSuite) TestQueryClockContract() { _, _, addr := testdata.KeyTestPubAddr() _ = s.FundAccount(s.ctx, addr, sdk.NewCoins(sdk.NewCoin("stake", sdk.NewInt(1_000_000)))) _, _, invalidAddr := testdata.KeyTestPubAddr() s.StoreCode() unjailedContract := s.InstantiateContract(addr.String(), "") _ = s.app.AppKeepers.ClockKeeper.SetClockContract(s.ctx, types.ClockContract{ ContractAddress: unjailedContract, IsJailed: false, }) jailedContract := s.InstantiateContract(addr.String(), "") _ = s.app.AppKeepers.ClockKeeper.SetClockContract(s.ctx, types.ClockContract{ ContractAddress: jailedContract, IsJailed: true, }) for _, tc := range []struct { desc string contract string isJailed bool success bool }{ { desc: "On Unjailed", contract: unjailedContract, isJailed: false, success: true, }, { desc: "On Jailed", contract: jailedContract, isJailed: true, success: true, }, { desc: "Invalid Contract - Unjailed", contract: invalidAddr.String(), isJailed: false, success: false, }, { desc: "Invalid Contract - Jailed", contract: invalidAddr.String(), isJailed: true, success: false, }, } { tc := tc s.Run(tc.desc, func() { // Query contract resp, err := s.queryClient.ClockContract(s.ctx, &types.QueryClockContract{ ContractAddress: tc.contract, }) // Validate responses if tc.success { s.Require().NoError(err) s.Require().Equal(resp.ClockContract.ContractAddress, tc.contract) s.Require().Equal(resp.ClockContract.IsJailed, tc.isJailed) } else { s.Require().Error(err) } }) } } ================================================ FILE: x/clock/module.go ================================================ package clock import ( "context" "encoding/json" "github.com/gorilla/mux" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/spf13/cobra" abci "github.com/cometbft/cometbft/abci/types" errorsmod "cosmossdk.io/errors" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/codec" codectypes "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" "github.com/cybercongress/go-cyber/v7/x/clock/client/cli" "github.com/cybercongress/go-cyber/v7/x/clock/keeper" "github.com/cybercongress/go-cyber/v7/x/clock/types" ) const ( ModuleName = types.ModuleName // ConsensusVersion defines the current x/clock module consensus version. ConsensusVersion = 1 ) var ( _ module.AppModuleBasic = AppModuleBasic{} _ module.AppModuleGenesis = AppModule{} _ module.AppModule = AppModule{} ) // AppModuleBasic defines the basic application module used by the wasm module. type AppModuleBasic struct { cdc codec.Codec } func (a AppModuleBasic) Name() string { return types.ModuleName } func (a AppModuleBasic) DefaultGenesis(cdc codec.JSONCodec) json.RawMessage { return cdc.MustMarshalJSON(&types.GenesisState{ Params: types.DefaultParams(), }) } func (a AppModuleBasic) ValidateGenesis(marshaler codec.JSONCodec, _ client.TxEncodingConfig, message json.RawMessage) error { var data types.GenesisState err := marshaler.UnmarshalJSON(message, &data) if err != nil { return err } if err := data.Params.Validate(); err != nil { return errorsmod.Wrap(err, "params") } return nil } func (a AppModuleBasic) RegisterRESTRoutes(_ client.Context, _ *mux.Router) { } func (a AppModuleBasic) RegisterGRPCGatewayRoutes(clientCtx client.Context, mux *runtime.ServeMux) { err := types.RegisterQueryHandlerClient(context.Background(), mux, types.NewQueryClient(clientCtx)) if err != nil { // same behavior as in cosmos-sdk panic(err) } } func (a AppModuleBasic) GetTxCmd() *cobra.Command { return cli.NewTxCmd() } func (a AppModuleBasic) GetQueryCmd() *cobra.Command { return cli.GetQueryCmd() } func (AppModuleBasic) RegisterLegacyAminoCodec(cdc *codec.LegacyAmino) { types.RegisterLegacyAminoCodec(cdc) } func (a AppModuleBasic) RegisterInterfaces(r codectypes.InterfaceRegistry) { types.RegisterInterfaces(r) } type AppModule struct { AppModuleBasic keeper keeper.Keeper } // NewAppModule constructor func NewAppModule( cdc codec.Codec, keeper keeper.Keeper, ) *AppModule { return &AppModule{ AppModuleBasic: AppModuleBasic{cdc: cdc}, keeper: keeper, } } func (a AppModule) RegisterServices(cfg module.Configurator) { types.RegisterMsgServer(cfg.MsgServer(), keeper.NewMsgServerImpl(a.keeper)) types.RegisterQueryServer(cfg.QueryServer(), keeper.NewQuerier(a.keeper)) } func (a AppModule) RegisterInvariants(_ sdk.InvariantRegistry) { } func (a AppModule) InitGenesis(ctx sdk.Context, marshaler codec.JSONCodec, message json.RawMessage) []abci.ValidatorUpdate { var genesisState types.GenesisState marshaler.MustUnmarshalJSON(message, &genesisState) _ = a.keeper.SetParams(ctx, genesisState.Params) return nil } func (a AppModule) ExportGenesis(ctx sdk.Context, marshaler codec.JSONCodec) json.RawMessage { genState := ExportGenesis(ctx, a.keeper) return marshaler.MustMarshalJSON(genState) } // ConsensusVersion is a sequence number for state-breaking change of the // module. It should be incremented on each consensus-breaking change // introduced by the module. To avoid wrong/empty versions, the initial version // should be set to 1. func (a AppModule) ConsensusVersion() uint64 { return ConsensusVersion } func (a AppModule) BeginBlock(ctx sdk.Context, _ abci.RequestBeginBlock) { BeginBlocker(ctx, a.keeper) } func (a AppModule) EndBlock(ctx sdk.Context, _ abci.RequestEndBlock) []abci.ValidatorUpdate { EndBlocker(ctx, a.keeper) return nil } // IsOnePerModuleType implements the depinject.OnePerModuleType interface. func (am AppModule) IsOnePerModuleType() {} // IsAppModule implements the appmodule.AppModule interface. func (am AppModule) IsAppModule() {} ================================================ FILE: x/clock/spec/01_concepts.md ================================================ # Concepts ## Clock The Clock module allows registered contracts to be executed at the start and the end of every block. This allows the smart contract to perform regular and routine actions without the need for external bots. Developers can setup their contract with x/Clock by registering their contract with the module. Once registered, the contract will be executed at the end of every block. If the contract throws an error during execution or exceeds the gas limit defined in the module's parameters, the contract will be jailed and no longer executed. The contract can be unjailed by the contract admin. ## Registering a Contract Register a contract with x/Clock by executing the following transaction: ```bash cyber tx clock register [contract_address] ``` > Note: the sender of this transaction must be the contract admin, if exists, or else the contract creator. The `contract_address` is the bech32 address of the contract to be executed at the end of every block. Once registered, the contract will be executed at the end of every block. Please ensure that your contract follows the guidelines outlined in [Integration](03_integration.md). ## Unjailing a Contract A contract can be unjailed by executing the following transaction: ```bash cyber tx clock unjail [contract_address] ``` > Note: the sender of this transaction must be the contract admin, if exists, or else the contract creator. The `contract_address` is the bech32 address of the contract to be unjailed. Unjailing a contract will allow it to be executed at the end of every block. If your contract becomes jailed, please see [Integration](03_integration.md) to ensure the contract is setup with a Sudo message. ## Unregistering a Contract A contract can be unregistered by executing the following transaction: ```bash cyber tx clock unregister [contract_address] ``` > Note: the sender of this transaction must be the contract admin, if exists, or else the contract creator. The `contract_address` is the bech32 address of the contract to be unregistered. Unregistering a contract will remove it from the Clock module. This means that the contract will no longer be executed at the end of every block. ================================================ FILE: x/clock/spec/02_state.md ================================================ # State ## State Objects The `x/clock` module only manages the following object in state: ClockContract. This object is used to store the address of the contract and its jail status. The jail status is used to determine if the contract should be executed at the end of every block. If the contract is jailed, it will not be executed. ```go // This object is used to store the contract address and the // jail status of the contract. message ClockContract { // The address of the contract. string contract_address = 1; // The jail status of the contract. bool is_jailed = 2; } ``` ## Genesis & Params The `x/clock` module's `GenesisState` defines the state necessary for initializing the chain from a previously exported height. It simply contains the gas limit parameter which is used to determine the maximum amount of gas that can be used by a contract. This value can be modified with a governance proposal. ```go // GenesisState - initial state of module message GenesisState { // Params of this module Params params = 1 [ (gogoproto.nullable) = false, (gogoproto.jsontag) = "params,omitempty" ]; } // Params defines the set of module parameters. message Params { // contract_gas_limit defines the maximum amount of gas that can be used by a contract. uint64 contract_gas_limit = 1 [ (gogoproto.jsontag) = "contract_gas_limit,omitempty", (gogoproto.moretags) = "yaml:\"contract_gas_limit\"" ]; } ``` ## State Transitions The following state transitions are possible: - Register a contract creates a new ClockContract object in state. - Jailing a contract updates the is_jailed field of a ClockContract object in state. - Unjailing a contract updates the is_jailed field of a ClockContract object in state. - Unregister a contract deletes a ClockContract object from state. ================================================ FILE: x/clock/spec/03_integration.md ================================================ # CosmWasm Integration This `x/clock` module does not require any custom bindings. Rather, you must add a Sudo message to your contract. If your contract does not implement this Sudo message, it will be jailed. Please review the following sections below for more information. > Note: you can find a basic [cw-clock contract here](https://github.com/Reecepbcups/cw-clock-example). ## Implementation To satisfy the module's requirements, add the following message and entry point to your contract: ```rust // msg.rs #[cw_serde] pub enum SudoMsg { BeginBlock { }, EndBlock { }, } // contract.rs #[cfg_attr(not(feature = "library"), entry_point)] pub fn sudo(deps: DepsMut, _env: Env, msg: SudoMsg) -> Result { match msg { SudoMsg::BeginBlock { } => {} SudoMsg::EndBlock { } => { // TODO: PERFORM LOGIC HERE Ok(Response::new()) } } } ``` At the end of every block, registered contracts will execute the `ClockEndBlock` Sudo message. This is where all of the contract's custom end block logic can be performed. Please keep in mind that contracts which exceed the gas limit specified in the params will be jailed. ## Examples In the example below, at the end of every block the `val` Config variable will increase by 1. This is a simple example, but one can extrapolate upon this idea and perform actions such as cleanup, auto compounding, etc. ```rust // msg.rs #[cw_serde] pub enum SudoMsg { BeginBlock { }, EndBlock { }, } // contract.rs #[cfg_attr(not(feature = "library"), entry_point)] pub fn sudo(deps: DepsMut, _env: Env, msg: SudoMsg) -> Result { match msg { SudoMsg::BeginBlock { } => {} SudoMsg::EndBlock { } => { let mut config = CONFIG.load(deps.storage)?; config.val += 1; CONFIG.save(deps.storage, &config)?; Ok(Response::new()) } } } ``` To perform an action occasionally rather than every block, use the `env` variable in the Sudo message to check the block height and then perform logic accordingly. The contract below will only increase the `val` Config variable by 1 if the block height is divisible by 10. ```rust // msg.rs #[cw_serde] pub enum SudoMsg { BeginBlock { }, EndBlock { }, } // contract.rs #[cfg_attr(not(feature = "library"), entry_point)] pub fn sudo(deps: DepsMut, env: Env, msg: SudoMsg) -> Result { match msg { SudoMsg::BeginBlock { } => {} SudoMsg::EndBlock { } => { // If the block is not divisible by ten, do nothing. if env.block.height % 10 != 0 { return Ok(Response::new()); } let mut config = CONFIG.load(deps.storage)?; config.val += 1; CONFIG.save(deps.storage, &config)?; Ok(Response::new()) } } } ``` ================================================ FILE: x/clock/spec/04_clients.md ================================================ # Clients ## Command Line Interface (CLI) The CLI has been updated with new queries and transactions for the `x/clock` module. View the entire list below. ### Queries | Command | Subcommand | Arguments | Description | |:--------------------| :---------- | :----------------- | :---------------------- | | `cyber query clock` | `params` | | Get Clock params | | `cyber query clock` | `contract` | [contract_address] | Get a Clock contract | | `cyber query clock` | `contracts` | | Get all Clock contracts | ### Transactions | Command | Subcommand | Arguments | Description | |:-----------------| :----------- | :----------------- | :-------------------------- | | `cyber tx clock` | `register` | [contract_address] | Register a Clock contract | | `cyber tx clock` | `unjail` | [contract_address] | Unjail a Clock contract | | `cyber tx clock` | `unregister` | [contract_address] | Unregister a Clock contract | ================================================ FILE: x/clock/spec/README.md ================================================ # `clock` ```text Thanks to Juno and Tgrade teams for the initial development of this module. This module is based on Juno clock's module implementation with few modifications: 1. Added support for ABCI BeginBlocker 2. TODO: Add support for gas limit for each contract ``` ## Abstract This document specifies the internal `x/clock` module of cyber-sdk based networks. The `x/clock` module allows specific contracts to be executed at the end of every block. This allows the smart contract to perform actions that may need to happen every block or at set block intervals. By using this module, your application can remove the headache of external whitelisted bots and instead depend on the chain itself for constant executions. ## Contents 1. **[Concepts](01_concepts.md)** 2. **[State](02_state.md)** 3. **[Contract Integration](03_integration.md)** 4. **[Clients](04_clients.md)** ================================================ FILE: x/clock/types/clock.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: cyber/clock/v1/clock.proto package types import ( fmt "fmt" proto "github.com/cosmos/gogoproto/proto" io "io" math "math" math_bits "math/bits" ) // Reference imports to suppress errors if they are not otherwise used. var _ = proto.Marshal var _ = fmt.Errorf var _ = math.Inf // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package // This object is used to store the contract address and the // jail status of the contract. type ClockContract struct { // The address of the contract. ContractAddress string `protobuf:"bytes,1,opt,name=contract_address,json=contractAddress,proto3" json:"contract_address,omitempty"` // The jail status of the contract. IsJailed bool `protobuf:"varint,2,opt,name=is_jailed,json=isJailed,proto3" json:"is_jailed,omitempty"` } func (m *ClockContract) Reset() { *m = ClockContract{} } func (m *ClockContract) String() string { return proto.CompactTextString(m) } func (*ClockContract) ProtoMessage() {} func (*ClockContract) Descriptor() ([]byte, []int) { return fileDescriptor_790af3b737cb20eb, []int{0} } func (m *ClockContract) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *ClockContract) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_ClockContract.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *ClockContract) XXX_Merge(src proto.Message) { xxx_messageInfo_ClockContract.Merge(m, src) } func (m *ClockContract) XXX_Size() int { return m.Size() } func (m *ClockContract) XXX_DiscardUnknown() { xxx_messageInfo_ClockContract.DiscardUnknown(m) } var xxx_messageInfo_ClockContract proto.InternalMessageInfo func (m *ClockContract) GetContractAddress() string { if m != nil { return m.ContractAddress } return "" } func (m *ClockContract) GetIsJailed() bool { if m != nil { return m.IsJailed } return false } func init() { proto.RegisterType((*ClockContract)(nil), "cyber.clock.v1.ClockContract") } func init() { proto.RegisterFile("cyber/clock/v1/clock.proto", fileDescriptor_790af3b737cb20eb) } var fileDescriptor_790af3b737cb20eb = []byte{ // 193 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0x4a, 0xae, 0x4c, 0x4a, 0x2d, 0xd2, 0x4f, 0xce, 0xc9, 0x4f, 0xce, 0xd6, 0x2f, 0x33, 0x84, 0x30, 0xf4, 0x0a, 0x8a, 0xf2, 0x4b, 0xf2, 0x85, 0xf8, 0xc0, 0x72, 0x7a, 0x10, 0xa1, 0x32, 0x43, 0xa5, 0x70, 0x2e, 0x5e, 0x67, 0x10, 0xdb, 0x39, 0x3f, 0xaf, 0xa4, 0x28, 0x31, 0xb9, 0x44, 0x48, 0x93, 0x4b, 0x20, 0x19, 0xca, 0x8e, 0x4f, 0x4c, 0x49, 0x29, 0x4a, 0x2d, 0x2e, 0x96, 0x60, 0x54, 0x60, 0xd4, 0xe0, 0x0c, 0xe2, 0x87, 0x89, 0x3b, 0x42, 0x84, 0x85, 0xa4, 0xb9, 0x38, 0x33, 0x8b, 0xe3, 0xb3, 0x12, 0x33, 0x73, 0x52, 0x53, 0x24, 0x98, 0x14, 0x18, 0x35, 0x38, 0x82, 0x38, 0x32, 0x8b, 0xbd, 0xc0, 0x7c, 0x27, 0xcf, 0x13, 0x8f, 0xe4, 0x18, 0x2f, 0x3c, 0x92, 0x63, 0x7c, 0xf0, 0x48, 0x8e, 0x71, 0xc2, 0x63, 0x39, 0x86, 0x0b, 0x8f, 0xe5, 0x18, 0x6e, 0x3c, 0x96, 0x63, 0x88, 0xd2, 0x4f, 0xcf, 0x2c, 0xc9, 0x28, 0x4d, 0xd2, 0x4b, 0xce, 0xcf, 0xd5, 0x07, 0xbb, 0x26, 0x39, 0x3f, 0x2f, 0x1d, 0x64, 0xa0, 0x7e, 0x7a, 0xbe, 0x2e, 0xc4, 0xe9, 0x15, 0x50, 0xc7, 0x97, 0x54, 0x16, 0xa4, 0x16, 0x27, 0xb1, 0x81, 0x9d, 0x6e, 0x0c, 0x08, 0x00, 0x00, 0xff, 0xff, 0x19, 0x17, 0xde, 0x92, 0xd8, 0x00, 0x00, 0x00, } func (m *ClockContract) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *ClockContract) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *ClockContract) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.IsJailed { i-- if m.IsJailed { dAtA[i] = 1 } else { dAtA[i] = 0 } i-- dAtA[i] = 0x10 } if len(m.ContractAddress) > 0 { i -= len(m.ContractAddress) copy(dAtA[i:], m.ContractAddress) i = encodeVarintClock(dAtA, i, uint64(len(m.ContractAddress))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func encodeVarintClock(dAtA []byte, offset int, v uint64) int { offset -= sovClock(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *ClockContract) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.ContractAddress) if l > 0 { n += 1 + l + sovClock(uint64(l)) } if m.IsJailed { n += 2 } return n } func sovClock(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozClock(x uint64) (n int) { return sovClock(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *ClockContract) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowClock } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: ClockContract: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: ClockContract: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field ContractAddress", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowClock } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthClock } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthClock } if postIndex > l { return io.ErrUnexpectedEOF } m.ContractAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field IsJailed", wireType) } var v int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowClock } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ v |= int(b&0x7F) << shift if b < 0x80 { break } } m.IsJailed = bool(v != 0) default: iNdEx = preIndex skippy, err := skipClock(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthClock } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipClock(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowClock } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowClock } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowClock } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthClock } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupClock } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthClock } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthClock = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowClock = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupClock = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/clock/types/codec.go ================================================ package types import ( "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/codec/types" cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/msgservice" authzcodec "github.com/cosmos/cosmos-sdk/x/authz/codec" govcodec "github.com/cosmos/cosmos-sdk/x/gov/codec" ) var ( amino = codec.NewLegacyAmino() AminoCdc = codec.NewAminoCodec(amino) ) func init() { RegisterLegacyAminoCodec(amino) cryptocodec.RegisterCrypto(amino) sdk.RegisterLegacyAminoCodec(amino) // Register all Amino interfaces and concrete types on the authz and gov Amino codec // so that this can later be used to properly serialize MsgGrant and MsgExec // instances. RegisterLegacyAminoCodec(authzcodec.Amino) RegisterLegacyAminoCodec(govcodec.Amino) } // RegisterLegacyAminoCodec registers concrete types on the LegacyAmino codec func RegisterLegacyAminoCodec(cdc *codec.LegacyAmino) { cdc.RegisterConcrete(&MsgRegisterClockContract{}, "clock/MsgRegisterClockContract", nil) cdc.RegisterConcrete(&MsgUnregisterClockContract{}, "clock/MsgUnregisterClockContract", nil) cdc.RegisterConcrete(&MsgUnjailClockContract{}, "clock/MsgUnjailClockContract", nil) cdc.RegisterConcrete(&MsgUpdateParams{}, "clock/MsgUpdateParams", nil) } func RegisterInterfaces(registry types.InterfaceRegistry) { registry.RegisterImplementations( (*sdk.Msg)(nil), &MsgRegisterClockContract{}, &MsgUnregisterClockContract{}, &MsgUnjailClockContract{}, &MsgUpdateParams{}, ) msgservice.RegisterMsgServiceDesc(registry, &_Msg_serviceDesc) } ================================================ FILE: x/clock/types/codec_test.go ================================================ package types import ( "testing" "github.com/stretchr/testify/suite" codectypes "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" ) type CodecTestSuite struct { suite.Suite } func TestCodecSuite(t *testing.T) { suite.Run(t, new(CodecTestSuite)) } func (suite *CodecTestSuite) TestRegisterInterfaces() { registry := codectypes.NewInterfaceRegistry() registry.RegisterInterface(sdk.MsgInterfaceProtoName, (*sdk.Msg)(nil)) RegisterInterfaces(registry) impls := registry.ListImplementations(sdk.MsgInterfaceProtoName) suite.Require().Equal(4, len(impls)) suite.Require().ElementsMatch([]string{ "/cyber.clock.v1.MsgUpdateParams", "/cyber.clock.v1.MsgRegisterClockContract", "/cyber.clock.v1.MsgUnregisterClockContract", "/cyber.clock.v1.MsgUnjailClockContract", }, impls) } ================================================ FILE: x/clock/types/errors.go ================================================ package types import ( errorsmod "cosmossdk.io/errors" ) var ( ErrContractJailed = errorsmod.Register(ModuleName, 1, "contract is jailed") ErrContractNotJailed = errorsmod.Register(ModuleName, 2, "contract is not jailed") ErrContractAlreadyJailed = errorsmod.Register(ModuleName, 3, "contract is already jailed") ) ================================================ FILE: x/clock/types/genesis.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: cyber/clock/v1/genesis.proto package types import ( fmt "fmt" _ "github.com/cosmos/gogoproto/gogoproto" proto "github.com/cosmos/gogoproto/proto" io "io" math "math" math_bits "math/bits" ) // Reference imports to suppress errors if they are not otherwise used. var _ = proto.Marshal var _ = fmt.Errorf var _ = math.Inf // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package // GenesisState - initial state of module type GenesisState struct { // Params of this module Params Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params,omitempty"` } func (m *GenesisState) Reset() { *m = GenesisState{} } func (m *GenesisState) String() string { return proto.CompactTextString(m) } func (*GenesisState) ProtoMessage() {} func (*GenesisState) Descriptor() ([]byte, []int) { return fileDescriptor_5e684cf0c154fcd7, []int{0} } func (m *GenesisState) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *GenesisState) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_GenesisState.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *GenesisState) XXX_Merge(src proto.Message) { xxx_messageInfo_GenesisState.Merge(m, src) } func (m *GenesisState) XXX_Size() int { return m.Size() } func (m *GenesisState) XXX_DiscardUnknown() { xxx_messageInfo_GenesisState.DiscardUnknown(m) } var xxx_messageInfo_GenesisState proto.InternalMessageInfo func (m *GenesisState) GetParams() Params { if m != nil { return m.Params } return Params{} } // Params defines the set of module parameters. type Params struct { // contract_gas_limit defines the maximum amount of gas that can be used by a // contract. ContractGasLimit uint64 `protobuf:"varint,1,opt,name=contract_gas_limit,json=contractGasLimit,proto3" json:"contract_gas_limit,omitempty" yaml:"contract_gas_limit"` } func (m *Params) Reset() { *m = Params{} } func (m *Params) String() string { return proto.CompactTextString(m) } func (*Params) ProtoMessage() {} func (*Params) Descriptor() ([]byte, []int) { return fileDescriptor_5e684cf0c154fcd7, []int{1} } func (m *Params) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *Params) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_Params.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *Params) XXX_Merge(src proto.Message) { xxx_messageInfo_Params.Merge(m, src) } func (m *Params) XXX_Size() int { return m.Size() } func (m *Params) XXX_DiscardUnknown() { xxx_messageInfo_Params.DiscardUnknown(m) } var xxx_messageInfo_Params proto.InternalMessageInfo func (m *Params) GetContractGasLimit() uint64 { if m != nil { return m.ContractGasLimit } return 0 } func init() { proto.RegisterType((*GenesisState)(nil), "cyber.clock.v1.GenesisState") proto.RegisterType((*Params)(nil), "cyber.clock.v1.Params") } func init() { proto.RegisterFile("cyber/clock/v1/genesis.proto", fileDescriptor_5e684cf0c154fcd7) } var fileDescriptor_5e684cf0c154fcd7 = []byte{ // 275 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0x49, 0xae, 0x4c, 0x4a, 0x2d, 0xd2, 0x4f, 0xce, 0xc9, 0x4f, 0xce, 0xd6, 0x2f, 0x33, 0xd4, 0x4f, 0x4f, 0xcd, 0x4b, 0x2d, 0xce, 0x2c, 0xd6, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0xe2, 0x03, 0xcb, 0xea, 0x81, 0x65, 0xf5, 0xca, 0x0c, 0xa5, 0x44, 0xd2, 0xf3, 0xd3, 0xf3, 0xc1, 0x52, 0xfa, 0x20, 0x16, 0x44, 0x95, 0x52, 0x04, 0x17, 0x8f, 0x3b, 0x44, 0x5b, 0x70, 0x49, 0x62, 0x49, 0xaa, 0x90, 0x07, 0x17, 0x5b, 0x41, 0x62, 0x51, 0x62, 0x6e, 0xb1, 0x04, 0xa3, 0x02, 0xa3, 0x06, 0xb7, 0x91, 0x98, 0x1e, 0xaa, 0x31, 0x7a, 0x01, 0x60, 0x59, 0x27, 0x89, 0x13, 0xf7, 0xe4, 0x19, 0x5e, 0xdd, 0x93, 0x17, 0x80, 0xa8, 0xd6, 0xc9, 0xcf, 0xcd, 0x2c, 0x49, 0xcd, 0x2d, 0x28, 0xa9, 0x0c, 0x82, 0xea, 0x57, 0x2a, 0xe5, 0x62, 0x83, 0xa8, 0x15, 0xca, 0xe6, 0x12, 0x4a, 0xce, 0xcf, 0x2b, 0x29, 0x4a, 0x4c, 0x2e, 0x89, 0x4f, 0x4f, 0x2c, 0x8e, 0xcf, 0xc9, 0xcc, 0xcd, 0x2c, 0x01, 0x9b, 0xcf, 0xe2, 0x64, 0xfb, 0xea, 0x9e, 0xbc, 0x0c, 0xa6, 0x2c, 0xc2, 0xbc, 0x4f, 0xf7, 0xe4, 0x25, 0x2b, 0x13, 0x73, 0x73, 0xac, 0x94, 0x30, 0x55, 0x29, 0x05, 0x09, 0xc0, 0x04, 0xdd, 0x13, 0x8b, 0x7d, 0x40, 0x42, 0x4e, 0x9e, 0x27, 0x1e, 0xc9, 0x31, 0x5e, 0x78, 0x24, 0xc7, 0xf8, 0xe0, 0x91, 0x1c, 0xe3, 0x84, 0xc7, 0x72, 0x0c, 0x17, 0x1e, 0xcb, 0x31, 0xdc, 0x78, 0x2c, 0xc7, 0x10, 0xa5, 0x9f, 0x9e, 0x59, 0x92, 0x51, 0x9a, 0xa4, 0x97, 0x9c, 0x9f, 0xab, 0x0f, 0xf6, 0x54, 0x72, 0x7e, 0x5e, 0x7a, 0x51, 0x6a, 0x71, 0xb1, 0x7e, 0x7a, 0xbe, 0x2e, 0x24, 0x28, 0x2b, 0xa0, 0x81, 0x59, 0x52, 0x59, 0x90, 0x5a, 0x9c, 0xc4, 0x06, 0x0e, 0x22, 0x63, 0x40, 0x00, 0x00, 0x00, 0xff, 0xff, 0x2f, 0x65, 0x95, 0x9e, 0x68, 0x01, 0x00, 0x00, } func (m *GenesisState) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *GenesisState) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *GenesisState) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.Params.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintGenesis(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa return len(dAtA) - i, nil } func (m *Params) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *Params) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *Params) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.ContractGasLimit != 0 { i = encodeVarintGenesis(dAtA, i, uint64(m.ContractGasLimit)) i-- dAtA[i] = 0x8 } return len(dAtA) - i, nil } func encodeVarintGenesis(dAtA []byte, offset int, v uint64) int { offset -= sovGenesis(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *GenesisState) Size() (n int) { if m == nil { return 0 } var l int _ = l l = m.Params.Size() n += 1 + l + sovGenesis(uint64(l)) return n } func (m *Params) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.ContractGasLimit != 0 { n += 1 + sovGenesis(uint64(m.ContractGasLimit)) } return n } func sovGenesis(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozGenesis(x uint64) (n int) { return sovGenesis(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *GenesisState) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenesis } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: GenesisState: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: GenesisState: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenesis } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthGenesis } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenesis } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Params.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipGenesis(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthGenesis } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *Params) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenesis } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: Params: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: Params: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field ContractGasLimit", wireType) } m.ContractGasLimit = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenesis } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.ContractGasLimit |= uint64(b&0x7F) << shift if b < 0x80 { break } } default: iNdEx = preIndex skippy, err := skipGenesis(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthGenesis } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipGenesis(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowGenesis } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowGenesis } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowGenesis } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthGenesis } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupGenesis } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthGenesis } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthGenesis = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowGenesis = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupGenesis = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/clock/types/keys.go ================================================ package types var ParamsKey = []byte{0x00} const ( ModuleName = "clock" RouterKey = ModuleName StoreKey = ModuleName ) ================================================ FILE: x/clock/types/msgs.go ================================================ package types import ( "cosmossdk.io/errors" sdk "github.com/cosmos/cosmos-sdk/types" globalerrors "github.com/cybercongress/go-cyber/v7/app/helpers" ) const ( // Sudo Message called on the contracts BeginBlockSudoMessage = `{"clock_begin_block":{}}` EndBlockSudoMessage = `{"clock_end_block":{}}` ) // == MsgUpdateParams == const ( TypeMsgRegisterFeePayContract = "register_clock_contract" TypeMsgUnregisterFeePayContract = "unregister_clock_contract" TypeMsgUnjailFeePayContract = "unjail_clock_contract" TypeMsgUpdateParams = "update_clock_params" ) var ( _ sdk.Msg = &MsgRegisterClockContract{} _ sdk.Msg = &MsgUnregisterClockContract{} _ sdk.Msg = &MsgUnjailClockContract{} _ sdk.Msg = &MsgUpdateParams{} ) // Route returns the name of the module func (msg MsgRegisterClockContract) Route() string { return RouterKey } // Type returns the the action func (msg MsgRegisterClockContract) Type() string { return TypeMsgRegisterFeePayContract } // ValidateBasic runs stateless checks on the message func (msg MsgRegisterClockContract) ValidateBasic() error { return validateAddresses(msg.SenderAddress, msg.ContractAddress) } // GetSignBytes encodes the message for signing func (msg *MsgRegisterClockContract) GetSignBytes() []byte { return sdk.MustSortJSON(AminoCdc.MustMarshalJSON(msg)) } // GetSigners defines whose signature is required func (msg MsgRegisterClockContract) GetSigners() []sdk.AccAddress { from, _ := sdk.AccAddressFromBech32(msg.SenderAddress) return []sdk.AccAddress{from} } // Route returns the name of the module func (msg MsgUnregisterClockContract) Route() string { return RouterKey } // Type returns the the action func (msg MsgUnregisterClockContract) Type() string { return TypeMsgRegisterFeePayContract } // ValidateBasic runs stateless checks on the message func (msg MsgUnregisterClockContract) ValidateBasic() error { return validateAddresses(msg.SenderAddress, msg.ContractAddress) } // GetSignBytes encodes the message for signing func (msg *MsgUnregisterClockContract) GetSignBytes() []byte { return sdk.MustSortJSON(AminoCdc.MustMarshalJSON(msg)) } // GetSigners defines whose signature is required func (msg MsgUnregisterClockContract) GetSigners() []sdk.AccAddress { from, _ := sdk.AccAddressFromBech32(msg.SenderAddress) return []sdk.AccAddress{from} } // Route returns the name of the module func (msg MsgUnjailClockContract) Route() string { return RouterKey } // Type returns the the action func (msg MsgUnjailClockContract) Type() string { return TypeMsgRegisterFeePayContract } // ValidateBasic runs stateless checks on the message func (msg MsgUnjailClockContract) ValidateBasic() error { return validateAddresses(msg.SenderAddress, msg.ContractAddress) } // GetSignBytes encodes the message for signing func (msg *MsgUnjailClockContract) GetSignBytes() []byte { return sdk.MustSortJSON(AminoCdc.MustMarshalJSON(msg)) } // GetSigners defines whose signature is required func (msg MsgUnjailClockContract) GetSigners() []sdk.AccAddress { from, _ := sdk.AccAddressFromBech32(msg.SenderAddress) return []sdk.AccAddress{from} } // NewMsgUpdateParams creates new instance of MsgUpdateParams func NewMsgUpdateParams( sender sdk.Address, contractGasLimit uint64, ) *MsgUpdateParams { return &MsgUpdateParams{ Authority: sender.String(), Params: NewParams(contractGasLimit), } } // Route returns the name of the module func (msg MsgUpdateParams) Route() string { return RouterKey } // Type returns the the action func (msg MsgUpdateParams) Type() string { return TypeMsgUpdateParams } // GetSignBytes implements the LegacyMsg interface. func (msg MsgUpdateParams) GetSignBytes() []byte { return sdk.MustSortJSON(AminoCdc.MustMarshalJSON(&msg)) } // GetSigners returns the expected signers for a MsgUpdateParams message. func (msg *MsgUpdateParams) GetSigners() []sdk.AccAddress { addr, _ := sdk.AccAddressFromBech32(msg.Authority) return []sdk.AccAddress{addr} } // ValidateBasic does a sanity check on the provided data. func (msg *MsgUpdateParams) ValidateBasic() error { if _, err := sdk.AccAddressFromBech32(msg.Authority); err != nil { return errors.Wrap(err, "invalid authority address") } return msg.Params.Validate() } // ValidateAddresses validates the provided addresses func validateAddresses(addresses ...string) error { for _, address := range addresses { if _, err := sdk.AccAddressFromBech32(address); err != nil { return errors.Wrapf(globalerrors.ErrInvalidAddress, "invalid address: %s", address) } } return nil } ================================================ FILE: x/clock/types/msgs_test.go ================================================ package types import ( "testing" "github.com/stretchr/testify/suite" sdk "github.com/cosmos/cosmos-sdk/types" ) type MsgsTestSuite struct { suite.Suite govModule string } func TestMsgsTestSuite(t *testing.T) { suite.Run(t, new(MsgsTestSuite)) } func (suite *MsgsTestSuite) SetupTest() { suite.govModule = "juno10d07y265gmmuvt4z0w9aw880jnsr700jvss730" } func (suite *MsgsTestSuite) TestMsgUpdateParams() { var limit uint64 = 100_000 p := MsgUpdateParams{ Authority: suite.govModule, Params: Params{ ContractGasLimit: limit, }, } acc, _ := sdk.AccAddressFromBech32(p.Authority) msg := NewMsgUpdateParams(acc, limit) suite.Require().Equal(RouterKey, msg.Route()) suite.Require().Equal(TypeMsgUpdateParams, msg.Type()) suite.Require().NotNil(msg.GetSigners()) } ================================================ FILE: x/clock/types/params.go ================================================ package types import ( errorsmod "cosmossdk.io/errors" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" ) // DefaultParams returns default parameters func DefaultParams() Params { return Params{ ContractGasLimit: 100_000, } } // NewParams creates a new Params object func NewParams( contractGasLimit uint64, ) Params { return Params{ ContractGasLimit: contractGasLimit, } } // Validate performs basic validation. func (p Params) Validate() error { minimumGas := uint64(100_000) if p.ContractGasLimit < minimumGas { return errorsmod.Wrapf( sdkerrors.ErrInvalidRequest, "invalid contract gas limit: %d. Must be above %d", p.ContractGasLimit, minimumGas, ) } return nil } ================================================ FILE: x/clock/types/params_test.go ================================================ package types_test import ( "testing" "github.com/stretchr/testify/require" "github.com/cybercongress/go-cyber/v7/x/clock/types" ) func TestParamsValidate(t *testing.T) { testCases := []struct { name string params types.Params success bool }{ { "Success - Default", types.DefaultParams(), true, }, { "Success - Meets min Gas", types.NewParams(100_000), true, }, { "Success - Meets min Gas", types.NewParams(500_000), true, }, { "Fail - Not Enough Gas", types.NewParams(1), false, }, { "Fail - Not Enough Gas", types.NewParams(100), false, }, { "Fail - Not Enough Gas", types.NewParams(1_000), false, }, { "Fail - Not Enough Gas", types.NewParams(10_000), false, }, } for _, tc := range testCases { err := tc.params.Validate() if tc.success { require.NoError(t, err, tc.name) } else { require.Error(t, err, tc.name) } } } ================================================ FILE: x/clock/types/query.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: cyber/clock/v1/query.proto package types import ( context "context" fmt "fmt" query "github.com/cosmos/cosmos-sdk/types/query" _ "github.com/cosmos/gogoproto/gogoproto" grpc1 "github.com/cosmos/gogoproto/grpc" proto "github.com/cosmos/gogoproto/proto" _ "google.golang.org/genproto/googleapis/api/annotations" grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" io "io" math "math" math_bits "math/bits" ) // Reference imports to suppress errors if they are not otherwise used. var _ = proto.Marshal var _ = fmt.Errorf var _ = math.Inf // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package // QueryClockContracts is the request type to get all contracts. type QueryClockContracts struct { // pagination defines an optional pagination for the request. Pagination *query.PageRequest `protobuf:"bytes,1,opt,name=pagination,proto3" json:"pagination,omitempty"` } func (m *QueryClockContracts) Reset() { *m = QueryClockContracts{} } func (m *QueryClockContracts) String() string { return proto.CompactTextString(m) } func (*QueryClockContracts) ProtoMessage() {} func (*QueryClockContracts) Descriptor() ([]byte, []int) { return fileDescriptor_05444fcb6b1de94a, []int{0} } func (m *QueryClockContracts) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryClockContracts) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryClockContracts.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryClockContracts) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryClockContracts.Merge(m, src) } func (m *QueryClockContracts) XXX_Size() int { return m.Size() } func (m *QueryClockContracts) XXX_DiscardUnknown() { xxx_messageInfo_QueryClockContracts.DiscardUnknown(m) } var xxx_messageInfo_QueryClockContracts proto.InternalMessageInfo func (m *QueryClockContracts) GetPagination() *query.PageRequest { if m != nil { return m.Pagination } return nil } // QueryClockContractsResponse is the response type for the Query/ClockContracts // RPC method. type QueryClockContractsResponse struct { // clock_contracts are the clock contracts. ClockContracts []ClockContract `protobuf:"bytes,1,rep,name=clock_contracts,json=clockContracts,proto3" json:"clock_contracts"` // pagination defines the pagination in the response. Pagination *query.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` } func (m *QueryClockContractsResponse) Reset() { *m = QueryClockContractsResponse{} } func (m *QueryClockContractsResponse) String() string { return proto.CompactTextString(m) } func (*QueryClockContractsResponse) ProtoMessage() {} func (*QueryClockContractsResponse) Descriptor() ([]byte, []int) { return fileDescriptor_05444fcb6b1de94a, []int{1} } func (m *QueryClockContractsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryClockContractsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryClockContractsResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryClockContractsResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryClockContractsResponse.Merge(m, src) } func (m *QueryClockContractsResponse) XXX_Size() int { return m.Size() } func (m *QueryClockContractsResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryClockContractsResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryClockContractsResponse proto.InternalMessageInfo func (m *QueryClockContractsResponse) GetClockContracts() []ClockContract { if m != nil { return m.ClockContracts } return nil } func (m *QueryClockContractsResponse) GetPagination() *query.PageResponse { if m != nil { return m.Pagination } return nil } // QueryClockContract is the request type to get a single contract. type QueryClockContract struct { // contract_address is the address of the contract to query. ContractAddress string `protobuf:"bytes,1,opt,name=contract_address,json=contractAddress,proto3" json:"contract_address,omitempty"` } func (m *QueryClockContract) Reset() { *m = QueryClockContract{} } func (m *QueryClockContract) String() string { return proto.CompactTextString(m) } func (*QueryClockContract) ProtoMessage() {} func (*QueryClockContract) Descriptor() ([]byte, []int) { return fileDescriptor_05444fcb6b1de94a, []int{2} } func (m *QueryClockContract) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryClockContract) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryClockContract.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryClockContract) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryClockContract.Merge(m, src) } func (m *QueryClockContract) XXX_Size() int { return m.Size() } func (m *QueryClockContract) XXX_DiscardUnknown() { xxx_messageInfo_QueryClockContract.DiscardUnknown(m) } var xxx_messageInfo_QueryClockContract proto.InternalMessageInfo func (m *QueryClockContract) GetContractAddress() string { if m != nil { return m.ContractAddress } return "" } // QueryClockContractResponse is the response type for the Query/ClockContract // RPC method. type QueryClockContractResponse struct { // contract is the clock contract. ClockContract ClockContract `protobuf:"bytes,1,opt,name=clock_contract,json=clockContract,proto3" json:"clock_contract"` } func (m *QueryClockContractResponse) Reset() { *m = QueryClockContractResponse{} } func (m *QueryClockContractResponse) String() string { return proto.CompactTextString(m) } func (*QueryClockContractResponse) ProtoMessage() {} func (*QueryClockContractResponse) Descriptor() ([]byte, []int) { return fileDescriptor_05444fcb6b1de94a, []int{3} } func (m *QueryClockContractResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryClockContractResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryClockContractResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryClockContractResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryClockContractResponse.Merge(m, src) } func (m *QueryClockContractResponse) XXX_Size() int { return m.Size() } func (m *QueryClockContractResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryClockContractResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryClockContractResponse proto.InternalMessageInfo func (m *QueryClockContractResponse) GetClockContract() ClockContract { if m != nil { return m.ClockContract } return ClockContract{} } // QueryParams is the request type to get all module params. type QueryParamsRequest struct { } func (m *QueryParamsRequest) Reset() { *m = QueryParamsRequest{} } func (m *QueryParamsRequest) String() string { return proto.CompactTextString(m) } func (*QueryParamsRequest) ProtoMessage() {} func (*QueryParamsRequest) Descriptor() ([]byte, []int) { return fileDescriptor_05444fcb6b1de94a, []int{4} } func (m *QueryParamsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryParamsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryParamsRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryParamsRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryParamsRequest.Merge(m, src) } func (m *QueryParamsRequest) XXX_Size() int { return m.Size() } func (m *QueryParamsRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryParamsRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryParamsRequest proto.InternalMessageInfo // QueryClockContractsResponse is the response type for the Query/ClockContracts // RPC method. type QueryParamsResponse struct { Params *Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params" yaml:"params"` } func (m *QueryParamsResponse) Reset() { *m = QueryParamsResponse{} } func (m *QueryParamsResponse) String() string { return proto.CompactTextString(m) } func (*QueryParamsResponse) ProtoMessage() {} func (*QueryParamsResponse) Descriptor() ([]byte, []int) { return fileDescriptor_05444fcb6b1de94a, []int{5} } func (m *QueryParamsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryParamsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryParamsResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryParamsResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryParamsResponse.Merge(m, src) } func (m *QueryParamsResponse) XXX_Size() int { return m.Size() } func (m *QueryParamsResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryParamsResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryParamsResponse proto.InternalMessageInfo func (m *QueryParamsResponse) GetParams() *Params { if m != nil { return m.Params } return nil } func init() { proto.RegisterType((*QueryClockContracts)(nil), "cyber.clock.v1.QueryClockContracts") proto.RegisterType((*QueryClockContractsResponse)(nil), "cyber.clock.v1.QueryClockContractsResponse") proto.RegisterType((*QueryClockContract)(nil), "cyber.clock.v1.QueryClockContract") proto.RegisterType((*QueryClockContractResponse)(nil), "cyber.clock.v1.QueryClockContractResponse") proto.RegisterType((*QueryParamsRequest)(nil), "cyber.clock.v1.QueryParamsRequest") proto.RegisterType((*QueryParamsResponse)(nil), "cyber.clock.v1.QueryParamsResponse") } func init() { proto.RegisterFile("cyber/clock/v1/query.proto", fileDescriptor_05444fcb6b1de94a) } var fileDescriptor_05444fcb6b1de94a = []byte{ // 539 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x94, 0x4d, 0x6b, 0x13, 0x41, 0x18, 0xc7, 0xb3, 0xad, 0x06, 0x9c, 0x92, 0x54, 0xc6, 0x52, 0xe2, 0x46, 0x37, 0x75, 0x0b, 0x5a, 0xab, 0xce, 0x90, 0xe8, 0xc9, 0x8b, 0x98, 0x82, 0xe2, 0xcb, 0xa1, 0xee, 0x51, 0x90, 0x32, 0xbb, 0x1d, 0xa6, 0x8b, 0xc9, 0xce, 0x66, 0x67, 0x12, 0x0c, 0xe2, 0x45, 0xf0, 0x2e, 0x88, 0x17, 0x3f, 0x87, 0x1f, 0xa2, 0xc7, 0x82, 0x17, 0x4f, 0x41, 0x12, 0x4f, 0x1e, 0xfd, 0x04, 0xb2, 0x33, 0xb3, 0xd1, 0xd9, 0xb6, 0xa6, 0xb7, 0xd9, 0xe7, 0xf5, 0xf7, 0x7f, 0x9e, 0x87, 0x05, 0x6e, 0x34, 0x0e, 0x69, 0x86, 0xa3, 0x1e, 0x8f, 0x5e, 0xe3, 0x51, 0x1b, 0x0f, 0x86, 0x34, 0x1b, 0xa3, 0x34, 0xe3, 0x92, 0xc3, 0xba, 0xf2, 0x21, 0xe5, 0x43, 0xa3, 0xb6, 0xbb, 0x1d, 0x71, 0xd1, 0xe7, 0x02, 0x87, 0x44, 0x50, 0x1d, 0x88, 0x47, 0xed, 0x90, 0x4a, 0xd2, 0xc6, 0x29, 0x61, 0x71, 0x42, 0x64, 0xcc, 0x13, 0x9d, 0xeb, 0xae, 0x31, 0xce, 0xb8, 0x7a, 0xe2, 0xfc, 0x65, 0xac, 0x57, 0x18, 0xe7, 0xac, 0x47, 0x31, 0x49, 0x63, 0x4c, 0x92, 0x84, 0x4b, 0x95, 0x22, 0x0a, 0x6f, 0x89, 0x85, 0xd1, 0x84, 0x8a, 0xb8, 0xf0, 0x96, 0x49, 0x35, 0x96, 0xf2, 0xf9, 0xaf, 0xc0, 0xa5, 0x17, 0x39, 0xcf, 0x4e, 0x6e, 0xdb, 0xe1, 0x89, 0xcc, 0x48, 0x24, 0x05, 0x7c, 0x04, 0xc0, 0x5f, 0xb0, 0x86, 0xb3, 0xe1, 0x6c, 0xad, 0x74, 0xae, 0x23, 0xad, 0x02, 0xe5, 0x2a, 0x90, 0x96, 0x6b, 0x54, 0xa0, 0x5d, 0xc2, 0x68, 0x40, 0x07, 0x43, 0x2a, 0x64, 0xf0, 0x4f, 0xa6, 0xff, 0xd5, 0x01, 0xcd, 0x13, 0xea, 0x07, 0x54, 0xa4, 0x3c, 0x11, 0x14, 0x3e, 0x07, 0xab, 0x8a, 0x66, 0x2f, 0x2a, 0x5c, 0x0d, 0x67, 0x63, 0x79, 0x6b, 0xa5, 0x73, 0x15, 0xd9, 0x23, 0x44, 0x56, 0x81, 0xee, 0xb9, 0xc3, 0x49, 0xab, 0x12, 0xd4, 0x23, 0x9b, 0xfa, 0xb1, 0x45, 0xbd, 0xa4, 0xa8, 0x6f, 0x2c, 0xa4, 0xd6, 0x28, 0x16, 0xf6, 0x03, 0x00, 0x8f, 0x53, 0xc3, 0x9b, 0xe0, 0x62, 0x81, 0xb9, 0x47, 0xf6, 0xf7, 0x33, 0x2a, 0x84, 0x1a, 0xcd, 0x85, 0x60, 0xb5, 0xb0, 0x3f, 0xd4, 0x66, 0xff, 0x00, 0xb8, 0xc7, 0x0b, 0xcc, 0x55, 0x3f, 0x05, 0x75, 0x5b, 0xb5, 0x99, 0xf0, 0x99, 0x44, 0xd7, 0x2c, 0xd1, 0xfe, 0x9a, 0x41, 0xdd, 0x25, 0x19, 0xe9, 0x0b, 0xb3, 0x03, 0x3f, 0x34, 0x6b, 0x2d, 0xac, 0xa6, 0xf1, 0x33, 0x50, 0x4d, 0x95, 0xc5, 0x34, 0x5c, 0x2f, 0x37, 0xd4, 0xf1, 0xdd, 0xe6, 0xaf, 0x49, 0xcb, 0x44, 0xfe, 0x9e, 0xb4, 0x6a, 0x63, 0xd2, 0xef, 0xdd, 0xf7, 0xf5, 0xb7, 0x1f, 0x18, 0x47, 0xe7, 0xcb, 0x32, 0x38, 0xaf, 0x9a, 0xc0, 0x0f, 0x0e, 0xa8, 0x97, 0x0e, 0x68, 0xb3, 0x5c, 0xf9, 0x84, 0x2b, 0x70, 0x6f, 0x9d, 0x21, 0xa8, 0x60, 0xf7, 0xaf, 0xbd, 0xff, 0xf6, 0xf3, 0xd3, 0x52, 0x13, 0x5e, 0xc6, 0xe5, 0x73, 0x9e, 0x37, 0xfd, 0xec, 0x80, 0x9a, 0xbd, 0x32, 0x7f, 0x71, 0x07, 0x77, 0x7b, 0x71, 0xcc, 0x1c, 0xe2, 0x9e, 0x82, 0x40, 0xf0, 0xf6, 0xa9, 0x10, 0xf8, 0x6d, 0xf9, 0x46, 0xde, 0xc1, 0x01, 0xa8, 0xea, 0xc1, 0x9e, 0xc2, 0x63, 0xed, 0xce, 0xdd, 0xfc, 0x6f, 0x8c, 0x01, 0xf1, 0x14, 0x48, 0x03, 0xae, 0x97, 0x41, 0xf4, 0x72, 0xba, 0x4f, 0x0e, 0xa7, 0x9e, 0x73, 0x34, 0xf5, 0x9c, 0x1f, 0x53, 0xcf, 0xf9, 0x38, 0xf3, 0x2a, 0x47, 0x33, 0xaf, 0xf2, 0x7d, 0xe6, 0x55, 0x5e, 0x62, 0x16, 0xcb, 0x83, 0x61, 0x88, 0x22, 0xde, 0xd7, 0xb9, 0x11, 0x4f, 0x58, 0xce, 0x89, 0x19, 0xbf, 0xa3, 0x8b, 0xbd, 0x31, 0xe5, 0xe4, 0x38, 0xa5, 0x22, 0xac, 0xaa, 0x3f, 0xc5, 0xdd, 0x3f, 0x01, 0x00, 0x00, 0xff, 0xff, 0x2a, 0x7c, 0xaf, 0x65, 0xf1, 0x04, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. var _ context.Context var _ grpc.ClientConn // This is a compile-time assertion to ensure that this generated file // is compatible with the grpc package it is being compiled against. const _ = grpc.SupportPackageIsVersion4 // QueryClient is the client API for Query service. // // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. type QueryClient interface { // ClockContracts ClockContracts(ctx context.Context, in *QueryClockContracts, opts ...grpc.CallOption) (*QueryClockContractsResponse, error) // ClockContract ClockContract(ctx context.Context, in *QueryClockContract, opts ...grpc.CallOption) (*QueryClockContractResponse, error) // Params Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) } type queryClient struct { cc grpc1.ClientConn } func NewQueryClient(cc grpc1.ClientConn) QueryClient { return &queryClient{cc} } func (c *queryClient) ClockContracts(ctx context.Context, in *QueryClockContracts, opts ...grpc.CallOption) (*QueryClockContractsResponse, error) { out := new(QueryClockContractsResponse) err := c.cc.Invoke(ctx, "/cyber.clock.v1.Query/ClockContracts", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) ClockContract(ctx context.Context, in *QueryClockContract, opts ...grpc.CallOption) (*QueryClockContractResponse, error) { out := new(QueryClockContractResponse) err := c.cc.Invoke(ctx, "/cyber.clock.v1.Query/ClockContract", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) { out := new(QueryParamsResponse) err := c.cc.Invoke(ctx, "/cyber.clock.v1.Query/Params", in, out, opts...) if err != nil { return nil, err } return out, nil } // QueryServer is the server API for Query service. type QueryServer interface { // ClockContracts ClockContracts(context.Context, *QueryClockContracts) (*QueryClockContractsResponse, error) // ClockContract ClockContract(context.Context, *QueryClockContract) (*QueryClockContractResponse, error) // Params Params(context.Context, *QueryParamsRequest) (*QueryParamsResponse, error) } // UnimplementedQueryServer can be embedded to have forward compatible implementations. type UnimplementedQueryServer struct { } func (*UnimplementedQueryServer) ClockContracts(ctx context.Context, req *QueryClockContracts) (*QueryClockContractsResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method ClockContracts not implemented") } func (*UnimplementedQueryServer) ClockContract(ctx context.Context, req *QueryClockContract) (*QueryClockContractResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method ClockContract not implemented") } func (*UnimplementedQueryServer) Params(ctx context.Context, req *QueryParamsRequest) (*QueryParamsResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method Params not implemented") } func RegisterQueryServer(s grpc1.Server, srv QueryServer) { s.RegisterService(&_Query_serviceDesc, srv) } func _Query_ClockContracts_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryClockContracts) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).ClockContracts(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.clock.v1.Query/ClockContracts", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).ClockContracts(ctx, req.(*QueryClockContracts)) } return interceptor(ctx, in, info, handler) } func _Query_ClockContract_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryClockContract) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).ClockContract(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.clock.v1.Query/ClockContract", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).ClockContract(ctx, req.(*QueryClockContract)) } return interceptor(ctx, in, info, handler) } func _Query_Params_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryParamsRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).Params(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.clock.v1.Query/Params", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Params(ctx, req.(*QueryParamsRequest)) } return interceptor(ctx, in, info, handler) } var _Query_serviceDesc = grpc.ServiceDesc{ ServiceName: "cyber.clock.v1.Query", HandlerType: (*QueryServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "ClockContracts", Handler: _Query_ClockContracts_Handler, }, { MethodName: "ClockContract", Handler: _Query_ClockContract_Handler, }, { MethodName: "Params", Handler: _Query_Params_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "cyber/clock/v1/query.proto", } func (m *QueryClockContracts) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryClockContracts) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryClockContracts) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.Pagination != nil { { size, err := m.Pagination.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *QueryClockContractsResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryClockContractsResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryClockContractsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.Pagination != nil { { size, err := m.Pagination.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 } if len(m.ClockContracts) > 0 { for iNdEx := len(m.ClockContracts) - 1; iNdEx >= 0; iNdEx-- { { size, err := m.ClockContracts[iNdEx].MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa } } return len(dAtA) - i, nil } func (m *QueryClockContract) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryClockContract) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryClockContract) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.ContractAddress) > 0 { i -= len(m.ContractAddress) copy(dAtA[i:], m.ContractAddress) i = encodeVarintQuery(dAtA, i, uint64(len(m.ContractAddress))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *QueryClockContractResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryClockContractResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryClockContractResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.ClockContract.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa return len(dAtA) - i, nil } func (m *QueryParamsRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryParamsRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryParamsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *QueryParamsResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryParamsResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryParamsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.Params != nil { { size, err := m.Params.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func encodeVarintQuery(dAtA []byte, offset int, v uint64) int { offset -= sovQuery(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *QueryClockContracts) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.Pagination != nil { l = m.Pagination.Size() n += 1 + l + sovQuery(uint64(l)) } return n } func (m *QueryClockContractsResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l if len(m.ClockContracts) > 0 { for _, e := range m.ClockContracts { l = e.Size() n += 1 + l + sovQuery(uint64(l)) } } if m.Pagination != nil { l = m.Pagination.Size() n += 1 + l + sovQuery(uint64(l)) } return n } func (m *QueryClockContract) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.ContractAddress) if l > 0 { n += 1 + l + sovQuery(uint64(l)) } return n } func (m *QueryClockContractResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l l = m.ClockContract.Size() n += 1 + l + sovQuery(uint64(l)) return n } func (m *QueryParamsRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *QueryParamsResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.Params != nil { l = m.Params.Size() n += 1 + l + sovQuery(uint64(l)) } return n } func sovQuery(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozQuery(x uint64) (n int) { return sovQuery(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *QueryClockContracts) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryClockContracts: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryClockContracts: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if m.Pagination == nil { m.Pagination = &query.PageRequest{} } if err := m.Pagination.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryClockContractsResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryClockContractsResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryClockContractsResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field ClockContracts", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } m.ClockContracts = append(m.ClockContracts, ClockContract{}) if err := m.ClockContracts[len(m.ClockContracts)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if m.Pagination == nil { m.Pagination = &query.PageResponse{} } if err := m.Pagination.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryClockContract) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryClockContract: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryClockContract: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field ContractAddress", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } m.ContractAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryClockContractResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryClockContractResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryClockContractResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field ClockContract", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.ClockContract.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryParamsRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryParamsRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryParamsRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryParamsResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryParamsResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryParamsResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if m.Params == nil { m.Params = &Params{} } if err := m.Params.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipQuery(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowQuery } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowQuery } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowQuery } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthQuery } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupQuery } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthQuery } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthQuery = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowQuery = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupQuery = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/clock/types/query.pb.gw.go ================================================ // Code generated by protoc-gen-grpc-gateway. DO NOT EDIT. // source: cyber/clock/v1/query.proto /* Package types is a reverse proxy. It translates gRPC into RESTful JSON APIs. */ package types import ( "context" "io" "net/http" "github.com/golang/protobuf/descriptor" "github.com/golang/protobuf/proto" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/grpc-ecosystem/grpc-gateway/utilities" "google.golang.org/grpc" "google.golang.org/grpc/codes" "google.golang.org/grpc/grpclog" "google.golang.org/grpc/metadata" "google.golang.org/grpc/status" ) // Suppress "imported and not used" errors var _ codes.Code var _ io.Reader var _ status.Status var _ = runtime.String var _ = utilities.NewDoubleArray var _ = descriptor.ForMessage var _ = metadata.Join var ( filter_Query_ClockContracts_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) func request_Query_ClockContracts_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryClockContracts var metadata runtime.ServerMetadata if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_ClockContracts_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := client.ClockContracts(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_ClockContracts_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryClockContracts var metadata runtime.ServerMetadata if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_ClockContracts_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := server.ClockContracts(ctx, &protoReq) return msg, metadata, err } func request_Query_ClockContract_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryClockContract var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["contract_address"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "contract_address") } protoReq.ContractAddress, err = runtime.String(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "contract_address", err) } msg, err := client.ClockContract(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_ClockContract_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryClockContract var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["contract_address"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "contract_address") } protoReq.ContractAddress, err = runtime.String(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "contract_address", err) } msg, err := server.ClockContract(ctx, &protoReq) return msg, metadata, err } func request_Query_Params_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryParamsRequest var metadata runtime.ServerMetadata msg, err := client.Params(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_Params_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryParamsRequest var metadata runtime.ServerMetadata msg, err := server.Params(ctx, &protoReq) return msg, metadata, err } // RegisterQueryHandlerServer registers the http handlers for service Query to "mux". // UnaryRPC :call QueryServer directly. // StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. // Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterQueryHandlerFromEndpoint instead. func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, server QueryServer) error { mux.Handle("GET", pattern_Query_ClockContracts_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_ClockContracts_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_ClockContracts_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_ClockContract_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_ClockContract_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_ClockContract_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_Params_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_Params_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Params_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) return nil } // RegisterQueryHandlerFromEndpoint is same as RegisterQueryHandler but // automatically dials to "endpoint" and closes the connection when "ctx" gets done. func RegisterQueryHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error) { conn, err := grpc.Dial(endpoint, opts...) if err != nil { return err } defer func() { if err != nil { if cerr := conn.Close(); cerr != nil { grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr) } return } go func() { <-ctx.Done() if cerr := conn.Close(); cerr != nil { grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr) } }() }() return RegisterQueryHandler(ctx, mux, conn) } // RegisterQueryHandler registers the http handlers for service Query to "mux". // The handlers forward requests to the grpc endpoint over "conn". func RegisterQueryHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error { return RegisterQueryHandlerClient(ctx, mux, NewQueryClient(conn)) } // RegisterQueryHandlerClient registers the http handlers for service Query // to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "QueryClient". // Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "QueryClient" // doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in // "QueryClient" to call the correct interceptors. func RegisterQueryHandlerClient(ctx context.Context, mux *runtime.ServeMux, client QueryClient) error { mux.Handle("GET", pattern_Query_ClockContracts_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_ClockContracts_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_ClockContracts_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_ClockContract_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_ClockContract_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_ClockContract_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_Params_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_Params_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Params_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) return nil } var ( pattern_Query_ClockContracts_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"cyber", "clock", "v1", "contracts"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_ClockContract_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4}, []string{"cyber", "clock", "v1", "contracts", "contract_address"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_Params_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"cyber", "clock", "v1", "params"}, "", runtime.AssumeColonVerbOpt(false))) ) var ( forward_Query_ClockContracts_0 = runtime.ForwardResponseMessage forward_Query_ClockContract_0 = runtime.ForwardResponseMessage forward_Query_Params_0 = runtime.ForwardResponseMessage ) ================================================ FILE: x/clock/types/tx.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: cyber/clock/v1/tx.proto package types import ( context "context" fmt "fmt" _ "github.com/cosmos/cosmos-proto" _ "github.com/cosmos/cosmos-sdk/types/msgservice" _ "github.com/cosmos/gogoproto/gogoproto" grpc1 "github.com/cosmos/gogoproto/grpc" proto "github.com/cosmos/gogoproto/proto" _ "google.golang.org/genproto/googleapis/api/annotations" grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" io "io" math "math" math_bits "math/bits" ) // Reference imports to suppress errors if they are not otherwise used. var _ = proto.Marshal var _ = fmt.Errorf var _ = math.Inf // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package // MsgRegisterClockContract is the Msg/RegisterClockContract request type. type MsgRegisterClockContract struct { // The address of the sender. SenderAddress string `protobuf:"bytes,1,opt,name=sender_address,json=senderAddress,proto3" json:"sender_address,omitempty"` // The address of the contract to register. ContractAddress string `protobuf:"bytes,2,opt,name=contract_address,json=contractAddress,proto3" json:"contract_address,omitempty"` } func (m *MsgRegisterClockContract) Reset() { *m = MsgRegisterClockContract{} } func (m *MsgRegisterClockContract) String() string { return proto.CompactTextString(m) } func (*MsgRegisterClockContract) ProtoMessage() {} func (*MsgRegisterClockContract) Descriptor() ([]byte, []int) { return fileDescriptor_f27fe74cf5db2c38, []int{0} } func (m *MsgRegisterClockContract) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgRegisterClockContract) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgRegisterClockContract.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgRegisterClockContract) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgRegisterClockContract.Merge(m, src) } func (m *MsgRegisterClockContract) XXX_Size() int { return m.Size() } func (m *MsgRegisterClockContract) XXX_DiscardUnknown() { xxx_messageInfo_MsgRegisterClockContract.DiscardUnknown(m) } var xxx_messageInfo_MsgRegisterClockContract proto.InternalMessageInfo func (m *MsgRegisterClockContract) GetSenderAddress() string { if m != nil { return m.SenderAddress } return "" } func (m *MsgRegisterClockContract) GetContractAddress() string { if m != nil { return m.ContractAddress } return "" } // MsgRegisterClockContractResponse defines the response structure for executing // a MsgRegisterClockContract message. type MsgRegisterClockContractResponse struct { } func (m *MsgRegisterClockContractResponse) Reset() { *m = MsgRegisterClockContractResponse{} } func (m *MsgRegisterClockContractResponse) String() string { return proto.CompactTextString(m) } func (*MsgRegisterClockContractResponse) ProtoMessage() {} func (*MsgRegisterClockContractResponse) Descriptor() ([]byte, []int) { return fileDescriptor_f27fe74cf5db2c38, []int{1} } func (m *MsgRegisterClockContractResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgRegisterClockContractResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgRegisterClockContractResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgRegisterClockContractResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgRegisterClockContractResponse.Merge(m, src) } func (m *MsgRegisterClockContractResponse) XXX_Size() int { return m.Size() } func (m *MsgRegisterClockContractResponse) XXX_DiscardUnknown() { xxx_messageInfo_MsgRegisterClockContractResponse.DiscardUnknown(m) } var xxx_messageInfo_MsgRegisterClockContractResponse proto.InternalMessageInfo // MsgUnregisterClockContract is the Msg/UnregisterClockContract request type. type MsgUnregisterClockContract struct { // The address of the sender. SenderAddress string `protobuf:"bytes,1,opt,name=sender_address,json=senderAddress,proto3" json:"sender_address,omitempty"` // The address of the contract to unregister. ContractAddress string `protobuf:"bytes,2,opt,name=contract_address,json=contractAddress,proto3" json:"contract_address,omitempty"` } func (m *MsgUnregisterClockContract) Reset() { *m = MsgUnregisterClockContract{} } func (m *MsgUnregisterClockContract) String() string { return proto.CompactTextString(m) } func (*MsgUnregisterClockContract) ProtoMessage() {} func (*MsgUnregisterClockContract) Descriptor() ([]byte, []int) { return fileDescriptor_f27fe74cf5db2c38, []int{2} } func (m *MsgUnregisterClockContract) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgUnregisterClockContract) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgUnregisterClockContract.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgUnregisterClockContract) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgUnregisterClockContract.Merge(m, src) } func (m *MsgUnregisterClockContract) XXX_Size() int { return m.Size() } func (m *MsgUnregisterClockContract) XXX_DiscardUnknown() { xxx_messageInfo_MsgUnregisterClockContract.DiscardUnknown(m) } var xxx_messageInfo_MsgUnregisterClockContract proto.InternalMessageInfo func (m *MsgUnregisterClockContract) GetSenderAddress() string { if m != nil { return m.SenderAddress } return "" } func (m *MsgUnregisterClockContract) GetContractAddress() string { if m != nil { return m.ContractAddress } return "" } // MsgUnregisterClockContractResponse defines the response structure for // executing a MsgUnregisterClockContract message. type MsgUnregisterClockContractResponse struct { } func (m *MsgUnregisterClockContractResponse) Reset() { *m = MsgUnregisterClockContractResponse{} } func (m *MsgUnregisterClockContractResponse) String() string { return proto.CompactTextString(m) } func (*MsgUnregisterClockContractResponse) ProtoMessage() {} func (*MsgUnregisterClockContractResponse) Descriptor() ([]byte, []int) { return fileDescriptor_f27fe74cf5db2c38, []int{3} } func (m *MsgUnregisterClockContractResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgUnregisterClockContractResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgUnregisterClockContractResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgUnregisterClockContractResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgUnregisterClockContractResponse.Merge(m, src) } func (m *MsgUnregisterClockContractResponse) XXX_Size() int { return m.Size() } func (m *MsgUnregisterClockContractResponse) XXX_DiscardUnknown() { xxx_messageInfo_MsgUnregisterClockContractResponse.DiscardUnknown(m) } var xxx_messageInfo_MsgUnregisterClockContractResponse proto.InternalMessageInfo // MsgUnjailClockContract is the Msg/UnjailClockContract request type. type MsgUnjailClockContract struct { // The address of the sender. SenderAddress string `protobuf:"bytes,1,opt,name=sender_address,json=senderAddress,proto3" json:"sender_address,omitempty"` // The address of the contract to unjail. ContractAddress string `protobuf:"bytes,2,opt,name=contract_address,json=contractAddress,proto3" json:"contract_address,omitempty"` } func (m *MsgUnjailClockContract) Reset() { *m = MsgUnjailClockContract{} } func (m *MsgUnjailClockContract) String() string { return proto.CompactTextString(m) } func (*MsgUnjailClockContract) ProtoMessage() {} func (*MsgUnjailClockContract) Descriptor() ([]byte, []int) { return fileDescriptor_f27fe74cf5db2c38, []int{4} } func (m *MsgUnjailClockContract) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgUnjailClockContract) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgUnjailClockContract.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgUnjailClockContract) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgUnjailClockContract.Merge(m, src) } func (m *MsgUnjailClockContract) XXX_Size() int { return m.Size() } func (m *MsgUnjailClockContract) XXX_DiscardUnknown() { xxx_messageInfo_MsgUnjailClockContract.DiscardUnknown(m) } var xxx_messageInfo_MsgUnjailClockContract proto.InternalMessageInfo func (m *MsgUnjailClockContract) GetSenderAddress() string { if m != nil { return m.SenderAddress } return "" } func (m *MsgUnjailClockContract) GetContractAddress() string { if m != nil { return m.ContractAddress } return "" } // MsgUnjailClockContractResponse defines the response structure for executing a // MsgUnjailClockContract message. type MsgUnjailClockContractResponse struct { } func (m *MsgUnjailClockContractResponse) Reset() { *m = MsgUnjailClockContractResponse{} } func (m *MsgUnjailClockContractResponse) String() string { return proto.CompactTextString(m) } func (*MsgUnjailClockContractResponse) ProtoMessage() {} func (*MsgUnjailClockContractResponse) Descriptor() ([]byte, []int) { return fileDescriptor_f27fe74cf5db2c38, []int{5} } func (m *MsgUnjailClockContractResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgUnjailClockContractResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgUnjailClockContractResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgUnjailClockContractResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgUnjailClockContractResponse.Merge(m, src) } func (m *MsgUnjailClockContractResponse) XXX_Size() int { return m.Size() } func (m *MsgUnjailClockContractResponse) XXX_DiscardUnknown() { xxx_messageInfo_MsgUnjailClockContractResponse.DiscardUnknown(m) } var xxx_messageInfo_MsgUnjailClockContractResponse proto.InternalMessageInfo // MsgUpdateParams is the Msg/UpdateParams request type. // // Since: cosmos-sdk 0.47 type MsgUpdateParams struct { // authority is the address of the governance account. Authority string `protobuf:"bytes,1,opt,name=authority,proto3" json:"authority,omitempty"` // params defines the x/clock parameters to update. // // NOTE: All parameters must be supplied. Params Params `protobuf:"bytes,2,opt,name=params,proto3" json:"params"` } func (m *MsgUpdateParams) Reset() { *m = MsgUpdateParams{} } func (m *MsgUpdateParams) String() string { return proto.CompactTextString(m) } func (*MsgUpdateParams) ProtoMessage() {} func (*MsgUpdateParams) Descriptor() ([]byte, []int) { return fileDescriptor_f27fe74cf5db2c38, []int{6} } func (m *MsgUpdateParams) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgUpdateParams) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgUpdateParams.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgUpdateParams) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgUpdateParams.Merge(m, src) } func (m *MsgUpdateParams) XXX_Size() int { return m.Size() } func (m *MsgUpdateParams) XXX_DiscardUnknown() { xxx_messageInfo_MsgUpdateParams.DiscardUnknown(m) } var xxx_messageInfo_MsgUpdateParams proto.InternalMessageInfo func (m *MsgUpdateParams) GetAuthority() string { if m != nil { return m.Authority } return "" } func (m *MsgUpdateParams) GetParams() Params { if m != nil { return m.Params } return Params{} } // MsgUpdateParamsResponse defines the response structure for executing a // MsgUpdateParams message. // // Since: cosmos-sdk 0.47 type MsgUpdateParamsResponse struct { } func (m *MsgUpdateParamsResponse) Reset() { *m = MsgUpdateParamsResponse{} } func (m *MsgUpdateParamsResponse) String() string { return proto.CompactTextString(m) } func (*MsgUpdateParamsResponse) ProtoMessage() {} func (*MsgUpdateParamsResponse) Descriptor() ([]byte, []int) { return fileDescriptor_f27fe74cf5db2c38, []int{7} } func (m *MsgUpdateParamsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgUpdateParamsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgUpdateParamsResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgUpdateParamsResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgUpdateParamsResponse.Merge(m, src) } func (m *MsgUpdateParamsResponse) XXX_Size() int { return m.Size() } func (m *MsgUpdateParamsResponse) XXX_DiscardUnknown() { xxx_messageInfo_MsgUpdateParamsResponse.DiscardUnknown(m) } var xxx_messageInfo_MsgUpdateParamsResponse proto.InternalMessageInfo func init() { proto.RegisterType((*MsgRegisterClockContract)(nil), "cyber.clock.v1.MsgRegisterClockContract") proto.RegisterType((*MsgRegisterClockContractResponse)(nil), "cyber.clock.v1.MsgRegisterClockContractResponse") proto.RegisterType((*MsgUnregisterClockContract)(nil), "cyber.clock.v1.MsgUnregisterClockContract") proto.RegisterType((*MsgUnregisterClockContractResponse)(nil), "cyber.clock.v1.MsgUnregisterClockContractResponse") proto.RegisterType((*MsgUnjailClockContract)(nil), "cyber.clock.v1.MsgUnjailClockContract") proto.RegisterType((*MsgUnjailClockContractResponse)(nil), "cyber.clock.v1.MsgUnjailClockContractResponse") proto.RegisterType((*MsgUpdateParams)(nil), "cyber.clock.v1.MsgUpdateParams") proto.RegisterType((*MsgUpdateParamsResponse)(nil), "cyber.clock.v1.MsgUpdateParamsResponse") } func init() { proto.RegisterFile("cyber/clock/v1/tx.proto", fileDescriptor_f27fe74cf5db2c38) } var fileDescriptor_f27fe74cf5db2c38 = []byte{ // 541 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xbc, 0x94, 0x41, 0x6f, 0xd3, 0x3e, 0x18, 0xc6, 0x9b, 0xfd, 0xa7, 0x49, 0xf3, 0x1f, 0x3a, 0x14, 0xc6, 0xda, 0x66, 0x5b, 0x5a, 0x0c, 0x83, 0x31, 0x69, 0x31, 0x2b, 0x88, 0x03, 0x37, 0xba, 0x13, 0x87, 0x4a, 0x28, 0x08, 0x09, 0x71, 0x99, 0xdc, 0xd4, 0xf2, 0x32, 0x1a, 0x3b, 0xb2, 0xdd, 0x69, 0xbd, 0xee, 0x0b, 0x30, 0x89, 0x0b, 0x47, 0x3e, 0xc2, 0x0e, 0x7c, 0x88, 0x1d, 0x27, 0xb8, 0x70, 0x42, 0xa8, 0x45, 0xe2, 0x6b, 0xa0, 0xd8, 0x49, 0xc6, 0xba, 0x44, 0xf4, 0x02, 0x37, 0xe7, 0x7d, 0x9f, 0xf7, 0x79, 0x7e, 0x8a, 0xdf, 0x04, 0xd4, 0x82, 0x51, 0x8f, 0x08, 0x14, 0x0c, 0x78, 0xf0, 0x16, 0x1d, 0xee, 0x20, 0x75, 0xe4, 0xc5, 0x82, 0x2b, 0x6e, 0x57, 0x75, 0xc3, 0xd3, 0x0d, 0xef, 0x70, 0xc7, 0x59, 0xa3, 0x9c, 0xd3, 0x01, 0x41, 0x38, 0x0e, 0x11, 0x66, 0x8c, 0x2b, 0xac, 0x42, 0xce, 0xa4, 0x51, 0x3b, 0xb5, 0x80, 0xcb, 0x88, 0x4b, 0x14, 0x49, 0x9a, 0xb8, 0x44, 0x92, 0xa6, 0x8d, 0xb5, 0x29, 0x7f, 0x4a, 0x18, 0x91, 0x61, 0x36, 0xb6, 0x4c, 0x39, 0xe5, 0xfa, 0x88, 0x92, 0x53, 0x5a, 0x6d, 0x18, 0xb3, 0x3d, 0xd3, 0x30, 0x0f, 0xa6, 0x05, 0x07, 0xa0, 0xde, 0x95, 0xd4, 0x27, 0x34, 0x94, 0x8a, 0x88, 0xdd, 0xc4, 0x75, 0x97, 0x33, 0x25, 0x70, 0xa0, 0xec, 0x0d, 0x50, 0x95, 0x84, 0xf5, 0x89, 0xd8, 0xc3, 0xfd, 0xbe, 0x20, 0x52, 0xd6, 0xad, 0x96, 0xb5, 0xb9, 0xe8, 0x5f, 0x37, 0xd5, 0x67, 0xa6, 0x68, 0x3f, 0x00, 0x37, 0x82, 0x74, 0x24, 0x17, 0xce, 0x69, 0xe1, 0x52, 0x56, 0x4f, 0xa5, 0x10, 0x82, 0x56, 0x59, 0x9a, 0x4f, 0x64, 0xcc, 0x99, 0x24, 0x90, 0x01, 0xa7, 0x2b, 0xe9, 0x2b, 0x26, 0xfe, 0x11, 0xd3, 0x5d, 0x00, 0xcb, 0xf3, 0x72, 0xaa, 0x03, 0xb0, 0xa2, 0x55, 0x07, 0x38, 0x1c, 0xfc, 0x6d, 0xa2, 0x16, 0x70, 0x8b, 0xb3, 0x72, 0x9a, 0x77, 0x16, 0x58, 0x4a, 0x24, 0x71, 0x1f, 0x2b, 0xf2, 0x02, 0x0b, 0x1c, 0x49, 0xfb, 0x09, 0x58, 0xc4, 0x43, 0xb5, 0xcf, 0x45, 0xa8, 0x46, 0x06, 0xa1, 0x53, 0xff, 0xfc, 0x69, 0x7b, 0x39, 0xbd, 0xee, 0xd4, 0xfc, 0xa5, 0x12, 0x21, 0xa3, 0xfe, 0x85, 0xd4, 0x7e, 0x0c, 0x16, 0x62, 0xed, 0xa0, 0x71, 0xfe, 0x6f, 0xaf, 0x78, 0x97, 0x17, 0xd5, 0x33, 0xfe, 0x9d, 0xf9, 0xb3, 0x6f, 0xcd, 0x8a, 0x9f, 0x6a, 0x9f, 0x56, 0x8f, 0x7f, 0x9e, 0x6e, 0x5d, 0xb8, 0xc0, 0x06, 0xa8, 0x4d, 0x01, 0x65, 0xb0, 0xed, 0xd3, 0x79, 0xf0, 0x5f, 0x57, 0x52, 0xfb, 0x83, 0x05, 0x6e, 0x15, 0x2f, 0xda, 0xe6, 0x74, 0x64, 0xd9, 0x92, 0x38, 0x0f, 0x67, 0x55, 0xe6, 0xaf, 0xea, 0xce, 0xf1, 0x97, 0x1f, 0xef, 0xe7, 0xd6, 0xe1, 0x2a, 0xba, 0xf2, 0x61, 0xa2, 0xec, 0xca, 0xed, 0x8f, 0x16, 0xa8, 0x95, 0x6d, 0xdc, 0x56, 0x41, 0x64, 0x89, 0xd6, 0x69, 0xcf, 0xae, 0xcd, 0x01, 0x37, 0x34, 0x60, 0x13, 0xae, 0x17, 0x00, 0x0e, 0xf3, 0x59, 0xfb, 0xc4, 0x02, 0x37, 0x8b, 0xd6, 0xef, 0x5e, 0x61, 0xe4, 0x15, 0x9d, 0xe3, 0xcd, 0xa6, 0xcb, 0xb1, 0x6e, 0x6b, 0xac, 0x55, 0xd8, 0x28, 0xc4, 0x4a, 0xe6, 0xec, 0xd7, 0xe0, 0xda, 0xa5, 0x0d, 0x6c, 0x16, 0x45, 0xfc, 0x26, 0x70, 0xee, 0xff, 0x41, 0x90, 0x85, 0x77, 0x9e, 0x9f, 0x8d, 0x5d, 0xeb, 0x7c, 0xec, 0x5a, 0xdf, 0xc7, 0xae, 0x75, 0x32, 0x71, 0x2b, 0xe7, 0x13, 0xb7, 0xf2, 0x75, 0xe2, 0x56, 0xde, 0x20, 0x1a, 0xaa, 0xfd, 0x61, 0xcf, 0x0b, 0x78, 0x64, 0xc0, 0x02, 0xce, 0x68, 0xb2, 0xd8, 0x88, 0xf2, 0x6d, 0x43, 0x7a, 0x94, 0xb2, 0xaa, 0x51, 0x4c, 0x64, 0x6f, 0x41, 0xff, 0xe7, 0x1e, 0xfd, 0x0a, 0x00, 0x00, 0xff, 0xff, 0x1f, 0xcc, 0xf9, 0xf2, 0x98, 0x05, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. var _ context.Context var _ grpc.ClientConn // This is a compile-time assertion to ensure that this generated file // is compatible with the grpc package it is being compiled against. const _ = grpc.SupportPackageIsVersion4 // MsgClient is the client API for Msg service. // // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. type MsgClient interface { // RegisterClockContract defines the endpoint for // registering a new clock contract. RegisterClockContract(ctx context.Context, in *MsgRegisterClockContract, opts ...grpc.CallOption) (*MsgRegisterClockContractResponse, error) // UnregisterClockContract defines the endpoint for // unregistering a clock contract. UnregisterClockContract(ctx context.Context, in *MsgUnregisterClockContract, opts ...grpc.CallOption) (*MsgUnregisterClockContractResponse, error) // UnjailClockContract defines the endpoint for // unjailing a clock contract. UnjailClockContract(ctx context.Context, in *MsgUnjailClockContract, opts ...grpc.CallOption) (*MsgUnjailClockContractResponse, error) // UpdateParams defines a governance operation for updating the x/clock module // parameters. The authority is hard-coded to the x/gov module account. // // Since: cosmos-sdk 0.47 UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) } type msgClient struct { cc grpc1.ClientConn } func NewMsgClient(cc grpc1.ClientConn) MsgClient { return &msgClient{cc} } func (c *msgClient) RegisterClockContract(ctx context.Context, in *MsgRegisterClockContract, opts ...grpc.CallOption) (*MsgRegisterClockContractResponse, error) { out := new(MsgRegisterClockContractResponse) err := c.cc.Invoke(ctx, "/cyber.clock.v1.Msg/RegisterClockContract", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *msgClient) UnregisterClockContract(ctx context.Context, in *MsgUnregisterClockContract, opts ...grpc.CallOption) (*MsgUnregisterClockContractResponse, error) { out := new(MsgUnregisterClockContractResponse) err := c.cc.Invoke(ctx, "/cyber.clock.v1.Msg/UnregisterClockContract", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *msgClient) UnjailClockContract(ctx context.Context, in *MsgUnjailClockContract, opts ...grpc.CallOption) (*MsgUnjailClockContractResponse, error) { out := new(MsgUnjailClockContractResponse) err := c.cc.Invoke(ctx, "/cyber.clock.v1.Msg/UnjailClockContract", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *msgClient) UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) { out := new(MsgUpdateParamsResponse) err := c.cc.Invoke(ctx, "/cyber.clock.v1.Msg/UpdateParams", in, out, opts...) if err != nil { return nil, err } return out, nil } // MsgServer is the server API for Msg service. type MsgServer interface { // RegisterClockContract defines the endpoint for // registering a new clock contract. RegisterClockContract(context.Context, *MsgRegisterClockContract) (*MsgRegisterClockContractResponse, error) // UnregisterClockContract defines the endpoint for // unregistering a clock contract. UnregisterClockContract(context.Context, *MsgUnregisterClockContract) (*MsgUnregisterClockContractResponse, error) // UnjailClockContract defines the endpoint for // unjailing a clock contract. UnjailClockContract(context.Context, *MsgUnjailClockContract) (*MsgUnjailClockContractResponse, error) // UpdateParams defines a governance operation for updating the x/clock module // parameters. The authority is hard-coded to the x/gov module account. // // Since: cosmos-sdk 0.47 UpdateParams(context.Context, *MsgUpdateParams) (*MsgUpdateParamsResponse, error) } // UnimplementedMsgServer can be embedded to have forward compatible implementations. type UnimplementedMsgServer struct { } func (*UnimplementedMsgServer) RegisterClockContract(ctx context.Context, req *MsgRegisterClockContract) (*MsgRegisterClockContractResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method RegisterClockContract not implemented") } func (*UnimplementedMsgServer) UnregisterClockContract(ctx context.Context, req *MsgUnregisterClockContract) (*MsgUnregisterClockContractResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method UnregisterClockContract not implemented") } func (*UnimplementedMsgServer) UnjailClockContract(ctx context.Context, req *MsgUnjailClockContract) (*MsgUnjailClockContractResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method UnjailClockContract not implemented") } func (*UnimplementedMsgServer) UpdateParams(ctx context.Context, req *MsgUpdateParams) (*MsgUpdateParamsResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method UpdateParams not implemented") } func RegisterMsgServer(s grpc1.Server, srv MsgServer) { s.RegisterService(&_Msg_serviceDesc, srv) } func _Msg_RegisterClockContract_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgRegisterClockContract) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(MsgServer).RegisterClockContract(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.clock.v1.Msg/RegisterClockContract", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).RegisterClockContract(ctx, req.(*MsgRegisterClockContract)) } return interceptor(ctx, in, info, handler) } func _Msg_UnregisterClockContract_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgUnregisterClockContract) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(MsgServer).UnregisterClockContract(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.clock.v1.Msg/UnregisterClockContract", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).UnregisterClockContract(ctx, req.(*MsgUnregisterClockContract)) } return interceptor(ctx, in, info, handler) } func _Msg_UnjailClockContract_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgUnjailClockContract) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(MsgServer).UnjailClockContract(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.clock.v1.Msg/UnjailClockContract", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).UnjailClockContract(ctx, req.(*MsgUnjailClockContract)) } return interceptor(ctx, in, info, handler) } func _Msg_UpdateParams_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgUpdateParams) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(MsgServer).UpdateParams(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.clock.v1.Msg/UpdateParams", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).UpdateParams(ctx, req.(*MsgUpdateParams)) } return interceptor(ctx, in, info, handler) } var _Msg_serviceDesc = grpc.ServiceDesc{ ServiceName: "cyber.clock.v1.Msg", HandlerType: (*MsgServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "RegisterClockContract", Handler: _Msg_RegisterClockContract_Handler, }, { MethodName: "UnregisterClockContract", Handler: _Msg_UnregisterClockContract_Handler, }, { MethodName: "UnjailClockContract", Handler: _Msg_UnjailClockContract_Handler, }, { MethodName: "UpdateParams", Handler: _Msg_UpdateParams_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "cyber/clock/v1/tx.proto", } func (m *MsgRegisterClockContract) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgRegisterClockContract) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgRegisterClockContract) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.ContractAddress) > 0 { i -= len(m.ContractAddress) copy(dAtA[i:], m.ContractAddress) i = encodeVarintTx(dAtA, i, uint64(len(m.ContractAddress))) i-- dAtA[i] = 0x12 } if len(m.SenderAddress) > 0 { i -= len(m.SenderAddress) copy(dAtA[i:], m.SenderAddress) i = encodeVarintTx(dAtA, i, uint64(len(m.SenderAddress))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *MsgRegisterClockContractResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgRegisterClockContractResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgRegisterClockContractResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *MsgUnregisterClockContract) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgUnregisterClockContract) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgUnregisterClockContract) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.ContractAddress) > 0 { i -= len(m.ContractAddress) copy(dAtA[i:], m.ContractAddress) i = encodeVarintTx(dAtA, i, uint64(len(m.ContractAddress))) i-- dAtA[i] = 0x12 } if len(m.SenderAddress) > 0 { i -= len(m.SenderAddress) copy(dAtA[i:], m.SenderAddress) i = encodeVarintTx(dAtA, i, uint64(len(m.SenderAddress))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *MsgUnregisterClockContractResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgUnregisterClockContractResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgUnregisterClockContractResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *MsgUnjailClockContract) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgUnjailClockContract) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgUnjailClockContract) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.ContractAddress) > 0 { i -= len(m.ContractAddress) copy(dAtA[i:], m.ContractAddress) i = encodeVarintTx(dAtA, i, uint64(len(m.ContractAddress))) i-- dAtA[i] = 0x12 } if len(m.SenderAddress) > 0 { i -= len(m.SenderAddress) copy(dAtA[i:], m.SenderAddress) i = encodeVarintTx(dAtA, i, uint64(len(m.SenderAddress))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *MsgUnjailClockContractResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgUnjailClockContractResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgUnjailClockContractResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *MsgUpdateParams) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgUpdateParams) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgUpdateParams) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.Params.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintTx(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 if len(m.Authority) > 0 { i -= len(m.Authority) copy(dAtA[i:], m.Authority) i = encodeVarintTx(dAtA, i, uint64(len(m.Authority))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *MsgUpdateParamsResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgUpdateParamsResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgUpdateParamsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func encodeVarintTx(dAtA []byte, offset int, v uint64) int { offset -= sovTx(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *MsgRegisterClockContract) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.SenderAddress) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = len(m.ContractAddress) if l > 0 { n += 1 + l + sovTx(uint64(l)) } return n } func (m *MsgRegisterClockContractResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *MsgUnregisterClockContract) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.SenderAddress) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = len(m.ContractAddress) if l > 0 { n += 1 + l + sovTx(uint64(l)) } return n } func (m *MsgUnregisterClockContractResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *MsgUnjailClockContract) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.SenderAddress) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = len(m.ContractAddress) if l > 0 { n += 1 + l + sovTx(uint64(l)) } return n } func (m *MsgUnjailClockContractResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *MsgUpdateParams) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Authority) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = m.Params.Size() n += 1 + l + sovTx(uint64(l)) return n } func (m *MsgUpdateParamsResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func sovTx(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozTx(x uint64) (n int) { return sovTx(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *MsgRegisterClockContract) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgRegisterClockContract: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgRegisterClockContract: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field SenderAddress", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.SenderAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field ContractAddress", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.ContractAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgRegisterClockContractResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgRegisterClockContractResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgRegisterClockContractResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgUnregisterClockContract) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgUnregisterClockContract: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgUnregisterClockContract: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field SenderAddress", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.SenderAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field ContractAddress", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.ContractAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgUnregisterClockContractResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgUnregisterClockContractResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgUnregisterClockContractResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgUnjailClockContract) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgUnjailClockContract: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgUnjailClockContract: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field SenderAddress", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.SenderAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field ContractAddress", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.ContractAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgUnjailClockContractResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgUnjailClockContractResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgUnjailClockContractResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgUpdateParams) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgUpdateParams: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgUpdateParams: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Authority", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Authority = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Params.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgUpdateParamsResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgUpdateParamsResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgUpdateParamsResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipTx(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTx } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTx } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTx } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthTx } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupTx } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthTx } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthTx = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowTx = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupTx = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/clock/types/tx.pb.gw.go ================================================ // Code generated by protoc-gen-grpc-gateway. DO NOT EDIT. // source: cyber/clock/v1/tx.proto /* Package types is a reverse proxy. It translates gRPC into RESTful JSON APIs. */ package types import ( "context" "io" "net/http" "github.com/golang/protobuf/descriptor" "github.com/golang/protobuf/proto" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/grpc-ecosystem/grpc-gateway/utilities" "google.golang.org/grpc" "google.golang.org/grpc/codes" "google.golang.org/grpc/grpclog" "google.golang.org/grpc/metadata" "google.golang.org/grpc/status" ) // Suppress "imported and not used" errors var _ codes.Code var _ io.Reader var _ status.Status var _ = runtime.String var _ = utilities.NewDoubleArray var _ = descriptor.ForMessage var _ = metadata.Join var ( filter_Msg_RegisterClockContract_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) func request_Msg_RegisterClockContract_0(ctx context.Context, marshaler runtime.Marshaler, client MsgClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq MsgRegisterClockContract var metadata runtime.ServerMetadata if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Msg_RegisterClockContract_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := client.RegisterClockContract(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Msg_RegisterClockContract_0(ctx context.Context, marshaler runtime.Marshaler, server MsgServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq MsgRegisterClockContract var metadata runtime.ServerMetadata if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Msg_RegisterClockContract_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := server.RegisterClockContract(ctx, &protoReq) return msg, metadata, err } var ( filter_Msg_UnregisterClockContract_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) func request_Msg_UnregisterClockContract_0(ctx context.Context, marshaler runtime.Marshaler, client MsgClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq MsgUnregisterClockContract var metadata runtime.ServerMetadata if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Msg_UnregisterClockContract_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := client.UnregisterClockContract(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Msg_UnregisterClockContract_0(ctx context.Context, marshaler runtime.Marshaler, server MsgServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq MsgUnregisterClockContract var metadata runtime.ServerMetadata if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Msg_UnregisterClockContract_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := server.UnregisterClockContract(ctx, &protoReq) return msg, metadata, err } var ( filter_Msg_UnjailClockContract_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) func request_Msg_UnjailClockContract_0(ctx context.Context, marshaler runtime.Marshaler, client MsgClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq MsgUnjailClockContract var metadata runtime.ServerMetadata if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Msg_UnjailClockContract_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := client.UnjailClockContract(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Msg_UnjailClockContract_0(ctx context.Context, marshaler runtime.Marshaler, server MsgServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq MsgUnjailClockContract var metadata runtime.ServerMetadata if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Msg_UnjailClockContract_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := server.UnjailClockContract(ctx, &protoReq) return msg, metadata, err } // RegisterMsgHandlerServer registers the http handlers for service Msg to "mux". // UnaryRPC :call MsgServer directly. // StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. // Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterMsgHandlerFromEndpoint instead. func RegisterMsgHandlerServer(ctx context.Context, mux *runtime.ServeMux, server MsgServer) error { mux.Handle("POST", pattern_Msg_RegisterClockContract_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Msg_RegisterClockContract_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Msg_RegisterClockContract_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("POST", pattern_Msg_UnregisterClockContract_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Msg_UnregisterClockContract_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Msg_UnregisterClockContract_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("POST", pattern_Msg_UnjailClockContract_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Msg_UnjailClockContract_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Msg_UnjailClockContract_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) return nil } // RegisterMsgHandlerFromEndpoint is same as RegisterMsgHandler but // automatically dials to "endpoint" and closes the connection when "ctx" gets done. func RegisterMsgHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error) { conn, err := grpc.Dial(endpoint, opts...) if err != nil { return err } defer func() { if err != nil { if cerr := conn.Close(); cerr != nil { grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr) } return } go func() { <-ctx.Done() if cerr := conn.Close(); cerr != nil { grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr) } }() }() return RegisterMsgHandler(ctx, mux, conn) } // RegisterMsgHandler registers the http handlers for service Msg to "mux". // The handlers forward requests to the grpc endpoint over "conn". func RegisterMsgHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error { return RegisterMsgHandlerClient(ctx, mux, NewMsgClient(conn)) } // RegisterMsgHandlerClient registers the http handlers for service Msg // to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "MsgClient". // Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "MsgClient" // doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in // "MsgClient" to call the correct interceptors. func RegisterMsgHandlerClient(ctx context.Context, mux *runtime.ServeMux, client MsgClient) error { mux.Handle("POST", pattern_Msg_RegisterClockContract_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Msg_RegisterClockContract_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Msg_RegisterClockContract_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("POST", pattern_Msg_UnregisterClockContract_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Msg_UnregisterClockContract_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Msg_UnregisterClockContract_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("POST", pattern_Msg_UnjailClockContract_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Msg_UnjailClockContract_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Msg_UnjailClockContract_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) return nil } var ( pattern_Msg_RegisterClockContract_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4}, []string{"cyber", "clock", "v1", "tx", "register"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Msg_UnregisterClockContract_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4}, []string{"cyber", "clock", "v1", "tx", "unregister"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Msg_UnjailClockContract_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4}, []string{"cyber", "clock", "v1", "tx", "unjail"}, "", runtime.AssumeColonVerbOpt(false))) ) var ( forward_Msg_RegisterClockContract_0 = runtime.ForwardResponseMessage forward_Msg_UnregisterClockContract_0 = runtime.ForwardResponseMessage forward_Msg_UnjailClockContract_0 = runtime.ForwardResponseMessage ) ================================================ FILE: x/cyberbank/abci.go ================================================ package cyberbank import ( "time" "github.com/cosmos/cosmos-sdk/telemetry" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/cyberbank/keeper" "github.com/cybercongress/go-cyber/v7/x/cyberbank/types" ) func EndBlocker(ctx sdk.Context, k *keeper.IndexedKeeper) { defer telemetry.ModuleMeasureSince(types.ModuleName, time.Now(), telemetry.MetricKeyEndBlocker) k.UpdateAccountsStakeAmpere(ctx) } ================================================ FILE: x/cyberbank/keeper/genesis.go ================================================ package keeper import ( sdk "github.com/cosmos/cosmos-sdk/types" ) func (k *IndexedKeeper) InitGenesis(ctx sdk.Context) { for _, account := range k.accountKeeper.GetAllAccounts(ctx) { k.InitializeStakeAmpere( account.GetAccountNumber(), uint64(k.Proxy.GetAccountStakeAmperPlusRouted(ctx, account.GetAddress())), ) } } ================================================ FILE: x/cyberbank/keeper/keeper.go ================================================ package keeper import ( "fmt" "time" storetypes "github.com/cosmos/cosmos-sdk/store/types" "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" gogotypes "github.com/cosmos/gogoproto/types" "github.com/cometbft/cometbft/libs/log" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" "github.com/cybercongress/go-cyber/v7/x/cyberbank/types" ) type IndexedKeeper struct { *Proxy accountKeeper types.AccountKeeper cdc codec.BinaryCodec authKey storetypes.StoreKey userTotalStakeAmpere map[uint64]uint64 userNewTotalStakeAmpere map[uint64]uint64 accountToUpdate []sdk.AccAddress } func NewIndexedKeeper( cdc codec.BinaryCodec, authKey storetypes.StoreKey, pbk *Proxy, ak types.AccountKeeper, ) *IndexedKeeper { indexedKeeper := &IndexedKeeper{ Proxy: pbk, cdc: cdc, authKey: authKey, accountKeeper: ak, accountToUpdate: make([]sdk.AccAddress, 0), } hook := func(ctx sdk.Context, from sdk.AccAddress, to sdk.AccAddress) { if from != nil { indexedKeeper.accountToUpdate = append(indexedKeeper.accountToUpdate, from) } if to != nil { indexedKeeper.accountToUpdate = append(indexedKeeper.accountToUpdate, to) } } pbk.AddHook(hook) return indexedKeeper } func (k IndexedKeeper) Logger(ctx sdk.Context) log.Logger { return ctx.Logger().With("module", fmt.Sprintf("x/%s", types.ModuleName)) } func (k *IndexedKeeper) LoadState(rankCtx sdk.Context, freshCtx sdk.Context) { k.userTotalStakeAmpere = make(map[uint64]uint64) k.accountKeeper.IterateAccounts(rankCtx, k.getCollectFunc(rankCtx, k.userTotalStakeAmpere)) k.userNewTotalStakeAmpere = make(map[uint64]uint64) k.accountKeeper.IterateAccounts(freshCtx, k.getCollectFunc(freshCtx, k.userNewTotalStakeAmpere)) } func (k *IndexedKeeper) getCollectFunc(ctx sdk.Context, userStake map[uint64]uint64) func(account authtypes.AccountI) bool { return func(account authtypes.AccountI) bool { balance := k.Proxy.GetAccountStakeAmperPlusRouted(ctx, account.GetAddress()) userStake[account.GetAccountNumber()] = uint64(balance) return false } } func (k *IndexedKeeper) InitializeStakeAmpere(account uint64, stake uint64) { k.userTotalStakeAmpere[account] = stake k.userNewTotalStakeAmpere[account] = stake } func (k *IndexedKeeper) GetTotalStakesAmpere() map[uint64]uint64 { return k.userTotalStakeAmpere } func (k *IndexedKeeper) DetectUsersStakeAmpereChange(ctx sdk.Context) bool { stakeChanged := false for o, n := range k.userNewTotalStakeAmpere { if _, ok := k.userTotalStakeAmpere[o]; ok { if k.userTotalStakeAmpere[o] != n { stakeChanged = true k.userTotalStakeAmpere[o] = n } } else { k.userTotalStakeAmpere[o] = n } } return stakeChanged } func (k *IndexedKeeper) UpdateAccountsStakeAmpere(ctx sdk.Context) { for _, addr := range k.accountToUpdate { k.Logger(ctx).Debug("account to update:", "address", addr.String()) stake := k.GetAccountStakeAmperPlusRouted(ctx, addr) if k.accountKeeper.GetAccount(ctx, addr) == nil { k.Logger(ctx).Info("skipped account:", "address", addr.String()) continue } accountNumber := k.accountKeeper.GetAccount(ctx, addr).GetAccountNumber() k.userNewTotalStakeAmpere[accountNumber] = uint64(stake) } // trigger full account map rebuild in case of account' missing (and if new contract deployed) // TODO migrate logic to storage listener in sdk 46? // NOTE returns last not applied yet next! account number // equal to current length of accounts ids array, but last id is equal to next-1 nextAccountNumber := k.GetNextAccountNumber(ctx) if uint64(len(k.userNewTotalStakeAmpere)) != nextAccountNumber { startTime := time.Now() for i := nextAccountNumber - 1; i > 0; i-- { if _, ok := k.userNewTotalStakeAmpere[i]; !ok { k.Logger(ctx).Info("added to stake index:", "account", i) // TODO update in next release // stake := k.GetAccountStakeAmperPlusRouted(ctx, addr) k.userNewTotalStakeAmpere[i] = 0 } } k.Logger(ctx).Info("rebuild stake index:", "duration", time.Since(startTime).String()) } k.accountToUpdate = make([]sdk.AccAddress, 0) } func (k IndexedKeeper) GetNextAccountNumber(ctx sdk.Context) uint64 { var accNumber uint64 store := ctx.KVStore(k.authKey) bz := store.Get(authtypes.GlobalAccountNumberKey) if bz == nil { accNumber = 0 } else { val := gogotypes.UInt64Value{} err := k.cdc.Unmarshal(bz, &val) if err != nil { panic(err) } accNumber = val.GetValue() } return accNumber } ================================================ FILE: x/cyberbank/keeper/proxy.go ================================================ package keeper import ( context "context" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/query" authkeeper "github.com/cosmos/cosmos-sdk/x/auth/keeper" bank "github.com/cosmos/cosmos-sdk/x/bank/keeper" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" ctypes "github.com/cybercongress/go-cyber/v7/types" "github.com/cybercongress/go-cyber/v7/x/cyberbank/types" resourcestypes "github.com/cybercongress/go-cyber/v7/x/resources/types" ) var _ bank.Keeper = (*Proxy)(nil) const ResourcesTransferBurnPercentage = int64(2) type Proxy struct { bk bank.Keeper ak authkeeper.AccountKeeper ek types.EnergyKeeper gk types.GraphKeeper coinsTransferHooks []types.CoinsTransferHook } func (p *Proxy) SpendableCoin(ctx sdk.Context, addr sdk.AccAddress, denom string) sdk.Coin { return p.bk.SpendableCoin(ctx, addr, denom) } func (p *Proxy) IsSendEnabledDenom(ctx sdk.Context, denom string) bool { return p.bk.IsSendEnabledDenom(ctx, denom) } func (p *Proxy) GetSendEnabledEntry(ctx sdk.Context, denom string) (banktypes.SendEnabled, bool) { return p.bk.GetSendEnabledEntry(ctx, denom) } func (p *Proxy) SetSendEnabled(ctx sdk.Context, denom string, value bool) { p.bk.SetSendEnabled(ctx, denom, value) } func (p *Proxy) SetAllSendEnabled(ctx sdk.Context, sendEnableds []*banktypes.SendEnabled) { p.bk.SetAllSendEnabled(ctx, sendEnableds) } func (p *Proxy) DeleteSendEnabled(ctx sdk.Context, denoms ...string) { p.bk.DeleteSendEnabled(ctx, denoms...) } func (p *Proxy) IterateSendEnabledEntries(ctx sdk.Context, cb func(denom string, sendEnabled bool) (stop bool)) { p.bk.IterateSendEnabledEntries(ctx, cb) } func (p *Proxy) GetAllSendEnabledEntries(ctx sdk.Context) []banktypes.SendEnabled { return p.bk.GetAllSendEnabledEntries(ctx) } func (p *Proxy) GetBlockedAddresses() map[string]bool { return p.bk.GetBlockedAddresses() } func (p *Proxy) GetAuthority() string { return p.bk.GetAuthority() } func (p *Proxy) WithMintCoinsRestriction(fn bank.MintingRestrictionFn) bank.BaseKeeper { return p.bk.WithMintCoinsRestriction(fn) } func (p *Proxy) HasDenomMetaData(ctx sdk.Context, denom string) bool { return p.bk.HasDenomMetaData(ctx, denom) } func (p *Proxy) GetAllDenomMetaData(ctx sdk.Context) []banktypes.Metadata { return p.bk.GetAllDenomMetaData(ctx) } func (p *Proxy) SpendableBalanceByDenom(ctx context.Context, request *banktypes.QuerySpendableBalanceByDenomRequest) (*banktypes.QuerySpendableBalanceByDenomResponse, error) { return p.bk.SpendableBalanceByDenom(ctx, request) } func (p *Proxy) DenomOwners(ctx context.Context, request *banktypes.QueryDenomOwnersRequest) (*banktypes.QueryDenomOwnersResponse, error) { return p.bk.DenomOwners(ctx, request) } func (p *Proxy) SendEnabled(ctx context.Context, request *banktypes.QuerySendEnabledRequest) (*banktypes.QuerySendEnabledResponse, error) { return p.bk.SendEnabled(ctx, request) } func Wrap(bk bank.Keeper) *Proxy { return &Proxy{ bk: bk, coinsTransferHooks: make([]types.CoinsTransferHook, 0), } } func (p *Proxy) AddHook(hook types.CoinsTransferHook) { p.coinsTransferHooks = append(p.coinsTransferHooks, hook) } func (p *Proxy) SetGridKeeper(ek types.EnergyKeeper) { p.ek = ek } func (p *Proxy) SetAccountKeeper(ak authkeeper.AccountKeeper) { p.ak = ak } func (p *Proxy) SetGraphKeeper(gk types.GraphKeeper) { p.gk = gk } func (p *Proxy) OnCoinsTransfer(ctx sdk.Context, from sdk.AccAddress, to sdk.AccAddress) { for _, hook := range p.coinsTransferHooks { hook(ctx, from, to) } } func (p Proxy) GetTotalSupplyVolt(ctx sdk.Context) int64 { return p.bk.GetSupply(ctx, ctypes.VOLT).Amount.Int64() } func (p Proxy) GetTotalSupplyAmper(ctx sdk.Context) int64 { return p.bk.GetSupply(ctx, ctypes.AMPERE).Amount.Int64() } func (p Proxy) GetAccountStakeVolt(ctx sdk.Context, addr sdk.AccAddress) int64 { return p.bk.GetBalance(ctx, addr, ctypes.VOLT).Amount.Int64() } func (p Proxy) GetAccountStakeAmperPlusRouted(ctx sdk.Context, addr sdk.AccAddress) int64 { return p.bk.GetBalance(ctx, addr, ctypes.AMPERE).Amount.Int64() + p.GetRoutedTo(ctx, addr).AmountOf(ctypes.AMPERE).Int64() } func (p Proxy) GetRoutedTo(ctx sdk.Context, addr sdk.AccAddress) sdk.Coins { return p.ek.GetRoutedToEnergy(ctx, addr) } // ----------------------------------------------------------------- func (p *Proxy) InputOutputCoins(ctx sdk.Context, inputs []banktypes.Input, outputs []banktypes.Output) error { err := p.bk.InputOutputCoins(ctx, inputs, outputs) if err == nil { for _, i := range inputs { inAddress, _ := sdk.AccAddressFromBech32(i.Address) p.OnCoinsTransfer(ctx, inAddress, nil) } for _, j := range outputs { outAddress, _ := sdk.AccAddressFromBech32(j.Address) p.OnCoinsTransfer(ctx, nil, outAddress) } } return err } func (p *Proxy) SendCoins(ctx sdk.Context, fromAddr sdk.AccAddress, toAddr sdk.AccAddress, amt sdk.Coins) error { // Calculate 2% burn for milliampere and millivolt denoms burnCoins := sdk.NewCoins() netCoins := sdk.NewCoins() for _, c := range amt { if c.Denom == "milliampere" || c.Denom == "millivolt" { fee := c.Amount.MulRaw(ResourcesTransferBurnPercentage).QuoRaw(100) if fee.IsPositive() { burnCoins = burnCoins.Add(sdk.NewCoin(c.Denom, fee)) netAmt := c.Amount.Sub(fee) if netAmt.IsPositive() { netCoins = netCoins.Add(sdk.NewCoin(c.Denom, netAmt)) } continue } } netCoins = netCoins.Add(c) } // Burn the fee portion via the resources module account if burnCoins.IsAllPositive() { if err := p.bk.SendCoinsFromAccountToModule(ctx, fromAddr, resourcestypes.ResourcesName, burnCoins); err != nil { return err } if err := p.bk.BurnCoins(ctx, resourcestypes.ResourcesName, burnCoins); err != nil { return err } if burnCoins.AmountOf(ctypes.VOLT).IsPositive() { p.gk.AddBurnedVolts(ctx, burnCoins.AmountOf(ctypes.VOLT).Uint64()) } if burnCoins.AmountOf(ctypes.VOLT).IsPositive() { p.gk.AddBurnedAmperes(ctx, burnCoins.AmountOf(ctypes.AMPERE).Uint64()) } } // Send the net amount to the recipient if netCoins.IsAllPositive() { if err := p.bk.SendCoins(ctx, fromAddr, toAddr, netCoins); err != nil { return err } } // Fire transfer hooks once for the logical transfer p.OnCoinsTransfer(ctx, fromAddr, toAddr) return nil } func (p *Proxy) DenomMetadata(ctx context.Context, request *banktypes.QueryDenomMetadataRequest) (*banktypes.QueryDenomMetadataResponse, error) { return p.bk.DenomMetadata(ctx, request) } func (p *Proxy) DenomsMetadata(ctx context.Context, request *banktypes.QueryDenomsMetadataRequest) (*banktypes.QueryDenomsMetadataResponse, error) { return p.bk.DenomsMetadata(ctx, request) } func (p *Proxy) SendCoinsFromModuleToAccount(ctx sdk.Context, senderModule string, recipientAddr sdk.AccAddress, amt sdk.Coins) error { err := p.bk.SendCoinsFromModuleToAccount(ctx, senderModule, recipientAddr, amt) if err == nil { p.OnCoinsTransfer(ctx, p.ak.GetModuleAddress(senderModule), recipientAddr) } return err } func (p *Proxy) SendCoinsFromModuleToModule(ctx sdk.Context, senderModule, recipientModule string, amt sdk.Coins) error { err := p.bk.SendCoinsFromModuleToModule(ctx, senderModule, recipientModule, amt) return err } func (p *Proxy) SendCoinsFromAccountToModule(ctx sdk.Context, senderAddr sdk.AccAddress, recipientModule string, amt sdk.Coins) error { err := p.bk.SendCoinsFromAccountToModule(ctx, senderAddr, recipientModule, amt) if err == nil { p.OnCoinsTransfer(ctx, senderAddr, p.ak.GetModuleAddress(recipientModule)) } return err } func (p *Proxy) ValidateBalance(ctx sdk.Context, addr sdk.AccAddress) error { return p.bk.ValidateBalance(ctx, addr) } func (p *Proxy) HasBalance(ctx sdk.Context, addr sdk.AccAddress, amt sdk.Coin) bool { return p.bk.HasBalance(ctx, addr, amt) } func (p *Proxy) GetAllBalances(ctx sdk.Context, addr sdk.AccAddress) sdk.Coins { return p.bk.GetAllBalances(ctx, addr) } func (p *Proxy) GetAccountsBalances(ctx sdk.Context) []banktypes.Balance { return p.bk.GetAccountsBalances(ctx) } func (p *Proxy) GetBalance(ctx sdk.Context, addr sdk.AccAddress, denom string) sdk.Coin { return p.bk.GetBalance(ctx, addr, denom) } func (p *Proxy) LockedCoins(ctx sdk.Context, addr sdk.AccAddress) sdk.Coins { return p.bk.LockedCoins(ctx, addr) } func (p *Proxy) SpendableCoins(ctx sdk.Context, addr sdk.AccAddress) sdk.Coins { return p.bk.SpendableCoins(ctx, addr) } func (p *Proxy) IterateAccountBalances(ctx sdk.Context, addr sdk.AccAddress, cb func(coin sdk.Coin) (stop bool)) { p.bk.IterateAccountBalances(ctx, addr, cb) } func (p *Proxy) IterateAllBalances(ctx sdk.Context, cb func(address sdk.AccAddress, coin sdk.Coin) (stop bool)) { p.bk.IterateAllBalances(ctx, cb) } func (p *Proxy) GetParams(ctx sdk.Context) banktypes.Params { return p.bk.GetParams(ctx) } func (p *Proxy) SetParams(ctx sdk.Context, params banktypes.Params) error { return p.bk.SetParams(ctx, params) } func (p *Proxy) BlockedAddr(addr sdk.AccAddress) bool { return p.bk.BlockedAddr(addr) } func (p *Proxy) InitGenesis(context sdk.Context, state *banktypes.GenesisState) { p.bk.InitGenesis(context, state) } func (p *Proxy) ExportGenesis(context sdk.Context) *banktypes.GenesisState { return p.bk.ExportGenesis(context) } func (p *Proxy) GetSupply(ctx sdk.Context, denom string) sdk.Coin { return p.bk.GetSupply(ctx, denom) } func (p *Proxy) IsSendEnabledCoin(ctx sdk.Context, coin sdk.Coin) bool { return p.bk.IsSendEnabledCoin(ctx, coin) } func (p *Proxy) IsSendEnabledCoins(ctx sdk.Context, coins ...sdk.Coin) error { return p.bk.IsSendEnabledCoins(ctx, coins...) } func (p *Proxy) GetPaginatedTotalSupply(ctx sdk.Context, pagination *query.PageRequest) (sdk.Coins, *query.PageResponse, error) { return p.bk.GetPaginatedTotalSupply(ctx, pagination) } func (p *Proxy) IterateTotalSupply(ctx sdk.Context, cb func(sdk.Coin) bool) { p.bk.IterateTotalSupply(ctx, cb) } func (p *Proxy) GetDenomMetaData(ctx sdk.Context, denom string) (banktypes.Metadata, bool) { return p.bk.GetDenomMetaData(ctx, denom) } func (p *Proxy) SetDenomMetaData(ctx sdk.Context, denomMetaData banktypes.Metadata) { p.bk.SetDenomMetaData(ctx, denomMetaData) } func (p *Proxy) IterateAllDenomMetaData(ctx sdk.Context, cb func(banktypes.Metadata) bool) { p.bk.IterateAllDenomMetaData(ctx, cb) } func (p *Proxy) DelegateCoinsFromAccountToModule(ctx sdk.Context, senderAddr sdk.AccAddress, recipientModule string, amt sdk.Coins) error { return p.bk.DelegateCoinsFromAccountToModule(ctx, senderAddr, recipientModule, amt) } func (p *Proxy) UndelegateCoinsFromModuleToAccount(ctx sdk.Context, senderModule string, recipientAddr sdk.AccAddress, amt sdk.Coins) error { return p.bk.UndelegateCoinsFromModuleToAccount(ctx, senderModule, recipientAddr, amt) } func (p *Proxy) MintCoins(ctx sdk.Context, moduleName string, amt sdk.Coins) error { return p.bk.MintCoins(ctx, moduleName, amt) } func (p *Proxy) BurnCoins(ctx sdk.Context, moduleName string, amt sdk.Coins) error { return p.bk.BurnCoins(ctx, moduleName, amt) } func (p *Proxy) DelegateCoins(ctx sdk.Context, delegatorAddr, moduleAccAddr sdk.AccAddress, amt sdk.Coins) error { return p.bk.DelegateCoins(ctx, delegatorAddr, moduleAccAddr, amt) } func (p *Proxy) UndelegateCoins(ctx sdk.Context, moduleAccAddr, delegatorAddr sdk.AccAddress, amt sdk.Coins) error { return p.bk.UndelegateCoins(ctx, moduleAccAddr, delegatorAddr, amt) } func (p *Proxy) Balance(ctx context.Context, request *banktypes.QueryBalanceRequest) (*banktypes.QueryBalanceResponse, error) { return p.bk.Balance(ctx, request) } func (p *Proxy) AllBalances(ctx context.Context, request *banktypes.QueryAllBalancesRequest) (*banktypes.QueryAllBalancesResponse, error) { return p.bk.AllBalances(ctx, request) } func (p *Proxy) TotalSupply(ctx context.Context, request *banktypes.QueryTotalSupplyRequest) (*banktypes.QueryTotalSupplyResponse, error) { return p.bk.TotalSupply(ctx, request) } func (p *Proxy) SupplyOf(ctx context.Context, request *banktypes.QuerySupplyOfRequest) (*banktypes.QuerySupplyOfResponse, error) { return p.bk.SupplyOf(ctx, request) } func (p *Proxy) Params(ctx context.Context, request *banktypes.QueryParamsRequest) (*banktypes.QueryParamsResponse, error) { return p.bk.Params(ctx, request) } func (p *Proxy) SpendableBalances(ctx context.Context, request *banktypes.QuerySpendableBalancesRequest) (*banktypes.QuerySpendableBalancesResponse, error) { return p.bk.SpendableBalances(ctx, request) } func (p *Proxy) HasSupply(ctx sdk.Context, denom string) bool { return p.bk.HasSupply(ctx, denom) } ================================================ FILE: x/cyberbank/keeper/snapshotter.go ================================================ package keeper import ( "github.com/cometbft/cometbft/libs/log" tmproto "github.com/cometbft/cometbft/proto/tendermint/types" snapshot "github.com/cosmos/cosmos-sdk/snapshots/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/cyberbank/types" ) var _ snapshot.ExtensionSnapshotter = &CyberbankSnapshotter{} const SnapshotFormat = 1 type CyberbankSnapshotter struct { indexedKeeper *IndexedKeeper cms sdk.MultiStore } func NewCyberbankSnapshotter(cms sdk.MultiStore, indexedKeeper *IndexedKeeper) *CyberbankSnapshotter { return &CyberbankSnapshotter{ indexedKeeper: indexedKeeper, cms: cms, } } func (cs *CyberbankSnapshotter) SnapshotName() string { return types.ModuleName } func (cs *CyberbankSnapshotter) SnapshotFormat() uint32 { return SnapshotFormat } func (cs *CyberbankSnapshotter) SupportedFormats() []uint32 { // If we support older formats, add them here and handle them in Restore return []uint32{SnapshotFormat} } func (cs *CyberbankSnapshotter) SnapshotExtension(_ uint64, _ snapshot.ExtensionPayloadWriter) error { return nil } func (cs *CyberbankSnapshotter) RestoreExtension(height uint64, format uint32, _ snapshot.ExtensionPayloadReader) error { if format == SnapshotFormat { freshCtx := sdk.NewContext(cs.cms, tmproto.Header{Height: int64(height)}, false, log.NewNopLogger()) // TODO revisit with get params and case of increased rank computation blocks calculationPeriod := int64(5) rankRoundBlockNumber := (freshCtx.BlockHeight() / calculationPeriod) * calculationPeriod store, err := cs.cms.CacheMultiStoreWithVersion(rankRoundBlockNumber) if err != nil { println("Error: ", err) } rankCtx := sdk.NewContext(store, tmproto.Header{Height: rankRoundBlockNumber}, false, log.NewNopLogger()) cs.indexedKeeper.LoadState(rankCtx, freshCtx) return nil } return snapshot.ErrUnknownFormat } ================================================ FILE: x/cyberbank/module.go ================================================ package cyberbank import ( "encoding/json" "github.com/cosmos/cosmos-sdk/client" codectypes "github.com/cosmos/cosmos-sdk/codec/types" "github.com/gorilla/mux" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/spf13/cobra" abci "github.com/cometbft/cometbft/abci/types" "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" "github.com/cybercongress/go-cyber/v7/x/cyberbank/keeper" "github.com/cybercongress/go-cyber/v7/x/cyberbank/types" ) var ( _ module.AppModule = AppModule{} _ module.AppModuleBasic = AppModuleBasic{} ) type AppModuleBasic struct { cdc codec.Codec } func (AppModuleBasic) Name() string { return types.ModuleName } func (AppModuleBasic) RegisterLegacyAminoCodec(_ *codec.LegacyAmino) {} func (AppModuleBasic) DefaultGenesis(_ codec.JSONCodec) json.RawMessage { return nil } func (AppModuleBasic) ValidateGenesis(_ codec.JSONCodec, _ client.TxEncodingConfig, _ json.RawMessage) error { return nil } func (AppModuleBasic) RegisterRESTRoutes(_ client.Context, _ *mux.Router) {} func (AppModuleBasic) RegisterGRPCGatewayRoutes(_ client.Context, _ *runtime.ServeMux) {} func (AppModuleBasic) GetTxCmd() *cobra.Command { return nil } func (AppModuleBasic) GetQueryCmd() *cobra.Command { return nil } func (AppModuleBasic) RegisterInterfaces(_ codectypes.InterfaceRegistry) {} type AppModule struct { AppModuleBasic keeper *keeper.IndexedKeeper } func NewAppModule( cdc codec.Codec, ik *keeper.IndexedKeeper, ) AppModule { return AppModule{ AppModuleBasic: AppModuleBasic{cdc: cdc}, keeper: ik, } } func (AppModule) Name() string { return types.ModuleName } func (AppModule) RegisterInvariants(_ sdk.InvariantRegistry) {} func (AppModule) RegisterServices(_ module.Configurator) {} func (am AppModule) InitGenesis(ctx sdk.Context, _ codec.JSONCodec, _ json.RawMessage) []abci.ValidatorUpdate { // this will be called by the app module manager because of null module params in genesis, used direct call in InitChainer // am.keeper.InitGenesis(ctx) return []abci.ValidatorUpdate{} } func (AppModule) ExportGenesis(_ sdk.Context, _ codec.JSONCodec) json.RawMessage { return nil } func (am AppModule) ConsensusVersion() uint64 { return 1 } func (AppModule) BeginBlock(_ sdk.Context, _ abci.RequestBeginBlock) {} func (am AppModule) EndBlock(ctx sdk.Context, _ abci.RequestEndBlock) []abci.ValidatorUpdate { EndBlocker(ctx, am.keeper) return []abci.ValidatorUpdate{} } ================================================ FILE: x/cyberbank/spec/00_concepts.md ================================================ # Concepts # In-memory token balance index # Balance change hooks # Consitency of balances ================================================ FILE: x/cyberbank/spec/02_state.md ================================================ ================================================ FILE: x/cyberbank/spec/03_state_transitions.md ================================================ ================================================ FILE: x/cyberbank/spec/README.md ================================================ # `cyberbank` ## Abstract The cyberbank module is the module that wraps the original Cosmos-SDK's bank module while providing extra functionality: 1. tracks of neuron's VOLTs balance change for [bandwidth](../../bandwidth/spec/README.md) module to adjust neuron's personal bandwidth 2. keeps two in-memory indexes of AMPEREs balances for the [rank](../../rank/spec/README.md) module (one index for last calculation and one for the next one) 3. tracking of routed to neurons resources (VOLTs and AMPEREs) from [energy](../../grid/spec/README.md) module Note: cyberbank wrapper keep all his state completely in-memory and not introduce any new modification to application storage ## Contents 1. **[Concepts](00_concepts.md)** 3. **[State](02_state.md)** 4. **[State Transitions](03_state_transitions.md)** ================================================ FILE: x/cyberbank/types/expected_keepers.go ================================================ package types import ( sdk "github.com/cosmos/cosmos-sdk/types" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" ) type AccountKeeper interface { IterateAccounts(ctx sdk.Context, process func(i authtypes.AccountI) (stop bool)) GetAccount(ctx sdk.Context, addr sdk.AccAddress) authtypes.AccountI GetAllAccounts(ctx sdk.Context) (accounts []authtypes.AccountI) } type EnergyKeeper interface { GetRoutedToEnergy(ctx sdk.Context, delegate sdk.AccAddress) sdk.Coins } type GraphKeeper interface { AddBurnedVolts(ctx sdk.Context, toBurn uint64) AddBurnedAmperes(ctx sdk.Context, toBurn uint64) } ================================================ FILE: x/cyberbank/types/hook.go ================================================ package types import sdk "github.com/cosmos/cosmos-sdk/types" type CoinsTransferHook = func(ctx sdk.Context, from sdk.AccAddress, to sdk.AccAddress) ================================================ FILE: x/cyberbank/types/keys.go ================================================ package types const ( ModuleName = "cyberbank" ) ================================================ FILE: x/dmn/abci.go ================================================ package dmn import ( "time" "github.com/cosmos/cosmos-sdk/telemetry" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/dmn/keeper" "github.com/cybercongress/go-cyber/v7/x/dmn/types" ) func BeginBlock(ctx sdk.Context, k keeper.Keeper) { defer telemetry.ModuleMeasureSince(types.ModuleName, time.Now(), telemetry.MetricKeyBeginBlocker) k.ExecuteThoughtsQueue(ctx) // TODO add block event } ================================================ FILE: x/dmn/client/cli/query.go ================================================ package cli import ( "context" "fmt" "github.com/cosmos/cosmos-sdk/client/flags" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/spf13/cobra" "github.com/cosmos/cosmos-sdk/client" "github.com/cybercongress/go-cyber/v7/x/dmn/types" ) func GetQueryCmd() *cobra.Command { queryCmd := &cobra.Command{ Use: types.ModuleName, Short: fmt.Sprintf("Querying commands for the %s module", types.ModuleName), DisableFlagParsing: true, SuggestionsMinimumDistance: 2, RunE: client.ValidateCmd, } queryCmd.AddCommand( GetCmdQueryParams(), GetCmdQueryThought(), GetCmdQueryThoughtStats(), GetCmdQueryThoughts(), GetCmdQueryThoughtsStats(), ) return queryCmd } func GetCmdQueryParams() *cobra.Command { cmd := &cobra.Command{ Use: "params", Args: cobra.NoArgs, Short: "Query the current dmn module parameters information", RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientQueryContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) res, err := queryClient.Params( context.Background(), &types.QueryParamsRequest{}, ) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } func GetCmdQueryThought() *cobra.Command { cmd := &cobra.Command{ Use: "thought [program] [name]", Short: "Query thought", Args: cobra.ExactArgs(2), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientQueryContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) program, err := sdk.AccAddressFromBech32(args[0]) if err != nil { return err } res, err := queryClient.Thought( context.Background(), &types.QueryThoughtParamsRequest{ Program: program.String(), Name: args[1], }, ) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } func GetCmdQueryThoughtStats() *cobra.Command { cmd := &cobra.Command{ Use: "thought-stats [program] [name]", Short: "Query thought stats", Args: cobra.ExactArgs(2), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientQueryContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) program, err := sdk.AccAddressFromBech32(args[0]) if err != nil { return err } res, err := queryClient.ThoughtStats( context.Background(), &types.QueryThoughtParamsRequest{ Program: program.String(), Name: args[1], }, ) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } func GetCmdQueryThoughts() *cobra.Command { cmd := &cobra.Command{ Use: "thoughts", Short: "Query all thoughts", Args: cobra.ExactArgs(0), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientQueryContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) res, err := queryClient.Thoughts( context.Background(), &types.QueryThoughtsRequest{}, ) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } func GetCmdQueryThoughtsStats() *cobra.Command { cmd := &cobra.Command{ Use: "thoughts-stats", Short: "Query all thoughts stats", Args: cobra.ExactArgs(0), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientQueryContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) res, err := queryClient.ThoughtsStats( context.Background(), &types.QueryThoughtsStatsRequest{}, ) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } ================================================ FILE: x/dmn/exported/exported.go ================================================ package exported import ( sdk "github.com/cosmos/cosmos-sdk/types" paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" ) type ( ParamSet = paramtypes.ParamSet // Subspace defines an interface that implements the legacy x/params Subspace // type. // // NOTE: This is used solely for migration of x/params managed parameters. Subspace interface { GetParamSet(ctx sdk.Context, ps ParamSet) } ) ================================================ FILE: x/dmn/keeper/genesis.go ================================================ package keeper import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/dmn/types" ) func InitGenesis(ctx sdk.Context, k Keeper, data types.GenesisState) { err := k.SetParams(ctx, data.Params) if err != nil { panic(err) } } func ExportGenesis(ctx sdk.Context, k Keeper) *types.GenesisState { params := k.GetParams(ctx) return types.NewGenesisState(params) } ================================================ FILE: x/dmn/keeper/grpc_query.go ================================================ package keeper import ( "context" ctypes "github.com/cybercongress/go-cyber/v7/types" sdk "github.com/cosmos/cosmos-sdk/types" "google.golang.org/grpc/codes" "google.golang.org/grpc/status" "github.com/cybercongress/go-cyber/v7/x/dmn/types" ) var _ types.QueryServer = Keeper{} func (k Keeper) Params(goCtx context.Context, request *types.QueryParamsRequest) (*types.QueryParamsResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) params := k.GetParams(ctx) return &types.QueryParamsResponse{Params: params}, nil } func (k Keeper) Thought(goCtx context.Context, request *types.QueryThoughtParamsRequest) (*types.QueryThoughtResponse, error) { if request == nil { return nil, status.Errorf(codes.InvalidArgument, "empty request") } if request.Program == "" { return nil, status.Errorf(codes.InvalidArgument, "program address cannot be empty") } if request.Name == "" { return nil, status.Errorf(codes.InvalidArgument, "thought name cannot be empty") } program, err := sdk.AccAddressFromBech32(request.Program) if err != nil { return nil, err } ctx := sdk.UnwrapSDKContext(goCtx) thought, found := k.GetThought(ctx, program, request.Name) if !found { return nil, status.Errorf(codes.NotFound, "thought with program %s and name %s not found", request.Program, request.Name) } return &types.QueryThoughtResponse{Thought: thought}, nil } func (k Keeper) ThoughtStats(goCtx context.Context, request *types.QueryThoughtParamsRequest) (*types.QueryThoughtStatsResponse, error) { if request == nil { return nil, status.Errorf(codes.InvalidArgument, "empty request") } if request.Program == "" { return nil, status.Errorf(codes.InvalidArgument, "program address cannot be empty") } if request.Name == "" { return nil, status.Errorf(codes.InvalidArgument, "thought name cannot be empty") } program, err := sdk.AccAddressFromBech32(request.Program) if err != nil { return nil, err } ctx := sdk.UnwrapSDKContext(goCtx) thoughtStats, found := k.GetThoughtStats(ctx, program, request.Name) if !found { return nil, status.Errorf(codes.NotFound, "thought stats with program %s and name %s not found", request.Program, request.Name) } return &types.QueryThoughtStatsResponse{ThoughtStats: thoughtStats}, nil } func (k Keeper) Thoughts(goCtx context.Context, _ *types.QueryThoughtsRequest) (*types.QueryThoughtsResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) thoughts := k.GetAllThoughts(ctx) return &types.QueryThoughtsResponse{Thoughts: thoughts}, nil } func (k Keeper) ThoughtsStats(goCtx context.Context, _ *types.QueryThoughtsStatsRequest) (*types.QueryThoughtsStatsResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) thoughtsStats := k.GetAllThoughtsStats(ctx) return &types.QueryThoughtsStatsResponse{ThoughtsStats: thoughtsStats}, nil } func (k Keeper) ThoughtsFees(goCtx context.Context, _ *types.QueryThoughtsFeesRequest) (*types.QueryThoughtsFeesResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) thoughts := k.GetAllThoughts(ctx) if len(thoughts) == 0 { return &types.QueryThoughtsFeesResponse{Fees: sdk.NewCoins(ctypes.NewCybCoin(0))}, nil } thoughts.Sort() var fees sdk.Coins for _, thought := range thoughts { fees = append(fees, thought.Load.GasPrice) } return &types.QueryThoughtsFeesResponse{Fees: fees}, nil } ================================================ FILE: x/dmn/keeper/keeper.go ================================================ package keeper import ( "encoding/base64" "encoding/hex" "fmt" storetypes "github.com/cosmos/cosmos-sdk/store/types" "github.com/CosmWasm/wasmd/x/wasm" "github.com/cometbft/cometbft/libs/log" "github.com/cosmos/cosmos-sdk/telemetry" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" paramstypes "github.com/cosmos/cosmos-sdk/x/params/types" "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" ctypes "github.com/cybercongress/go-cyber/v7/types" "github.com/cybercongress/go-cyber/v7/x/dmn/types" graphtypes "github.com/cybercongress/go-cyber/v7/x/graph/types" ) // Keeper of the power store type Keeper struct { storeKey storetypes.StoreKey cdc codec.BinaryCodec wasmKeeper wasm.Keeper accountKeeper types.AccountKeeper proxyKeeper types.BankKeeper paramspace paramstypes.Subspace authority string } func NewKeeper( cdc codec.BinaryCodec, key storetypes.StoreKey, bk types.BankKeeper, ak types.AccountKeeper, authority string, ) *Keeper { return &Keeper{ storeKey: key, cdc: cdc, proxyKeeper: bk, accountKeeper: ak, authority: authority, } } func (k *Keeper) SetWasmKeeper(ws wasm.Keeper) { k.wasmKeeper = ws } // GetAuthority returns the x/mint module's authority. func (k Keeper) GetAuthority() string { return k.authority } func (k Keeper) Logger(ctx sdk.Context) log.Logger { return ctx.Logger().With("module", fmt.Sprintf("x/%s", types.ModuleName)) } func (k Keeper) SetParams(ctx sdk.Context, p types.Params) error { if err := p.Validate(); err != nil { return err } store := ctx.KVStore(k.storeKey) bz := k.cdc.MustMarshal(&p) store.Set(types.ParamsKey, bz) return nil } func (k Keeper) GetParams(ctx sdk.Context) (p types.Params) { store := ctx.KVStore(k.storeKey) bz := store.Get(types.ParamsKey) if bz == nil { return p } k.cdc.MustUnmarshal(bz, &p) return p } func (k Keeper) SaveThought( ctx sdk.Context, program sdk.AccAddress, trigger types.Trigger, load types.Load, name string, particle graphtypes.Cid, ) error { if trigger.Block != 0 && ctx.BlockHeight() > int64(trigger.Block) { return types.ErrBadTrigger } // if there are full slots but new one with higher fee than delete thought with // the smallest one fee and add new one with higher fee thoughts := k.GetAllThoughts(ctx) thoughts.Sort() if uint32(len(thoughts)) == k.MaxThougths(ctx) { if thoughts[len(thoughts)-1].Load.GasPrice.IsLT(load.GasPrice) { pr, _ := sdk.AccAddressFromBech32(thoughts[len(thoughts)-1].Program) k.DeleteThought(ctx, pr, thoughts[len(thoughts)-1].Name) k.DeleteThoughtStats(ctx, pr, name) } else { return types.ErrExceededMaxThoughts } } k.SetThought(ctx, types.NewThought( program.String(), trigger, load, name, string(particle), )) // set last_block to current height to start count future ttl fee k.SetThoughtStats(ctx, program, name, types.NewStats( program.String(), name, 0, 0, 0, uint64(ctx.BlockHeight()), ), ) return nil } func (k Keeper) RemoveThoughtFull( ctx sdk.Context, program sdk.AccAddress, name string, ) error { _, found := k.GetThought(ctx, program, name) if !found { return types.ErrThoughtNotExist } k.DeleteThought(ctx, program, name) k.DeleteThoughtStats(ctx, program, name) return nil } func (k Keeper) UpdateThoughtParticle( ctx sdk.Context, program sdk.AccAddress, name string, particle graphtypes.Cid, ) error { thought, found := k.GetThought(ctx, program, name) if !found { return types.ErrThoughtNotExist } k.SetThought(ctx, types.NewThought( thought.Program, thought.Trigger, thought.Load, thought.Name, string(particle), )) return nil } func (k Keeper) UpdateThoughtName( ctx sdk.Context, program sdk.AccAddress, name string, nameNew string, ) error { thought, found := k.GetThought(ctx, program, name) if !found { return types.ErrThoughtNotExist } thoughtStats, _ := k.GetThoughtStats(ctx, program, name) if thought.Name == nameNew { return types.ErrBadName } k.DeleteThought(ctx, program, name) k.DeleteThoughtStats(ctx, program, name) k.SetThought(ctx, types.NewThought( thought.Program, thought.Trigger, thought.Load, nameNew, thought.Particle, )) k.SetThoughtStats(ctx, program, nameNew, types.NewStats( program.String(), nameNew, thoughtStats.Calls, thoughtStats.Fees, thoughtStats.Fees, thoughtStats.LastBlock, )) return nil } func (k Keeper) UpdateThoughtCallData( ctx sdk.Context, program sdk.AccAddress, name string, calldata string, ) error { thought, found := k.GetThought(ctx, program, name) if !found { return types.ErrThoughtNotExist } k.SetThought(ctx, types.NewThought( thought.Program, thought.Trigger, types.NewLoad(calldata, thought.Load.GasPrice), thought.Name, thought.Particle, )) return nil } func (k Keeper) UpdateThoughtGasPrice( ctx sdk.Context, program sdk.AccAddress, name string, gasprice sdk.Coin, ) error { thought, found := k.GetThought(ctx, program, name) if !found { return types.ErrThoughtNotExist } k.SetThought(ctx, types.NewThought( thought.Program, thought.Trigger, types.NewLoad(thought.Load.Input, gasprice), thought.Name, thought.Particle, )) return nil } func (k Keeper) UpdateThoughtPeriod( ctx sdk.Context, program sdk.AccAddress, name string, period uint64, ) error { thought, found := k.GetThought(ctx, program, name) if !found { return types.ErrThoughtNotExist } if thought.Trigger.Block > 0 { return types.ErrConvertTrigger } k.SetThought(ctx, types.NewThought( thought.Program, types.NewTrigger(period, thought.Trigger.Block), thought.Load, thought.Name, thought.Particle, )) return nil } func (k Keeper) UpdateThoughtBlock( ctx sdk.Context, program sdk.AccAddress, name string, block uint64, ) error { thought, found := k.GetThought(ctx, program, name) if !found { return types.ErrThoughtNotExist } if ctx.BlockHeight() >= int64(block) { return types.ErrBadTrigger } if thought.Trigger.Period > 0 { return types.ErrConvertTrigger } k.SetThought(ctx, types.NewThought( thought.Program, types.NewTrigger(thought.Trigger.Period, block), thought.Load, thought.Name, thought.Particle, )) return nil } func (k Keeper) MaxThougths(ctx sdk.Context) (res uint32) { return k.GetParams(ctx).MaxSlots } func (k Keeper) MaxGas(ctx sdk.Context) (res uint32) { return k.GetParams(ctx).MaxGas } func (k Keeper) FeeTTL(ctx sdk.Context) (res uint32) { return k.GetParams(ctx).FeeTtl } func (k Keeper) SetThought(ctx sdk.Context, thought types.Thought) { store := ctx.KVStore(k.storeKey) b := k.cdc.MustMarshal(&thought) program, _ := sdk.AccAddressFromBech32(thought.Program) store.Set(types.GetThoughtKey(program, thought.Name), b) } func (k Keeper) DeleteThought(ctx sdk.Context, program sdk.AccAddress, name string) { store := ctx.KVStore(k.storeKey) store.Delete(types.GetThoughtKey(program, name)) } func (k Keeper) SetThoughts(ctx sdk.Context, thoughts types.Thoughts) error { for _, thought := range thoughts { k.SetThought(ctx, types.NewThought( thought.Program, thought.Trigger, thought.Load, thought.Name, thought.Particle, )) } return nil } func (k Keeper) SetThoughtStats(ctx sdk.Context, program sdk.AccAddress, name string, stats types.ThoughtStats) { store := ctx.KVStore(k.storeKey) b := k.cdc.MustMarshal(&stats) store.Set(types.GetThoughtStatsKey(program, name), b) } func (k Keeper) DeleteThoughtStats(ctx sdk.Context, program sdk.AccAddress, name string) { store := ctx.KVStore(k.storeKey) store.Delete(types.GetThoughtStatsKey(program, name)) } func (k Keeper) GetThought(ctx sdk.Context, program sdk.AccAddress, name string) (thought types.Thought, found bool) { store := ctx.KVStore(k.storeKey) key := types.GetThoughtKey(program, name) value := store.Get(key) if value == nil { return thought, false } k.cdc.MustUnmarshal(value, &thought) return thought, true } func (k Keeper) GetAllThoughts(ctx sdk.Context) (thoughts types.Thoughts) { k.IterateAllThoughts(ctx, func(thought types.Thought) bool { thoughts = append(thoughts, thought) return false }) return thoughts } func (k Keeper) GetAllThoughtsStats(ctx sdk.Context) (thoughtsStats types.ThoughtsStats) { k.IterateAllThoughtsStats(ctx, func(thoughtStats types.ThoughtStats) bool { thoughtsStats = append(thoughtsStats, thoughtStats) return false }) return thoughtsStats } func (k Keeper) IterateAllThoughtsStats(ctx sdk.Context, cb func(thoughtStats types.ThoughtStats) (stop bool)) { store := ctx.KVStore(k.storeKey) iterator := sdk.KVStorePrefixIterator(store, types.ThoughtStatsKey) defer iterator.Close() for ; iterator.Valid(); iterator.Next() { var thoughtStats types.ThoughtStats k.cdc.MustUnmarshal(iterator.Value(), &thoughtStats) if cb(thoughtStats) { break } } } func (k Keeper) IterateAllThoughts(ctx sdk.Context, cb func(thought types.Thought) (stop bool)) { store := ctx.KVStore(k.storeKey) iterator := sdk.KVStorePrefixIterator(store, types.ThoughtKey) defer iterator.Close() for ; iterator.Valid(); iterator.Next() { var thought types.Thought k.cdc.MustUnmarshal(iterator.Value(), &thought) if cb(thought) { break } } } func (k Keeper) GetThoughtStats(ctx sdk.Context, program sdk.AccAddress, name string) (stats types.ThoughtStats, found bool) { store := ctx.KVStore(k.storeKey) key := types.GetThoughtStatsKey(program, name) value := store.Get(key) if value == nil { return stats, false } k.cdc.MustUnmarshal(value, &stats) return stats, true } func (k Keeper) ExecuteThoughtsQueue(ctx sdk.Context) { defer func() { if r := recover(); r != nil { switch rType := r.(type) { case sdk.ErrorOutOfGas: errorMsg := fmt.Sprintf( "out of gas in location: %v; gasUsed: %d", rType.Descriptor, ctx.GasMeter().GasConsumed(), ) k.Logger(ctx).Error(sdkerrors.Wrap(sdkerrors.ErrOutOfGas, errorMsg).Error()) default: // Not ErrorOutOfGas, so panic again. panic(r) } } }() thoughts := k.GetAllThoughts(ctx) thoughts.Sort() maxGas := k.MaxGas(ctx) gasBeforeDmn := ctx.GasMeter().GasConsumed() gasUsedTotal := sdk.Gas(0) feeTTL := k.FeeTTL(ctx) maxThoughts := k.MaxThougths(ctx) maxGasPerThought := maxGas / maxThoughts if thoughts.Len() > 0 { k.Logger(ctx).Info("Thoughts in queue", "size", thoughts.Len()) } var thoughtsTriggered uint32 for i, thought := range thoughts { if (thought.Trigger.Period != 0 && ctx.BlockHeight()%int64(thought.Trigger.Period) == 0) || (thought.Trigger.Period == 0 && ctx.BlockHeight() == int64(thought.Trigger.Block)) { price := thought.Load.GasPrice k.Logger(ctx).Info("Started thought", "number", i, "gas price", price) thoughtsTriggered++ cacheContext, writeFn := ctx.CacheContext() cacheContext = cacheContext.WithGasMeter(sdk.NewGasMeter(sdk.Gas(maxGasPerThought))) k.Logger(ctx).Info("Context gas stats before thought execution", "consumed", ctx.GasMeter().GasConsumed(), ) remained := ctx.GasMeter().Limit() - ctx.GasMeter().GasConsumedToLimit() if remained < uint64(maxGasPerThought) { k.Logger(ctx).Info("Thought break, not enough gas", "thought #", i) break } program, _ := sdk.AccAddressFromBech32(thought.Program) _, errExecute := k.executeThoughtWithSudo( cacheContext, program, thought.Load.Input, ) gasUsedByThought := cacheContext.GasMeter().GasConsumed() ctx.GasMeter().ConsumeGas(gasUsedByThought, "thought execution") if gasUsedTotal+gasUsedByThought > uint64(maxGas) { break } else { gasUsedTotal += gasUsedByThought } js, _ := k.GetThoughtStats(ctx, program, thought.Name) // TODO move to more advanced fee system, 10X fee reducer applied (min 0.1 per gas) amtGasFee := price.Amount.Int64() * int64(gasUsedByThought) / 10 amtTTLFee := (ctx.BlockHeight() - int64(js.LastBlock)) * int64(feeTTL) amtTotalFee := amtGasFee + amtTTLFee k.Logger(ctx).Info("Gas thought execution stats", "used", gasUsedByThought, "gas fee", amtGasFee, "ttl fee", amtTTLFee, "total fee", amtTotalFee, ) fee := sdk.NewCoin(ctypes.CYB, sdk.NewInt(amtTotalFee)) errSend := k.proxyKeeper.SendCoins( ctx, program, k.accountKeeper.GetModuleAddress(authtypes.FeeCollectorName), sdk.NewCoins(fee)) if errSend != nil { k.DeleteThought(ctx, program, thought.Name) k.DeleteThoughtStats(ctx, program, thought.Name) k.Logger(ctx).Info("Not enough program balance, state not applied, thought forgotten", "Thought #", i) continue } if errExecute != nil { k.Logger(ctx).Info("Thought failed, state not applied", "Thought #", i) k.Logger(ctx).Info("Failed with error: ", "Error", errExecute.Error()) } else { writeFn() // apply cached context k.Logger(ctx).Info("Thought finished, state applied", "Thought #", i) } k.SetThoughtStats(ctx, program, thought.Name, types.NewStats( program.String(), thought.Name, js.Calls+1, js.Fees+uint64(amtTotalFee), js.Gas+gasUsedByThought, uint64(ctx.BlockHeight())), ) if ctx.BlockHeight() == int64(thought.Trigger.Block) { k.DeleteThought(ctx, program, thought.Name) k.DeleteThoughtStats(ctx, program, thought.Name) k.Logger(ctx).Info("Thought executed at given block, deleted from queue", "Thought #", i) } } } gasAfterDmn := ctx.GasMeter().GasConsumed() if thoughtsTriggered > 0 { k.Logger(ctx).Info("Total dmn gas used", "Gas used", gasAfterDmn-gasBeforeDmn) } } func (k Keeper) executeThoughtWithSudo(ctx sdk.Context, program sdk.AccAddress, msg string) ([]byte, error) { defer func() { if r := recover(); r != nil { switch rType := r.(type) { case sdk.ErrorOutOfGas: errorMsg := fmt.Sprintf( "out of gas in location: %v; gasUsed: %d", rType.Descriptor, ctx.GasMeter().GasConsumed(), ) k.Logger(ctx).Error(sdkerrors.Wrap(sdkerrors.ErrOutOfGas, errorMsg).Error()) default: // Not ErrorOutOfGas, so panic again. panic(r) } } telemetry.IncrCounter(1.0, types.ModuleName, "thought") }() callData, berr := base64.StdEncoding.DecodeString(msg) if berr != nil { // TODO remove hex later as deprecated _, herr := hex.DecodeString(msg) if herr != nil { return nil, types.ErrBadCallData } } return k.wasmKeeper.Sudo(ctx, program, callData) } ================================================ FILE: x/dmn/keeper/migrator.go ================================================ package keeper import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/dmn/exported" v2 "github.com/cybercongress/go-cyber/v7/x/dmn/migrations/v2" ) // Migrator is a struct for handling in-place state migrations. type Migrator struct { keeper Keeper legacySubspace exported.Subspace } func NewMigrator(k Keeper, ss exported.Subspace) Migrator { return Migrator{ keeper: k, legacySubspace: ss, } } func (m Migrator) Migrate1to2(ctx sdk.Context) error { return v2.Migrate(ctx, ctx.KVStore(m.keeper.storeKey), m.legacySubspace, m.keeper.cdc) } ================================================ FILE: x/dmn/keeper/msg_server.go ================================================ package keeper import ( "context" govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" "cosmossdk.io/errors" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/dmn/types" graph "github.com/cybercongress/go-cyber/v7/x/graph/types" ) type msgServer struct { Keeper } func NewMsgServerImpl( keeper Keeper, ) types.MsgServer { return &msgServer{ keeper, } } var _ types.MsgServer = msgServer{} func (k msgServer) CreateThought(goCtx context.Context, msg *types.MsgCreateThought) (*types.MsgCreateThoughtResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) program, _ := sdk.AccAddressFromBech32(msg.Program) err := k.SaveThought( ctx, program, msg.Trigger, msg.Load, msg.Name, graph.Cid(msg.Particle), ) if err != nil { return nil, err } ctx.EventManager().EmitEvents(sdk.Events{ sdk.NewEvent( sdk.EventTypeMessage, sdk.NewAttribute(sdk.AttributeKeyModule, types.AttributeValueCategory), sdk.NewAttribute(sdk.AttributeKeySender, msg.Program), ), sdk.NewEvent( types.EventTypeCreateThought, sdk.NewAttribute(types.AttributeKeyThoughtProgram, msg.Program), sdk.NewAttribute(types.AttributeKeyThoughtTrigger, msg.Trigger.String()), sdk.NewAttribute(types.AttributeKeyThoughtLoad, msg.Load.String()), sdk.NewAttribute(types.AttributeKeyThoughtName, msg.Name), sdk.NewAttribute(types.AttributeKeyThoughtParticle, msg.Particle), ), }) return &types.MsgCreateThoughtResponse{}, nil } func (k msgServer) ForgetThought(goCtx context.Context, msg *types.MsgForgetThought) (*types.MsgForgetThoughtResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) program, _ := sdk.AccAddressFromBech32(msg.Program) err := k.RemoveThoughtFull(ctx, program, msg.Name) if err != nil { return nil, err } ctx.EventManager().EmitEvents(sdk.Events{ sdk.NewEvent( sdk.EventTypeMessage, sdk.NewAttribute(sdk.AttributeKeyModule, types.AttributeValueCategory), sdk.NewAttribute(sdk.AttributeKeySender, msg.Program), ), sdk.NewEvent( types.EventTypeForgetThought, sdk.NewAttribute(types.AttributeKeyThoughtProgram, msg.Program), ), }) return &types.MsgForgetThoughtResponse{}, nil } func (k msgServer) ChangeThoughtParticle(goCtx context.Context, msg *types.MsgChangeThoughtParticle) (*types.MsgChangeThoughtParticleResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) program, _ := sdk.AccAddressFromBech32(msg.Program) err := k.UpdateThoughtParticle(ctx, program, msg.Name, graph.Cid(msg.Particle)) if err != nil { return nil, err } ctx.EventManager().EmitEvents(sdk.Events{ sdk.NewEvent( sdk.EventTypeMessage, sdk.NewAttribute(sdk.AttributeKeyModule, types.AttributeValueCategory), sdk.NewAttribute(sdk.AttributeKeySender, msg.Program), ), sdk.NewEvent( types.EventTypeChangeThoughtParticle, sdk.NewAttribute(types.AttributeKeyThoughtProgram, msg.Program), sdk.NewAttribute(types.AttributeKeyThoughtParticle, msg.Particle), ), }) return &types.MsgChangeThoughtParticleResponse{}, nil } func (k msgServer) ChangeThoughtName(goCtx context.Context, msg *types.MsgChangeThoughtName) (*types.MsgChangeThoughtNameResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) program, _ := sdk.AccAddressFromBech32(msg.Program) err := k.UpdateThoughtName(ctx, program, msg.Name, msg.NewName) if err != nil { return nil, err } ctx.EventManager().EmitEvents(sdk.Events{ sdk.NewEvent( sdk.EventTypeMessage, sdk.NewAttribute(sdk.AttributeKeyModule, types.AttributeValueCategory), sdk.NewAttribute(sdk.AttributeKeySender, msg.Program), ), sdk.NewEvent( types.EventTypeChangeThoughtName, sdk.NewAttribute(types.AttributeKeyThoughtProgram, msg.Program), sdk.NewAttribute(types.AttributeKeyThoughtName, msg.Name), ), }) return &types.MsgChangeThoughtNameResponse{}, nil } func (k msgServer) ChangeThoughtInput(goCtx context.Context, msg *types.MsgChangeThoughtInput) (*types.MsgChangeThoughtInputResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) program, _ := sdk.AccAddressFromBech32(msg.Program) err := k.UpdateThoughtCallData(ctx, program, msg.Name, msg.Input) if err != nil { return nil, err } ctx.EventManager().EmitEvents(sdk.Events{ sdk.NewEvent( sdk.EventTypeMessage, sdk.NewAttribute(sdk.AttributeKeyModule, types.AttributeValueCategory), sdk.NewAttribute(sdk.AttributeKeySender, msg.Program), ), sdk.NewEvent( types.EventTypeChangeThoughtInput, sdk.NewAttribute(types.AttributeKeyThoughtProgram, msg.Program), sdk.NewAttribute(types.AttributeKeyThoughtInput, msg.Input), ), }) return &types.MsgChangeThoughtInputResponse{}, nil } func (k msgServer) ChangeThoughtGasPrice(goCtx context.Context, msg *types.MsgChangeThoughtGasPrice) (*types.MsgChangeThoughtGasPriceResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) program, _ := sdk.AccAddressFromBech32(msg.Program) err := k.UpdateThoughtGasPrice(ctx, program, msg.Name, msg.GasPrice) if err != nil { return nil, err } ctx.EventManager().EmitEvents(sdk.Events{ sdk.NewEvent( sdk.EventTypeMessage, sdk.NewAttribute(sdk.AttributeKeyModule, types.AttributeValueCategory), sdk.NewAttribute(sdk.AttributeKeySender, msg.Program), ), sdk.NewEvent( types.EventTypeChangeThoughtGasPrice, sdk.NewAttribute(types.AttributeKeyThoughtProgram, msg.Program), sdk.NewAttribute(types.AttributeKeyThoughtGasPrice, msg.GasPrice.String()), ), }) return &types.MsgChangeThoughtGasPriceResponse{}, nil } func (k msgServer) ChangeThoughtPeriod(goCtx context.Context, msg *types.MsgChangeThoughtPeriod) (*types.MsgChangeThoughtPeriodResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) program, _ := sdk.AccAddressFromBech32(msg.Program) err := k.UpdateThoughtPeriod(ctx, program, msg.Name, msg.Period) if err != nil { return nil, err } ctx.EventManager().EmitEvents(sdk.Events{ sdk.NewEvent( sdk.EventTypeMessage, sdk.NewAttribute(sdk.AttributeKeyModule, types.AttributeValueCategory), sdk.NewAttribute(sdk.AttributeKeySender, msg.Program), ), sdk.NewEvent( types.EventTypeChangeThoughtPeriod, sdk.NewAttribute(types.AttributeKeyThoughtProgram, msg.Program), // TODO:update later sdk.NewAttribute(types.AttributeKeyThoughtPeriod, string(msg.Period)), //nolint:govet ), }) return &types.MsgChangeThoughtPeriodResponse{}, nil } func (k msgServer) ChangeThoughtBlock(goCtx context.Context, msg *types.MsgChangeThoughtBlock) (*types.MsgChangeThoughtBlockResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) program, _ := sdk.AccAddressFromBech32(msg.Program) err := k.UpdateThoughtBlock(ctx, program, msg.Name, msg.Block) if err != nil { return nil, err } ctx.EventManager().EmitEvents(sdk.Events{ sdk.NewEvent( sdk.EventTypeMessage, sdk.NewAttribute(sdk.AttributeKeyModule, types.AttributeValueCategory), sdk.NewAttribute(sdk.AttributeKeySender, msg.Program), ), sdk.NewEvent( types.EventTypeChangeThoughtBlock, sdk.NewAttribute(types.AttributeKeyThoughtProgram, msg.Program), // TODO:update later sdk.NewAttribute(types.AttributeKeyThoughtBlock, string(msg.Block)), //nolint:govet ), }) return &types.MsgChangeThoughtBlockResponse{}, nil } func (server msgServer) UpdateParams(goCtx context.Context, req *types.MsgUpdateParams) (*types.MsgUpdateParamsResponse, error) { if server.authority != req.Authority { return nil, errors.Wrapf(govtypes.ErrInvalidSigner, "invalid authority; expected %s, got %s", server.authority, req.Authority) } ctx := sdk.UnwrapSDKContext(goCtx) if err := server.SetParams(ctx, req.Params); err != nil { return nil, err } return &types.MsgUpdateParamsResponse{}, nil } ================================================ FILE: x/dmn/migrations/v2/migrate.go ================================================ package v2 import ( "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/dmn/exported" "github.com/cybercongress/go-cyber/v7/x/dmn/types" ) func Migrate( ctx sdk.Context, store sdk.KVStore, legacySubspace exported.Subspace, cdc codec.BinaryCodec, ) error { var currParams types.Params legacySubspace.GetParamSet(ctx, &currParams) if err := currParams.Validate(); err != nil { return err } bz := cdc.MustMarshal(&currParams) store.Set(types.ParamsKey, bz) return nil } ================================================ FILE: x/dmn/module.go ================================================ package dmn import ( "context" "encoding/json" "fmt" "github.com/cosmos/cosmos-sdk/client" codectypes "github.com/cosmos/cosmos-sdk/codec/types" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/spf13/cobra" abci "github.com/cometbft/cometbft/abci/types" "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" "github.com/cybercongress/go-cyber/v7/x/dmn/client/cli" "github.com/cybercongress/go-cyber/v7/x/dmn/exported" "github.com/cybercongress/go-cyber/v7/x/dmn/keeper" "github.com/cybercongress/go-cyber/v7/x/dmn/types" ) var ( _ module.AppModule = AppModule{} _ module.AppModuleBasic = AppModuleBasic{} ) type AppModuleBasic struct { cdc codec.Codec } func (AppModuleBasic) Name() string { return types.ModuleName } func (AppModuleBasic) RegisterLegacyAminoCodec(cdc *codec.LegacyAmino) { types.RegisterLegacyAminoCodec(cdc) } func (AppModuleBasic) DefaultGenesis(cdc codec.JSONCodec) json.RawMessage { return cdc.MustMarshalJSON(types.DefaultGenesisState()) } func (AppModuleBasic) ValidateGenesis(cdc codec.JSONCodec, _ client.TxEncodingConfig, bz json.RawMessage) error { var data types.GenesisState err := cdc.UnmarshalJSON(bz, &data) if err != nil { return fmt.Errorf("failed to unmarshal %s genesis state: %w", types.ModuleName, err) } return types.ValidateGenesis(data) } func (AppModuleBasic) RegisterGRPCGatewayRoutes(clientCtx client.Context, mux *runtime.ServeMux) { if err := types.RegisterQueryHandlerClient(context.Background(), mux, types.NewQueryClient(clientCtx)); err != nil { panic(err) } } func (AppModuleBasic) GetTxCmd() *cobra.Command { return nil } func (AppModuleBasic) GetQueryCmd() *cobra.Command { return cli.GetQueryCmd() } func (AppModuleBasic) RegisterInterfaces(registry codectypes.InterfaceRegistry) { types.RegisterInterfaces(registry) } type AppModule struct { AppModuleBasic cdc codec.Codec keeper keeper.Keeper legacySubspace exported.Subspace } func NewAppModule( cdc codec.Codec, k keeper.Keeper, ss exported.Subspace, ) AppModule { return AppModule{ AppModuleBasic: AppModuleBasic{cdc: cdc}, cdc: cdc, keeper: k, legacySubspace: ss, } } func (AppModule) Name() string { return types.ModuleName } func (am AppModule) RegisterInvariants(_ sdk.InvariantRegistry) {} func (am AppModule) RegisterServices(cfg module.Configurator) { types.RegisterMsgServer(cfg.MsgServer(), keeper.NewMsgServerImpl(am.keeper)) types.RegisterQueryServer(cfg.QueryServer(), am.keeper) m := keeper.NewMigrator(am.keeper, am.legacySubspace) if err := cfg.RegisterMigration(types.ModuleName, 1, m.Migrate1to2); err != nil { panic(fmt.Sprintf("failed to migrate x/%s from version 1 to 2: %v", types.ModuleName, err)) } } func (am AppModule) InitGenesis(ctx sdk.Context, cdc codec.JSONCodec, data json.RawMessage) []abci.ValidatorUpdate { var genesisState types.GenesisState cdc.MustUnmarshalJSON(data, &genesisState) keeper.InitGenesis(ctx, am.keeper, genesisState) return []abci.ValidatorUpdate{} } func (am AppModule) ExportGenesis(ctx sdk.Context, cdc codec.JSONCodec) json.RawMessage { gs := keeper.ExportGenesis(ctx, am.keeper) return cdc.MustMarshalJSON(gs) } func (am AppModule) ConsensusVersion() uint64 { return 2 } func (am AppModule) BeginBlock(ctx sdk.Context, _ abci.RequestBeginBlock) { BeginBlock(ctx, am.keeper) } func (am AppModule) EndBlock(_ sdk.Context, _ abci.RequestEndBlock) []abci.ValidatorUpdate { return []abci.ValidatorUpdate{} } ================================================ FILE: x/dmn/types/codec.go ================================================ package types import ( "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/codec/legacy" "github.com/cosmos/cosmos-sdk/codec/types" cdctypes "github.com/cosmos/cosmos-sdk/codec/types" cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/msgservice" govcodec "github.com/cosmos/cosmos-sdk/x/gov/codec" ) func RegisterLegacyAminoCodec(cdc *codec.LegacyAmino) { legacy.RegisterAminoMsg(cdc, &MsgUpdateParams{}, "cyber/dmn/MsgUpdateParams") cdc.RegisterConcrete(Params{}, "cyber/dmn/Params", nil) } func RegisterInterfaces(registry types.InterfaceRegistry) { registry.RegisterImplementations((*sdk.Msg)(nil), &MsgCreateThought{}, &MsgForgetThought{}, &MsgChangeThoughtParticle{}, &MsgChangeThoughtName{}, &MsgChangeThoughtInput{}, &MsgChangeThoughtGasPrice{}, &MsgChangeThoughtPeriod{}, &MsgChangeThoughtBlock{}, &MsgUpdateParams{}, ) msgservice.RegisterMsgServiceDesc(registry, &_Msg_serviceDesc) } var ( amino = codec.NewLegacyAmino() ModuleCdc = codec.NewProtoCodec(cdctypes.NewInterfaceRegistry()) // ModuleCdc = codec.NewAminoCodec(amino) ) func init() { RegisterLegacyAminoCodec(amino) cryptocodec.RegisterCrypto(amino) sdk.RegisterLegacyAminoCodec(amino) RegisterLegacyAminoCodec(govcodec.Amino) } ================================================ FILE: x/dmn/types/errors.go ================================================ package types import ( errorsmod "cosmossdk.io/errors" ) var ( ErrInvalidAddress = errorsmod.Register(ModuleName, 2, "invalid address") ErrExceededMaxThoughts = errorsmod.Register(ModuleName, 3, "exceeded max thoughts") ErrBadCallData = errorsmod.Register(ModuleName, 4, "bad call data") ErrBadGasPrice = errorsmod.Register(ModuleName, 5, "bad gas price") ErrBadTrigger = errorsmod.Register(ModuleName, 6, "bad trigger") ErrBadName = errorsmod.Register(ModuleName, 7, "bad name") ErrThoughtNotExist = errorsmod.Register(ModuleName, 8, "thought does not exist") ErrConvertTrigger = errorsmod.Register(ModuleName, 9, "cannot convert trigger") ) ================================================ FILE: x/dmn/types/events.go ================================================ package types const ( EventTypeCreateThought = "create_thought" EventTypeForgetThought = "forget_thought" EventTypeChangeThoughtParticle = "change_thought_particle" EventTypeChangeThoughtName = "change_thought_name" EventTypeChangeThoughtInput = "change_thought_input" EventTypeChangeThoughtGasPrice = "change_thought_gas_price" EventTypeChangeThoughtPeriod = "change_thought_period" EventTypeChangeThoughtBlock = "change_thought_block" AttributeKeyThoughtProgram = "program" AttributeKeyThoughtTrigger = "trigger" AttributeKeyThoughtLoad = "load" AttributeKeyThoughtName = "name" AttributeKeyThoughtParticle = "particle" AttributeKeyThoughtInput = "input" AttributeKeyThoughtGasPrice = "gas_price" AttributeKeyThoughtPeriod = "period" AttributeKeyThoughtBlock = "block" AttributeValueCategory = ModuleName ) ================================================ FILE: x/dmn/types/expected_keepers.go ================================================ package types import ( sdk "github.com/cosmos/cosmos-sdk/types" ) type BankKeeper interface { OnCoinsTransfer(ctx sdk.Context, from sdk.AccAddress, to sdk.AccAddress) SendCoins(ctx sdk.Context, from sdk.AccAddress, to sdk.AccAddress, amt sdk.Coins) error } type AccountKeeper interface { GetModuleAddress(name string) sdk.AccAddress } ================================================ FILE: x/dmn/types/genesis.go ================================================ package types func NewGenesisState(params Params) *GenesisState { return &GenesisState{ Params: params, } } func DefaultGenesisState() *GenesisState { return &GenesisState{ Params: DefaultParams(), } } func ValidateGenesis(_ GenesisState) error { return nil } ================================================ FILE: x/dmn/types/genesis.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: cyber/dmn/v1beta1/genesis.proto package types import ( fmt "fmt" io "io" math "math" math_bits "math/bits" _ "github.com/cosmos/gogoproto/gogoproto" proto "github.com/cosmos/gogoproto/proto" ) // Reference imports to suppress errors if they are not otherwise used. var ( _ = proto.Marshal _ = fmt.Errorf _ = math.Inf ) // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package type GenesisState struct { Params Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params"` } func (m *GenesisState) Reset() { *m = GenesisState{} } func (m *GenesisState) String() string { return proto.CompactTextString(m) } func (*GenesisState) ProtoMessage() {} func (*GenesisState) Descriptor() ([]byte, []int) { return fileDescriptor_3d0e09d4ad24cea5, []int{0} } func (m *GenesisState) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *GenesisState) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_GenesisState.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *GenesisState) XXX_Merge(src proto.Message) { xxx_messageInfo_GenesisState.Merge(m, src) } func (m *GenesisState) XXX_Size() int { return m.Size() } func (m *GenesisState) XXX_DiscardUnknown() { xxx_messageInfo_GenesisState.DiscardUnknown(m) } var xxx_messageInfo_GenesisState proto.InternalMessageInfo func (m *GenesisState) GetParams() Params { if m != nil { return m.Params } return Params{} } func init() { proto.RegisterType((*GenesisState)(nil), "cyber.dmn.v1beta1.GenesisState") } func init() { proto.RegisterFile("cyber/dmn/v1beta1/genesis.proto", fileDescriptor_3d0e09d4ad24cea5) } var fileDescriptor_3d0e09d4ad24cea5 = []byte{ // 205 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0x4f, 0xae, 0x4c, 0x4a, 0x2d, 0xd2, 0x4f, 0xc9, 0xcd, 0xd3, 0x2f, 0x33, 0x4c, 0x4a, 0x2d, 0x49, 0x34, 0xd4, 0x4f, 0x4f, 0xcd, 0x4b, 0x2d, 0xce, 0x2c, 0xd6, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x04, 0x2b, 0xd0, 0x4b, 0xc9, 0xcd, 0xd3, 0x83, 0x2a, 0x90, 0x12, 0x49, 0xcf, 0x4f, 0xcf, 0x07, 0xcb, 0xea, 0x83, 0x58, 0x10, 0x85, 0x52, 0xb2, 0x98, 0x26, 0x95, 0x54, 0x16, 0xa4, 0x42, 0xcd, 0x51, 0x72, 0xe7, 0xe2, 0x71, 0x87, 0x18, 0x1c, 0x5c, 0x92, 0x58, 0x92, 0x2a, 0x64, 0xce, 0xc5, 0x56, 0x90, 0x58, 0x94, 0x98, 0x5b, 0x2c, 0xc1, 0xa8, 0xc0, 0xa8, 0xc1, 0x6d, 0x24, 0xa9, 0x87, 0x61, 0x91, 0x5e, 0x00, 0x58, 0x81, 0x13, 0xcb, 0x89, 0x7b, 0xf2, 0x0c, 0x41, 0x50, 0xe5, 0x4e, 0xee, 0x27, 0x1e, 0xc9, 0x31, 0x5e, 0x78, 0x24, 0xc7, 0xf8, 0xe0, 0x91, 0x1c, 0xe3, 0x84, 0xc7, 0x72, 0x0c, 0x17, 0x1e, 0xcb, 0x31, 0xdc, 0x78, 0x2c, 0xc7, 0x10, 0xa5, 0x9b, 0x9e, 0x59, 0x92, 0x51, 0x9a, 0xa4, 0x97, 0x9c, 0x9f, 0xab, 0x0f, 0x36, 0x2c, 0x39, 0x3f, 0x2f, 0xbd, 0x28, 0xb5, 0xb8, 0x58, 0x3f, 0x3d, 0x5f, 0x17, 0xe2, 0xba, 0x0a, 0xb0, 0xfb, 0xc0, 0xee, 0x4a, 0x62, 0x03, 0x3b, 0xcc, 0x18, 0x10, 0x00, 0x00, 0xff, 0xff, 0x71, 0xd6, 0xba, 0xca, 0x03, 0x01, 0x00, 0x00, } func (m *GenesisState) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *GenesisState) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *GenesisState) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.Params.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintGenesis(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa return len(dAtA) - i, nil } func encodeVarintGenesis(dAtA []byte, offset int, v uint64) int { offset -= sovGenesis(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *GenesisState) Size() (n int) { if m == nil { return 0 } var l int _ = l l = m.Params.Size() n += 1 + l + sovGenesis(uint64(l)) return n } func sovGenesis(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozGenesis(x uint64) (n int) { return sovGenesis(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *GenesisState) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenesis } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: GenesisState: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: GenesisState: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenesis } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthGenesis } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenesis } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Params.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipGenesis(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthGenesis } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipGenesis(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowGenesis } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowGenesis } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowGenesis } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthGenesis } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupGenesis } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthGenesis } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthGenesis = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowGenesis = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupGenesis = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/dmn/types/keys.go ================================================ package types import sdk "github.com/cosmos/cosmos-sdk/types" const ( ModuleName = "dmn" StoreKey = ModuleName RouterKey = ModuleName ) var ( ThoughtKey = []byte{0x00} ThoughtStatsKey = []byte{0x01} ParamsKey = []byte{0x02} ) func GetThoughtKey(program sdk.AccAddress, name string) []byte { key := append(program.Bytes(), []byte(name)...) return append(ThoughtKey, key...) } func GetThoughtStatsKey(program sdk.AccAddress, name string) []byte { key := append(program.Bytes(), []byte(name)...) return append(ThoughtStatsKey, key...) } ================================================ FILE: x/dmn/types/msgs.go ================================================ package types import ( errorsmod "cosmossdk.io/errors" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" "github.com/ipfs/go-cid" // sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" "github.com/cybercongress/go-cyber/v7/types" graph "github.com/cybercongress/go-cyber/v7/x/graph/types" ) const ( TypeMsgCreateThought = "create_thought" TypeMsgForgetThought = "forget_thought" TypeMsgChangeThoughtName = "change_thought_name" TypeMsgChangeThoughtParticle = "change_thought_particle" TypeMsgChangeThoughtInput = "change_thought_input" TypeMsgChangeThoughtGasPrice = "change_thought_gas_price" TypeMsgChangeThoughtPeriod = "change_thought_period" TypeMsgChangeThoughtBlock = "change_thought_block" ) func NewMsgCreateThought( program sdk.AccAddress, trigger Trigger, load Load, name string, particle string, ) *MsgCreateThought { return &MsgCreateThought{ Program: program.String(), Trigger: trigger, Load: load, Name: name, Particle: particle, } } func (msg MsgCreateThought) Route() string { return RouterKey } func (msg MsgCreateThought) Type() string { return TypeMsgCreateThought } func (msg MsgCreateThought) ValidateBasic() error { _, err := sdk.AccAddressFromBech32(msg.Program) if err != nil { return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "Invalid program address (%s)", err) } if msg.Load.Input == "" || len(msg.Load.Input) > 2048 { return ErrBadCallData } if msg.Load.GasPrice.Denom != types.CYB { return ErrBadGasPrice } if !msg.Load.GasPrice.Amount.IsPositive() { return ErrBadGasPrice } if msg.Trigger.Period == 0 && msg.Trigger.Block == 0 { return ErrBadTrigger } if msg.Trigger.Period > 0 && msg.Trigger.Block > 0 { return ErrBadTrigger } if msg.Name == "" || len(msg.Name) > 32 { return ErrBadName } particle, err := cid.Decode(msg.Particle) if err != nil { return graph.ErrInvalidParticle } if particle.Version() != 0 { return graph.ErrCidVersion } return nil } func (msg MsgCreateThought) GetSignBytes() []byte { bz := ModuleCdc.MustMarshalJSON(&msg) return sdk.MustSortJSON(bz) } func (msg MsgCreateThought) GetSigners() []sdk.AccAddress { addr, err := sdk.AccAddressFromBech32(msg.Program) if err != nil { panic(err) } return []sdk.AccAddress{addr} } func NewMsgForgetThought(program sdk.AccAddress, label string) *MsgForgetThought { return &MsgForgetThought{ Program: program.String(), Name: label, } } func (msg MsgForgetThought) Route() string { return RouterKey } func (msg MsgForgetThought) Type() string { return TypeMsgForgetThought } func (msg MsgForgetThought) ValidateBasic() error { _, err := sdk.AccAddressFromBech32(msg.Program) if err != nil { return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "Invalid program address (%s)", err) } if msg.Name == "" || len(msg.Name) > 32 { return ErrBadName } return nil } func (msg MsgForgetThought) GetSignBytes() []byte { bz := ModuleCdc.MustMarshalJSON(&msg) return sdk.MustSortJSON(bz) } func (msg MsgForgetThought) GetSigners() []sdk.AccAddress { addr, err := sdk.AccAddressFromBech32(msg.Program) if err != nil { panic(err) } return []sdk.AccAddress{addr} } func NewMsgChangeThoughtName( program sdk.AccAddress, name, newName string, ) *MsgChangeThoughtName { return &MsgChangeThoughtName{ Program: program.String(), Name: name, NewName: newName, } } func (msg MsgChangeThoughtName) Route() string { return RouterKey } func (msg MsgChangeThoughtName) Type() string { return TypeMsgChangeThoughtName } func (msg MsgChangeThoughtName) ValidateBasic() error { _, err := sdk.AccAddressFromBech32(msg.Program) if err != nil { return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "Invalid program address (%s)", err) } if msg.Name == "" || len(msg.Name) > 32 { return ErrBadName } if msg.NewName == "" || len(msg.NewName) > 32 { return ErrBadName } return nil } func (msg MsgChangeThoughtName) GetSignBytes() []byte { bz := ModuleCdc.MustMarshalJSON(&msg) return sdk.MustSortJSON(bz) } func (msg MsgChangeThoughtName) GetSigners() []sdk.AccAddress { addr, err := sdk.AccAddressFromBech32(msg.Program) if err != nil { panic(err) } return []sdk.AccAddress{addr} } func NewMsgChangeThoughtParticle( program sdk.AccAddress, label string, cid string, ) *MsgChangeThoughtParticle { return &MsgChangeThoughtParticle{ Program: program.String(), Name: label, Particle: cid, } } func (msg MsgChangeThoughtParticle) Route() string { return RouterKey } func (msg MsgChangeThoughtParticle) Type() string { return TypeMsgChangeThoughtParticle } func (msg MsgChangeThoughtParticle) ValidateBasic() error { _, err := sdk.AccAddressFromBech32(msg.Program) if err != nil { return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "Invalid program address (%s)", err) } particle, err := cid.Decode(msg.Particle) if err != nil { return graph.ErrInvalidParticle } if particle.Version() != 0 { return graph.ErrCidVersion } if msg.Name == "" || len(msg.Name) > 32 { return ErrBadName } return nil } func (msg MsgChangeThoughtParticle) GetSignBytes() []byte { bz := ModuleCdc.MustMarshalJSON(&msg) return sdk.MustSortJSON(bz) } func (msg MsgChangeThoughtParticle) GetSigners() []sdk.AccAddress { addr, err := sdk.AccAddressFromBech32(msg.Program) if err != nil { panic(err) } return []sdk.AccAddress{addr} } func NewMsgChangeCallInput( program sdk.AccAddress, name string, input string, ) *MsgChangeThoughtInput { return &MsgChangeThoughtInput{ Program: program.String(), Name: name, Input: input, } } func (msg MsgChangeThoughtInput) Route() string { return RouterKey } func (msg MsgChangeThoughtInput) Type() string { return TypeMsgChangeThoughtInput } func (msg MsgChangeThoughtInput) ValidateBasic() error { _, err := sdk.AccAddressFromBech32(msg.Program) if err != nil { return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "Invalid program address (%s)", err) } if msg.Name == "" || len(msg.Name) > 32 { return ErrBadName } if msg.Input == "" || len(msg.Input) > 2048 { return ErrBadCallData } return nil } func (msg MsgChangeThoughtInput) GetSignBytes() []byte { bz := ModuleCdc.MustMarshalJSON(&msg) return sdk.MustSortJSON(bz) } func (msg MsgChangeThoughtInput) GetSigners() []sdk.AccAddress { addr, err := sdk.AccAddressFromBech32(msg.Program) if err != nil { panic(err) } return []sdk.AccAddress{addr} } func NewMsgChangeThoughtGasPrice( program sdk.AccAddress, name string, gasprice sdk.Coin, ) *MsgChangeThoughtGasPrice { return &MsgChangeThoughtGasPrice{ Program: program.String(), Name: name, GasPrice: gasprice, } } func (msg MsgChangeThoughtGasPrice) Route() string { return RouterKey } func (msg MsgChangeThoughtGasPrice) Type() string { return TypeMsgChangeThoughtGasPrice } func (msg MsgChangeThoughtGasPrice) ValidateBasic() error { _, err := sdk.AccAddressFromBech32(msg.Program) if err != nil { return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "Invalid program address (%s)", err) } if msg.Name == "" || len(msg.Name) > 32 { return ErrBadName } if msg.GasPrice.Denom != types.CYB { return ErrBadGasPrice } if !msg.GasPrice.Amount.IsPositive() { return ErrBadGasPrice } return nil } func (msg MsgChangeThoughtGasPrice) GetSignBytes() []byte { bz := ModuleCdc.MustMarshalJSON(&msg) return sdk.MustSortJSON(bz) } func (msg MsgChangeThoughtGasPrice) GetSigners() []sdk.AccAddress { addr, err := sdk.AccAddressFromBech32(msg.Program) if err != nil { panic(err) } return []sdk.AccAddress{addr} } func NewMsgChangeThoughtPeriod( program sdk.AccAddress, name string, period uint64, ) *MsgChangeThoughtPeriod { return &MsgChangeThoughtPeriod{ Program: program.String(), Name: name, Period: period, } } func (msg MsgChangeThoughtPeriod) Route() string { return RouterKey } func (msg MsgChangeThoughtPeriod) Type() string { return TypeMsgChangeThoughtPeriod } func (msg MsgChangeThoughtPeriod) ValidateBasic() error { _, err := sdk.AccAddressFromBech32(msg.Program) if err != nil { return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "Invalid program address (%s)", err) } if msg.Name == "" || len(msg.Name) > 32 { return ErrBadName } if msg.Period == 0 { return ErrBadTrigger } return nil } func (msg MsgChangeThoughtPeriod) GetSignBytes() []byte { bz := ModuleCdc.MustMarshalJSON(&msg) return sdk.MustSortJSON(bz) } func (msg MsgChangeThoughtPeriod) GetSigners() []sdk.AccAddress { addr, err := sdk.AccAddressFromBech32(msg.Program) if err != nil { panic(err) } return []sdk.AccAddress{addr} } func NewMsgChangeThoughtBlock( program sdk.AccAddress, name string, block uint64, ) *MsgChangeThoughtBlock { return &MsgChangeThoughtBlock{ Program: program.String(), Name: name, Block: block, } } func (msg MsgChangeThoughtBlock) Route() string { return RouterKey } func (msg MsgChangeThoughtBlock) Type() string { return TypeMsgChangeThoughtBlock } func (msg MsgChangeThoughtBlock) ValidateBasic() error { _, err := sdk.AccAddressFromBech32(msg.Program) if err != nil { return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "Invalid program address (%s)", err) } if msg.Name == "" || len(msg.Name) > 32 { return ErrBadName } if msg.Block == 0 { return ErrBadTrigger } return nil } func (msg MsgChangeThoughtBlock) GetSigners() []sdk.AccAddress { addr, err := sdk.AccAddressFromBech32(msg.Program) if err != nil { panic(err) } return []sdk.AccAddress{addr} } func (msg MsgChangeThoughtBlock) GetSignBytes() []byte { bz := ModuleCdc.MustMarshalJSON(&msg) return sdk.MustSortJSON(bz) } var _ sdk.Msg = &MsgUpdateParams{} // GetSignBytes implements the LegacyMsg interface. func (m MsgUpdateParams) GetSignBytes() []byte { return sdk.MustSortJSON(ModuleCdc.MustMarshalJSON(&m)) } // GetSigners returns the expected signers for a MsgUpdateParams message. func (m *MsgUpdateParams) GetSigners() []sdk.AccAddress { addr, _ := sdk.AccAddressFromBech32(m.Authority) return []sdk.AccAddress{addr} } // ValidateBasic does a sanity check on the provided data. func (m *MsgUpdateParams) ValidateBasic() error { if _, err := sdk.AccAddressFromBech32(m.Authority); err != nil { return errorsmod.Wrap(err, "invalid authority address") } return m.Params.Validate() } ================================================ FILE: x/dmn/types/params.go ================================================ package types import ( "fmt" ) const ( DefaultMaxSlots uint32 = 4 DefaultMaxGas uint32 = 2000000 DefaultFeeTTL uint32 = 50 ) func DefaultParams() Params { return Params{ DefaultMaxSlots, DefaultMaxGas, DefaultFeeTTL, } } func NewParams( maxSlots uint32, maxGas uint32, feeTtl uint32, ) Params { return Params{ maxSlots, maxGas, feeTtl, } } func (p Params) Validate() error { if err := validateMaxSlots(p.MaxSlots); err != nil { return err } if err := validateMaxGas(p.MaxGas); err != nil { return err } if err := validateFeeTTL(p.FeeTtl); err != nil { return err } return nil } func validateMaxSlots(i interface{}) error { v, ok := i.(uint32) if !ok { return fmt.Errorf("invalid parameter type: %T", i) } if v < 4 { return fmt.Errorf("max slots must be equal or more than 4: %d", v) } return nil } func validateMaxGas(i interface{}) error { v, ok := i.(uint32) if !ok { return fmt.Errorf("invalid parameter type: %T", i) } if v < 2000000 { return fmt.Errorf("max gas must be equal or more than 2000000: %d", v) } return nil } func validateFeeTTL(i interface{}) error { v, ok := i.(uint32) if !ok { return fmt.Errorf("invalid parameter type: %T", i) } if v == 0 { return fmt.Errorf("fee ttl must be positive: %d", v) } return nil } ================================================ FILE: x/dmn/types/params_legacy.go ================================================ package types import paramstypes "github.com/cosmos/cosmos-sdk/x/params/types" var ( KeyMaxSlots = []byte("MaxSlots") KeyMaxGas = []byte("MaxGas") KeyFeeTTL = []byte("FeeTTL") ) // Deprecated: Type declaration for parameters func ParamKeyTable() paramstypes.KeyTable { return paramstypes.NewKeyTable().RegisterParamSet(&Params{}) } func (p *Params) ParamSetPairs() paramstypes.ParamSetPairs { return paramstypes.ParamSetPairs{ paramstypes.NewParamSetPair(KeyMaxSlots, &p.MaxSlots, validateMaxSlots), paramstypes.NewParamSetPair(KeyMaxGas, &p.MaxGas, validateMaxGas), paramstypes.NewParamSetPair(KeyFeeTTL, &p.FeeTtl, validateFeeTTL), } } ================================================ FILE: x/dmn/types/querier.go ================================================ package types import sdk "github.com/cosmos/cosmos-sdk/types" const ( QueryParams = "params" QueryThought = "thought" QueryThoughtStats = "thought_stats" QueryThoughts = "thoughts" QueryThoughtsStats = "thoughts_stats" ) type QueryThoughtParams struct { Program sdk.AccAddress Name string } func NewQueryThoughtParams(program sdk.AccAddress, name string) QueryThoughtParams { return QueryThoughtParams{program, name} } ================================================ FILE: x/dmn/types/query.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: cyber/dmn/v1beta1/query.proto package types import ( context "context" fmt "fmt" io "io" math "math" math_bits "math/bits" github_com_cosmos_cosmos_sdk_types "github.com/cosmos/cosmos-sdk/types" types "github.com/cosmos/cosmos-sdk/types" _ "github.com/cosmos/gogoproto/gogoproto" grpc1 "github.com/cosmos/gogoproto/grpc" proto "github.com/cosmos/gogoproto/proto" _ "google.golang.org/genproto/googleapis/api/annotations" grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" ) // Reference imports to suppress errors if they are not otherwise used. var ( _ = proto.Marshal _ = fmt.Errorf _ = math.Inf ) // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package type QueryParamsRequest struct{} func (m *QueryParamsRequest) Reset() { *m = QueryParamsRequest{} } func (m *QueryParamsRequest) String() string { return proto.CompactTextString(m) } func (*QueryParamsRequest) ProtoMessage() {} func (*QueryParamsRequest) Descriptor() ([]byte, []int) { return fileDescriptor_55109069a1b1f260, []int{0} } func (m *QueryParamsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryParamsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryParamsRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryParamsRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryParamsRequest.Merge(m, src) } func (m *QueryParamsRequest) XXX_Size() int { return m.Size() } func (m *QueryParamsRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryParamsRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryParamsRequest proto.InternalMessageInfo type QueryParamsResponse struct { Params Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params"` } func (m *QueryParamsResponse) Reset() { *m = QueryParamsResponse{} } func (m *QueryParamsResponse) String() string { return proto.CompactTextString(m) } func (*QueryParamsResponse) ProtoMessage() {} func (*QueryParamsResponse) Descriptor() ([]byte, []int) { return fileDescriptor_55109069a1b1f260, []int{1} } func (m *QueryParamsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryParamsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryParamsResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryParamsResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryParamsResponse.Merge(m, src) } func (m *QueryParamsResponse) XXX_Size() int { return m.Size() } func (m *QueryParamsResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryParamsResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryParamsResponse proto.InternalMessageInfo func (m *QueryParamsResponse) GetParams() Params { if m != nil { return m.Params } return Params{} } type QueryThoughtParamsRequest struct { Program string `protobuf:"bytes,1,opt,name=program,proto3" json:"program,omitempty"` Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"` } func (m *QueryThoughtParamsRequest) Reset() { *m = QueryThoughtParamsRequest{} } func (m *QueryThoughtParamsRequest) String() string { return proto.CompactTextString(m) } func (*QueryThoughtParamsRequest) ProtoMessage() {} func (*QueryThoughtParamsRequest) Descriptor() ([]byte, []int) { return fileDescriptor_55109069a1b1f260, []int{2} } func (m *QueryThoughtParamsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryThoughtParamsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryThoughtParamsRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryThoughtParamsRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryThoughtParamsRequest.Merge(m, src) } func (m *QueryThoughtParamsRequest) XXX_Size() int { return m.Size() } func (m *QueryThoughtParamsRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryThoughtParamsRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryThoughtParamsRequest proto.InternalMessageInfo func (m *QueryThoughtParamsRequest) GetProgram() string { if m != nil { return m.Program } return "" } func (m *QueryThoughtParamsRequest) GetName() string { if m != nil { return m.Name } return "" } type QueryThoughtResponse struct { Thought Thought `protobuf:"bytes,1,opt,name=thought,proto3" json:"thought"` } func (m *QueryThoughtResponse) Reset() { *m = QueryThoughtResponse{} } func (m *QueryThoughtResponse) String() string { return proto.CompactTextString(m) } func (*QueryThoughtResponse) ProtoMessage() {} func (*QueryThoughtResponse) Descriptor() ([]byte, []int) { return fileDescriptor_55109069a1b1f260, []int{3} } func (m *QueryThoughtResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryThoughtResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryThoughtResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryThoughtResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryThoughtResponse.Merge(m, src) } func (m *QueryThoughtResponse) XXX_Size() int { return m.Size() } func (m *QueryThoughtResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryThoughtResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryThoughtResponse proto.InternalMessageInfo func (m *QueryThoughtResponse) GetThought() Thought { if m != nil { return m.Thought } return Thought{} } type QueryThoughtStatsResponse struct { ThoughtStats ThoughtStats `protobuf:"bytes,1,opt,name=thought_stats,json=thoughtStats,proto3" json:"thought_stats"` } func (m *QueryThoughtStatsResponse) Reset() { *m = QueryThoughtStatsResponse{} } func (m *QueryThoughtStatsResponse) String() string { return proto.CompactTextString(m) } func (*QueryThoughtStatsResponse) ProtoMessage() {} func (*QueryThoughtStatsResponse) Descriptor() ([]byte, []int) { return fileDescriptor_55109069a1b1f260, []int{4} } func (m *QueryThoughtStatsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryThoughtStatsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryThoughtStatsResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryThoughtStatsResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryThoughtStatsResponse.Merge(m, src) } func (m *QueryThoughtStatsResponse) XXX_Size() int { return m.Size() } func (m *QueryThoughtStatsResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryThoughtStatsResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryThoughtStatsResponse proto.InternalMessageInfo func (m *QueryThoughtStatsResponse) GetThoughtStats() ThoughtStats { if m != nil { return m.ThoughtStats } return ThoughtStats{} } type QueryThoughtsRequest struct{} func (m *QueryThoughtsRequest) Reset() { *m = QueryThoughtsRequest{} } func (m *QueryThoughtsRequest) String() string { return proto.CompactTextString(m) } func (*QueryThoughtsRequest) ProtoMessage() {} func (*QueryThoughtsRequest) Descriptor() ([]byte, []int) { return fileDescriptor_55109069a1b1f260, []int{5} } func (m *QueryThoughtsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryThoughtsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryThoughtsRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryThoughtsRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryThoughtsRequest.Merge(m, src) } func (m *QueryThoughtsRequest) XXX_Size() int { return m.Size() } func (m *QueryThoughtsRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryThoughtsRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryThoughtsRequest proto.InternalMessageInfo type QueryThoughtsResponse struct { Thoughts Thoughts `protobuf:"bytes,1,rep,name=thoughts,proto3,castrepeated=Thoughts" json:"thoughts"` } func (m *QueryThoughtsResponse) Reset() { *m = QueryThoughtsResponse{} } func (m *QueryThoughtsResponse) String() string { return proto.CompactTextString(m) } func (*QueryThoughtsResponse) ProtoMessage() {} func (*QueryThoughtsResponse) Descriptor() ([]byte, []int) { return fileDescriptor_55109069a1b1f260, []int{6} } func (m *QueryThoughtsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryThoughtsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryThoughtsResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryThoughtsResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryThoughtsResponse.Merge(m, src) } func (m *QueryThoughtsResponse) XXX_Size() int { return m.Size() } func (m *QueryThoughtsResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryThoughtsResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryThoughtsResponse proto.InternalMessageInfo func (m *QueryThoughtsResponse) GetThoughts() Thoughts { if m != nil { return m.Thoughts } return nil } type QueryThoughtsStatsRequest struct{} func (m *QueryThoughtsStatsRequest) Reset() { *m = QueryThoughtsStatsRequest{} } func (m *QueryThoughtsStatsRequest) String() string { return proto.CompactTextString(m) } func (*QueryThoughtsStatsRequest) ProtoMessage() {} func (*QueryThoughtsStatsRequest) Descriptor() ([]byte, []int) { return fileDescriptor_55109069a1b1f260, []int{7} } func (m *QueryThoughtsStatsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryThoughtsStatsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryThoughtsStatsRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryThoughtsStatsRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryThoughtsStatsRequest.Merge(m, src) } func (m *QueryThoughtsStatsRequest) XXX_Size() int { return m.Size() } func (m *QueryThoughtsStatsRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryThoughtsStatsRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryThoughtsStatsRequest proto.InternalMessageInfo type QueryThoughtsStatsResponse struct { ThoughtsStats ThoughtsStats `protobuf:"bytes,1,rep,name=thoughts_stats,json=thoughtsStats,proto3,castrepeated=ThoughtsStats" json:"thoughts_stats"` } func (m *QueryThoughtsStatsResponse) Reset() { *m = QueryThoughtsStatsResponse{} } func (m *QueryThoughtsStatsResponse) String() string { return proto.CompactTextString(m) } func (*QueryThoughtsStatsResponse) ProtoMessage() {} func (*QueryThoughtsStatsResponse) Descriptor() ([]byte, []int) { return fileDescriptor_55109069a1b1f260, []int{8} } func (m *QueryThoughtsStatsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryThoughtsStatsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryThoughtsStatsResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryThoughtsStatsResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryThoughtsStatsResponse.Merge(m, src) } func (m *QueryThoughtsStatsResponse) XXX_Size() int { return m.Size() } func (m *QueryThoughtsStatsResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryThoughtsStatsResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryThoughtsStatsResponse proto.InternalMessageInfo func (m *QueryThoughtsStatsResponse) GetThoughtsStats() ThoughtsStats { if m != nil { return m.ThoughtsStats } return nil } type QueryThoughtsFeesRequest struct{} func (m *QueryThoughtsFeesRequest) Reset() { *m = QueryThoughtsFeesRequest{} } func (m *QueryThoughtsFeesRequest) String() string { return proto.CompactTextString(m) } func (*QueryThoughtsFeesRequest) ProtoMessage() {} func (*QueryThoughtsFeesRequest) Descriptor() ([]byte, []int) { return fileDescriptor_55109069a1b1f260, []int{9} } func (m *QueryThoughtsFeesRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryThoughtsFeesRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryThoughtsFeesRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryThoughtsFeesRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryThoughtsFeesRequest.Merge(m, src) } func (m *QueryThoughtsFeesRequest) XXX_Size() int { return m.Size() } func (m *QueryThoughtsFeesRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryThoughtsFeesRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryThoughtsFeesRequest proto.InternalMessageInfo type QueryThoughtsFeesResponse struct { Fees github_com_cosmos_cosmos_sdk_types.Coins `protobuf:"bytes,3,rep,name=fees,proto3,castrepeated=github.com/cosmos/cosmos-sdk/types.Coins" json:"fees"` } func (m *QueryThoughtsFeesResponse) Reset() { *m = QueryThoughtsFeesResponse{} } func (m *QueryThoughtsFeesResponse) String() string { return proto.CompactTextString(m) } func (*QueryThoughtsFeesResponse) ProtoMessage() {} func (*QueryThoughtsFeesResponse) Descriptor() ([]byte, []int) { return fileDescriptor_55109069a1b1f260, []int{10} } func (m *QueryThoughtsFeesResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryThoughtsFeesResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryThoughtsFeesResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryThoughtsFeesResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryThoughtsFeesResponse.Merge(m, src) } func (m *QueryThoughtsFeesResponse) XXX_Size() int { return m.Size() } func (m *QueryThoughtsFeesResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryThoughtsFeesResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryThoughtsFeesResponse proto.InternalMessageInfo func (m *QueryThoughtsFeesResponse) GetFees() github_com_cosmos_cosmos_sdk_types.Coins { if m != nil { return m.Fees } return nil } func init() { proto.RegisterType((*QueryParamsRequest)(nil), "cyber.dmn.v1beta1.QueryParamsRequest") proto.RegisterType((*QueryParamsResponse)(nil), "cyber.dmn.v1beta1.QueryParamsResponse") proto.RegisterType((*QueryThoughtParamsRequest)(nil), "cyber.dmn.v1beta1.QueryThoughtParamsRequest") proto.RegisterType((*QueryThoughtResponse)(nil), "cyber.dmn.v1beta1.QueryThoughtResponse") proto.RegisterType((*QueryThoughtStatsResponse)(nil), "cyber.dmn.v1beta1.QueryThoughtStatsResponse") proto.RegisterType((*QueryThoughtsRequest)(nil), "cyber.dmn.v1beta1.QueryThoughtsRequest") proto.RegisterType((*QueryThoughtsResponse)(nil), "cyber.dmn.v1beta1.QueryThoughtsResponse") proto.RegisterType((*QueryThoughtsStatsRequest)(nil), "cyber.dmn.v1beta1.QueryThoughtsStatsRequest") proto.RegisterType((*QueryThoughtsStatsResponse)(nil), "cyber.dmn.v1beta1.QueryThoughtsStatsResponse") proto.RegisterType((*QueryThoughtsFeesRequest)(nil), "cyber.dmn.v1beta1.QueryThoughtsFeesRequest") proto.RegisterType((*QueryThoughtsFeesResponse)(nil), "cyber.dmn.v1beta1.QueryThoughtsFeesResponse") } func init() { proto.RegisterFile("cyber/dmn/v1beta1/query.proto", fileDescriptor_55109069a1b1f260) } var fileDescriptor_55109069a1b1f260 = []byte{ // 668 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x94, 0x95, 0xcd, 0x6e, 0xd3, 0x40, 0x10, 0xc7, 0xe3, 0x26, 0x24, 0x65, 0x69, 0x11, 0x2c, 0x29, 0x4a, 0x0c, 0x75, 0x8a, 0x45, 0x3e, 0x24, 0x1a, 0x9b, 0x96, 0x03, 0x12, 0xc7, 0x20, 0xf1, 0x75, 0x40, 0x10, 0x38, 0x21, 0xa1, 0xc8, 0x49, 0x16, 0x27, 0x02, 0x7b, 0x5d, 0xef, 0x06, 0x11, 0x81, 0x38, 0x70, 0x40, 0x1c, 0x91, 0x38, 0x80, 0xc4, 0x1b, 0xf0, 0x24, 0x3d, 0x56, 0xe2, 0xc2, 0x09, 0x50, 0xc2, 0x99, 0x67, 0x40, 0xde, 0x9d, 0xb8, 0xd9, 0x26, 0xa9, 0xc3, 0xa9, 0xce, 0xce, 0xcc, 0x7f, 0x7e, 0x33, 0xbb, 0x7f, 0x15, 0x6d, 0x76, 0x86, 0x6d, 0x12, 0xda, 0x5d, 0xcf, 0xb7, 0x5f, 0xee, 0xb4, 0x09, 0x77, 0x76, 0xec, 0xbd, 0x01, 0x09, 0x87, 0x56, 0x10, 0x52, 0x4e, 0xf1, 0x59, 0x11, 0xb6, 0xba, 0x9e, 0x6f, 0x41, 0x58, 0xcf, 0xbb, 0xd4, 0xa5, 0x22, 0x6a, 0x47, 0x5f, 0x32, 0x51, 0xbf, 0xe8, 0x52, 0xea, 0xbe, 0x20, 0xb6, 0x13, 0xf4, 0x6d, 0xc7, 0xf7, 0x29, 0x77, 0x78, 0x9f, 0xfa, 0x0c, 0xa2, 0x46, 0x87, 0x32, 0x8f, 0x32, 0xbb, 0xed, 0x30, 0x12, 0xf7, 0xe9, 0xd0, 0xbe, 0x0f, 0xf1, 0x39, 0x14, 0x7c, 0x18, 0x10, 0x28, 0x37, 0xf3, 0x08, 0x3f, 0x8c, 0xa0, 0x1e, 0x38, 0xa1, 0xe3, 0xb1, 0x26, 0xd9, 0x1b, 0x10, 0xc6, 0xcd, 0xfb, 0xe8, 0x9c, 0x72, 0xca, 0x02, 0xea, 0x33, 0x82, 0xaf, 0xa3, 0x6c, 0x20, 0x4e, 0x0a, 0xda, 0x96, 0x56, 0x3b, 0xb5, 0x5b, 0xb4, 0x66, 0x66, 0xb0, 0x64, 0x49, 0x23, 0xb3, 0xff, 0xb3, 0x94, 0x6a, 0x42, 0xba, 0x79, 0x17, 0x15, 0x85, 0xde, 0xe3, 0x1e, 0x1d, 0xb8, 0x3d, 0xae, 0x34, 0xc3, 0x05, 0x94, 0x0b, 0x42, 0xea, 0x86, 0x8e, 0x27, 0x64, 0x4f, 0x36, 0x27, 0x3f, 0x31, 0x46, 0x19, 0xdf, 0xf1, 0x48, 0x61, 0x45, 0x1c, 0x8b, 0x6f, 0xb3, 0x89, 0xf2, 0xd3, 0x52, 0x31, 0xdb, 0x0d, 0x94, 0xe3, 0xf2, 0x08, 0xe0, 0xf4, 0x39, 0x70, 0x50, 0x04, 0x74, 0x93, 0x02, 0xd3, 0x55, 0xf1, 0x1e, 0x71, 0x87, 0x1f, 0x0e, 0x7d, 0x0f, 0xad, 0x43, 0x5e, 0x8b, 0x45, 0x01, 0x90, 0x2f, 0x2d, 0x96, 0x17, 0xf5, 0xd0, 0x63, 0x8d, 0x4f, 0x9d, 0x99, 0xe7, 0x55, 0xf8, 0x78, 0xdf, 0x0e, 0xda, 0x38, 0x72, 0x0e, 0xcd, 0xef, 0xa0, 0x55, 0x10, 0x88, 0xfa, 0xa6, 0x13, 0xc6, 0x3a, 0x13, 0xb5, 0xfc, 0xf6, 0xab, 0xb4, 0x1a, 0xeb, 0xc4, 0xd5, 0xe6, 0x05, 0x75, 0x46, 0x06, 0x43, 0xca, 0xfe, 0xaf, 0x91, 0x3e, 0x2f, 0x08, 0x10, 0x4f, 0xd1, 0xe9, 0x89, 0x4c, 0xbc, 0x82, 0xf4, 0x32, 0x2b, 0xd8, 0x00, 0x9e, 0x75, 0x55, 0x77, 0xb2, 0x4f, 0xf9, 0xd3, 0xd4, 0x51, 0x41, 0x69, 0x7e, 0x8b, 0x90, 0x18, 0xec, 0xcd, 0x11, 0x6a, 0x19, 0x03, 0xae, 0x16, 0xca, 0x3c, 0x23, 0x84, 0x15, 0xd2, 0x82, 0xa6, 0x68, 0x49, 0x27, 0x58, 0x91, 0x13, 0x62, 0x9e, 0x9b, 0xb4, 0xef, 0x37, 0xae, 0x02, 0x47, 0xcd, 0xed, 0xf3, 0xde, 0xa0, 0x6d, 0x75, 0xa8, 0x67, 0x83, 0x6d, 0xe4, 0x9f, 0x3a, 0xeb, 0x3e, 0x07, 0x5b, 0x44, 0x05, 0xac, 0x29, 0x84, 0x77, 0xff, 0x66, 0xd1, 0x09, 0xd1, 0x1e, 0xbf, 0x45, 0x59, 0xf9, 0x68, 0x71, 0x79, 0xce, 0xd0, 0xb3, 0x0e, 0xd2, 0x2b, 0x49, 0x69, 0x72, 0x06, 0xb3, 0xfc, 0xee, 0xfb, 0x9f, 0x4f, 0x2b, 0x25, 0xbc, 0x69, 0xcf, 0xfa, 0x34, 0xfa, 0x96, 0x06, 0xc2, 0x1f, 0x34, 0x94, 0x83, 0x1d, 0xe0, 0xed, 0x45, 0xd2, 0xf3, 0xdc, 0xa5, 0x57, 0x13, 0xb2, 0x63, 0x92, 0x8a, 0x20, 0xd9, 0xc2, 0xc6, 0x02, 0x12, 0xb8, 0x34, 0xfc, 0x45, 0x43, 0x6b, 0xd3, 0xb7, 0xfc, 0x9f, 0x3c, 0x49, 0xd9, 0xca, 0xd3, 0x33, 0xb7, 0x05, 0x54, 0x05, 0x5f, 0x3e, 0x1e, 0x4a, 0x3e, 0x4b, 0xfc, 0x5e, 0x43, 0xf1, 0xd3, 0xc7, 0x49, 0x83, 0xc7, 0x44, 0xb5, 0xe4, 0x44, 0xa0, 0xa9, 0x0a, 0x9a, 0x4b, 0xb8, 0x74, 0x3c, 0x0d, 0xc3, 0x5f, 0x35, 0xa4, 0xbe, 0xf9, 0xc4, 0x25, 0x29, 0x7e, 0xd4, 0xeb, 0x4b, 0x66, 0x03, 0x57, 0x5d, 0x70, 0x55, 0x71, 0x39, 0x81, 0x0b, 0xd6, 0xf4, 0xf9, 0xf0, 0x06, 0x85, 0xa1, 0xf0, 0x95, 0xa4, 0x76, 0x53, 0x96, 0x4c, 0xbc, 0x40, 0xc5, 0xa3, 0xcb, 0x5e, 0x20, 0x6b, 0x45, 0x86, 0x6b, 0xdc, 0xde, 0x1f, 0x19, 0xda, 0xc1, 0xc8, 0xd0, 0x7e, 0x8f, 0x0c, 0xed, 0xe3, 0xd8, 0x48, 0x1d, 0x8c, 0x8d, 0xd4, 0x8f, 0xb1, 0x91, 0x7a, 0x52, 0x9f, 0xb6, 0x6e, 0xa4, 0xd4, 0xa1, 0xbe, 0x1b, 0x12, 0xc6, 0x6c, 0x97, 0xd6, 0xa5, 0xf4, 0x2b, 0x29, 0x18, 0xb9, 0xb8, 0x9d, 0x15, 0xff, 0xdd, 0xae, 0xfd, 0x0b, 0x00, 0x00, 0xff, 0xff, 0x7a, 0x0c, 0x0d, 0x7e, 0x84, 0x07, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. var ( _ context.Context _ grpc.ClientConn ) // This is a compile-time assertion to ensure that this generated file // is compatible with the grpc package it is being compiled against. const _ = grpc.SupportPackageIsVersion4 // QueryClient is the client API for Query service. // // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. type QueryClient interface { Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) Thought(ctx context.Context, in *QueryThoughtParamsRequest, opts ...grpc.CallOption) (*QueryThoughtResponse, error) ThoughtStats(ctx context.Context, in *QueryThoughtParamsRequest, opts ...grpc.CallOption) (*QueryThoughtStatsResponse, error) Thoughts(ctx context.Context, in *QueryThoughtsRequest, opts ...grpc.CallOption) (*QueryThoughtsResponse, error) ThoughtsStats(ctx context.Context, in *QueryThoughtsStatsRequest, opts ...grpc.CallOption) (*QueryThoughtsStatsResponse, error) ThoughtsFees(ctx context.Context, in *QueryThoughtsFeesRequest, opts ...grpc.CallOption) (*QueryThoughtsFeesResponse, error) } type queryClient struct { cc grpc1.ClientConn } func NewQueryClient(cc grpc1.ClientConn) QueryClient { return &queryClient{cc} } func (c *queryClient) Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) { out := new(QueryParamsResponse) err := c.cc.Invoke(ctx, "/cyber.dmn.v1beta1.Query/Params", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) Thought(ctx context.Context, in *QueryThoughtParamsRequest, opts ...grpc.CallOption) (*QueryThoughtResponse, error) { out := new(QueryThoughtResponse) err := c.cc.Invoke(ctx, "/cyber.dmn.v1beta1.Query/Thought", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) ThoughtStats(ctx context.Context, in *QueryThoughtParamsRequest, opts ...grpc.CallOption) (*QueryThoughtStatsResponse, error) { out := new(QueryThoughtStatsResponse) err := c.cc.Invoke(ctx, "/cyber.dmn.v1beta1.Query/ThoughtStats", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) Thoughts(ctx context.Context, in *QueryThoughtsRequest, opts ...grpc.CallOption) (*QueryThoughtsResponse, error) { out := new(QueryThoughtsResponse) err := c.cc.Invoke(ctx, "/cyber.dmn.v1beta1.Query/Thoughts", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) ThoughtsStats(ctx context.Context, in *QueryThoughtsStatsRequest, opts ...grpc.CallOption) (*QueryThoughtsStatsResponse, error) { out := new(QueryThoughtsStatsResponse) err := c.cc.Invoke(ctx, "/cyber.dmn.v1beta1.Query/ThoughtsStats", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) ThoughtsFees(ctx context.Context, in *QueryThoughtsFeesRequest, opts ...grpc.CallOption) (*QueryThoughtsFeesResponse, error) { out := new(QueryThoughtsFeesResponse) err := c.cc.Invoke(ctx, "/cyber.dmn.v1beta1.Query/ThoughtsFees", in, out, opts...) if err != nil { return nil, err } return out, nil } // QueryServer is the server API for Query service. type QueryServer interface { Params(context.Context, *QueryParamsRequest) (*QueryParamsResponse, error) Thought(context.Context, *QueryThoughtParamsRequest) (*QueryThoughtResponse, error) ThoughtStats(context.Context, *QueryThoughtParamsRequest) (*QueryThoughtStatsResponse, error) Thoughts(context.Context, *QueryThoughtsRequest) (*QueryThoughtsResponse, error) ThoughtsStats(context.Context, *QueryThoughtsStatsRequest) (*QueryThoughtsStatsResponse, error) ThoughtsFees(context.Context, *QueryThoughtsFeesRequest) (*QueryThoughtsFeesResponse, error) } // UnimplementedQueryServer can be embedded to have forward compatible implementations. type UnimplementedQueryServer struct{} func (*UnimplementedQueryServer) Params(ctx context.Context, req *QueryParamsRequest) (*QueryParamsResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method Params not implemented") } func (*UnimplementedQueryServer) Thought(ctx context.Context, req *QueryThoughtParamsRequest) (*QueryThoughtResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method Thought not implemented") } func (*UnimplementedQueryServer) ThoughtStats(ctx context.Context, req *QueryThoughtParamsRequest) (*QueryThoughtStatsResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method ThoughtStats not implemented") } func (*UnimplementedQueryServer) Thoughts(ctx context.Context, req *QueryThoughtsRequest) (*QueryThoughtsResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method Thoughts not implemented") } func (*UnimplementedQueryServer) ThoughtsStats(ctx context.Context, req *QueryThoughtsStatsRequest) (*QueryThoughtsStatsResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method ThoughtsStats not implemented") } func (*UnimplementedQueryServer) ThoughtsFees(ctx context.Context, req *QueryThoughtsFeesRequest) (*QueryThoughtsFeesResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method ThoughtsFees not implemented") } func RegisterQueryServer(s grpc1.Server, srv QueryServer) { s.RegisterService(&_Query_serviceDesc, srv) } func _Query_Params_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryParamsRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).Params(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.dmn.v1beta1.Query/Params", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Params(ctx, req.(*QueryParamsRequest)) } return interceptor(ctx, in, info, handler) } func _Query_Thought_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryThoughtParamsRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).Thought(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.dmn.v1beta1.Query/Thought", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Thought(ctx, req.(*QueryThoughtParamsRequest)) } return interceptor(ctx, in, info, handler) } func _Query_ThoughtStats_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryThoughtParamsRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).ThoughtStats(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.dmn.v1beta1.Query/ThoughtStats", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).ThoughtStats(ctx, req.(*QueryThoughtParamsRequest)) } return interceptor(ctx, in, info, handler) } func _Query_Thoughts_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryThoughtsRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).Thoughts(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.dmn.v1beta1.Query/Thoughts", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Thoughts(ctx, req.(*QueryThoughtsRequest)) } return interceptor(ctx, in, info, handler) } func _Query_ThoughtsStats_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryThoughtsStatsRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).ThoughtsStats(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.dmn.v1beta1.Query/ThoughtsStats", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).ThoughtsStats(ctx, req.(*QueryThoughtsStatsRequest)) } return interceptor(ctx, in, info, handler) } func _Query_ThoughtsFees_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryThoughtsFeesRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).ThoughtsFees(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.dmn.v1beta1.Query/ThoughtsFees", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).ThoughtsFees(ctx, req.(*QueryThoughtsFeesRequest)) } return interceptor(ctx, in, info, handler) } var _Query_serviceDesc = grpc.ServiceDesc{ ServiceName: "cyber.dmn.v1beta1.Query", HandlerType: (*QueryServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "Params", Handler: _Query_Params_Handler, }, { MethodName: "Thought", Handler: _Query_Thought_Handler, }, { MethodName: "ThoughtStats", Handler: _Query_ThoughtStats_Handler, }, { MethodName: "Thoughts", Handler: _Query_Thoughts_Handler, }, { MethodName: "ThoughtsStats", Handler: _Query_ThoughtsStats_Handler, }, { MethodName: "ThoughtsFees", Handler: _Query_ThoughtsFees_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "cyber/dmn/v1beta1/query.proto", } func (m *QueryParamsRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryParamsRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryParamsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *QueryParamsResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryParamsResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryParamsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.Params.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa return len(dAtA) - i, nil } func (m *QueryThoughtParamsRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryThoughtParamsRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryThoughtParamsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.Name) > 0 { i -= len(m.Name) copy(dAtA[i:], m.Name) i = encodeVarintQuery(dAtA, i, uint64(len(m.Name))) i-- dAtA[i] = 0x12 } if len(m.Program) > 0 { i -= len(m.Program) copy(dAtA[i:], m.Program) i = encodeVarintQuery(dAtA, i, uint64(len(m.Program))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *QueryThoughtResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryThoughtResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryThoughtResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.Thought.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa return len(dAtA) - i, nil } func (m *QueryThoughtStatsResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryThoughtStatsResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryThoughtStatsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.ThoughtStats.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa return len(dAtA) - i, nil } func (m *QueryThoughtsRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryThoughtsRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryThoughtsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *QueryThoughtsResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryThoughtsResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryThoughtsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.Thoughts) > 0 { for iNdEx := len(m.Thoughts) - 1; iNdEx >= 0; iNdEx-- { { size, err := m.Thoughts[iNdEx].MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa } } return len(dAtA) - i, nil } func (m *QueryThoughtsStatsRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryThoughtsStatsRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryThoughtsStatsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *QueryThoughtsStatsResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryThoughtsStatsResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryThoughtsStatsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.ThoughtsStats) > 0 { for iNdEx := len(m.ThoughtsStats) - 1; iNdEx >= 0; iNdEx-- { { size, err := m.ThoughtsStats[iNdEx].MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa } } return len(dAtA) - i, nil } func (m *QueryThoughtsFeesRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryThoughtsFeesRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryThoughtsFeesRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *QueryThoughtsFeesResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryThoughtsFeesResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryThoughtsFeesResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.Fees) > 0 { for iNdEx := len(m.Fees) - 1; iNdEx >= 0; iNdEx-- { { size, err := m.Fees[iNdEx].MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x1a } } return len(dAtA) - i, nil } func encodeVarintQuery(dAtA []byte, offset int, v uint64) int { offset -= sovQuery(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *QueryParamsRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *QueryParamsResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l l = m.Params.Size() n += 1 + l + sovQuery(uint64(l)) return n } func (m *QueryThoughtParamsRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Program) if l > 0 { n += 1 + l + sovQuery(uint64(l)) } l = len(m.Name) if l > 0 { n += 1 + l + sovQuery(uint64(l)) } return n } func (m *QueryThoughtResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l l = m.Thought.Size() n += 1 + l + sovQuery(uint64(l)) return n } func (m *QueryThoughtStatsResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l l = m.ThoughtStats.Size() n += 1 + l + sovQuery(uint64(l)) return n } func (m *QueryThoughtsRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *QueryThoughtsResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l if len(m.Thoughts) > 0 { for _, e := range m.Thoughts { l = e.Size() n += 1 + l + sovQuery(uint64(l)) } } return n } func (m *QueryThoughtsStatsRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *QueryThoughtsStatsResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l if len(m.ThoughtsStats) > 0 { for _, e := range m.ThoughtsStats { l = e.Size() n += 1 + l + sovQuery(uint64(l)) } } return n } func (m *QueryThoughtsFeesRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *QueryThoughtsFeesResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l if len(m.Fees) > 0 { for _, e := range m.Fees { l = e.Size() n += 1 + l + sovQuery(uint64(l)) } } return n } func sovQuery(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozQuery(x uint64) (n int) { return sovQuery(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *QueryParamsRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryParamsRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryParamsRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryParamsResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryParamsResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryParamsResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Params.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryThoughtParamsRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryThoughtParamsRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryThoughtParamsRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Program", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } m.Program = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryThoughtResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryThoughtResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryThoughtResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Thought", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Thought.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryThoughtStatsResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryThoughtStatsResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryThoughtStatsResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field ThoughtStats", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.ThoughtStats.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryThoughtsRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryThoughtsRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryThoughtsRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryThoughtsResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryThoughtsResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryThoughtsResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Thoughts", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } m.Thoughts = append(m.Thoughts, Thought{}) if err := m.Thoughts[len(m.Thoughts)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryThoughtsStatsRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryThoughtsStatsRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryThoughtsStatsRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryThoughtsStatsResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryThoughtsStatsResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryThoughtsStatsResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field ThoughtsStats", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } m.ThoughtsStats = append(m.ThoughtsStats, ThoughtStats{}) if err := m.ThoughtsStats[len(m.ThoughtsStats)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryThoughtsFeesRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryThoughtsFeesRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryThoughtsFeesRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryThoughtsFeesResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryThoughtsFeesResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryThoughtsFeesResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 3: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Fees", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } m.Fees = append(m.Fees, types.Coin{}) if err := m.Fees[len(m.Fees)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipQuery(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowQuery } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowQuery } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowQuery } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthQuery } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupQuery } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthQuery } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthQuery = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowQuery = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupQuery = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/dmn/types/query.pb.gw.go ================================================ // Code generated by protoc-gen-grpc-gateway. DO NOT EDIT. // source: cyber/dmn/v1beta1/query.proto /* Package types is a reverse proxy. It translates gRPC into RESTful JSON APIs. */ package types import ( "context" "io" "net/http" "github.com/golang/protobuf/descriptor" "github.com/golang/protobuf/proto" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/grpc-ecosystem/grpc-gateway/utilities" "google.golang.org/grpc" "google.golang.org/grpc/codes" "google.golang.org/grpc/grpclog" "google.golang.org/grpc/metadata" "google.golang.org/grpc/status" ) // Suppress "imported and not used" errors var ( _ codes.Code _ io.Reader _ status.Status _ = runtime.String _ = utilities.NewDoubleArray _ = descriptor.ForMessage _ = metadata.Join ) func request_Query_Params_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryParamsRequest var metadata runtime.ServerMetadata msg, err := client.Params(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_Params_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryParamsRequest var metadata runtime.ServerMetadata msg, err := server.Params(ctx, &protoReq) return msg, metadata, err } var filter_Query_Thought_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} func request_Query_Thought_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryThoughtParamsRequest var metadata runtime.ServerMetadata if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_Thought_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := client.Thought(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_Thought_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryThoughtParamsRequest var metadata runtime.ServerMetadata if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_Thought_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := server.Thought(ctx, &protoReq) return msg, metadata, err } var filter_Query_ThoughtStats_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} func request_Query_ThoughtStats_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryThoughtParamsRequest var metadata runtime.ServerMetadata if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_ThoughtStats_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := client.ThoughtStats(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_ThoughtStats_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryThoughtParamsRequest var metadata runtime.ServerMetadata if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_ThoughtStats_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := server.ThoughtStats(ctx, &protoReq) return msg, metadata, err } func request_Query_Thoughts_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryThoughtsRequest var metadata runtime.ServerMetadata msg, err := client.Thoughts(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_Thoughts_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryThoughtsRequest var metadata runtime.ServerMetadata msg, err := server.Thoughts(ctx, &protoReq) return msg, metadata, err } func request_Query_ThoughtsStats_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryThoughtsStatsRequest var metadata runtime.ServerMetadata msg, err := client.ThoughtsStats(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_ThoughtsStats_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryThoughtsStatsRequest var metadata runtime.ServerMetadata msg, err := server.ThoughtsStats(ctx, &protoReq) return msg, metadata, err } func request_Query_ThoughtsFees_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryThoughtsFeesRequest var metadata runtime.ServerMetadata msg, err := client.ThoughtsFees(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_ThoughtsFees_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryThoughtsFeesRequest var metadata runtime.ServerMetadata msg, err := server.ThoughtsFees(ctx, &protoReq) return msg, metadata, err } // RegisterQueryHandlerServer registers the http handlers for service Query to "mux". // UnaryRPC :call QueryServer directly. // StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. // Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterQueryHandlerFromEndpoint instead. func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, server QueryServer) error { mux.Handle("GET", pattern_Query_Params_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_Params_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Params_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_Thought_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_Thought_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Thought_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_ThoughtStats_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_ThoughtStats_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_ThoughtStats_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_Thoughts_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_Thoughts_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Thoughts_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_ThoughtsStats_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_ThoughtsStats_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_ThoughtsStats_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_ThoughtsFees_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_ThoughtsFees_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_ThoughtsFees_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) return nil } // RegisterQueryHandlerFromEndpoint is same as RegisterQueryHandler but // automatically dials to "endpoint" and closes the connection when "ctx" gets done. func RegisterQueryHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error) { conn, err := grpc.Dial(endpoint, opts...) if err != nil { return err } defer func() { if err != nil { if cerr := conn.Close(); cerr != nil { grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr) } return } go func() { <-ctx.Done() if cerr := conn.Close(); cerr != nil { grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr) } }() }() return RegisterQueryHandler(ctx, mux, conn) } // RegisterQueryHandler registers the http handlers for service Query to "mux". // The handlers forward requests to the grpc endpoint over "conn". func RegisterQueryHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error { return RegisterQueryHandlerClient(ctx, mux, NewQueryClient(conn)) } // RegisterQueryHandlerClient registers the http handlers for service Query // to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "QueryClient". // Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "QueryClient" // doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in // "QueryClient" to call the correct interceptors. func RegisterQueryHandlerClient(ctx context.Context, mux *runtime.ServeMux, client QueryClient) error { mux.Handle("GET", pattern_Query_Params_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_Params_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Params_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_Thought_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_Thought_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Thought_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_ThoughtStats_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_ThoughtStats_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_ThoughtStats_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_Thoughts_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_Thoughts_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Thoughts_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_ThoughtsStats_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_ThoughtsStats_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_ThoughtsStats_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_ThoughtsFees_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_ThoughtsFees_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_ThoughtsFees_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) return nil } var ( pattern_Query_Params_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 1, 2, 3}, []string{"cyber", "dmn", "v1beta1", "params"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_Thought_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 1, 2, 3}, []string{"cyber", "dmn", "v1beta1", "thought"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_ThoughtStats_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 1, 2, 3}, []string{"cyber", "dmn", "v1beta1", "thought_stats"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_Thoughts_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 1, 2, 3}, []string{"cyber", "dmn", "v1beta1", "thoughts"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_ThoughtsStats_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 1, 2, 3}, []string{"cyber", "dmn", "v1beta1", "thoughts_stats"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_ThoughtsFees_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 1, 2, 3}, []string{"cyber", "dmn", "v1beta1", "thoughts_fees"}, "", runtime.AssumeColonVerbOpt(false))) ) var ( forward_Query_Params_0 = runtime.ForwardResponseMessage forward_Query_Thought_0 = runtime.ForwardResponseMessage forward_Query_ThoughtStats_0 = runtime.ForwardResponseMessage forward_Query_Thoughts_0 = runtime.ForwardResponseMessage forward_Query_ThoughtsStats_0 = runtime.ForwardResponseMessage forward_Query_ThoughtsFees_0 = runtime.ForwardResponseMessage ) ================================================ FILE: x/dmn/types/thought.go ================================================ package types import ( "sort" sdk "github.com/cosmos/cosmos-sdk/types" ) func NewThought( program string, trigger Trigger, load Load, name string, particle string, ) Thought { return Thought{ Program: program, Trigger: trigger, Load: load, Name: name, Particle: particle, } } type Thoughts []Thought type ThoughtsStats []ThoughtStats func (js Thoughts) Sort() { sort.Sort(js) } func (js Thoughts) Len() int { return len(js) } func (js Thoughts) Less(i, j int) bool { return js[j].Load.GasPrice.IsLT(js[i].Load.GasPrice) // return js[i].Load.GasPrice.Amount.GT(js[j].Load.GasPrice.Amount) } func (js Thoughts) Swap(i, j int) { js[i], js[j] = js[j], js[i] } func NewTrigger(period, block uint64) Trigger { return Trigger{ Period: period, Block: block, } } func NewStats( program, name string, calls, fees, gas, block uint64, ) ThoughtStats { return ThoughtStats{ Program: program, Name: name, Calls: calls, Fees: fees, Gas: gas, LastBlock: block, } } func NewLoad(calldata string, gasprice sdk.Coin) Load { return Load{ Input: calldata, GasPrice: gasprice, } } ================================================ FILE: x/dmn/types/tx.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: cyber/dmn/v1beta1/tx.proto package types import ( context "context" fmt "fmt" io "io" math "math" math_bits "math/bits" _ "github.com/cosmos/cosmos-proto" _ "github.com/cosmos/cosmos-sdk/types" github_com_cosmos_cosmos_sdk_types "github.com/cosmos/cosmos-sdk/types" _ "github.com/cosmos/cosmos-sdk/types/msgservice" _ "github.com/cosmos/gogoproto/gogoproto" grpc1 "github.com/cosmos/gogoproto/grpc" proto "github.com/cosmos/gogoproto/proto" grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" ) // Reference imports to suppress errors if they are not otherwise used. var ( _ = proto.Marshal _ = fmt.Errorf _ = math.Inf ) // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package type MsgCreateThought struct { Program string `protobuf:"bytes,1,opt,name=program,proto3" json:"program,omitempty"` Trigger Trigger `protobuf:"bytes,2,opt,name=trigger,proto3" json:"trigger"` Load Load `protobuf:"bytes,3,opt,name=load,proto3" json:"load"` Name string `protobuf:"bytes,4,opt,name=name,proto3" json:"name,omitempty"` Particle string `protobuf:"bytes,5,opt,name=particle,proto3" json:"particle,omitempty"` } func (m *MsgCreateThought) Reset() { *m = MsgCreateThought{} } func (m *MsgCreateThought) String() string { return proto.CompactTextString(m) } func (*MsgCreateThought) ProtoMessage() {} func (*MsgCreateThought) Descriptor() ([]byte, []int) { return fileDescriptor_4770788ccd571dd4, []int{0} } func (m *MsgCreateThought) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgCreateThought) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgCreateThought.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgCreateThought) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgCreateThought.Merge(m, src) } func (m *MsgCreateThought) XXX_Size() int { return m.Size() } func (m *MsgCreateThought) XXX_DiscardUnknown() { xxx_messageInfo_MsgCreateThought.DiscardUnknown(m) } var xxx_messageInfo_MsgCreateThought proto.InternalMessageInfo func (m *MsgCreateThought) GetProgram() string { if m != nil { return m.Program } return "" } func (m *MsgCreateThought) GetTrigger() Trigger { if m != nil { return m.Trigger } return Trigger{} } func (m *MsgCreateThought) GetLoad() Load { if m != nil { return m.Load } return Load{} } func (m *MsgCreateThought) GetName() string { if m != nil { return m.Name } return "" } func (m *MsgCreateThought) GetParticle() string { if m != nil { return m.Particle } return "" } type MsgForgetThought struct { Program string `protobuf:"bytes,1,opt,name=program,proto3" json:"program,omitempty"` Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"` } func (m *MsgForgetThought) Reset() { *m = MsgForgetThought{} } func (m *MsgForgetThought) String() string { return proto.CompactTextString(m) } func (*MsgForgetThought) ProtoMessage() {} func (*MsgForgetThought) Descriptor() ([]byte, []int) { return fileDescriptor_4770788ccd571dd4, []int{1} } func (m *MsgForgetThought) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgForgetThought) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgForgetThought.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgForgetThought) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgForgetThought.Merge(m, src) } func (m *MsgForgetThought) XXX_Size() int { return m.Size() } func (m *MsgForgetThought) XXX_DiscardUnknown() { xxx_messageInfo_MsgForgetThought.DiscardUnknown(m) } var xxx_messageInfo_MsgForgetThought proto.InternalMessageInfo func (m *MsgForgetThought) GetProgram() string { if m != nil { return m.Program } return "" } func (m *MsgForgetThought) GetName() string { if m != nil { return m.Name } return "" } type MsgChangeThoughtParticle struct { Program string `protobuf:"bytes,1,opt,name=program,proto3" json:"program,omitempty"` Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"` Particle string `protobuf:"bytes,3,opt,name=particle,proto3" json:"particle,omitempty"` } func (m *MsgChangeThoughtParticle) Reset() { *m = MsgChangeThoughtParticle{} } func (m *MsgChangeThoughtParticle) String() string { return proto.CompactTextString(m) } func (*MsgChangeThoughtParticle) ProtoMessage() {} func (*MsgChangeThoughtParticle) Descriptor() ([]byte, []int) { return fileDescriptor_4770788ccd571dd4, []int{2} } func (m *MsgChangeThoughtParticle) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgChangeThoughtParticle) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgChangeThoughtParticle.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgChangeThoughtParticle) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgChangeThoughtParticle.Merge(m, src) } func (m *MsgChangeThoughtParticle) XXX_Size() int { return m.Size() } func (m *MsgChangeThoughtParticle) XXX_DiscardUnknown() { xxx_messageInfo_MsgChangeThoughtParticle.DiscardUnknown(m) } var xxx_messageInfo_MsgChangeThoughtParticle proto.InternalMessageInfo func (m *MsgChangeThoughtParticle) GetProgram() string { if m != nil { return m.Program } return "" } func (m *MsgChangeThoughtParticle) GetName() string { if m != nil { return m.Name } return "" } func (m *MsgChangeThoughtParticle) GetParticle() string { if m != nil { return m.Particle } return "" } type MsgChangeThoughtName struct { Program string `protobuf:"bytes,1,opt,name=program,proto3" json:"program,omitempty"` Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"` NewName string `protobuf:"bytes,3,opt,name=new_name,json=newName,proto3" json:"new_name,omitempty"` } func (m *MsgChangeThoughtName) Reset() { *m = MsgChangeThoughtName{} } func (m *MsgChangeThoughtName) String() string { return proto.CompactTextString(m) } func (*MsgChangeThoughtName) ProtoMessage() {} func (*MsgChangeThoughtName) Descriptor() ([]byte, []int) { return fileDescriptor_4770788ccd571dd4, []int{3} } func (m *MsgChangeThoughtName) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgChangeThoughtName) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgChangeThoughtName.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgChangeThoughtName) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgChangeThoughtName.Merge(m, src) } func (m *MsgChangeThoughtName) XXX_Size() int { return m.Size() } func (m *MsgChangeThoughtName) XXX_DiscardUnknown() { xxx_messageInfo_MsgChangeThoughtName.DiscardUnknown(m) } var xxx_messageInfo_MsgChangeThoughtName proto.InternalMessageInfo func (m *MsgChangeThoughtName) GetProgram() string { if m != nil { return m.Program } return "" } func (m *MsgChangeThoughtName) GetName() string { if m != nil { return m.Name } return "" } func (m *MsgChangeThoughtName) GetNewName() string { if m != nil { return m.NewName } return "" } type MsgChangeThoughtInput struct { Program string `protobuf:"bytes,1,opt,name=program,proto3" json:"program,omitempty"` Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"` Input string `protobuf:"bytes,3,opt,name=input,proto3" json:"input,omitempty"` } func (m *MsgChangeThoughtInput) Reset() { *m = MsgChangeThoughtInput{} } func (m *MsgChangeThoughtInput) String() string { return proto.CompactTextString(m) } func (*MsgChangeThoughtInput) ProtoMessage() {} func (*MsgChangeThoughtInput) Descriptor() ([]byte, []int) { return fileDescriptor_4770788ccd571dd4, []int{4} } func (m *MsgChangeThoughtInput) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgChangeThoughtInput) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgChangeThoughtInput.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgChangeThoughtInput) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgChangeThoughtInput.Merge(m, src) } func (m *MsgChangeThoughtInput) XXX_Size() int { return m.Size() } func (m *MsgChangeThoughtInput) XXX_DiscardUnknown() { xxx_messageInfo_MsgChangeThoughtInput.DiscardUnknown(m) } var xxx_messageInfo_MsgChangeThoughtInput proto.InternalMessageInfo func (m *MsgChangeThoughtInput) GetProgram() string { if m != nil { return m.Program } return "" } func (m *MsgChangeThoughtInput) GetName() string { if m != nil { return m.Name } return "" } func (m *MsgChangeThoughtInput) GetInput() string { if m != nil { return m.Input } return "" } type MsgChangeThoughtGasPrice struct { Program string `protobuf:"bytes,1,opt,name=program,proto3" json:"program,omitempty"` Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"` GasPrice github_com_cosmos_cosmos_sdk_types.Coin `protobuf:"bytes,3,opt,name=gas_price,json=gasPrice,proto3,casttype=github.com/cosmos/cosmos-sdk/types.Coin" json:"gas_price"` } func (m *MsgChangeThoughtGasPrice) Reset() { *m = MsgChangeThoughtGasPrice{} } func (m *MsgChangeThoughtGasPrice) String() string { return proto.CompactTextString(m) } func (*MsgChangeThoughtGasPrice) ProtoMessage() {} func (*MsgChangeThoughtGasPrice) Descriptor() ([]byte, []int) { return fileDescriptor_4770788ccd571dd4, []int{5} } func (m *MsgChangeThoughtGasPrice) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgChangeThoughtGasPrice) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgChangeThoughtGasPrice.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgChangeThoughtGasPrice) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgChangeThoughtGasPrice.Merge(m, src) } func (m *MsgChangeThoughtGasPrice) XXX_Size() int { return m.Size() } func (m *MsgChangeThoughtGasPrice) XXX_DiscardUnknown() { xxx_messageInfo_MsgChangeThoughtGasPrice.DiscardUnknown(m) } var xxx_messageInfo_MsgChangeThoughtGasPrice proto.InternalMessageInfo func (m *MsgChangeThoughtGasPrice) GetProgram() string { if m != nil { return m.Program } return "" } func (m *MsgChangeThoughtGasPrice) GetName() string { if m != nil { return m.Name } return "" } func (m *MsgChangeThoughtGasPrice) GetGasPrice() github_com_cosmos_cosmos_sdk_types.Coin { if m != nil { return m.GasPrice } return github_com_cosmos_cosmos_sdk_types.Coin{} } type MsgChangeThoughtPeriod struct { Program string `protobuf:"bytes,1,opt,name=program,proto3" json:"program,omitempty"` Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"` Period uint64 `protobuf:"varint,3,opt,name=period,proto3" json:"period,omitempty"` } func (m *MsgChangeThoughtPeriod) Reset() { *m = MsgChangeThoughtPeriod{} } func (m *MsgChangeThoughtPeriod) String() string { return proto.CompactTextString(m) } func (*MsgChangeThoughtPeriod) ProtoMessage() {} func (*MsgChangeThoughtPeriod) Descriptor() ([]byte, []int) { return fileDescriptor_4770788ccd571dd4, []int{6} } func (m *MsgChangeThoughtPeriod) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgChangeThoughtPeriod) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgChangeThoughtPeriod.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgChangeThoughtPeriod) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgChangeThoughtPeriod.Merge(m, src) } func (m *MsgChangeThoughtPeriod) XXX_Size() int { return m.Size() } func (m *MsgChangeThoughtPeriod) XXX_DiscardUnknown() { xxx_messageInfo_MsgChangeThoughtPeriod.DiscardUnknown(m) } var xxx_messageInfo_MsgChangeThoughtPeriod proto.InternalMessageInfo func (m *MsgChangeThoughtPeriod) GetProgram() string { if m != nil { return m.Program } return "" } func (m *MsgChangeThoughtPeriod) GetName() string { if m != nil { return m.Name } return "" } func (m *MsgChangeThoughtPeriod) GetPeriod() uint64 { if m != nil { return m.Period } return 0 } type MsgChangeThoughtBlock struct { Program string `protobuf:"bytes,1,opt,name=program,proto3" json:"program,omitempty"` Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"` Block uint64 `protobuf:"varint,3,opt,name=block,proto3" json:"block,omitempty"` } func (m *MsgChangeThoughtBlock) Reset() { *m = MsgChangeThoughtBlock{} } func (m *MsgChangeThoughtBlock) String() string { return proto.CompactTextString(m) } func (*MsgChangeThoughtBlock) ProtoMessage() {} func (*MsgChangeThoughtBlock) Descriptor() ([]byte, []int) { return fileDescriptor_4770788ccd571dd4, []int{7} } func (m *MsgChangeThoughtBlock) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgChangeThoughtBlock) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgChangeThoughtBlock.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgChangeThoughtBlock) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgChangeThoughtBlock.Merge(m, src) } func (m *MsgChangeThoughtBlock) XXX_Size() int { return m.Size() } func (m *MsgChangeThoughtBlock) XXX_DiscardUnknown() { xxx_messageInfo_MsgChangeThoughtBlock.DiscardUnknown(m) } var xxx_messageInfo_MsgChangeThoughtBlock proto.InternalMessageInfo func (m *MsgChangeThoughtBlock) GetProgram() string { if m != nil { return m.Program } return "" } func (m *MsgChangeThoughtBlock) GetName() string { if m != nil { return m.Name } return "" } func (m *MsgChangeThoughtBlock) GetBlock() uint64 { if m != nil { return m.Block } return 0 } type MsgUpdateParams struct { Authority string `protobuf:"bytes,1,opt,name=authority,proto3" json:"authority,omitempty"` Params Params `protobuf:"bytes,2,opt,name=params,proto3" json:"params"` } func (m *MsgUpdateParams) Reset() { *m = MsgUpdateParams{} } func (m *MsgUpdateParams) String() string { return proto.CompactTextString(m) } func (*MsgUpdateParams) ProtoMessage() {} func (*MsgUpdateParams) Descriptor() ([]byte, []int) { return fileDescriptor_4770788ccd571dd4, []int{8} } func (m *MsgUpdateParams) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgUpdateParams) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgUpdateParams.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgUpdateParams) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgUpdateParams.Merge(m, src) } func (m *MsgUpdateParams) XXX_Size() int { return m.Size() } func (m *MsgUpdateParams) XXX_DiscardUnknown() { xxx_messageInfo_MsgUpdateParams.DiscardUnknown(m) } var xxx_messageInfo_MsgUpdateParams proto.InternalMessageInfo func (m *MsgUpdateParams) GetAuthority() string { if m != nil { return m.Authority } return "" } func (m *MsgUpdateParams) GetParams() Params { if m != nil { return m.Params } return Params{} } type MsgCreateThoughtResponse struct{} func (m *MsgCreateThoughtResponse) Reset() { *m = MsgCreateThoughtResponse{} } func (m *MsgCreateThoughtResponse) String() string { return proto.CompactTextString(m) } func (*MsgCreateThoughtResponse) ProtoMessage() {} func (*MsgCreateThoughtResponse) Descriptor() ([]byte, []int) { return fileDescriptor_4770788ccd571dd4, []int{9} } func (m *MsgCreateThoughtResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgCreateThoughtResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgCreateThoughtResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgCreateThoughtResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgCreateThoughtResponse.Merge(m, src) } func (m *MsgCreateThoughtResponse) XXX_Size() int { return m.Size() } func (m *MsgCreateThoughtResponse) XXX_DiscardUnknown() { xxx_messageInfo_MsgCreateThoughtResponse.DiscardUnknown(m) } var xxx_messageInfo_MsgCreateThoughtResponse proto.InternalMessageInfo type MsgForgetThoughtResponse struct{} func (m *MsgForgetThoughtResponse) Reset() { *m = MsgForgetThoughtResponse{} } func (m *MsgForgetThoughtResponse) String() string { return proto.CompactTextString(m) } func (*MsgForgetThoughtResponse) ProtoMessage() {} func (*MsgForgetThoughtResponse) Descriptor() ([]byte, []int) { return fileDescriptor_4770788ccd571dd4, []int{10} } func (m *MsgForgetThoughtResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgForgetThoughtResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgForgetThoughtResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgForgetThoughtResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgForgetThoughtResponse.Merge(m, src) } func (m *MsgForgetThoughtResponse) XXX_Size() int { return m.Size() } func (m *MsgForgetThoughtResponse) XXX_DiscardUnknown() { xxx_messageInfo_MsgForgetThoughtResponse.DiscardUnknown(m) } var xxx_messageInfo_MsgForgetThoughtResponse proto.InternalMessageInfo type MsgChangeThoughtParticleResponse struct{} func (m *MsgChangeThoughtParticleResponse) Reset() { *m = MsgChangeThoughtParticleResponse{} } func (m *MsgChangeThoughtParticleResponse) String() string { return proto.CompactTextString(m) } func (*MsgChangeThoughtParticleResponse) ProtoMessage() {} func (*MsgChangeThoughtParticleResponse) Descriptor() ([]byte, []int) { return fileDescriptor_4770788ccd571dd4, []int{11} } func (m *MsgChangeThoughtParticleResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgChangeThoughtParticleResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgChangeThoughtParticleResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgChangeThoughtParticleResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgChangeThoughtParticleResponse.Merge(m, src) } func (m *MsgChangeThoughtParticleResponse) XXX_Size() int { return m.Size() } func (m *MsgChangeThoughtParticleResponse) XXX_DiscardUnknown() { xxx_messageInfo_MsgChangeThoughtParticleResponse.DiscardUnknown(m) } var xxx_messageInfo_MsgChangeThoughtParticleResponse proto.InternalMessageInfo type MsgChangeThoughtNameResponse struct{} func (m *MsgChangeThoughtNameResponse) Reset() { *m = MsgChangeThoughtNameResponse{} } func (m *MsgChangeThoughtNameResponse) String() string { return proto.CompactTextString(m) } func (*MsgChangeThoughtNameResponse) ProtoMessage() {} func (*MsgChangeThoughtNameResponse) Descriptor() ([]byte, []int) { return fileDescriptor_4770788ccd571dd4, []int{12} } func (m *MsgChangeThoughtNameResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgChangeThoughtNameResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgChangeThoughtNameResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgChangeThoughtNameResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgChangeThoughtNameResponse.Merge(m, src) } func (m *MsgChangeThoughtNameResponse) XXX_Size() int { return m.Size() } func (m *MsgChangeThoughtNameResponse) XXX_DiscardUnknown() { xxx_messageInfo_MsgChangeThoughtNameResponse.DiscardUnknown(m) } var xxx_messageInfo_MsgChangeThoughtNameResponse proto.InternalMessageInfo type MsgChangeThoughtInputResponse struct{} func (m *MsgChangeThoughtInputResponse) Reset() { *m = MsgChangeThoughtInputResponse{} } func (m *MsgChangeThoughtInputResponse) String() string { return proto.CompactTextString(m) } func (*MsgChangeThoughtInputResponse) ProtoMessage() {} func (*MsgChangeThoughtInputResponse) Descriptor() ([]byte, []int) { return fileDescriptor_4770788ccd571dd4, []int{13} } func (m *MsgChangeThoughtInputResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgChangeThoughtInputResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgChangeThoughtInputResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgChangeThoughtInputResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgChangeThoughtInputResponse.Merge(m, src) } func (m *MsgChangeThoughtInputResponse) XXX_Size() int { return m.Size() } func (m *MsgChangeThoughtInputResponse) XXX_DiscardUnknown() { xxx_messageInfo_MsgChangeThoughtInputResponse.DiscardUnknown(m) } var xxx_messageInfo_MsgChangeThoughtInputResponse proto.InternalMessageInfo type MsgChangeThoughtGasPriceResponse struct{} func (m *MsgChangeThoughtGasPriceResponse) Reset() { *m = MsgChangeThoughtGasPriceResponse{} } func (m *MsgChangeThoughtGasPriceResponse) String() string { return proto.CompactTextString(m) } func (*MsgChangeThoughtGasPriceResponse) ProtoMessage() {} func (*MsgChangeThoughtGasPriceResponse) Descriptor() ([]byte, []int) { return fileDescriptor_4770788ccd571dd4, []int{14} } func (m *MsgChangeThoughtGasPriceResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgChangeThoughtGasPriceResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgChangeThoughtGasPriceResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgChangeThoughtGasPriceResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgChangeThoughtGasPriceResponse.Merge(m, src) } func (m *MsgChangeThoughtGasPriceResponse) XXX_Size() int { return m.Size() } func (m *MsgChangeThoughtGasPriceResponse) XXX_DiscardUnknown() { xxx_messageInfo_MsgChangeThoughtGasPriceResponse.DiscardUnknown(m) } var xxx_messageInfo_MsgChangeThoughtGasPriceResponse proto.InternalMessageInfo type MsgChangeThoughtPeriodResponse struct{} func (m *MsgChangeThoughtPeriodResponse) Reset() { *m = MsgChangeThoughtPeriodResponse{} } func (m *MsgChangeThoughtPeriodResponse) String() string { return proto.CompactTextString(m) } func (*MsgChangeThoughtPeriodResponse) ProtoMessage() {} func (*MsgChangeThoughtPeriodResponse) Descriptor() ([]byte, []int) { return fileDescriptor_4770788ccd571dd4, []int{15} } func (m *MsgChangeThoughtPeriodResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgChangeThoughtPeriodResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgChangeThoughtPeriodResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgChangeThoughtPeriodResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgChangeThoughtPeriodResponse.Merge(m, src) } func (m *MsgChangeThoughtPeriodResponse) XXX_Size() int { return m.Size() } func (m *MsgChangeThoughtPeriodResponse) XXX_DiscardUnknown() { xxx_messageInfo_MsgChangeThoughtPeriodResponse.DiscardUnknown(m) } var xxx_messageInfo_MsgChangeThoughtPeriodResponse proto.InternalMessageInfo type MsgChangeThoughtBlockResponse struct{} func (m *MsgChangeThoughtBlockResponse) Reset() { *m = MsgChangeThoughtBlockResponse{} } func (m *MsgChangeThoughtBlockResponse) String() string { return proto.CompactTextString(m) } func (*MsgChangeThoughtBlockResponse) ProtoMessage() {} func (*MsgChangeThoughtBlockResponse) Descriptor() ([]byte, []int) { return fileDescriptor_4770788ccd571dd4, []int{16} } func (m *MsgChangeThoughtBlockResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgChangeThoughtBlockResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgChangeThoughtBlockResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgChangeThoughtBlockResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgChangeThoughtBlockResponse.Merge(m, src) } func (m *MsgChangeThoughtBlockResponse) XXX_Size() int { return m.Size() } func (m *MsgChangeThoughtBlockResponse) XXX_DiscardUnknown() { xxx_messageInfo_MsgChangeThoughtBlockResponse.DiscardUnknown(m) } var xxx_messageInfo_MsgChangeThoughtBlockResponse proto.InternalMessageInfo type MsgUpdateParamsResponse struct{} func (m *MsgUpdateParamsResponse) Reset() { *m = MsgUpdateParamsResponse{} } func (m *MsgUpdateParamsResponse) String() string { return proto.CompactTextString(m) } func (*MsgUpdateParamsResponse) ProtoMessage() {} func (*MsgUpdateParamsResponse) Descriptor() ([]byte, []int) { return fileDescriptor_4770788ccd571dd4, []int{17} } func (m *MsgUpdateParamsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgUpdateParamsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgUpdateParamsResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgUpdateParamsResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgUpdateParamsResponse.Merge(m, src) } func (m *MsgUpdateParamsResponse) XXX_Size() int { return m.Size() } func (m *MsgUpdateParamsResponse) XXX_DiscardUnknown() { xxx_messageInfo_MsgUpdateParamsResponse.DiscardUnknown(m) } var xxx_messageInfo_MsgUpdateParamsResponse proto.InternalMessageInfo func init() { proto.RegisterType((*MsgCreateThought)(nil), "cyber.dmn.v1beta1.MsgCreateThought") proto.RegisterType((*MsgForgetThought)(nil), "cyber.dmn.v1beta1.MsgForgetThought") proto.RegisterType((*MsgChangeThoughtParticle)(nil), "cyber.dmn.v1beta1.MsgChangeThoughtParticle") proto.RegisterType((*MsgChangeThoughtName)(nil), "cyber.dmn.v1beta1.MsgChangeThoughtName") proto.RegisterType((*MsgChangeThoughtInput)(nil), "cyber.dmn.v1beta1.MsgChangeThoughtInput") proto.RegisterType((*MsgChangeThoughtGasPrice)(nil), "cyber.dmn.v1beta1.MsgChangeThoughtGasPrice") proto.RegisterType((*MsgChangeThoughtPeriod)(nil), "cyber.dmn.v1beta1.MsgChangeThoughtPeriod") proto.RegisterType((*MsgChangeThoughtBlock)(nil), "cyber.dmn.v1beta1.MsgChangeThoughtBlock") proto.RegisterType((*MsgUpdateParams)(nil), "cyber.dmn.v1beta1.MsgUpdateParams") proto.RegisterType((*MsgCreateThoughtResponse)(nil), "cyber.dmn.v1beta1.MsgCreateThoughtResponse") proto.RegisterType((*MsgForgetThoughtResponse)(nil), "cyber.dmn.v1beta1.MsgForgetThoughtResponse") proto.RegisterType((*MsgChangeThoughtParticleResponse)(nil), "cyber.dmn.v1beta1.MsgChangeThoughtParticleResponse") proto.RegisterType((*MsgChangeThoughtNameResponse)(nil), "cyber.dmn.v1beta1.MsgChangeThoughtNameResponse") proto.RegisterType((*MsgChangeThoughtInputResponse)(nil), "cyber.dmn.v1beta1.MsgChangeThoughtInputResponse") proto.RegisterType((*MsgChangeThoughtGasPriceResponse)(nil), "cyber.dmn.v1beta1.MsgChangeThoughtGasPriceResponse") proto.RegisterType((*MsgChangeThoughtPeriodResponse)(nil), "cyber.dmn.v1beta1.MsgChangeThoughtPeriodResponse") proto.RegisterType((*MsgChangeThoughtBlockResponse)(nil), "cyber.dmn.v1beta1.MsgChangeThoughtBlockResponse") proto.RegisterType((*MsgUpdateParamsResponse)(nil), "cyber.dmn.v1beta1.MsgUpdateParamsResponse") } func init() { proto.RegisterFile("cyber/dmn/v1beta1/tx.proto", fileDescriptor_4770788ccd571dd4) } var fileDescriptor_4770788ccd571dd4 = []byte{ // 802 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x94, 0x56, 0xcd, 0x4e, 0xdb, 0x4c, 0x14, 0x8d, 0x21, 0x10, 0xb8, 0xdf, 0x2f, 0xfe, 0x02, 0x38, 0xd6, 0x87, 0x89, 0xdc, 0x05, 0x94, 0x2a, 0x71, 0x03, 0x52, 0x2b, 0xb1, 0x6a, 0x83, 0x54, 0x54, 0xa9, 0x54, 0x28, 0xa5, 0x9b, 0x56, 0x02, 0x4d, 0xec, 0xd1, 0xc4, 0x02, 0x7b, 0x2c, 0x8f, 0x03, 0x64, 0xdb, 0x27, 0xa8, 0xfa, 0x24, 0xad, 0xd4, 0x87, 0x40, 0xea, 0x06, 0x75, 0xd5, 0x15, 0xaa, 0x60, 0x51, 0xf5, 0x15, 0xba, 0xaa, 0x66, 0x3c, 0x36, 0x24, 0x71, 0xc0, 0x59, 0x25, 0xe3, 0x7b, 0xee, 0x39, 0x33, 0x67, 0xee, 0xbd, 0x36, 0xe8, 0x76, 0xaf, 0x8d, 0x43, 0xcb, 0xf1, 0x7c, 0xeb, 0xb8, 0xd1, 0xc6, 0x11, 0x6a, 0x58, 0xd1, 0x69, 0x3d, 0x08, 0x69, 0x44, 0xd5, 0x39, 0x11, 0xab, 0x3b, 0x9e, 0x5f, 0x97, 0x31, 0xbd, 0x4c, 0x28, 0xa1, 0x22, 0x6a, 0xf1, 0x7f, 0x31, 0x50, 0x5f, 0xb4, 0x29, 0xf3, 0x28, 0xb3, 0x3c, 0x46, 0xac, 0xe3, 0x06, 0xff, 0x91, 0x81, 0x4a, 0x1c, 0x38, 0x88, 0x33, 0xe2, 0x85, 0x0c, 0x2d, 0x65, 0x08, 0xf7, 0x02, 0x9c, 0x84, 0x0d, 0x49, 0xd9, 0x46, 0x0c, 0xa7, 0x00, 0x9b, 0xba, 0x7e, 0x1c, 0x37, 0xbf, 0x28, 0xf0, 0xef, 0x0e, 0x23, 0x5b, 0x21, 0x46, 0x11, 0xde, 0xeb, 0xd0, 0x2e, 0xe9, 0x44, 0xaa, 0x06, 0xa5, 0x20, 0xa4, 0x24, 0x44, 0x9e, 0xa6, 0x54, 0x95, 0xd5, 0xd9, 0x56, 0xb2, 0x54, 0x37, 0xa1, 0x14, 0x85, 0x2e, 0x21, 0x38, 0xd4, 0x26, 0xaa, 0xca, 0xea, 0x1f, 0xeb, 0x7a, 0x7d, 0xe8, 0x70, 0xf5, 0xbd, 0x18, 0xd1, 0x2c, 0x9e, 0x5d, 0x2c, 0x17, 0x5a, 0x49, 0x82, 0xda, 0x80, 0xe2, 0x11, 0x45, 0x8e, 0x36, 0x29, 0x12, 0x17, 0x33, 0x12, 0x5f, 0x50, 0xe4, 0xc8, 0x2c, 0x01, 0x55, 0x55, 0x28, 0xfa, 0xc8, 0xc3, 0x5a, 0x51, 0xec, 0x42, 0xfc, 0x57, 0x75, 0x98, 0x09, 0x50, 0x18, 0xb9, 0xf6, 0x11, 0xd6, 0xa6, 0xc4, 0xf3, 0x74, 0x6d, 0x3e, 0x11, 0x87, 0x79, 0x46, 0x43, 0x82, 0xa3, 0xbb, 0x0f, 0x93, 0xb0, 0x4f, 0x5c, 0xb3, 0x9b, 0x0e, 0x68, 0xdc, 0x8e, 0x0e, 0xf2, 0x49, 0x62, 0xc7, 0xae, 0x64, 0x1f, 0x8f, 0xa9, 0x6f, 0x9f, 0x93, 0x03, 0xfb, 0x3c, 0x80, 0xf2, 0xa0, 0xca, 0x4b, 0x9e, 0x33, 0x9e, 0x42, 0x05, 0x66, 0x7c, 0x7c, 0x72, 0x20, 0x9e, 0xc7, 0x0a, 0x25, 0x1f, 0x9f, 0x70, 0x22, 0xf3, 0x2d, 0xcc, 0x0f, 0x0a, 0x3c, 0xf7, 0x83, 0xee, 0x98, 0x6e, 0xa8, 0x65, 0x98, 0x72, 0x79, 0x9a, 0xa4, 0x8f, 0x17, 0xe6, 0x27, 0x65, 0xd8, 0xa4, 0x6d, 0xc4, 0x76, 0x43, 0xd7, 0x1e, 0xf7, 0x08, 0x04, 0x66, 0x09, 0xe2, 0x75, 0xed, 0xda, 0x58, 0x16, 0x46, 0xa5, 0x2e, 0xeb, 0x9b, 0x97, 0x6c, 0x5a, 0x1a, 0x5b, 0xd4, 0xf5, 0x9b, 0x16, 0x2f, 0x8d, 0x5f, 0x17, 0xcb, 0x2b, 0xc4, 0x8d, 0x3a, 0xdd, 0x76, 0xdd, 0xa6, 0x9e, 0x6c, 0x06, 0xf9, 0x53, 0x63, 0xce, 0xa1, 0x2c, 0x7f, 0x9e, 0xd0, 0x9a, 0x21, 0x72, 0x5b, 0xe6, 0x3e, 0x2c, 0x0c, 0xdd, 0x2b, 0x0e, 0x5d, 0xea, 0x8c, 0xb9, 0xe1, 0x05, 0x98, 0x0e, 0x44, 0x9e, 0xd8, 0x6d, 0xb1, 0x25, 0x57, 0x59, 0x86, 0x37, 0x8f, 0xa8, 0x7d, 0x38, 0xbe, 0xe1, 0x6d, 0x9e, 0x26, 0xd9, 0xe3, 0x85, 0xf9, 0x41, 0x81, 0x7f, 0x76, 0x18, 0x79, 0x1d, 0x38, 0x28, 0xc2, 0xbb, 0x28, 0x44, 0x1e, 0x53, 0x1f, 0xc1, 0x2c, 0xea, 0x46, 0x1d, 0x1a, 0xba, 0x51, 0x2f, 0x66, 0x6e, 0x6a, 0x5f, 0x3f, 0xd7, 0xca, 0xd2, 0xbc, 0xa7, 0x8e, 0x13, 0x62, 0xc6, 0x5e, 0x45, 0xa1, 0xeb, 0x93, 0xd6, 0x35, 0x54, 0x7d, 0x0c, 0xd3, 0x81, 0x60, 0x90, 0x0d, 0x5c, 0xc9, 0xe8, 0xc3, 0x58, 0x42, 0x76, 0xa2, 0x84, 0x6f, 0xfe, 0xfd, 0xee, 0xc7, 0xc7, 0xb5, 0x6b, 0x22, 0x53, 0x8f, 0x8b, 0xe0, 0xe6, 0xe0, 0x68, 0x61, 0x16, 0x50, 0x9f, 0x61, 0x19, 0xeb, 0xeb, 0xc3, 0x34, 0x66, 0x42, 0x75, 0x54, 0x87, 0xa5, 0x18, 0x03, 0xfe, 0xcf, 0xea, 0x8f, 0x34, 0xbe, 0x0c, 0x4b, 0x99, 0xe5, 0x7d, 0x9b, 0x48, 0x52, 0xa1, 0x29, 0xa6, 0x0a, 0x46, 0x76, 0x49, 0xdc, 0x26, 0x23, 0x2e, 0x35, 0x05, 0x54, 0x60, 0x71, 0xe0, 0x5e, 0x92, 0xd0, 0xfa, 0xcf, 0x12, 0x4c, 0xee, 0x30, 0xa2, 0x22, 0xf8, 0xab, 0x7f, 0xb8, 0xde, 0xcb, 0x30, 0x7c, 0xd0, 0x48, 0xfd, 0x41, 0x0e, 0x50, 0x22, 0xc5, 0x25, 0xfa, 0x47, 0xde, 0x08, 0x89, 0x3e, 0xd0, 0x28, 0x89, 0xcc, 0x4b, 0x53, 0x7b, 0x30, 0x9f, 0x3d, 0x13, 0x47, 0x6d, 0x34, 0x0b, 0xac, 0x6f, 0x8c, 0x01, 0x4e, 0xa5, 0x3d, 0x98, 0x1b, 0x1e, 0x94, 0x2b, 0x39, 0x98, 0x38, 0x50, 0xb7, 0x72, 0x02, 0x53, 0xb9, 0x00, 0xd4, 0x8c, 0xb1, 0xb9, 0x9a, 0x83, 0x46, 0x20, 0xf5, 0x87, 0x79, 0x91, 0x23, 0xbd, 0x4d, 0x47, 0x69, 0x1e, 0x6f, 0x13, 0x70, 0x2e, 0x6f, 0x07, 0x5b, 0x40, 0x65, 0xf0, 0x5f, 0xd6, 0x48, 0xbc, 0x9f, 0xe7, 0x9e, 0x04, 0x54, 0x6f, 0xe4, 0x86, 0x8e, 0x74, 0x38, 0x9e, 0x93, 0x79, 0x1c, 0x16, 0xc8, 0x5c, 0x0e, 0xf7, 0xb5, 0xa9, 0xba, 0x0f, 0x7f, 0xf6, 0xcd, 0x4e, 0x33, 0x9b, 0xe1, 0x26, 0x46, 0x5f, 0xbb, 0x1b, 0x93, 0xf0, 0x37, 0xb7, 0xcf, 0x2e, 0x0d, 0xe5, 0xfc, 0xd2, 0x50, 0xbe, 0x5f, 0x1a, 0xca, 0xfb, 0x2b, 0xa3, 0x70, 0x7e, 0x65, 0x14, 0xbe, 0x5d, 0x19, 0x85, 0x37, 0xb5, 0x9b, 0x6f, 0x2a, 0xce, 0x67, 0x53, 0x9f, 0xf0, 0xc1, 0x6c, 0x11, 0x5a, 0x8b, 0xbf, 0xdc, 0x4e, 0xc5, 0xb7, 0x9b, 0x78, 0x69, 0xb5, 0xa7, 0xc5, 0x47, 0xd9, 0xc6, 0xef, 0x00, 0x00, 0x00, 0xff, 0xff, 0xfa, 0xd9, 0x80, 0x0a, 0x4e, 0x0a, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. var ( _ context.Context _ grpc.ClientConn ) // This is a compile-time assertion to ensure that this generated file // is compatible with the grpc package it is being compiled against. const _ = grpc.SupportPackageIsVersion4 // MsgClient is the client API for Msg service. // // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. type MsgClient interface { CreateThought(ctx context.Context, in *MsgCreateThought, opts ...grpc.CallOption) (*MsgCreateThoughtResponse, error) ForgetThought(ctx context.Context, in *MsgForgetThought, opts ...grpc.CallOption) (*MsgForgetThoughtResponse, error) ChangeThoughtParticle(ctx context.Context, in *MsgChangeThoughtParticle, opts ...grpc.CallOption) (*MsgChangeThoughtParticleResponse, error) ChangeThoughtName(ctx context.Context, in *MsgChangeThoughtName, opts ...grpc.CallOption) (*MsgChangeThoughtNameResponse, error) ChangeThoughtInput(ctx context.Context, in *MsgChangeThoughtInput, opts ...grpc.CallOption) (*MsgChangeThoughtInputResponse, error) ChangeThoughtGasPrice(ctx context.Context, in *MsgChangeThoughtGasPrice, opts ...grpc.CallOption) (*MsgChangeThoughtGasPriceResponse, error) ChangeThoughtPeriod(ctx context.Context, in *MsgChangeThoughtPeriod, opts ...grpc.CallOption) (*MsgChangeThoughtPeriodResponse, error) ChangeThoughtBlock(ctx context.Context, in *MsgChangeThoughtBlock, opts ...grpc.CallOption) (*MsgChangeThoughtBlockResponse, error) UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) } type msgClient struct { cc grpc1.ClientConn } func NewMsgClient(cc grpc1.ClientConn) MsgClient { return &msgClient{cc} } func (c *msgClient) CreateThought(ctx context.Context, in *MsgCreateThought, opts ...grpc.CallOption) (*MsgCreateThoughtResponse, error) { out := new(MsgCreateThoughtResponse) err := c.cc.Invoke(ctx, "/cyber.dmn.v1beta1.Msg/CreateThought", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *msgClient) ForgetThought(ctx context.Context, in *MsgForgetThought, opts ...grpc.CallOption) (*MsgForgetThoughtResponse, error) { out := new(MsgForgetThoughtResponse) err := c.cc.Invoke(ctx, "/cyber.dmn.v1beta1.Msg/ForgetThought", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *msgClient) ChangeThoughtParticle(ctx context.Context, in *MsgChangeThoughtParticle, opts ...grpc.CallOption) (*MsgChangeThoughtParticleResponse, error) { out := new(MsgChangeThoughtParticleResponse) err := c.cc.Invoke(ctx, "/cyber.dmn.v1beta1.Msg/ChangeThoughtParticle", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *msgClient) ChangeThoughtName(ctx context.Context, in *MsgChangeThoughtName, opts ...grpc.CallOption) (*MsgChangeThoughtNameResponse, error) { out := new(MsgChangeThoughtNameResponse) err := c.cc.Invoke(ctx, "/cyber.dmn.v1beta1.Msg/ChangeThoughtName", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *msgClient) ChangeThoughtInput(ctx context.Context, in *MsgChangeThoughtInput, opts ...grpc.CallOption) (*MsgChangeThoughtInputResponse, error) { out := new(MsgChangeThoughtInputResponse) err := c.cc.Invoke(ctx, "/cyber.dmn.v1beta1.Msg/ChangeThoughtInput", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *msgClient) ChangeThoughtGasPrice(ctx context.Context, in *MsgChangeThoughtGasPrice, opts ...grpc.CallOption) (*MsgChangeThoughtGasPriceResponse, error) { out := new(MsgChangeThoughtGasPriceResponse) err := c.cc.Invoke(ctx, "/cyber.dmn.v1beta1.Msg/ChangeThoughtGasPrice", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *msgClient) ChangeThoughtPeriod(ctx context.Context, in *MsgChangeThoughtPeriod, opts ...grpc.CallOption) (*MsgChangeThoughtPeriodResponse, error) { out := new(MsgChangeThoughtPeriodResponse) err := c.cc.Invoke(ctx, "/cyber.dmn.v1beta1.Msg/ChangeThoughtPeriod", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *msgClient) ChangeThoughtBlock(ctx context.Context, in *MsgChangeThoughtBlock, opts ...grpc.CallOption) (*MsgChangeThoughtBlockResponse, error) { out := new(MsgChangeThoughtBlockResponse) err := c.cc.Invoke(ctx, "/cyber.dmn.v1beta1.Msg/ChangeThoughtBlock", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *msgClient) UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) { out := new(MsgUpdateParamsResponse) err := c.cc.Invoke(ctx, "/cyber.dmn.v1beta1.Msg/UpdateParams", in, out, opts...) if err != nil { return nil, err } return out, nil } // MsgServer is the server API for Msg service. type MsgServer interface { CreateThought(context.Context, *MsgCreateThought) (*MsgCreateThoughtResponse, error) ForgetThought(context.Context, *MsgForgetThought) (*MsgForgetThoughtResponse, error) ChangeThoughtParticle(context.Context, *MsgChangeThoughtParticle) (*MsgChangeThoughtParticleResponse, error) ChangeThoughtName(context.Context, *MsgChangeThoughtName) (*MsgChangeThoughtNameResponse, error) ChangeThoughtInput(context.Context, *MsgChangeThoughtInput) (*MsgChangeThoughtInputResponse, error) ChangeThoughtGasPrice(context.Context, *MsgChangeThoughtGasPrice) (*MsgChangeThoughtGasPriceResponse, error) ChangeThoughtPeriod(context.Context, *MsgChangeThoughtPeriod) (*MsgChangeThoughtPeriodResponse, error) ChangeThoughtBlock(context.Context, *MsgChangeThoughtBlock) (*MsgChangeThoughtBlockResponse, error) UpdateParams(context.Context, *MsgUpdateParams) (*MsgUpdateParamsResponse, error) } // UnimplementedMsgServer can be embedded to have forward compatible implementations. type UnimplementedMsgServer struct{} func (*UnimplementedMsgServer) CreateThought(ctx context.Context, req *MsgCreateThought) (*MsgCreateThoughtResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method CreateThought not implemented") } func (*UnimplementedMsgServer) ForgetThought(ctx context.Context, req *MsgForgetThought) (*MsgForgetThoughtResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method ForgetThought not implemented") } func (*UnimplementedMsgServer) ChangeThoughtParticle(ctx context.Context, req *MsgChangeThoughtParticle) (*MsgChangeThoughtParticleResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method ChangeThoughtParticle not implemented") } func (*UnimplementedMsgServer) ChangeThoughtName(ctx context.Context, req *MsgChangeThoughtName) (*MsgChangeThoughtNameResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method ChangeThoughtName not implemented") } func (*UnimplementedMsgServer) ChangeThoughtInput(ctx context.Context, req *MsgChangeThoughtInput) (*MsgChangeThoughtInputResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method ChangeThoughtInput not implemented") } func (*UnimplementedMsgServer) ChangeThoughtGasPrice(ctx context.Context, req *MsgChangeThoughtGasPrice) (*MsgChangeThoughtGasPriceResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method ChangeThoughtGasPrice not implemented") } func (*UnimplementedMsgServer) ChangeThoughtPeriod(ctx context.Context, req *MsgChangeThoughtPeriod) (*MsgChangeThoughtPeriodResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method ChangeThoughtPeriod not implemented") } func (*UnimplementedMsgServer) ChangeThoughtBlock(ctx context.Context, req *MsgChangeThoughtBlock) (*MsgChangeThoughtBlockResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method ChangeThoughtBlock not implemented") } func (*UnimplementedMsgServer) UpdateParams(ctx context.Context, req *MsgUpdateParams) (*MsgUpdateParamsResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method UpdateParams not implemented") } func RegisterMsgServer(s grpc1.Server, srv MsgServer) { s.RegisterService(&_Msg_serviceDesc, srv) } func _Msg_CreateThought_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgCreateThought) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(MsgServer).CreateThought(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.dmn.v1beta1.Msg/CreateThought", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).CreateThought(ctx, req.(*MsgCreateThought)) } return interceptor(ctx, in, info, handler) } func _Msg_ForgetThought_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgForgetThought) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(MsgServer).ForgetThought(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.dmn.v1beta1.Msg/ForgetThought", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).ForgetThought(ctx, req.(*MsgForgetThought)) } return interceptor(ctx, in, info, handler) } func _Msg_ChangeThoughtParticle_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgChangeThoughtParticle) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(MsgServer).ChangeThoughtParticle(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.dmn.v1beta1.Msg/ChangeThoughtParticle", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).ChangeThoughtParticle(ctx, req.(*MsgChangeThoughtParticle)) } return interceptor(ctx, in, info, handler) } func _Msg_ChangeThoughtName_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgChangeThoughtName) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(MsgServer).ChangeThoughtName(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.dmn.v1beta1.Msg/ChangeThoughtName", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).ChangeThoughtName(ctx, req.(*MsgChangeThoughtName)) } return interceptor(ctx, in, info, handler) } func _Msg_ChangeThoughtInput_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgChangeThoughtInput) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(MsgServer).ChangeThoughtInput(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.dmn.v1beta1.Msg/ChangeThoughtInput", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).ChangeThoughtInput(ctx, req.(*MsgChangeThoughtInput)) } return interceptor(ctx, in, info, handler) } func _Msg_ChangeThoughtGasPrice_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgChangeThoughtGasPrice) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(MsgServer).ChangeThoughtGasPrice(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.dmn.v1beta1.Msg/ChangeThoughtGasPrice", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).ChangeThoughtGasPrice(ctx, req.(*MsgChangeThoughtGasPrice)) } return interceptor(ctx, in, info, handler) } func _Msg_ChangeThoughtPeriod_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgChangeThoughtPeriod) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(MsgServer).ChangeThoughtPeriod(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.dmn.v1beta1.Msg/ChangeThoughtPeriod", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).ChangeThoughtPeriod(ctx, req.(*MsgChangeThoughtPeriod)) } return interceptor(ctx, in, info, handler) } func _Msg_ChangeThoughtBlock_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgChangeThoughtBlock) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(MsgServer).ChangeThoughtBlock(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.dmn.v1beta1.Msg/ChangeThoughtBlock", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).ChangeThoughtBlock(ctx, req.(*MsgChangeThoughtBlock)) } return interceptor(ctx, in, info, handler) } func _Msg_UpdateParams_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgUpdateParams) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(MsgServer).UpdateParams(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.dmn.v1beta1.Msg/UpdateParams", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).UpdateParams(ctx, req.(*MsgUpdateParams)) } return interceptor(ctx, in, info, handler) } var _Msg_serviceDesc = grpc.ServiceDesc{ ServiceName: "cyber.dmn.v1beta1.Msg", HandlerType: (*MsgServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "CreateThought", Handler: _Msg_CreateThought_Handler, }, { MethodName: "ForgetThought", Handler: _Msg_ForgetThought_Handler, }, { MethodName: "ChangeThoughtParticle", Handler: _Msg_ChangeThoughtParticle_Handler, }, { MethodName: "ChangeThoughtName", Handler: _Msg_ChangeThoughtName_Handler, }, { MethodName: "ChangeThoughtInput", Handler: _Msg_ChangeThoughtInput_Handler, }, { MethodName: "ChangeThoughtGasPrice", Handler: _Msg_ChangeThoughtGasPrice_Handler, }, { MethodName: "ChangeThoughtPeriod", Handler: _Msg_ChangeThoughtPeriod_Handler, }, { MethodName: "ChangeThoughtBlock", Handler: _Msg_ChangeThoughtBlock_Handler, }, { MethodName: "UpdateParams", Handler: _Msg_UpdateParams_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "cyber/dmn/v1beta1/tx.proto", } func (m *MsgCreateThought) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgCreateThought) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgCreateThought) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.Particle) > 0 { i -= len(m.Particle) copy(dAtA[i:], m.Particle) i = encodeVarintTx(dAtA, i, uint64(len(m.Particle))) i-- dAtA[i] = 0x2a } if len(m.Name) > 0 { i -= len(m.Name) copy(dAtA[i:], m.Name) i = encodeVarintTx(dAtA, i, uint64(len(m.Name))) i-- dAtA[i] = 0x22 } { size, err := m.Load.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintTx(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x1a { size, err := m.Trigger.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintTx(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 if len(m.Program) > 0 { i -= len(m.Program) copy(dAtA[i:], m.Program) i = encodeVarintTx(dAtA, i, uint64(len(m.Program))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *MsgForgetThought) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgForgetThought) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgForgetThought) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.Name) > 0 { i -= len(m.Name) copy(dAtA[i:], m.Name) i = encodeVarintTx(dAtA, i, uint64(len(m.Name))) i-- dAtA[i] = 0x12 } if len(m.Program) > 0 { i -= len(m.Program) copy(dAtA[i:], m.Program) i = encodeVarintTx(dAtA, i, uint64(len(m.Program))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *MsgChangeThoughtParticle) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgChangeThoughtParticle) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgChangeThoughtParticle) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.Particle) > 0 { i -= len(m.Particle) copy(dAtA[i:], m.Particle) i = encodeVarintTx(dAtA, i, uint64(len(m.Particle))) i-- dAtA[i] = 0x1a } if len(m.Name) > 0 { i -= len(m.Name) copy(dAtA[i:], m.Name) i = encodeVarintTx(dAtA, i, uint64(len(m.Name))) i-- dAtA[i] = 0x12 } if len(m.Program) > 0 { i -= len(m.Program) copy(dAtA[i:], m.Program) i = encodeVarintTx(dAtA, i, uint64(len(m.Program))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *MsgChangeThoughtName) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgChangeThoughtName) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgChangeThoughtName) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.NewName) > 0 { i -= len(m.NewName) copy(dAtA[i:], m.NewName) i = encodeVarintTx(dAtA, i, uint64(len(m.NewName))) i-- dAtA[i] = 0x1a } if len(m.Name) > 0 { i -= len(m.Name) copy(dAtA[i:], m.Name) i = encodeVarintTx(dAtA, i, uint64(len(m.Name))) i-- dAtA[i] = 0x12 } if len(m.Program) > 0 { i -= len(m.Program) copy(dAtA[i:], m.Program) i = encodeVarintTx(dAtA, i, uint64(len(m.Program))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *MsgChangeThoughtInput) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgChangeThoughtInput) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgChangeThoughtInput) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.Input) > 0 { i -= len(m.Input) copy(dAtA[i:], m.Input) i = encodeVarintTx(dAtA, i, uint64(len(m.Input))) i-- dAtA[i] = 0x1a } if len(m.Name) > 0 { i -= len(m.Name) copy(dAtA[i:], m.Name) i = encodeVarintTx(dAtA, i, uint64(len(m.Name))) i-- dAtA[i] = 0x12 } if len(m.Program) > 0 { i -= len(m.Program) copy(dAtA[i:], m.Program) i = encodeVarintTx(dAtA, i, uint64(len(m.Program))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *MsgChangeThoughtGasPrice) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgChangeThoughtGasPrice) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgChangeThoughtGasPrice) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.GasPrice.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintTx(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x1a if len(m.Name) > 0 { i -= len(m.Name) copy(dAtA[i:], m.Name) i = encodeVarintTx(dAtA, i, uint64(len(m.Name))) i-- dAtA[i] = 0x12 } if len(m.Program) > 0 { i -= len(m.Program) copy(dAtA[i:], m.Program) i = encodeVarintTx(dAtA, i, uint64(len(m.Program))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *MsgChangeThoughtPeriod) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgChangeThoughtPeriod) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgChangeThoughtPeriod) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.Period != 0 { i = encodeVarintTx(dAtA, i, uint64(m.Period)) i-- dAtA[i] = 0x18 } if len(m.Name) > 0 { i -= len(m.Name) copy(dAtA[i:], m.Name) i = encodeVarintTx(dAtA, i, uint64(len(m.Name))) i-- dAtA[i] = 0x12 } if len(m.Program) > 0 { i -= len(m.Program) copy(dAtA[i:], m.Program) i = encodeVarintTx(dAtA, i, uint64(len(m.Program))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *MsgChangeThoughtBlock) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgChangeThoughtBlock) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgChangeThoughtBlock) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.Block != 0 { i = encodeVarintTx(dAtA, i, uint64(m.Block)) i-- dAtA[i] = 0x18 } if len(m.Name) > 0 { i -= len(m.Name) copy(dAtA[i:], m.Name) i = encodeVarintTx(dAtA, i, uint64(len(m.Name))) i-- dAtA[i] = 0x12 } if len(m.Program) > 0 { i -= len(m.Program) copy(dAtA[i:], m.Program) i = encodeVarintTx(dAtA, i, uint64(len(m.Program))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *MsgUpdateParams) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgUpdateParams) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgUpdateParams) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.Params.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintTx(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 if len(m.Authority) > 0 { i -= len(m.Authority) copy(dAtA[i:], m.Authority) i = encodeVarintTx(dAtA, i, uint64(len(m.Authority))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *MsgCreateThoughtResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgCreateThoughtResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgCreateThoughtResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *MsgForgetThoughtResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgForgetThoughtResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgForgetThoughtResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *MsgChangeThoughtParticleResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgChangeThoughtParticleResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgChangeThoughtParticleResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *MsgChangeThoughtNameResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgChangeThoughtNameResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgChangeThoughtNameResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *MsgChangeThoughtInputResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgChangeThoughtInputResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgChangeThoughtInputResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *MsgChangeThoughtGasPriceResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgChangeThoughtGasPriceResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgChangeThoughtGasPriceResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *MsgChangeThoughtPeriodResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgChangeThoughtPeriodResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgChangeThoughtPeriodResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *MsgChangeThoughtBlockResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgChangeThoughtBlockResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgChangeThoughtBlockResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *MsgUpdateParamsResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgUpdateParamsResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgUpdateParamsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func encodeVarintTx(dAtA []byte, offset int, v uint64) int { offset -= sovTx(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *MsgCreateThought) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Program) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = m.Trigger.Size() n += 1 + l + sovTx(uint64(l)) l = m.Load.Size() n += 1 + l + sovTx(uint64(l)) l = len(m.Name) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = len(m.Particle) if l > 0 { n += 1 + l + sovTx(uint64(l)) } return n } func (m *MsgForgetThought) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Program) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = len(m.Name) if l > 0 { n += 1 + l + sovTx(uint64(l)) } return n } func (m *MsgChangeThoughtParticle) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Program) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = len(m.Name) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = len(m.Particle) if l > 0 { n += 1 + l + sovTx(uint64(l)) } return n } func (m *MsgChangeThoughtName) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Program) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = len(m.Name) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = len(m.NewName) if l > 0 { n += 1 + l + sovTx(uint64(l)) } return n } func (m *MsgChangeThoughtInput) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Program) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = len(m.Name) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = len(m.Input) if l > 0 { n += 1 + l + sovTx(uint64(l)) } return n } func (m *MsgChangeThoughtGasPrice) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Program) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = len(m.Name) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = m.GasPrice.Size() n += 1 + l + sovTx(uint64(l)) return n } func (m *MsgChangeThoughtPeriod) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Program) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = len(m.Name) if l > 0 { n += 1 + l + sovTx(uint64(l)) } if m.Period != 0 { n += 1 + sovTx(uint64(m.Period)) } return n } func (m *MsgChangeThoughtBlock) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Program) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = len(m.Name) if l > 0 { n += 1 + l + sovTx(uint64(l)) } if m.Block != 0 { n += 1 + sovTx(uint64(m.Block)) } return n } func (m *MsgUpdateParams) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Authority) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = m.Params.Size() n += 1 + l + sovTx(uint64(l)) return n } func (m *MsgCreateThoughtResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *MsgForgetThoughtResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *MsgChangeThoughtParticleResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *MsgChangeThoughtNameResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *MsgChangeThoughtInputResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *MsgChangeThoughtGasPriceResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *MsgChangeThoughtPeriodResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *MsgChangeThoughtBlockResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *MsgUpdateParamsResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func sovTx(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozTx(x uint64) (n int) { return sovTx(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *MsgCreateThought) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgCreateThought: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgCreateThought: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Program", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Program = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Trigger", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Trigger.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 3: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Load", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Load.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 4: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 5: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Particle", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Particle = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgForgetThought) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgForgetThought: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgForgetThought: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Program", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Program = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgChangeThoughtParticle) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgChangeThoughtParticle: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgChangeThoughtParticle: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Program", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Program = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Particle", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Particle = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgChangeThoughtName) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgChangeThoughtName: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgChangeThoughtName: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Program", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Program = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field NewName", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.NewName = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgChangeThoughtInput) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgChangeThoughtInput: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgChangeThoughtInput: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Program", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Program = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Input", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Input = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgChangeThoughtGasPrice) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgChangeThoughtGasPrice: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgChangeThoughtGasPrice: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Program", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Program = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field GasPrice", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.GasPrice.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgChangeThoughtPeriod) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgChangeThoughtPeriod: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgChangeThoughtPeriod: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Program", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Program = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field Period", wireType) } m.Period = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.Period |= uint64(b&0x7F) << shift if b < 0x80 { break } } default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgChangeThoughtBlock) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgChangeThoughtBlock: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgChangeThoughtBlock: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Program", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Program = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field Block", wireType) } m.Block = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.Block |= uint64(b&0x7F) << shift if b < 0x80 { break } } default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgUpdateParams) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgUpdateParams: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgUpdateParams: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Authority", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Authority = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Params.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgCreateThoughtResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgCreateThoughtResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgCreateThoughtResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgForgetThoughtResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgForgetThoughtResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgForgetThoughtResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgChangeThoughtParticleResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgChangeThoughtParticleResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgChangeThoughtParticleResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgChangeThoughtNameResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgChangeThoughtNameResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgChangeThoughtNameResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgChangeThoughtInputResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgChangeThoughtInputResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgChangeThoughtInputResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgChangeThoughtGasPriceResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgChangeThoughtGasPriceResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgChangeThoughtGasPriceResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgChangeThoughtPeriodResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgChangeThoughtPeriodResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgChangeThoughtPeriodResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgChangeThoughtBlockResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgChangeThoughtBlockResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgChangeThoughtBlockResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgUpdateParamsResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgUpdateParamsResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgUpdateParamsResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipTx(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTx } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTx } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTx } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthTx } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupTx } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthTx } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthTx = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowTx = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupTx = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/dmn/types/types.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: cyber/dmn/v1beta1/types.proto package types import ( fmt "fmt" io "io" math "math" math_bits "math/bits" _ "github.com/cosmos/cosmos-sdk/types" github_com_cosmos_cosmos_sdk_types "github.com/cosmos/cosmos-sdk/types" _ "github.com/cosmos/gogoproto/gogoproto" proto "github.com/cosmos/gogoproto/proto" ) // Reference imports to suppress errors if they are not otherwise used. var ( _ = proto.Marshal _ = fmt.Errorf _ = math.Inf ) // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package type Params struct { MaxSlots uint32 `protobuf:"varint,1,opt,name=max_slots,json=maxSlots,proto3" json:"max_slots,omitempty"` MaxGas uint32 `protobuf:"varint,2,opt,name=max_gas,json=maxGas,proto3" json:"max_gas,omitempty"` FeeTtl uint32 `protobuf:"varint,3,opt,name=fee_ttl,json=feeTtl,proto3" json:"fee_ttl,omitempty"` } func (m *Params) Reset() { *m = Params{} } func (m *Params) String() string { return proto.CompactTextString(m) } func (*Params) ProtoMessage() {} func (*Params) Descriptor() ([]byte, []int) { return fileDescriptor_a414790454046b0b, []int{0} } func (m *Params) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *Params) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_Params.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *Params) XXX_Merge(src proto.Message) { xxx_messageInfo_Params.Merge(m, src) } func (m *Params) XXX_Size() int { return m.Size() } func (m *Params) XXX_DiscardUnknown() { xxx_messageInfo_Params.DiscardUnknown(m) } var xxx_messageInfo_Params proto.InternalMessageInfo func (m *Params) GetMaxSlots() uint32 { if m != nil { return m.MaxSlots } return 0 } func (m *Params) GetMaxGas() uint32 { if m != nil { return m.MaxGas } return 0 } func (m *Params) GetFeeTtl() uint32 { if m != nil { return m.FeeTtl } return 0 } type Thought struct { Program string `protobuf:"bytes,1,opt,name=program,proto3" json:"program,omitempty"` Trigger Trigger `protobuf:"bytes,2,opt,name=trigger,proto3" json:"trigger"` Load Load `protobuf:"bytes,3,opt,name=load,proto3" json:"load"` Name string `protobuf:"bytes,4,opt,name=name,proto3" json:"name,omitempty"` Particle string `protobuf:"bytes,5,opt,name=particle,proto3" json:"particle,omitempty"` } func (m *Thought) Reset() { *m = Thought{} } func (m *Thought) String() string { return proto.CompactTextString(m) } func (*Thought) ProtoMessage() {} func (*Thought) Descriptor() ([]byte, []int) { return fileDescriptor_a414790454046b0b, []int{1} } func (m *Thought) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *Thought) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_Thought.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *Thought) XXX_Merge(src proto.Message) { xxx_messageInfo_Thought.Merge(m, src) } func (m *Thought) XXX_Size() int { return m.Size() } func (m *Thought) XXX_DiscardUnknown() { xxx_messageInfo_Thought.DiscardUnknown(m) } var xxx_messageInfo_Thought proto.InternalMessageInfo type Trigger struct { Period uint64 `protobuf:"varint,1,opt,name=period,proto3" json:"period,omitempty"` Block uint64 `protobuf:"varint,2,opt,name=block,proto3" json:"block,omitempty"` } func (m *Trigger) Reset() { *m = Trigger{} } func (m *Trigger) String() string { return proto.CompactTextString(m) } func (*Trigger) ProtoMessage() {} func (*Trigger) Descriptor() ([]byte, []int) { return fileDescriptor_a414790454046b0b, []int{2} } func (m *Trigger) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *Trigger) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_Trigger.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *Trigger) XXX_Merge(src proto.Message) { xxx_messageInfo_Trigger.Merge(m, src) } func (m *Trigger) XXX_Size() int { return m.Size() } func (m *Trigger) XXX_DiscardUnknown() { xxx_messageInfo_Trigger.DiscardUnknown(m) } var xxx_messageInfo_Trigger proto.InternalMessageInfo type Load struct { Input string `protobuf:"bytes,1,opt,name=input,proto3" json:"input,omitempty"` GasPrice github_com_cosmos_cosmos_sdk_types.Coin `protobuf:"bytes,2,opt,name=gas_price,json=gasPrice,proto3,casttype=github.com/cosmos/cosmos-sdk/types.Coin" json:"gas_price"` } func (m *Load) Reset() { *m = Load{} } func (m *Load) String() string { return proto.CompactTextString(m) } func (*Load) ProtoMessage() {} func (*Load) Descriptor() ([]byte, []int) { return fileDescriptor_a414790454046b0b, []int{3} } func (m *Load) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *Load) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_Load.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *Load) XXX_Merge(src proto.Message) { xxx_messageInfo_Load.Merge(m, src) } func (m *Load) XXX_Size() int { return m.Size() } func (m *Load) XXX_DiscardUnknown() { xxx_messageInfo_Load.DiscardUnknown(m) } var xxx_messageInfo_Load proto.InternalMessageInfo type ThoughtStats struct { Program string `protobuf:"bytes,1,opt,name=program,proto3" json:"program,omitempty"` Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"` Calls uint64 `protobuf:"varint,3,opt,name=calls,proto3" json:"calls,omitempty"` Fees uint64 `protobuf:"varint,4,opt,name=fees,proto3" json:"fees,omitempty"` Gas uint64 `protobuf:"varint,5,opt,name=gas,proto3" json:"gas,omitempty"` LastBlock uint64 `protobuf:"varint,6,opt,name=last_block,json=lastBlock,proto3" json:"last_block,omitempty"` } func (m *ThoughtStats) Reset() { *m = ThoughtStats{} } func (m *ThoughtStats) String() string { return proto.CompactTextString(m) } func (*ThoughtStats) ProtoMessage() {} func (*ThoughtStats) Descriptor() ([]byte, []int) { return fileDescriptor_a414790454046b0b, []int{4} } func (m *ThoughtStats) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *ThoughtStats) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_ThoughtStats.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *ThoughtStats) XXX_Merge(src proto.Message) { xxx_messageInfo_ThoughtStats.Merge(m, src) } func (m *ThoughtStats) XXX_Size() int { return m.Size() } func (m *ThoughtStats) XXX_DiscardUnknown() { xxx_messageInfo_ThoughtStats.DiscardUnknown(m) } var xxx_messageInfo_ThoughtStats proto.InternalMessageInfo func init() { proto.RegisterType((*Params)(nil), "cyber.dmn.v1beta1.Params") proto.RegisterType((*Thought)(nil), "cyber.dmn.v1beta1.Thought") proto.RegisterType((*Trigger)(nil), "cyber.dmn.v1beta1.Trigger") proto.RegisterType((*Load)(nil), "cyber.dmn.v1beta1.Load") proto.RegisterType((*ThoughtStats)(nil), "cyber.dmn.v1beta1.ThoughtStats") } func init() { proto.RegisterFile("cyber/dmn/v1beta1/types.proto", fileDescriptor_a414790454046b0b) } var fileDescriptor_a414790454046b0b = []byte{ // 531 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x7c, 0x53, 0xbd, 0x8e, 0xd3, 0x40, 0x10, 0xb6, 0xef, 0x9c, 0xbf, 0x3d, 0x90, 0x60, 0x15, 0x71, 0x26, 0xe8, 0x1c, 0x94, 0x06, 0x9a, 0xd8, 0xca, 0xd1, 0xa5, 0x23, 0x14, 0xd7, 0x50, 0x9c, 0x7c, 0xa9, 0x90, 0x50, 0xb4, 0xb6, 0x37, 0x1b, 0xeb, 0xbc, 0x5e, 0x6b, 0x77, 0x83, 0x72, 0x6f, 0x40, 0x07, 0x8f, 0x10, 0xde, 0xe6, 0x0a, 0x8a, 0x2b, 0xa9, 0x4e, 0x28, 0x69, 0xee, 0x19, 0xa8, 0xd0, 0xce, 0x3a, 0x51, 0x10, 0x88, 0xca, 0xf3, 0xed, 0x37, 0x33, 0x9e, 0xf9, 0xbe, 0x5d, 0x74, 0x96, 0xde, 0x24, 0x54, 0x46, 0x19, 0x2f, 0xa3, 0x4f, 0xa3, 0x84, 0x6a, 0x32, 0x8a, 0xf4, 0x4d, 0x45, 0x55, 0x58, 0x49, 0xa1, 0x05, 0x7e, 0x0a, 0x74, 0x98, 0xf1, 0x32, 0xac, 0xe9, 0x5e, 0x97, 0x09, 0x26, 0x80, 0x8d, 0x4c, 0x64, 0x13, 0x7b, 0x41, 0x2a, 0x14, 0x17, 0x2a, 0x4a, 0x88, 0xa2, 0xfb, 0x4e, 0xa9, 0xc8, 0x4b, 0xcb, 0x0f, 0x3e, 0xa2, 0xe6, 0x25, 0x91, 0x84, 0x2b, 0xfc, 0x02, 0x75, 0x38, 0x59, 0xcd, 0x54, 0x21, 0xb4, 0xf2, 0xdd, 0x97, 0xee, 0xeb, 0xc7, 0x71, 0x9b, 0x93, 0xd5, 0x95, 0xc1, 0xf8, 0x14, 0xb5, 0x0c, 0xc9, 0x88, 0xf2, 0x8f, 0x80, 0x6a, 0x72, 0xb2, 0xba, 0x20, 0x40, 0xcc, 0x29, 0x9d, 0x69, 0x5d, 0xf8, 0xc7, 0x96, 0x98, 0x53, 0x3a, 0xd5, 0xc5, 0xd8, 0x7b, 0x58, 0xf7, 0xdd, 0xc1, 0x77, 0x17, 0xb5, 0xa6, 0x0b, 0xb1, 0x64, 0x0b, 0x8d, 0x7d, 0xd4, 0xaa, 0xa4, 0x60, 0x92, 0x70, 0x68, 0xdf, 0x89, 0x77, 0x10, 0x8f, 0x51, 0x4b, 0xcb, 0x9c, 0x31, 0x2a, 0xa1, 0xfb, 0xc9, 0x79, 0x2f, 0xfc, 0x6b, 0xbf, 0x70, 0x6a, 0x33, 0x26, 0xde, 0xed, 0x7d, 0xdf, 0x89, 0x77, 0x05, 0x78, 0x84, 0xbc, 0x42, 0x90, 0x0c, 0xfe, 0x7e, 0x72, 0x7e, 0xfa, 0x8f, 0xc2, 0xf7, 0x82, 0x64, 0x75, 0x15, 0xa4, 0x62, 0x8c, 0xbc, 0x92, 0x70, 0xea, 0x7b, 0x30, 0x05, 0xc4, 0xb8, 0x87, 0xda, 0x15, 0x91, 0x3a, 0x4f, 0x0b, 0xea, 0x37, 0xe0, 0x7c, 0x8f, 0xc7, 0xed, 0xcf, 0xeb, 0xbe, 0xf3, 0xb0, 0xee, 0x3b, 0x83, 0xb7, 0xa8, 0x55, 0x8f, 0x81, 0x9f, 0xa1, 0x66, 0x45, 0x65, 0x2e, 0x32, 0x58, 0xc6, 0x8b, 0x6b, 0x84, 0xbb, 0xa8, 0x91, 0x14, 0x22, 0xbd, 0x86, 0x4d, 0xbc, 0xd8, 0x82, 0x83, 0x16, 0x5f, 0x5c, 0xe4, 0x99, 0x89, 0x4c, 0x62, 0x5e, 0x56, 0x4b, 0x5d, 0x8b, 0x61, 0x01, 0x66, 0xa8, 0xc3, 0x88, 0x9a, 0x55, 0x32, 0x4f, 0x69, 0x2d, 0xc6, 0xf3, 0xd0, 0x7a, 0x18, 0x1a, 0x0f, 0xf7, 0x5b, 0xbd, 0x13, 0x79, 0x39, 0x89, 0xcc, 0x56, 0xbf, 0xee, 0xfb, 0xaf, 0x58, 0xae, 0x17, 0xcb, 0x24, 0x4c, 0x05, 0x8f, 0x6a, 0xc3, 0xed, 0x67, 0xa8, 0xb2, 0xeb, 0xfa, 0xe2, 0x98, 0x82, 0xb8, 0xcd, 0x88, 0xba, 0x34, 0xbd, 0x0f, 0x26, 0xfa, 0xe6, 0xa2, 0x47, 0xb5, 0x47, 0x57, 0x9a, 0x68, 0xf5, 0x1f, 0xa3, 0x76, 0xca, 0x1d, 0x1d, 0x28, 0xd7, 0x45, 0x8d, 0x94, 0x14, 0x85, 0x02, 0x07, 0xbc, 0xd8, 0x02, 0x93, 0x39, 0xa7, 0x54, 0x81, 0xc6, 0x5e, 0x0c, 0x31, 0x7e, 0x82, 0x8e, 0xcd, 0x05, 0x6a, 0xc0, 0x91, 0x09, 0xf1, 0x19, 0x42, 0x05, 0x51, 0x7a, 0x66, 0x15, 0x6b, 0x02, 0xd1, 0x31, 0x27, 0x93, 0x3f, 0x55, 0x9b, 0x5c, 0xdc, 0x6e, 0x02, 0xf7, 0x6e, 0x13, 0xb8, 0x3f, 0x37, 0x81, 0xfb, 0x75, 0x1b, 0x38, 0x77, 0xdb, 0xc0, 0xf9, 0xb1, 0x0d, 0x9c, 0x0f, 0xc3, 0xc3, 0xd5, 0x8d, 0xf7, 0xa9, 0x28, 0x99, 0xa4, 0x4a, 0x45, 0x4c, 0x0c, 0xed, 0x23, 0x5a, 0xc1, 0x33, 0x02, 0x15, 0x92, 0x26, 0x5c, 0xfb, 0x37, 0xbf, 0x03, 0x00, 0x00, 0xff, 0xff, 0xc6, 0xd9, 0xbc, 0x48, 0x60, 0x03, 0x00, 0x00, } func (this *Params) Equal(that interface{}) bool { if that == nil { return this == nil } that1, ok := that.(*Params) if !ok { that2, ok := that.(Params) if ok { that1 = &that2 } else { return false } } if that1 == nil { return this == nil } else if this == nil { return false } if this.MaxSlots != that1.MaxSlots { return false } if this.MaxGas != that1.MaxGas { return false } if this.FeeTtl != that1.FeeTtl { return false } return true } func (m *Params) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *Params) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *Params) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.FeeTtl != 0 { i = encodeVarintTypes(dAtA, i, uint64(m.FeeTtl)) i-- dAtA[i] = 0x18 } if m.MaxGas != 0 { i = encodeVarintTypes(dAtA, i, uint64(m.MaxGas)) i-- dAtA[i] = 0x10 } if m.MaxSlots != 0 { i = encodeVarintTypes(dAtA, i, uint64(m.MaxSlots)) i-- dAtA[i] = 0x8 } return len(dAtA) - i, nil } func (m *Thought) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *Thought) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *Thought) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.Particle) > 0 { i -= len(m.Particle) copy(dAtA[i:], m.Particle) i = encodeVarintTypes(dAtA, i, uint64(len(m.Particle))) i-- dAtA[i] = 0x2a } if len(m.Name) > 0 { i -= len(m.Name) copy(dAtA[i:], m.Name) i = encodeVarintTypes(dAtA, i, uint64(len(m.Name))) i-- dAtA[i] = 0x22 } { size, err := m.Load.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintTypes(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x1a { size, err := m.Trigger.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintTypes(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 if len(m.Program) > 0 { i -= len(m.Program) copy(dAtA[i:], m.Program) i = encodeVarintTypes(dAtA, i, uint64(len(m.Program))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *Trigger) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *Trigger) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *Trigger) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.Block != 0 { i = encodeVarintTypes(dAtA, i, uint64(m.Block)) i-- dAtA[i] = 0x10 } if m.Period != 0 { i = encodeVarintTypes(dAtA, i, uint64(m.Period)) i-- dAtA[i] = 0x8 } return len(dAtA) - i, nil } func (m *Load) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *Load) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *Load) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.GasPrice.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintTypes(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 if len(m.Input) > 0 { i -= len(m.Input) copy(dAtA[i:], m.Input) i = encodeVarintTypes(dAtA, i, uint64(len(m.Input))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *ThoughtStats) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *ThoughtStats) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *ThoughtStats) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.LastBlock != 0 { i = encodeVarintTypes(dAtA, i, uint64(m.LastBlock)) i-- dAtA[i] = 0x30 } if m.Gas != 0 { i = encodeVarintTypes(dAtA, i, uint64(m.Gas)) i-- dAtA[i] = 0x28 } if m.Fees != 0 { i = encodeVarintTypes(dAtA, i, uint64(m.Fees)) i-- dAtA[i] = 0x20 } if m.Calls != 0 { i = encodeVarintTypes(dAtA, i, uint64(m.Calls)) i-- dAtA[i] = 0x18 } if len(m.Name) > 0 { i -= len(m.Name) copy(dAtA[i:], m.Name) i = encodeVarintTypes(dAtA, i, uint64(len(m.Name))) i-- dAtA[i] = 0x12 } if len(m.Program) > 0 { i -= len(m.Program) copy(dAtA[i:], m.Program) i = encodeVarintTypes(dAtA, i, uint64(len(m.Program))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func encodeVarintTypes(dAtA []byte, offset int, v uint64) int { offset -= sovTypes(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *Params) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.MaxSlots != 0 { n += 1 + sovTypes(uint64(m.MaxSlots)) } if m.MaxGas != 0 { n += 1 + sovTypes(uint64(m.MaxGas)) } if m.FeeTtl != 0 { n += 1 + sovTypes(uint64(m.FeeTtl)) } return n } func (m *Thought) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Program) if l > 0 { n += 1 + l + sovTypes(uint64(l)) } l = m.Trigger.Size() n += 1 + l + sovTypes(uint64(l)) l = m.Load.Size() n += 1 + l + sovTypes(uint64(l)) l = len(m.Name) if l > 0 { n += 1 + l + sovTypes(uint64(l)) } l = len(m.Particle) if l > 0 { n += 1 + l + sovTypes(uint64(l)) } return n } func (m *Trigger) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.Period != 0 { n += 1 + sovTypes(uint64(m.Period)) } if m.Block != 0 { n += 1 + sovTypes(uint64(m.Block)) } return n } func (m *Load) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Input) if l > 0 { n += 1 + l + sovTypes(uint64(l)) } l = m.GasPrice.Size() n += 1 + l + sovTypes(uint64(l)) return n } func (m *ThoughtStats) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Program) if l > 0 { n += 1 + l + sovTypes(uint64(l)) } l = len(m.Name) if l > 0 { n += 1 + l + sovTypes(uint64(l)) } if m.Calls != 0 { n += 1 + sovTypes(uint64(m.Calls)) } if m.Fees != 0 { n += 1 + sovTypes(uint64(m.Fees)) } if m.Gas != 0 { n += 1 + sovTypes(uint64(m.Gas)) } if m.LastBlock != 0 { n += 1 + sovTypes(uint64(m.LastBlock)) } return n } func sovTypes(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozTypes(x uint64) (n int) { return sovTypes(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *Params) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: Params: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: Params: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field MaxSlots", wireType) } m.MaxSlots = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.MaxSlots |= uint32(b&0x7F) << shift if b < 0x80 { break } } case 2: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field MaxGas", wireType) } m.MaxGas = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.MaxGas |= uint32(b&0x7F) << shift if b < 0x80 { break } } case 3: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field FeeTtl", wireType) } m.FeeTtl = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.FeeTtl |= uint32(b&0x7F) << shift if b < 0x80 { break } } default: iNdEx = preIndex skippy, err := skipTypes(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTypes } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *Thought) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: Thought: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: Thought: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Program", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTypes } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTypes } if postIndex > l { return io.ErrUnexpectedEOF } m.Program = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Trigger", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthTypes } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthTypes } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Trigger.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 3: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Load", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthTypes } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthTypes } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Load.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 4: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTypes } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTypes } if postIndex > l { return io.ErrUnexpectedEOF } m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 5: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Particle", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTypes } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTypes } if postIndex > l { return io.ErrUnexpectedEOF } m.Particle = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTypes(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTypes } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *Trigger) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: Trigger: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: Trigger: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field Period", wireType) } m.Period = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.Period |= uint64(b&0x7F) << shift if b < 0x80 { break } } case 2: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field Block", wireType) } m.Block = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.Block |= uint64(b&0x7F) << shift if b < 0x80 { break } } default: iNdEx = preIndex skippy, err := skipTypes(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTypes } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *Load) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: Load: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: Load: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Input", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTypes } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTypes } if postIndex > l { return io.ErrUnexpectedEOF } m.Input = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field GasPrice", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthTypes } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthTypes } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.GasPrice.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTypes(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTypes } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *ThoughtStats) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: ThoughtStats: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: ThoughtStats: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Program", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTypes } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTypes } if postIndex > l { return io.ErrUnexpectedEOF } m.Program = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTypes } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTypes } if postIndex > l { return io.ErrUnexpectedEOF } m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field Calls", wireType) } m.Calls = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.Calls |= uint64(b&0x7F) << shift if b < 0x80 { break } } case 4: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field Fees", wireType) } m.Fees = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.Fees |= uint64(b&0x7F) << shift if b < 0x80 { break } } case 5: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field Gas", wireType) } m.Gas = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.Gas |= uint64(b&0x7F) << shift if b < 0x80 { break } } case 6: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field LastBlock", wireType) } m.LastBlock = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.LastBlock |= uint64(b&0x7F) << shift if b < 0x80 { break } } default: iNdEx = preIndex skippy, err := skipTypes(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTypes } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipTypes(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTypes } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTypes } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTypes } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthTypes } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupTypes } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthTypes } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthTypes = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowTypes = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupTypes = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/dmn/wasm/interface.go ================================================ package wasm import ( "encoding/json" errorsmod "cosmossdk.io/errors" wasmvmtypes "github.com/CosmWasm/wasmvm/types" pluginstypes "github.com/cybercongress/go-cyber/v7/plugins/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/dmn/keeper" ) type Messenger struct { keeper *keeper.Keeper } func NewMessenger( keeper *keeper.Keeper, ) *Messenger { return &Messenger{ keeper: keeper, } } func (m *Messenger) HandleMsg(ctx sdk.Context, contractAddr sdk.AccAddress, contractIBCPortID string, msg pluginstypes.CyberMsg) ([]sdk.Event, [][]byte, error) { switch { case msg.CreateThought != nil: if msg.CreateThought.Program != contractAddr.String() { return nil, nil, wasmvmtypes.InvalidRequest{Err: "create thought wrong program"} } msgServer := keeper.NewMsgServerImpl(*m.keeper) if err := msg.CreateThought.ValidateBasic(); err != nil { return nil, nil, errorsmod.Wrap(err, "failed validating msg") } res, err := msgServer.CreateThought( sdk.WrapSDKContext(ctx), msg.CreateThought, ) if err != nil { return nil, nil, errorsmod.Wrap(err, "create thought msg") } responseBytes, err := json.Marshal(*res) if err != nil { return nil, nil, errorsmod.Wrap(err, "failed to serialize create thought response") } resp := [][]byte{responseBytes} return nil, resp, nil case msg.ForgetThought != nil: if msg.ForgetThought.Program != contractAddr.String() { return nil, nil, wasmvmtypes.InvalidRequest{Err: "forget thought wrong program"} } msgServer := keeper.NewMsgServerImpl(*m.keeper) if err := msg.ForgetThought.ValidateBasic(); err != nil { return nil, nil, errorsmod.Wrap(err, "failed validating msg") } res, err := msgServer.ForgetThought( sdk.WrapSDKContext(ctx), msg.ForgetThought, ) if err != nil { return nil, nil, errorsmod.Wrap(err, "forget thought msg") } responseBytes, err := json.Marshal(*res) if err != nil { return nil, nil, errorsmod.Wrap(err, "failed to serialize forget thought response") } resp := [][]byte{responseBytes} return nil, resp, nil case msg.ChangeThoughtInput != nil: if msg.ChangeThoughtInput.Program != contractAddr.String() { return nil, nil, wasmvmtypes.InvalidRequest{Err: "change thought wrong program"} } msgServer := keeper.NewMsgServerImpl(*m.keeper) if err := msg.ChangeThoughtInput.ValidateBasic(); err != nil { return nil, nil, errorsmod.Wrap(err, "failed validating msg") } res, err := msgServer.ChangeThoughtInput( sdk.WrapSDKContext(ctx), msg.ChangeThoughtInput, ) if err != nil { return nil, nil, errorsmod.Wrap(err, "change thought input msg") } responseBytes, err := json.Marshal(*res) if err != nil { return nil, nil, errorsmod.Wrap(err, "failed to serialize change thought input response") } resp := [][]byte{responseBytes} return nil, resp, nil case msg.ChangeThoughtPeriod != nil: if msg.ChangeThoughtPeriod.Program != contractAddr.String() { return nil, nil, wasmvmtypes.InvalidRequest{Err: "change thought wrong program"} } msgServer := keeper.NewMsgServerImpl(*m.keeper) if err := msg.ChangeThoughtPeriod.ValidateBasic(); err != nil { return nil, nil, errorsmod.Wrap(err, "failed validating msg") } res, err := msgServer.ChangeThoughtPeriod( sdk.WrapSDKContext(ctx), msg.ChangeThoughtPeriod, ) if err != nil { return nil, nil, errorsmod.Wrap(err, "change thought period msg") } responseBytes, err := json.Marshal(*res) if err != nil { return nil, nil, errorsmod.Wrap(err, "failed to serialize change thought period response") } resp := [][]byte{responseBytes} return nil, resp, nil case msg.ChangeThoughtBlock != nil: if msg.ChangeThoughtBlock.Program != contractAddr.String() { return nil, nil, wasmvmtypes.InvalidRequest{Err: "change thought wrong program"} } msgServer := keeper.NewMsgServerImpl(*m.keeper) if err := msg.ChangeThoughtBlock.ValidateBasic(); err != nil { return nil, nil, errorsmod.Wrap(err, "failed validating msg") } res, err := msgServer.ChangeThoughtBlock( sdk.WrapSDKContext(ctx), msg.ChangeThoughtBlock, ) if err != nil { return nil, nil, errorsmod.Wrap(err, "change thought block msg") } responseBytes, err := json.Marshal(*res) if err != nil { return nil, nil, errorsmod.Wrap(err, "failed to serialize change thought block response") } resp := [][]byte{responseBytes} return nil, resp, nil case msg.ChangeThoughtGasPrice != nil: if msg.ChangeThoughtGasPrice.Program != contractAddr.String() { return nil, nil, wasmvmtypes.InvalidRequest{Err: "change thought wrong program"} } msgServer := keeper.NewMsgServerImpl(*m.keeper) if err := msg.ChangeThoughtGasPrice.ValidateBasic(); err != nil { return nil, nil, errorsmod.Wrap(err, "failed validating msg") } res, err := msgServer.ChangeThoughtGasPrice( sdk.WrapSDKContext(ctx), msg.ChangeThoughtGasPrice, ) if err != nil { return nil, nil, errorsmod.Wrap(err, "change thought gas price msg") } responseBytes, err := json.Marshal(*res) if err != nil { return nil, nil, errorsmod.Wrap(err, "failed to serialize change thought gas price response") } resp := [][]byte{responseBytes} return nil, resp, nil case msg.ChangeThoughtParticle != nil: if msg.ChangeThoughtParticle.Program != contractAddr.String() { return nil, nil, wasmvmtypes.InvalidRequest{Err: "change thought wrong program"} } msgServer := keeper.NewMsgServerImpl(*m.keeper) if err := msg.ChangeThoughtParticle.ValidateBasic(); err != nil { return nil, nil, errorsmod.Wrap(err, "failed validating msg") } res, err := msgServer.ChangeThoughtParticle( sdk.WrapSDKContext(ctx), msg.ChangeThoughtParticle, ) if err != nil { return nil, nil, errorsmod.Wrap(err, "change thought particle msg") } responseBytes, err := json.Marshal(*res) if err != nil { return nil, nil, errorsmod.Wrap(err, "failed to serialize change thought particle response") } resp := [][]byte{responseBytes} return nil, resp, nil case msg.ChangeThoughtName != nil: if msg.ChangeThoughtName.Program != contractAddr.String() { return nil, nil, wasmvmtypes.InvalidRequest{Err: "change thought wrong program"} } msgServer := keeper.NewMsgServerImpl(*m.keeper) if err := msg.ChangeThoughtName.ValidateBasic(); err != nil { return nil, nil, errorsmod.Wrap(err, "failed validating msg") } res, err := msgServer.ChangeThoughtName( sdk.WrapSDKContext(ctx), msg.ChangeThoughtName, ) if err != nil { return nil, nil, errorsmod.Wrap(err, "change thought name msg") } responseBytes, err := json.Marshal(*res) if err != nil { return nil, nil, errorsmod.Wrap(err, "failed to serialize change thought name response") } resp := [][]byte{responseBytes} return nil, resp, nil default: return nil, nil, pluginstypes.ErrHandleMsg } } type Querier struct { *keeper.Keeper } func NewWasmQuerier(keeper *keeper.Keeper) *Querier { return &Querier{keeper} } func (querier *Querier) HandleQuery(ctx sdk.Context, query pluginstypes.CyberQuery) ([]byte, error) { switch { case query.Thought != nil: res, err := querier.Keeper.Thought(ctx, query.Thought) if err != nil { return nil, errorsmod.Wrap(err, "failed to get dmn thought") } responseBytes, err := json.Marshal(res) if err != nil { return nil, errorsmod.Wrap(err, "failed to serialize dmn thought response") } return responseBytes, nil case query.ThoughtStats != nil: res, err := querier.Keeper.ThoughtStats(ctx, query.ThoughtStats) if err != nil { return nil, errorsmod.Wrap(err, "failed to get dmn thought stats") } responseBytes, err := json.Marshal(res) if err != nil { return nil, errorsmod.Wrap(err, "failed to serialize dmn thought stats response") } return responseBytes, nil case query.ThoughtsFees != nil: res, err := querier.Keeper.ThoughtsFees(ctx, query.ThoughtsFees) if err != nil { return nil, errorsmod.Wrap(err, "failed to get dmn thoughts fees") } responseBytes, err := json.Marshal(res) if err != nil { return nil, errorsmod.Wrap(err, "failed to serialize dmn thoughts fees response") } return responseBytes, nil default: return nil, pluginstypes.ErrHandleQuery } } ================================================ FILE: x/graph/abci.go ================================================ package graph import ( "time" "github.com/cosmos/cosmos-sdk/telemetry" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/graph/keeper" "github.com/cybercongress/go-cyber/v7/x/graph/types" ) func EndBlocker(ctx sdk.Context, gk *keeper.GraphKeeper, ik *keeper.IndexKeeper) { amountParticles := gk.GetCidsCount(ctx) amountLinks := gk.GetLinksCount(ctx) defer telemetry.ModuleMeasureSince(types.ModuleName, time.Now(), telemetry.MetricKeyEndBlocker) defer telemetry.ModuleSetGauge(types.ModuleName, float32(amountLinks), "total_cyberlinks") defer telemetry.ModuleSetGauge(types.ModuleName, float32(amountParticles), "total_particles") gk.UpdateMemNeudegs(ctx) // ik.MergeContextLinks(ctx) } ================================================ FILE: x/graph/client/cli/query.go ================================================ package cli import ( "context" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" "github.com/spf13/cobra" "github.com/cybercongress/go-cyber/v7/x/graph/types" ) // GetQueryCmd returns func GetQueryCmd() *cobra.Command { queryCmd := &cobra.Command{ Use: types.ModuleName, Short: "Querying commands for the graph module", DisableFlagParsing: true, SuggestionsMinimumDistance: 2, RunE: client.ValidateCmd, } queryCmd.AddCommand( GetCmdGraphStats(), ) return queryCmd } func GetCmdGraphStats() *cobra.Command { cmd := &cobra.Command{ Use: "stats", Short: "Query the graph stats", Args: cobra.NoArgs, RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientQueryContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) res, err := queryClient.GraphStats( context.Background(), &types.QueryGraphStatsRequest{}, ) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } ================================================ FILE: x/graph/client/cli/tx.go ================================================ package cli import ( "fmt" "strings" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/client/tx" "github.com/cosmos/cosmos-sdk/version" "github.com/ipfs/go-cid" "github.com/spf13/cobra" "github.com/cybercongress/go-cyber/v7/x/graph/types" ) func NewTxCmd() *cobra.Command { txCmd := &cobra.Command{ Use: types.ModuleName, Short: "Graph transaction subcommands", DisableFlagParsing: true, SuggestionsMinimumDistance: 2, RunE: client.ValidateCmd, } txCmd.AddCommand( GetCmdLink(), ) return txCmd } func GetCmdLink() *cobra.Command { cmd := &cobra.Command{ Use: "cyberlink [cid-from] [cid-to]", Short: "Create cyberlink", Args: cobra.ExactArgs(2), Long: strings.TrimSpace( fmt.Sprintf(`Create cyberlink. Example: $ %s tx link cyberlink QmWZYRj344JSLShtBnrMS4vw5DQ2zsGqrytYKMqcQgEneB QmfZwbahFLTcB3MTMT8TA8si5khhRmzm7zbHToo4WVK3zn `, version.AppName, ), ), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientTxContext(cmd) if err != nil { return err } cidFrom := types.Cid(args[0]) cidTo := types.Cid(args[1]) if _, err := cid.Decode(string(cidFrom)); err != nil { return types.ErrInvalidParticle } if _, err := cid.Decode(string(cidTo)); err != nil { return types.ErrInvalidParticle } msg := types.NewMsgCyberlink( clientCtx.GetFromAddress(), []types.Link{ {From: string(cidFrom), To: string(cidTo)}, }, ) err = msg.ValidateBasic() if err != nil { return err } return tx.GenerateOrBroadcastTxCLI(clientCtx, cmd.Flags(), msg) }, } flags.AddTxFlagsToCmd(cmd) return cmd } ================================================ FILE: x/graph/keeper/genesis.go ================================================ package keeper import ( "bufio" "os" "path/filepath" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/utils" ) const ( LinksFileName = "config/graph" LinksExportFileName = "export/graph" ) // TODO make refactoring of initial rank calculation on graph load from binary func InitGenesis( ctx sdk.Context, gk GraphKeeper, ik *IndexKeeper, ) (err error) { linksFilePath := utils.RootifyPath(LinksFileName) linksFile, err := os.Open(linksFilePath) if err != nil { if os.IsNotExist(err) { gk.Logger(ctx).Info("File with cyberlinks and particles not found. Empty set will be used") return nil } return err } reader := bufio.NewReader(linksFile) // 4096 bytes chunk size // initialize slices to read data err = gk.LoadFromReader(ctx, reader) if err != nil { return err } // Read all links err = ik.LoadFromReader(ctx, reader) if err != nil { return err } return } func WriteGenesis( ctx sdk.Context, gk GraphKeeper, ik *IndexKeeper, ) (err error) { linksFilePath := utils.RootifyPath(LinksExportFileName) dirName := filepath.Dir(linksFilePath) if _, err := os.Stat(dirName); err != nil { if err = os.MkdirAll(dirName, os.ModePerm); err != nil { return err } } linksFile, err := os.Create(linksFilePath) if err != nil { return } writer := bufio.NewWriter(linksFile) // 4096 byte chunk err = gk.WriteCids(ctx, writer) if err != nil { return } err = ik.WriteLinks(ctx, writer) if err != nil { return } err = writer.Flush() if err != nil { return } gk.Logger(ctx).Info("Particles and cyberlinks exported. File created.", "path", linksFilePath) return //nolint:nakedret } ================================================ FILE: x/graph/keeper/graph.go ================================================ package keeper import ( "encoding/binary" "fmt" "io" storetypes "github.com/cosmos/cosmos-sdk/store/types" "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/telemetry" "github.com/cometbft/cometbft/libs/log" ctypes "github.com/cybercongress/go-cyber/v7/types" "github.com/cybercongress/go-cyber/v7/x/graph/types" sdk "github.com/cosmos/cosmos-sdk/types" ) const ( LinkBytesSize = uint64(24) LinksCountBytesSize = uint64(8) ) type GraphKeeper struct { key storetypes.StoreKey cdc codec.BinaryCodec neudeg map[uint64]uint64 rankNeudeg map[uint64]uint64 tkey *storetypes.TransientStoreKey } func NewKeeper( cdc codec.BinaryCodec, storeKey storetypes.StoreKey, tkey *storetypes.TransientStoreKey, ) *GraphKeeper { return &GraphKeeper{ cdc: cdc, key: storeKey, tkey: tkey, neudeg: make(map[uint64]uint64), rankNeudeg: make(map[uint64]uint64), } } func (gk GraphKeeper) Logger(ctx sdk.Context) log.Logger { return ctx.Logger().With("module", fmt.Sprintf("x/%s", types.ModuleName)) } func (gk GraphKeeper) SaveLink(ctx sdk.Context, link types.CompactLink) { defer telemetry.IncrCounter(1.0, types.ModuleName, "cyberlinks") store := ctx.KVStore(gk.key) store.Set(types.CyberlinksStoreKey(types.CyberlinkRawKey(link)), sdk.Uint64ToBigEndian(uint64(ctx.BlockHeight()))) gk.IncrementLinksCount(ctx) } func (gk GraphKeeper) GetAllLinks(ctx sdk.Context) (types.Links, types.Links, error) { return gk.GetAllLinksFiltered(ctx, func(l types.CompactLink) bool { return true }) } func (gk GraphKeeper) GetAllLinksFiltered(ctx sdk.Context, filter types.LinkFilter) (types.Links, types.Links, error) { inLinks := make(map[types.CidNumber]types.CidLinks) outLinks := make(map[types.CidNumber]types.CidLinks) gk.IterateLinks(ctx, func(link types.CompactLink) { if filter(link) { types.Links(outLinks).Put(types.CidNumber(link.From), types.CidNumber(link.To), ctypes.AccNumber(link.Account)) types.Links(inLinks).Put(types.CidNumber(link.To), types.CidNumber(link.From), ctypes.AccNumber(link.Account)) } }) return inLinks, outLinks, nil } func (gk GraphKeeper) IterateLinks(ctx sdk.Context, process func(link types.CompactLink)) { gk.IterateBinaryLinks(ctx, func(key, value []byte) { compactLink := types.CompactLink{ // because first byte is prefix From: sdk.BigEndianToUint64(key[1:9]), To: sdk.BigEndianToUint64(key[17:25]), Account: sdk.BigEndianToUint64(key[9:17]), } process(compactLink) }) } func (gk GraphKeeper) IterateBinaryLinks(ctx sdk.Context, process func(key, value []byte)) { store := ctx.KVStore(gk.key) iterator := sdk.KVStorePrefixIterator(store, types.CyberlinkStoreKeyPrefix) defer iterator.Close() for ; iterator.Valid(); iterator.Next() { process(iterator.Key(), iterator.Value()) } } func (gk GraphKeeper) IncrementLinksCount(ctx sdk.Context) { store := ctx.KVStore(gk.key) linksCount := gk.GetLinksCount(ctx) + 1 store.Set(types.LinksCount, sdk.Uint64ToBigEndian(linksCount)) } func (gk GraphKeeper) GetLinksCount(ctx sdk.Context) uint64 { store := ctx.KVStore(gk.key) linksCountAsBytes := store.Get(types.LinksCount) if linksCountAsBytes == nil { return 0 } return sdk.BigEndianToUint64(linksCountAsBytes) } func (gk GraphKeeper) GetBurnedVolts(ctx sdk.Context) uint64 { store := ctx.KVStore(gk.key) burnedVoltsAsBytes := store.Get(types.BurnedVolts) if burnedVoltsAsBytes == nil { return 0 } return sdk.BigEndianToUint64(burnedVoltsAsBytes) } func (gk GraphKeeper) AddBurnedVolts(ctx sdk.Context, toBurn uint64) { var burnedVolts = uint64(0) store := ctx.KVStore(gk.key) burnedVoltsAsBytes := store.Get(types.BurnedVolts) if burnedVoltsAsBytes != nil { burnedVolts = sdk.BigEndianToUint64(burnedVoltsAsBytes) } store.Set(types.BurnedVolts, sdk.Uint64ToBigEndian(burnedVolts+toBurn)) } func (gk GraphKeeper) GetBurnedAmperes(ctx sdk.Context) uint64 { store := ctx.KVStore(gk.key) burnedAmperesAsBytes := store.Get(types.BurnedAmperes) if burnedAmperesAsBytes == nil { return 0 } return sdk.BigEndianToUint64(burnedAmperesAsBytes) } func (gk GraphKeeper) AddBurnedAmperes(ctx sdk.Context, toBurn uint64) { var burnedAmperes = uint64(0) store := ctx.KVStore(gk.key) burnedAmperesAsBytes := store.Get(types.BurnedAmperes) if burnedAmperesAsBytes != nil { burnedAmperes = sdk.BigEndianToUint64(burnedAmperesAsBytes) } store.Set(types.BurnedAmperes, sdk.Uint64ToBigEndian(burnedAmperes+toBurn)) } // write links to writer in binary format: ... func (gk GraphKeeper) WriteLinks(ctx sdk.Context, writer io.Writer) (err error) { uintAsBytes := make([]byte, 8) linksCount := gk.GetLinksCount(ctx) binary.LittleEndian.PutUint64(uintAsBytes, linksCount) _, err = writer.Write(uintAsBytes) if err != nil { return } gk.IterateLinks(ctx, func(link types.CompactLink) { bytes := link.MarshalBinaryLink() _, err = writer.Write(bytes) if err != nil { return } }) return nil } ================================================ FILE: x/graph/keeper/grpc_query.go ================================================ package keeper import ( "context" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/graph/types" ) var _ types.QueryServer = GraphKeeper{} func (gk GraphKeeper) GraphStats(goCtx context.Context, _ *types.QueryGraphStatsRequest) (*types.QueryGraphStatsResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) links := gk.GetLinksCount(ctx) cids := gk.GetCidsCount(ctx) return &types.QueryGraphStatsResponse{Cyberlinks: links, Particles: cids}, nil } func (gk GraphKeeper) BurnStats(goCtx context.Context, _ *types.QueryBurnStatsRequest) (*types.QueryBurnStatsResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) millivolts := gk.GetBurnedVolts(ctx) milliamperes := gk.GetBurnedAmperes(ctx) return &types.QueryBurnStatsResponse{millivolts, milliamperes}, nil } ================================================ FILE: x/graph/keeper/index.go ================================================ package keeper import ( "encoding/binary" "io" storetypes "github.com/cosmos/cosmos-sdk/store/types" ctypes "github.com/cybercongress/go-cyber/v7/types" "github.com/cybercongress/go-cyber/v7/utils" "github.com/cybercongress/go-cyber/v7/x/graph/types" tmos "github.com/cometbft/cometbft/libs/os" sdk "github.com/cosmos/cosmos-sdk/types" ) type IndexKeeper struct { GraphKeeper // Actual links for current rank calculated state. currentRankInLinks types.Links currentRankOutLinks types.Links // New links for the next rank calculation. nextRankInLinks types.Links nextRankOutLinks types.Links // Inter-block cache for cyberlinks, reset on every block during Commit tkey *storetypes.TransientStoreKey // currentBlockLinks []types.CompactLink } func NewIndexKeeper(gk GraphKeeper, tkey *storetypes.TransientStoreKey) *IndexKeeper { return &IndexKeeper{ GraphKeeper: gk, tkey: tkey, } } func (i *IndexKeeper) LoadState(rankCtx sdk.Context, freshCtx sdk.Context) { inLinks, outLinks, err := i.GraphKeeper.GetAllLinks(rankCtx) if err != nil { tmos.Exit(err.Error()) } i.currentRankInLinks = inLinks i.currentRankOutLinks = outLinks newInLinks, newOutLinks, err := i.GraphKeeper.GetAllLinksFiltered(freshCtx, func(l types.CompactLink) bool { return !i.currentRankOutLinks.IsLinkExist(types.CidNumber(l.From), types.CidNumber(l.To), ctypes.AccNumber(l.Account)) }) if err != nil { tmos.Exit(err.Error()) } i.nextRankInLinks = newInLinks i.nextRankOutLinks = newOutLinks } func (i *IndexKeeper) UpdateRankLinks() { i.currentRankInLinks.PutAll(i.nextRankInLinks) i.currentRankOutLinks.PutAll(i.nextRankOutLinks) i.nextRankInLinks = make(types.Links) i.nextRankOutLinks = make(types.Links) } func (i *IndexKeeper) MergeContextLinks(ctx sdk.Context) { lenLinks := uint64(0) iterator := sdk.KVStorePrefixIterator(ctx.TransientStore(i.tkey), types.CyberlinkTStoreKeyPrefix) defer iterator.Close() for ; iterator.Valid(); iterator.Next() { link := types.UnmarshalBinaryLink(iterator.Key()[1:]) i.nextRankOutLinks.Put(types.CidNumber(link.From), types.CidNumber(link.To), ctypes.AccNumber(link.Account)) i.nextRankInLinks.Put(types.CidNumber(link.To), types.CidNumber(link.From), ctypes.AccNumber(link.Account)) lenLinks++ } if lenLinks > 0 { store := ctx.TransientStore(i.tkey) store.Set(types.HasNewLinks, sdk.Uint64ToBigEndian(lenLinks)) } } func (i *IndexKeeper) HasNewLinks(ctx sdk.Context) bool { store := ctx.TransientStore(i.tkey) hasLinks := store.Get(types.HasNewLinks) if hasLinks == nil { return false } return sdk.BigEndianToUint64(hasLinks) > 0 } // Use transient store because need to commit cyberlinks to cache only when transaction is successful func (i *IndexKeeper) PutLink(ctx sdk.Context, link types.CompactLink) { store := ctx.TransientStore(i.tkey) store.Set(types.CyberlinksTStoreKey(link.MarshalBinaryLink()), []byte{1}) } func (i *IndexKeeper) GetOutLinks() types.Links { return i.currentRankOutLinks } func (i *IndexKeeper) GetInLinks() types.Links { return i.currentRankInLinks } func (i *IndexKeeper) GetNextOutLinks() types.Links { return i.nextRankOutLinks } func (i *IndexKeeper) GetCurrentBlockNewLinks(ctx sdk.Context) []types.CompactLink { result := make([]types.CompactLink, 0, 1000) iterator := sdk.KVStorePrefixIterator(ctx.TransientStore(i.tkey), types.CyberlinkTStoreKeyPrefix) defer iterator.Close() for ; iterator.Valid(); iterator.Next() { link := types.UnmarshalBinaryLink(iterator.Key()[1:]) if !i.IsAnyLinkExist(types.CidNumber(link.From), types.CidNumber(link.To)) { result = append(result, link) } } return result } func (i *IndexKeeper) IsAnyLinkExist(from types.CidNumber, to types.CidNumber) bool { return i.currentRankOutLinks.IsAnyLinkExist(from, to) || i.nextRankOutLinks.IsAnyLinkExist(from, to) } func (i *IndexKeeper) IsLinkExist(link types.CompactLink) bool { return i.currentRankOutLinks.IsLinkExist(types.CidNumber(link.From), types.CidNumber(link.To), ctypes.AccNumber(link.Account)) || i.nextRankOutLinks.IsLinkExist(types.CidNumber(link.From), types.CidNumber(link.To), ctypes.AccNumber(link.Account)) } func (i *IndexKeeper) IsLinkExistInCache(ctx sdk.Context, link types.CompactLink) bool { store := ctx.TransientStore(i.tkey) return store.Has(link.MarshalBinaryLink()) } func (i *IndexKeeper) LoadFromReader(ctx sdk.Context, reader io.Reader) (err error) { linksCountBytes, err := utils.ReadExactlyNBytes(reader, LinksCountBytesSize) if err != nil { return } linksCount := binary.LittleEndian.Uint64(linksCountBytes) for j := uint64(0); j < linksCount; j++ { linkBytes, err := utils.ReadExactlyNBytes(reader, LinkBytesSize) if err != nil { return err } compactLink := types.UnmarshalBinaryLink(linkBytes) i.GraphKeeper.neudeg[compactLink.Account] += 1 i.GraphKeeper.rankNeudeg[compactLink.Account] += 1 i.GraphKeeper.SaveLink(ctx, compactLink) i.PutLink(ctx, compactLink) } for acc, links := range i.GraphKeeper.neudeg { i.GraphKeeper.SaveNeudeg(ctx, acc, links) } return } ================================================ FILE: x/graph/keeper/msg_server.go ================================================ package keeper import ( "context" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" sdk "github.com/cosmos/cosmos-sdk/types" authkeeper "github.com/cosmos/cosmos-sdk/x/auth/keeper" ctypes "github.com/cybercongress/go-cyber/v7/types" bandwidthkeeper "github.com/cybercongress/go-cyber/v7/x/bandwidth/keeper" bandwidthtypes "github.com/cybercongress/go-cyber/v7/x/bandwidth/types" cyberbankkeeper "github.com/cybercongress/go-cyber/v7/x/cyberbank/keeper" // sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" "github.com/cybercongress/go-cyber/v7/x/graph/types" ) type msgServer struct { *GraphKeeper *IndexKeeper authkeeper.AccountKeeper *cyberbankkeeper.IndexedKeeper *bandwidthkeeper.BandwidthMeter } // NewMsgServerImpl returns an implementation of the stored MsgServer interface // for the provided Keeper. func NewMsgServerImpl( gk *GraphKeeper, ik *IndexKeeper, ak authkeeper.AccountKeeper, bk *cyberbankkeeper.IndexedKeeper, bm *bandwidthkeeper.BandwidthMeter, ) types.MsgServer { return &msgServer{ gk, ik, ak, bk, bm, } } var _ types.MsgServer = msgServer{} func (k msgServer) Cyberlink(goCtx context.Context, msg *types.MsgCyberlink) (*types.MsgCyberlinkResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) var accNumber ctypes.AccNumber addr, err := sdk.AccAddressFromBech32(msg.Neuron) if err != nil { return nil, err } acc := k.GetAccount(ctx, addr) if acc != nil { accNumber = ctypes.AccNumber(acc.GetAccountNumber()) } else { return nil, sdkerrors.Wrap(sdkerrors.ErrInvalidAddress, "Invalid neuron address") } // TODO move to ante and contract case below if ampers, ok := k.GetTotalStakesAmpere()[uint64(accNumber)]; ok { if ampers == 0 { return nil, types.ErrZeroPower } } else { return nil, types.ErrZeroPower } cost := uint64(k.GetCurrentCreditPrice().MulInt64(int64(len(msg.Links) * 1000)).TruncateInt64()) currentBlockSpentBandwidth := k.GetCurrentBlockSpentBandwidth(ctx) maxBlockBandwidth := k.GetMaxBlockBandwidth(ctx) if !k.HasEnoughAccountBandwidthVolt(ctx, cost, addr) { return nil, bandwidthtypes.ErrNotEnoughBandwidth } if (cost + currentBlockSpentBandwidth) > maxBlockBandwidth { return nil, bandwidthtypes.ErrExceededMaxBlockBandwidth } err = k.BurnAccountBandwidthVolt(ctx, cost, addr) if err != nil { return nil, bandwidthtypes.ErrNotEnoughBandwidth } k.AddToBlockBandwidth(ctx, cost) k.AddBurnedVolts(ctx, cost) for _, link := range msg.Links { // if cid not exists it automatically means that this is new link fromCidNumber, exists := k.GetCidNumber(ctx, types.Cid(link.From)) if !exists { continue } toCidNumber, exists := k.GetCidNumber(ctx, types.Cid(link.To)) if !exists { continue } compactLink := types.NewLink(fromCidNumber, toCidNumber, accNumber) if k.IndexKeeper.IsLinkExist(compactLink) { return nil, types.ErrCyberlinkExist } if k.IndexKeeper.IsLinkExistInCache(ctx, compactLink) { return nil, types.ErrCyberlinkExist } } for _, link := range msg.Links { fromCidNumber := k.GetOrPutCidNumber(ctx, types.Cid(link.From)) toCidNumber := k.GetOrPutCidNumber(ctx, types.Cid(link.To)) k.GraphKeeper.SaveLink(ctx, types.NewLink(fromCidNumber, toCidNumber, accNumber)) k.GraphKeeper.IncrementNeudeg(ctx, uint64(accNumber)) k.IndexKeeper.PutLink(ctx, types.NewLink(fromCidNumber, toCidNumber, accNumber)) ctx.EventManager().EmitEvent( sdk.NewEvent( types.EventTypeCyberlink, sdk.NewAttribute(types.AttributeKeyParticleFrom, link.From), sdk.NewAttribute(types.AttributeKeyParticleTo, link.To), ), ) } ctx.EventManager().EmitEvents(sdk.Events{ sdk.NewEvent( types.EventTypeCyberlink, sdk.NewAttribute(types.AttributeKeyNeuron, msg.Neuron), ), sdk.NewEvent( sdk.EventTypeMessage, sdk.NewAttribute(sdk.AttributeKeyModule, types.AttributeValueCategory), sdk.NewAttribute(sdk.AttributeKeySender, msg.Neuron), ), }) return &types.MsgCyberlinkResponse{}, nil } ================================================ FILE: x/graph/keeper/neudeg.go ================================================ package keeper import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/graph/types" ) // In order to calculate the flow of amperes through cyberlinks created by given agents than need to compute neurons out-degree // transient store used to sync values to in-memory at the end block func (gk *GraphKeeper) LoadNeudeg(rankCtx sdk.Context, freshCtx sdk.Context) { iterator := sdk.KVStorePrefixIterator(rankCtx.KVStore(gk.key), types.NeudegStoreKeyPrefix) for ; iterator.Valid(); iterator.Next() { acc := sdk.BigEndianToUint64(iterator.Key()[1:]) gk.rankNeudeg[acc] = sdk.BigEndianToUint64(iterator.Value()) } iterator.Close() iterator = sdk.KVStorePrefixIterator(freshCtx.KVStore(gk.key), types.NeudegStoreKeyPrefix) for ; iterator.Valid(); iterator.Next() { acc := sdk.BigEndianToUint64(iterator.Key()[1:]) gk.neudeg[acc] = sdk.BigEndianToUint64(iterator.Value()) } iterator.Close() } // NOTE: used when load from exported graph with links func (gk GraphKeeper) SaveNeudeg(ctx sdk.Context, accNumber uint64, neudeg uint64) { store := ctx.KVStore(gk.key) store.Set(types.NeudegStoreKey(accNumber), sdk.Uint64ToBigEndian(neudeg)) } func (gk GraphKeeper) IncrementNeudeg(ctx sdk.Context, accNumber uint64) { store := ctx.KVStore(gk.key) neudeg := gk.GetNeudeg(ctx, accNumber) + 1 store.Set(types.NeudegStoreKey(accNumber), sdk.Uint64ToBigEndian(neudeg)) store = ctx.TransientStore(gk.tkey) tneudeg := gk.GetTNeudeg(ctx, accNumber) + 1 store.Set(types.NeudegTStoreKey(accNumber), sdk.Uint64ToBigEndian(tneudeg)) } func (gk GraphKeeper) GetNeudeg(ctx sdk.Context, accNumber uint64) uint64 { store := ctx.KVStore(gk.key) neudeg := store.Get(types.NeudegStoreKey(accNumber)) if neudeg == nil { return 0 } return sdk.BigEndianToUint64(neudeg) } func (gk GraphKeeper) GetTNeudeg(ctx sdk.Context, accNumber uint64) uint64 { store := ctx.TransientStore(gk.tkey) neudeg := store.Get(types.NeudegTStoreKey(accNumber)) if neudeg == nil { return 0 } return sdk.BigEndianToUint64(neudeg) } func (gk *GraphKeeper) GetNeudegs() map[uint64]uint64 { return gk.rankNeudeg } func (gk *GraphKeeper) UpdateMemNeudegs(ctx sdk.Context) { iterator := sdk.KVStorePrefixIterator(ctx.TransientStore(gk.tkey), types.NeudegTStoreKeyPrefix) defer iterator.Close() for ; iterator.Valid(); iterator.Next() { acc := sdk.BigEndianToUint64(iterator.Key()[1:]) gk.neudeg[acc] += sdk.BigEndianToUint64(iterator.Value()) } } func (gk *GraphKeeper) UpdateRankNeudegs() { for acc := range gk.neudeg { gk.rankNeudeg[acc] = gk.neudeg[acc] } } ================================================ FILE: x/graph/keeper/particles.go ================================================ package keeper import ( "encoding/binary" "io" "github.com/cosmos/cosmos-sdk/telemetry" "github.com/cybercongress/go-cyber/v7/utils" "github.com/cybercongress/go-cyber/v7/x/graph/types" sdk "github.com/cosmos/cosmos-sdk/types" ) const ( CidLengthBytesSize = uint64(1) CidNumberBytesSize = uint64(8) CidCountBytesSize = uint64(8) ) // Return cid number and true, if cid exists func (gk GraphKeeper) GetCidNumber(ctx sdk.Context, cid types.Cid) (types.CidNumber, bool) { store := ctx.KVStore(gk.key) cidIndexAsBytes := store.Get(types.CidStoreKey(cid)) if cidIndexAsBytes != nil { return types.CidNumber(sdk.BigEndianToUint64(cidIndexAsBytes)), true } return 0, false } func (gk GraphKeeper) GetCid(ctx sdk.Context, num types.CidNumber) types.Cid { store := ctx.KVStore(gk.key) cidAsBytes := store.Get(types.CidReverseStoreKey(num)) return types.Cid(cidAsBytes) } // CIDs index is array of all added CIDs, sorted asc by first link time. // for given link, CIDs added in order [CID1, CID2] (if they both new to chain) // This method performs lookup of CIDs, returns index value, or create and put in index new value if not exists. func (gk GraphKeeper) GetOrPutCidNumber(ctx sdk.Context, cid types.Cid) types.CidNumber { store := ctx.KVStore(gk.key) cidIndexAsBytes := store.Get(types.CidStoreKey(cid)) if cidIndexAsBytes == nil { lastIndex := gk.GetCidsCount(ctx) store.Set(types.CidStoreKey(cid), sdk.Uint64ToBigEndian(lastIndex)) store.Set(types.CidReverseStoreKey(types.CidNumber(lastIndex)), []byte(cid)) store.Set(types.LastCidNumber, sdk.Uint64ToBigEndian(lastIndex)) telemetry.IncrCounter(1.0, types.ModuleName, "cids") return types.CidNumber(lastIndex) } return types.CidNumber(sdk.BigEndianToUint64(cidIndexAsBytes)) } func (gk GraphKeeper) GetCidsCount(ctx sdk.Context) uint64 { store := ctx.KVStore(gk.key) lastIndexAsBytes := store.Get(types.LastCidNumber) if lastIndexAsBytes == nil { return 0 } return sdk.BigEndianToUint64(lastIndexAsBytes) + 1 } func (gk GraphKeeper) SetLastCidIndex(ctx sdk.Context, lastCidIndex uint64) { store := ctx.KVStore(gk.key) store.Set(types.LastCidNumber, sdk.Uint64ToBigEndian(lastCidIndex)) } func (gk GraphKeeper) PutCid(ctx sdk.Context, cid types.Cid, cidNumber types.CidNumber) { store := ctx.KVStore(gk.key) store.Set(types.CidStoreKey(cid), sdk.Uint64ToBigEndian(uint64(cidNumber))) store.Set(types.CidReverseStoreKey(cidNumber), []byte(cid)) } func (gk GraphKeeper) IterateCids(ctx sdk.Context, process func(types.Cid, types.CidNumber)) { store := ctx.KVStore(gk.key) iterator := sdk.KVStorePrefixIterator(store, types.CidStoreKeyPrefix) defer iterator.Close() for iterator.Valid() { // [1:0] because we have prefix []byte{0x01} for cids process(types.Cid(iterator.Key()[1:]), types.CidNumber(sdk.BigEndianToUint64(iterator.Value()))) iterator.Next() } } // write CIDs to writer in binary format: .... func (gk GraphKeeper) WriteCids(ctx sdk.Context, writer io.Writer) (err error) { uintAsBytes := make([]byte, 8) // common bytes array to convert uints cidsCount := gk.GetCidsCount(ctx) binary.LittleEndian.PutUint64(uintAsBytes, cidsCount) _, err = writer.Write(uintAsBytes) if err != nil { return } gk.IterateCids(ctx, func(cid types.Cid, number types.CidNumber) { cidLength := len(cid) if cidLength > 255 { // err = errors.New("cid length cannot be over 255") return } _, err = writer.Write([]byte{byte(cidLength)}) if err != nil { return } _, err = writer.Write([]byte(cid)) if err != nil { return } binary.LittleEndian.PutUint64(uintAsBytes, uint64(number)) _, err = writer.Write(uintAsBytes) if err != nil { return } }) return //nolint:nakedret } func (gk GraphKeeper) LoadFromReader(ctx sdk.Context, reader io.Reader) (err error) { cidCountBytes, err := utils.ReadExactlyNBytes(reader, CidCountBytesSize) if err != nil { return } cidCount := binary.LittleEndian.Uint64(cidCountBytes) for i := uint64(0); i < cidCount; i++ { cidLengthBytes, err := utils.ReadExactlyNBytes(reader, CidLengthBytesSize) if err != nil { return err } cidBytes, err := utils.ReadExactlyNBytes(reader, uint64(cidLengthBytes[0])) if err != nil { return err } cid := types.Cid(cidBytes) cidNumberBytes, err := utils.ReadExactlyNBytes(reader, CidNumberBytesSize) if err != nil { return err } cidNumber := types.CidNumber(binary.LittleEndian.Uint64(cidNumberBytes)) gk.PutCid(ctx, cid, cidNumber) } lastCidIndex := cidCount - 1 gk.SetLastCidIndex(ctx, lastCidIndex) return } ================================================ FILE: x/graph/keeper/snapshotter.go ================================================ package keeper import ( "github.com/cometbft/cometbft/libs/log" tmproto "github.com/cometbft/cometbft/proto/tendermint/types" snapshot "github.com/cosmos/cosmos-sdk/snapshots/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/graph/types" ) var _ snapshot.ExtensionSnapshotter = &GraphSnapshotter{} const SnapshotFormat = 1 type GraphSnapshotter struct { graphKeeper *GraphKeeper indexKeeper *IndexKeeper cms sdk.MultiStore } func NewGraphSnapshotter(cms sdk.MultiStore, graphKeeper *GraphKeeper, indexKeeper *IndexKeeper) *GraphSnapshotter { return &GraphSnapshotter{ graphKeeper: graphKeeper, indexKeeper: indexKeeper, cms: cms, } } func (gs *GraphSnapshotter) SnapshotName() string { return types.ModuleName } func (gs *GraphSnapshotter) SnapshotFormat() uint32 { return SnapshotFormat } func (gs *GraphSnapshotter) SupportedFormats() []uint32 { // If we support older formats, add them here and handle them in Restore return []uint32{SnapshotFormat} } func (gs *GraphSnapshotter) SnapshotExtension(_ uint64, _ snapshot.ExtensionPayloadWriter) error { return nil } func (gs *GraphSnapshotter) RestoreExtension(height uint64, format uint32, _ snapshot.ExtensionPayloadReader) error { if format == SnapshotFormat { freshCtx := sdk.NewContext(gs.cms, tmproto.Header{Height: int64(height)}, false, log.NewNopLogger()) // TODO revisit with get params and case of increased rank computation blocks calculationPeriod := int64(5) rankRoundBlockNumber := (freshCtx.BlockHeight() / calculationPeriod) * calculationPeriod store, err := gs.cms.CacheMultiStoreWithVersion(rankRoundBlockNumber) if err != nil { println("Error: ", err) } rankCtx := sdk.NewContext(store, tmproto.Header{Height: rankRoundBlockNumber}, false, log.NewNopLogger()) gs.indexKeeper.LoadState(rankCtx, freshCtx) gs.graphKeeper.LoadNeudeg(rankCtx, freshCtx) return nil } return snapshot.ErrUnknownFormat } ================================================ FILE: x/graph/module.go ================================================ package graph import ( "context" "encoding/json" abci "github.com/cometbft/cometbft/abci/types" "github.com/cosmos/cosmos-sdk/client" codectypes "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" "github.com/grpc-ecosystem/grpc-gateway/runtime" bandwidthkeeper "github.com/cybercongress/go-cyber/v7/x/bandwidth/keeper" "github.com/cosmos/cosmos-sdk/codec" authkeeper "github.com/cosmos/cosmos-sdk/x/auth/keeper" "github.com/spf13/cobra" cyberbankkeeper "github.com/cybercongress/go-cyber/v7/x/cyberbank/keeper" "github.com/cybercongress/go-cyber/v7/x/graph/client/cli" "github.com/cybercongress/go-cyber/v7/x/graph/keeper" "github.com/cybercongress/go-cyber/v7/x/graph/types" ) var ( _ module.AppModule = AppModule{} _ module.AppModuleBasic = AppModuleBasic{} ) type AppModuleBasic struct { cdc codec.Codec } func (AppModuleBasic) Name() string { return types.ModuleName } func (AppModuleBasic) RegisterLegacyAminoCodec(cdc *codec.LegacyAmino) { types.RegisterLegacyAminoCodec(cdc) } func (AppModuleBasic) DefaultGenesis(_ codec.JSONCodec) json.RawMessage { return nil } func (AppModuleBasic) ValidateGenesis(_ codec.JSONCodec, _ client.TxEncodingConfig, _ json.RawMessage) error { return nil } func (AppModuleBasic) RegisterGRPCGatewayRoutes(clientCtx client.Context, mux *runtime.ServeMux) { if err := types.RegisterQueryHandlerClient(context.Background(), mux, types.NewQueryClient(clientCtx)); err != nil { panic(err) } } func (AppModuleBasic) GetTxCmd() *cobra.Command { return cli.NewTxCmd() } func (AppModuleBasic) GetQueryCmd() *cobra.Command { return cli.GetQueryCmd() } func (AppModuleBasic) RegisterInterfaces(registry codectypes.InterfaceRegistry) { types.RegisterInterfaces(registry) } type AppModule struct { AppModuleBasic gk *keeper.GraphKeeper ik *keeper.IndexKeeper ak authkeeper.AccountKeeper bk *cyberbankkeeper.IndexedKeeper bm *bandwidthkeeper.BandwidthMeter } func NewAppModule( cdc codec.Codec, graphKeeper *keeper.GraphKeeper, indexKeeper *keeper.IndexKeeper, accountKeeper authkeeper.AccountKeeper, bankKeeper *cyberbankkeeper.IndexedKeeper, bandwidthKeeper *bandwidthkeeper.BandwidthMeter, ) AppModule { return AppModule{ AppModuleBasic: AppModuleBasic{cdc: cdc}, gk: graphKeeper, ik: indexKeeper, ak: accountKeeper, bk: bankKeeper, bm: bandwidthKeeper, } } func (AppModule) Name() string { return types.ModuleName } func (am AppModule) RegisterInvariants(_ sdk.InvariantRegistry) {} func (am AppModule) RegisterServices(cfg module.Configurator) { types.RegisterMsgServer(cfg.MsgServer(), keeper.NewMsgServerImpl(am.gk, am.ik, am.ak, am.bk, am.bm)) types.RegisterQueryServer(cfg.QueryServer(), am.gk) } func (am AppModule) InitGenesis(ctx sdk.Context, _ codec.JSONCodec, _ json.RawMessage) []abci.ValidatorUpdate { _ = keeper.InitGenesis(ctx, *am.gk, am.ik) return []abci.ValidatorUpdate{} } func (am AppModule) ExportGenesis(ctx sdk.Context, _ codec.JSONCodec) json.RawMessage { err := keeper.WriteGenesis(ctx, *am.gk, am.ik) if err != nil { panic(err) } return nil } func (am AppModule) ConsensusVersion() uint64 { return 1 } func (am AppModule) BeginBlock(_ sdk.Context, _ abci.RequestBeginBlock) {} func (am AppModule) EndBlock(ctx sdk.Context, _ abci.RequestEndBlock) []abci.ValidatorUpdate { EndBlocker(ctx, am.gk, am.ik) return []abci.ValidatorUpdate{} } ================================================ FILE: x/graph/types/codec.go ================================================ package types import ( "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/codec/legacy" "github.com/cosmos/cosmos-sdk/codec/types" cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/msgservice" authzcodec "github.com/cosmos/cosmos-sdk/x/authz/codec" govcodec "github.com/cosmos/cosmos-sdk/x/gov/codec" ) func RegisterLegacyAminoCodec(cdc *codec.LegacyAmino) { legacy.RegisterAminoMsg(cdc, &MsgCyberlink{}, "cyber/MsgCyberlink") } func RegisterInterfaces(registry types.InterfaceRegistry) { registry.RegisterImplementations((*sdk.Msg)(nil), &MsgCyberlink{}, ) msgservice.RegisterMsgServiceDesc(registry, &_Msg_serviceDesc) } var ( amino = codec.NewLegacyAmino() ModuleCdc = codec.NewAminoCodec(amino) ) func init() { RegisterLegacyAminoCodec(amino) cryptocodec.RegisterCrypto(amino) sdk.RegisterLegacyAminoCodec(amino) RegisterLegacyAminoCodec(authzcodec.Amino) RegisterLegacyAminoCodec(govcodec.Amino) } ================================================ FILE: x/graph/types/compact_link.go ================================================ package types import ( "encoding/binary" "github.com/cybercongress/go-cyber/v7/types" ) type CompactLink struct { From uint64 To uint64 Account uint64 } type LinkFilter func(CompactLink) bool func NewLink(from CidNumber, to CidNumber, acc types.AccNumber) CompactLink { return CompactLink{ From: uint64(from), To: uint64(to), Account: uint64(acc), } } func UnmarshalBinaryLink(b []byte) CompactLink { return NewLink( CidNumber(binary.LittleEndian.Uint64(b[0:8])), CidNumber(binary.LittleEndian.Uint64(b[8:16])), types.AccNumber(binary.LittleEndian.Uint64(b[16:24])), ) } func (l CompactLink) MarshalBinaryLink() []byte { b := make([]byte, 24) binary.LittleEndian.PutUint64(b[0:8], l.From) binary.LittleEndian.PutUint64(b[8:16], l.To) binary.LittleEndian.PutUint64(b[16:24], l.Account) return b } ================================================ FILE: x/graph/types/cyberlinks.go ================================================ package types import "github.com/cybercongress/go-cyber/v7/types" // map of map, where first key is cid, second key is account.String() // second map is used as set for fast contains check type ( Links map[CidNumber]CidLinks CidLinks map[CidNumber]map[types.AccNumber]struct{} ) type ( Cid string CidNumber uint64 ) func (links Links) Put(from CidNumber, to CidNumber, acc types.AccNumber) { cidLinks := links[from] if cidLinks == nil { cidLinks = make(CidLinks) } users := cidLinks[to] if users == nil { users = make(map[types.AccNumber]struct{}) } users[acc] = struct{}{} cidLinks[to] = users links[from] = cidLinks } func (links Links) PutAll(newLinks Links) { for from := range newLinks { for to := range newLinks[from] { for u := range newLinks[from][to] { links.Put(from, to, u) } } } } func (links Links) Copy() Links { linksCopy := make(Links, len(links)) for from := range links { fromLinks := make(CidLinks, len(links[from])) for to := range links[from] { users := make(map[types.AccNumber]struct{}, len(links[from][to])) for u := range links[from][to] { users[u] = struct{}{} } fromLinks[to] = users } linksCopy[from] = fromLinks } return linksCopy } func (links Links) IsAnyLinkExist(from CidNumber, to CidNumber) bool { toLinks, fromExists := links[from] if fromExists { linkAccs, toExists := toLinks[to] if toExists && len(linkAccs) != 0 { return true } } return false } func (links Links) IsLinkExist(from CidNumber, to CidNumber, acc types.AccNumber) bool { toLinks, fromExists := links[from] if fromExists { linkAccs, toExists := toLinks[to] if toExists && len(linkAccs) != 0 { _, exists := linkAccs[acc] return exists } } return false } ================================================ FILE: x/graph/types/errors.go ================================================ package types import ( errorsmod "cosmossdk.io/errors" ) var ( ErrCyberlinkExist = errorsmod.Register(ModuleName, 2, "your cyberlink already exists") ErrZeroLinks = errorsmod.Register(ModuleName, 3, "cyberlinks not found") ErrSelfLink = errorsmod.Register(ModuleName, 4, "loop cyberlink not allowed") ErrInvalidParticle = errorsmod.Register(ModuleName, 5, "invalid particle") ErrCidNotFound = errorsmod.Register(ModuleName, 6, "particle not found") ErrCidVersion = errorsmod.Register(ModuleName, 7, "unsupported cid version") ErrZeroPower = errorsmod.Register(ModuleName, 8, "neuron has zero power") ) ================================================ FILE: x/graph/types/events.go ================================================ package types const ( EventTypeCyberlink = "cyberlink" AttributeKeyParticleFrom = "particleFrom" AttributeKeyParticleTo = "particleTo" AttributeKeyNeuron = "neuron" AttributeValueCategory = ModuleName ) ================================================ FILE: x/graph/types/keys.go ================================================ package types import ( sdk "github.com/cosmos/cosmos-sdk/types" ) const ( ModuleName = "graph" RouterKey = ModuleName StoreKey = ModuleName TStoreKey = "transient_index" ) var ( GlobalStoreKeyPrefix = []byte{0x00} CidStoreKeyPrefix = []byte{0x01} CidReverseStoreKeyPrefix = []byte{0x02} CyberlinkStoreKeyPrefix = []byte{0x03} CyberlinkTStoreKeyPrefix = []byte{0x04} // inter-block cache for cyberlinks NeudegStoreKeyPrefix = []byte{0x05} NeudegTStoreKeyPrefix = []byte{0x06} // inter-block cache for neurons cyberlink' degree LastCidNumber = append(GlobalStoreKeyPrefix, []byte("lastParticleNumber")...) LinksCount = append(GlobalStoreKeyPrefix, []byte("cyberlinksAmount")...) HasNewLinks = append(GlobalStoreKeyPrefix, []byte("blockHasNewLinks")...) BurnedVolts = append(GlobalStoreKeyPrefix, []byte("burnedVolts")...) BurnedAmperes = append(GlobalStoreKeyPrefix, []byte("burnedAmperes")...) ) func CidStoreKey(cid Cid) []byte { return append(CidStoreKeyPrefix, []byte(cid)...) } func CidReverseStoreKey(num CidNumber) []byte { return append(CidReverseStoreKeyPrefix, sdk.Uint64ToBigEndian(uint64(num))...) } func CyberlinksStoreKey(linkKey []byte) []byte { return append(CyberlinkStoreKeyPrefix, linkKey...) } func CyberlinksTStoreKey(link []byte) []byte { return append(CyberlinkTStoreKeyPrefix, link...) } func NeudegStoreKey(accNumber uint64) []byte { return append(NeudegStoreKeyPrefix, sdk.Uint64ToBigEndian(accNumber)...) } func NeudegTStoreKey(accNumber uint64) []byte { return append(NeudegTStoreKeyPrefix, sdk.Uint64ToBigEndian(accNumber)...) } func CyberlinkRawKey(link CompactLink) []byte { keyAsBytes := make([]byte, 24) copy(keyAsBytes[0:8], sdk.Uint64ToBigEndian(link.From)) copy(keyAsBytes[8:16], sdk.Uint64ToBigEndian(link.Account)) copy(keyAsBytes[16:24], sdk.Uint64ToBigEndian(link.To)) return keyAsBytes } ================================================ FILE: x/graph/types/msgs.go ================================================ package types import ( sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" "github.com/ipfs/go-cid" ) const ( TypeMsgCyberlink = "cyberlink" ) var _ sdk.Msg = &MsgCyberlink{} func NewMsgCyberlink(address sdk.AccAddress, links []Link) *MsgCyberlink { return &MsgCyberlink{ Neuron: address.String(), Links: links, } } func (msg MsgCyberlink) Route() string { return RouterKey } func (msg MsgCyberlink) Type() string { return TypeMsgCyberlink } func (msg MsgCyberlink) GetSigners() []sdk.AccAddress { addr, _ := sdk.AccAddressFromBech32(msg.Neuron) return []sdk.AccAddress{addr} } func (msg MsgCyberlink) GetSignBytes() []byte { return sdk.MustSortJSON(ModuleCdc.MustMarshalJSON(&msg)) } func (msg MsgCyberlink) ValidateBasic() error { _, err := sdk.AccAddressFromBech32(msg.Neuron) if err != nil { return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "Invalid neuron address: %s", err) } if len(msg.Links) == 0 { return ErrZeroLinks } filter := make(CidsFilter) for _, link := range msg.Links { if link.From == link.To { return ErrSelfLink } fromCid, err := cid.Decode(link.From) if err != nil { return ErrInvalidParticle } if fromCid.Version() != 0 { return ErrCidVersion } toCid, err := cid.Decode(link.To) if err != nil { return ErrInvalidParticle } if toCid.Version() != 0 { return ErrCidVersion } if filter.Contains(Cid(link.From), Cid(link.To)) { return ErrCyberlinkExist } filter.Put(Cid(link.From), Cid(link.To)) } return nil } ================================================ FILE: x/graph/types/particles_filter.go ================================================ package types type CidsFilter map[Cid]map[Cid]struct{} func (cf CidsFilter) Put(from Cid, to Cid) { cidLinks := cf[from] if cidLinks == nil { cidLinks = make(map[Cid]struct{}) } cidLinks[to] = struct{}{} cf[from] = cidLinks } func (cf CidsFilter) Contains(from Cid, to Cid) bool { cidLinks := cf[from] if cidLinks == nil { return false } _, contains := cidLinks[to] return contains } ================================================ FILE: x/graph/types/querier.go ================================================ package types const ( QueryGraphStats = "graph_stats" ) ================================================ FILE: x/graph/types/query.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: cyber/graph/v1beta1/query.proto package types import ( context "context" fmt "fmt" grpc1 "github.com/cosmos/gogoproto/grpc" proto "github.com/cosmos/gogoproto/proto" _ "google.golang.org/genproto/googleapis/api/annotations" grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" io "io" math "math" math_bits "math/bits" ) // Reference imports to suppress errors if they are not otherwise used. var _ = proto.Marshal var _ = fmt.Errorf var _ = math.Inf // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package type QueryGraphStatsRequest struct { } func (m *QueryGraphStatsRequest) Reset() { *m = QueryGraphStatsRequest{} } func (m *QueryGraphStatsRequest) String() string { return proto.CompactTextString(m) } func (*QueryGraphStatsRequest) ProtoMessage() {} func (*QueryGraphStatsRequest) Descriptor() ([]byte, []int) { return fileDescriptor_1588f994db3ad35c, []int{0} } func (m *QueryGraphStatsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryGraphStatsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryGraphStatsRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryGraphStatsRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryGraphStatsRequest.Merge(m, src) } func (m *QueryGraphStatsRequest) XXX_Size() int { return m.Size() } func (m *QueryGraphStatsRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryGraphStatsRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryGraphStatsRequest proto.InternalMessageInfo type QueryGraphStatsResponse struct { Cyberlinks uint64 `protobuf:"varint,1,opt,name=cyberlinks,proto3" json:"cyberlinks,omitempty"` Particles uint64 `protobuf:"varint,2,opt,name=particles,proto3" json:"particles,omitempty"` } func (m *QueryGraphStatsResponse) Reset() { *m = QueryGraphStatsResponse{} } func (m *QueryGraphStatsResponse) String() string { return proto.CompactTextString(m) } func (*QueryGraphStatsResponse) ProtoMessage() {} func (*QueryGraphStatsResponse) Descriptor() ([]byte, []int) { return fileDescriptor_1588f994db3ad35c, []int{1} } func (m *QueryGraphStatsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryGraphStatsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryGraphStatsResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryGraphStatsResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryGraphStatsResponse.Merge(m, src) } func (m *QueryGraphStatsResponse) XXX_Size() int { return m.Size() } func (m *QueryGraphStatsResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryGraphStatsResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryGraphStatsResponse proto.InternalMessageInfo func (m *QueryGraphStatsResponse) GetCyberlinks() uint64 { if m != nil { return m.Cyberlinks } return 0 } func (m *QueryGraphStatsResponse) GetParticles() uint64 { if m != nil { return m.Particles } return 0 } type QueryBurnStatsRequest struct { } func (m *QueryBurnStatsRequest) Reset() { *m = QueryBurnStatsRequest{} } func (m *QueryBurnStatsRequest) String() string { return proto.CompactTextString(m) } func (*QueryBurnStatsRequest) ProtoMessage() {} func (*QueryBurnStatsRequest) Descriptor() ([]byte, []int) { return fileDescriptor_1588f994db3ad35c, []int{2} } func (m *QueryBurnStatsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryBurnStatsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryBurnStatsRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryBurnStatsRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryBurnStatsRequest.Merge(m, src) } func (m *QueryBurnStatsRequest) XXX_Size() int { return m.Size() } func (m *QueryBurnStatsRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryBurnStatsRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryBurnStatsRequest proto.InternalMessageInfo type QueryBurnStatsResponse struct { Millivolt uint64 `protobuf:"varint,1,opt,name=millivolt,proto3" json:"millivolt,omitempty"` Milliampere uint64 `protobuf:"varint,2,opt,name=milliampere,proto3" json:"milliampere,omitempty"` } func (m *QueryBurnStatsResponse) Reset() { *m = QueryBurnStatsResponse{} } func (m *QueryBurnStatsResponse) String() string { return proto.CompactTextString(m) } func (*QueryBurnStatsResponse) ProtoMessage() {} func (*QueryBurnStatsResponse) Descriptor() ([]byte, []int) { return fileDescriptor_1588f994db3ad35c, []int{3} } func (m *QueryBurnStatsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryBurnStatsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryBurnStatsResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryBurnStatsResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryBurnStatsResponse.Merge(m, src) } func (m *QueryBurnStatsResponse) XXX_Size() int { return m.Size() } func (m *QueryBurnStatsResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryBurnStatsResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryBurnStatsResponse proto.InternalMessageInfo func (m *QueryBurnStatsResponse) GetMillivolt() uint64 { if m != nil { return m.Millivolt } return 0 } func (m *QueryBurnStatsResponse) GetMilliampere() uint64 { if m != nil { return m.Milliampere } return 0 } func init() { proto.RegisterType((*QueryGraphStatsRequest)(nil), "cyber.graph.v1beta1.QueryGraphStatsRequest") proto.RegisterType((*QueryGraphStatsResponse)(nil), "cyber.graph.v1beta1.QueryGraphStatsResponse") proto.RegisterType((*QueryBurnStatsRequest)(nil), "cyber.graph.v1beta1.QueryBurnStatsRequest") proto.RegisterType((*QueryBurnStatsResponse)(nil), "cyber.graph.v1beta1.QueryBurnStatsResponse") } func init() { proto.RegisterFile("cyber/graph/v1beta1/query.proto", fileDescriptor_1588f994db3ad35c) } var fileDescriptor_1588f994db3ad35c = []byte{ // 361 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x52, 0xc1, 0x4e, 0x2a, 0x31, 0x14, 0xa5, 0xe4, 0x3d, 0x13, 0xea, 0xae, 0x46, 0x21, 0x84, 0x14, 0x9c, 0x8d, 0x44, 0x74, 0x1a, 0xf4, 0x0f, 0xd8, 0x18, 0x97, 0xe2, 0x42, 0xe3, 0xc6, 0x74, 0x26, 0xcd, 0xd0, 0x38, 0xb4, 0xa5, 0xed, 0x10, 0xd9, 0xba, 0x37, 0xd1, 0xf8, 0x19, 0xfe, 0x88, 0x4b, 0x12, 0x37, 0x2e, 0x0d, 0xf8, 0x21, 0x86, 0x4e, 0x23, 0xa8, 0x63, 0xc2, 0xf2, 0x9e, 0x7b, 0xee, 0x39, 0xe7, 0xde, 0x16, 0x36, 0xe3, 0x49, 0xc4, 0x34, 0x49, 0x34, 0x55, 0x03, 0x32, 0xee, 0x46, 0xcc, 0xd2, 0x2e, 0x19, 0x65, 0x4c, 0x4f, 0x42, 0xa5, 0xa5, 0x95, 0x68, 0xcb, 0x11, 0x42, 0x47, 0x08, 0x3d, 0xa1, 0xde, 0x48, 0xa4, 0x4c, 0x52, 0x46, 0xa8, 0xe2, 0x84, 0x0a, 0x21, 0x2d, 0xb5, 0x5c, 0x0a, 0x93, 0x8f, 0x04, 0x35, 0xb8, 0x73, 0xb6, 0x50, 0x38, 0x59, 0xcc, 0x9c, 0x5b, 0x6a, 0x4d, 0x9f, 0x8d, 0x32, 0x66, 0x6c, 0x70, 0x01, 0xab, 0xbf, 0x3a, 0x46, 0x49, 0x61, 0x18, 0xc2, 0x10, 0x3a, 0xa7, 0x94, 0x8b, 0x1b, 0x53, 0x03, 0x2d, 0xd0, 0xfe, 0xd7, 0x5f, 0x41, 0x50, 0x03, 0x56, 0x14, 0xd5, 0x96, 0xc7, 0x29, 0x33, 0xb5, 0xb2, 0x6b, 0x2f, 0x81, 0xa0, 0x0a, 0xb7, 0x9d, 0x70, 0x2f, 0xd3, 0xe2, 0x9b, 0xe3, 0xa5, 0xcf, 0xb2, 0xd2, 0xf0, 0x86, 0x0d, 0x58, 0x19, 0xf2, 0x34, 0xe5, 0x63, 0x99, 0x5a, 0xef, 0xb7, 0x04, 0x50, 0x0b, 0x6e, 0xba, 0x82, 0x0e, 0x15, 0xd3, 0xcc, 0x1b, 0xae, 0x42, 0x47, 0xcf, 0x65, 0xf8, 0xdf, 0x49, 0xa3, 0x47, 0x00, 0xe1, 0x72, 0x23, 0xd4, 0x09, 0x0b, 0x4e, 0x16, 0x16, 0x5f, 0xa4, 0x7e, 0xb0, 0x1e, 0x39, 0xcf, 0x1c, 0xb4, 0xef, 0x5e, 0x3f, 0x9e, 0xca, 0x01, 0x6a, 0x91, 0xa2, 0x67, 0x73, 0xd5, 0xb5, 0x71, 0x21, 0xee, 0x01, 0xac, 0x7c, 0xed, 0x8c, 0xf6, 0xff, 0x76, 0xf9, 0x79, 0xb1, 0x7a, 0x67, 0x2d, 0xae, 0x0f, 0xb4, 0xe7, 0x02, 0xed, 0xa2, 0x66, 0x61, 0xa0, 0x28, 0xd3, 0x22, 0xcf, 0xd3, 0x3b, 0x7d, 0x99, 0x61, 0x30, 0x9d, 0x61, 0xf0, 0x3e, 0xc3, 0xe0, 0x61, 0x8e, 0x4b, 0xd3, 0x39, 0x2e, 0xbd, 0xcd, 0x71, 0xe9, 0x8a, 0x24, 0xdc, 0x0e, 0xb2, 0x28, 0x8c, 0xe5, 0x30, 0x17, 0x89, 0xa5, 0x48, 0x34, 0x33, 0x86, 0x24, 0xf2, 0x30, 0x57, 0xbd, 0xf5, 0xba, 0x76, 0xa2, 0x98, 0x89, 0x36, 0xdc, 0x2f, 0x3b, 0xfe, 0x0c, 0x00, 0x00, 0xff, 0xff, 0x55, 0x5d, 0xaf, 0x89, 0xbb, 0x02, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. var _ context.Context var _ grpc.ClientConn // This is a compile-time assertion to ensure that this generated file // is compatible with the grpc package it is being compiled against. const _ = grpc.SupportPackageIsVersion4 // QueryClient is the client API for Query service. // // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. type QueryClient interface { GraphStats(ctx context.Context, in *QueryGraphStatsRequest, opts ...grpc.CallOption) (*QueryGraphStatsResponse, error) BurnStats(ctx context.Context, in *QueryBurnStatsRequest, opts ...grpc.CallOption) (*QueryBurnStatsResponse, error) } type queryClient struct { cc grpc1.ClientConn } func NewQueryClient(cc grpc1.ClientConn) QueryClient { return &queryClient{cc} } func (c *queryClient) GraphStats(ctx context.Context, in *QueryGraphStatsRequest, opts ...grpc.CallOption) (*QueryGraphStatsResponse, error) { out := new(QueryGraphStatsResponse) err := c.cc.Invoke(ctx, "/cyber.graph.v1beta1.Query/GraphStats", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) BurnStats(ctx context.Context, in *QueryBurnStatsRequest, opts ...grpc.CallOption) (*QueryBurnStatsResponse, error) { out := new(QueryBurnStatsResponse) err := c.cc.Invoke(ctx, "/cyber.graph.v1beta1.Query/BurnStats", in, out, opts...) if err != nil { return nil, err } return out, nil } // QueryServer is the server API for Query service. type QueryServer interface { GraphStats(context.Context, *QueryGraphStatsRequest) (*QueryGraphStatsResponse, error) BurnStats(context.Context, *QueryBurnStatsRequest) (*QueryBurnStatsResponse, error) } // UnimplementedQueryServer can be embedded to have forward compatible implementations. type UnimplementedQueryServer struct { } func (*UnimplementedQueryServer) GraphStats(ctx context.Context, req *QueryGraphStatsRequest) (*QueryGraphStatsResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method GraphStats not implemented") } func (*UnimplementedQueryServer) BurnStats(ctx context.Context, req *QueryBurnStatsRequest) (*QueryBurnStatsResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method BurnStats not implemented") } func RegisterQueryServer(s grpc1.Server, srv QueryServer) { s.RegisterService(&_Query_serviceDesc, srv) } func _Query_GraphStats_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryGraphStatsRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).GraphStats(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.graph.v1beta1.Query/GraphStats", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).GraphStats(ctx, req.(*QueryGraphStatsRequest)) } return interceptor(ctx, in, info, handler) } func _Query_BurnStats_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryBurnStatsRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).BurnStats(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.graph.v1beta1.Query/BurnStats", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).BurnStats(ctx, req.(*QueryBurnStatsRequest)) } return interceptor(ctx, in, info, handler) } var _Query_serviceDesc = grpc.ServiceDesc{ ServiceName: "cyber.graph.v1beta1.Query", HandlerType: (*QueryServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "GraphStats", Handler: _Query_GraphStats_Handler, }, { MethodName: "BurnStats", Handler: _Query_BurnStats_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "cyber/graph/v1beta1/query.proto", } func (m *QueryGraphStatsRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryGraphStatsRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryGraphStatsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *QueryGraphStatsResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryGraphStatsResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryGraphStatsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.Particles != 0 { i = encodeVarintQuery(dAtA, i, uint64(m.Particles)) i-- dAtA[i] = 0x10 } if m.Cyberlinks != 0 { i = encodeVarintQuery(dAtA, i, uint64(m.Cyberlinks)) i-- dAtA[i] = 0x8 } return len(dAtA) - i, nil } func (m *QueryBurnStatsRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryBurnStatsRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryBurnStatsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *QueryBurnStatsResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryBurnStatsResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryBurnStatsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.Milliampere != 0 { i = encodeVarintQuery(dAtA, i, uint64(m.Milliampere)) i-- dAtA[i] = 0x10 } if m.Millivolt != 0 { i = encodeVarintQuery(dAtA, i, uint64(m.Millivolt)) i-- dAtA[i] = 0x8 } return len(dAtA) - i, nil } func encodeVarintQuery(dAtA []byte, offset int, v uint64) int { offset -= sovQuery(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *QueryGraphStatsRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *QueryGraphStatsResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.Cyberlinks != 0 { n += 1 + sovQuery(uint64(m.Cyberlinks)) } if m.Particles != 0 { n += 1 + sovQuery(uint64(m.Particles)) } return n } func (m *QueryBurnStatsRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *QueryBurnStatsResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.Millivolt != 0 { n += 1 + sovQuery(uint64(m.Millivolt)) } if m.Milliampere != 0 { n += 1 + sovQuery(uint64(m.Milliampere)) } return n } func sovQuery(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozQuery(x uint64) (n int) { return sovQuery(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *QueryGraphStatsRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryGraphStatsRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryGraphStatsRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryGraphStatsResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryGraphStatsResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryGraphStatsResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field Cyberlinks", wireType) } m.Cyberlinks = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.Cyberlinks |= uint64(b&0x7F) << shift if b < 0x80 { break } } case 2: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field Particles", wireType) } m.Particles = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.Particles |= uint64(b&0x7F) << shift if b < 0x80 { break } } default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryBurnStatsRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryBurnStatsRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryBurnStatsRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryBurnStatsResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryBurnStatsResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryBurnStatsResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field Millivolt", wireType) } m.Millivolt = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.Millivolt |= uint64(b&0x7F) << shift if b < 0x80 { break } } case 2: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field Milliampere", wireType) } m.Milliampere = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.Milliampere |= uint64(b&0x7F) << shift if b < 0x80 { break } } default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipQuery(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowQuery } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowQuery } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowQuery } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthQuery } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupQuery } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthQuery } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthQuery = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowQuery = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupQuery = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/graph/types/query.pb.gw.go ================================================ // Code generated by protoc-gen-grpc-gateway. DO NOT EDIT. // source: cyber/graph/v1beta1/query.proto /* Package types is a reverse proxy. It translates gRPC into RESTful JSON APIs. */ package types import ( "context" "io" "net/http" "github.com/golang/protobuf/descriptor" "github.com/golang/protobuf/proto" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/grpc-ecosystem/grpc-gateway/utilities" "google.golang.org/grpc" "google.golang.org/grpc/codes" "google.golang.org/grpc/grpclog" "google.golang.org/grpc/metadata" "google.golang.org/grpc/status" ) // Suppress "imported and not used" errors var _ codes.Code var _ io.Reader var _ status.Status var _ = runtime.String var _ = utilities.NewDoubleArray var _ = descriptor.ForMessage var _ = metadata.Join func request_Query_GraphStats_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryGraphStatsRequest var metadata runtime.ServerMetadata msg, err := client.GraphStats(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_GraphStats_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryGraphStatsRequest var metadata runtime.ServerMetadata msg, err := server.GraphStats(ctx, &protoReq) return msg, metadata, err } func request_Query_BurnStats_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryBurnStatsRequest var metadata runtime.ServerMetadata msg, err := client.BurnStats(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_BurnStats_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryBurnStatsRequest var metadata runtime.ServerMetadata msg, err := server.BurnStats(ctx, &protoReq) return msg, metadata, err } // RegisterQueryHandlerServer registers the http handlers for service Query to "mux". // UnaryRPC :call QueryServer directly. // StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. // Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterQueryHandlerFromEndpoint instead. func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, server QueryServer) error { mux.Handle("GET", pattern_Query_GraphStats_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_GraphStats_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_GraphStats_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_BurnStats_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_BurnStats_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_BurnStats_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) return nil } // RegisterQueryHandlerFromEndpoint is same as RegisterQueryHandler but // automatically dials to "endpoint" and closes the connection when "ctx" gets done. func RegisterQueryHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error) { conn, err := grpc.Dial(endpoint, opts...) if err != nil { return err } defer func() { if err != nil { if cerr := conn.Close(); cerr != nil { grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr) } return } go func() { <-ctx.Done() if cerr := conn.Close(); cerr != nil { grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr) } }() }() return RegisterQueryHandler(ctx, mux, conn) } // RegisterQueryHandler registers the http handlers for service Query to "mux". // The handlers forward requests to the grpc endpoint over "conn". func RegisterQueryHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error { return RegisterQueryHandlerClient(ctx, mux, NewQueryClient(conn)) } // RegisterQueryHandlerClient registers the http handlers for service Query // to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "QueryClient". // Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "QueryClient" // doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in // "QueryClient" to call the correct interceptors. func RegisterQueryHandlerClient(ctx context.Context, mux *runtime.ServeMux, client QueryClient) error { mux.Handle("GET", pattern_Query_GraphStats_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_GraphStats_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_GraphStats_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_BurnStats_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_BurnStats_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_BurnStats_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) return nil } var ( pattern_Query_GraphStats_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"cyber", "graph", "v1beta1", "graph_stats"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_BurnStats_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"cyber", "graph", "v1beta1", "burn_stats"}, "", runtime.AssumeColonVerbOpt(false))) ) var ( forward_Query_GraphStats_0 = runtime.ForwardResponseMessage forward_Query_BurnStats_0 = runtime.ForwardResponseMessage ) ================================================ FILE: x/graph/types/tx.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: cyber/graph/v1beta1/tx.proto package types import ( context "context" fmt "fmt" io "io" math "math" math_bits "math/bits" _ "github.com/cosmos/gogoproto/gogoproto" grpc1 "github.com/cosmos/gogoproto/grpc" proto "github.com/cosmos/gogoproto/proto" grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" ) // Reference imports to suppress errors if they are not otherwise used. var ( _ = proto.Marshal _ = fmt.Errorf _ = math.Inf ) // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package type MsgCyberlink struct { Neuron string `protobuf:"bytes,1,opt,name=neuron,proto3" json:"neuron,omitempty"` Links []Link `protobuf:"bytes,2,rep,name=links,proto3" json:"links"` } func (m *MsgCyberlink) Reset() { *m = MsgCyberlink{} } func (m *MsgCyberlink) String() string { return proto.CompactTextString(m) } func (*MsgCyberlink) ProtoMessage() {} func (*MsgCyberlink) Descriptor() ([]byte, []int) { return fileDescriptor_39ffdb6b83edbf38, []int{0} } func (m *MsgCyberlink) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgCyberlink) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgCyberlink.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgCyberlink) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgCyberlink.Merge(m, src) } func (m *MsgCyberlink) XXX_Size() int { return m.Size() } func (m *MsgCyberlink) XXX_DiscardUnknown() { xxx_messageInfo_MsgCyberlink.DiscardUnknown(m) } var xxx_messageInfo_MsgCyberlink proto.InternalMessageInfo type MsgCyberlinkResponse struct{} func (m *MsgCyberlinkResponse) Reset() { *m = MsgCyberlinkResponse{} } func (m *MsgCyberlinkResponse) String() string { return proto.CompactTextString(m) } func (*MsgCyberlinkResponse) ProtoMessage() {} func (*MsgCyberlinkResponse) Descriptor() ([]byte, []int) { return fileDescriptor_39ffdb6b83edbf38, []int{1} } func (m *MsgCyberlinkResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgCyberlinkResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgCyberlinkResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgCyberlinkResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgCyberlinkResponse.Merge(m, src) } func (m *MsgCyberlinkResponse) XXX_Size() int { return m.Size() } func (m *MsgCyberlinkResponse) XXX_DiscardUnknown() { xxx_messageInfo_MsgCyberlinkResponse.DiscardUnknown(m) } var xxx_messageInfo_MsgCyberlinkResponse proto.InternalMessageInfo func init() { proto.RegisterType((*MsgCyberlink)(nil), "cyber.graph.v1beta1.MsgCyberlink") proto.RegisterType((*MsgCyberlinkResponse)(nil), "cyber.graph.v1beta1.MsgCyberlinkResponse") } func init() { proto.RegisterFile("cyber/graph/v1beta1/tx.proto", fileDescriptor_39ffdb6b83edbf38) } var fileDescriptor_39ffdb6b83edbf38 = []byte{ // 270 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0x49, 0xae, 0x4c, 0x4a, 0x2d, 0xd2, 0x4f, 0x2f, 0x4a, 0x2c, 0xc8, 0xd0, 0x2f, 0x33, 0x4c, 0x4a, 0x2d, 0x49, 0x34, 0xd4, 0x2f, 0xa9, 0xd0, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x06, 0xcb, 0xea, 0x81, 0x65, 0xf5, 0xa0, 0xb2, 0x52, 0x22, 0xe9, 0xf9, 0xe9, 0xf9, 0x60, 0x79, 0x7d, 0x10, 0x0b, 0xa2, 0x54, 0x4a, 0x1e, 0xab, 0x41, 0x95, 0x05, 0xa9, 0xc5, 0x10, 0x05, 0x4a, 0xe9, 0x5c, 0x3c, 0xbe, 0xc5, 0xe9, 0xce, 0x20, 0x55, 0x39, 0x99, 0x79, 0xd9, 0x42, 0x62, 0x5c, 0x6c, 0x79, 0xa9, 0xa5, 0x45, 0xf9, 0x79, 0x12, 0x8c, 0x0a, 0x8c, 0x1a, 0x9c, 0x41, 0x50, 0x9e, 0x90, 0x29, 0x17, 0x2b, 0x48, 0xbe, 0x58, 0x82, 0x49, 0x81, 0x59, 0x83, 0xdb, 0x48, 0x52, 0x0f, 0x8b, 0x1b, 0xf4, 0x7c, 0x32, 0xf3, 0xb2, 0x9d, 0x58, 0x4e, 0xdc, 0x93, 0x67, 0x08, 0x82, 0xa8, 0xb6, 0xe2, 0xe8, 0x58, 0x20, 0xcf, 0xf0, 0x62, 0x81, 0x3c, 0x83, 0x92, 0x18, 0x97, 0x08, 0xb2, 0x45, 0x41, 0xa9, 0xc5, 0x05, 0xf9, 0x79, 0xc5, 0xa9, 0x46, 0x09, 0x5c, 0xcc, 0xbe, 0xc5, 0xe9, 0x42, 0x91, 0x5c, 0x9c, 0x08, 0x47, 0x28, 0x62, 0x35, 0x1d, 0x59, 0xbb, 0x94, 0x26, 0x41, 0x25, 0x30, 0x1b, 0x9c, 0x3c, 0x4f, 0x3c, 0x92, 0x63, 0xbc, 0xf0, 0x48, 0x8e, 0xf1, 0xc1, 0x23, 0x39, 0xc6, 0x09, 0x8f, 0xe5, 0x18, 0x2e, 0x3c, 0x96, 0x63, 0xb8, 0xf1, 0x58, 0x8e, 0x21, 0x4a, 0x3f, 0x3d, 0xb3, 0x24, 0xa3, 0x34, 0x49, 0x2f, 0x39, 0x3f, 0x57, 0x1f, 0x6c, 0x5c, 0x72, 0x7e, 0x5e, 0x7a, 0x51, 0x6a, 0x71, 0xb1, 0x7e, 0x7a, 0xbe, 0x2e, 0x24, 0xe4, 0x2a, 0xa0, 0x61, 0x07, 0x0e, 0xb3, 0x24, 0x36, 0x70, 0xa0, 0x19, 0x03, 0x02, 0x00, 0x00, 0xff, 0xff, 0x06, 0xfa, 0xf1, 0xe3, 0xa0, 0x01, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. var ( _ context.Context _ grpc.ClientConn ) // This is a compile-time assertion to ensure that this generated file // is compatible with the grpc package it is being compiled against. const _ = grpc.SupportPackageIsVersion4 // MsgClient is the client API for Msg service. // // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. type MsgClient interface { Cyberlink(ctx context.Context, in *MsgCyberlink, opts ...grpc.CallOption) (*MsgCyberlinkResponse, error) } type msgClient struct { cc grpc1.ClientConn } func NewMsgClient(cc grpc1.ClientConn) MsgClient { return &msgClient{cc} } func (c *msgClient) Cyberlink(ctx context.Context, in *MsgCyberlink, opts ...grpc.CallOption) (*MsgCyberlinkResponse, error) { out := new(MsgCyberlinkResponse) err := c.cc.Invoke(ctx, "/cyber.graph.v1beta1.Msg/Cyberlink", in, out, opts...) if err != nil { return nil, err } return out, nil } // MsgServer is the server API for Msg service. type MsgServer interface { Cyberlink(context.Context, *MsgCyberlink) (*MsgCyberlinkResponse, error) } // UnimplementedMsgServer can be embedded to have forward compatible implementations. type UnimplementedMsgServer struct{} func (*UnimplementedMsgServer) Cyberlink(ctx context.Context, req *MsgCyberlink) (*MsgCyberlinkResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method Cyberlink not implemented") } func RegisterMsgServer(s grpc1.Server, srv MsgServer) { s.RegisterService(&_Msg_serviceDesc, srv) } func _Msg_Cyberlink_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgCyberlink) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(MsgServer).Cyberlink(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.graph.v1beta1.Msg/Cyberlink", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).Cyberlink(ctx, req.(*MsgCyberlink)) } return interceptor(ctx, in, info, handler) } var _Msg_serviceDesc = grpc.ServiceDesc{ ServiceName: "cyber.graph.v1beta1.Msg", HandlerType: (*MsgServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "Cyberlink", Handler: _Msg_Cyberlink_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "cyber/graph/v1beta1/tx.proto", } func (m *MsgCyberlink) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgCyberlink) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgCyberlink) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.Links) > 0 { for iNdEx := len(m.Links) - 1; iNdEx >= 0; iNdEx-- { { size, err := m.Links[iNdEx].MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintTx(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 } } if len(m.Neuron) > 0 { i -= len(m.Neuron) copy(dAtA[i:], m.Neuron) i = encodeVarintTx(dAtA, i, uint64(len(m.Neuron))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *MsgCyberlinkResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgCyberlinkResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgCyberlinkResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func encodeVarintTx(dAtA []byte, offset int, v uint64) int { offset -= sovTx(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *MsgCyberlink) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Neuron) if l > 0 { n += 1 + l + sovTx(uint64(l)) } if len(m.Links) > 0 { for _, e := range m.Links { l = e.Size() n += 1 + l + sovTx(uint64(l)) } } return n } func (m *MsgCyberlinkResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func sovTx(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozTx(x uint64) (n int) { return sovTx(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *MsgCyberlink) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgCyberlink: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgCyberlink: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Neuron", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Neuron = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Links", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Links = append(m.Links, Link{}) if err := m.Links[len(m.Links)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgCyberlinkResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgCyberlinkResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgCyberlinkResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipTx(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTx } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTx } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTx } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthTx } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupTx } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthTx } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthTx = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowTx = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupTx = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/graph/types/types.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: cyber/graph/v1beta1/types.proto package types import ( fmt "fmt" io "io" math "math" math_bits "math/bits" _ "github.com/cosmos/gogoproto/gogoproto" proto "github.com/cosmos/gogoproto/proto" ) // Reference imports to suppress errors if they are not otherwise used. var ( _ = proto.Marshal _ = fmt.Errorf _ = math.Inf ) // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package type Link struct { From string `protobuf:"bytes,1,opt,name=from,proto3" json:"from,omitempty"` To string `protobuf:"bytes,2,opt,name=to,proto3" json:"to,omitempty"` } func (m *Link) Reset() { *m = Link{} } func (m *Link) String() string { return proto.CompactTextString(m) } func (*Link) ProtoMessage() {} func (*Link) Descriptor() ([]byte, []int) { return fileDescriptor_71ff86aea4c7c827, []int{0} } func (m *Link) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *Link) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_Link.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *Link) XXX_Merge(src proto.Message) { xxx_messageInfo_Link.Merge(m, src) } func (m *Link) XXX_Size() int { return m.Size() } func (m *Link) XXX_DiscardUnknown() { xxx_messageInfo_Link.DiscardUnknown(m) } var xxx_messageInfo_Link proto.InternalMessageInfo func init() { proto.RegisterType((*Link)(nil), "cyber.graph.v1beta1.Link") } func init() { proto.RegisterFile("cyber/graph/v1beta1/types.proto", fileDescriptor_71ff86aea4c7c827) } var fileDescriptor_71ff86aea4c7c827 = []byte{ // 195 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0x4f, 0xae, 0x4c, 0x4a, 0x2d, 0xd2, 0x4f, 0x2f, 0x4a, 0x2c, 0xc8, 0xd0, 0x2f, 0x33, 0x4c, 0x4a, 0x2d, 0x49, 0x34, 0xd4, 0x2f, 0xa9, 0x2c, 0x48, 0x2d, 0xd6, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x06, 0x2b, 0xd0, 0x03, 0x2b, 0xd0, 0x83, 0x2a, 0x90, 0x12, 0x49, 0xcf, 0x4f, 0xcf, 0x07, 0xcb, 0xeb, 0x83, 0x58, 0x10, 0xa5, 0x4a, 0x26, 0x5c, 0x2c, 0x3e, 0x99, 0x79, 0xd9, 0x42, 0x42, 0x5c, 0x2c, 0x69, 0x45, 0xf9, 0xb9, 0x12, 0x8c, 0x0a, 0x8c, 0x1a, 0x9c, 0x41, 0x60, 0xb6, 0x10, 0x1f, 0x17, 0x53, 0x49, 0xbe, 0x04, 0x13, 0x58, 0x84, 0xa9, 0x24, 0xdf, 0x8a, 0xa3, 0x63, 0x81, 0x3c, 0xc3, 0x8b, 0x05, 0xf2, 0x0c, 0x4e, 0x9e, 0x27, 0x1e, 0xc9, 0x31, 0x5e, 0x78, 0x24, 0xc7, 0xf8, 0xe0, 0x91, 0x1c, 0xe3, 0x84, 0xc7, 0x72, 0x0c, 0x17, 0x1e, 0xcb, 0x31, 0xdc, 0x78, 0x2c, 0xc7, 0x10, 0xa5, 0x9f, 0x9e, 0x59, 0x92, 0x51, 0x9a, 0xa4, 0x97, 0x9c, 0x9f, 0xab, 0x0f, 0x76, 0x45, 0x72, 0x7e, 0x5e, 0x7a, 0x51, 0x6a, 0x71, 0xb1, 0x7e, 0x7a, 0xbe, 0x2e, 0xc4, 0xdd, 0x15, 0x50, 0x97, 0x83, 0x5d, 0x9c, 0xc4, 0x06, 0x76, 0x87, 0x31, 0x20, 0x00, 0x00, 0xff, 0xff, 0x2c, 0x2d, 0xc4, 0xc5, 0xd5, 0x00, 0x00, 0x00, } func (m *Link) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *Link) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *Link) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.To) > 0 { i -= len(m.To) copy(dAtA[i:], m.To) i = encodeVarintTypes(dAtA, i, uint64(len(m.To))) i-- dAtA[i] = 0x12 } if len(m.From) > 0 { i -= len(m.From) copy(dAtA[i:], m.From) i = encodeVarintTypes(dAtA, i, uint64(len(m.From))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func encodeVarintTypes(dAtA []byte, offset int, v uint64) int { offset -= sovTypes(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *Link) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.From) if l > 0 { n += 1 + l + sovTypes(uint64(l)) } l = len(m.To) if l > 0 { n += 1 + l + sovTypes(uint64(l)) } return n } func sovTypes(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozTypes(x uint64) (n int) { return sovTypes(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *Link) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: Link: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: Link: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field From", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTypes } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTypes } if postIndex > l { return io.ErrUnexpectedEOF } m.From = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field To", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTypes } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTypes } if postIndex > l { return io.ErrUnexpectedEOF } m.To = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTypes(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTypes } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipTypes(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTypes } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTypes } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTypes } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthTypes } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupTypes } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthTypes } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthTypes = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowTypes = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupTypes = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/graph/wasm/interface.go ================================================ package wasm import ( "encoding/json" errorsmod "cosmossdk.io/errors" wasmvmtypes "github.com/CosmWasm/wasmvm/types" authkeeper "github.com/cosmos/cosmos-sdk/x/auth/keeper" pluginstypes "github.com/cybercongress/go-cyber/v7/plugins/types" bandwidthkeeper "github.com/cybercongress/go-cyber/v7/x/bandwidth/keeper" cyberbankkeeper "github.com/cybercongress/go-cyber/v7/x/cyberbank/keeper" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/graph/keeper" ) type Messenger struct { gk *keeper.GraphKeeper ik *keeper.IndexKeeper ak *authkeeper.AccountKeeper bk *cyberbankkeeper.IndexedKeeper bm *bandwidthkeeper.BandwidthMeter } func NewMessenger( gk *keeper.GraphKeeper, ik *keeper.IndexKeeper, ak *authkeeper.AccountKeeper, bk *cyberbankkeeper.IndexedKeeper, bm *bandwidthkeeper.BandwidthMeter, ) *Messenger { return &Messenger{ gk, ik, ak, bk, bm, } } func (m *Messenger) HandleMsg(ctx sdk.Context, contractAddr sdk.AccAddress, contractIBCPortID string, msg pluginstypes.CyberMsg) ([]sdk.Event, [][]byte, error) { switch { case msg.Cyberlink != nil: if msg.Cyberlink.Neuron != contractAddr.String() { return nil, nil, wasmvmtypes.InvalidRequest{Err: "cyberlink wrong neuron"} } msgServer := keeper.NewMsgServerImpl(m.gk, m.ik, *m.ak, m.bk, m.bm) if err := msg.Cyberlink.ValidateBasic(); err != nil { return nil, nil, errorsmod.Wrap(err, "failed validating msg") } res, err := msgServer.Cyberlink( sdk.WrapSDKContext(ctx), msg.Cyberlink, ) if err != nil { return nil, nil, errorsmod.Wrap(err, "cyberlink msg") } responseBytes, err := json.Marshal(*res) if err != nil { return nil, nil, errorsmod.Wrap(err, "failed to serialize cyberlink response") } resp := [][]byte{responseBytes} return nil, resp, nil default: return nil, nil, pluginstypes.ErrHandleMsg } } type Querier struct { *keeper.GraphKeeper } func NewWasmQuerier(keeper *keeper.GraphKeeper) *Querier { return &Querier{keeper} } func (querier *Querier) HandleQuery(ctx sdk.Context, query pluginstypes.CyberQuery) ([]byte, error) { switch { case query.GraphStats != nil: res, err := querier.GraphKeeper.GraphStats(ctx, query.GraphStats) if err != nil { return nil, errorsmod.Wrap(err, "failed to get graph stats") } responseBytes, err := json.Marshal(res) if err != nil { return nil, errorsmod.Wrap(err, "failed to serialize graph stats response") } return responseBytes, nil default: return nil, pluginstypes.ErrHandleQuery } } ================================================ FILE: x/grid/client/cli/query.go ================================================ package cli import ( "context" "fmt" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/spf13/cobra" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cybercongress/go-cyber/v7/x/grid/types" ) func GetQueryCmd() *cobra.Command { queryCmd := &cobra.Command{ Use: types.ModuleName, Short: fmt.Sprintf("Querying commands for the %s module", types.ModuleName), DisableFlagParsing: true, SuggestionsMinimumDistance: 2, RunE: client.ValidateCmd, } queryCmd.AddCommand( GetCmdQueryParams(), GetCmdQuerySourceRoutes(), GetCmdQueryDestinationRoutes(), GetCmdQuerySourceRoutedEnergy(), GetCmdQueryDestinationRoutedEnergy(), GetCmdQueryRoute(), GetCmdQueryRoutes(), ) return queryCmd } func GetCmdQueryParams() *cobra.Command { cmd := &cobra.Command{ Use: "params", Short: "Query the current grid module parameters information", Args: cobra.NoArgs, RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientQueryContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) res, err := queryClient.Params( context.Background(), &types.QueryParamsRequest{}, ) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } func GetCmdQuerySourceRoutes() *cobra.Command { cmd := &cobra.Command{ Use: "routes-from [source]", Short: "Query all grid routes that made from source account", Args: cobra.ExactArgs(1), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientQueryContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) src, err := sdk.AccAddressFromBech32(args[0]) if err != nil { return err } res, err := queryClient.SourceRoutes( context.Background(), &types.QuerySourceRequest{Source: src.String()}, ) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } func GetCmdQueryDestinationRoutes() *cobra.Command { cmd := &cobra.Command{ Use: "routes-to [destination]", Short: "Query all grid routes that routed to destination account", Args: cobra.ExactArgs(1), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientQueryContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) dst, err := sdk.AccAddressFromBech32(args[0]) if err != nil { return err } res, err := queryClient.DestinationRoutes( context.Background(), &types.QueryDestinationRequest{Destination: dst.String()}, ) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } func GetCmdQuerySourceRoutedEnergy() *cobra.Command { cmd := &cobra.Command{ Use: "routed-from [source]", Short: "Query grid value that routed from source account", Args: cobra.ExactArgs(1), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientQueryContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) src, err := sdk.AccAddressFromBech32(args[0]) if err != nil { return err } res, err := queryClient.SourceRoutedEnergy( context.Background(), &types.QuerySourceRequest{Source: src.String()}, ) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } func GetCmdQueryDestinationRoutedEnergy() *cobra.Command { cmd := &cobra.Command{ Use: "routed-to [destination]", Short: "Query grid value that routed to destination account", Args: cobra.ExactArgs(1), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientQueryContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) dst, err := sdk.AccAddressFromBech32(args[0]) if err != nil { return err } res, err := queryClient.DestinationRoutedEnergy( context.Background(), &types.QueryDestinationRequest{Destination: dst.String()}, ) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } func GetCmdQueryRoute() *cobra.Command { cmd := &cobra.Command{ Use: "route [source] [destination]", Short: "Query grid route that routes for given source and destination accounts", Args: cobra.ExactArgs(2), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientQueryContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) src, err := sdk.AccAddressFromBech32(args[0]) if err != nil { return err } dst, err := sdk.AccAddressFromBech32(args[1]) if err != nil { return err } res, err := queryClient.Route( context.Background(), &types.QueryRouteRequest{ Source: src.String(), Destination: dst.String(), }, ) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } func GetCmdQueryRoutes() *cobra.Command { cmd := &cobra.Command{ Use: "routes", Short: "Query all grid routes", Args: cobra.ExactArgs(0), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientQueryContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) pageReq, err := client.ReadPageRequest(cmd.Flags()) if err != nil { return err } res, err := queryClient.Routes( context.Background(), &types.QueryRoutesRequest{ Pagination: pageReq, }, ) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } ================================================ FILE: x/grid/client/cli/tx.go ================================================ package cli import ( "fmt" "github.com/cosmos/cosmos-sdk/client/tx" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/spf13/cobra" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cybercongress/go-cyber/v7/x/grid/types" ) // GetTxCmd returns the transaction commands for this module func NewTxCmd() *cobra.Command { txCmd := &cobra.Command{ Use: types.ModuleName, Short: fmt.Sprintf("%s transactions subcommands", types.ModuleName), DisableFlagParsing: true, SuggestionsMinimumDistance: 2, RunE: client.ValidateCmd, } txCmd.AddCommand( GetCmdCreateRoute(), GetCmdEditRoute(), GetCmdDeleteRoute(), GetCmdEditRouteName(), ) return txCmd } func GetCmdCreateRoute() *cobra.Command { cmd := &cobra.Command{ Use: "create-route [destination] [name]", Args: cobra.ExactArgs(2), Short: "Create grid route from your address to destination address with provided name", RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientTxContext(cmd) if err != nil { return err } src := clientCtx.GetFromAddress() dst, err := sdk.AccAddressFromBech32(args[0]) if err != nil { return err } msg := types.NewMsgCreateRoute(src, dst, args[1]) err = msg.ValidateBasic() if err != nil { return err } return tx.GenerateOrBroadcastTxCLI(clientCtx, cmd.Flags(), msg) }, } flags.AddTxFlagsToCmd(cmd) return cmd } func GetCmdEditRoute() *cobra.Command { cmd := &cobra.Command{ Use: "edit-route [destination] [value]", Args: cobra.ExactArgs(2), Short: "Set value of grid route to destination address", RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientTxContext(cmd) if err != nil { return err } amount, err := sdk.ParseCoinNormalized(args[1]) if err != nil { return err } src := clientCtx.GetFromAddress() dst, err := sdk.AccAddressFromBech32(args[0]) if err != nil { return err } msg := types.NewMsgEditRoute(src, dst, amount) err = msg.ValidateBasic() if err != nil { return err } return tx.GenerateOrBroadcastTxCLI(clientCtx, cmd.Flags(), msg) }, } flags.AddTxFlagsToCmd(cmd) return cmd } func GetCmdDeleteRoute() *cobra.Command { cmd := &cobra.Command{ Use: "delete-route [destination]", Args: cobra.ExactArgs(1), Short: "Delete your grid route to given destination address", RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientTxContext(cmd) if err != nil { return err } src := clientCtx.GetFromAddress() dst, err := sdk.AccAddressFromBech32(args[0]) if err != nil { return err } msg := types.NewMsgDeleteRoute(src, dst) err = msg.ValidateBasic() if err != nil { return err } return tx.GenerateOrBroadcastTxCLI(clientCtx, cmd.Flags(), msg) }, } flags.AddTxFlagsToCmd(cmd) return cmd } func GetCmdEditRouteName() *cobra.Command { cmd := &cobra.Command{ Use: "edit-route-name [destination] [name]", Args: cobra.ExactArgs(2), Short: "Edit name of grid route to given destination address", RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientTxContext(cmd) if err != nil { return err } src := clientCtx.GetFromAddress() dst, err := sdk.AccAddressFromBech32(args[0]) if err != nil { return err } msg := types.NewMsgEditRouteName(src, dst, args[1]) err = msg.ValidateBasic() if err != nil { return err } return tx.GenerateOrBroadcastTxCLI(clientCtx, cmd.Flags(), msg) }, } flags.AddTxFlagsToCmd(cmd) return cmd } ================================================ FILE: x/grid/exported/exported.go ================================================ package exported import ( sdk "github.com/cosmos/cosmos-sdk/types" paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" ) type EnergyKeeper interface { GetRoutedToEnergy(ctx sdk.Context, delegate sdk.AccAddress) sdk.Coins } type ( ParamSet = paramtypes.ParamSet // Subspace defines an interface that implements the legacy x/params Subspace // type. // // NOTE: This is used solely for migration of x/params managed parameters. Subspace interface { GetParamSet(ctx sdk.Context, ps ParamSet) } ) ================================================ FILE: x/grid/keeper/genesis.go ================================================ package keeper import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/grid/types" ) func InitGenesis(ctx sdk.Context, k Keeper, data types.GenesisState) { // TODO check EnergyGrid balance aggregated value on genesis if err := k.SetParams(ctx, data.Params); err != nil { panic(err) } err := k.SetRoutes(ctx, data.Routes) if err != nil { panic(err) } } func ExportGenesis(ctx sdk.Context, k Keeper) *types.GenesisState { params := k.GetParams(ctx) //routes := k.GetAllRoutes(ctx) // Create an empty slice of types.Route var routes []types.Route return types.NewGenesisState(params, routes) } ================================================ FILE: x/grid/keeper/grpc_query.go ================================================ package keeper import ( "context" "github.com/cosmos/cosmos-sdk/store/prefix" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/query" "google.golang.org/grpc/codes" "google.golang.org/grpc/status" "github.com/cybercongress/go-cyber/v7/x/grid/types" ) var _ types.QueryServer = Keeper{} func (k Keeper) Params(goCtx context.Context, _ *types.QueryParamsRequest) (*types.QueryParamsResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) params := k.GetParams(ctx) return &types.QueryParamsResponse{Params: params}, nil } func (k Keeper) SourceRoutes(goCtx context.Context, request *types.QuerySourceRequest) (*types.QueryRoutesResponse, error) { if request == nil { return nil, status.Errorf(codes.InvalidArgument, "empty request") } if request.Source == "" { return nil, status.Errorf(codes.InvalidArgument, "source address cannot be empty") } addr, err := sdk.AccAddressFromBech32(request.Source) if err != nil { return nil, err } ctx := sdk.UnwrapSDKContext(goCtx) routes := k.GetSourceRoutes(ctx, addr, 16) return &types.QueryRoutesResponse{Routes: routes}, nil } // DestinationRoutes TODO add pagination func (k Keeper) DestinationRoutes(goCtx context.Context, request *types.QueryDestinationRequest) (*types.QueryRoutesResponse, error) { if request == nil { return nil, status.Errorf(codes.InvalidArgument, "empty request") } if request.Destination == "" { return nil, status.Errorf(codes.InvalidArgument, "destination address cannot be empty") } addr, err := sdk.AccAddressFromBech32(request.Destination) if err != nil { return nil, err } ctx := sdk.UnwrapSDKContext(goCtx) routes := k.GetDestinationRoutes(ctx, addr) return &types.QueryRoutesResponse{Routes: routes}, nil } func (k Keeper) DestinationRoutedEnergy(goCtx context.Context, request *types.QueryDestinationRequest) (*types.QueryRoutedEnergyResponse, error) { if request == nil { return nil, status.Errorf(codes.InvalidArgument, "empty request") } if request.Destination == "" { return nil, status.Errorf(codes.InvalidArgument, "destination address cannot be empty") } addr, err := sdk.AccAddressFromBech32(request.Destination) if err != nil { return nil, err } ctx := sdk.UnwrapSDKContext(goCtx) routedEnergy := k.GetRoutedToEnergy(ctx, addr) return &types.QueryRoutedEnergyResponse{Value: routedEnergy}, nil } func (k Keeper) SourceRoutedEnergy(goCtx context.Context, request *types.QuerySourceRequest) (*types.QueryRoutedEnergyResponse, error) { if request == nil { return nil, status.Errorf(codes.InvalidArgument, "empty request") } if request.Source == "" { return nil, status.Errorf(codes.InvalidArgument, "source address cannot be empty") } addr, err := sdk.AccAddressFromBech32(request.Source) if err != nil { return nil, err } ctx := sdk.UnwrapSDKContext(goCtx) routedEnergy := k.GetRoutedFromEnergy(ctx, addr) return &types.QueryRoutedEnergyResponse{Value: routedEnergy}, nil } func (k Keeper) Route(goCtx context.Context, request *types.QueryRouteRequest) (*types.QueryRouteResponse, error) { if request == nil { return nil, status.Errorf(codes.InvalidArgument, "empty request") } if request.Source == "" { return nil, status.Errorf(codes.InvalidArgument, "source address cannot be empty") } if request.Destination == "" { return nil, status.Errorf(codes.InvalidArgument, "destination address cannot be empty") } src, err := sdk.AccAddressFromBech32(request.Source) if err != nil { return nil, err } dst, err := sdk.AccAddressFromBech32(request.Destination) if err != nil { return nil, err } ctx := sdk.UnwrapSDKContext(goCtx) route, found := k.GetRoute(ctx, src, dst) if !found { return nil, status.Errorf( codes.NotFound, "route with source %s and destination %s not found", request.Source, request.Destination) } return &types.QueryRouteResponse{Route: route}, nil } func (k Keeper) Routes(goCtx context.Context, request *types.QueryRoutesRequest) (*types.QueryRoutesResponse, error) { if request == nil { return nil, status.Errorf(codes.InvalidArgument, "empty request") } if request.Pagination == nil { return nil, status.Errorf(codes.InvalidArgument, "pagination cannot be empty") } ctx := sdk.UnwrapSDKContext(goCtx) var routes types.Routes store := ctx.KVStore(k.storeKey) routesStore := prefix.NewStore(store, types.RouteKey) pageRes, err := query.Paginate(routesStore, request.Pagination, func(key []byte, value []byte) error { route, err := types.UnmarshalRoute(k.cdc, value) if err != nil { return err } routes = append(routes, route) return nil }) if err != nil { return nil, status.Error(codes.Internal, err.Error()) } return &types.QueryRoutesResponse{Routes: routes, Pagination: pageRes}, nil } ================================================ FILE: x/grid/keeper/keeper.go ================================================ package keeper import ( "fmt" storetypes "github.com/cosmos/cosmos-sdk/store/types" "github.com/cometbft/cometbft/libs/log" "github.com/cosmos/cosmos-sdk/telemetry" ctypes "github.com/cybercongress/go-cyber/v7/types" "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/grid/exported" "github.com/cybercongress/go-cyber/v7/x/grid/types" ) var _ = exported.EnergyKeeper(nil) type Keeper struct { storeKey storetypes.StoreKey cdc codec.BinaryCodec accountKeeper types.AccountKeeper proxyKeeper types.CyberbankKeeper authority string } func NewKeeper( cdc codec.BinaryCodec, key storetypes.StoreKey, bk types.CyberbankKeeper, ak types.AccountKeeper, authority string, ) Keeper { if addr := ak.GetModuleAddress(types.GridPoolName); addr == nil { panic(fmt.Sprintf("%s module account has not been set", types.GridPoolName)) } keeper := Keeper{ storeKey: key, cdc: cdc, proxyKeeper: bk, accountKeeper: ak, authority: authority, } return keeper } // GetAuthority returns the x/mint module's authority. func (k Keeper) GetAuthority() string { return k.authority } func (k Keeper) Logger(ctx sdk.Context) log.Logger { return ctx.Logger().With("module", fmt.Sprintf("x/%s", types.ModuleName)) } func (k Keeper) SetParams(ctx sdk.Context, p types.Params) error { if err := p.Validate(); err != nil { return err } store := ctx.KVStore(k.storeKey) bz := k.cdc.MustMarshal(&p) store.Set(types.ParamsKey, bz) return nil } func (k Keeper) GetParams(ctx sdk.Context) (p types.Params) { store := ctx.KVStore(k.storeKey) bz := store.Get(types.ParamsKey) if bz == nil { return p } k.cdc.MustUnmarshal(bz, &p) return p } func (k Keeper) CreateEnergyRoute(ctx sdk.Context, src, dst sdk.AccAddress, name string) error { if src.Equals(dst) { return types.ErrSelfRoute } _, found := k.GetRoute(ctx, src, dst) if found { return types.ErrRouteExist } routes := k.GetSourceRoutes(ctx, src, k.MaxSourceRoutes(ctx)) if uint32(len(routes)) == k.MaxSourceRoutes(ctx) { return types.ErrMaxRoutes } acc := k.accountKeeper.GetAccount(ctx, dst) if acc == nil { acc = k.accountKeeper.NewAccountWithAddress(ctx, dst) k.accountKeeper.SetAccount(ctx, acc) } k.SetRoute(ctx, src, dst, types.NewRoute(src, dst, name, sdk.Coins{})) k.proxyKeeper.OnCoinsTransfer(ctx, nil, dst) return nil } func (k Keeper) EditEnergyRoute(ctx sdk.Context, src, dst sdk.AccAddress, value sdk.Coin) error { defer telemetry.IncrCounter(1.0, types.ModuleName, "grid routed") route, found := k.GetRoute(ctx, src, dst) if !found { return types.ErrRouteNotExist } energy := k.GetRoutedToEnergy(ctx, dst) if !route.Value.IsValid() { coins := sdk.NewCoins(value) if err := k.proxyKeeper.SendCoinsFromAccountToModule(ctx, src, types.GridPoolName, coins); err != nil { return err } k.SetRoutedEnergy(ctx, dst, sdk.NewCoins(value)) } else { if value.Amount.GT(route.Value.AmountOf(value.Denom)) { diff := sdk.NewCoin(value.Denom, value.Amount.Sub(route.Value.AmountOf(value.Denom))) coins := sdk.NewCoins(diff) if err := k.proxyKeeper.SendCoinsFromAccountToModule(ctx, src, types.GridPoolName, coins); err != nil { return err // should never happen } k.SetRoutedEnergy(ctx, dst, energy.Sort().Add(diff)) } else { diff := sdk.NewCoin(value.Denom, route.Value.AmountOf(value.Denom).Sub(value.Amount)) coins := sdk.NewCoins(diff) if err := k.proxyKeeper.SendCoinsFromModuleToAccount(ctx, types.GridPoolName, src, coins); err != nil { return err // should never happen } k.SetRoutedEnergy(ctx, dst, energy.Sort().Sub(coins...)) } } ampers := route.Value.AmountOf(ctypes.AMPERE) volts := route.Value.AmountOf(ctypes.VOLT) var newValues sdk.Coins if value.Denom == ctypes.VOLT { newValues = sdk.NewCoins(value, sdk.NewCoin(ctypes.AMPERE, ampers)) } else { newValues = sdk.NewCoins(sdk.NewCoin(ctypes.VOLT, volts), value) } k.SetRoute(ctx, src, dst, types.NewRoute(src, dst, route.Name, newValues.Sort())) k.proxyKeeper.OnCoinsTransfer(ctx, src, dst) return nil } func (k Keeper) DeleteEnergyRoute(ctx sdk.Context, src, dst sdk.AccAddress) error { route, found := k.GetRoute(ctx, src, dst) if !found { return types.ErrRouteNotExist } if err := k.proxyKeeper.SendCoinsFromModuleToAccount(ctx, types.GridPoolName, src, route.Value); err != nil { return err // should never happen } energy := k.GetRoutedToEnergy(ctx, dst) k.SetRoutedEnergy(ctx, dst, energy.Sub(route.Value...)) k.RemoveRoute(ctx, src, dst) k.proxyKeeper.OnCoinsTransfer(ctx, src, dst) return nil } func (k Keeper) EditEnergyRouteName(ctx sdk.Context, src, dst sdk.AccAddress, name string) error { route, found := k.GetRoute(ctx, src, dst) if !found { return types.ErrRouteNotExist } k.SetRoute(ctx, src, dst, types.NewRoute(src, dst, name, route.Value)) return nil } func (k Keeper) SetRoutes(ctx sdk.Context, routes types.Routes) error { // TODO add check that source and destinations addresses already exist for _, route := range routes { src, err := sdk.AccAddressFromBech32(route.Source) if err != nil { return err } dst, err := sdk.AccAddressFromBech32(route.Destination) if err != nil { return err } energy := k.GetRoutedToEnergy(ctx, dst) if !energy.IsValid() { k.SetRoutedEnergy(ctx, dst, route.Value) } else { k.SetRoutedEnergy(ctx, dst, energy.Add(route.Value...)) } k.SetRoute(ctx, src, dst, types.NewRoute(src, dst, route.Name, route.Value)) k.proxyKeeper.OnCoinsTransfer(ctx, src, dst) } return nil } func (k Keeper) MaxSourceRoutes(ctx sdk.Context) (res uint32) { return k.GetParams(ctx).MaxRoutes } func (k Keeper) SetRoute(ctx sdk.Context, src, dst sdk.AccAddress, route types.Route) { store := ctx.KVStore(k.storeKey) store.Set(types.GetRouteKey(src, dst), types.MustMarshalRoute(k.cdc, route)) } func (k Keeper) RemoveRoute(ctx sdk.Context, src, dst sdk.AccAddress) { store := ctx.KVStore(k.storeKey) store.Delete(types.GetRouteKey(src, dst)) } func (k Keeper) SetRoutedEnergy(ctx sdk.Context, dst sdk.AccAddress, amount sdk.Coins) { store := ctx.KVStore(k.storeKey) value := types.NewValue(amount) store.Set(types.GetRoutedEnergyByDestinationKey(dst), k.cdc.MustMarshal(&value)) } func (k Keeper) GetRoute(ctx sdk.Context, src, dst sdk.AccAddress) (route types.Route, found bool) { store := ctx.KVStore(k.storeKey) key := types.GetRouteKey(src, dst) value := store.Get(key) if value == nil { return route, false } route = types.MustUnmarshalRoute(k.cdc, value) return route, true } func (k Keeper) GetAllRoutes(ctx sdk.Context) (routes []types.Route) { k.IterateAllRoutes(ctx, func(route types.Route) bool { routes = append(routes, route) return false }) return routes } // Deprecated: enable after debug with empty routes func (k Keeper) IterateAllRoutes(ctx sdk.Context, cb func(route types.Route) (stop bool)) { store := ctx.KVStore(k.storeKey) iterator := sdk.KVStorePrefixIterator(store, types.RouteKey) defer iterator.Close() for ; iterator.Valid(); iterator.Next() { route, err := types.UnmarshalRoute(k.cdc, iterator.Value()) if err != nil { // TODO fix empty case //"grid" : { // "routes" : [{ // "destination" : "", // "value" : [], // "source" : "", // "name" : "" // }], // "params" : { // "max_routes" : 16 // } //} break } if cb(route) { break } } } func (k Keeper) GetDestinationRoutes(ctx sdk.Context, dst sdk.AccAddress) (routes []types.Route) { store := ctx.KVStore(k.storeKey) iterator := sdk.KVStorePrefixIterator(store, types.RouteKey) defer iterator.Close() for ; iterator.Valid(); iterator.Next() { route := types.MustUnmarshalRoute(k.cdc, iterator.Value()) rdst, _ := sdk.AccAddressFromBech32(route.Destination) if rdst.Equals(dst) { routes = append(routes, route) } } return routes } func (k Keeper) GetSourceRoutes(ctx sdk.Context, src sdk.AccAddress, maxRetrieve uint32) (routes []types.Route) { routes = make([]types.Route, maxRetrieve) store := ctx.KVStore(k.storeKey) sourcePrefixKey := types.GetRoutesKey(src) iterator := sdk.KVStorePrefixIterator(store, sourcePrefixKey) defer iterator.Close() i := 0 for ; iterator.Valid() && i < int(maxRetrieve); iterator.Next() { route := types.MustUnmarshalRoute(k.cdc, iterator.Value()) routes[i] = route i++ } return routes[:i] // trim if the array length < maxRetrieve } func (k Keeper) GetRoutedToEnergy(ctx sdk.Context, dst sdk.AccAddress) sdk.Coins { store := ctx.KVStore(k.storeKey) bz := store.Get(types.GetRoutedEnergyByDestinationKey(dst)) if bz == nil { return sdk.Coins{} } amount := types.Value{} k.cdc.MustUnmarshal(bz, &amount) return amount.Value } func (k Keeper) GetRoutedFromEnergy(ctx sdk.Context, src sdk.AccAddress) (amount sdk.Coins) { store := ctx.KVStore(k.storeKey) sourcePrefixKey := types.GetRoutesKey(src) iterator := sdk.KVStorePrefixIterator(store, sourcePrefixKey) amount = sdk.Coins{} defer iterator.Close() for ; iterator.Valid(); iterator.Next() { var route types.Route k.cdc.MustUnmarshal(iterator.Value(), &route) if amount.IsValid() { amount = amount.Add(route.Value...) } else { amount = route.Value } } return amount } ================================================ FILE: x/grid/keeper/migrator.go ================================================ package keeper import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/grid/exported" v2 "github.com/cybercongress/go-cyber/v7/x/grid/migrations/v2" ) // Migrator is a struct for handling in-place state migrations. type Migrator struct { keeper Keeper legacySubspace exported.Subspace } func NewMigrator(k Keeper, ss exported.Subspace) Migrator { return Migrator{ keeper: k, legacySubspace: ss, } } func (m Migrator) Migrate1to2(ctx sdk.Context) error { return v2.Migrate(ctx, ctx.KVStore(m.keeper.storeKey), m.legacySubspace, m.keeper.cdc) } ================================================ FILE: x/grid/keeper/msg_server.go ================================================ package keeper import ( "context" govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" "cosmossdk.io/errors" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/grid/types" ) type msgServer struct { Keeper } func NewMsgServerImpl( keeper Keeper, ) types.MsgServer { return &msgServer{ keeper, } } var _ types.MsgServer = msgServer{} func (k msgServer) CreateRoute(goCtx context.Context, msg *types.MsgCreateRoute) (*types.MsgCreateRouteResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) src, err := sdk.AccAddressFromBech32(msg.Source) if err != nil { return nil, err } dst, err := sdk.AccAddressFromBech32(msg.Destination) if err != nil { return nil, err } err = k.Keeper.CreateEnergyRoute(ctx, src, dst, msg.Name) if err != nil { return nil, err } ctx.EventManager().EmitEvents(sdk.Events{ sdk.NewEvent( sdk.EventTypeMessage, sdk.NewAttribute(sdk.AttributeKeyModule, types.AttributeValueCategory), sdk.NewAttribute(sdk.AttributeKeySender, msg.Source), ), sdk.NewEvent( types.EventTypeCreateRoute, sdk.NewAttribute(types.AttributeKeySource, msg.Source), sdk.NewAttribute(types.AttributeKeyDestination, msg.Destination), sdk.NewAttribute(types.AttributeKeyName, msg.Name), ), }) return &types.MsgCreateRouteResponse{}, nil } func (k msgServer) EditRoute(goCtx context.Context, msg *types.MsgEditRoute) (*types.MsgEditRouteResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) src, err := sdk.AccAddressFromBech32(msg.Source) if err != nil { return nil, err } dst, err := sdk.AccAddressFromBech32(msg.Destination) if err != nil { return nil, err } err = k.Keeper.EditEnergyRoute(ctx, src, dst, msg.Value) if err != nil { return nil, err } ctx.EventManager().EmitEvents(sdk.Events{ sdk.NewEvent( sdk.EventTypeMessage, sdk.NewAttribute(sdk.AttributeKeyModule, types.AttributeValueCategory), sdk.NewAttribute(sdk.AttributeKeySender, msg.Source), ), sdk.NewEvent( types.EventTypeEditRoute, sdk.NewAttribute(types.AttributeKeySource, msg.Source), sdk.NewAttribute(types.AttributeKeyDestination, msg.Destination), sdk.NewAttribute(types.AttributeKeyValue, msg.Value.String()), ), }) return &types.MsgEditRouteResponse{}, nil } func (k msgServer) DeleteRoute(goCtx context.Context, msg *types.MsgDeleteRoute) (*types.MsgDeleteRouteResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) src, err := sdk.AccAddressFromBech32(msg.Source) if err != nil { return nil, err } dst, err := sdk.AccAddressFromBech32(msg.Destination) if err != nil { return nil, err } err = k.Keeper.DeleteEnergyRoute(ctx, src, dst) if err != nil { return nil, err } ctx.EventManager().EmitEvents(sdk.Events{ sdk.NewEvent( sdk.EventTypeMessage, sdk.NewAttribute(sdk.AttributeKeyModule, types.AttributeValueCategory), sdk.NewAttribute(sdk.AttributeKeySender, msg.Source), ), sdk.NewEvent( types.EventTypeDeleteRoute, sdk.NewAttribute(types.AttributeKeySource, msg.Source), sdk.NewAttribute(types.AttributeKeyDestination, msg.Destination), ), }) return &types.MsgDeleteRouteResponse{}, nil } func (k msgServer) EditRouteName(goCtx context.Context, msg *types.MsgEditRouteName) (*types.MsgEditRouteNameResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) src, err := sdk.AccAddressFromBech32(msg.Source) if err != nil { return nil, err } dst, err := sdk.AccAddressFromBech32(msg.Destination) if err != nil { return nil, err } err = k.Keeper.EditEnergyRouteName(ctx, src, dst, msg.Name) if err != nil { return nil, err } ctx.EventManager().EmitEvents(sdk.Events{ sdk.NewEvent( sdk.EventTypeMessage, sdk.NewAttribute(sdk.AttributeKeyModule, types.AttributeValueCategory), sdk.NewAttribute(sdk.AttributeKeySender, msg.Source), ), sdk.NewEvent( types.EventTypeEditRouteName, sdk.NewAttribute(types.AttributeKeySource, msg.Source), sdk.NewAttribute(types.AttributeKeyDestination, msg.Destination), sdk.NewAttribute(types.AttributeKeyName, msg.Name), ), }) return &types.MsgEditRouteNameResponse{}, nil } func (server msgServer) UpdateParams(goCtx context.Context, req *types.MsgUpdateParams) (*types.MsgUpdateParamsResponse, error) { if server.authority != req.Authority { return nil, errors.Wrapf(govtypes.ErrInvalidSigner, "invalid authority; expected %s, got %s", server.authority, req.Authority) } ctx := sdk.UnwrapSDKContext(goCtx) if err := server.SetParams(ctx, req.Params); err != nil { return nil, err } return &types.MsgUpdateParamsResponse{}, nil } ================================================ FILE: x/grid/migrations/v2/migrate.go ================================================ package v2 import ( "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/grid/exported" "github.com/cybercongress/go-cyber/v7/x/grid/types" ) func Migrate( ctx sdk.Context, store sdk.KVStore, legacySubspace exported.Subspace, cdc codec.BinaryCodec, ) error { var currParams types.Params legacySubspace.GetParamSet(ctx, &currParams) if err := currParams.Validate(); err != nil { return err } bz := cdc.MustMarshal(&currParams) store.Set(types.ParamsKey, bz) return nil } ================================================ FILE: x/grid/module.go ================================================ package energy import ( "context" "encoding/json" "fmt" "github.com/cosmos/cosmos-sdk/client" codectypes "github.com/cosmos/cosmos-sdk/codec/types" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/spf13/cobra" abci "github.com/cometbft/cometbft/abci/types" "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" "github.com/cybercongress/go-cyber/v7/x/grid/client/cli" "github.com/cybercongress/go-cyber/v7/x/grid/exported" "github.com/cybercongress/go-cyber/v7/x/grid/keeper" "github.com/cybercongress/go-cyber/v7/x/grid/types" ) var ( _ module.AppModule = AppModule{} _ module.AppModuleBasic = AppModuleBasic{} ) type AppModuleBasic struct { cdc codec.Codec } func (AppModuleBasic) Name() string { return types.ModuleName } // RegisterLegacyAminoCodec registers the reports module's types for the given codec. func (AppModuleBasic) RegisterLegacyAminoCodec(cdc *codec.LegacyAmino) { types.RegisterLegacyAminoCodec(cdc) } func (AppModuleBasic) DefaultGenesis(cdc codec.JSONCodec) json.RawMessage { return cdc.MustMarshalJSON(types.DefaultGenesisState()) } func (AppModuleBasic) ValidateGenesis(cdc codec.JSONCodec, _ client.TxEncodingConfig, bz json.RawMessage) error { var data types.GenesisState err := cdc.UnmarshalJSON(bz, &data) if err != nil { return fmt.Errorf("failed to unmarshal %s genesis state: %w", types.ModuleName, err) } return types.ValidateGenesis(data) } func (AppModuleBasic) RegisterGRPCGatewayRoutes(clientCtx client.Context, mux *runtime.ServeMux) { if err := types.RegisterQueryHandlerClient(context.Background(), mux, types.NewQueryClient(clientCtx)); err != nil { panic(err) } } func (AppModuleBasic) GetTxCmd() *cobra.Command { return cli.NewTxCmd() } func (AppModuleBasic) GetQueryCmd() *cobra.Command { return cli.GetQueryCmd() } func (AppModuleBasic) RegisterInterfaces(registry codectypes.InterfaceRegistry) { types.RegisterInterfaces(registry) } type AppModule struct { AppModuleBasic keeper keeper.Keeper legacySubspace exported.Subspace } func NewAppModule( cdc codec.Codec, k keeper.Keeper, ss exported.Subspace, ) AppModule { return AppModule{ AppModuleBasic: AppModuleBasic{cdc: cdc}, keeper: k, legacySubspace: ss, } } func (AppModule) Name() string { return types.ModuleName } func (am AppModule) RegisterInvariants(_ sdk.InvariantRegistry) {} func (am AppModule) RegisterServices(cfg module.Configurator) { types.RegisterQueryServer(cfg.QueryServer(), am.keeper) types.RegisterMsgServer(cfg.MsgServer(), keeper.NewMsgServerImpl(am.keeper)) m := keeper.NewMigrator(am.keeper, am.legacySubspace) if err := cfg.RegisterMigration(types.ModuleName, 1, m.Migrate1to2); err != nil { panic(fmt.Sprintf("failed to migrate x/%s from version 1 to 2: %v", types.ModuleName, err)) } } func (am AppModule) InitGenesis(ctx sdk.Context, cdc codec.JSONCodec, data json.RawMessage) []abci.ValidatorUpdate { // TODO add validation of grid balance in genesis var genesisState types.GenesisState cdc.MustUnmarshalJSON(data, &genesisState) keeper.InitGenesis(ctx, am.keeper, genesisState) return []abci.ValidatorUpdate{} } func (am AppModule) ExportGenesis(ctx sdk.Context, cdc codec.JSONCodec) json.RawMessage { gs := keeper.ExportGenesis(ctx, am.keeper) return cdc.MustMarshalJSON(gs) } func (am AppModule) ConsensusVersion() uint64 { return 2 } func (am AppModule) BeginBlock(_ sdk.Context, _ abci.RequestBeginBlock) {} func (am AppModule) EndBlock(_ sdk.Context, _ abci.RequestEndBlock) []abci.ValidatorUpdate { return []abci.ValidatorUpdate{} } ================================================ FILE: x/grid/spec/00_concepts.md ================================================ # Concepts ## Routes The route is an energy route that routes Volts (changing cyberlinks bandwidth of destination) and Amperes (changing graph power of destination) to the given account. The route is consists of a source, destination, value (volts and amperes), and alias. Account or contract may only have fixed amount routes that adjust with the `MaxRoutes` parameter with network governance. ## Routing of Energy - routing of volts will increase or decrease the bandwidth of the dedicated account - onboard new neurons to a network allowing creating of cyberlinks - adjust maximum cyberlinks rate of given dedicated account - adjust maximum cyberlinks rate of a given business - adjust maximum cyberlinks rate of a given community - routing of amperes will increase or decrease graph power of dedicated account - onboard new neurons to a network allowing change ranks of knowledge graph - adjusting ranks of personal knowledge subgraph - adjusting ranks of business knowledge subgraph - adjusting ranks of community knowledge subgraph - routing of volts and amperes will change your personal balance - routed volts and amperes will be sent to the `EnergyGrid` account - routed volts and amperes will be sent back to your account from the `EnergyGrid` account ## Graph Circuits Graph circuit is a bundle of routes of a given account. The circuit allows an agent to dynamically reflect and affect what is going on in the knowledge graph. All agent's graph circuits are formed global network circuit. ## Energy Grid Energy flows through the global network's circuit and forms a global energy grid. ## Accounting While editing the route, you choose what value to SET, the target value of the route that you would like to be after messages will be applied. You will send tokens if you increase route value and will receive if decreasing. ================================================ FILE: x/grid/spec/01_api.md ================================================ # API # REST | Path | Parameters | Description | | --------------------------------------| ------------- | ------------------ | | /energy/parameters | | get module params | | /energy/{%s}/source_routes | {sourceAddress} | get routes from source | | /energy/{%s}/destination_routes | {destinationAddress}| get routes to destination | | /energy/{%s}/source_routed_energy | {sourceAddress} | get routed total energy from source | | /energy/{%s}/destination_routed_energy| {destinationAddress}| get routed total energy to destination | | /energy/route/{%s}/{%s} | {sourceAddress} and {destinationAddress} | get given route information | | /energy/routes | page and limit | get all routes | # GRPC | Path | Parameters | Description | | --------------------------------------| ------------- | ------------------ | | /cyber/energy/v1beta1/energy/params | | get module params | | /cyber/energy/v1beta1/energy/source_routes | {sourceAddress} | get routes from source | | /cyber/energy/v1beta1/energy/destination_routes | {destinationAddress}| get routes to destination | | /cyber/energy/v1beta1/energy/destination_routed_energy| {sourceAddress} | get routed total energy from source | | /cyber/energy/v1beta1/energy/source_routed_energy | {destinationAddress}| get routed total energy to destination | | /cyber/energy/v1beta1/energy/route | {sourceAddress} and {destinationAddress} | get given route information | | /cyber/energy/v1beta1/energy/routes | page and limit | get all routes ================================================ FILE: x/grid/spec/02_state.md ================================================ # State ## Route Route is used for tracking amount of volts and amperes routed to given account. Route type has the following structure: ``` type Route struct { source string // source account address, route from destination string // destination account address, route to alias string // releated alias or tag value []sdk.Coin // amount of volts and amperes in this route } ``` ## Value Value is used to store up-to-date summarized value of all routes routed to given destination. ``` type Value struct { value []sdk.Coin // amount of volts and amperes in this route } ``` ------- ## Keys - Route: `0x00 | Source | Destination -> ProtocolBuffer(Route)` - Value: `0x01 | Destination -> ProtocolBuffer(Value)` - ModuleName, RouterKey, StoreKey: `energy` - EnergyPoolName: `energy_grid` ================================================ FILE: x/grid/spec/03_state_transitions.md ================================================ # State Transitions These messages (Msg) in the energy module trigger state transitions. ``` Value may represents {V}, {A} and {A,V} Route Key-Value storage is `0x00 | Source | Destination -> ProtocolBuffer(Route)` Value Key-Value storage is `0x01 | Destination -> ProtocolBuffer(Value)` ``` ## Route creation 1. Save destination account if account not already exist in storage (sdk's account keeper) 2. Save route with given source, destination, alias and empty route value if route not already exist 3. Call `OnCoinsTransfer` cyberbank's module hook to trigger index of balances to update with destination account (not storage) ## Route set 1. If route have zero value than escrow new value into `EnergyGrid` account 2. If route have old value more than new value to set than send `SendCoinsFromModuleToAccount` from `EnergyGrid` account to source account difference between old and new values (old-new) 3. If route have old value less than new value to set than escrow with `SendCoinsFromAccountToModule` from source account to `EnergyGrid` account difference between new and old values (new-old) 4. Update routed to destination energy value (add of sub value) 5. Update route with updated value 6. Call `OnCoinsTransfer` cyberbank's module hook to trigger index of balances to update with source and destination accounts (not storage) ## Route's alias edit 1. Update route with new alias ## Route remove 1. Send `SendCoinsFromModuleToAccount` from `EnergyGrid` account to source account route value (volts and amperes) 2. Update routed to destination energy value (sub value) 3. Remove route 4. Call `OnCoinsTransfer` cyberbank's module hook to trigger index of balances to update with source and destination accounts (not storage) ## Import routes on genesis 1. Initialize or update (add) routed to destination value 2. Set route 3. Call `OnCoinsTransfer` cyberbank's module hook to trigger index of balances to update with source and destination accounts (not storage) ================================================ FILE: x/grid/spec/04_messages.md ================================================ # Messages Messages (Msg) are objects that trigger state transitions. Msgs are wrapped in transactions (Txs) that clients submit to the network. The Cosmos SDK wraps and unwraps energy module messages from transactions. ## MsgCreateRoute A route is created with zero initial value with the `MsgCreateRoute` message. ```go type MsgCreateRoute struct { source string // account address of the origin of this message destination string // account address routing to alias string // related alias or tag } ``` ### Validity Checks Validity checks are performed for MsgCreatePool messages. The transaction that is triggered with `MsgCreateRoute` fails if: - Stateless - if msg.Source is not valid address - if msg.Destination is not valid address - if msg.Alias is equal 0 or more than 32 bytes - Stateful - if route with given msg.Source and msg.Destination exist - if total amount of routes from msg.Source in store more than or equal max_routes param. ## MsgEditRoute SET value (volts or amperes) to given route with the `MsgEditRoute` message. ```go type MsgEditRoute struct { source string // account address of the origin of this message destination string // account address editing to value sdk.Coin // value volts are amperes to set } ``` Note: SET means that you are setting value of volts and amperes to be routed to. Depending of the state of the given route msg.Source will need to provide more coins (if value increased) to `EnergyGrid` or will receive coins (if value decreased) from `EnergyGrid`. ### Validity Checks Validity checks are performed for MsgEditRoute messages. The transaction that is triggered with `MsgEditRoute` fails if: - Stateless - if msg.Source is not valid address - if msg.Destination is not valid address - if msg.Value denom is not equal denoms of volts or amperes - Stateful - if Route with given msg.Source and msg.Destination not exist - if the balance of `Source` does not have enough amount of coins for `SendCoinsFromAccountToModule` to `EnergyGrid` ## MsgDeleteRoute Delete the given route with the `MsgDeleteRoute` message. ```go type MsgDeleteRoute struct { source string // account address of the origin of this message destination string // account address deleting to } ``` ### Validity Checks Validity checks are performed for MsgDeleteRoute messages. The transaction that is triggered with `MsgDeleteRoute` fails if: - Stateless - if msg.Source is not valid address - if msg.Destination is not valid address - Stateful - if Route with given msg.Source and msg.Destination not exist ## MsgEditRouteAlias SET value (volts or amperes) to given route with the `MsgEditRoute` message. ```go type MsgEditRouteAlias struct { source string // account address of the origin of this message destination string // account address editing to alias string // new related alias or tag } ``` ### Validity Checks Validity checks are performed for MsgEditRoute messages. The transaction that is triggered with `MsgEditRoute` fails if: - Stateless - if msg.Source is not valid address - if msg.Destination is not valid address - if msg.Alias is equal 0 or more than 32 bytes - Stateful - if Route with given msg.Source and msg.Destination not exist ================================================ FILE: x/grid/spec/05_events.md ================================================ # Events The energy module emits the following events: ## Msg's ### MsgCreateRoute | Type | Attribute Key | Attribute Value | | ---------------- | ------------- | ------------------ | | message | module | energy | | message | action | create_route | | create_route | source | {sourceAddress} | | create_route | destination | {destinationAddress} | | create_route | alias | {alias} | ### MsgEditRoute | Type | Attribute Key | Attribute Value | | ---------------- | ------------- | ------------------ | | message | module | energy | | message | action | edit_route | | edit_route | source | {sourceAddress} | | edit_route | destination | {destinationAddress} | | edit_route | value | {value} | ### MsgDeleteRoute | Type | Attribute Key | Attribute Value | | ---------------- | ------------- | ------------------ | | message | module | energy | | message | action | delete_route | | delete_route | source | {sourceAddress} | | delete_route | destination | {destinationAddress} | ### MsgEditRouteAlias | Type | Attribute Key | Attribute Value | | ---------------- | ------------- | ------------------ | | message | module | energy | | message | action | edit_route_alias | | edit_route_alias | source | {sourceAddress} | | edit_route_alias | destination | {destinationAddress} | | edit_route_alias | alias | {alias} | ================================================ FILE: x/grid/spec/06_params.md ================================================ # Parameters The energy module contains the following parameters: | Key | Type | Example | | ----------------------- | -------------- | ---------------------- | | MaxRoutes | uint32 | 8 | ## Max Routes Maximum total number of outgoing routes that can be stored by account and contract. ================================================ FILE: x/grid/spec/07_wasm.md ================================================ # WASM LINE In addition to the core CosmWasm functionality, the energy module bindings include ## Query support - SourceRoutes - SourceRoutedEnergy - DestinationRoutedEnergy - Route ## Messages Encoding - MsgCreateRoute - MsgEditRoute - MsgEditRouteAlias - MsgDeleteRoute -------- Hack with [cw-cyber](https://github.com/cybercongress/cw-cyber) library ================================================ FILE: x/grid/spec/08_errors.md ================================================ # Errors The energy module may return the following errors: | Type | Code | Description | | ------------------------ | ------| ---------------------------------- | | ErrWrongAlias | 2 | length of the alias isn't valid | | ErrRouteNotExist | 3 | the route isn't exist | | ErrRouteExist | 4 | the route is exist | | ErrWrongValueDenom | 5 | the denom of value isn't supported | | ErrMaxRoutes | 6 | max routes are exceeded | | ErrSelfRoute | 7 | routing to self is not allowed | ================================================ FILE: x/grid/spec/09_cli.md ================================================ # CLI ## Queries Query all energy routes that made from source account: ```bash cyber query grid routes-from [source-addr] ``` Query all energy routes that routed to destination account: ```bash cyber query grid routes-to [destination-addr] ``` Query energy value that routed from source account: ```bash cyber query grid routed-from [source-addr] ``` Query energy value that routed to destination account: ```bash cyber query grid routed-to [destination-addr] ``` Query energy route that routes for given source and destination accounts: ```bash cyber query grid route [source-addr] [destination-addr] ``` Query all energy routes (pagination flags supported): ```bash cyber query grid routes ``` ## Transactions Create energy route from your address to destination address with provided alias: ```bash cyber tx grid create-route [destination-addr] [alias] ``` Set value of energy route to destination address: ```bash cyber tx grid edit-route [destination-addr] [value] ``` Delete your energy route to given destination address: ```bash cyber tx grid delete-route [destination-addr] ``` Edit alias of energy route to given destination address: ```bash cyber tx grid edit-route-alias [destination-addr] [new-alias] ``` ================================================ FILE: x/grid/spec/README.md ================================================ # `energy` ## Abstract The energy module allows neurons to dynamically route power and bandwidth through the network. ## Contents 1. **[Concepts](00_concepts.md)** 2. **[API](01_api.md)** 3. **[State](02_state.md)** 4. **[State Transitions](03_state_transitions.md)** 5. **[Messages](04_messages.md)** 6. **[Events](05_events.md)** 7. **[Parameters](06_params.md)** 8. **[WASM](07_wasm.md)** 9. **[Errors](08_errors.md)** 10. **[CLI](09_cli.md)** ================================================ FILE: x/grid/types/codec.go ================================================ package types import ( "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/codec/legacy" codectypes "github.com/cosmos/cosmos-sdk/codec/types" cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/msgservice" authzcodec "github.com/cosmos/cosmos-sdk/x/authz/codec" govcodec "github.com/cosmos/cosmos-sdk/x/gov/codec" ) func RegisterLegacyAminoCodec(cdc *codec.LegacyAmino) { legacy.RegisterAminoMsg(cdc, &MsgCreateRoute{}, "cyber/grid/MsgCreateRoute") legacy.RegisterAminoMsg(cdc, &MsgEditRoute{}, "cyber/grid/MsgEditRoute") legacy.RegisterAminoMsg(cdc, &MsgDeleteRoute{}, "cyber/grid/MsgDeleteRoute") legacy.RegisterAminoMsg(cdc, &MsgEditRouteName{}, "cyber/grid/MsgEditRouteName") legacy.RegisterAminoMsg(cdc, &MsgUpdateParams{}, "cyber/grid/MsgUpdateParams") cdc.RegisterConcrete(Params{}, "cyber/grid/Params", nil) } func RegisterInterfaces(registry codectypes.InterfaceRegistry) { registry.RegisterImplementations((*sdk.Msg)(nil), &MsgCreateRoute{}, &MsgEditRoute{}, &MsgDeleteRoute{}, &MsgEditRouteName{}, &MsgUpdateParams{}, ) msgservice.RegisterMsgServiceDesc(registry, &_Msg_serviceDesc) } var ( amino = codec.NewLegacyAmino() ModuleCdc = codec.NewAminoCodec(amino) ) func init() { RegisterLegacyAminoCodec(amino) cryptocodec.RegisterCrypto(amino) sdk.RegisterLegacyAminoCodec(amino) RegisterLegacyAminoCodec(authzcodec.Amino) RegisterLegacyAminoCodec(govcodec.Amino) } ================================================ FILE: x/grid/types/errors.go ================================================ package types import ( errorsmod "cosmossdk.io/errors" ) var ( ErrWrongName = errorsmod.Register(ModuleName, 2, "length of the name is not valid") ErrRouteNotExist = errorsmod.Register(ModuleName, 3, "the route does not exist") ErrRouteExist = errorsmod.Register(ModuleName, 4, "the route exists") ErrWrongValueDenom = errorsmod.Register(ModuleName, 5, "the denom of value is not supported") ErrMaxRoutes = errorsmod.Register(ModuleName, 6, "max routes are exceeded") ErrSelfRoute = errorsmod.Register(ModuleName, 7, "routing to self is not allowed") ) ================================================ FILE: x/grid/types/events.go ================================================ package types const ( EventTypeCreateRoute = "create_route" EventTypeEditRoute = "edit_route" EventTypeDeleteRoute = "delete_route" EventTypeEditRouteName = "edit_route_name" AttributeKeySource = "source" AttributeKeyDestination = "destination" AttributeKeyName = "name" AttributeKeyValue = "value" AttributeValueCategory = ModuleName ) ================================================ FILE: x/grid/types/expected_keepers.go ================================================ package types import ( sdk "github.com/cosmos/cosmos-sdk/types" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" ) type CyberbankKeeper interface { OnCoinsTransfer(ctx sdk.Context, from sdk.AccAddress, to sdk.AccAddress) SendCoinsFromModuleToAccount(ctx sdk.Context, senderModule string, recipientAddr sdk.AccAddress, amt sdk.Coins) error SendCoinsFromAccountToModule(ctx sdk.Context, senderAddr sdk.AccAddress, recipientModule string, amt sdk.Coins) error } type AccountKeeper interface { GetAccount(ctx sdk.Context, addr sdk.AccAddress) authtypes.AccountI SetAccount(ctx sdk.Context, acc authtypes.AccountI) GetModuleAddress(name string) sdk.AccAddress NewAccountWithAddress(ctx sdk.Context, addr sdk.AccAddress) authtypes.AccountI } ================================================ FILE: x/grid/types/genesis.go ================================================ package types func NewGenesisState(params Params, routes []Route) *GenesisState { return &GenesisState{ Params: params, Routes: routes, } } func DefaultGenesisState() *GenesisState { return &GenesisState{ Params: DefaultParams(), } } func ValidateGenesis(state GenesisState) error { return state.Params.Validate() } ================================================ FILE: x/grid/types/genesis.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: cyber/grid/v1beta1/genesis.proto package types import ( fmt "fmt" io "io" math "math" math_bits "math/bits" _ "github.com/cosmos/gogoproto/gogoproto" proto "github.com/cosmos/gogoproto/proto" ) // Reference imports to suppress errors if they are not otherwise used. var ( _ = proto.Marshal _ = fmt.Errorf _ = math.Inf ) // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package type GenesisState struct { Params Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params"` Routes Routes `protobuf:"bytes,2,rep,name=routes,proto3,castrepeated=Routes" json:"routes"` } func (m *GenesisState) Reset() { *m = GenesisState{} } func (m *GenesisState) String() string { return proto.CompactTextString(m) } func (*GenesisState) ProtoMessage() {} func (*GenesisState) Descriptor() ([]byte, []int) { return fileDescriptor_e1ab9a0f068eb924, []int{0} } func (m *GenesisState) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *GenesisState) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_GenesisState.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *GenesisState) XXX_Merge(src proto.Message) { xxx_messageInfo_GenesisState.Merge(m, src) } func (m *GenesisState) XXX_Size() int { return m.Size() } func (m *GenesisState) XXX_DiscardUnknown() { xxx_messageInfo_GenesisState.DiscardUnknown(m) } var xxx_messageInfo_GenesisState proto.InternalMessageInfo func (m *GenesisState) GetParams() Params { if m != nil { return m.Params } return Params{} } func (m *GenesisState) GetRoutes() Routes { if m != nil { return m.Routes } return nil } func init() { proto.RegisterType((*GenesisState)(nil), "cyber.grid.v1beta1.GenesisState") } func init() { proto.RegisterFile("cyber/grid/v1beta1/genesis.proto", fileDescriptor_e1ab9a0f068eb924) } var fileDescriptor_e1ab9a0f068eb924 = []byte{ // 244 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x48, 0xae, 0x4c, 0x4a, 0x2d, 0xd2, 0x4f, 0x2f, 0xca, 0x4c, 0xd1, 0x2f, 0x33, 0x4c, 0x4a, 0x2d, 0x49, 0x34, 0xd4, 0x4f, 0x4f, 0xcd, 0x4b, 0x2d, 0xce, 0x2c, 0xd6, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x02, 0xab, 0xd0, 0x03, 0xa9, 0xd0, 0x83, 0xaa, 0x90, 0x12, 0x49, 0xcf, 0x4f, 0xcf, 0x07, 0x4b, 0xeb, 0x83, 0x58, 0x10, 0x95, 0x52, 0x72, 0x58, 0xcc, 0x2a, 0xa9, 0x2c, 0x48, 0x85, 0x9a, 0xa4, 0xd4, 0xcd, 0xc8, 0xc5, 0xe3, 0x0e, 0x31, 0x3b, 0xb8, 0x24, 0xb1, 0x24, 0x55, 0xc8, 0x82, 0x8b, 0xad, 0x20, 0xb1, 0x28, 0x31, 0xb7, 0x58, 0x82, 0x51, 0x81, 0x51, 0x83, 0xdb, 0x48, 0x4a, 0x0f, 0xd3, 0x2e, 0xbd, 0x00, 0xb0, 0x0a, 0x27, 0x96, 0x13, 0xf7, 0xe4, 0x19, 0x82, 0xa0, 0xea, 0x85, 0x1c, 0xb9, 0xd8, 0x8a, 0xf2, 0x4b, 0x4b, 0x52, 0x8b, 0x25, 0x98, 0x14, 0x98, 0x35, 0xb8, 0x8d, 0x24, 0xb1, 0xe9, 0x0c, 0x02, 0xa9, 0x70, 0xe2, 0x03, 0x69, 0x5c, 0x75, 0x5f, 0x9e, 0x0d, 0xcc, 0x2d, 0x0e, 0x82, 0x6a, 0x74, 0xf2, 0x38, 0xf1, 0x48, 0x8e, 0xf1, 0xc2, 0x23, 0x39, 0xc6, 0x07, 0x8f, 0xe4, 0x18, 0x27, 0x3c, 0x96, 0x63, 0xb8, 0xf0, 0x58, 0x8e, 0xe1, 0xc6, 0x63, 0x39, 0x86, 0x28, 0xbd, 0xf4, 0xcc, 0x92, 0x8c, 0xd2, 0x24, 0xbd, 0xe4, 0xfc, 0x5c, 0x7d, 0xb0, 0xb1, 0xc9, 0xf9, 0x79, 0xe9, 0x45, 0xa9, 0xc5, 0xc5, 0xfa, 0xe9, 0xf9, 0xba, 0x10, 0x3f, 0x56, 0x40, 0x7c, 0x09, 0xf6, 0x5d, 0x12, 0x1b, 0xd8, 0x7b, 0xc6, 0x80, 0x00, 0x00, 0x00, 0xff, 0xff, 0x27, 0xac, 0xd8, 0xcd, 0x4c, 0x01, 0x00, 0x00, } func (m *GenesisState) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *GenesisState) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *GenesisState) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.Routes) > 0 { for iNdEx := len(m.Routes) - 1; iNdEx >= 0; iNdEx-- { { size, err := m.Routes[iNdEx].MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintGenesis(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 } } { size, err := m.Params.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintGenesis(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa return len(dAtA) - i, nil } func encodeVarintGenesis(dAtA []byte, offset int, v uint64) int { offset -= sovGenesis(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *GenesisState) Size() (n int) { if m == nil { return 0 } var l int _ = l l = m.Params.Size() n += 1 + l + sovGenesis(uint64(l)) if len(m.Routes) > 0 { for _, e := range m.Routes { l = e.Size() n += 1 + l + sovGenesis(uint64(l)) } } return n } func sovGenesis(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozGenesis(x uint64) (n int) { return sovGenesis(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *GenesisState) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenesis } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: GenesisState: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: GenesisState: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenesis } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthGenesis } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenesis } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Params.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Routes", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenesis } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthGenesis } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenesis } if postIndex > l { return io.ErrUnexpectedEOF } m.Routes = append(m.Routes, Route{}) if err := m.Routes[len(m.Routes)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipGenesis(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthGenesis } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipGenesis(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowGenesis } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowGenesis } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowGenesis } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthGenesis } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupGenesis } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthGenesis } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthGenesis = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowGenesis = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupGenesis = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/grid/types/keys.go ================================================ package types import sdk "github.com/cosmos/cosmos-sdk/types" const ( ModuleName = "grid" StoreKey = ModuleName RouterKey = ModuleName GridPoolName = "energy_grid" ) var ( RouteKey = []byte{0x00} RoutedEnergyByDestinationKey = []byte{0x01} ParamsKey = []byte{0x02} ) func GetRoutedEnergyByDestinationKey(dst sdk.AccAddress) []byte { return append(RoutedEnergyByDestinationKey, dst.Bytes()...) } func GetRouteKey(src sdk.AccAddress, dst sdk.AccAddress) []byte { return append(GetRoutesKey(src), dst.Bytes()...) } func GetRoutesKey(src sdk.AccAddress) []byte { return append(RouteKey, src.Bytes()...) } ================================================ FILE: x/grid/types/msgs.go ================================================ package types import ( errorsmod "cosmossdk.io/errors" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" ctypes "github.com/cybercongress/go-cyber/v7/types" ) const ( ActionCreateRoute = "create_route" ActionEditRoute = "edit_route" ActionDeleteRoute = "delete_route" ActionEditRouteName = "edit_route_name" ) var ( _ sdk.Msg = &MsgCreateRoute{} _ sdk.Msg = &MsgEditRoute{} _ sdk.Msg = &MsgDeleteRoute{} _ sdk.Msg = &MsgEditRouteName{} _ sdk.Msg = &MsgUpdateParams{} ) func NewMsgCreateRoute(src sdk.AccAddress, dst sdk.AccAddress, name string) *MsgCreateRoute { return &MsgCreateRoute{ Source: src.String(), Destination: dst.String(), Name: name, } } func (msg MsgCreateRoute) Route() string { return RouterKey } func (msg MsgCreateRoute) Type() string { return ActionCreateRoute } func (msg MsgCreateRoute) ValidateBasic() error { _, err := sdk.AccAddressFromBech32(msg.Source) if err != nil { return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "Invalid source address (%s)", err) } _, err = sdk.AccAddressFromBech32(msg.Destination) if err != nil { return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "Invalid destination address (%s)", err) } if len(msg.Name) == 0 || len(msg.Name) > 32 { // TODO fix validation return ErrWrongName } return nil } func (msg MsgCreateRoute) GetSignBytes() []byte { bz := ModuleCdc.MustMarshalJSON(&msg) return sdk.MustSortJSON(bz) } func (msg MsgCreateRoute) GetSigners() []sdk.AccAddress { addr, err := sdk.AccAddressFromBech32(msg.Source) if err != nil { panic(err) } return []sdk.AccAddress{addr} } func NewMsgEditRoute(src sdk.AccAddress, dst sdk.AccAddress, value sdk.Coin) *MsgEditRoute { return &MsgEditRoute{ Source: src.String(), Destination: dst.String(), Value: value, } } func (msg MsgEditRoute) Route() string { return RouterKey } func (msg MsgEditRoute) Type() string { return ActionEditRoute } func (msg MsgEditRoute) ValidateBasic() error { _, err := sdk.AccAddressFromBech32(msg.Source) if err != nil { return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "Invalid source address (%s)", err) } _, err = sdk.AccAddressFromBech32(msg.Destination) if err != nil { return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "Invalid destination address (%s)", err) } if msg.Value.Denom != ctypes.AMPERE && msg.Value.Denom != ctypes.VOLT { return ErrWrongValueDenom } return nil } func (msg MsgEditRoute) GetSignBytes() []byte { bz := ModuleCdc.MustMarshalJSON(&msg) return sdk.MustSortJSON(bz) } func (msg MsgEditRoute) GetSigners() []sdk.AccAddress { addr, err := sdk.AccAddressFromBech32(msg.Source) if err != nil { panic(err) } return []sdk.AccAddress{addr} } func NewMsgDeleteRoute(src sdk.AccAddress, dst sdk.AccAddress) *MsgDeleteRoute { return &MsgDeleteRoute{ Source: src.String(), Destination: dst.String(), } } func (msg MsgDeleteRoute) Route() string { return RouterKey } func (msg MsgDeleteRoute) Type() string { return ActionDeleteRoute } func (msg MsgDeleteRoute) ValidateBasic() error { _, err := sdk.AccAddressFromBech32(msg.Source) if err != nil { return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "Invalid source address (%s)", err) } _, err = sdk.AccAddressFromBech32(msg.Destination) if err != nil { return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "Invalid destination address (%s)", err) } return nil } func (msg MsgDeleteRoute) GetSignBytes() []byte { bz := ModuleCdc.MustMarshalJSON(&msg) return sdk.MustSortJSON(bz) } func (msg MsgDeleteRoute) GetSigners() []sdk.AccAddress { addr, err := sdk.AccAddressFromBech32(msg.Source) if err != nil { panic(err) } return []sdk.AccAddress{addr} } func NewMsgEditRouteName(src sdk.AccAddress, dst sdk.AccAddress, name string) *MsgEditRouteName { return &MsgEditRouteName{ Source: src.String(), Destination: dst.String(), Name: name, } } func (msg MsgEditRouteName) Route() string { return RouterKey } func (msg MsgEditRouteName) Type() string { return ActionEditRouteName } func (msg MsgEditRouteName) ValidateBasic() error { _, err := sdk.AccAddressFromBech32(msg.Source) if err != nil { return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "Invalid source address (%s)", err) } _, err = sdk.AccAddressFromBech32(msg.Destination) if err != nil { return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "Invalid destination address (%s)", err) } if len(msg.Name) == 0 || len(msg.Name) > 32 { return ErrWrongName } return nil } func (msg MsgEditRouteName) GetSignBytes() []byte { bz := ModuleCdc.MustMarshalJSON(&msg) return sdk.MustSortJSON(bz) } func (msg MsgEditRouteName) GetSigners() []sdk.AccAddress { addr, err := sdk.AccAddressFromBech32(msg.Source) if err != nil { panic(err) } return []sdk.AccAddress{addr} } // GetSignBytes implements the LegacyMsg interface. func (m MsgUpdateParams) GetSignBytes() []byte { return sdk.MustSortJSON(ModuleCdc.MustMarshalJSON(&m)) } // GetSigners returns the expected signers for a MsgUpdateParams message. func (m *MsgUpdateParams) GetSigners() []sdk.AccAddress { addr, _ := sdk.AccAddressFromBech32(m.Authority) return []sdk.AccAddress{addr} } // ValidateBasic does a sanity check on the provided data. func (m *MsgUpdateParams) ValidateBasic() error { if _, err := sdk.AccAddressFromBech32(m.Authority); err != nil { return errorsmod.Wrap(err, "invalid authority address") } return m.Params.Validate() } ================================================ FILE: x/grid/types/params.go ================================================ package types import ( "fmt" ) func DefaultParams() Params { return Params{ MaxRoutes: uint32(8), } } func (p Params) Validate() error { if err := validateMaxRoutes(p.MaxRoutes); err != nil { return err } return nil } func validateMaxRoutes(i interface{}) error { v, ok := i.(uint32) if !ok { return fmt.Errorf("invalid parameter type: %T", i) } if v == 0 { return fmt.Errorf("max routes must be positive: %d", v) } if v > 16 { return fmt.Errorf("max routes must be less or equal than 16: %d", v) } return nil } ================================================ FILE: x/grid/types/params_legacy.go ================================================ package types import paramstypes "github.com/cosmos/cosmos-sdk/x/params/types" var KeyMaxRoutes = []byte("MaxRoutes") // Deprecated: Type declaration for parameters func ParamKeyTable() paramstypes.KeyTable { return paramstypes.NewKeyTable().RegisterParamSet(&Params{}) } func (p *Params) ParamSetPairs() paramstypes.ParamSetPairs { return paramstypes.ParamSetPairs{ paramstypes.NewParamSetPair(KeyMaxRoutes, &p.MaxRoutes, validateMaxRoutes), } } ================================================ FILE: x/grid/types/query.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: cyber/grid/v1beta1/query.proto package types import ( context "context" fmt "fmt" io "io" math "math" math_bits "math/bits" github_com_cosmos_cosmos_sdk_types "github.com/cosmos/cosmos-sdk/types" types "github.com/cosmos/cosmos-sdk/types" query "github.com/cosmos/cosmos-sdk/types/query" _ "github.com/cosmos/gogoproto/gogoproto" grpc1 "github.com/cosmos/gogoproto/grpc" proto "github.com/cosmos/gogoproto/proto" _ "google.golang.org/genproto/googleapis/api/annotations" grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" ) // Reference imports to suppress errors if they are not otherwise used. var ( _ = proto.Marshal _ = fmt.Errorf _ = math.Inf ) // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package type QueryParamsRequest struct{} func (m *QueryParamsRequest) Reset() { *m = QueryParamsRequest{} } func (m *QueryParamsRequest) String() string { return proto.CompactTextString(m) } func (*QueryParamsRequest) ProtoMessage() {} func (*QueryParamsRequest) Descriptor() ([]byte, []int) { return fileDescriptor_f6ec0dbd7f0bdd2b, []int{0} } func (m *QueryParamsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryParamsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryParamsRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryParamsRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryParamsRequest.Merge(m, src) } func (m *QueryParamsRequest) XXX_Size() int { return m.Size() } func (m *QueryParamsRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryParamsRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryParamsRequest proto.InternalMessageInfo type QueryParamsResponse struct { Params Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params"` } func (m *QueryParamsResponse) Reset() { *m = QueryParamsResponse{} } func (m *QueryParamsResponse) String() string { return proto.CompactTextString(m) } func (*QueryParamsResponse) ProtoMessage() {} func (*QueryParamsResponse) Descriptor() ([]byte, []int) { return fileDescriptor_f6ec0dbd7f0bdd2b, []int{1} } func (m *QueryParamsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryParamsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryParamsResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryParamsResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryParamsResponse.Merge(m, src) } func (m *QueryParamsResponse) XXX_Size() int { return m.Size() } func (m *QueryParamsResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryParamsResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryParamsResponse proto.InternalMessageInfo func (m *QueryParamsResponse) GetParams() Params { if m != nil { return m.Params } return Params{} } type QuerySourceRequest struct { Source string `protobuf:"bytes,1,opt,name=source,proto3" json:"source,omitempty"` } func (m *QuerySourceRequest) Reset() { *m = QuerySourceRequest{} } func (m *QuerySourceRequest) String() string { return proto.CompactTextString(m) } func (*QuerySourceRequest) ProtoMessage() {} func (*QuerySourceRequest) Descriptor() ([]byte, []int) { return fileDescriptor_f6ec0dbd7f0bdd2b, []int{2} } func (m *QuerySourceRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QuerySourceRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QuerySourceRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QuerySourceRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QuerySourceRequest.Merge(m, src) } func (m *QuerySourceRequest) XXX_Size() int { return m.Size() } func (m *QuerySourceRequest) XXX_DiscardUnknown() { xxx_messageInfo_QuerySourceRequest.DiscardUnknown(m) } var xxx_messageInfo_QuerySourceRequest proto.InternalMessageInfo func (m *QuerySourceRequest) GetSource() string { if m != nil { return m.Source } return "" } type QueryDestinationRequest struct { Destination string `protobuf:"bytes,1,opt,name=destination,proto3" json:"destination,omitempty"` } func (m *QueryDestinationRequest) Reset() { *m = QueryDestinationRequest{} } func (m *QueryDestinationRequest) String() string { return proto.CompactTextString(m) } func (*QueryDestinationRequest) ProtoMessage() {} func (*QueryDestinationRequest) Descriptor() ([]byte, []int) { return fileDescriptor_f6ec0dbd7f0bdd2b, []int{3} } func (m *QueryDestinationRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryDestinationRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryDestinationRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryDestinationRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryDestinationRequest.Merge(m, src) } func (m *QueryDestinationRequest) XXX_Size() int { return m.Size() } func (m *QueryDestinationRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryDestinationRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryDestinationRequest proto.InternalMessageInfo func (m *QueryDestinationRequest) GetDestination() string { if m != nil { return m.Destination } return "" } type QueryRoutedEnergyResponse struct { Value github_com_cosmos_cosmos_sdk_types.Coins `protobuf:"bytes,1,rep,name=value,proto3,castrepeated=github.com/cosmos/cosmos-sdk/types.Coins" json:"value"` } func (m *QueryRoutedEnergyResponse) Reset() { *m = QueryRoutedEnergyResponse{} } func (m *QueryRoutedEnergyResponse) String() string { return proto.CompactTextString(m) } func (*QueryRoutedEnergyResponse) ProtoMessage() {} func (*QueryRoutedEnergyResponse) Descriptor() ([]byte, []int) { return fileDescriptor_f6ec0dbd7f0bdd2b, []int{4} } func (m *QueryRoutedEnergyResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryRoutedEnergyResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryRoutedEnergyResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryRoutedEnergyResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryRoutedEnergyResponse.Merge(m, src) } func (m *QueryRoutedEnergyResponse) XXX_Size() int { return m.Size() } func (m *QueryRoutedEnergyResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryRoutedEnergyResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryRoutedEnergyResponse proto.InternalMessageInfo func (m *QueryRoutedEnergyResponse) GetValue() github_com_cosmos_cosmos_sdk_types.Coins { if m != nil { return m.Value } return nil } type QueryRouteRequest struct { Source string `protobuf:"bytes,1,opt,name=source,proto3" json:"source,omitempty"` Destination string `protobuf:"bytes,2,opt,name=destination,proto3" json:"destination,omitempty"` } func (m *QueryRouteRequest) Reset() { *m = QueryRouteRequest{} } func (m *QueryRouteRequest) String() string { return proto.CompactTextString(m) } func (*QueryRouteRequest) ProtoMessage() {} func (*QueryRouteRequest) Descriptor() ([]byte, []int) { return fileDescriptor_f6ec0dbd7f0bdd2b, []int{5} } func (m *QueryRouteRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryRouteRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryRouteRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryRouteRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryRouteRequest.Merge(m, src) } func (m *QueryRouteRequest) XXX_Size() int { return m.Size() } func (m *QueryRouteRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryRouteRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryRouteRequest proto.InternalMessageInfo func (m *QueryRouteRequest) GetSource() string { if m != nil { return m.Source } return "" } func (m *QueryRouteRequest) GetDestination() string { if m != nil { return m.Destination } return "" } type QueryRouteResponse struct { Route Route `protobuf:"bytes,1,opt,name=route,proto3" json:"route"` } func (m *QueryRouteResponse) Reset() { *m = QueryRouteResponse{} } func (m *QueryRouteResponse) String() string { return proto.CompactTextString(m) } func (*QueryRouteResponse) ProtoMessage() {} func (*QueryRouteResponse) Descriptor() ([]byte, []int) { return fileDescriptor_f6ec0dbd7f0bdd2b, []int{6} } func (m *QueryRouteResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryRouteResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryRouteResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryRouteResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryRouteResponse.Merge(m, src) } func (m *QueryRouteResponse) XXX_Size() int { return m.Size() } func (m *QueryRouteResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryRouteResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryRouteResponse proto.InternalMessageInfo func (m *QueryRouteResponse) GetRoute() Route { if m != nil { return m.Route } return Route{} } type QueryRoutesRequest struct { Pagination *query.PageRequest `protobuf:"bytes,1,opt,name=pagination,proto3" json:"pagination,omitempty"` } func (m *QueryRoutesRequest) Reset() { *m = QueryRoutesRequest{} } func (m *QueryRoutesRequest) String() string { return proto.CompactTextString(m) } func (*QueryRoutesRequest) ProtoMessage() {} func (*QueryRoutesRequest) Descriptor() ([]byte, []int) { return fileDescriptor_f6ec0dbd7f0bdd2b, []int{7} } func (m *QueryRoutesRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryRoutesRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryRoutesRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryRoutesRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryRoutesRequest.Merge(m, src) } func (m *QueryRoutesRequest) XXX_Size() int { return m.Size() } func (m *QueryRoutesRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryRoutesRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryRoutesRequest proto.InternalMessageInfo func (m *QueryRoutesRequest) GetPagination() *query.PageRequest { if m != nil { return m.Pagination } return nil } type QueryRoutesResponse struct { Routes Routes `protobuf:"bytes,1,rep,name=routes,proto3,castrepeated=Routes" json:"routes"` Pagination *query.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` } func (m *QueryRoutesResponse) Reset() { *m = QueryRoutesResponse{} } func (m *QueryRoutesResponse) String() string { return proto.CompactTextString(m) } func (*QueryRoutesResponse) ProtoMessage() {} func (*QueryRoutesResponse) Descriptor() ([]byte, []int) { return fileDescriptor_f6ec0dbd7f0bdd2b, []int{8} } func (m *QueryRoutesResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryRoutesResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryRoutesResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryRoutesResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryRoutesResponse.Merge(m, src) } func (m *QueryRoutesResponse) XXX_Size() int { return m.Size() } func (m *QueryRoutesResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryRoutesResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryRoutesResponse proto.InternalMessageInfo func (m *QueryRoutesResponse) GetRoutes() Routes { if m != nil { return m.Routes } return nil } func (m *QueryRoutesResponse) GetPagination() *query.PageResponse { if m != nil { return m.Pagination } return nil } func init() { proto.RegisterType((*QueryParamsRequest)(nil), "cyber.grid.v1beta1.QueryParamsRequest") proto.RegisterType((*QueryParamsResponse)(nil), "cyber.grid.v1beta1.QueryParamsResponse") proto.RegisterType((*QuerySourceRequest)(nil), "cyber.grid.v1beta1.QuerySourceRequest") proto.RegisterType((*QueryDestinationRequest)(nil), "cyber.grid.v1beta1.QueryDestinationRequest") proto.RegisterType((*QueryRoutedEnergyResponse)(nil), "cyber.grid.v1beta1.QueryRoutedEnergyResponse") proto.RegisterType((*QueryRouteRequest)(nil), "cyber.grid.v1beta1.QueryRouteRequest") proto.RegisterType((*QueryRouteResponse)(nil), "cyber.grid.v1beta1.QueryRouteResponse") proto.RegisterType((*QueryRoutesRequest)(nil), "cyber.grid.v1beta1.QueryRoutesRequest") proto.RegisterType((*QueryRoutesResponse)(nil), "cyber.grid.v1beta1.QueryRoutesResponse") } func init() { proto.RegisterFile("cyber/grid/v1beta1/query.proto", fileDescriptor_f6ec0dbd7f0bdd2b) } var fileDescriptor_f6ec0dbd7f0bdd2b = []byte{ // 693 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x94, 0x95, 0x5d, 0x6b, 0xd3, 0x5e, 0x18, 0xc0, 0x9b, 0xfd, 0xff, 0x0d, 0x7a, 0x26, 0xc2, 0x8e, 0xc3, 0xb9, 0x22, 0xd9, 0x0c, 0xd8, 0x15, 0x67, 0x13, 0xd7, 0x39, 0x10, 0xbd, 0x72, 0xbe, 0x82, 0x88, 0x1a, 0xef, 0x44, 0x18, 0x69, 0x7b, 0x88, 0xc1, 0x2d, 0x27, 0xcb, 0x49, 0x86, 0xbd, 0xd9, 0xc5, 0xbe, 0x80, 0x82, 0xd7, 0x0a, 0x7a, 0xe9, 0x9d, 0xdf, 0x62, 0x97, 0x03, 0x6f, 0xbc, 0x52, 0x69, 0xfd, 0x20, 0x92, 0xe7, 0x3c, 0x69, 0x92, 0xb6, 0x69, 0xba, 0xab, 0x36, 0xcf, 0xeb, 0xef, 0x79, 0x4b, 0x88, 0xd6, 0xe9, 0xb5, 0x59, 0x60, 0x3a, 0x81, 0xdb, 0x35, 0x0f, 0x36, 0xda, 0x2c, 0xb4, 0x37, 0xcc, 0xfd, 0x88, 0x05, 0x3d, 0xc3, 0x0f, 0x78, 0xc8, 0x29, 0x05, 0xbd, 0x11, 0xeb, 0x0d, 0xd4, 0xd7, 0x16, 0x1d, 0xee, 0x70, 0x50, 0x9b, 0xf1, 0x3f, 0x69, 0x59, 0xbb, 0xec, 0x70, 0xee, 0xec, 0x32, 0xd3, 0xf6, 0x5d, 0xd3, 0xf6, 0x3c, 0x1e, 0xda, 0xa1, 0xcb, 0x3d, 0x81, 0xda, 0x49, 0x79, 0xc2, 0x9e, 0xcf, 0x52, 0x3d, 0x17, 0x7b, 0x5c, 0x98, 0x6d, 0x5b, 0xb0, 0xa1, 0x41, 0x87, 0xbb, 0x1e, 0xea, 0xaf, 0x65, 0xf5, 0x00, 0x38, 0xb4, 0xf2, 0x6d, 0xc7, 0xf5, 0x20, 0x99, 0xb4, 0xd5, 0x17, 0x09, 0x7d, 0x11, 0x5b, 0x3c, 0xb7, 0x03, 0x7b, 0x4f, 0x58, 0x6c, 0x3f, 0x62, 0x22, 0xd4, 0x9f, 0x91, 0x0b, 0x39, 0xa9, 0xf0, 0xb9, 0x27, 0x18, 0xbd, 0x45, 0x54, 0x1f, 0x24, 0x97, 0x94, 0x55, 0xa5, 0x31, 0xdf, 0xaa, 0x19, 0xe3, 0x15, 0x1b, 0xd2, 0x67, 0xfb, 0xff, 0xe3, 0x5f, 0x2b, 0x15, 0x0b, 0xed, 0xf5, 0xeb, 0x98, 0xe6, 0x25, 0x8f, 0x82, 0x0e, 0xc3, 0x34, 0xf4, 0x22, 0x51, 0x05, 0x08, 0x20, 0xde, 0x59, 0x0b, 0x9f, 0xf4, 0x3b, 0x64, 0x09, 0xac, 0xef, 0x33, 0x11, 0x22, 0x6e, 0xe2, 0xb2, 0x4a, 0xe6, 0xbb, 0xa9, 0x14, 0xfd, 0xb2, 0x22, 0xfd, 0x90, 0x2c, 0x83, 0xb3, 0xc5, 0xa3, 0x90, 0x75, 0x1f, 0x78, 0x2c, 0x70, 0x7a, 0xc3, 0x0a, 0x6c, 0x52, 0x3d, 0xb0, 0x77, 0xa3, 0x38, 0xe1, 0x7f, 0x8d, 0xf9, 0xd6, 0xb2, 0x21, 0x5b, 0x65, 0xc4, 0xad, 0x1a, 0x56, 0x70, 0x8f, 0xbb, 0xde, 0xf6, 0x8d, 0x98, 0xff, 0xdb, 0xef, 0x95, 0x86, 0xe3, 0x86, 0x6f, 0xa2, 0xb6, 0xd1, 0xe1, 0x7b, 0x26, 0xf6, 0x55, 0xfe, 0x34, 0x45, 0xf7, 0x2d, 0x8e, 0x25, 0x76, 0x10, 0x96, 0x8c, 0xac, 0x3f, 0x25, 0x0b, 0x69, 0xfe, 0x92, 0x4a, 0x47, 0xcb, 0x99, 0x1b, 0x2f, 0xe7, 0x09, 0x76, 0x0e, 0xc3, 0x61, 0x1d, 0x5b, 0xa4, 0x1a, 0xc4, 0x02, 0x1c, 0xc4, 0xf2, 0xa4, 0x41, 0x80, 0x07, 0xce, 0x41, 0x5a, 0xeb, 0xaf, 0xb3, 0xc1, 0x92, 0x69, 0xd3, 0x87, 0x84, 0xa4, 0x7b, 0x81, 0x11, 0xeb, 0xb9, 0xce, 0xc8, 0x2d, 0x4f, 0x27, 0xec, 0x24, 0x85, 0x59, 0x19, 0x4f, 0xfd, 0x8b, 0x82, 0x6b, 0x93, 0x84, 0x47, 0xd8, 0xbb, 0x44, 0x85, 0xf4, 0x22, 0xed, 0x7a, 0x11, 0xed, 0x79, 0xec, 0xba, 0x8a, 0x21, 0xd0, 0x91, 0x3e, 0xca, 0x21, 0xce, 0x01, 0xe2, 0x5a, 0x29, 0xa2, 0xcc, 0x9f, 0x65, 0x6c, 0x7d, 0x3a, 0x43, 0xaa, 0xc0, 0x48, 0x8f, 0x14, 0xa2, 0xca, 0x5d, 0xa5, 0xf5, 0x49, 0x40, 0xe3, 0x67, 0x51, 0x5b, 0x2b, 0xb5, 0x93, 0x19, 0xf5, 0xb5, 0xa3, 0x1f, 0x7f, 0x3f, 0xce, 0x5d, 0xa1, 0x2b, 0xe6, 0x84, 0x53, 0x86, 0x07, 0x79, 0x17, 0xf4, 0xbd, 0x42, 0xce, 0xe1, 0x4d, 0xc8, 0x42, 0x8b, 0x51, 0x72, 0xa7, 0x33, 0x05, 0x25, 0xdf, 0x7c, 0xdd, 0x00, 0x94, 0x06, 0xad, 0x17, 0xa2, 0xc8, 0x55, 0xdc, 0xc1, 0x4e, 0x7f, 0x56, 0xc8, 0x42, 0xf6, 0xee, 0xa4, 0x74, 0xbd, 0x30, 0xdd, 0xf8, 0x8d, 0xce, 0xce, 0xb6, 0x09, 0x6c, 0x4d, 0xba, 0x5e, 0xc8, 0x96, 0xb9, 0x84, 0x04, 0xf0, 0xbb, 0x42, 0x96, 0x46, 0x01, 0xf1, 0xcc, 0x4f, 0x87, 0xd9, 0x9c, 0x8e, 0x39, 0xf2, 0xea, 0xd0, 0x6f, 0x03, 0xec, 0x4d, 0xda, 0x9a, 0x1d, 0xb6, 0xbb, 0xc3, 0x24, 0xd7, 0x57, 0x85, 0xd0, 0xcc, 0x98, 0x13, 0xdc, 0x59, 0x87, 0x7d, 0x4a, 0xd2, 0x2d, 0x20, 0x35, 0x69, 0x73, 0xa6, 0x91, 0x0f, 0x21, 0x0f, 0x49, 0x15, 0xc2, 0xd1, 0xab, 0xd3, 0xd3, 0x25, 0x54, 0xf5, 0x32, 0x33, 0xc4, 0xa9, 0x03, 0xce, 0x2a, 0xd5, 0x0a, 0x71, 0x80, 0x03, 0x0e, 0xb2, 0xf4, 0x0a, 0x72, 0x6f, 0xae, 0xd9, 0x37, 0xad, 0xfc, 0x20, 0xe5, 0x76, 0x6d, 0x3f, 0x3e, 0xee, 0x6b, 0xca, 0x49, 0x5f, 0x53, 0xfe, 0xf4, 0x35, 0xe5, 0xc3, 0x40, 0xab, 0x9c, 0x0c, 0xb4, 0xca, 0xcf, 0x81, 0x56, 0x79, 0x65, 0x64, 0x3f, 0x04, 0x71, 0x90, 0x0e, 0xf7, 0x9c, 0x80, 0x09, 0x61, 0x3a, 0xbc, 0x29, 0xa3, 0xbe, 0x93, 0xa1, 0xe0, 0xa3, 0xd0, 0x56, 0xe1, 0x03, 0xbb, 0xf9, 0x2f, 0x00, 0x00, 0xff, 0xff, 0xc5, 0xea, 0x02, 0xd4, 0x36, 0x08, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. var ( _ context.Context _ grpc.ClientConn ) // This is a compile-time assertion to ensure that this generated file // is compatible with the grpc package it is being compiled against. const _ = grpc.SupportPackageIsVersion4 // QueryClient is the client API for Query service. // // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. type QueryClient interface { Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) SourceRoutes(ctx context.Context, in *QuerySourceRequest, opts ...grpc.CallOption) (*QueryRoutesResponse, error) DestinationRoutes(ctx context.Context, in *QueryDestinationRequest, opts ...grpc.CallOption) (*QueryRoutesResponse, error) DestinationRoutedEnergy(ctx context.Context, in *QueryDestinationRequest, opts ...grpc.CallOption) (*QueryRoutedEnergyResponse, error) SourceRoutedEnergy(ctx context.Context, in *QuerySourceRequest, opts ...grpc.CallOption) (*QueryRoutedEnergyResponse, error) Route(ctx context.Context, in *QueryRouteRequest, opts ...grpc.CallOption) (*QueryRouteResponse, error) Routes(ctx context.Context, in *QueryRoutesRequest, opts ...grpc.CallOption) (*QueryRoutesResponse, error) } type queryClient struct { cc grpc1.ClientConn } func NewQueryClient(cc grpc1.ClientConn) QueryClient { return &queryClient{cc} } func (c *queryClient) Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) { out := new(QueryParamsResponse) err := c.cc.Invoke(ctx, "/cyber.grid.v1beta1.Query/Params", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) SourceRoutes(ctx context.Context, in *QuerySourceRequest, opts ...grpc.CallOption) (*QueryRoutesResponse, error) { out := new(QueryRoutesResponse) err := c.cc.Invoke(ctx, "/cyber.grid.v1beta1.Query/SourceRoutes", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) DestinationRoutes(ctx context.Context, in *QueryDestinationRequest, opts ...grpc.CallOption) (*QueryRoutesResponse, error) { out := new(QueryRoutesResponse) err := c.cc.Invoke(ctx, "/cyber.grid.v1beta1.Query/DestinationRoutes", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) DestinationRoutedEnergy(ctx context.Context, in *QueryDestinationRequest, opts ...grpc.CallOption) (*QueryRoutedEnergyResponse, error) { out := new(QueryRoutedEnergyResponse) err := c.cc.Invoke(ctx, "/cyber.grid.v1beta1.Query/DestinationRoutedEnergy", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) SourceRoutedEnergy(ctx context.Context, in *QuerySourceRequest, opts ...grpc.CallOption) (*QueryRoutedEnergyResponse, error) { out := new(QueryRoutedEnergyResponse) err := c.cc.Invoke(ctx, "/cyber.grid.v1beta1.Query/SourceRoutedEnergy", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) Route(ctx context.Context, in *QueryRouteRequest, opts ...grpc.CallOption) (*QueryRouteResponse, error) { out := new(QueryRouteResponse) err := c.cc.Invoke(ctx, "/cyber.grid.v1beta1.Query/Route", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) Routes(ctx context.Context, in *QueryRoutesRequest, opts ...grpc.CallOption) (*QueryRoutesResponse, error) { out := new(QueryRoutesResponse) err := c.cc.Invoke(ctx, "/cyber.grid.v1beta1.Query/Routes", in, out, opts...) if err != nil { return nil, err } return out, nil } // QueryServer is the server API for Query service. type QueryServer interface { Params(context.Context, *QueryParamsRequest) (*QueryParamsResponse, error) SourceRoutes(context.Context, *QuerySourceRequest) (*QueryRoutesResponse, error) DestinationRoutes(context.Context, *QueryDestinationRequest) (*QueryRoutesResponse, error) DestinationRoutedEnergy(context.Context, *QueryDestinationRequest) (*QueryRoutedEnergyResponse, error) SourceRoutedEnergy(context.Context, *QuerySourceRequest) (*QueryRoutedEnergyResponse, error) Route(context.Context, *QueryRouteRequest) (*QueryRouteResponse, error) Routes(context.Context, *QueryRoutesRequest) (*QueryRoutesResponse, error) } // UnimplementedQueryServer can be embedded to have forward compatible implementations. type UnimplementedQueryServer struct{} func (*UnimplementedQueryServer) Params(ctx context.Context, req *QueryParamsRequest) (*QueryParamsResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method Params not implemented") } func (*UnimplementedQueryServer) SourceRoutes(ctx context.Context, req *QuerySourceRequest) (*QueryRoutesResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method SourceRoutes not implemented") } func (*UnimplementedQueryServer) DestinationRoutes(ctx context.Context, req *QueryDestinationRequest) (*QueryRoutesResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method DestinationRoutes not implemented") } func (*UnimplementedQueryServer) DestinationRoutedEnergy(ctx context.Context, req *QueryDestinationRequest) (*QueryRoutedEnergyResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method DestinationRoutedEnergy not implemented") } func (*UnimplementedQueryServer) SourceRoutedEnergy(ctx context.Context, req *QuerySourceRequest) (*QueryRoutedEnergyResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method SourceRoutedEnergy not implemented") } func (*UnimplementedQueryServer) Route(ctx context.Context, req *QueryRouteRequest) (*QueryRouteResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method Route not implemented") } func (*UnimplementedQueryServer) Routes(ctx context.Context, req *QueryRoutesRequest) (*QueryRoutesResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method Routes not implemented") } func RegisterQueryServer(s grpc1.Server, srv QueryServer) { s.RegisterService(&_Query_serviceDesc, srv) } func _Query_Params_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryParamsRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).Params(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.grid.v1beta1.Query/Params", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Params(ctx, req.(*QueryParamsRequest)) } return interceptor(ctx, in, info, handler) } func _Query_SourceRoutes_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QuerySourceRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).SourceRoutes(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.grid.v1beta1.Query/SourceRoutes", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).SourceRoutes(ctx, req.(*QuerySourceRequest)) } return interceptor(ctx, in, info, handler) } func _Query_DestinationRoutes_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryDestinationRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).DestinationRoutes(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.grid.v1beta1.Query/DestinationRoutes", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).DestinationRoutes(ctx, req.(*QueryDestinationRequest)) } return interceptor(ctx, in, info, handler) } func _Query_DestinationRoutedEnergy_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryDestinationRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).DestinationRoutedEnergy(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.grid.v1beta1.Query/DestinationRoutedEnergy", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).DestinationRoutedEnergy(ctx, req.(*QueryDestinationRequest)) } return interceptor(ctx, in, info, handler) } func _Query_SourceRoutedEnergy_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QuerySourceRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).SourceRoutedEnergy(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.grid.v1beta1.Query/SourceRoutedEnergy", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).SourceRoutedEnergy(ctx, req.(*QuerySourceRequest)) } return interceptor(ctx, in, info, handler) } func _Query_Route_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryRouteRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).Route(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.grid.v1beta1.Query/Route", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Route(ctx, req.(*QueryRouteRequest)) } return interceptor(ctx, in, info, handler) } func _Query_Routes_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryRoutesRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).Routes(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.grid.v1beta1.Query/Routes", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Routes(ctx, req.(*QueryRoutesRequest)) } return interceptor(ctx, in, info, handler) } var _Query_serviceDesc = grpc.ServiceDesc{ ServiceName: "cyber.grid.v1beta1.Query", HandlerType: (*QueryServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "Params", Handler: _Query_Params_Handler, }, { MethodName: "SourceRoutes", Handler: _Query_SourceRoutes_Handler, }, { MethodName: "DestinationRoutes", Handler: _Query_DestinationRoutes_Handler, }, { MethodName: "DestinationRoutedEnergy", Handler: _Query_DestinationRoutedEnergy_Handler, }, { MethodName: "SourceRoutedEnergy", Handler: _Query_SourceRoutedEnergy_Handler, }, { MethodName: "Route", Handler: _Query_Route_Handler, }, { MethodName: "Routes", Handler: _Query_Routes_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "cyber/grid/v1beta1/query.proto", } func (m *QueryParamsRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryParamsRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryParamsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *QueryParamsResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryParamsResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryParamsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.Params.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa return len(dAtA) - i, nil } func (m *QuerySourceRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QuerySourceRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QuerySourceRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.Source) > 0 { i -= len(m.Source) copy(dAtA[i:], m.Source) i = encodeVarintQuery(dAtA, i, uint64(len(m.Source))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *QueryDestinationRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryDestinationRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryDestinationRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.Destination) > 0 { i -= len(m.Destination) copy(dAtA[i:], m.Destination) i = encodeVarintQuery(dAtA, i, uint64(len(m.Destination))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *QueryRoutedEnergyResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryRoutedEnergyResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryRoutedEnergyResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.Value) > 0 { for iNdEx := len(m.Value) - 1; iNdEx >= 0; iNdEx-- { { size, err := m.Value[iNdEx].MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa } } return len(dAtA) - i, nil } func (m *QueryRouteRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryRouteRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryRouteRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.Destination) > 0 { i -= len(m.Destination) copy(dAtA[i:], m.Destination) i = encodeVarintQuery(dAtA, i, uint64(len(m.Destination))) i-- dAtA[i] = 0x12 } if len(m.Source) > 0 { i -= len(m.Source) copy(dAtA[i:], m.Source) i = encodeVarintQuery(dAtA, i, uint64(len(m.Source))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *QueryRouteResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryRouteResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryRouteResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.Route.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa return len(dAtA) - i, nil } func (m *QueryRoutesRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryRoutesRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryRoutesRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.Pagination != nil { { size, err := m.Pagination.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *QueryRoutesResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryRoutesResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryRoutesResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.Pagination != nil { { size, err := m.Pagination.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 } if len(m.Routes) > 0 { for iNdEx := len(m.Routes) - 1; iNdEx >= 0; iNdEx-- { { size, err := m.Routes[iNdEx].MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa } } return len(dAtA) - i, nil } func encodeVarintQuery(dAtA []byte, offset int, v uint64) int { offset -= sovQuery(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *QueryParamsRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *QueryParamsResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l l = m.Params.Size() n += 1 + l + sovQuery(uint64(l)) return n } func (m *QuerySourceRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Source) if l > 0 { n += 1 + l + sovQuery(uint64(l)) } return n } func (m *QueryDestinationRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Destination) if l > 0 { n += 1 + l + sovQuery(uint64(l)) } return n } func (m *QueryRoutedEnergyResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l if len(m.Value) > 0 { for _, e := range m.Value { l = e.Size() n += 1 + l + sovQuery(uint64(l)) } } return n } func (m *QueryRouteRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Source) if l > 0 { n += 1 + l + sovQuery(uint64(l)) } l = len(m.Destination) if l > 0 { n += 1 + l + sovQuery(uint64(l)) } return n } func (m *QueryRouteResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l l = m.Route.Size() n += 1 + l + sovQuery(uint64(l)) return n } func (m *QueryRoutesRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.Pagination != nil { l = m.Pagination.Size() n += 1 + l + sovQuery(uint64(l)) } return n } func (m *QueryRoutesResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l if len(m.Routes) > 0 { for _, e := range m.Routes { l = e.Size() n += 1 + l + sovQuery(uint64(l)) } } if m.Pagination != nil { l = m.Pagination.Size() n += 1 + l + sovQuery(uint64(l)) } return n } func sovQuery(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozQuery(x uint64) (n int) { return sovQuery(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *QueryParamsRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryParamsRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryParamsRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryParamsResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryParamsResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryParamsResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Params.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QuerySourceRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QuerySourceRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QuerySourceRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Source", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } m.Source = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryDestinationRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryDestinationRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryDestinationRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Destination", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } m.Destination = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryRoutedEnergyResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryRoutedEnergyResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryRoutedEnergyResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Value", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } m.Value = append(m.Value, types.Coin{}) if err := m.Value[len(m.Value)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryRouteRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryRouteRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryRouteRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Source", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } m.Source = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Destination", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } m.Destination = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryRouteResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryRouteResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryRouteResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Route", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Route.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryRoutesRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryRoutesRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryRoutesRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if m.Pagination == nil { m.Pagination = &query.PageRequest{} } if err := m.Pagination.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryRoutesResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryRoutesResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryRoutesResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Routes", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } m.Routes = append(m.Routes, Route{}) if err := m.Routes[len(m.Routes)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if m.Pagination == nil { m.Pagination = &query.PageResponse{} } if err := m.Pagination.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipQuery(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowQuery } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowQuery } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowQuery } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthQuery } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupQuery } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthQuery } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthQuery = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowQuery = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupQuery = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/grid/types/query.pb.gw.go ================================================ // Code generated by protoc-gen-grpc-gateway. DO NOT EDIT. // source: cyber/grid/v1beta1/query.proto /* Package types is a reverse proxy. It translates gRPC into RESTful JSON APIs. */ package types import ( "context" "io" "net/http" "github.com/golang/protobuf/descriptor" "github.com/golang/protobuf/proto" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/grpc-ecosystem/grpc-gateway/utilities" "google.golang.org/grpc" "google.golang.org/grpc/codes" "google.golang.org/grpc/grpclog" "google.golang.org/grpc/metadata" "google.golang.org/grpc/status" ) // Suppress "imported and not used" errors var ( _ codes.Code _ io.Reader _ status.Status _ = runtime.String _ = utilities.NewDoubleArray _ = descriptor.ForMessage _ = metadata.Join ) func request_Query_Params_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryParamsRequest var metadata runtime.ServerMetadata msg, err := client.Params(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_Params_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryParamsRequest var metadata runtime.ServerMetadata msg, err := server.Params(ctx, &protoReq) return msg, metadata, err } var filter_Query_SourceRoutes_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} func request_Query_SourceRoutes_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QuerySourceRequest var metadata runtime.ServerMetadata if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_SourceRoutes_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := client.SourceRoutes(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_SourceRoutes_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QuerySourceRequest var metadata runtime.ServerMetadata if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_SourceRoutes_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := server.SourceRoutes(ctx, &protoReq) return msg, metadata, err } var filter_Query_DestinationRoutes_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} func request_Query_DestinationRoutes_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryDestinationRequest var metadata runtime.ServerMetadata if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_DestinationRoutes_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := client.DestinationRoutes(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_DestinationRoutes_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryDestinationRequest var metadata runtime.ServerMetadata if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_DestinationRoutes_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := server.DestinationRoutes(ctx, &protoReq) return msg, metadata, err } var filter_Query_DestinationRoutedEnergy_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} func request_Query_DestinationRoutedEnergy_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryDestinationRequest var metadata runtime.ServerMetadata if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_DestinationRoutedEnergy_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := client.DestinationRoutedEnergy(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_DestinationRoutedEnergy_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryDestinationRequest var metadata runtime.ServerMetadata if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_DestinationRoutedEnergy_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := server.DestinationRoutedEnergy(ctx, &protoReq) return msg, metadata, err } var filter_Query_SourceRoutedEnergy_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} func request_Query_SourceRoutedEnergy_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QuerySourceRequest var metadata runtime.ServerMetadata if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_SourceRoutedEnergy_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := client.SourceRoutedEnergy(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_SourceRoutedEnergy_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QuerySourceRequest var metadata runtime.ServerMetadata if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_SourceRoutedEnergy_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := server.SourceRoutedEnergy(ctx, &protoReq) return msg, metadata, err } var filter_Query_Route_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} func request_Query_Route_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryRouteRequest var metadata runtime.ServerMetadata if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_Route_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := client.Route(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_Route_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryRouteRequest var metadata runtime.ServerMetadata if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_Route_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := server.Route(ctx, &protoReq) return msg, metadata, err } var filter_Query_Routes_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} func request_Query_Routes_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryRoutesRequest var metadata runtime.ServerMetadata if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_Routes_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := client.Routes(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_Routes_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryRoutesRequest var metadata runtime.ServerMetadata if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_Routes_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := server.Routes(ctx, &protoReq) return msg, metadata, err } // RegisterQueryHandlerServer registers the http handlers for service Query to "mux". // UnaryRPC :call QueryServer directly. // StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. // Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterQueryHandlerFromEndpoint instead. func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, server QueryServer) error { mux.Handle("GET", pattern_Query_Params_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_Params_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Params_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_SourceRoutes_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_SourceRoutes_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_SourceRoutes_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_DestinationRoutes_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_DestinationRoutes_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_DestinationRoutes_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_DestinationRoutedEnergy_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_DestinationRoutedEnergy_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_DestinationRoutedEnergy_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_SourceRoutedEnergy_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_SourceRoutedEnergy_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_SourceRoutedEnergy_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_Route_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_Route_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Route_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_Routes_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_Routes_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Routes_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) return nil } // RegisterQueryHandlerFromEndpoint is same as RegisterQueryHandler but // automatically dials to "endpoint" and closes the connection when "ctx" gets done. func RegisterQueryHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error) { conn, err := grpc.Dial(endpoint, opts...) if err != nil { return err } defer func() { if err != nil { if cerr := conn.Close(); cerr != nil { grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr) } return } go func() { <-ctx.Done() if cerr := conn.Close(); cerr != nil { grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr) } }() }() return RegisterQueryHandler(ctx, mux, conn) } // RegisterQueryHandler registers the http handlers for service Query to "mux". // The handlers forward requests to the grpc endpoint over "conn". func RegisterQueryHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error { return RegisterQueryHandlerClient(ctx, mux, NewQueryClient(conn)) } // RegisterQueryHandlerClient registers the http handlers for service Query // to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "QueryClient". // Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "QueryClient" // doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in // "QueryClient" to call the correct interceptors. func RegisterQueryHandlerClient(ctx context.Context, mux *runtime.ServeMux, client QueryClient) error { mux.Handle("GET", pattern_Query_Params_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_Params_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Params_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_SourceRoutes_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_SourceRoutes_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_SourceRoutes_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_DestinationRoutes_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_DestinationRoutes_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_DestinationRoutes_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_DestinationRoutedEnergy_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_DestinationRoutedEnergy_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_DestinationRoutedEnergy_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_SourceRoutedEnergy_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_SourceRoutedEnergy_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_SourceRoutedEnergy_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_Route_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_Route_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Route_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_Routes_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_Routes_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Routes_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) return nil } var ( pattern_Query_Params_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 1, 2, 3}, []string{"cyber", "grid", "v1beta1", "params"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_SourceRoutes_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 1, 2, 3}, []string{"cyber", "grid", "v1beta1", "source_routes"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_DestinationRoutes_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 1, 2, 3}, []string{"cyber", "grid", "v1beta1", "destination_routes"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_DestinationRoutedEnergy_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 1, 2, 3}, []string{"cyber", "grid", "v1beta1", "destination_routed_energy"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_SourceRoutedEnergy_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 1, 2, 3}, []string{"cyber", "grid", "v1beta1", "source_routed_energy"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_Route_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 1, 2, 3}, []string{"cyber", "grid", "v1beta1", "route"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_Routes_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 1, 2, 3}, []string{"cyber", "grid", "v1beta1", "routes"}, "", runtime.AssumeColonVerbOpt(false))) ) var ( forward_Query_Params_0 = runtime.ForwardResponseMessage forward_Query_SourceRoutes_0 = runtime.ForwardResponseMessage forward_Query_DestinationRoutes_0 = runtime.ForwardResponseMessage forward_Query_DestinationRoutedEnergy_0 = runtime.ForwardResponseMessage forward_Query_SourceRoutedEnergy_0 = runtime.ForwardResponseMessage forward_Query_Route_0 = runtime.ForwardResponseMessage forward_Query_Routes_0 = runtime.ForwardResponseMessage ) ================================================ FILE: x/grid/types/route.go ================================================ package types import ( "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" ) // NewRoute creates a new route object func NewRoute(src sdk.AccAddress, dst sdk.AccAddress, name string, value sdk.Coins) Route { return Route{ Source: src.String(), Destination: dst.String(), Name: name, Value: value, } } type Routes []Route func NewValue(coins sdk.Coins) Value { return Value{coins} } // MustMarshalRoute returns the route bytes. Panics if fails func MustMarshalRoute(cdc codec.BinaryCodec, route Route) []byte { return cdc.MustMarshal(&route) } // MustUnmarshalRoute return the unmarshaled route from bytes. Panics if fails. func MustUnmarshalRoute(cdc codec.BinaryCodec, value []byte) Route { route, err := UnmarshalRoute(cdc, value) if err != nil { panic(err) } return route } func UnmarshalRoute(cdc codec.BinaryCodec, value []byte) (route Route, err error) { err = cdc.Unmarshal(value, &route) return route, err } ================================================ FILE: x/grid/types/tx.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: cyber/grid/v1beta1/tx.proto package types import ( context "context" fmt "fmt" io "io" math "math" math_bits "math/bits" _ "github.com/cosmos/cosmos-proto" _ "github.com/cosmos/cosmos-sdk/types" github_com_cosmos_cosmos_sdk_types "github.com/cosmos/cosmos-sdk/types" _ "github.com/cosmos/cosmos-sdk/types/msgservice" _ "github.com/cosmos/gogoproto/gogoproto" grpc1 "github.com/cosmos/gogoproto/grpc" proto "github.com/cosmos/gogoproto/proto" grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" ) // Reference imports to suppress errors if they are not otherwise used. var ( _ = proto.Marshal _ = fmt.Errorf _ = math.Inf ) // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package type MsgCreateRoute struct { Source string `protobuf:"bytes,1,opt,name=source,proto3" json:"source,omitempty"` Destination string `protobuf:"bytes,2,opt,name=destination,proto3" json:"destination,omitempty"` Name string `protobuf:"bytes,3,opt,name=name,proto3" json:"name,omitempty"` } func (m *MsgCreateRoute) Reset() { *m = MsgCreateRoute{} } func (m *MsgCreateRoute) String() string { return proto.CompactTextString(m) } func (*MsgCreateRoute) ProtoMessage() {} func (*MsgCreateRoute) Descriptor() ([]byte, []int) { return fileDescriptor_c3762e80adb8270a, []int{0} } func (m *MsgCreateRoute) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgCreateRoute) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgCreateRoute.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgCreateRoute) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgCreateRoute.Merge(m, src) } func (m *MsgCreateRoute) XXX_Size() int { return m.Size() } func (m *MsgCreateRoute) XXX_DiscardUnknown() { xxx_messageInfo_MsgCreateRoute.DiscardUnknown(m) } var xxx_messageInfo_MsgCreateRoute proto.InternalMessageInfo func (m *MsgCreateRoute) GetSource() string { if m != nil { return m.Source } return "" } func (m *MsgCreateRoute) GetDestination() string { if m != nil { return m.Destination } return "" } func (m *MsgCreateRoute) GetName() string { if m != nil { return m.Name } return "" } type MsgEditRoute struct { Source string `protobuf:"bytes,1,opt,name=source,proto3" json:"source,omitempty"` Destination string `protobuf:"bytes,2,opt,name=destination,proto3" json:"destination,omitempty"` Value github_com_cosmos_cosmos_sdk_types.Coin `protobuf:"bytes,3,opt,name=value,proto3,casttype=github.com/cosmos/cosmos-sdk/types.Coin" json:"value"` } func (m *MsgEditRoute) Reset() { *m = MsgEditRoute{} } func (m *MsgEditRoute) String() string { return proto.CompactTextString(m) } func (*MsgEditRoute) ProtoMessage() {} func (*MsgEditRoute) Descriptor() ([]byte, []int) { return fileDescriptor_c3762e80adb8270a, []int{1} } func (m *MsgEditRoute) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgEditRoute) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgEditRoute.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgEditRoute) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgEditRoute.Merge(m, src) } func (m *MsgEditRoute) XXX_Size() int { return m.Size() } func (m *MsgEditRoute) XXX_DiscardUnknown() { xxx_messageInfo_MsgEditRoute.DiscardUnknown(m) } var xxx_messageInfo_MsgEditRoute proto.InternalMessageInfo func (m *MsgEditRoute) GetSource() string { if m != nil { return m.Source } return "" } func (m *MsgEditRoute) GetDestination() string { if m != nil { return m.Destination } return "" } func (m *MsgEditRoute) GetValue() github_com_cosmos_cosmos_sdk_types.Coin { if m != nil { return m.Value } return github_com_cosmos_cosmos_sdk_types.Coin{} } type MsgDeleteRoute struct { Source string `protobuf:"bytes,1,opt,name=source,proto3" json:"source,omitempty"` Destination string `protobuf:"bytes,2,opt,name=destination,proto3" json:"destination,omitempty"` } func (m *MsgDeleteRoute) Reset() { *m = MsgDeleteRoute{} } func (m *MsgDeleteRoute) String() string { return proto.CompactTextString(m) } func (*MsgDeleteRoute) ProtoMessage() {} func (*MsgDeleteRoute) Descriptor() ([]byte, []int) { return fileDescriptor_c3762e80adb8270a, []int{2} } func (m *MsgDeleteRoute) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgDeleteRoute) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgDeleteRoute.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgDeleteRoute) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgDeleteRoute.Merge(m, src) } func (m *MsgDeleteRoute) XXX_Size() int { return m.Size() } func (m *MsgDeleteRoute) XXX_DiscardUnknown() { xxx_messageInfo_MsgDeleteRoute.DiscardUnknown(m) } var xxx_messageInfo_MsgDeleteRoute proto.InternalMessageInfo func (m *MsgDeleteRoute) GetSource() string { if m != nil { return m.Source } return "" } func (m *MsgDeleteRoute) GetDestination() string { if m != nil { return m.Destination } return "" } type MsgEditRouteName struct { Source string `protobuf:"bytes,1,opt,name=source,proto3" json:"source,omitempty"` Destination string `protobuf:"bytes,2,opt,name=destination,proto3" json:"destination,omitempty"` Name string `protobuf:"bytes,3,opt,name=name,proto3" json:"name,omitempty"` } func (m *MsgEditRouteName) Reset() { *m = MsgEditRouteName{} } func (m *MsgEditRouteName) String() string { return proto.CompactTextString(m) } func (*MsgEditRouteName) ProtoMessage() {} func (*MsgEditRouteName) Descriptor() ([]byte, []int) { return fileDescriptor_c3762e80adb8270a, []int{3} } func (m *MsgEditRouteName) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgEditRouteName) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgEditRouteName.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgEditRouteName) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgEditRouteName.Merge(m, src) } func (m *MsgEditRouteName) XXX_Size() int { return m.Size() } func (m *MsgEditRouteName) XXX_DiscardUnknown() { xxx_messageInfo_MsgEditRouteName.DiscardUnknown(m) } var xxx_messageInfo_MsgEditRouteName proto.InternalMessageInfo func (m *MsgEditRouteName) GetSource() string { if m != nil { return m.Source } return "" } func (m *MsgEditRouteName) GetDestination() string { if m != nil { return m.Destination } return "" } func (m *MsgEditRouteName) GetName() string { if m != nil { return m.Name } return "" } type MsgUpdateParams struct { Authority string `protobuf:"bytes,1,opt,name=authority,proto3" json:"authority,omitempty"` Params Params `protobuf:"bytes,2,opt,name=params,proto3" json:"params"` } func (m *MsgUpdateParams) Reset() { *m = MsgUpdateParams{} } func (m *MsgUpdateParams) String() string { return proto.CompactTextString(m) } func (*MsgUpdateParams) ProtoMessage() {} func (*MsgUpdateParams) Descriptor() ([]byte, []int) { return fileDescriptor_c3762e80adb8270a, []int{4} } func (m *MsgUpdateParams) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgUpdateParams) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgUpdateParams.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgUpdateParams) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgUpdateParams.Merge(m, src) } func (m *MsgUpdateParams) XXX_Size() int { return m.Size() } func (m *MsgUpdateParams) XXX_DiscardUnknown() { xxx_messageInfo_MsgUpdateParams.DiscardUnknown(m) } var xxx_messageInfo_MsgUpdateParams proto.InternalMessageInfo func (m *MsgUpdateParams) GetAuthority() string { if m != nil { return m.Authority } return "" } func (m *MsgUpdateParams) GetParams() Params { if m != nil { return m.Params } return Params{} } type MsgCreateRouteResponse struct{} func (m *MsgCreateRouteResponse) Reset() { *m = MsgCreateRouteResponse{} } func (m *MsgCreateRouteResponse) String() string { return proto.CompactTextString(m) } func (*MsgCreateRouteResponse) ProtoMessage() {} func (*MsgCreateRouteResponse) Descriptor() ([]byte, []int) { return fileDescriptor_c3762e80adb8270a, []int{5} } func (m *MsgCreateRouteResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgCreateRouteResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgCreateRouteResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgCreateRouteResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgCreateRouteResponse.Merge(m, src) } func (m *MsgCreateRouteResponse) XXX_Size() int { return m.Size() } func (m *MsgCreateRouteResponse) XXX_DiscardUnknown() { xxx_messageInfo_MsgCreateRouteResponse.DiscardUnknown(m) } var xxx_messageInfo_MsgCreateRouteResponse proto.InternalMessageInfo type MsgEditRouteResponse struct{} func (m *MsgEditRouteResponse) Reset() { *m = MsgEditRouteResponse{} } func (m *MsgEditRouteResponse) String() string { return proto.CompactTextString(m) } func (*MsgEditRouteResponse) ProtoMessage() {} func (*MsgEditRouteResponse) Descriptor() ([]byte, []int) { return fileDescriptor_c3762e80adb8270a, []int{6} } func (m *MsgEditRouteResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgEditRouteResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgEditRouteResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgEditRouteResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgEditRouteResponse.Merge(m, src) } func (m *MsgEditRouteResponse) XXX_Size() int { return m.Size() } func (m *MsgEditRouteResponse) XXX_DiscardUnknown() { xxx_messageInfo_MsgEditRouteResponse.DiscardUnknown(m) } var xxx_messageInfo_MsgEditRouteResponse proto.InternalMessageInfo type MsgDeleteRouteResponse struct{} func (m *MsgDeleteRouteResponse) Reset() { *m = MsgDeleteRouteResponse{} } func (m *MsgDeleteRouteResponse) String() string { return proto.CompactTextString(m) } func (*MsgDeleteRouteResponse) ProtoMessage() {} func (*MsgDeleteRouteResponse) Descriptor() ([]byte, []int) { return fileDescriptor_c3762e80adb8270a, []int{7} } func (m *MsgDeleteRouteResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgDeleteRouteResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgDeleteRouteResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgDeleteRouteResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgDeleteRouteResponse.Merge(m, src) } func (m *MsgDeleteRouteResponse) XXX_Size() int { return m.Size() } func (m *MsgDeleteRouteResponse) XXX_DiscardUnknown() { xxx_messageInfo_MsgDeleteRouteResponse.DiscardUnknown(m) } var xxx_messageInfo_MsgDeleteRouteResponse proto.InternalMessageInfo type MsgEditRouteNameResponse struct{} func (m *MsgEditRouteNameResponse) Reset() { *m = MsgEditRouteNameResponse{} } func (m *MsgEditRouteNameResponse) String() string { return proto.CompactTextString(m) } func (*MsgEditRouteNameResponse) ProtoMessage() {} func (*MsgEditRouteNameResponse) Descriptor() ([]byte, []int) { return fileDescriptor_c3762e80adb8270a, []int{8} } func (m *MsgEditRouteNameResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgEditRouteNameResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgEditRouteNameResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgEditRouteNameResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgEditRouteNameResponse.Merge(m, src) } func (m *MsgEditRouteNameResponse) XXX_Size() int { return m.Size() } func (m *MsgEditRouteNameResponse) XXX_DiscardUnknown() { xxx_messageInfo_MsgEditRouteNameResponse.DiscardUnknown(m) } var xxx_messageInfo_MsgEditRouteNameResponse proto.InternalMessageInfo type MsgUpdateParamsResponse struct{} func (m *MsgUpdateParamsResponse) Reset() { *m = MsgUpdateParamsResponse{} } func (m *MsgUpdateParamsResponse) String() string { return proto.CompactTextString(m) } func (*MsgUpdateParamsResponse) ProtoMessage() {} func (*MsgUpdateParamsResponse) Descriptor() ([]byte, []int) { return fileDescriptor_c3762e80adb8270a, []int{9} } func (m *MsgUpdateParamsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgUpdateParamsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgUpdateParamsResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgUpdateParamsResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgUpdateParamsResponse.Merge(m, src) } func (m *MsgUpdateParamsResponse) XXX_Size() int { return m.Size() } func (m *MsgUpdateParamsResponse) XXX_DiscardUnknown() { xxx_messageInfo_MsgUpdateParamsResponse.DiscardUnknown(m) } var xxx_messageInfo_MsgUpdateParamsResponse proto.InternalMessageInfo func init() { proto.RegisterType((*MsgCreateRoute)(nil), "cyber.grid.v1beta1.MsgCreateRoute") proto.RegisterType((*MsgEditRoute)(nil), "cyber.grid.v1beta1.MsgEditRoute") proto.RegisterType((*MsgDeleteRoute)(nil), "cyber.grid.v1beta1.MsgDeleteRoute") proto.RegisterType((*MsgEditRouteName)(nil), "cyber.grid.v1beta1.MsgEditRouteName") proto.RegisterType((*MsgUpdateParams)(nil), "cyber.grid.v1beta1.MsgUpdateParams") proto.RegisterType((*MsgCreateRouteResponse)(nil), "cyber.grid.v1beta1.MsgCreateRouteResponse") proto.RegisterType((*MsgEditRouteResponse)(nil), "cyber.grid.v1beta1.MsgEditRouteResponse") proto.RegisterType((*MsgDeleteRouteResponse)(nil), "cyber.grid.v1beta1.MsgDeleteRouteResponse") proto.RegisterType((*MsgEditRouteNameResponse)(nil), "cyber.grid.v1beta1.MsgEditRouteNameResponse") proto.RegisterType((*MsgUpdateParamsResponse)(nil), "cyber.grid.v1beta1.MsgUpdateParamsResponse") } func init() { proto.RegisterFile("cyber/grid/v1beta1/tx.proto", fileDescriptor_c3762e80adb8270a) } var fileDescriptor_c3762e80adb8270a = []byte{ // 570 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x54, 0x41, 0x8b, 0xd3, 0x40, 0x14, 0x6e, 0xec, 0x5a, 0xe8, 0xeb, 0xba, 0xca, 0x50, 0xba, 0x69, 0x84, 0x6c, 0x89, 0x82, 0xcb, 0x6a, 0x13, 0x5a, 0x41, 0xc4, 0x9b, 0x5d, 0x05, 0x11, 0x2a, 0x12, 0x11, 0x41, 0x58, 0xed, 0x34, 0x19, 0x66, 0x83, 0x9b, 0x4c, 0xc9, 0x4c, 0xcb, 0xf6, 0xea, 0x2f, 0x10, 0xfc, 0x17, 0x9e, 0x3c, 0xf8, 0x23, 0xf6, 0xb8, 0x78, 0xf2, 0xb4, 0x48, 0x7b, 0xf0, 0x3f, 0x78, 0x92, 0x64, 0xa6, 0x69, 0xba, 0xb6, 0x74, 0x61, 0xf7, 0x94, 0x64, 0xbe, 0xef, 0x7d, 0x6f, 0xde, 0xc7, 0x97, 0x07, 0xb7, 0xbd, 0x71, 0x9f, 0xc4, 0x0e, 0x8d, 0x03, 0xdf, 0x19, 0xb5, 0xfa, 0x44, 0xe0, 0x96, 0x23, 0x8e, 0xed, 0x41, 0xcc, 0x04, 0x43, 0x28, 0x05, 0xed, 0x04, 0xb4, 0x15, 0x68, 0x54, 0x29, 0xa3, 0x2c, 0x85, 0x9d, 0xe4, 0x4d, 0x32, 0x8d, 0x6d, 0x8f, 0xf1, 0x90, 0x71, 0x27, 0xe4, 0xd4, 0x19, 0xb5, 0x92, 0x87, 0x02, 0xea, 0x12, 0xf8, 0x28, 0x2b, 0xe4, 0x87, 0x82, 0xcc, 0x65, 0xad, 0xc7, 0x03, 0x32, 0xc7, 0xa5, 0x66, 0x1f, 0x73, 0x92, 0x11, 0x3c, 0x16, 0x44, 0x12, 0xb7, 0x3e, 0xc0, 0x56, 0x97, 0xd3, 0xfd, 0x98, 0x60, 0x41, 0x5c, 0x36, 0x14, 0x04, 0xd5, 0xa0, 0xc4, 0xd9, 0x30, 0xf6, 0x88, 0xae, 0x35, 0xb4, 0xdd, 0xb2, 0xab, 0xbe, 0x50, 0x03, 0x2a, 0x3e, 0xe1, 0x22, 0x88, 0xb0, 0x08, 0x58, 0xa4, 0x5f, 0x4b, 0xc1, 0xfc, 0x11, 0x42, 0xb0, 0x11, 0xe1, 0x90, 0xe8, 0xc5, 0x14, 0x4a, 0xdf, 0xad, 0x6f, 0x1a, 0x6c, 0x76, 0x39, 0x7d, 0xee, 0x07, 0xe2, 0xb2, 0xf2, 0x3d, 0xb8, 0x3e, 0xc2, 0x47, 0x43, 0xa9, 0x5f, 0x69, 0xd7, 0x6d, 0x65, 0x44, 0x32, 0xda, 0xcc, 0x59, 0x7b, 0x9f, 0x05, 0x51, 0xc7, 0x39, 0x39, 0xdb, 0x29, 0xfc, 0x3d, 0xdb, 0xb9, 0x47, 0x03, 0x71, 0x38, 0xec, 0xdb, 0x1e, 0x0b, 0x95, 0x6b, 0xea, 0xd1, 0xe4, 0xfe, 0x27, 0x65, 0x53, 0x52, 0xe0, 0x4a, 0x61, 0xeb, 0x65, 0x6a, 0xc6, 0x33, 0x72, 0x44, 0x2e, 0x6d, 0x86, 0xd5, 0x83, 0x5b, 0xf9, 0xb9, 0x5f, 0xe1, 0xf0, 0xaa, 0xad, 0xfd, 0xaa, 0xc1, 0xcd, 0x2e, 0xa7, 0x6f, 0x07, 0x3e, 0x16, 0xe4, 0x35, 0x8e, 0x71, 0xc8, 0xd1, 0x23, 0x28, 0xe3, 0xa1, 0x38, 0x64, 0x71, 0x20, 0xc6, 0xb2, 0x49, 0x47, 0xff, 0xf9, 0xa3, 0x59, 0x55, 0x56, 0x3d, 0xf5, 0xfd, 0x98, 0x70, 0xfe, 0x46, 0xc4, 0x41, 0x44, 0xdd, 0x39, 0x15, 0x3d, 0x86, 0xd2, 0x20, 0x55, 0x48, 0x9b, 0x57, 0xda, 0x86, 0xfd, 0x7f, 0x6a, 0x6d, 0xd9, 0xa3, 0xb3, 0x91, 0xb8, 0xeb, 0x2a, 0xfe, 0x93, 0xad, 0xcf, 0x7f, 0xbe, 0xef, 0xcd, 0x95, 0x2c, 0x1d, 0x6a, 0x8b, 0x81, 0x72, 0x09, 0x1f, 0xb0, 0x88, 0x13, 0xab, 0x06, 0xd5, 0xbc, 0x23, 0xd9, 0xb9, 0xac, 0xc8, 0xb9, 0x9e, 0x21, 0x06, 0xe8, 0xe7, 0x3d, 0xcc, 0xb0, 0x3a, 0x6c, 0x9f, 0x1b, 0x7e, 0x06, 0xb5, 0xa7, 0x45, 0x28, 0x76, 0x39, 0x45, 0x07, 0x50, 0xc9, 0x07, 0xdb, 0x5a, 0x36, 0xd3, 0xe2, 0x5d, 0x8d, 0xbd, 0xf5, 0x9c, 0x59, 0x1b, 0xf4, 0x0e, 0xca, 0xf3, 0x58, 0x37, 0x56, 0x14, 0x66, 0x0c, 0x63, 0x77, 0x1d, 0x23, 0x13, 0x3e, 0x80, 0x4a, 0x3e, 0x83, 0xab, 0xee, 0x9d, 0xe3, 0xac, 0xbc, 0xf7, 0x12, 0x57, 0x91, 0x07, 0x37, 0x16, 0x63, 0x79, 0x77, 0xdd, 0xcd, 0x12, 0x96, 0xf1, 0xe0, 0x22, 0xac, 0xac, 0x49, 0x0f, 0x36, 0x17, 0x82, 0x79, 0x67, 0x45, 0x75, 0x9e, 0x64, 0xdc, 0xbf, 0x00, 0x69, 0xd6, 0xa1, 0xf3, 0xe2, 0x64, 0x62, 0x6a, 0xa7, 0x13, 0x53, 0xfb, 0x3d, 0x31, 0xb5, 0x2f, 0x53, 0xb3, 0x70, 0x3a, 0x35, 0x0b, 0xbf, 0xa6, 0x66, 0xe1, 0xbd, 0x9d, 0xff, 0xed, 0x13, 0x41, 0x8f, 0x45, 0x34, 0xc9, 0xbd, 0x43, 0x59, 0x53, 0xee, 0xcb, 0x63, 0xb9, 0x31, 0xd3, 0x15, 0xd0, 0x2f, 0xa5, 0xab, 0xf0, 0xe1, 0xbf, 0x00, 0x00, 0x00, 0xff, 0xff, 0x22, 0x43, 0x84, 0x7f, 0xc7, 0x05, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. var ( _ context.Context _ grpc.ClientConn ) // This is a compile-time assertion to ensure that this generated file // is compatible with the grpc package it is being compiled against. const _ = grpc.SupportPackageIsVersion4 // MsgClient is the client API for Msg service. // // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. type MsgClient interface { CreateRoute(ctx context.Context, in *MsgCreateRoute, opts ...grpc.CallOption) (*MsgCreateRouteResponse, error) EditRoute(ctx context.Context, in *MsgEditRoute, opts ...grpc.CallOption) (*MsgEditRouteResponse, error) DeleteRoute(ctx context.Context, in *MsgDeleteRoute, opts ...grpc.CallOption) (*MsgDeleteRouteResponse, error) EditRouteName(ctx context.Context, in *MsgEditRouteName, opts ...grpc.CallOption) (*MsgEditRouteNameResponse, error) UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) } type msgClient struct { cc grpc1.ClientConn } func NewMsgClient(cc grpc1.ClientConn) MsgClient { return &msgClient{cc} } func (c *msgClient) CreateRoute(ctx context.Context, in *MsgCreateRoute, opts ...grpc.CallOption) (*MsgCreateRouteResponse, error) { out := new(MsgCreateRouteResponse) err := c.cc.Invoke(ctx, "/cyber.grid.v1beta1.Msg/CreateRoute", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *msgClient) EditRoute(ctx context.Context, in *MsgEditRoute, opts ...grpc.CallOption) (*MsgEditRouteResponse, error) { out := new(MsgEditRouteResponse) err := c.cc.Invoke(ctx, "/cyber.grid.v1beta1.Msg/EditRoute", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *msgClient) DeleteRoute(ctx context.Context, in *MsgDeleteRoute, opts ...grpc.CallOption) (*MsgDeleteRouteResponse, error) { out := new(MsgDeleteRouteResponse) err := c.cc.Invoke(ctx, "/cyber.grid.v1beta1.Msg/DeleteRoute", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *msgClient) EditRouteName(ctx context.Context, in *MsgEditRouteName, opts ...grpc.CallOption) (*MsgEditRouteNameResponse, error) { out := new(MsgEditRouteNameResponse) err := c.cc.Invoke(ctx, "/cyber.grid.v1beta1.Msg/EditRouteName", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *msgClient) UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) { out := new(MsgUpdateParamsResponse) err := c.cc.Invoke(ctx, "/cyber.grid.v1beta1.Msg/UpdateParams", in, out, opts...) if err != nil { return nil, err } return out, nil } // MsgServer is the server API for Msg service. type MsgServer interface { CreateRoute(context.Context, *MsgCreateRoute) (*MsgCreateRouteResponse, error) EditRoute(context.Context, *MsgEditRoute) (*MsgEditRouteResponse, error) DeleteRoute(context.Context, *MsgDeleteRoute) (*MsgDeleteRouteResponse, error) EditRouteName(context.Context, *MsgEditRouteName) (*MsgEditRouteNameResponse, error) UpdateParams(context.Context, *MsgUpdateParams) (*MsgUpdateParamsResponse, error) } // UnimplementedMsgServer can be embedded to have forward compatible implementations. type UnimplementedMsgServer struct{} func (*UnimplementedMsgServer) CreateRoute(ctx context.Context, req *MsgCreateRoute) (*MsgCreateRouteResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method CreateRoute not implemented") } func (*UnimplementedMsgServer) EditRoute(ctx context.Context, req *MsgEditRoute) (*MsgEditRouteResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method EditRoute not implemented") } func (*UnimplementedMsgServer) DeleteRoute(ctx context.Context, req *MsgDeleteRoute) (*MsgDeleteRouteResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method DeleteRoute not implemented") } func (*UnimplementedMsgServer) EditRouteName(ctx context.Context, req *MsgEditRouteName) (*MsgEditRouteNameResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method EditRouteName not implemented") } func (*UnimplementedMsgServer) UpdateParams(ctx context.Context, req *MsgUpdateParams) (*MsgUpdateParamsResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method UpdateParams not implemented") } func RegisterMsgServer(s grpc1.Server, srv MsgServer) { s.RegisterService(&_Msg_serviceDesc, srv) } func _Msg_CreateRoute_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgCreateRoute) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(MsgServer).CreateRoute(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.grid.v1beta1.Msg/CreateRoute", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).CreateRoute(ctx, req.(*MsgCreateRoute)) } return interceptor(ctx, in, info, handler) } func _Msg_EditRoute_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgEditRoute) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(MsgServer).EditRoute(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.grid.v1beta1.Msg/EditRoute", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).EditRoute(ctx, req.(*MsgEditRoute)) } return interceptor(ctx, in, info, handler) } func _Msg_DeleteRoute_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgDeleteRoute) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(MsgServer).DeleteRoute(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.grid.v1beta1.Msg/DeleteRoute", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).DeleteRoute(ctx, req.(*MsgDeleteRoute)) } return interceptor(ctx, in, info, handler) } func _Msg_EditRouteName_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgEditRouteName) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(MsgServer).EditRouteName(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.grid.v1beta1.Msg/EditRouteName", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).EditRouteName(ctx, req.(*MsgEditRouteName)) } return interceptor(ctx, in, info, handler) } func _Msg_UpdateParams_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgUpdateParams) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(MsgServer).UpdateParams(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.grid.v1beta1.Msg/UpdateParams", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).UpdateParams(ctx, req.(*MsgUpdateParams)) } return interceptor(ctx, in, info, handler) } var _Msg_serviceDesc = grpc.ServiceDesc{ ServiceName: "cyber.grid.v1beta1.Msg", HandlerType: (*MsgServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "CreateRoute", Handler: _Msg_CreateRoute_Handler, }, { MethodName: "EditRoute", Handler: _Msg_EditRoute_Handler, }, { MethodName: "DeleteRoute", Handler: _Msg_DeleteRoute_Handler, }, { MethodName: "EditRouteName", Handler: _Msg_EditRouteName_Handler, }, { MethodName: "UpdateParams", Handler: _Msg_UpdateParams_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "cyber/grid/v1beta1/tx.proto", } func (m *MsgCreateRoute) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgCreateRoute) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgCreateRoute) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.Name) > 0 { i -= len(m.Name) copy(dAtA[i:], m.Name) i = encodeVarintTx(dAtA, i, uint64(len(m.Name))) i-- dAtA[i] = 0x1a } if len(m.Destination) > 0 { i -= len(m.Destination) copy(dAtA[i:], m.Destination) i = encodeVarintTx(dAtA, i, uint64(len(m.Destination))) i-- dAtA[i] = 0x12 } if len(m.Source) > 0 { i -= len(m.Source) copy(dAtA[i:], m.Source) i = encodeVarintTx(dAtA, i, uint64(len(m.Source))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *MsgEditRoute) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgEditRoute) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgEditRoute) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.Value.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintTx(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x1a if len(m.Destination) > 0 { i -= len(m.Destination) copy(dAtA[i:], m.Destination) i = encodeVarintTx(dAtA, i, uint64(len(m.Destination))) i-- dAtA[i] = 0x12 } if len(m.Source) > 0 { i -= len(m.Source) copy(dAtA[i:], m.Source) i = encodeVarintTx(dAtA, i, uint64(len(m.Source))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *MsgDeleteRoute) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgDeleteRoute) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgDeleteRoute) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.Destination) > 0 { i -= len(m.Destination) copy(dAtA[i:], m.Destination) i = encodeVarintTx(dAtA, i, uint64(len(m.Destination))) i-- dAtA[i] = 0x12 } if len(m.Source) > 0 { i -= len(m.Source) copy(dAtA[i:], m.Source) i = encodeVarintTx(dAtA, i, uint64(len(m.Source))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *MsgEditRouteName) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgEditRouteName) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgEditRouteName) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.Name) > 0 { i -= len(m.Name) copy(dAtA[i:], m.Name) i = encodeVarintTx(dAtA, i, uint64(len(m.Name))) i-- dAtA[i] = 0x1a } if len(m.Destination) > 0 { i -= len(m.Destination) copy(dAtA[i:], m.Destination) i = encodeVarintTx(dAtA, i, uint64(len(m.Destination))) i-- dAtA[i] = 0x12 } if len(m.Source) > 0 { i -= len(m.Source) copy(dAtA[i:], m.Source) i = encodeVarintTx(dAtA, i, uint64(len(m.Source))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *MsgUpdateParams) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgUpdateParams) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgUpdateParams) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.Params.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintTx(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 if len(m.Authority) > 0 { i -= len(m.Authority) copy(dAtA[i:], m.Authority) i = encodeVarintTx(dAtA, i, uint64(len(m.Authority))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *MsgCreateRouteResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgCreateRouteResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgCreateRouteResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *MsgEditRouteResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgEditRouteResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgEditRouteResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *MsgDeleteRouteResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgDeleteRouteResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgDeleteRouteResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *MsgEditRouteNameResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgEditRouteNameResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgEditRouteNameResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *MsgUpdateParamsResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgUpdateParamsResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgUpdateParamsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func encodeVarintTx(dAtA []byte, offset int, v uint64) int { offset -= sovTx(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *MsgCreateRoute) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Source) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = len(m.Destination) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = len(m.Name) if l > 0 { n += 1 + l + sovTx(uint64(l)) } return n } func (m *MsgEditRoute) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Source) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = len(m.Destination) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = m.Value.Size() n += 1 + l + sovTx(uint64(l)) return n } func (m *MsgDeleteRoute) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Source) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = len(m.Destination) if l > 0 { n += 1 + l + sovTx(uint64(l)) } return n } func (m *MsgEditRouteName) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Source) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = len(m.Destination) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = len(m.Name) if l > 0 { n += 1 + l + sovTx(uint64(l)) } return n } func (m *MsgUpdateParams) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Authority) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = m.Params.Size() n += 1 + l + sovTx(uint64(l)) return n } func (m *MsgCreateRouteResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *MsgEditRouteResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *MsgDeleteRouteResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *MsgEditRouteNameResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *MsgUpdateParamsResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func sovTx(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozTx(x uint64) (n int) { return sovTx(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *MsgCreateRoute) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgCreateRoute: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgCreateRoute: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Source", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Source = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Destination", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Destination = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgEditRoute) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgEditRoute: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgEditRoute: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Source", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Source = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Destination", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Destination = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Value", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Value.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgDeleteRoute) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgDeleteRoute: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgDeleteRoute: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Source", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Source = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Destination", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Destination = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgEditRouteName) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgEditRouteName: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgEditRouteName: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Source", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Source = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Destination", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Destination = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgUpdateParams) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgUpdateParams: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgUpdateParams: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Authority", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Authority = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Params.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgCreateRouteResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgCreateRouteResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgCreateRouteResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgEditRouteResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgEditRouteResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgEditRouteResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgDeleteRouteResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgDeleteRouteResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgDeleteRouteResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgEditRouteNameResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgEditRouteNameResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgEditRouteNameResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgUpdateParamsResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgUpdateParamsResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgUpdateParamsResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipTx(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTx } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTx } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTx } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthTx } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupTx } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthTx } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthTx = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowTx = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupTx = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/grid/types/types.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: cyber/grid/v1beta1/types.proto package types import ( fmt "fmt" io "io" math "math" math_bits "math/bits" github_com_cosmos_cosmos_sdk_types "github.com/cosmos/cosmos-sdk/types" types "github.com/cosmos/cosmos-sdk/types" _ "github.com/cosmos/gogoproto/gogoproto" proto "github.com/cosmos/gogoproto/proto" ) // Reference imports to suppress errors if they are not otherwise used. var ( _ = proto.Marshal _ = fmt.Errorf _ = math.Inf ) // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package type Params struct { MaxRoutes uint32 `protobuf:"varint,1,opt,name=max_routes,json=maxRoutes,proto3" json:"max_routes,omitempty"` } func (m *Params) Reset() { *m = Params{} } func (m *Params) String() string { return proto.CompactTextString(m) } func (*Params) ProtoMessage() {} func (*Params) Descriptor() ([]byte, []int) { return fileDescriptor_1673181069a7f05c, []int{0} } func (m *Params) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *Params) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_Params.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *Params) XXX_Merge(src proto.Message) { xxx_messageInfo_Params.Merge(m, src) } func (m *Params) XXX_Size() int { return m.Size() } func (m *Params) XXX_DiscardUnknown() { xxx_messageInfo_Params.DiscardUnknown(m) } var xxx_messageInfo_Params proto.InternalMessageInfo func (m *Params) GetMaxRoutes() uint32 { if m != nil { return m.MaxRoutes } return 0 } type Route struct { Source string `protobuf:"bytes,1,opt,name=source,proto3" json:"source,omitempty"` Destination string `protobuf:"bytes,2,opt,name=destination,proto3" json:"destination,omitempty"` Name string `protobuf:"bytes,3,opt,name=name,proto3" json:"name,omitempty"` Value github_com_cosmos_cosmos_sdk_types.Coins `protobuf:"bytes,4,rep,name=value,proto3,castrepeated=github.com/cosmos/cosmos-sdk/types.Coins" json:"value"` } func (m *Route) Reset() { *m = Route{} } func (m *Route) String() string { return proto.CompactTextString(m) } func (*Route) ProtoMessage() {} func (*Route) Descriptor() ([]byte, []int) { return fileDescriptor_1673181069a7f05c, []int{1} } func (m *Route) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *Route) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_Route.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *Route) XXX_Merge(src proto.Message) { xxx_messageInfo_Route.Merge(m, src) } func (m *Route) XXX_Size() int { return m.Size() } func (m *Route) XXX_DiscardUnknown() { xxx_messageInfo_Route.DiscardUnknown(m) } var xxx_messageInfo_Route proto.InternalMessageInfo type Value struct { Value github_com_cosmos_cosmos_sdk_types.Coins `protobuf:"bytes,1,rep,name=value,proto3,castrepeated=github.com/cosmos/cosmos-sdk/types.Coins" json:"value"` } func (m *Value) Reset() { *m = Value{} } func (m *Value) String() string { return proto.CompactTextString(m) } func (*Value) ProtoMessage() {} func (*Value) Descriptor() ([]byte, []int) { return fileDescriptor_1673181069a7f05c, []int{2} } func (m *Value) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *Value) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_Value.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *Value) XXX_Merge(src proto.Message) { xxx_messageInfo_Value.Merge(m, src) } func (m *Value) XXX_Size() int { return m.Size() } func (m *Value) XXX_DiscardUnknown() { xxx_messageInfo_Value.DiscardUnknown(m) } var xxx_messageInfo_Value proto.InternalMessageInfo func init() { proto.RegisterType((*Params)(nil), "cyber.grid.v1beta1.Params") proto.RegisterType((*Route)(nil), "cyber.grid.v1beta1.Route") proto.RegisterType((*Value)(nil), "cyber.grid.v1beta1.Value") } func init() { proto.RegisterFile("cyber/grid/v1beta1/types.proto", fileDescriptor_1673181069a7f05c) } var fileDescriptor_1673181069a7f05c = []byte{ // 343 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xb4, 0x92, 0xbd, 0x4e, 0xc3, 0x30, 0x10, 0xc7, 0x63, 0xfa, 0x21, 0xea, 0x8a, 0xc5, 0x42, 0x28, 0x54, 0xc2, 0xa9, 0x3a, 0x75, 0xa9, 0x4d, 0x61, 0xeb, 0x58, 0x16, 0x46, 0x94, 0x81, 0x81, 0x05, 0x39, 0xa9, 0x15, 0x22, 0x48, 0xae, 0xb2, 0x9d, 0xaa, 0x7d, 0x03, 0x46, 0x1e, 0xa1, 0x33, 0x8f, 0xc1, 0xd4, 0xb1, 0x23, 0x13, 0xa0, 0x76, 0xe9, 0x63, 0xa0, 0xd8, 0x01, 0xfa, 0x02, 0x4c, 0x3e, 0xff, 0x7f, 0xe7, 0xfb, 0xf0, 0x1d, 0xa6, 0xf1, 0x22, 0x92, 0x8a, 0x27, 0x2a, 0x9d, 0xf0, 0xd9, 0x30, 0x92, 0x46, 0x0c, 0xb9, 0x59, 0x4c, 0xa5, 0x66, 0x53, 0x05, 0x06, 0x08, 0xb1, 0x9c, 0x95, 0x9c, 0x55, 0xbc, 0x73, 0x9c, 0x40, 0x02, 0x16, 0xf3, 0xd2, 0x72, 0x9e, 0x1d, 0x1a, 0x83, 0xce, 0x40, 0xf3, 0x48, 0x68, 0xf9, 0x1b, 0x2a, 0x86, 0x34, 0x77, 0xbc, 0x37, 0xc0, 0xcd, 0x1b, 0xa1, 0x44, 0xa6, 0xc9, 0x19, 0xc6, 0x99, 0x98, 0xdf, 0x2b, 0x28, 0x8c, 0xd4, 0x3e, 0xea, 0xa2, 0xfe, 0x51, 0xd8, 0xca, 0xc4, 0x3c, 0xb4, 0xc2, 0xa8, 0xbe, 0x5b, 0x06, 0xa8, 0xf7, 0x86, 0x70, 0xc3, 0x0a, 0xe4, 0x04, 0x37, 0x35, 0x14, 0x2a, 0x96, 0xd6, 0xb5, 0x15, 0x56, 0x37, 0xd2, 0xc5, 0xed, 0x89, 0xd4, 0x26, 0xcd, 0x85, 0x49, 0x21, 0xf7, 0x0f, 0x2c, 0xdc, 0x97, 0x08, 0xc1, 0xf5, 0x5c, 0x64, 0xd2, 0xaf, 0x59, 0x64, 0x6d, 0x22, 0x70, 0x63, 0x26, 0x9e, 0x0a, 0xe9, 0xd7, 0xbb, 0xb5, 0x7e, 0xfb, 0xe2, 0x94, 0xb9, 0xb2, 0x59, 0x59, 0xf6, 0x4f, 0x87, 0xec, 0x0a, 0xd2, 0x7c, 0x7c, 0xbe, 0xfa, 0x08, 0xbc, 0xd7, 0xcf, 0xa0, 0x9f, 0xa4, 0xe6, 0xa1, 0x88, 0x58, 0x0c, 0x19, 0xaf, 0x7a, 0x74, 0xc7, 0x40, 0x4f, 0x1e, 0xab, 0xcf, 0x2a, 0x1f, 0xe8, 0xd0, 0x45, 0x1e, 0x1d, 0x3e, 0x2f, 0x03, 0x6f, 0xb7, 0x0c, 0xbc, 0x9e, 0xc1, 0x8d, 0xdb, 0x52, 0xfa, 0xcb, 0x8a, 0xfe, 0x3f, 0xeb, 0xf8, 0x7a, 0xb5, 0xa1, 0x68, 0xbd, 0xa1, 0xe8, 0x6b, 0x43, 0xd1, 0xcb, 0x96, 0x7a, 0xeb, 0x2d, 0xf5, 0xde, 0xb7, 0xd4, 0xbb, 0x63, 0xfb, 0x41, 0xcb, 0xc1, 0xc6, 0x90, 0x27, 0x4a, 0x6a, 0xcd, 0x13, 0x18, 0xb8, 0x4d, 0x98, 0xbb, 0x5d, 0xb0, 0x09, 0xa2, 0xa6, 0x1d, 0xdd, 0xe5, 0x77, 0x00, 0x00, 0x00, 0xff, 0xff, 0x3c, 0x5d, 0x34, 0xe8, 0x26, 0x02, 0x00, 0x00, } func (this *Params) Equal(that interface{}) bool { if that == nil { return this == nil } that1, ok := that.(*Params) if !ok { that2, ok := that.(Params) if ok { that1 = &that2 } else { return false } } if that1 == nil { return this == nil } else if this == nil { return false } if this.MaxRoutes != that1.MaxRoutes { return false } return true } func (m *Params) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *Params) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *Params) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.MaxRoutes != 0 { i = encodeVarintTypes(dAtA, i, uint64(m.MaxRoutes)) i-- dAtA[i] = 0x8 } return len(dAtA) - i, nil } func (m *Route) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *Route) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *Route) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.Value) > 0 { for iNdEx := len(m.Value) - 1; iNdEx >= 0; iNdEx-- { { size, err := m.Value[iNdEx].MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintTypes(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x22 } } if len(m.Name) > 0 { i -= len(m.Name) copy(dAtA[i:], m.Name) i = encodeVarintTypes(dAtA, i, uint64(len(m.Name))) i-- dAtA[i] = 0x1a } if len(m.Destination) > 0 { i -= len(m.Destination) copy(dAtA[i:], m.Destination) i = encodeVarintTypes(dAtA, i, uint64(len(m.Destination))) i-- dAtA[i] = 0x12 } if len(m.Source) > 0 { i -= len(m.Source) copy(dAtA[i:], m.Source) i = encodeVarintTypes(dAtA, i, uint64(len(m.Source))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *Value) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *Value) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *Value) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.Value) > 0 { for iNdEx := len(m.Value) - 1; iNdEx >= 0; iNdEx-- { { size, err := m.Value[iNdEx].MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintTypes(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa } } return len(dAtA) - i, nil } func encodeVarintTypes(dAtA []byte, offset int, v uint64) int { offset -= sovTypes(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *Params) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.MaxRoutes != 0 { n += 1 + sovTypes(uint64(m.MaxRoutes)) } return n } func (m *Route) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Source) if l > 0 { n += 1 + l + sovTypes(uint64(l)) } l = len(m.Destination) if l > 0 { n += 1 + l + sovTypes(uint64(l)) } l = len(m.Name) if l > 0 { n += 1 + l + sovTypes(uint64(l)) } if len(m.Value) > 0 { for _, e := range m.Value { l = e.Size() n += 1 + l + sovTypes(uint64(l)) } } return n } func (m *Value) Size() (n int) { if m == nil { return 0 } var l int _ = l if len(m.Value) > 0 { for _, e := range m.Value { l = e.Size() n += 1 + l + sovTypes(uint64(l)) } } return n } func sovTypes(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozTypes(x uint64) (n int) { return sovTypes(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *Params) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: Params: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: Params: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field MaxRoutes", wireType) } m.MaxRoutes = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.MaxRoutes |= uint32(b&0x7F) << shift if b < 0x80 { break } } default: iNdEx = preIndex skippy, err := skipTypes(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTypes } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *Route) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: Route: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: Route: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Source", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTypes } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTypes } if postIndex > l { return io.ErrUnexpectedEOF } m.Source = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Destination", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTypes } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTypes } if postIndex > l { return io.ErrUnexpectedEOF } m.Destination = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTypes } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTypes } if postIndex > l { return io.ErrUnexpectedEOF } m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 4: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Value", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthTypes } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthTypes } if postIndex > l { return io.ErrUnexpectedEOF } m.Value = append(m.Value, types.Coin{}) if err := m.Value[len(m.Value)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTypes(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTypes } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *Value) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: Value: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: Value: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Value", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthTypes } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthTypes } if postIndex > l { return io.ErrUnexpectedEOF } m.Value = append(m.Value, types.Coin{}) if err := m.Value[len(m.Value)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTypes(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTypes } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipTypes(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTypes } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTypes } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTypes } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthTypes } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupTypes } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthTypes } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthTypes = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowTypes = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupTypes = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/grid/wasm/interface.go ================================================ package wasm import ( "encoding/json" errorsmod "cosmossdk.io/errors" wasmvmtypes "github.com/CosmWasm/wasmvm/types" pluginstypes "github.com/cybercongress/go-cyber/v7/plugins/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/grid/keeper" ) type Messenger struct { keeper *keeper.Keeper } func NewMessenger( keeper *keeper.Keeper, ) *Messenger { return &Messenger{ keeper: keeper, } } func (m *Messenger) HandleMsg(ctx sdk.Context, contractAddr sdk.AccAddress, contractIBCPortID string, msg pluginstypes.CyberMsg) ([]sdk.Event, [][]byte, error) { switch { case msg.CreateEnergyRoute != nil: if msg.CreateEnergyRoute.Source != contractAddr.String() { return nil, nil, wasmvmtypes.InvalidRequest{Err: "create route wrong source"} } msgServer := keeper.NewMsgServerImpl(*m.keeper) if err := msg.CreateEnergyRoute.ValidateBasic(); err != nil { return nil, nil, errorsmod.Wrap(err, "failed validating msg") } res, err := msgServer.CreateRoute( sdk.WrapSDKContext(ctx), msg.CreateEnergyRoute, ) if err != nil { return nil, nil, errorsmod.Wrap(err, "create energy route msg") } responseBytes, err := json.Marshal(*res) if err != nil { return nil, nil, errorsmod.Wrap(err, "failed to serialize create energy route response") } resp := [][]byte{responseBytes} return nil, resp, nil case msg.EditEnergyRoute != nil: if msg.EditEnergyRoute.Source != contractAddr.String() { return nil, nil, wasmvmtypes.InvalidRequest{Err: "create route wrong source"} } msgServer := keeper.NewMsgServerImpl(*m.keeper) if err := msg.EditEnergyRoute.ValidateBasic(); err != nil { return nil, nil, errorsmod.Wrap(err, "failed validating msg") } res, err := msgServer.EditRoute( sdk.WrapSDKContext(ctx), msg.EditEnergyRoute, ) if err != nil { return nil, nil, errorsmod.Wrap(err, "edit energy route msg") } responseBytes, err := json.Marshal(*res) if err != nil { return nil, nil, errorsmod.Wrap(err, "failed to serialize edit energy route response") } resp := [][]byte{responseBytes} return nil, resp, nil case msg.EditEnergyRouteName != nil: if msg.EditEnergyRouteName.Source != contractAddr.String() { return nil, nil, wasmvmtypes.InvalidRequest{Err: "edit energy route wrong source"} } msgServer := keeper.NewMsgServerImpl(*m.keeper) if err := msg.EditEnergyRouteName.ValidateBasic(); err != nil { return nil, nil, errorsmod.Wrap(err, "failed validating msg") } res, err := msgServer.EditRouteName( sdk.WrapSDKContext(ctx), msg.EditEnergyRouteName, ) if err != nil { return nil, nil, errorsmod.Wrap(err, "edit energy route name msg") } responseBytes, err := json.Marshal(*res) if err != nil { return nil, nil, errorsmod.Wrap(err, "failed to serialize edit energy route name response") } resp := [][]byte{responseBytes} return nil, resp, nil case msg.DeleteEnergyRoute != nil: if msg.DeleteEnergyRoute.Source != contractAddr.String() { return nil, nil, wasmvmtypes.InvalidRequest{Err: "delete route wrong source"} } msgServer := keeper.NewMsgServerImpl(*m.keeper) if err := msg.DeleteEnergyRoute.ValidateBasic(); err != nil { return nil, nil, errorsmod.Wrap(err, "failed validating msg") } res, err := msgServer.DeleteRoute( sdk.WrapSDKContext(ctx), msg.DeleteEnergyRoute, ) if err != nil { return nil, nil, errorsmod.Wrap(err, "delete energy route name msg") } responseBytes, err := json.Marshal(*res) if err != nil { return nil, nil, errorsmod.Wrap(err, "failed to serialize delete energy route name response") } resp := [][]byte{responseBytes} return nil, resp, nil default: return nil, nil, pluginstypes.ErrHandleMsg } } type Querier struct { *keeper.Keeper } func NewWasmQuerier(keeper *keeper.Keeper) *Querier { return &Querier{keeper} } func (querier *Querier) HandleQuery(ctx sdk.Context, query pluginstypes.CyberQuery) ([]byte, error) { switch { case query.SourceRoutes != nil: res, err := querier.Keeper.SourceRoutes(ctx, query.SourceRoutes) if err != nil { return nil, errorsmod.Wrap(err, "failed to get source routes") } responseBytes, err := json.Marshal(res) if err != nil { return nil, errorsmod.Wrap(err, "failed to serialize source routes response") } return responseBytes, nil case query.SourceRoutedEnergy != nil: res, err := querier.Keeper.SourceRoutedEnergy(ctx, query.SourceRoutedEnergy) if err != nil { return nil, errorsmod.Wrap(err, "failed to get source routed energy") } responseBytes, err := json.Marshal(res) if err != nil { return nil, errorsmod.Wrap(err, "failed to serialize source routed energy response") } return responseBytes, nil case query.DestinationRoutedEnergy != nil: res, err := querier.Keeper.DestinationRoutedEnergy(ctx, query.DestinationRoutedEnergy) if err != nil { return nil, errorsmod.Wrap(err, "failed to get destination routed energy") } responseBytes, err := json.Marshal(res) if err != nil { return nil, errorsmod.Wrap(err, "failed to serialize destination routed energy response") } return responseBytes, nil case query.Route != nil: res, err := querier.Keeper.Route(ctx, query.Route) if err != nil { return nil, errorsmod.Wrap(err, "failed to get route") } responseBytes, err := json.Marshal(res) if err != nil { return nil, errorsmod.Wrap(err, "failed to serialize route response") } return responseBytes, nil default: return nil, pluginstypes.ErrHandleQuery } } ================================================ FILE: x/liquidity/abci.go ================================================ package liquidity import ( "time" "github.com/cosmos/cosmos-sdk/telemetry" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/liquidity/keeper" "github.com/cybercongress/go-cyber/v7/x/liquidity/types" ) // In the Begin blocker of the liquidity module, // Reinitialize batch messages that were not executed in the previous batch and delete batch messages that were executed or ready to delete. func BeginBlocker(ctx sdk.Context, k keeper.Keeper) { defer telemetry.ModuleMeasureSince(types.ModuleName, time.Now(), telemetry.MetricKeyBeginBlocker) k.DeleteAndInitPoolBatches(ctx) } // In case of deposit, withdraw, and swap msgs, unlike other normal tx msgs, // collect them in the liquidity pool batch and perform an execution once at the endblock to calculate and use the universal price. func EndBlocker(ctx sdk.Context, k keeper.Keeper) { defer telemetry.ModuleMeasureSince(types.ModuleName, time.Now(), telemetry.MetricKeyEndBlocker) k.ExecutePoolBatches(ctx) } ================================================ FILE: x/liquidity/client/cli/flags.go ================================================ package cli // DONTCOVER import ( flag "github.com/spf13/pflag" ) const ( FlagPoolCoinDenom = "pool-coin-denom" FlagReserveAcc = "reserve-acc" ) func flagSetPool() *flag.FlagSet { fs := flag.NewFlagSet("", flag.ContinueOnError) fs.String(FlagPoolCoinDenom, "", "The denomination of the pool coin") fs.String(FlagReserveAcc, "", "The Bech32 address of the reserve account") return fs } ================================================ FILE: x/liquidity/client/cli/query.go ================================================ package cli // DONTCOVER // client is excluded from test coverage in the poc phase milestone 1 and will be included in milestone 2 with completeness import ( "context" "fmt" "strconv" "strings" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/version" "github.com/spf13/cobra" "github.com/cybercongress/go-cyber/v7/x/liquidity/types" ) // GetQueryCmd returns the cli query commands for this module func GetQueryCmd() *cobra.Command { liquidityQueryCmd := &cobra.Command{ Use: types.ModuleName, Short: "Querying commands for the liquidity module", DisableFlagParsing: true, SuggestionsMinimumDistance: 2, RunE: client.ValidateCmd, } liquidityQueryCmd.AddCommand( GetCmdQueryParams(), GetCmdQueryLiquidityPool(), GetCmdQueryLiquidityPools(), GetCmdQueryLiquidityPoolBatch(), GetCmdQueryPoolBatchDepositMsgs(), GetCmdQueryPoolBatchDepositMsg(), GetCmdQueryPoolBatchWithdrawMsgs(), GetCmdQueryPoolBatchWithdrawMsg(), GetCmdQueryPoolBatchSwapMsgs(), GetCmdQueryPoolBatchSwapMsg(), ) return liquidityQueryCmd } // GetCmdQueryParams implements the params query command. func GetCmdQueryParams() *cobra.Command { cmd := &cobra.Command{ Use: "params", Args: cobra.NoArgs, Short: "Query the values set as liquidity parameters", Long: strings.TrimSpace( fmt.Sprintf(`Query values set as liquidity parameters. Example: $ %s query %s params `, version.AppName, types.ModuleName, ), ), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientTxContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) res, err := queryClient.Params( context.Background(), &types.QueryParamsRequest{}, ) if err != nil { return err } return clientCtx.PrintProto(&res.Params) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } func GetCmdQueryLiquidityPool() *cobra.Command { cmd := &cobra.Command{ Use: "pool [pool-id]", Short: "Query details of a liquidity pool", Long: strings.TrimSpace( fmt.Sprintf(`Query details of a liquidity pool Example: $ %[1]s query %[2]s pool 1 Example (with pool coin denom): $ %[1]s query %[2]s pool --pool-coin-denom=[denom] Example (with reserve acc): $ %[1]s query %[2]s pool --reserve-acc=[address] `, version.AppName, types.ModuleName, ), ), RunE: func(cmd *cobra.Command, args []string) error { var res *types.QueryLiquidityPoolResponse clientCtx, err := client.GetClientTxContext(cmd) if err != nil { return err } foundArg := false queryClient := types.NewQueryClient(clientCtx) poolCoinDenom, _ := cmd.Flags().GetString(FlagPoolCoinDenom) if poolCoinDenom != "" { foundArg = true res, err = queryClient.LiquidityPoolByPoolCoinDenom( context.Background(), &types.QueryLiquidityPoolByPoolCoinDenomRequest{PoolCoinDenom: poolCoinDenom}, ) if err != nil { return err } } reserveAcc, _ := cmd.Flags().GetString(FlagReserveAcc) if !foundArg && reserveAcc != "" { foundArg = true res, err = queryClient.LiquidityPoolByReserveAcc( context.Background(), &types.QueryLiquidityPoolByReserveAccRequest{ReserveAcc: reserveAcc}, ) if err != nil { return err } } if !foundArg && len(args) > 0 { poolID, err := strconv.ParseUint(args[0], 10, 64) if err != nil { return fmt.Errorf("pool-id %s not a valid uint, input a valid unsigned 32-bit integer for pool-id", args[0]) } if poolID != 0 { foundArg = true res, err = queryClient.LiquidityPool( context.Background(), &types.QueryLiquidityPoolRequest{PoolId: poolID}, ) if err != nil { return err } } } if !foundArg { return fmt.Errorf("provide the pool-id argument or --%s or --%s flag", FlagPoolCoinDenom, FlagReserveAcc) } return clientCtx.PrintProto(res) }, } cmd.Flags().AddFlagSet(flagSetPool()) flags.AddQueryFlagsToCmd(cmd) return cmd } func GetCmdQueryLiquidityPools() *cobra.Command { cmd := &cobra.Command{ Use: "pools", Args: cobra.NoArgs, Short: "Query for all liquidity pools", Long: strings.TrimSpace( fmt.Sprintf(`Query details about all liquidity pools on a network. Example: $ %s query %s pools `, version.AppName, types.ModuleName, ), ), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientTxContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) pageReq, err := client.ReadPageRequest(cmd.Flags()) if err != nil { return err } res, err := queryClient.LiquidityPools( context.Background(), &types.QueryLiquidityPoolsRequest{Pagination: pageReq}, ) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } func GetCmdQueryLiquidityPoolBatch() *cobra.Command { cmd := &cobra.Command{ Use: "batch [pool-id]", Args: cobra.ExactArgs(1), Short: "Query details of a liquidity pool batch", Long: strings.TrimSpace( fmt.Sprintf(`Query details of a liquidity pool batch Example: $ %s query %s batch 1 `, version.AppName, types.ModuleName, ), ), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientTxContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) poolID, err := strconv.ParseUint(args[0], 10, 64) if err != nil { return fmt.Errorf("pool-id %s not a valid uint32, input a valid unsigned 32-bit integer pool-id", args[0]) } res, err := queryClient.LiquidityPoolBatch( context.Background(), &types.QueryLiquidityPoolBatchRequest{PoolId: poolID}, ) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } func GetCmdQueryPoolBatchDepositMsgs() *cobra.Command { cmd := &cobra.Command{ Use: "deposits [pool-id]", Args: cobra.ExactArgs(1), Short: "Query all deposit messages of the liquidity pool batch", Long: strings.TrimSpace( fmt.Sprintf(`Query all deposit messages of the liquidity pool batch on the specified pool If batch messages are normally processed from the endblock, the resulting state is applied and the messages are removed in the beginning of next block. To query for past blocks, query the block height using the REST/gRPC API of a node that is not pruned. Example: $ %s query %s deposits 1 `, version.AppName, types.ModuleName, ), ), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientTxContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) pageReq, err := client.ReadPageRequest(cmd.Flags()) if err != nil { return err } poolID, err := strconv.ParseUint(args[0], 10, 64) if err != nil { return fmt.Errorf("pool-id %s not a valid uint, input a valid unsigned 32-bit integer pool-id", args[0]) } res, err := queryClient.PoolBatchDepositMsgs( context.Background(), &types.QueryPoolBatchDepositMsgsRequest{ PoolId: poolID, Pagination: pageReq, }, ) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } func GetCmdQueryPoolBatchDepositMsg() *cobra.Command { cmd := &cobra.Command{ Use: "deposit [pool-id] [msg-index]", Args: cobra.ExactArgs(2), Short: "Query the deposit messages on the liquidity pool batch", Long: strings.TrimSpace( fmt.Sprintf(`Query the deposit messages on the liquidity pool batch for the specified pool-id and msg-index If batch messages are normally processed from the endblock, the resulting state is applied and the messages are removed from the beginning of the next block. To query for past blocks, query the block height using the REST/gRPC API of a node that is not pruned. Example: $ %s query %s deposit 1 20 `, version.AppName, types.ModuleName, ), ), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientTxContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) poolID, err := strconv.ParseUint(args[0], 10, 64) if err != nil { return fmt.Errorf("pool-id %s not a valid uint, input a valid unsigned 32-bit integer for pool-id", args[0]) } msgIndex, err := strconv.ParseUint(args[1], 10, 64) if err != nil { return fmt.Errorf("msg-index %s not a valid uint, input a valid unsigned 32-bit integer for msg-index", args[1]) } res, err := queryClient.PoolBatchDepositMsg( context.Background(), &types.QueryPoolBatchDepositMsgRequest{ PoolId: poolID, MsgIndex: msgIndex, }, ) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } func GetCmdQueryPoolBatchWithdrawMsgs() *cobra.Command { cmd := &cobra.Command{ Use: "withdraws [pool-id]", Args: cobra.ExactArgs(1), Short: "Query for all withdraw messages on the liquidity pool batch", Long: strings.TrimSpace( fmt.Sprintf(`Query all withdraw messages on the liquidity pool batch for the specified pool-id If batch messages are normally processed from the endblock, the resulting state is applied and the messages are removed in the beginning of next block. To query for past blocks, query the block height using the REST/gRPC API of a node that is not pruned. Example: $ %s query %s withdraws 1 `, version.AppName, types.ModuleName, ), ), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientTxContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) pageReq, err := client.ReadPageRequest(cmd.Flags()) if err != nil { return err } poolID, err := strconv.ParseUint(args[0], 10, 64) if err != nil { return fmt.Errorf("pool-id %s not a valid uint, input a valid unsigned 32-bit integer pool-id", args[0]) } result, err := queryClient.PoolBatchWithdrawMsgs(context.Background(), &types.QueryPoolBatchWithdrawMsgsRequest{ PoolId: poolID, Pagination: pageReq, }) if err != nil { return err } return clientCtx.PrintProto(result) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } func GetCmdQueryPoolBatchWithdrawMsg() *cobra.Command { cmd := &cobra.Command{ Use: "withdraw [pool-id] [msg-index]", Args: cobra.ExactArgs(2), Short: "Query the withdraw messages in the liquidity pool batch", Long: strings.TrimSpace( fmt.Sprintf(`Query the withdraw messages in the liquidity pool batch for the specified pool-id and msg-index if the batch message are normally processed from the endblock, the resulting state is applied and the messages are removed in the beginning of next block. To query for past blocks, query the block height using the REST/gRPC API of a node that is not pruned. Example: $ %s query %s withdraw 1 20 `, version.AppName, types.ModuleName, ), ), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientTxContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) poolID, err := strconv.ParseUint(args[0], 10, 64) if err != nil { return fmt.Errorf("pool-id %s not a valid uint, input a valid unsigned 32-bit integer pool-id", args[0]) } msgIndex, err := strconv.ParseUint(args[1], 10, 64) if err != nil { return fmt.Errorf("msg-index %s not a valid uint, input a valid unsigned 32-bit integer msg-index", args[1]) } res, err := queryClient.PoolBatchWithdrawMsg( context.Background(), &types.QueryPoolBatchWithdrawMsgRequest{ PoolId: poolID, MsgIndex: msgIndex, }, ) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } func GetCmdQueryPoolBatchSwapMsgs() *cobra.Command { cmd := &cobra.Command{ Use: "swaps [pool-id]", Args: cobra.ExactArgs(1), Short: "Query all swap messages in the liquidity pool batch", Long: strings.TrimSpace( fmt.Sprintf(`Query all swap messages in the liquidity pool batch for the specified pool-id If batch messages are normally processed from the endblock, the resulting state is applied and the messages are removed in the beginning of next block. To query for past blocks, query the block height using the REST/gRPC API of a node that is not pruned. Example: $ %s query %s swaps 1 `, version.AppName, types.ModuleName, ), ), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientTxContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) pageReq, err := client.ReadPageRequest(cmd.Flags()) if err != nil { return err } poolID, err := strconv.ParseUint(args[0], 10, 64) if err != nil { return fmt.Errorf("pool-id %s not a valid uint, input a valid unsigned 32-bit integer pool-id", args[0]) } res, err := queryClient.PoolBatchSwapMsgs( context.Background(), &types.QueryPoolBatchSwapMsgsRequest{ PoolId: poolID, Pagination: pageReq, }, ) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } func GetCmdQueryPoolBatchSwapMsg() *cobra.Command { cmd := &cobra.Command{ Use: "swap [pool-id] [msg-index]", Args: cobra.ExactArgs(2), Short: "Query for the swap message on the batch of the liquidity pool specified pool-id and msg-index", Long: strings.TrimSpace( fmt.Sprintf(`Query for the swap message on the batch of the liquidity pool specified pool-id and msg-index If the batch message are normally processed and from the endblock, the resulting state is applied and the messages are removed in the beginning of next block. To query for past blocks, query the block height using the REST/gRPC API of a node that is not pruned. Example: $ %s query %s swap 1 20 `, version.AppName, types.ModuleName, ), ), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientTxContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) poolID, err := strconv.ParseUint(args[0], 10, 64) if err != nil { return fmt.Errorf("pool-id %s not a valid uint, input a valid unsigned 32-bit integer for pool-id", args[0]) } msgIndex, err := strconv.ParseUint(args[1], 10, 64) if err != nil { return fmt.Errorf("msg-index %s not a valid uint, input a valid unsigned 32-bit integer for msg-index", args[1]) } res, err := queryClient.PoolBatchSwapMsg( context.Background(), &types.QueryPoolBatchSwapMsgRequest{ PoolId: poolID, MsgIndex: msgIndex, }, ) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } ================================================ FILE: x/liquidity/client/cli/tx.go ================================================ package cli // DONTCOVER // client is excluded from test coverage in the poc phase milestone 1 and will be included in milestone 2 with completeness import ( "fmt" "strconv" "strings" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/client/tx" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/version" "github.com/spf13/cobra" "github.com/cybercongress/go-cyber/v7/x/liquidity/types" ) // GetTxCmd returns a root CLI command handler for all x/liquidity transaction commands. func GetTxCmd() *cobra.Command { liquidityTxCmd := &cobra.Command{ Use: types.ModuleName, Short: "Liquidity transaction subcommands", DisableFlagParsing: true, SuggestionsMinimumDistance: 2, RunE: client.ValidateCmd, } liquidityTxCmd.AddCommand( NewCreatePoolCmd(), NewDepositWithinBatchCmd(), NewWithdrawWithinBatchCmd(), NewSwapWithinBatchCmd(), ) return liquidityTxCmd } // Create new liquidity pool with the specified pool type and deposit coins. func NewCreatePoolCmd() *cobra.Command { cmd := &cobra.Command{ Use: "create-pool [pool-type] [deposit-coins]", Args: cobra.ExactArgs(2), Short: "Create liquidity pool and deposit coins", Long: strings.TrimSpace( fmt.Sprintf(`Create liquidity pool and deposit coins. Example: $ %s tx %s create-pool 1 1000000000uatom,50000000000uusd --from mykey This example creates a liquidity pool of pool-type 1 (two coins) and deposits 1000000000uatom and 50000000000uusd. New liquidity pools can be created only for coin combinations that do not already exist in the network. [pool-type]: The id of the liquidity pool-type. The only supported pool type is 1 [deposit-coins]: The amount of coins to deposit to the liquidity pool. The number of deposit coins must be 2 in pool type 1. `, version.AppName, types.ModuleName, ), ), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientTxContext(cmd) if err != nil { return err } poolCreator := clientCtx.GetFromAddress() // Get pool type index poolTypeID, err := strconv.ParseUint(args[0], 10, 32) if err != nil { return fmt.Errorf("pool-type %s not a valid uint, input a valid unsigned 32-bit integer for pool-type", args[0]) } // Get deposit coins depositCoins, err := sdk.ParseCoinsNormalized(args[1]) if err != nil { return err } err = depositCoins.Validate() if err != nil { return err } if poolTypeID != 1 { return types.ErrPoolTypeNotExists } if depositCoins.Len() != 2 { return fmt.Errorf("the number of deposit coins must be two in pool-type 1") } msg := types.NewMsgCreatePool(poolCreator, uint32(poolTypeID), depositCoins) if err := msg.ValidateBasic(); err != nil { return err } return tx.GenerateOrBroadcastTxCLI(clientCtx, cmd.Flags(), msg) }, } flags.AddTxFlagsToCmd(cmd) return cmd } // Deposit coins to the specified liquidity pool. func NewDepositWithinBatchCmd() *cobra.Command { cmd := &cobra.Command{ Use: "deposit [pool-id] [deposit-coins]", Args: cobra.ExactArgs(2), Short: "Deposit coins to a liquidity pool", Long: strings.TrimSpace( fmt.Sprintf(`Deposit coins a liquidity pool. This deposit request is not processed immediately since it is accumulated in the liquidity pool batch. All requests in a batch are treated equally and executed at the same swap price. Example: $ %s tx %s deposit 1 100000000uatom,5000000000uusd --from mykey This example request deposits 100000000uatom and 5000000000uusd to pool-id 1. Deposits must be the same coin denoms as the reserve coins. [pool-id]: The pool id of the liquidity pool [deposit-coins]: The amount of coins to deposit to the liquidity pool `, version.AppName, types.ModuleName, ), ), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientTxContext(cmd) if err != nil { return err } depositor := clientCtx.GetFromAddress() // Get pool type index poolID, err := strconv.ParseUint(args[0], 10, 64) if err != nil { return fmt.Errorf("pool-id %s not a valid uint, input a valid unsigned 32-bit integer for pool-id", args[0]) } // Get deposit coins depositCoins, err := sdk.ParseCoinsNormalized(args[1]) if err != nil { return err } err = depositCoins.Validate() if err != nil { return err } if depositCoins.Len() != 2 { return fmt.Errorf("the number of deposit coins must be two in the pool-type 1") } msg := types.NewMsgDepositWithinBatch(depositor, poolID, depositCoins) if err := msg.ValidateBasic(); err != nil { return err } return tx.GenerateOrBroadcastTxCLI(clientCtx, cmd.Flags(), msg) }, } flags.AddTxFlagsToCmd(cmd) return cmd } // Withdraw pool coin from the specified liquidity pool. func NewWithdrawWithinBatchCmd() *cobra.Command { cmd := &cobra.Command{ Use: "withdraw [pool-id] [pool-coin]", Args: cobra.ExactArgs(2), Short: "Withdraw pool coin from the specified liquidity pool", Long: strings.TrimSpace( fmt.Sprintf(`Withdraw pool coin from the specified liquidity pool. This swap request is not processed immediately since it is accumulated in the liquidity pool batch. All requests in a batch are treated equally and executed at the same swap price. Example: $ %s tx %s withdraw 1 10000pool96EF6EA6E5AC828ED87E8D07E7AE2A8180570ADD212117B2DA6F0B75D17A6295 --from mykey This example request withdraws 10000 pool coin from the specified liquidity pool. The appropriate pool coin must be requested from the specified pool. [pool-id]: The pool id of the liquidity pool [pool-coin]: The amount of pool coin to withdraw from the liquidity pool `, version.AppName, types.ModuleName, ), ), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientTxContext(cmd) if err != nil { return err } withdrawer := clientCtx.GetFromAddress() // Get pool type index poolID, err := strconv.ParseUint(args[0], 10, 64) if err != nil { return fmt.Errorf("pool-id %s not a valid uint, input a valid unsigned 32-bit integer for pool-id", args[0]) } // Get pool coin of the target pool poolCoin, err := sdk.ParseCoinNormalized(args[1]) if err != nil { return err } err = poolCoin.Validate() if err != nil { return err } msg := types.NewMsgWithdrawWithinBatch(withdrawer, poolID, poolCoin) if err := msg.ValidateBasic(); err != nil { return err } return tx.GenerateOrBroadcastTxCLI(clientCtx, cmd.Flags(), msg) }, } flags.AddTxFlagsToCmd(cmd) return cmd } // Swap offer coin with demand coin from the specified liquidity pool with the given order price. func NewSwapWithinBatchCmd() *cobra.Command { cmd := &cobra.Command{ Use: "swap [pool-id] [swap-type] [offer-coin] [demand-coin-denom] [order-price] [swap-fee-rate]", Args: cobra.ExactArgs(6), Short: "Swap offer coin with demand coin from the liquidity pool with the given order price", Long: strings.TrimSpace( fmt.Sprintf(`Swap offer coin with demand coin from the liquidity pool with the given order price. This swap request is not processed immediately since it is accumulated in the liquidity pool batch. All requests in a batch are treated equally and executed at the same swap price. The order of swap requests is ignored since the universal swap price is calculated in every batch to prevent front running. The requested swap is executed with a swap price that is calculated from the given swap price function of the pool, the other swap requests, and the liquidity pool coin reserve status. Swap orders are executed only when the execution swap price is equal to or greater than the submitted order price of the swap order. Example: $ %s tx %s swap 1 1 50000000uusd uatom 0.019 0.003 --from mykey For this example, imagine that an existing liquidity pool has with 1000000000uatom and 50000000000uusd. This example request swaps 50000000uusd for at least 950000uatom with the order price of 0.019 and swap fee rate of 0.003. A sufficient balance of half of the swap-fee-rate of the offer coin is required to reserve the offer coin fee. The order price is the exchange ratio of X/Y, where X is the amount of the first coin and Y is the amount of the second coin when their denoms are sorted alphabetically. Increasing order price reduces the possibility for your request to be processed and results in buying uatom at a lower price than the pool price. For explicit calculations, The swap fee rate must be the value that set as liquidity parameter in the current network. The only supported swap-type is 1. For the detailed swap algorithm, see https://github.com/gravity-devs/liquidity/v3 [pool-id]: The pool id of the liquidity pool [swap-type]: The swap type of the swap message. The only supported swap type is 1 (instant swap). [offer-coin]: The amount of offer coin to swap [demand-coin-denom]: The denomination of the coin to exchange with offer coin [order-price]: The limit order price for the swap order. The price is the exchange ratio of X/Y where X is the amount of the first coin and Y is the amount of the second coin when their denoms are sorted alphabetically [swap-fee-rate]: The swap fee rate to pay for swap that is proportional to swap amount. The swap fee rate must be the value that set as liquidity parameter in the current network. `, version.AppName, types.ModuleName, ), ), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientTxContext(cmd) if err != nil { return err } swapRequester := clientCtx.GetFromAddress() // Get pool id poolID, err := strconv.ParseUint(args[0], 10, 64) if err != nil { return fmt.Errorf("pool-id %s not a valid uint, input a valid unsigned 32-bit integer for pool-id", args[0]) } // Get swap type swapTypeID, err := strconv.ParseUint(args[1], 10, 32) if err != nil { return fmt.Errorf("swap-type %s not a valid uint, input a valid unsigned 32-bit integer for swap-type", args[2]) } if swapTypeID != 1 { return types.ErrSwapTypeNotExists } // Get offer coin offerCoin, err := sdk.ParseCoinNormalized(args[2]) if err != nil { return err } err = offerCoin.Validate() if err != nil { return err } err = sdk.ValidateDenom(args[3]) if err != nil { return err } orderPrice, err := sdk.NewDecFromStr(args[4]) if err != nil { return err } swapFeeRate, err := sdk.NewDecFromStr(args[5]) if err != nil { return err } msg := types.NewMsgSwapWithinBatch(swapRequester, poolID, uint32(swapTypeID), offerCoin, args[3], orderPrice, swapFeeRate) if err := msg.ValidateBasic(); err != nil { return err } return tx.GenerateOrBroadcastTxCLI(clientCtx, cmd.Flags(), msg) }, } flags.AddTxFlagsToCmd(cmd) return cmd } ================================================ FILE: x/liquidity/exported/exported.go ================================================ package exported import ( sdk "github.com/cosmos/cosmos-sdk/types" paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" ) type EnergyKeeper interface { GetRoutedToEnergy(ctx sdk.Context, delegate sdk.AccAddress) sdk.Coins } type ( ParamSet = paramtypes.ParamSet // Subspace defines an interface that implements the legacy x/params Subspace // type. // // NOTE: This is used solely for migration of x/params managed parameters. Subspace interface { GetParamSet(ctx sdk.Context, ps ParamSet) } ) ================================================ FILE: x/liquidity/genesis.go ================================================ package liquidity import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/liquidity/keeper" "github.com/cybercongress/go-cyber/v7/x/liquidity/types" ) // InitGenesis new liquidity genesis func InitGenesis(ctx sdk.Context, keeper keeper.Keeper, data types.GenesisState) { keeper.InitGenesis(ctx, data) } // ExportGenesis returns a GenesisState for a given context and keeper. func ExportGenesis(ctx sdk.Context, keeper keeper.Keeper) *types.GenesisState { return keeper.ExportGenesis(ctx) } ================================================ FILE: x/liquidity/handler.go ================================================ package liquidity import ( errorsmod "cosmossdk.io/errors" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" "github.com/cybercongress/go-cyber/v7/x/liquidity/keeper" "github.com/cybercongress/go-cyber/v7/x/liquidity/types" ) // NewHandler returns a handler for all "liquidity" type messages. func NewHandler(k keeper.Keeper) sdk.Handler { msgServer := keeper.NewMsgServerImpl(k) return func(ctx sdk.Context, msg sdk.Msg) (*sdk.Result, error) { ctx = ctx.WithEventManager(sdk.NewEventManager()) switch msg := msg.(type) { case *types.MsgCreatePool: res, err := msgServer.CreatePool(sdk.WrapSDKContext(ctx), msg) return sdk.WrapServiceResult(ctx, res, err) case *types.MsgDepositWithinBatch: res, err := msgServer.DepositWithinBatch(sdk.WrapSDKContext(ctx), msg) return sdk.WrapServiceResult(ctx, res, err) case *types.MsgWithdrawWithinBatch: res, err := msgServer.WithdrawWithinBatch(sdk.WrapSDKContext(ctx), msg) return sdk.WrapServiceResult(ctx, res, err) case *types.MsgSwapWithinBatch: res, err := msgServer.Swap(sdk.WrapSDKContext(ctx), msg) return sdk.WrapServiceResult(ctx, res, err) default: return nil, errorsmod.Wrapf(sdkerrors.ErrUnknownRequest, "unrecognized %s message type: %T", types.ModuleName, msg) } } } ================================================ FILE: x/liquidity/keeper/batch.go ================================================ package keeper import ( sdk "github.com/cosmos/cosmos-sdk/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" "github.com/cybercongress/go-cyber/v7/x/liquidity/types" ) // DeleteAndInitPoolBatches resets batch msg states that were previously executed // and deletes msg states that were marked to be deleted. func (k Keeper) DeleteAndInitPoolBatches(ctx sdk.Context) { k.IterateAllPoolBatches(ctx, func(poolBatch types.PoolBatch) bool { // Re-initialize the executed batch. if poolBatch.Executed { // On the other hand, BatchDeposit, BatchWithdraw, is all handled by the endblock if there is no error. // If there are BatchMsgs left, reset the Executed, Succeeded flag so that it can be executed in the next batch. depositMsgs := k.GetAllRemainingPoolBatchDepositMsgStates(ctx, poolBatch) if len(depositMsgs) > 0 { for _, msg := range depositMsgs { msg.Executed = false msg.Succeeded = false } k.SetPoolBatchDepositMsgStatesByPointer(ctx, poolBatch.PoolId, depositMsgs) } withdrawMsgs := k.GetAllRemainingPoolBatchWithdrawMsgStates(ctx, poolBatch) if len(withdrawMsgs) > 0 { for _, msg := range withdrawMsgs { msg.Executed = false msg.Succeeded = false } k.SetPoolBatchWithdrawMsgStatesByPointer(ctx, poolBatch.PoolId, withdrawMsgs) } height := ctx.BlockHeight() // In the case of remaining swap msg states, those are either fractionally matched // or has not yet been expired. swapMsgs := k.GetAllRemainingPoolBatchSwapMsgStates(ctx, poolBatch) if len(swapMsgs) > 0 { for _, msg := range swapMsgs { if height > msg.OrderExpiryHeight { msg.ToBeDeleted = true } else { msg.Executed = false msg.Succeeded = false } } k.SetPoolBatchSwapMsgStatesByPointer(ctx, poolBatch.PoolId, swapMsgs) } // Delete all batch msg states that are ready to be deleted. k.DeleteAllReadyPoolBatchDepositMsgStates(ctx, poolBatch) k.DeleteAllReadyPoolBatchWithdrawMsgStates(ctx, poolBatch) k.DeleteAllReadyPoolBatchSwapMsgStates(ctx, poolBatch) if err := k.InitNextPoolBatch(ctx, poolBatch); err != nil { panic(err) } } return false }) } // InitNextPoolBatch re-initializes the batch and increases the batch index. func (k Keeper) InitNextPoolBatch(ctx sdk.Context, poolBatch types.PoolBatch) error { if !poolBatch.Executed { return types.ErrBatchNotExecuted } poolBatch.Index++ poolBatch.BeginHeight = ctx.BlockHeight() poolBatch.Executed = false k.SetPoolBatch(ctx, poolBatch) return nil } // ExecutePoolBatches executes the accumulated msgs in the batch. // The order is (1)swap, (2)deposit, (3)withdraw. func (k Keeper) ExecutePoolBatches(ctx sdk.Context) { params := k.GetParams(ctx) logger := k.Logger(ctx) k.IterateAllPoolBatches(ctx, func(poolBatch types.PoolBatch) bool { if !poolBatch.Executed && ctx.BlockHeight()%int64(params.UnitBatchHeight) == 0 { executedMsgCount, err := k.SwapExecution(ctx, poolBatch) if err != nil { panic(err) } k.IterateAllPoolBatchDepositMsgStates(ctx, poolBatch, func(batchMsg types.DepositMsgState) bool { if batchMsg.Executed || batchMsg.ToBeDeleted || batchMsg.Succeeded { return false } executedMsgCount++ if err := k.ExecuteDeposit(ctx, batchMsg, poolBatch); err != nil { logger.Error("deposit failed", "poolID", poolBatch.PoolId, "batchIndex", poolBatch.Index, "msgIndex", batchMsg.MsgIndex, "depositor", batchMsg.Msg.GetDepositor(), "error", err) if err := k.RefundDeposit(ctx, batchMsg, poolBatch); err != nil { panic(err) } } return false }) k.IterateAllPoolBatchWithdrawMsgStates(ctx, poolBatch, func(batchMsg types.WithdrawMsgState) bool { if batchMsg.Executed || batchMsg.ToBeDeleted || batchMsg.Succeeded { return false } executedMsgCount++ if err := k.ExecuteWithdrawal(ctx, batchMsg, poolBatch); err != nil { logger.Error("withdraw failed", "poolID", poolBatch.PoolId, "batchIndex", poolBatch.Index, "msgIndex", batchMsg.MsgIndex, "withdrawer", batchMsg.Msg.GetWithdrawer(), "error", err) if err := k.RefundWithdrawal(ctx, batchMsg, poolBatch); err != nil { panic(err) } } return false }) // Mark the batch as executed when any msgs were executed. if executedMsgCount > 0 { poolBatch.Executed = true k.SetPoolBatch(ctx, poolBatch) } } return false }) } // HoldEscrow sends coins to the module account for an escrow. func (k Keeper) HoldEscrow(ctx sdk.Context, depositor sdk.AccAddress, depositCoins sdk.Coins) error { err := k.bankKeeper.SendCoinsFromAccountToModule(ctx, depositor, types.ModuleName, depositCoins) return err } // If batch messages have expired or have not been processed, coins that were deposited with this function are refunded to the escrow. func (k Keeper) ReleaseEscrow(ctx sdk.Context, withdrawer sdk.AccAddress, withdrawCoins sdk.Coins) error { err := k.bankKeeper.SendCoinsFromModuleToAccount(ctx, types.ModuleName, withdrawer, withdrawCoins) return err } // Generate inputs and outputs to treat escrow refunds atomically. func (k Keeper) ReleaseEscrowForMultiSend(withdrawer sdk.AccAddress, withdrawCoins sdk.Coins) ( banktypes.Input, banktypes.Output, error, ) { var input banktypes.Input var output banktypes.Output input = banktypes.NewInput(k.accountKeeper.GetModuleAddress(types.ModuleName), withdrawCoins) output = banktypes.NewOutput(withdrawer, withdrawCoins) if err := banktypes.ValidateInputsOutputs([]banktypes.Input{input}, []banktypes.Output{output}); err != nil { return banktypes.Input{}, banktypes.Output{}, err } return input, output, nil } // In order to deal with the batch at the same time, the coins of msgs are deposited in escrow. func (k Keeper) DepositWithinBatch(ctx sdk.Context, msg *types.MsgDepositWithinBatch) (types.DepositMsgState, error) { if err := k.ValidateMsgDepositWithinBatch(ctx, *msg); err != nil { return types.DepositMsgState{}, err } poolBatch, found := k.GetPoolBatch(ctx, msg.PoolId) if !found { return types.DepositMsgState{}, types.ErrPoolBatchNotExists } if poolBatch.BeginHeight == 0 { poolBatch.BeginHeight = ctx.BlockHeight() } msgState := types.DepositMsgState{ MsgHeight: ctx.BlockHeight(), MsgIndex: poolBatch.DepositMsgIndex, Msg: msg, } if err := k.HoldEscrow(ctx, msg.GetDepositor(), msg.DepositCoins); err != nil { return types.DepositMsgState{}, err } poolBatch.DepositMsgIndex++ k.SetPoolBatch(ctx, poolBatch) k.SetPoolBatchDepositMsgState(ctx, poolBatch.PoolId, msgState) return msgState, nil } // In order to deal with the batch at the same time, the coins of msgs are deposited in escrow. func (k Keeper) WithdrawWithinBatch(ctx sdk.Context, msg *types.MsgWithdrawWithinBatch) (types.WithdrawMsgState, error) { if err := k.ValidateMsgWithdrawWithinBatch(ctx, *msg); err != nil { return types.WithdrawMsgState{}, err } poolBatch, found := k.GetPoolBatch(ctx, msg.PoolId) if !found { return types.WithdrawMsgState{}, types.ErrPoolBatchNotExists } if poolBatch.BeginHeight == 0 { poolBatch.BeginHeight = ctx.BlockHeight() } batchPoolMsg := types.WithdrawMsgState{ MsgHeight: ctx.BlockHeight(), MsgIndex: poolBatch.WithdrawMsgIndex, Msg: msg, } if err := k.HoldEscrow(ctx, msg.GetWithdrawer(), sdk.NewCoins(msg.PoolCoin)); err != nil { return types.WithdrawMsgState{}, err } poolBatch.WithdrawMsgIndex++ k.SetPoolBatch(ctx, poolBatch) k.SetPoolBatchWithdrawMsgState(ctx, poolBatch.PoolId, batchPoolMsg) return batchPoolMsg, nil } // In order to deal with the batch at the same time, the coins of msgs are deposited in escrow. func (k Keeper) SwapWithinBatch(ctx sdk.Context, msg *types.MsgSwapWithinBatch, orderExpirySpanHeight int64) (*types.SwapMsgState, error) { pool, found := k.GetPool(ctx, msg.PoolId) if !found { return nil, types.ErrPoolNotExists } if k.IsDepletedPool(ctx, pool) { return nil, types.ErrDepletedPool } if err := k.ValidateMsgSwapWithinBatch(ctx, *msg, pool); err != nil { return nil, err } poolBatch, found := k.GetPoolBatch(ctx, msg.PoolId) if !found { return nil, types.ErrPoolBatchNotExists } if poolBatch.BeginHeight == 0 { poolBatch.BeginHeight = ctx.BlockHeight() } currentHeight := ctx.BlockHeight() if orderExpirySpanHeight == 0 { params := k.GetParams(ctx) u := int64(params.UnitBatchHeight) orderExpirySpanHeight = (u - currentHeight%u) % u } batchPoolMsg := types.SwapMsgState{ MsgHeight: currentHeight, MsgIndex: poolBatch.SwapMsgIndex, Executed: false, Succeeded: false, ToBeDeleted: false, OrderExpiryHeight: currentHeight + orderExpirySpanHeight, ExchangedOfferCoin: sdk.NewCoin(msg.OfferCoin.Denom, sdk.ZeroInt()), RemainingOfferCoin: msg.OfferCoin, ReservedOfferCoinFee: msg.OfferCoinFee, Msg: msg, } if err := k.HoldEscrow(ctx, msg.GetSwapRequester(), sdk.NewCoins(msg.OfferCoin.Add(msg.OfferCoinFee))); err != nil { return nil, err } poolBatch.SwapMsgIndex++ k.SetPoolBatch(ctx, poolBatch) k.SetPoolBatchSwapMsgState(ctx, poolBatch.PoolId, batchPoolMsg) return &batchPoolMsg, nil } ================================================ FILE: x/liquidity/keeper/genesis.go ================================================ package keeper import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/liquidity/types" ) // InitGenesis initializes the liquidity module's state from a given genesis state. func (k Keeper) InitGenesis(ctx sdk.Context, genState types.GenesisState) { if err := k.ValidateGenesis(ctx, genState); err != nil { panic(err) } k.SetParams(ctx, genState.Params) for _, record := range genState.PoolRecords { k.SetPoolRecord(ctx, record) } } // ExportGenesis returns the liquidity module's genesis state. func (k Keeper) ExportGenesis(ctx sdk.Context) *types.GenesisState { params := k.GetParams(ctx) var poolRecords []types.PoolRecord pools := k.GetAllPools(ctx) for _, pool := range pools { record, found := k.GetPoolRecord(ctx, pool) if found { poolRecords = append(poolRecords, record) } } if len(poolRecords) == 0 { poolRecords = []types.PoolRecord{} } return types.NewGenesisState(params, poolRecords) } // ValidateGenesis validates the liquidity module's genesis state. func (k Keeper) ValidateGenesis(ctx sdk.Context, genState types.GenesisState) error { if err := genState.Params.Validate(); err != nil { return err } cc, _ := ctx.CacheContext() k.SetParams(cc, genState.Params) for _, record := range genState.PoolRecords { record = k.SetPoolRecord(cc, record) if err := k.ValidatePoolRecord(cc, record); err != nil { return err } } return nil } ================================================ FILE: x/liquidity/keeper/grpc_query.go ================================================ package keeper // DONTCOVER // client is excluded from test coverage in the poc phase milestone 1 and will be included in milestone 2 with completeness import ( "context" "github.com/cosmos/cosmos-sdk/store/prefix" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/query" "google.golang.org/grpc/codes" "google.golang.org/grpc/status" "github.com/cybercongress/go-cyber/v7/x/liquidity/types" ) // Querier is used as Keeper will have duplicate methods if used directly, and gRPC names take precedence over keeper. type Querier struct { Keeper } var _ types.QueryServer = Querier{} // LiquidityPool queries a liquidity pool with the given pool id. func (k Querier) LiquidityPool(c context.Context, req *types.QueryLiquidityPoolRequest) (*types.QueryLiquidityPoolResponse, error) { empty := &types.QueryLiquidityPoolRequest{} if req == nil || *req == *empty { return nil, status.Errorf(codes.InvalidArgument, "empty request") } ctx := sdk.UnwrapSDKContext(c) pool, found := k.GetPool(ctx, req.PoolId) if !found { return nil, status.Errorf(codes.NotFound, "liquidity pool %d doesn't exist", req.PoolId) } return k.MakeQueryLiquidityPoolResponse(pool) } // LiquidityPool queries a liquidity pool with the given pool coin denom. func (k Querier) LiquidityPoolByPoolCoinDenom(c context.Context, req *types.QueryLiquidityPoolByPoolCoinDenomRequest) (*types.QueryLiquidityPoolResponse, error) { empty := &types.QueryLiquidityPoolByPoolCoinDenomRequest{} if req == nil || *req == *empty { return nil, status.Errorf(codes.InvalidArgument, "empty request") } ctx := sdk.UnwrapSDKContext(c) reserveAcc, err := types.GetReserveAcc(req.PoolCoinDenom, false) if err != nil { return nil, status.Errorf(codes.NotFound, "liquidity pool with pool coin denom %s doesn't exist", req.PoolCoinDenom) } pool, found := k.GetPoolByReserveAccIndex(ctx, reserveAcc) if !found { return nil, status.Errorf(codes.NotFound, "liquidity pool with pool coin denom %s doesn't exist", req.PoolCoinDenom) } return k.MakeQueryLiquidityPoolResponse(pool) } // LiquidityPool queries a liquidity pool with the given reserve account address. func (k Querier) LiquidityPoolByReserveAcc(c context.Context, req *types.QueryLiquidityPoolByReserveAccRequest) (*types.QueryLiquidityPoolResponse, error) { empty := &types.QueryLiquidityPoolByReserveAccRequest{} if req == nil || *req == *empty { return nil, status.Errorf(codes.InvalidArgument, "empty request") } ctx := sdk.UnwrapSDKContext(c) reserveAcc, err := sdk.AccAddressFromBech32(req.ReserveAcc) if err != nil { return nil, status.Errorf(codes.NotFound, "the reserve account address %s is not valid", req.ReserveAcc) } pool, found := k.GetPoolByReserveAccIndex(ctx, reserveAcc) if !found { return nil, status.Errorf(codes.NotFound, "liquidity pool with pool reserve account %s doesn't exist", req.ReserveAcc) } return k.MakeQueryLiquidityPoolResponse(pool) } // LiquidityPoolBatch queries a liquidity pool batch with the given pool id. func (k Querier) LiquidityPoolBatch(c context.Context, req *types.QueryLiquidityPoolBatchRequest) (*types.QueryLiquidityPoolBatchResponse, error) { empty := &types.QueryLiquidityPoolBatchRequest{} if req == nil || *req == *empty { return nil, status.Errorf(codes.InvalidArgument, "empty request") } ctx := sdk.UnwrapSDKContext(c) batch, found := k.GetPoolBatch(ctx, req.PoolId) if !found { return nil, status.Errorf(codes.NotFound, "liquidity pool batch %d doesn't exist", req.PoolId) } return &types.QueryLiquidityPoolBatchResponse{ Batch: batch, }, nil } // Pools queries all liquidity pools currently existed with each liquidity pool with batch and metadata. func (k Querier) LiquidityPools(c context.Context, req *types.QueryLiquidityPoolsRequest) (*types.QueryLiquidityPoolsResponse, error) { ctx := sdk.UnwrapSDKContext(c) store := ctx.KVStore(k.storeKey) poolStore := prefix.NewStore(store, types.PoolKeyPrefix) var pools types.Pools pageRes, err := query.Paginate(poolStore, req.Pagination, func(key []byte, value []byte) error { pool, err := types.UnmarshalPool(k.cdc, value) if err != nil { return err } pools = append(pools, pool) return nil }) if err != nil { return nil, status.Error(codes.Internal, err.Error()) } if len(pools) == 0 { return nil, status.Error(codes.NotFound, "There are no pools present.") } return &types.QueryLiquidityPoolsResponse{ Pools: pools, Pagination: pageRes, }, nil } // PoolBatchSwapMsg queries the pool batch swap message with the message index of the liquidity pool. func (k Querier) PoolBatchSwapMsg(c context.Context, req *types.QueryPoolBatchSwapMsgRequest) (*types.QueryPoolBatchSwapMsgResponse, error) { empty := &types.QueryPoolBatchSwapMsgRequest{} if req == nil || *req == *empty { return nil, status.Errorf(codes.InvalidArgument, "empty request") } ctx := sdk.UnwrapSDKContext(c) msg, found := k.GetPoolBatchSwapMsgState(ctx, req.PoolId, req.MsgIndex) if !found { return nil, status.Errorf(codes.NotFound, "the msg given msg_index %d doesn't exist or deleted", req.MsgIndex) } return &types.QueryPoolBatchSwapMsgResponse{ Swap: msg, }, nil } // PoolBatchSwapMsgs queries all pool batch swap messages of the liquidity pool. func (k Querier) PoolBatchSwapMsgs(c context.Context, req *types.QueryPoolBatchSwapMsgsRequest) (*types.QueryPoolBatchSwapMsgsResponse, error) { empty := &types.QueryPoolBatchSwapMsgsRequest{} if req == nil || *req == *empty { return nil, status.Errorf(codes.InvalidArgument, "empty request") } ctx := sdk.UnwrapSDKContext(c) _, found := k.GetPool(ctx, req.PoolId) if !found { return nil, status.Errorf(codes.NotFound, "liquidity pool %d doesn't exist", req.PoolId) } store := ctx.KVStore(k.storeKey) msgStore := prefix.NewStore(store, types.GetPoolBatchSwapMsgStatesPrefix(req.PoolId)) var msgs []types.SwapMsgState pageRes, err := query.Paginate(msgStore, req.Pagination, func(key []byte, value []byte) error { msg, err := types.UnmarshalSwapMsgState(k.cdc, value) if err != nil { return err } msgs = append(msgs, msg) return nil }) if err != nil { return nil, status.Error(codes.Internal, err.Error()) } return &types.QueryPoolBatchSwapMsgsResponse{ Swaps: msgs, Pagination: pageRes, }, nil } // PoolBatchDepositMsg queries the pool batch deposit message with the msg_index of the liquidity pool. func (k Querier) PoolBatchDepositMsg(c context.Context, req *types.QueryPoolBatchDepositMsgRequest) (*types.QueryPoolBatchDepositMsgResponse, error) { empty := &types.QueryPoolBatchDepositMsgRequest{} if req == nil || *req == *empty { return nil, status.Errorf(codes.InvalidArgument, "empty request") } ctx := sdk.UnwrapSDKContext(c) msg, found := k.GetPoolBatchDepositMsgState(ctx, req.PoolId, req.MsgIndex) if !found { return nil, status.Errorf(codes.NotFound, "the msg given msg_index %d doesn't exist or deleted", req.MsgIndex) } return &types.QueryPoolBatchDepositMsgResponse{ Deposit: msg, }, nil } // PoolBatchDepositMsgs queries all pool batch deposit messages of the liquidity pool. func (k Querier) PoolBatchDepositMsgs(c context.Context, req *types.QueryPoolBatchDepositMsgsRequest) (*types.QueryPoolBatchDepositMsgsResponse, error) { empty := &types.QueryPoolBatchDepositMsgsRequest{} if req == nil || *req == *empty { return nil, status.Errorf(codes.InvalidArgument, "empty request") } ctx := sdk.UnwrapSDKContext(c) _, found := k.GetPool(ctx, req.PoolId) if !found { return nil, status.Errorf(codes.NotFound, "liquidity pool %d doesn't exist", req.PoolId) } store := ctx.KVStore(k.storeKey) msgStore := prefix.NewStore(store, types.GetPoolBatchDepositMsgStatesPrefix(req.PoolId)) var msgs []types.DepositMsgState pageRes, err := query.Paginate(msgStore, req.Pagination, func(key []byte, value []byte) error { msg, err := types.UnmarshalDepositMsgState(k.cdc, value) if err != nil { return err } msgs = append(msgs, msg) return nil }) if err != nil { return nil, status.Error(codes.Internal, err.Error()) } return &types.QueryPoolBatchDepositMsgsResponse{ Deposits: msgs, Pagination: pageRes, }, nil } // PoolBatchWithdrawMsg queries the pool batch withdraw message with the msg_index of the liquidity pool. func (k Querier) PoolBatchWithdrawMsg(c context.Context, req *types.QueryPoolBatchWithdrawMsgRequest) (*types.QueryPoolBatchWithdrawMsgResponse, error) { empty := &types.QueryPoolBatchWithdrawMsgRequest{} if req == nil || *req == *empty { return nil, status.Errorf(codes.InvalidArgument, "empty request") } ctx := sdk.UnwrapSDKContext(c) msg, found := k.GetPoolBatchWithdrawMsgState(ctx, req.PoolId, req.MsgIndex) if !found { return nil, status.Errorf(codes.NotFound, "the msg given msg_index %d doesn't exist or deleted", req.MsgIndex) } return &types.QueryPoolBatchWithdrawMsgResponse{ Withdraw: msg, }, nil } // PoolBatchWithdrawMsgs queries all pool batch withdraw messages of the liquidity pool. func (k Querier) PoolBatchWithdrawMsgs(c context.Context, req *types.QueryPoolBatchWithdrawMsgsRequest) (*types.QueryPoolBatchWithdrawMsgsResponse, error) { empty := &types.QueryPoolBatchWithdrawMsgsRequest{} if req == nil || *req == *empty { return nil, status.Errorf(codes.InvalidArgument, "empty request") } ctx := sdk.UnwrapSDKContext(c) _, found := k.GetPool(ctx, req.PoolId) if !found { return nil, status.Errorf(codes.NotFound, "liquidity pool %d doesn't exist", req.PoolId) } store := ctx.KVStore(k.storeKey) msgStore := prefix.NewStore(store, types.GetPoolBatchWithdrawMsgsPrefix(req.PoolId)) var msgs []types.WithdrawMsgState pageRes, err := query.Paginate(msgStore, req.Pagination, func(key []byte, value []byte) error { msg, err := types.UnmarshalWithdrawMsgState(k.cdc, value) if err != nil { return err } msgs = append(msgs, msg) return nil }) if err != nil { return nil, status.Error(codes.Internal, err.Error()) } return &types.QueryPoolBatchWithdrawMsgsResponse{ Withdraws: msgs, Pagination: pageRes, }, nil } // Params queries params of liquidity module. func (k Querier) Params(c context.Context, req *types.QueryParamsRequest) (*types.QueryParamsResponse, error) { ctx := sdk.UnwrapSDKContext(c) params := k.GetParams(ctx) return &types.QueryParamsResponse{ Params: params, }, nil } // MakeQueryLiquidityPoolResponse wraps MakeQueryLiquidityPoolResponse. func (k Querier) MakeQueryLiquidityPoolResponse(pool types.Pool) (*types.QueryLiquidityPoolResponse, error) { return &types.QueryLiquidityPoolResponse{ Pool: pool, }, nil } // MakeQueryLiquidityPoolsResponse wraps a list of QueryLiquidityPoolResponses. func (k Querier) MakeQueryLiquidityPoolsResponse(pools types.Pools) (*[]types.QueryLiquidityPoolResponse, error) { resp := make([]types.QueryLiquidityPoolResponse, len(pools)) for i, pool := range pools { res := types.QueryLiquidityPoolResponse{ Pool: pool, } resp[i] = res } return &resp, nil } ================================================ FILE: x/liquidity/keeper/invariants.go ================================================ package keeper import ( "fmt" "cosmossdk.io/math" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/liquidity/types" ) // RegisterInvariants registers all liquidity invariants. func RegisterInvariants(ir sdk.InvariantRegistry, k Keeper) { ir.RegisterRoute(types.ModuleName, "escrow-amount", LiquidityPoolsEscrowAmountInvariant(k)) } // AllInvariants runs all invariants of the liquidity module. func AllInvariants(k Keeper) sdk.Invariant { return func(ctx sdk.Context) (string, bool) { res, stop := LiquidityPoolsEscrowAmountInvariant(k)(ctx) return res, stop } } // LiquidityPoolsEscrowAmountInvariant checks that outstanding unwithdrawn fees are never negative. func LiquidityPoolsEscrowAmountInvariant(k Keeper) sdk.Invariant { return func(ctx sdk.Context) (string, bool) { remainingCoins := sdk.NewCoins() batches := k.GetAllPoolBatches(ctx) for _, batch := range batches { swapMsgs := k.GetAllPoolBatchSwapMsgStatesNotToBeDeleted(ctx, batch) for _, msg := range swapMsgs { remainingCoins = remainingCoins.Add(msg.RemainingOfferCoin) } depositMsgs := k.GetAllPoolBatchDepositMsgStatesNotToBeDeleted(ctx, batch) for _, msg := range depositMsgs { remainingCoins = remainingCoins.Add(msg.Msg.DepositCoins...) } withdrawMsgs := k.GetAllPoolBatchWithdrawMsgStatesNotToBeDeleted(ctx, batch) for _, msg := range withdrawMsgs { remainingCoins = remainingCoins.Add(msg.Msg.PoolCoin) } } batchEscrowAcc := k.accountKeeper.GetModuleAddress(types.ModuleName) escrowAmt := k.bankKeeper.GetAllBalances(ctx, batchEscrowAcc) broken := !escrowAmt.IsAllGTE(remainingCoins) return sdk.FormatInvariant(types.ModuleName, "batch escrow amount invariant broken", "batch escrow amount LT batch remaining amount"), broken } } // These invariants cannot be registered via RegisterInvariants since the module uses per-block batch execution. // We should approach adding these invariant checks inside actual logics of deposit / withdraw / swap. var ( BatchLogicInvariantCheckFlag = false // It is only used at the development stage, and is disabled at the product level. // For coin amounts less than coinAmountThreshold, a high errorRate does not mean // that the calculation logic has errors. // For example, if there were two X coins and three Y coins in the pool, and someone deposits // one X coin and one Y coin, it's an acceptable input. // But pool price would change from 2/3 to 3/4 so errorRate will report 1/8(=0.125), // meaning that the price has changed by 12.5%. // This happens with small coin amounts, so there should be a threshold for coin amounts // before we calculate the errorRate. errorRateThreshold = sdk.NewDecWithPrec(5, 2) // 5% coinAmountThreshold = sdk.NewInt(20) // If a decimal error occurs at a value less than 20, the error rate is over 5%. ) func errorRate(expected, actual sdk.Dec) sdk.Dec { // To prevent divide-by-zero panics, return 1.0(=100%) as the error rate // when the expected value is 0. if expected.IsZero() { return sdk.OneDec() } return actual.Sub(expected).Quo(expected).Abs() } // MintingPoolCoinsInvariant checks the correct ratio of minting amount of pool coins. func MintingPoolCoinsInvariant(poolCoinTotalSupply, mintPoolCoin, depositCoinA, depositCoinB, lastReserveCoinA, lastReserveCoinB, refundedCoinA, refundedCoinB math.Int) { if !refundedCoinA.IsZero() { depositCoinA = depositCoinA.Sub(refundedCoinA) } if !refundedCoinB.IsZero() { depositCoinB = depositCoinB.Sub(refundedCoinB) } poolCoinRatio := sdk.NewDecFromInt(mintPoolCoin).QuoInt(poolCoinTotalSupply) depositCoinARatio := sdk.NewDecFromInt(depositCoinA).QuoInt(lastReserveCoinA) depositCoinBRatio := sdk.NewDecFromInt(depositCoinB).QuoInt(lastReserveCoinB) expectedMintPoolCoinAmtBasedA := depositCoinARatio.MulInt(poolCoinTotalSupply).TruncateInt() expectedMintPoolCoinAmtBasedB := depositCoinBRatio.MulInt(poolCoinTotalSupply).TruncateInt() // NewPoolCoinAmount / LastPoolCoinSupply == AfterRefundedDepositCoinA / LastReserveCoinA // NewPoolCoinAmount / LastPoolCoinSupply == AfterRefundedDepositCoinA / LastReserveCoinB if depositCoinA.GTE(coinAmountThreshold) && depositCoinB.GTE(coinAmountThreshold) && lastReserveCoinA.GTE(coinAmountThreshold) && lastReserveCoinB.GTE(coinAmountThreshold) && mintPoolCoin.GTE(coinAmountThreshold) && poolCoinTotalSupply.GTE(coinAmountThreshold) { if errorRate(depositCoinARatio, poolCoinRatio).GT(errorRateThreshold) || errorRate(depositCoinBRatio, poolCoinRatio).GT(errorRateThreshold) { panic("invariant check fails due to incorrect ratio of pool coins") } } if mintPoolCoin.GTE(coinAmountThreshold) && (sdk.NewDecFromInt(sdk.MaxInt(mintPoolCoin, expectedMintPoolCoinAmtBasedA).Sub(sdk.MinInt(mintPoolCoin, expectedMintPoolCoinAmtBasedA))).QuoInt(mintPoolCoin).GT(errorRateThreshold) || sdk.NewDecFromInt(sdk.MaxInt(mintPoolCoin, expectedMintPoolCoinAmtBasedB).Sub(sdk.MinInt(mintPoolCoin, expectedMintPoolCoinAmtBasedA))).QuoInt(mintPoolCoin).GT(errorRateThreshold)) { panic("invariant check fails due to incorrect amount of pool coins") } } // DepositInvariant checks after deposit amounts. // //nolint:staticcheck func DepositInvariant(lastReserveCoinA, lastReserveCoinB, depositCoinA, depositCoinB, afterReserveCoinA, afterReserveCoinB, refundedCoinA, refundedCoinB math.Int) { depositCoinA = depositCoinA.Sub(refundedCoinA) depositCoinB = depositCoinB.Sub(refundedCoinB) depositCoinRatio := sdk.NewDecFromInt(depositCoinA).Quo(sdk.NewDecFromInt(depositCoinB)) lastReserveRatio := sdk.NewDecFromInt(lastReserveCoinA).Quo(sdk.NewDecFromInt(lastReserveCoinB)) afterReserveRatio := sdk.NewDecFromInt(afterReserveCoinA).Quo(sdk.NewDecFromInt(afterReserveCoinB)) // AfterDepositReserveCoinA = LastReserveCoinA + AfterRefundedDepositCoinA // AfterDepositReserveCoinB = LastReserveCoinB + AfterRefundedDepositCoinA if !afterReserveCoinA.Equal(lastReserveCoinA.Add(depositCoinA)) || !afterReserveCoinB.Equal(lastReserveCoinB.Add(depositCoinB)) { panic("invariant check fails due to incorrect deposit amounts") } if depositCoinA.GTE(coinAmountThreshold) && depositCoinB.GTE(coinAmountThreshold) && lastReserveCoinA.GTE(coinAmountThreshold) && lastReserveCoinB.GTE(coinAmountThreshold) { // AfterRefundedDepositCoinA / AfterRefundedDepositCoinA = LastReserveCoinA / LastReserveCoinB if errorRate(lastReserveRatio, depositCoinRatio).GT(errorRateThreshold) { panic("invariant check fails due to incorrect deposit ratio") } // LastReserveCoinA / LastReserveCoinB = AfterDepositReserveCoinA / AfterDepositReserveCoinB if errorRate(lastReserveRatio, afterReserveRatio).GT(errorRateThreshold) { panic("invariant check fails due to incorrect pool price ratio") } } } // BurningPoolCoinsInvariant checks the correct burning amount of pool coins. // //nolint:staticcheck func BurningPoolCoinsInvariant(burnedPoolCoin, withdrawCoinA, withdrawCoinB, reserveCoinA, reserveCoinB, lastPoolCoinSupply math.Int, withdrawFeeCoins sdk.Coins) { burningPoolCoinRatio := sdk.NewDecFromInt(burnedPoolCoin).Quo(sdk.NewDecFromInt(lastPoolCoinSupply)) if burningPoolCoinRatio.Equal(sdk.OneDec()) { return } withdrawCoinARatio := sdk.NewDecFromInt(withdrawCoinA.Add(withdrawFeeCoins[0].Amount)).Quo(sdk.NewDecFromInt(reserveCoinA)) withdrawCoinBRatio := sdk.NewDecFromInt(withdrawCoinB.Add(withdrawFeeCoins[1].Amount)).Quo(sdk.NewDecFromInt(reserveCoinB)) // BurnedPoolCoinAmount / LastPoolCoinSupply >= (WithdrawCoinA+WithdrawFeeCoinA) / LastReserveCoinA // BurnedPoolCoinAmount / LastPoolCoinSupply >= (WithdrawCoinB+WithdrawFeeCoinB) / LastReserveCoinB if withdrawCoinARatio.GT(burningPoolCoinRatio) || withdrawCoinBRatio.GT(burningPoolCoinRatio) { panic("invariant check fails due to incorrect ratio of burning pool coins") } expectedBurningPoolCoinBasedA := sdk.NewDecFromInt(lastPoolCoinSupply).MulTruncate(withdrawCoinARatio).TruncateInt() expectedBurningPoolCoinBasedB := sdk.NewDecFromInt(lastPoolCoinSupply).MulTruncate(withdrawCoinBRatio).TruncateInt() if burnedPoolCoin.GTE(coinAmountThreshold) && (sdk.NewDecFromInt(sdk.MaxInt(burnedPoolCoin, expectedBurningPoolCoinBasedA).Sub(sdk.MinInt(burnedPoolCoin, expectedBurningPoolCoinBasedA))).QuoInt(burnedPoolCoin).GT(errorRateThreshold) || sdk.NewDecFromInt(sdk.MaxInt(burnedPoolCoin, expectedBurningPoolCoinBasedB).Sub(sdk.MinInt(burnedPoolCoin, expectedBurningPoolCoinBasedB))).QuoInt(burnedPoolCoin).GT(errorRateThreshold)) { panic("invariant check fails due to incorrect amount of burning pool coins") } } // WithdrawReserveCoinsInvariant checks the after withdraw amounts. // //nolint:staticcheck func WithdrawReserveCoinsInvariant(withdrawCoinA, withdrawCoinB, reserveCoinA, reserveCoinB, afterReserveCoinA, afterReserveCoinB, afterPoolCoinTotalSupply, lastPoolCoinSupply, burnedPoolCoin math.Int, ) { // AfterWithdrawReserveCoinA = LastReserveCoinA - WithdrawCoinA if !afterReserveCoinA.Equal(reserveCoinA.Sub(withdrawCoinA)) { panic("invariant check fails due to incorrect withdraw coin A amount") } // AfterWithdrawReserveCoinB = LastReserveCoinB - WithdrawCoinB if !afterReserveCoinB.Equal(reserveCoinB.Sub(withdrawCoinB)) { panic("invariant check fails due to incorrect withdraw coin B amount") } // AfterWithdrawPoolCoinSupply = LastPoolCoinSupply - BurnedPoolCoinAmount if !afterPoolCoinTotalSupply.Equal(lastPoolCoinSupply.Sub(burnedPoolCoin)) { panic("invariant check fails due to incorrect total supply") } } // WithdrawAmountInvariant checks the correct ratio of withdraw coin amounts. // //nolint:staticcheck func WithdrawAmountInvariant(withdrawCoinA, withdrawCoinB, reserveCoinA, reserveCoinB, burnedPoolCoin, poolCoinSupply math.Int, withdrawFeeRate sdk.Dec) { ratio := sdk.NewDecFromInt(burnedPoolCoin).Quo(sdk.NewDecFromInt(poolCoinSupply)).Mul(sdk.OneDec().Sub(withdrawFeeRate)) idealWithdrawCoinA := sdk.NewDecFromInt(reserveCoinA).Mul(ratio) idealWithdrawCoinB := sdk.NewDecFromInt(reserveCoinB).Mul(ratio) diffA := idealWithdrawCoinA.Sub(sdk.NewDecFromInt(withdrawCoinA)).Abs() diffB := idealWithdrawCoinB.Sub(sdk.NewDecFromInt(withdrawCoinB)).Abs() if !burnedPoolCoin.Equal(poolCoinSupply) { if diffA.GTE(sdk.OneDec()) { panic(fmt.Sprintf("withdraw coin amount %v differs too much from %v", withdrawCoinA, idealWithdrawCoinA)) } if diffB.GTE(sdk.OneDec()) { panic(fmt.Sprintf("withdraw coin amount %v differs too much from %v", withdrawCoinB, idealWithdrawCoinB)) } } } // ImmutablePoolPriceAfterWithdrawInvariant checks the immutable pool price after withdrawing coins. // //nolint:staticcheck func ImmutablePoolPriceAfterWithdrawInvariant(reserveCoinA, reserveCoinB, withdrawCoinA, withdrawCoinB, afterReserveCoinA, afterReserveCoinB math.Int) { // TestReinitializePool tests a scenario where after reserve coins are zero if !afterReserveCoinA.IsZero() && !afterReserveCoinB.IsZero() { reserveCoinA = reserveCoinA.Sub(withdrawCoinA) reserveCoinB = reserveCoinB.Sub(withdrawCoinB) reserveCoinRatio := sdk.NewDecFromInt(reserveCoinA).Quo(sdk.NewDecFromInt(reserveCoinB)) afterReserveCoinRatio := sdk.NewDecFromInt(afterReserveCoinA).Quo(sdk.NewDecFromInt(afterReserveCoinB)) // LastReserveCoinA / LastReserveCoinB = AfterWithdrawReserveCoinA / AfterWithdrawReserveCoinB if reserveCoinA.GTE(coinAmountThreshold) && reserveCoinB.GTE(coinAmountThreshold) && withdrawCoinA.GTE(coinAmountThreshold) && withdrawCoinB.GTE(coinAmountThreshold) && errorRate(reserveCoinRatio, afterReserveCoinRatio).GT(errorRateThreshold) { panic("invariant check fails due to incorrect pool price ratio") } } } // SwapMatchingInvariants checks swap matching results of both X to Y and Y to X cases. func SwapMatchingInvariants(xToY, yToX []*types.SwapMsgState, matchResultXtoY, matchResultYtoX []types.MatchResult) { beforeMatchingXtoYLen := len(xToY) beforeMatchingYtoXLen := len(yToX) afterMatchingXtoYLen := len(matchResultXtoY) afterMatchingYtoXLen := len(matchResultYtoX) notMatchedXtoYLen := beforeMatchingXtoYLen - afterMatchingXtoYLen notMatchedYtoXLen := beforeMatchingYtoXLen - afterMatchingYtoXLen if notMatchedXtoYLen != types.CountNotMatchedMsgs(xToY) { panic("invariant check fails due to invalid xToY match length") } if notMatchedYtoXLen != types.CountNotMatchedMsgs(yToX) { panic("invariant check fails due to invalid yToX match length") } } // SwapPriceInvariants checks swap price invariants. func SwapPriceInvariants(matchResultXtoY, matchResultYtoX []types.MatchResult, poolXDelta, poolYDelta, poolXDelta2, poolYDelta2 sdk.Dec, result types.BatchResult) { invariantCheckX := sdk.ZeroDec() invariantCheckY := sdk.ZeroDec() for _, m := range matchResultXtoY { invariantCheckX = invariantCheckX.Sub(m.TransactedCoinAmt) invariantCheckY = invariantCheckY.Add(m.ExchangedDemandCoinAmt) } for _, m := range matchResultYtoX { invariantCheckY = invariantCheckY.Sub(m.TransactedCoinAmt) invariantCheckX = invariantCheckX.Add(m.ExchangedDemandCoinAmt) } invariantCheckX = invariantCheckX.Add(poolXDelta2) invariantCheckY = invariantCheckY.Add(poolYDelta2) if !invariantCheckX.IsZero() && !invariantCheckY.IsZero() { panic(fmt.Errorf("invariant check fails due to invalid swap price: %s", invariantCheckX.String())) } validitySwapPrice := types.CheckSwapPrice(matchResultXtoY, matchResultYtoX, result.SwapPrice) if !validitySwapPrice { panic("invariant check fails due to invalid swap price") } } // SwapPriceDirectionInvariants checks whether the calculated swap price is increased, decreased, or stayed from the last pool price. func SwapPriceDirectionInvariants(currentPoolPrice sdk.Dec, batchResult types.BatchResult) { switch batchResult.PriceDirection { case types.Increasing: if !batchResult.SwapPrice.GT(currentPoolPrice) { panic("invariant check fails due to incorrect price direction") } case types.Decreasing: if !batchResult.SwapPrice.LT(currentPoolPrice) { panic("invariant check fails due to incorrect price direction") } case types.Staying: if !batchResult.SwapPrice.Equal(currentPoolPrice) { panic("invariant check fails due to incorrect price direction") } } } // SwapMsgStatesInvariants checks swap match result states invariants. func SwapMsgStatesInvariants(matchResultXtoY, matchResultYtoX []types.MatchResult, matchResultMap map[uint64]types.MatchResult, swapMsgStates []*types.SwapMsgState, xToY, yToX []*types.SwapMsgState, ) { if len(matchResultXtoY)+len(matchResultYtoX) != len(matchResultMap) { panic("invalid length of match result") } for k, v := range matchResultMap { if k != v.SwapMsgState.MsgIndex { panic("broken map consistency") } } for _, sms := range swapMsgStates { for _, smsXtoY := range xToY { if sms.MsgIndex == smsXtoY.MsgIndex { if *(sms) != *(smsXtoY) || sms != smsXtoY { panic("swap message state not matched") } else { break } } } for _, smsYtoX := range yToX { if sms.MsgIndex == smsYtoX.MsgIndex { if *(sms) != *(smsYtoX) || sms != smsYtoX { panic("swap message state not matched") } else { break } } } if msgAfter, ok := matchResultMap[sms.MsgIndex]; ok { if sms.MsgIndex == msgAfter.SwapMsgState.MsgIndex { if *(sms) != *(msgAfter.SwapMsgState) || sms != msgAfter.SwapMsgState { panic("batch message not matched") } } else { panic("fail msg pointer consistency") } } } } // SwapOrdersExecutionStateInvariants checks all executed orders have order price which is not "executable" or not "unexecutable". func SwapOrdersExecutionStateInvariants(matchResultMap map[uint64]types.MatchResult, swapMsgStates []*types.SwapMsgState, batchResult types.BatchResult, denomX string, ) { for _, sms := range swapMsgStates { if _, ok := matchResultMap[sms.MsgIndex]; ok { if !sms.Executed || !sms.Succeeded { panic("swap msg state consistency error, matched but not succeeded") } if sms.Msg.OfferCoin.Denom == denomX { // buy orders having equal or higher order price than found swapPrice if !sms.Msg.OrderPrice.GTE(batchResult.SwapPrice) { panic("execution validity failed, executed but unexecutable") } } else { // sell orders having equal or lower order price than found swapPrice if !sms.Msg.OrderPrice.LTE(batchResult.SwapPrice) { panic("execution validity failed, executed but unexecutable") } } } else { // check whether every unexecuted orders have order price which is not "executable" if sms.Executed && sms.Succeeded { panic("sms consistency error, not matched but succeeded") } if sms.Msg.OfferCoin.Denom == denomX { // buy orders having equal or lower order price than found swapPrice if !sms.Msg.OrderPrice.LTE(batchResult.SwapPrice) { panic("execution validity failed, unexecuted but executable") } } else { // sell orders having equal or higher order price than found swapPrice if !sms.Msg.OrderPrice.GTE(batchResult.SwapPrice) { panic("execution validity failed, unexecuted but executable") } } } } } ================================================ FILE: x/liquidity/keeper/keeper.go ================================================ package keeper import ( "fmt" "github.com/cometbft/cometbft/libs/log" "github.com/cosmos/cosmos-sdk/codec" storetypes "github.com/cosmos/cosmos-sdk/store/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/liquidity/types" ) // Keeper of the liquidity store type Keeper struct { cdc codec.BinaryCodec storeKey storetypes.StoreKey bankKeeper types.BankKeeper accountKeeper types.AccountKeeper distrKeeper types.DistributionKeeper authority string } // NewKeeper returns a liquidity keeper. It handles: // - creating new ModuleAccounts for each pool ReserveAccount // - sending to and from ModuleAccounts // - minting, burning PoolCoins func NewKeeper( cdc codec.BinaryCodec, key storetypes.StoreKey, bankKeeper types.BankKeeper, accountKeeper types.AccountKeeper, distrKeeper types.DistributionKeeper, authority string, ) Keeper { // ensure liquidity module account is set if addr := accountKeeper.GetModuleAddress(types.ModuleName); addr == nil { panic(fmt.Sprintf("%s module account has not been set", types.ModuleName)) } return Keeper{ storeKey: key, bankKeeper: bankKeeper, accountKeeper: accountKeeper, distrKeeper: distrKeeper, cdc: cdc, authority: authority, } } // GetAuthority returns the x/mint module's authority. func (k Keeper) GetAuthority() string { return k.authority } func (k Keeper) Logger(ctx sdk.Context) log.Logger { return ctx.Logger().With("module", fmt.Sprintf("x/%s", types.ModuleName)) } func (k Keeper) SetParams(ctx sdk.Context, p types.Params) error { if err := p.Validate(); err != nil { return err } store := ctx.KVStore(k.storeKey) bz := k.cdc.MustMarshal(&p) store.Set(types.ParamsKey, bz) return nil } func (k Keeper) GetParams(ctx sdk.Context) (p types.Params) { store := ctx.KVStore(k.storeKey) bz := store.Get(types.ParamsKey) if bz == nil { return p } k.cdc.MustUnmarshal(bz, &p) return p } // GetCircuitBreakerEnabled returns circuit breaker enabled param from the paramspace. func (k Keeper) GetCircuitBreakerEnabled(ctx sdk.Context) bool { return k.GetParams(ctx).CircuitBreakerEnabled } ================================================ FILE: x/liquidity/keeper/liquidity_pool.go ================================================ package keeper import ( "fmt" "strconv" errorsmod "cosmossdk.io/errors" "cosmossdk.io/math" sdk "github.com/cosmos/cosmos-sdk/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" "github.com/cybercongress/go-cyber/v7/x/liquidity/types" ) func (k Keeper) ValidateMsgCreatePool(ctx sdk.Context, msg *types.MsgCreatePool) error { params := k.GetParams(ctx) var poolType types.PoolType // check poolType exist, get poolType from param if len(params.PoolTypes) >= int(msg.PoolTypeId) { poolType = params.PoolTypes[msg.PoolTypeId-1] if poolType.Id != msg.PoolTypeId { return types.ErrPoolTypeNotExists } } else { return types.ErrPoolTypeNotExists } reserveCoinNum := uint32(msg.DepositCoins.Len()) if reserveCoinNum > poolType.MaxReserveCoinNum || poolType.MinReserveCoinNum > reserveCoinNum { return types.ErrNumOfReserveCoin } reserveCoinDenoms := make([]string, reserveCoinNum) for i := 0; i < int(reserveCoinNum); i++ { reserveCoinDenoms[i] = msg.DepositCoins.GetDenomByIndex(i) } denomA, denomB := types.AlphabeticalDenomPair(reserveCoinDenoms[0], reserveCoinDenoms[1]) if denomA != msg.DepositCoins[0].Denom || denomB != msg.DepositCoins[1].Denom { return types.ErrBadOrderingReserveCoin } if denomA == denomB { return types.ErrEqualDenom } if err := types.ValidateReserveCoinLimit(params.MaxReserveCoinAmount, msg.DepositCoins); err != nil { return err } poolName := types.PoolName(reserveCoinDenoms, msg.PoolTypeId) reserveAcc := types.GetPoolReserveAcc(poolName, false) _, found := k.GetPoolByReserveAccIndex(ctx, reserveAcc) if found { return types.ErrPoolAlreadyExists } return nil } func (k Keeper) MintAndSendPoolCoin(ctx sdk.Context, pool types.Pool, srcAddr, creatorAddr sdk.AccAddress, depositCoins sdk.Coins) (sdk.Coin, error) { cacheCtx, writeCache := ctx.CacheContext() params := k.GetParams(cacheCtx) mintingCoin := sdk.NewCoin(pool.PoolCoinDenom, params.InitPoolCoinMintAmount) mintingCoins := sdk.NewCoins(mintingCoin) if err := k.bankKeeper.MintCoins(cacheCtx, types.ModuleName, mintingCoins); err != nil { return sdk.Coin{}, err } reserveAcc := pool.GetReserveAccount() var inputs []banktypes.Input var outputs []banktypes.Output inputs = append(inputs, banktypes.NewInput(srcAddr, depositCoins)) outputs = append(outputs, banktypes.NewOutput(reserveAcc, depositCoins)) inputs = append(inputs, banktypes.NewInput(k.accountKeeper.GetModuleAddress(types.ModuleName), mintingCoins)) outputs = append(outputs, banktypes.NewOutput(creatorAddr, mintingCoins)) if err := k.bankKeeper.InputOutputCoins(cacheCtx, inputs, outputs); err != nil { return sdk.Coin{}, err } writeCache() return mintingCoin, nil } func (k Keeper) CreatePool(ctx sdk.Context, msg *types.MsgCreatePool) (types.Pool, error) { if err := k.ValidateMsgCreatePool(ctx, msg); err != nil { return types.Pool{}, err } params := k.GetParams(ctx) denom1, denom2 := types.AlphabeticalDenomPair(msg.DepositCoins[0].Denom, msg.DepositCoins[1].Denom) reserveCoinDenoms := []string{denom1, denom2} poolName := types.PoolName(reserveCoinDenoms, msg.PoolTypeId) pool := types.Pool{ // Id: will set on SetPoolAtomic TypeId: msg.PoolTypeId, ReserveCoinDenoms: reserveCoinDenoms, ReserveAccountAddress: types.GetPoolReserveAcc(poolName, false).String(), PoolCoinDenom: types.GetPoolCoinDenom(poolName), } poolCreator := msg.GetPoolCreator() for _, coin := range msg.DepositCoins { if coin.Amount.LT(params.MinInitDepositAmount) { return types.Pool{}, errorsmod.Wrapf( types.ErrLessThanMinInitDeposit, "deposit coin %s is smaller than %s", coin, params.MinInitDepositAmount) } } for _, coin := range msg.DepositCoins { balance := k.bankKeeper.GetBalance(ctx, poolCreator, coin.Denom) if balance.IsLT(coin) { return types.Pool{}, errorsmod.Wrapf( types.ErrInsufficientBalance, "%s is smaller than %s", balance, coin) } } for _, coin := range params.PoolCreationFee { balance := k.bankKeeper.GetBalance(ctx, poolCreator, coin.Denom) neededAmt := coin.Amount.Add(msg.DepositCoins.AmountOf(coin.Denom)) neededCoin := sdk.NewCoin(coin.Denom, neededAmt) if balance.IsLT(neededCoin) { return types.Pool{}, errorsmod.Wrapf( types.ErrInsufficientPoolCreationFee, "%s is smaller than %s", balance, neededCoin) } } if _, err := k.MintAndSendPoolCoin(ctx, pool, poolCreator, poolCreator, msg.DepositCoins); err != nil { return types.Pool{}, err } // pool creation fees are collected in community pool if err := k.distrKeeper.FundCommunityPool(ctx, params.PoolCreationFee, poolCreator); err != nil { return types.Pool{}, err } pool = k.SetPoolAtomic(ctx, pool) batch := types.NewPoolBatch(pool.Id, 1) batch.BeginHeight = ctx.BlockHeight() k.SetPoolBatch(ctx, batch) reserveCoins := k.GetReserveCoins(ctx, pool) lastReserveRatio := sdk.NewDecFromInt(reserveCoins[0].Amount).Quo(sdk.NewDecFromInt(reserveCoins[1].Amount)) logger := k.Logger(ctx) logger.Debug( "create liquidity pool", "msg", msg, "pool", pool, "reserveCoins", reserveCoins, "lastReserveRatio", lastReserveRatio, ) return pool, nil } func (k Keeper) ExecuteDeposit(ctx sdk.Context, msg types.DepositMsgState, batch types.PoolBatch) error { if msg.Executed || msg.ToBeDeleted || msg.Succeeded { return fmt.Errorf("cannot process already executed batch msg") } msg.Executed = true k.SetPoolBatchDepositMsgState(ctx, msg.Msg.PoolId, msg) if err := k.ValidateMsgDepositWithinBatch(ctx, *msg.Msg); err != nil { return err } pool, found := k.GetPool(ctx, msg.Msg.PoolId) if !found { return types.ErrPoolNotExists } depositCoins := msg.Msg.DepositCoins.Sort() batchEscrowAcc := k.accountKeeper.GetModuleAddress(types.ModuleName) reserveAcc := pool.GetReserveAccount() depositor := msg.Msg.GetDepositor() params := k.GetParams(ctx) reserveCoins := k.GetReserveCoins(ctx, pool) // reinitialize pool if the pool is depleted if k.IsDepletedPool(ctx, pool) { for _, depositCoin := range msg.Msg.DepositCoins { if depositCoin.Amount.Add(reserveCoins.AmountOf(depositCoin.Denom)).LT(params.MinInitDepositAmount) { return types.ErrLessThanMinInitDeposit } } poolCoin, err := k.MintAndSendPoolCoin(ctx, pool, batchEscrowAcc, depositor, msg.Msg.DepositCoins) if err != nil { return err } // set deposit msg state of the pool batch complete msg.Succeeded = true msg.ToBeDeleted = true k.SetPoolBatchDepositMsgState(ctx, msg.Msg.PoolId, msg) reserveCoins = k.GetReserveCoins(ctx, pool) lastReserveCoinA := sdk.NewDecFromInt(reserveCoins[0].Amount) lastReserveCoinB := sdk.NewDecFromInt(reserveCoins[1].Amount) lastReserveRatio := lastReserveCoinA.Quo(lastReserveCoinB) ctx.EventManager().EmitEvent( sdk.NewEvent( types.EventTypeDepositToPool, sdk.NewAttribute(types.AttributeValuePoolId, strconv.FormatUint(pool.Id, 10)), sdk.NewAttribute(types.AttributeValueBatchIndex, strconv.FormatUint(batch.Index, 10)), sdk.NewAttribute(types.AttributeValueMsgIndex, strconv.FormatUint(msg.MsgIndex, 10)), sdk.NewAttribute(types.AttributeValueDepositor, depositor.String()), sdk.NewAttribute(types.AttributeValueAcceptedCoins, msg.Msg.DepositCoins.String()), sdk.NewAttribute(types.AttributeValueRefundedCoins, ""), sdk.NewAttribute(types.AttributeValuePoolCoinDenom, poolCoin.Denom), sdk.NewAttribute(types.AttributeValuePoolCoinAmount, poolCoin.Amount.String()), sdk.NewAttribute(types.AttributeValueSuccess, types.Success), ), ) logger := k.Logger(ctx) logger.Debug( "reinitialize pool", "msg", msg, "pool", pool, "reserveCoins", reserveCoins, "lastReserveRatio", lastReserveRatio, ) return nil } reserveCoins.Sort() lastReserveCoinA := reserveCoins[0] lastReserveCoinB := reserveCoins[1] depositCoinA := depositCoins[0] depositCoinB := depositCoins[1] poolCoinTotalSupply := sdk.NewDecFromInt(k.GetPoolCoinTotalSupply(ctx, pool)) if err := types.CheckOverflowWithDec(poolCoinTotalSupply, sdk.NewDecFromInt(depositCoinA.Amount)); err != nil { return err } if err := types.CheckOverflowWithDec(poolCoinTotalSupply, sdk.NewDecFromInt(depositCoinB.Amount)); err != nil { return err } poolCoinMintAmt := sdk.MinDec( poolCoinTotalSupply.MulTruncate(sdk.NewDecFromInt(depositCoinA.Amount)).QuoTruncate(sdk.NewDecFromInt(lastReserveCoinA.Amount)), poolCoinTotalSupply.MulTruncate(sdk.NewDecFromInt(depositCoinB.Amount)).QuoTruncate(sdk.NewDecFromInt(lastReserveCoinB.Amount)), ) mintRate := poolCoinMintAmt.TruncateDec().QuoTruncate(poolCoinTotalSupply) acceptedCoins := sdk.NewCoins( sdk.NewCoin(depositCoins[0].Denom, sdk.NewDecFromInt(lastReserveCoinA.Amount).Mul(mintRate).TruncateInt()), sdk.NewCoin(depositCoins[1].Denom, sdk.NewDecFromInt(lastReserveCoinB.Amount).Mul(mintRate).TruncateInt()), ) refundedCoins := depositCoins.Sub(acceptedCoins...) refundedCoinA := sdk.NewCoin(depositCoinA.Denom, refundedCoins.AmountOf(depositCoinA.Denom)) refundedCoinB := sdk.NewCoin(depositCoinB.Denom, refundedCoins.AmountOf(depositCoinB.Denom)) mintPoolCoin := sdk.NewCoin(pool.PoolCoinDenom, poolCoinMintAmt.TruncateInt()) mintPoolCoins := sdk.NewCoins(mintPoolCoin) if mintPoolCoins.IsZero() || acceptedCoins.IsZero() { return fmt.Errorf("pool coin truncated, no accepted coin, refund") } if err := k.bankKeeper.MintCoins(ctx, types.ModuleName, mintPoolCoins); err != nil { return err } var inputs []banktypes.Input var outputs []banktypes.Output if !refundedCoins.IsZero() { // refund truncated deposit coins inputs = append(inputs, banktypes.NewInput(batchEscrowAcc, refundedCoins)) outputs = append(outputs, banktypes.NewOutput(depositor, refundedCoins)) } // send accepted deposit coins inputs = append(inputs, banktypes.NewInput(batchEscrowAcc, acceptedCoins)) outputs = append(outputs, banktypes.NewOutput(reserveAcc, acceptedCoins)) // send minted pool coins inputs = append(inputs, banktypes.NewInput(batchEscrowAcc, mintPoolCoins)) outputs = append(outputs, banktypes.NewOutput(depositor, mintPoolCoins)) // execute multi-send if err := k.bankKeeper.InputOutputCoins(ctx, inputs, outputs); err != nil { return err } msg.Succeeded = true msg.ToBeDeleted = true k.SetPoolBatchDepositMsgState(ctx, msg.Msg.PoolId, msg) if BatchLogicInvariantCheckFlag { afterReserveCoins := k.GetReserveCoins(ctx, pool) afterReserveCoinA := afterReserveCoins[0].Amount afterReserveCoinB := afterReserveCoins[1].Amount MintingPoolCoinsInvariant(poolCoinTotalSupply.TruncateInt(), mintPoolCoin.Amount, depositCoinA.Amount, depositCoinB.Amount, lastReserveCoinA.Amount, lastReserveCoinB.Amount, refundedCoinA.Amount, refundedCoinB.Amount) DepositInvariant(lastReserveCoinA.Amount, lastReserveCoinB.Amount, depositCoinA.Amount, depositCoinB.Amount, afterReserveCoinA, afterReserveCoinB, refundedCoinA.Amount, refundedCoinB.Amount) } ctx.EventManager().EmitEvent( sdk.NewEvent( types.EventTypeDepositToPool, sdk.NewAttribute(types.AttributeValuePoolId, strconv.FormatUint(pool.Id, 10)), sdk.NewAttribute(types.AttributeValueBatchIndex, strconv.FormatUint(batch.Index, 10)), sdk.NewAttribute(types.AttributeValueMsgIndex, strconv.FormatUint(msg.MsgIndex, 10)), sdk.NewAttribute(types.AttributeValueDepositor, depositor.String()), sdk.NewAttribute(types.AttributeValueAcceptedCoins, acceptedCoins.String()), sdk.NewAttribute(types.AttributeValueRefundedCoins, refundedCoins.String()), sdk.NewAttribute(types.AttributeValuePoolCoinDenom, mintPoolCoin.Denom), sdk.NewAttribute(types.AttributeValuePoolCoinAmount, mintPoolCoin.Amount.String()), sdk.NewAttribute(types.AttributeValueSuccess, types.Success), ), ) reserveCoins = k.GetReserveCoins(ctx, pool) lastReserveRatio := sdk.NewDecFromInt(reserveCoins[0].Amount).Quo(sdk.NewDecFromInt(reserveCoins[1].Amount)) logger := k.Logger(ctx) logger.Debug( "deposit coins to the pool", "msg", msg, "pool", pool, "inputs", inputs, "outputs", outputs, "reserveCoins", reserveCoins, "lastReserveRatio", lastReserveRatio, ) return nil } // ExecuteWithdrawal withdraws pool coin from the liquidity pool func (k Keeper) ExecuteWithdrawal(ctx sdk.Context, msg types.WithdrawMsgState, batch types.PoolBatch) error { if msg.Executed || msg.ToBeDeleted || msg.Succeeded { return fmt.Errorf("cannot process already executed batch msg") } msg.Executed = true k.SetPoolBatchWithdrawMsgState(ctx, msg.Msg.PoolId, msg) if err := k.ValidateMsgWithdrawWithinBatch(ctx, *msg.Msg); err != nil { return err } poolCoins := sdk.NewCoins(msg.Msg.PoolCoin) pool, found := k.GetPool(ctx, msg.Msg.PoolId) if !found { return types.ErrPoolNotExists } poolCoinTotalSupply := k.GetPoolCoinTotalSupply(ctx, pool) reserveCoins := k.GetReserveCoins(ctx, pool) reserveCoins.Sort() var inputs []banktypes.Input var outputs []banktypes.Output reserveAcc := pool.GetReserveAccount() withdrawer := msg.Msg.GetWithdrawer() params := k.GetParams(ctx) withdrawProportion := sdk.OneDec().Sub(params.WithdrawFeeRate) withdrawCoins := sdk.NewCoins() withdrawFeeCoins := sdk.NewCoins() // Case for withdrawing all reserve coins if msg.Msg.PoolCoin.Amount.Equal(poolCoinTotalSupply) { withdrawCoins = reserveCoins } else { // Calculate withdraw amount of respective reserve coin considering fees and pool coin's totally supply for _, reserveCoin := range reserveCoins { if err := types.CheckOverflow(reserveCoin.Amount, msg.Msg.PoolCoin.Amount); err != nil { return err } if err := types.CheckOverflow(sdk.NewDecFromInt(reserveCoin.Amount.Mul(msg.Msg.PoolCoin.Amount)).TruncateInt(), poolCoinTotalSupply); err != nil { return err } // WithdrawAmount = ReserveAmount * PoolCoinAmount * WithdrawFeeProportion / TotalSupply withdrawAmtWithFee := sdk.NewDecFromInt(reserveCoin.Amount.Mul(msg.Msg.PoolCoin.Amount)).TruncateInt().Quo(poolCoinTotalSupply) withdrawAmt := sdk.NewDecFromInt(reserveCoin.Amount.Mul(msg.Msg.PoolCoin.Amount)).MulTruncate(withdrawProportion).TruncateInt().Quo(poolCoinTotalSupply) withdrawCoins = append(withdrawCoins, sdk.NewCoin(reserveCoin.Denom, withdrawAmt)) withdrawFeeCoins = append(withdrawFeeCoins, sdk.NewCoin(reserveCoin.Denom, withdrawAmtWithFee.Sub(withdrawAmt))) } } if withdrawCoins.IsValid() { inputs = append(inputs, banktypes.NewInput(reserveAcc, withdrawCoins)) outputs = append(outputs, banktypes.NewOutput(withdrawer, withdrawCoins)) } else { return types.ErrBadPoolCoinAmount } // send withdrawing coins to the withdrawer if err := k.bankKeeper.InputOutputCoins(ctx, inputs, outputs); err != nil { return err } // burn the escrowed pool coins if err := k.bankKeeper.BurnCoins(ctx, types.ModuleName, poolCoins); err != nil { return err } msg.Succeeded = true msg.ToBeDeleted = true k.SetPoolBatchWithdrawMsgState(ctx, msg.Msg.PoolId, msg) if BatchLogicInvariantCheckFlag { afterPoolCoinTotalSupply := k.GetPoolCoinTotalSupply(ctx, pool) afterReserveCoins := k.GetReserveCoins(ctx, pool) afterReserveCoinA := sdk.ZeroInt() afterReserveCoinB := sdk.ZeroInt() if !afterReserveCoins.IsZero() { afterReserveCoinA = afterReserveCoins[0].Amount afterReserveCoinB = afterReserveCoins[1].Amount } burnedPoolCoin := poolCoins[0].Amount withdrawCoinA := withdrawCoins[0].Amount withdrawCoinB := withdrawCoins[1].Amount reserveCoinA := reserveCoins[0].Amount reserveCoinB := reserveCoins[1].Amount lastPoolCoinTotalSupply := poolCoinTotalSupply afterPoolTotalSupply := afterPoolCoinTotalSupply BurningPoolCoinsInvariant(burnedPoolCoin, withdrawCoinA, withdrawCoinB, reserveCoinA, reserveCoinB, lastPoolCoinTotalSupply, withdrawFeeCoins) WithdrawReserveCoinsInvariant(withdrawCoinA, withdrawCoinB, reserveCoinA, reserveCoinB, afterReserveCoinA, afterReserveCoinB, afterPoolTotalSupply, lastPoolCoinTotalSupply, burnedPoolCoin) WithdrawAmountInvariant(withdrawCoinA, withdrawCoinB, reserveCoinA, reserveCoinB, burnedPoolCoin, lastPoolCoinTotalSupply, params.WithdrawFeeRate) ImmutablePoolPriceAfterWithdrawInvariant(reserveCoinA, reserveCoinB, withdrawCoinA, withdrawCoinB, afterReserveCoinA, afterReserveCoinB) } ctx.EventManager().EmitEvent( sdk.NewEvent( types.EventTypeWithdrawFromPool, sdk.NewAttribute(types.AttributeValuePoolId, strconv.FormatUint(pool.Id, 10)), sdk.NewAttribute(types.AttributeValueBatchIndex, strconv.FormatUint(batch.Index, 10)), sdk.NewAttribute(types.AttributeValueMsgIndex, strconv.FormatUint(msg.MsgIndex, 10)), sdk.NewAttribute(types.AttributeValueWithdrawer, withdrawer.String()), sdk.NewAttribute(types.AttributeValuePoolCoinDenom, msg.Msg.PoolCoin.Denom), sdk.NewAttribute(types.AttributeValuePoolCoinAmount, msg.Msg.PoolCoin.Amount.String()), sdk.NewAttribute(types.AttributeValueWithdrawCoins, withdrawCoins.String()), sdk.NewAttribute(types.AttributeValueWithdrawFeeCoins, withdrawFeeCoins.String()), sdk.NewAttribute(types.AttributeValueSuccess, types.Success), ), ) reserveCoins = k.GetReserveCoins(ctx, pool) var lastReserveRatio sdk.Dec if reserveCoins.IsZero() { lastReserveRatio = sdk.ZeroDec() } else { lastReserveRatio = sdk.NewDecFromInt(reserveCoins[0].Amount).Quo(sdk.NewDecFromInt(reserveCoins[1].Amount)) } logger := k.Logger(ctx) logger.Debug( "withdraw pool coin from the pool", "msg", msg, "pool", pool, "inputs", inputs, "outputs", outputs, "reserveCoins", reserveCoins, "lastReserveRatio", lastReserveRatio, ) return nil } // GetPoolCoinTotalSupply returns total supply of pool coin of the pool in form of math.Int // //nolint:staticcheck func (k Keeper) GetPoolCoinTotalSupply(ctx sdk.Context, pool types.Pool) math.Int { return k.bankKeeper.GetSupply(ctx, pool.PoolCoinDenom).Amount } // IsDepletedPool returns true if the pool is depleted. func (k Keeper) IsDepletedPool(ctx sdk.Context, pool types.Pool) bool { reserveCoins := k.GetReserveCoins(ctx, pool) return !k.GetPoolCoinTotalSupply(ctx, pool).IsPositive() || reserveCoins.AmountOf(pool.ReserveCoinDenoms[0]).IsZero() || reserveCoins.AmountOf(pool.ReserveCoinDenoms[1]).IsZero() } // GetPoolCoinTotal returns total supply of pool coin of the pool in form of sdk.Coin func (k Keeper) GetPoolCoinTotal(ctx sdk.Context, pool types.Pool) sdk.Coin { return sdk.NewCoin(pool.PoolCoinDenom, k.GetPoolCoinTotalSupply(ctx, pool)) } // GetReserveCoins returns reserve coins from the liquidity pool func (k Keeper) GetReserveCoins(ctx sdk.Context, pool types.Pool) (reserveCoins sdk.Coins) { reserveAcc := pool.GetReserveAccount() reserveCoins = sdk.NewCoins() for _, denom := range pool.ReserveCoinDenoms { reserveCoins = append(reserveCoins, k.bankKeeper.GetBalance(ctx, reserveAcc, denom)) } return } // GetPoolMetaData returns metadata of the pool func (k Keeper) GetPoolMetaData(ctx sdk.Context, pool types.Pool) types.PoolMetadata { return types.PoolMetadata{ PoolId: pool.Id, PoolCoinTotalSupply: k.GetPoolCoinTotal(ctx, pool), ReserveCoins: k.GetReserveCoins(ctx, pool), } } // GetPoolRecord returns the liquidity pool record with the given pool information func (k Keeper) GetPoolRecord(ctx sdk.Context, pool types.Pool) (types.PoolRecord, bool) { batch, found := k.GetPoolBatch(ctx, pool.Id) if !found { return types.PoolRecord{}, false } return types.PoolRecord{ Pool: pool, PoolMetadata: k.GetPoolMetaData(ctx, pool), PoolBatch: batch, DepositMsgStates: k.GetAllPoolBatchDepositMsgs(ctx, batch), WithdrawMsgStates: k.GetAllPoolBatchWithdrawMsgStates(ctx, batch), SwapMsgStates: k.GetAllPoolBatchSwapMsgStates(ctx, batch), }, true } // SetPoolRecord stores liquidity pool states func (k Keeper) SetPoolRecord(ctx sdk.Context, record types.PoolRecord) types.PoolRecord { k.SetPoolAtomic(ctx, record.Pool) if record.PoolBatch.BeginHeight > ctx.BlockHeight() { record.PoolBatch.BeginHeight = 0 } k.SetPoolBatch(ctx, record.PoolBatch) k.SetPoolBatchDepositMsgStates(ctx, record.Pool.Id, record.DepositMsgStates) k.SetPoolBatchWithdrawMsgStates(ctx, record.Pool.Id, record.WithdrawMsgStates) k.SetPoolBatchSwapMsgStates(ctx, record.Pool.Id, record.SwapMsgStates) return record } // RefundDeposit refunds deposit amounts to the depositor func (k Keeper) RefundDeposit(ctx sdk.Context, batchMsg types.DepositMsgState, batch types.PoolBatch) error { batchMsg, _ = k.GetPoolBatchDepositMsgState(ctx, batchMsg.Msg.PoolId, batchMsg.MsgIndex) if !batchMsg.Executed || batchMsg.Succeeded { return fmt.Errorf("cannot refund not executed or already succeeded msg") } pool, _ := k.GetPool(ctx, batchMsg.Msg.PoolId) if err := k.ReleaseEscrow(ctx, batchMsg.Msg.GetDepositor(), batchMsg.Msg.DepositCoins); err != nil { return err } // not delete now, set ToBeDeleted true for delete on next block beginblock batchMsg.ToBeDeleted = true k.SetPoolBatchDepositMsgState(ctx, batchMsg.Msg.PoolId, batchMsg) ctx.EventManager().EmitEvent( sdk.NewEvent( types.EventTypeDepositToPool, sdk.NewAttribute(types.AttributeValuePoolId, strconv.FormatUint(pool.Id, 10)), sdk.NewAttribute(types.AttributeValueBatchIndex, strconv.FormatUint(batch.Index, 10)), sdk.NewAttribute(types.AttributeValueMsgIndex, strconv.FormatUint(batchMsg.MsgIndex, 10)), sdk.NewAttribute(types.AttributeValueDepositor, batchMsg.Msg.GetDepositor().String()), sdk.NewAttribute(types.AttributeValueAcceptedCoins, sdk.NewCoins().String()), sdk.NewAttribute(types.AttributeValueRefundedCoins, batchMsg.Msg.DepositCoins.String()), sdk.NewAttribute(types.AttributeValueSuccess, types.Failure), )) return nil } // RefundWithdrawal refunds pool coin of the liquidity pool to the withdrawer func (k Keeper) RefundWithdrawal(ctx sdk.Context, batchMsg types.WithdrawMsgState, batch types.PoolBatch) error { batchMsg, _ = k.GetPoolBatchWithdrawMsgState(ctx, batchMsg.Msg.PoolId, batchMsg.MsgIndex) if !batchMsg.Executed || batchMsg.Succeeded { return fmt.Errorf("cannot refund not executed or already succeeded msg") } pool, _ := k.GetPool(ctx, batchMsg.Msg.PoolId) if err := k.ReleaseEscrow(ctx, batchMsg.Msg.GetWithdrawer(), sdk.NewCoins(batchMsg.Msg.PoolCoin)); err != nil { return err } ctx.EventManager().EmitEvent( sdk.NewEvent( types.EventTypeWithdrawFromPool, sdk.NewAttribute(types.AttributeValuePoolId, strconv.FormatUint(pool.Id, 10)), sdk.NewAttribute(types.AttributeValueBatchIndex, strconv.FormatUint(batch.Index, 10)), sdk.NewAttribute(types.AttributeValueMsgIndex, strconv.FormatUint(batchMsg.MsgIndex, 10)), sdk.NewAttribute(types.AttributeValueWithdrawer, batchMsg.Msg.GetWithdrawer().String()), sdk.NewAttribute(types.AttributeValuePoolCoinDenom, batchMsg.Msg.PoolCoin.Denom), sdk.NewAttribute(types.AttributeValuePoolCoinAmount, batchMsg.Msg.PoolCoin.Amount.String()), sdk.NewAttribute(types.AttributeValueSuccess, types.Failure), )) // not delete now, set ToBeDeleted true for delete on next block beginblock batchMsg.ToBeDeleted = true k.SetPoolBatchWithdrawMsgState(ctx, batchMsg.Msg.PoolId, batchMsg) return nil } // TransactAndRefundSwapLiquidityPool transacts, refunds, expires, sends coins with escrow, update state by TransactAndRefundSwapLiquidityPool func (k Keeper) TransactAndRefundSwapLiquidityPool(ctx sdk.Context, swapMsgStates []*types.SwapMsgState, matchResultMap map[uint64]types.MatchResult, pool types.Pool, batchResult types.BatchResult, ) error { var inputs []banktypes.Input var outputs []banktypes.Output batchEscrowAcc := k.accountKeeper.GetModuleAddress(types.ModuleName) poolReserveAcc := pool.GetReserveAccount() batch, found := k.GetPoolBatch(ctx, pool.Id) if !found { return types.ErrPoolBatchNotExists } sendCoin := func(from, to sdk.AccAddress, coin sdk.Coin) { coins := sdk.NewCoins(coin) if !coins.Empty() && coins.IsValid() { inputs = append(inputs, banktypes.NewInput(from, coins)) outputs = append(outputs, banktypes.NewOutput(to, coins)) } } for _, sms := range swapMsgStates { if pool.Id != sms.Msg.PoolId { return fmt.Errorf("broken msg pool consistency") } if !sms.Executed && sms.Succeeded { return fmt.Errorf("can't refund not executed with succeed msg") } if sms.RemainingOfferCoin.IsNegative() { return fmt.Errorf("negative RemainingOfferCoin") } else if sms.RemainingOfferCoin.IsPositive() && ((!sms.ToBeDeleted && sms.OrderExpiryHeight <= ctx.BlockHeight()) || (sms.ToBeDeleted && sms.OrderExpiryHeight != ctx.BlockHeight())) { return fmt.Errorf("consistency of OrderExpiryHeight and ToBeDeleted flag is broken") } if match, ok := matchResultMap[sms.MsgIndex]; ok { transactedAmt := match.TransactedCoinAmt.TruncateInt() receiveAmt := match.ExchangedDemandCoinAmt.Sub(match.ExchangedCoinFeeAmt).TruncateInt() offerCoinFeeAmt := match.OfferCoinFeeAmt.TruncateInt() sendCoin(batchEscrowAcc, poolReserveAcc, sdk.NewCoin(sms.Msg.OfferCoin.Denom, transactedAmt)) sendCoin(poolReserveAcc, sms.Msg.GetSwapRequester(), sdk.NewCoin(sms.Msg.DemandCoinDenom, receiveAmt)) sendCoin(batchEscrowAcc, poolReserveAcc, sdk.NewCoin(sms.Msg.OfferCoin.Denom, offerCoinFeeAmt)) if sms.RemainingOfferCoin.Add(sms.ReservedOfferCoinFee).IsPositive() && sms.OrderExpiryHeight == ctx.BlockHeight() { sendCoin(batchEscrowAcc, sms.Msg.GetSwapRequester(), sms.RemainingOfferCoin.Add(sms.ReservedOfferCoinFee)) } sms.Succeeded = true if sms.RemainingOfferCoin.IsZero() { sms.ToBeDeleted = true } ctx.EventManager().EmitEvent( sdk.NewEvent( types.EventTypeSwapTransacted, sdk.NewAttribute(types.AttributeValuePoolId, strconv.FormatUint(pool.Id, 10)), sdk.NewAttribute(types.AttributeValueBatchIndex, strconv.FormatUint(batch.Index, 10)), sdk.NewAttribute(types.AttributeValueMsgIndex, strconv.FormatUint(sms.MsgIndex, 10)), sdk.NewAttribute(types.AttributeValueSwapRequester, sms.Msg.GetSwapRequester().String()), sdk.NewAttribute(types.AttributeValueSwapTypeId, strconv.FormatUint(uint64(sms.Msg.SwapTypeId), 10)), sdk.NewAttribute(types.AttributeValueOfferCoinDenom, sms.Msg.OfferCoin.Denom), sdk.NewAttribute(types.AttributeValueOfferCoinAmount, sms.Msg.OfferCoin.Amount.String()), sdk.NewAttribute(types.AttributeValueDemandCoinDenom, sms.Msg.DemandCoinDenom), sdk.NewAttribute(types.AttributeValueOrderPrice, sms.Msg.OrderPrice.String()), sdk.NewAttribute(types.AttributeValueSwapPrice, batchResult.SwapPrice.String()), sdk.NewAttribute(types.AttributeValueTransactedCoinAmount, transactedAmt.String()), sdk.NewAttribute(types.AttributeValueRemainingOfferCoinAmount, sms.RemainingOfferCoin.Amount.String()), sdk.NewAttribute(types.AttributeValueExchangedOfferCoinAmount, sms.ExchangedOfferCoin.Amount.String()), sdk.NewAttribute(types.AttributeValueExchangedDemandCoinAmount, receiveAmt.String()), sdk.NewAttribute(types.AttributeValueOfferCoinFeeAmount, offerCoinFeeAmt.String()), sdk.NewAttribute(types.AttributeValueExchangedCoinFeeAmount, match.ExchangedCoinFeeAmt.String()), sdk.NewAttribute(types.AttributeValueReservedOfferCoinFeeAmount, sms.ReservedOfferCoinFee.Amount.String()), sdk.NewAttribute(types.AttributeValueOrderExpiryHeight, strconv.FormatInt(sms.OrderExpiryHeight, 10)), sdk.NewAttribute(types.AttributeValueSuccess, types.Success), )) } else { // Not matched, remaining sendCoin(batchEscrowAcc, sms.Msg.GetSwapRequester(), sms.RemainingOfferCoin.Add(sms.ReservedOfferCoinFee)) sms.Succeeded = false sms.ToBeDeleted = true ctx.EventManager().EmitEvent( sdk.NewEvent( types.EventTypeSwapTransacted, sdk.NewAttribute(types.AttributeValuePoolId, strconv.FormatUint(pool.Id, 10)), sdk.NewAttribute(types.AttributeValueBatchIndex, strconv.FormatUint(batch.Index, 10)), sdk.NewAttribute(types.AttributeValueMsgIndex, strconv.FormatUint(sms.MsgIndex, 10)), sdk.NewAttribute(types.AttributeValueSwapRequester, sms.Msg.GetSwapRequester().String()), sdk.NewAttribute(types.AttributeValueSwapTypeId, strconv.FormatUint(uint64(sms.Msg.SwapTypeId), 10)), sdk.NewAttribute(types.AttributeValueOfferCoinDenom, sms.Msg.OfferCoin.Denom), sdk.NewAttribute(types.AttributeValueOfferCoinAmount, sms.Msg.OfferCoin.Amount.String()), sdk.NewAttribute(types.AttributeValueDemandCoinDenom, sms.Msg.DemandCoinDenom), sdk.NewAttribute(types.AttributeValueOrderPrice, sms.Msg.OrderPrice.String()), sdk.NewAttribute(types.AttributeValueSwapPrice, batchResult.SwapPrice.String()), sdk.NewAttribute(types.AttributeValueRemainingOfferCoinAmount, sms.RemainingOfferCoin.Amount.String()), sdk.NewAttribute(types.AttributeValueExchangedOfferCoinAmount, sms.ExchangedOfferCoin.Amount.String()), sdk.NewAttribute(types.AttributeValueReservedOfferCoinFeeAmount, sms.ReservedOfferCoinFee.Amount.String()), sdk.NewAttribute(types.AttributeValueOrderExpiryHeight, strconv.FormatInt(sms.OrderExpiryHeight, 10)), sdk.NewAttribute(types.AttributeValueSuccess, types.Failure), )) } } if err := k.bankKeeper.InputOutputCoins(ctx, inputs, outputs); err != nil { return err } k.SetPoolBatchSwapMsgStatesByPointer(ctx, pool.Id, swapMsgStates) return nil } func (k Keeper) RefundSwaps(ctx sdk.Context, pool types.Pool, swapMsgStates []*types.SwapMsgState) error { var inputs []banktypes.Input var outputs []banktypes.Output sendCoin := func(from, to sdk.AccAddress, coin sdk.Coin) { coins := sdk.NewCoins(coin) if !coins.Empty() && coins.IsValid() { inputs = append(inputs, banktypes.NewInput(from, coins)) outputs = append(outputs, banktypes.NewOutput(to, coins)) } } for _, sms := range swapMsgStates { if sms.OrderExpiryHeight == ctx.BlockHeight() { sendCoin(k.accountKeeper.GetModuleAddress(types.ModuleName), sms.Msg.GetSwapRequester(), sms.RemainingOfferCoin.Add(sms.ReservedOfferCoinFee)) sms.Succeeded = false sms.ToBeDeleted = true } } if err := k.bankKeeper.InputOutputCoins(ctx, inputs, outputs); err != nil { return err } k.SetPoolBatchSwapMsgStatesByPointer(ctx, pool.Id, swapMsgStates) return nil } // ValidateMsgDepositWithinBatch validates MsgDepositWithinBatch func (k Keeper) ValidateMsgDepositWithinBatch(ctx sdk.Context, msg types.MsgDepositWithinBatch) error { pool, found := k.GetPool(ctx, msg.PoolId) if !found { return types.ErrPoolNotExists } if msg.DepositCoins.Len() != len(pool.ReserveCoinDenoms) { return types.ErrNumOfReserveCoin } params := k.GetParams(ctx) reserveCoins := k.GetReserveCoins(ctx, pool) if err := types.ValidateReserveCoinLimit(params.MaxReserveCoinAmount, reserveCoins.Add(msg.DepositCoins...)); err != nil { return err } denomA, denomB := types.AlphabeticalDenomPair(msg.DepositCoins[0].Denom, msg.DepositCoins[1].Denom) if denomA != pool.ReserveCoinDenoms[0] || denomB != pool.ReserveCoinDenoms[1] { return types.ErrNotMatchedReserveCoin } return nil } // ValidateMsgWithdrawWithinBatch validates MsgWithdrawWithinBatch func (k Keeper) ValidateMsgWithdrawWithinBatch(ctx sdk.Context, msg types.MsgWithdrawWithinBatch) error { pool, found := k.GetPool(ctx, msg.PoolId) if !found { return types.ErrPoolNotExists } if msg.PoolCoin.Denom != pool.PoolCoinDenom { return types.ErrBadPoolCoinDenom } poolCoinTotalSupply := k.GetPoolCoinTotalSupply(ctx, pool) if k.IsDepletedPool(ctx, pool) { return types.ErrDepletedPool } if msg.PoolCoin.Amount.GT(poolCoinTotalSupply) { return types.ErrBadPoolCoinAmount } return nil } // ValidateMsgSwapWithinBatch validates MsgSwapWithinBatch. func (k Keeper) ValidateMsgSwapWithinBatch(ctx sdk.Context, msg types.MsgSwapWithinBatch, pool types.Pool) error { denomA, denomB := types.AlphabeticalDenomPair(msg.OfferCoin.Denom, msg.DemandCoinDenom) if denomA != pool.ReserveCoinDenoms[0] || denomB != pool.ReserveCoinDenoms[1] { return types.ErrNotMatchedReserveCoin } params := k.GetParams(ctx) // can not exceed max order ratio of reserve coins that can be ordered at a order reserveCoinAmt := k.GetReserveCoins(ctx, pool).AmountOf(msg.OfferCoin.Denom) // Decimal Error, Multiply the Int coin amount by the Decimal Rate and erase the decimal point to order a lower value maximumOrderableAmt := reserveCoinAmt.ToLegacyDec().MulTruncate(params.MaxOrderAmountRatio).TruncateInt() if msg.OfferCoin.Amount.GT(maximumOrderableAmt) { return types.ErrExceededMaxOrderable } if msg.OfferCoinFee.Denom != msg.OfferCoin.Denom { return types.ErrBadOfferCoinFee } if err := types.CheckOverflowWithDec(msg.OfferCoin.Amount.ToLegacyDec(), msg.OrderPrice); err != nil { return err } if !msg.OfferCoinFee.Equal(types.GetOfferCoinFee(msg.OfferCoin, params.SwapFeeRate)) { return types.ErrBadOfferCoinFee } return nil } // ValidatePool validates logic for liquidity pool after set or before export func (k Keeper) ValidatePool(ctx sdk.Context, pool *types.Pool) error { params := k.GetParams(ctx) var poolType types.PoolType // check poolType exist, get poolType from param if len(params.PoolTypes) >= int(pool.TypeId) { poolType = params.PoolTypes[pool.TypeId-1] if poolType.Id != pool.TypeId { return types.ErrPoolTypeNotExists } } else { return types.ErrPoolTypeNotExists } if poolType.MaxReserveCoinNum > types.MaxReserveCoinNum || types.MinReserveCoinNum > poolType.MinReserveCoinNum { return types.ErrNumOfReserveCoin } reserveCoins := k.GetReserveCoins(ctx, *pool) if uint32(reserveCoins.Len()) > poolType.MaxReserveCoinNum || poolType.MinReserveCoinNum > uint32(reserveCoins.Len()) { return types.ErrNumOfReserveCoin } if len(pool.ReserveCoinDenoms) != reserveCoins.Len() { return types.ErrNumOfReserveCoin } for i, denom := range pool.ReserveCoinDenoms { if denom != reserveCoins[i].Denom { return types.ErrInvalidDenom } } denomA, denomB := types.AlphabeticalDenomPair(pool.ReserveCoinDenoms[0], pool.ReserveCoinDenoms[1]) if denomA != pool.ReserveCoinDenoms[0] || denomB != pool.ReserveCoinDenoms[1] { return types.ErrBadOrderingReserveCoin } poolName := types.PoolName(pool.ReserveCoinDenoms, pool.TypeId) poolCoin := k.GetPoolCoinTotal(ctx, *pool) if poolCoin.Denom != types.GetPoolCoinDenom(poolName) { return types.ErrBadPoolCoinDenom } _, found := k.GetPoolBatch(ctx, pool.Id) if !found { return types.ErrPoolBatchNotExists } return nil } // ValidatePoolMetadata validates logic for liquidity pool metadata func (k Keeper) ValidatePoolMetadata(ctx sdk.Context, pool *types.Pool, metaData *types.PoolMetadata) error { if err := metaData.ReserveCoins.Validate(); err != nil { return err } if !metaData.ReserveCoins.IsEqual(k.GetReserveCoins(ctx, *pool)) { return types.ErrNumOfReserveCoin } if !metaData.PoolCoinTotalSupply.IsEqual(sdk.NewCoin(pool.PoolCoinDenom, k.GetPoolCoinTotalSupply(ctx, *pool))) { return types.ErrBadPoolCoinAmount } return nil } // ValidatePoolRecord validates liquidity pool record after init or after export func (k Keeper) ValidatePoolRecord(ctx sdk.Context, record types.PoolRecord) error { if err := k.ValidatePool(ctx, &record.Pool); err != nil { return err } if err := k.ValidatePoolMetadata(ctx, &record.Pool, &record.PoolMetadata); err != nil { return err } if len(record.DepositMsgStates) != 0 && record.PoolBatch.DepositMsgIndex != record.DepositMsgStates[len(record.DepositMsgStates)-1].MsgIndex+1 { return types.ErrBadBatchMsgIndex } if len(record.WithdrawMsgStates) != 0 && record.PoolBatch.WithdrawMsgIndex != record.WithdrawMsgStates[len(record.WithdrawMsgStates)-1].MsgIndex+1 { return types.ErrBadBatchMsgIndex } if len(record.SwapMsgStates) != 0 && record.PoolBatch.SwapMsgIndex != record.SwapMsgStates[len(record.SwapMsgStates)-1].MsgIndex+1 { return types.ErrBadBatchMsgIndex } return nil } // IsPoolCoinDenom returns true if the denom is a valid pool coin denom. func (k Keeper) IsPoolCoinDenom(ctx sdk.Context, denom string) bool { reserveAcc, err := types.GetReserveAcc(denom, false) if err != nil { return false } _, found := k.GetPoolByReserveAccIndex(ctx, reserveAcc) return found } ================================================ FILE: x/liquidity/keeper/migrator.go ================================================ package keeper import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/liquidity/exported" v3 "github.com/cybercongress/go-cyber/v7/x/liquidity/migrations/v3" ) // Migrator is a struct for handling in-place store migrations. type Migrator struct { keeper Keeper legacySubspace exported.Subspace } // NewMigrator returns a new Migrator. func NewMigrator(keeper Keeper, ss exported.Subspace) Migrator { return Migrator{ keeper: keeper, legacySubspace: ss, } } // Migrate2to3 migrates from version 2 to 3. func (m Migrator) Migrate2to3(ctx sdk.Context) error { return v3.Migrate(ctx, ctx.KVStore(m.keeper.storeKey), m.legacySubspace, m.keeper.cdc) } ================================================ FILE: x/liquidity/keeper/msg_server.go ================================================ package keeper // DONTCOVER // Although written in msg_server_test.go, it is approached at the keeper level rather than at the msgServer level // so is not included in the coverage. import ( "context" "fmt" "strconv" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/liquidity/types" ) type msgServer struct { Keeper } // NewMsgServerImpl returns an implementation of the distribution MsgServer interface // for the provided Keeper. func NewMsgServerImpl(keeper Keeper) types.MsgServer { return &msgServer{Keeper: keeper} } var _ types.MsgServer = msgServer{} // Message server, handler for CreatePool msg func (k msgServer) CreatePool(goCtx context.Context, msg *types.MsgCreatePool) (*types.MsgCreatePoolResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) if k.GetCircuitBreakerEnabled(ctx) { return nil, types.ErrCircuitBreakerEnabled } pool, err := k.Keeper.CreatePool(ctx, msg) if err != nil { return nil, err } ctx.EventManager().EmitEvents(sdk.Events{ sdk.NewEvent( sdk.EventTypeMessage, sdk.NewAttribute(sdk.AttributeKeyModule, types.AttributeValueCategory), ), sdk.NewEvent( types.EventTypeCreatePool, sdk.NewAttribute(types.AttributeValuePoolId, strconv.FormatUint(pool.Id, 10)), sdk.NewAttribute(types.AttributeValuePoolTypeId, fmt.Sprintf("%d", msg.PoolTypeId)), sdk.NewAttribute(types.AttributeValuePoolName, pool.Name()), sdk.NewAttribute(types.AttributeValueReserveAccount, pool.ReserveAccountAddress), sdk.NewAttribute(types.AttributeValueDepositCoins, msg.DepositCoins.String()), sdk.NewAttribute(types.AttributeValuePoolCoinDenom, pool.PoolCoinDenom), ), }) return &types.MsgCreatePoolResponse{}, nil } // Message server, handler for MsgDepositWithinBatch func (k msgServer) DepositWithinBatch(goCtx context.Context, msg *types.MsgDepositWithinBatch) (*types.MsgDepositWithinBatchResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) if k.GetCircuitBreakerEnabled(ctx) { return nil, types.ErrCircuitBreakerEnabled } poolBatch, found := k.GetPoolBatch(ctx, msg.PoolId) if !found { return nil, types.ErrPoolBatchNotExists } batchMsg, err := k.Keeper.DepositWithinBatch(ctx, msg) if err != nil { return nil, err } ctx.EventManager().EmitEvents(sdk.Events{ sdk.NewEvent( sdk.EventTypeMessage, sdk.NewAttribute(sdk.AttributeKeyModule, types.AttributeValueCategory), ), sdk.NewEvent( types.EventTypeDepositWithinBatch, sdk.NewAttribute(types.AttributeValuePoolId, strconv.FormatUint(batchMsg.Msg.PoolId, 10)), sdk.NewAttribute(types.AttributeValueBatchIndex, strconv.FormatUint(poolBatch.Index, 10)), sdk.NewAttribute(types.AttributeValueMsgIndex, strconv.FormatUint(batchMsg.MsgIndex, 10)), sdk.NewAttribute(types.AttributeValueDepositCoins, batchMsg.Msg.DepositCoins.String()), ), }) return &types.MsgDepositWithinBatchResponse{}, nil } // Message server, handler for MsgWithdrawWithinBatch func (k msgServer) WithdrawWithinBatch(goCtx context.Context, msg *types.MsgWithdrawWithinBatch) (*types.MsgWithdrawWithinBatchResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) poolBatch, found := k.GetPoolBatch(ctx, msg.PoolId) if !found { return nil, types.ErrPoolBatchNotExists } batchMsg, err := k.Keeper.WithdrawWithinBatch(ctx, msg) if err != nil { return nil, err } ctx.EventManager().EmitEvents(sdk.Events{ sdk.NewEvent( sdk.EventTypeMessage, sdk.NewAttribute(sdk.AttributeKeyModule, types.AttributeValueCategory), ), sdk.NewEvent( types.EventTypeWithdrawWithinBatch, sdk.NewAttribute(types.AttributeValuePoolId, strconv.FormatUint(batchMsg.Msg.PoolId, 10)), sdk.NewAttribute(types.AttributeValueBatchIndex, strconv.FormatUint(poolBatch.Index, 10)), sdk.NewAttribute(types.AttributeValueMsgIndex, strconv.FormatUint(batchMsg.MsgIndex, 10)), sdk.NewAttribute(types.AttributeValuePoolCoinDenom, batchMsg.Msg.PoolCoin.Denom), sdk.NewAttribute(types.AttributeValuePoolCoinAmount, batchMsg.Msg.PoolCoin.Amount.String()), ), }) return &types.MsgWithdrawWithinBatchResponse{}, nil } // Message server, handler for MsgSwapWithinBatch func (k msgServer) Swap(goCtx context.Context, msg *types.MsgSwapWithinBatch) (*types.MsgSwapWithinBatchResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) if k.GetCircuitBreakerEnabled(ctx) { return nil, types.ErrCircuitBreakerEnabled } poolBatch, found := k.GetPoolBatch(ctx, msg.PoolId) if !found { return nil, types.ErrPoolBatchNotExists } batchMsg, err := k.Keeper.SwapWithinBatch(ctx, msg, types.CancelOrderLifeSpan) if err != nil { return nil, err } ctx.EventManager().EmitEvents(sdk.Events{ sdk.NewEvent( sdk.EventTypeMessage, sdk.NewAttribute(sdk.AttributeKeyModule, types.AttributeValueCategory), ), sdk.NewEvent( types.EventTypeSwapWithinBatch, sdk.NewAttribute(types.AttributeValuePoolId, strconv.FormatUint(batchMsg.Msg.PoolId, 10)), sdk.NewAttribute(types.AttributeValueBatchIndex, strconv.FormatUint(poolBatch.Index, 10)), sdk.NewAttribute(types.AttributeValueMsgIndex, strconv.FormatUint(batchMsg.MsgIndex, 10)), sdk.NewAttribute(types.AttributeValueSwapTypeId, strconv.FormatUint(uint64(batchMsg.Msg.SwapTypeId), 10)), sdk.NewAttribute(types.AttributeValueOfferCoinDenom, batchMsg.Msg.OfferCoin.Denom), sdk.NewAttribute(types.AttributeValueOfferCoinAmount, batchMsg.Msg.OfferCoin.Amount.String()), sdk.NewAttribute(types.AttributeValueOfferCoinFeeAmount, batchMsg.Msg.OfferCoinFee.Amount.String()), sdk.NewAttribute(types.AttributeValueDemandCoinDenom, batchMsg.Msg.DemandCoinDenom), sdk.NewAttribute(types.AttributeValueOrderPrice, batchMsg.Msg.OrderPrice.String()), ), }) return &types.MsgSwapWithinBatchResponse{}, nil } ================================================ FILE: x/liquidity/keeper/store.go ================================================ package keeper import ( sdk "github.com/cosmos/cosmos-sdk/types" gogotypes "github.com/cosmos/gogoproto/types" "github.com/cybercongress/go-cyber/v7/x/liquidity/types" ) // GetPool reads from kvstore and returns a specific pool func (k Keeper) GetPool(ctx sdk.Context, poolID uint64) (pool types.Pool, found bool) { store := ctx.KVStore(k.storeKey) key := types.GetPoolKey(poolID) value := store.Get(key) if value == nil { return pool, false } pool = types.MustUnmarshalPool(k.cdc, value) return pool, true } // SetPool sets to kvstore a specific pool func (k Keeper) SetPool(ctx sdk.Context, pool types.Pool) { store := ctx.KVStore(k.storeKey) b := types.MustMarshalPool(k.cdc, pool) store.Set(types.GetPoolKey(pool.Id), b) } // delete from kvstore a specific liquidityPool func (k Keeper) DeletePool(ctx sdk.Context, pool types.Pool) { store := ctx.KVStore(k.storeKey) Key := types.GetPoolKey(pool.Id) store.Delete(Key) } // IterateAllPools iterate through all of the liquidityPools func (k Keeper) IterateAllPools(ctx sdk.Context, cb func(pool types.Pool) (stop bool)) { store := ctx.KVStore(k.storeKey) iterator := sdk.KVStorePrefixIterator(store, types.PoolKeyPrefix) defer iterator.Close() for ; iterator.Valid(); iterator.Next() { pool := types.MustUnmarshalPool(k.cdc, iterator.Value()) if cb(pool) { break } } } // GetAllPools returns all liquidityPools used during genesis dump func (k Keeper) GetAllPools(ctx sdk.Context) (pools []types.Pool) { k.IterateAllPools(ctx, func(liquidityPool types.Pool) bool { pools = append(pools, liquidityPool) return false }) return pools } // GetNextPoolIDWithUpdate returns and increments the global Pool ID counter. // If the global account number is not set, it initializes it with value 0. func (k Keeper) GetNextPoolIDWithUpdate(ctx sdk.Context) uint64 { store := ctx.KVStore(k.storeKey) poolID := k.GetNextPoolID(ctx) bz := k.cdc.MustMarshal(&gogotypes.UInt64Value{Value: poolID + 1}) store.Set(types.GlobalLiquidityPoolIDKey, bz) return poolID } // GetNextPoolID returns next pool id for new pool, using index of latest pool id func (k Keeper) GetNextPoolID(ctx sdk.Context) uint64 { var poolID uint64 store := ctx.KVStore(k.storeKey) bz := store.Get(types.GlobalLiquidityPoolIDKey) if bz == nil { // initialize the LiquidityPoolID poolID = 1 } else { val := gogotypes.UInt64Value{} err := k.cdc.Unmarshal(bz, &val) if err != nil { panic(err) } poolID = val.GetValue() } return poolID } // GetPoolByReserveAccIndex reads from kvstore and return a specific liquidityPool indexed by given reserve account func (k Keeper) GetPoolByReserveAccIndex(ctx sdk.Context, reserveAcc sdk.AccAddress) (pool types.Pool, found bool) { store := ctx.KVStore(k.storeKey) key := types.GetPoolByReserveAccIndexKey(reserveAcc) value := store.Get(key) if value == nil { return pool, false } val := gogotypes.UInt64Value{} err := k.cdc.Unmarshal(value, &val) if err != nil { return pool, false } poolID := val.GetValue() return k.GetPool(ctx, poolID) } // SetPoolByReserveAccIndex sets Index by ReserveAcc for pool duplication check func (k Keeper) SetPoolByReserveAccIndex(ctx sdk.Context, pool types.Pool) { store := ctx.KVStore(k.storeKey) b := k.cdc.MustMarshal(&gogotypes.UInt64Value{Value: pool.Id}) store.Set(types.GetPoolByReserveAccIndexKey(pool.GetReserveAccount()), b) } // SetPoolAtomic sets pool with set global pool id index +1 and index by reserveAcc func (k Keeper) SetPoolAtomic(ctx sdk.Context, pool types.Pool) types.Pool { pool.Id = k.GetNextPoolIDWithUpdate(ctx) k.SetPool(ctx, pool) k.SetPoolByReserveAccIndex(ctx, pool) return pool } // GetPoolBatch returns a specific pool batch func (k Keeper) GetPoolBatch(ctx sdk.Context, poolID uint64) (poolBatch types.PoolBatch, found bool) { store := ctx.KVStore(k.storeKey) key := types.GetPoolBatchKey(poolID) value := store.Get(key) if value == nil { return poolBatch, false } poolBatch = types.MustUnmarshalPoolBatch(k.cdc, value) return poolBatch, true } // GetAllPoolBatches returns all batches of the all existed liquidity pools func (k Keeper) GetAllPoolBatches(ctx sdk.Context) (poolBatches []types.PoolBatch) { k.IterateAllPoolBatches(ctx, func(poolBatch types.PoolBatch) bool { poolBatches = append(poolBatches, poolBatch) return false }) return poolBatches } // IterateAllPoolBatches iterate through all of the pool batches func (k Keeper) IterateAllPoolBatches(ctx sdk.Context, cb func(poolBatch types.PoolBatch) (stop bool)) { store := ctx.KVStore(k.storeKey) iterator := sdk.KVStorePrefixIterator(store, types.PoolBatchKeyPrefix) defer iterator.Close() for ; iterator.Valid(); iterator.Next() { poolBatch := types.MustUnmarshalPoolBatch(k.cdc, iterator.Value()) if cb(poolBatch) { break } } } // DeletePoolBatch deletes batch of the pool, it used for test case func (k Keeper) DeletePoolBatch(ctx sdk.Context, poolBatch types.PoolBatch) { store := ctx.KVStore(k.storeKey) batchKey := types.GetPoolBatchKey(poolBatch.PoolId) store.Delete(batchKey) } // SetPoolBatch sets batch of the pool, with current state func (k Keeper) SetPoolBatch(ctx sdk.Context, poolBatch types.PoolBatch) { store := ctx.KVStore(k.storeKey) b := types.MustMarshalPoolBatch(k.cdc, poolBatch) store.Set(types.GetPoolBatchKey(poolBatch.PoolId), b) } // GetPoolBatchDepositMsgState returns a specific DepositMsgState func (k Keeper) GetPoolBatchDepositMsgState(ctx sdk.Context, poolID, msgIndex uint64) (state types.DepositMsgState, found bool) { store := ctx.KVStore(k.storeKey) key := types.GetPoolBatchDepositMsgStateIndexKey(poolID, msgIndex) value := store.Get(key) if value == nil { return state, false } state = types.MustUnmarshalDepositMsgState(k.cdc, value) return state, true } // SetPoolBatchDepositMsgState sets deposit msg state of the pool batch, with current state func (k Keeper) SetPoolBatchDepositMsgState(ctx sdk.Context, poolID uint64, state types.DepositMsgState) { store := ctx.KVStore(k.storeKey) b := types.MustMarshalDepositMsgState(k.cdc, state) store.Set(types.GetPoolBatchDepositMsgStateIndexKey(poolID, state.MsgIndex), b) } // SetPoolBatchDepositMsgStatesByPointer sets deposit batch msgs of the pool batch, with current state using pointers func (k Keeper) SetPoolBatchDepositMsgStatesByPointer(ctx sdk.Context, poolID uint64, states []*types.DepositMsgState) { store := ctx.KVStore(k.storeKey) for _, state := range states { if poolID != state.Msg.PoolId { continue } b := types.MustMarshalDepositMsgState(k.cdc, *state) store.Set(types.GetPoolBatchDepositMsgStateIndexKey(poolID, state.MsgIndex), b) } } // SetPoolBatchDepositMsgStates sets deposit batch msgs of the pool batch, with current state func (k Keeper) SetPoolBatchDepositMsgStates(ctx sdk.Context, poolID uint64, states []types.DepositMsgState) { store := ctx.KVStore(k.storeKey) for _, state := range states { if poolID != state.Msg.PoolId { continue } b := types.MustMarshalDepositMsgState(k.cdc, state) store.Set(types.GetPoolBatchDepositMsgStateIndexKey(poolID, state.MsgIndex), b) } } // IterateAllPoolBatchDepositMsgStates iterate through all of the DepositMsgStates in the batch func (k Keeper) IterateAllPoolBatchDepositMsgStates(ctx sdk.Context, poolBatch types.PoolBatch, cb func(state types.DepositMsgState) (stop bool)) { store := ctx.KVStore(k.storeKey) prefix := types.GetPoolBatchDepositMsgStatesPrefix(poolBatch.PoolId) iterator := sdk.KVStorePrefixIterator(store, prefix) defer iterator.Close() for ; iterator.Valid(); iterator.Next() { state := types.MustUnmarshalDepositMsgState(k.cdc, iterator.Value()) if cb(state) { break } } } // IterateAllDepositMsgStates iterate through all of the DepositMsgState of all batches func (k Keeper) IterateAllDepositMsgStates(ctx sdk.Context, cb func(state types.DepositMsgState) (stop bool)) { store := ctx.KVStore(k.storeKey) prefix := types.PoolBatchDepositMsgStateIndexKeyPrefix iterator := sdk.KVStorePrefixIterator(store, prefix) defer iterator.Close() for ; iterator.Valid(); iterator.Next() { state := types.MustUnmarshalDepositMsgState(k.cdc, iterator.Value()) if cb(state) { break } } } // GetAllDepositMsgStates returns all BatchDepositMsgs for all batches. func (k Keeper) GetAllDepositMsgStates(ctx sdk.Context) (states []types.DepositMsgState) { k.IterateAllDepositMsgStates(ctx, func(state types.DepositMsgState) bool { states = append(states, state) return false }) return states } // GetAllPoolBatchDepositMsgs returns all BatchDepositMsgs indexed by the pool batch func (k Keeper) GetAllPoolBatchDepositMsgs(ctx sdk.Context, poolBatch types.PoolBatch) (states []types.DepositMsgState) { k.IterateAllPoolBatchDepositMsgStates(ctx, poolBatch, func(state types.DepositMsgState) bool { states = append(states, state) return false }) return states } // GetAllPoolBatchDepositMsgStatesNotToBeDeleted returns all Not toDelete BatchDepositMsgs indexed by the liquidityPoolBatch func (k Keeper) GetAllPoolBatchDepositMsgStatesNotToBeDeleted(ctx sdk.Context, poolBatch types.PoolBatch) (states []types.DepositMsgState) { k.IterateAllPoolBatchDepositMsgStates(ctx, poolBatch, func(state types.DepositMsgState) bool { if !state.ToBeDeleted { states = append(states, state) } return false }) return states } // GetAllRemainingPoolBatchDepositMsgStates returns all remaining DepositMsgStates after endblock, // which are executed but not to be deleted func (k Keeper) GetAllRemainingPoolBatchDepositMsgStates(ctx sdk.Context, poolBatch types.PoolBatch) (states []*types.DepositMsgState) { k.IterateAllPoolBatchDepositMsgStates(ctx, poolBatch, func(state types.DepositMsgState) bool { if state.Executed && !state.ToBeDeleted { states = append(states, &state) } return false }) return states } // delete deposit batch msgs of the liquidity pool batch which has state ToBeDeleted func (k Keeper) DeleteAllReadyPoolBatchDepositMsgStates(ctx sdk.Context, poolBatch types.PoolBatch) { store := ctx.KVStore(k.storeKey) iterator := sdk.KVStorePrefixIterator(store, types.GetPoolBatchDepositMsgStatesPrefix(poolBatch.PoolId)) defer iterator.Close() for ; iterator.Valid(); iterator.Next() { state := types.MustUnmarshalDepositMsgState(k.cdc, iterator.Value()) if state.ToBeDeleted { store.Delete(iterator.Key()) } } } // return a specific liquidityPoolBatchWithdrawMsg func (k Keeper) GetPoolBatchWithdrawMsgState(ctx sdk.Context, poolID, msgIndex uint64) (state types.WithdrawMsgState, found bool) { store := ctx.KVStore(k.storeKey) key := types.GetPoolBatchWithdrawMsgStateIndexKey(poolID, msgIndex) value := store.Get(key) if value == nil { return state, false } state = types.MustUnmarshalWithdrawMsgState(k.cdc, value) return state, true } // set withdraw batch msg of the liquidity pool batch, with current state func (k Keeper) SetPoolBatchWithdrawMsgState(ctx sdk.Context, poolID uint64, state types.WithdrawMsgState) { store := ctx.KVStore(k.storeKey) b := types.MustMarshalWithdrawMsgState(k.cdc, state) store.Set(types.GetPoolBatchWithdrawMsgStateIndexKey(poolID, state.MsgIndex), b) } // set withdraw batch msgs of the liquidity pool batch, with current state using pointers func (k Keeper) SetPoolBatchWithdrawMsgStatesByPointer(ctx sdk.Context, poolID uint64, states []*types.WithdrawMsgState) { store := ctx.KVStore(k.storeKey) for _, state := range states { if poolID != state.Msg.PoolId { continue } b := types.MustMarshalWithdrawMsgState(k.cdc, *state) store.Set(types.GetPoolBatchWithdrawMsgStateIndexKey(poolID, state.MsgIndex), b) } } // set withdraw batch msgs of the pool batch, with current state func (k Keeper) SetPoolBatchWithdrawMsgStates(ctx sdk.Context, poolID uint64, states []types.WithdrawMsgState) { store := ctx.KVStore(k.storeKey) for _, state := range states { if poolID != state.Msg.PoolId { continue } b := types.MustMarshalWithdrawMsgState(k.cdc, state) store.Set(types.GetPoolBatchWithdrawMsgStateIndexKey(poolID, state.MsgIndex), b) } } // IterateAllPoolBatchWithdrawMsgStates iterate through all of the LiquidityPoolBatchWithdrawMsgs func (k Keeper) IterateAllPoolBatchWithdrawMsgStates(ctx sdk.Context, poolBatch types.PoolBatch, cb func(state types.WithdrawMsgState) (stop bool)) { store := ctx.KVStore(k.storeKey) prefix := types.GetPoolBatchWithdrawMsgsPrefix(poolBatch.PoolId) iterator := sdk.KVStorePrefixIterator(store, prefix) defer iterator.Close() for ; iterator.Valid(); iterator.Next() { state := types.MustUnmarshalWithdrawMsgState(k.cdc, iterator.Value()) if cb(state) { break } } } // IterateAllWithdrawMsgStates iterate through all of the WithdrawMsgState of all batches func (k Keeper) IterateAllWithdrawMsgStates(ctx sdk.Context, cb func(state types.WithdrawMsgState) (stop bool)) { store := ctx.KVStore(k.storeKey) prefix := types.PoolBatchWithdrawMsgStateIndexKeyPrefix iterator := sdk.KVStorePrefixIterator(store, prefix) defer iterator.Close() for ; iterator.Valid(); iterator.Next() { state := types.MustUnmarshalWithdrawMsgState(k.cdc, iterator.Value()) if cb(state) { break } } } // GetAllWithdrawMsgStates returns all BatchWithdrawMsgs for all batches func (k Keeper) GetAllWithdrawMsgStates(ctx sdk.Context) (states []types.WithdrawMsgState) { k.IterateAllWithdrawMsgStates(ctx, func(state types.WithdrawMsgState) bool { states = append(states, state) return false }) return states } // GetAllPoolBatchWithdrawMsgStates returns all BatchWithdrawMsgs indexed by the liquidityPoolBatch func (k Keeper) GetAllPoolBatchWithdrawMsgStates(ctx sdk.Context, poolBatch types.PoolBatch) (states []types.WithdrawMsgState) { k.IterateAllPoolBatchWithdrawMsgStates(ctx, poolBatch, func(state types.WithdrawMsgState) bool { states = append(states, state) return false }) return states } // GetAllPoolBatchWithdrawMsgStatesNotToBeDeleted returns all Not to delete BatchWithdrawMsgs indexed by the liquidityPoolBatch func (k Keeper) GetAllPoolBatchWithdrawMsgStatesNotToBeDeleted(ctx sdk.Context, poolBatch types.PoolBatch) (states []types.WithdrawMsgState) { k.IterateAllPoolBatchWithdrawMsgStates(ctx, poolBatch, func(state types.WithdrawMsgState) bool { if !state.ToBeDeleted { states = append(states, state) } return false }) return states } // GetAllRemainingPoolBatchWithdrawMsgStates returns All only remaining BatchWithdrawMsgs after endblock, executed but not toDelete func (k Keeper) GetAllRemainingPoolBatchWithdrawMsgStates(ctx sdk.Context, poolBatch types.PoolBatch) (states []*types.WithdrawMsgState) { k.IterateAllPoolBatchWithdrawMsgStates(ctx, poolBatch, func(state types.WithdrawMsgState) bool { if state.Executed && !state.ToBeDeleted { states = append(states, &state) } return false }) return states } // delete withdraw batch msgs of the liquidity pool batch which has state ToBeDeleted func (k Keeper) DeleteAllReadyPoolBatchWithdrawMsgStates(ctx sdk.Context, poolBatch types.PoolBatch) { store := ctx.KVStore(k.storeKey) iterator := sdk.KVStorePrefixIterator(store, types.GetPoolBatchWithdrawMsgsPrefix(poolBatch.PoolId)) defer iterator.Close() for ; iterator.Valid(); iterator.Next() { state := types.MustUnmarshalWithdrawMsgState(k.cdc, iterator.Value()) if state.ToBeDeleted { store.Delete(iterator.Key()) } } } // return a specific SwapMsgState given the pool_id with the msg_index func (k Keeper) GetPoolBatchSwapMsgState(ctx sdk.Context, poolID, msgIndex uint64) (state types.SwapMsgState, found bool) { store := ctx.KVStore(k.storeKey) key := types.GetPoolBatchSwapMsgStateIndexKey(poolID, msgIndex) value := store.Get(key) if value == nil { return state, false } state = types.MustUnmarshalSwapMsgState(k.cdc, value) return state, true } // set swap batch msg of the liquidity pool batch, with current state func (k Keeper) SetPoolBatchSwapMsgState(ctx sdk.Context, poolID uint64, state types.SwapMsgState) { store := ctx.KVStore(k.storeKey) b := types.MustMarshalSwapMsgState(k.cdc, state) store.Set(types.GetPoolBatchSwapMsgStateIndexKey(poolID, state.MsgIndex), b) } // Delete swap batch msg of the liquidity pool batch, it used for test case func (k Keeper) DeletePoolBatchSwapMsgState(ctx sdk.Context, poolID uint64, msgIndex uint64) { store := ctx.KVStore(k.storeKey) batchKey := types.GetPoolBatchSwapMsgStateIndexKey(poolID, msgIndex) store.Delete(batchKey) } // IterateAllPoolBatchSwapMsgStates iterate through all of the LiquidityPoolBatchSwapMsgs func (k Keeper) IterateAllPoolBatchSwapMsgStates(ctx sdk.Context, poolBatch types.PoolBatch, cb func(state types.SwapMsgState) (stop bool)) { store := ctx.KVStore(k.storeKey) prefix := types.GetPoolBatchSwapMsgStatesPrefix(poolBatch.PoolId) iterator := sdk.KVStorePrefixIterator(store, prefix) defer iterator.Close() for ; iterator.Valid(); iterator.Next() { state := types.MustUnmarshalSwapMsgState(k.cdc, iterator.Value()) if cb(state) { break } } } // IterateAllSwapMsgStates iterate through all of the SwapMsgState of all batches func (k Keeper) IterateAllSwapMsgStates(ctx sdk.Context, cb func(state types.SwapMsgState) (stop bool)) { store := ctx.KVStore(k.storeKey) prefix := types.PoolBatchSwapMsgStateIndexKeyPrefix iterator := sdk.KVStorePrefixIterator(store, prefix) defer iterator.Close() for ; iterator.Valid(); iterator.Next() { state := types.MustUnmarshalSwapMsgState(k.cdc, iterator.Value()) if cb(state) { break } } } // GetAllSwapMsgStates returns all BatchSwapMsgs of all batches func (k Keeper) GetAllSwapMsgStates(ctx sdk.Context) (states []types.SwapMsgState) { k.IterateAllSwapMsgStates(ctx, func(state types.SwapMsgState) bool { states = append(states, state) return false }) return states } // delete swap batch msgs of the liquidity pool batch which has state ToBeDeleted func (k Keeper) DeleteAllReadyPoolBatchSwapMsgStates(ctx sdk.Context, poolBatch types.PoolBatch) { store := ctx.KVStore(k.storeKey) iterator := sdk.KVStorePrefixIterator(store, types.GetPoolBatchSwapMsgStatesPrefix(poolBatch.PoolId)) defer iterator.Close() for ; iterator.Valid(); iterator.Next() { state := types.MustUnmarshalSwapMsgState(k.cdc, iterator.Value()) if state.ToBeDeleted { store.Delete(iterator.Key()) } } } // GetAllPoolBatchSwapMsgStatesAsPointer returns all BatchSwapMsgs pointer indexed by the liquidityPoolBatch func (k Keeper) GetAllPoolBatchSwapMsgStatesAsPointer(ctx sdk.Context, poolBatch types.PoolBatch) (states []*types.SwapMsgState) { k.IterateAllPoolBatchSwapMsgStates(ctx, poolBatch, func(state types.SwapMsgState) bool { states = append(states, &state) return false }) return states } // GetAllPoolBatchSwapMsgStates returns all BatchSwapMsgs indexed by the liquidityPoolBatch func (k Keeper) GetAllPoolBatchSwapMsgStates(ctx sdk.Context, poolBatch types.PoolBatch) (states []types.SwapMsgState) { k.IterateAllPoolBatchSwapMsgStates(ctx, poolBatch, func(state types.SwapMsgState) bool { states = append(states, state) return false }) return states } // GetAllNotProcessedPoolBatchSwapMsgStates returns All only not processed swap msgs, not executed with not succeed and not toDelete BatchSwapMsgs indexed by the liquidityPoolBatch func (k Keeper) GetAllNotProcessedPoolBatchSwapMsgStates(ctx sdk.Context, poolBatch types.PoolBatch) (states []*types.SwapMsgState) { k.IterateAllPoolBatchSwapMsgStates(ctx, poolBatch, func(state types.SwapMsgState) bool { if !state.Executed && !state.Succeeded && !state.ToBeDeleted { states = append(states, &state) } return false }) return states } // GetAllRemainingPoolBatchSwapMsgStates returns All only remaining after endblock swap msgs, executed but not toDelete func (k Keeper) GetAllRemainingPoolBatchSwapMsgStates(ctx sdk.Context, poolBatch types.PoolBatch) (states []*types.SwapMsgState) { k.IterateAllPoolBatchSwapMsgStates(ctx, poolBatch, func(state types.SwapMsgState) bool { if state.Executed && !state.ToBeDeleted { states = append(states, &state) } return false }) return states } // GetAllPoolBatchSwapMsgStatesNotToBeDeleted returns All only not to delete swap msgs func (k Keeper) GetAllPoolBatchSwapMsgStatesNotToBeDeleted(ctx sdk.Context, poolBatch types.PoolBatch) (states []*types.SwapMsgState) { k.IterateAllPoolBatchSwapMsgStates(ctx, poolBatch, func(state types.SwapMsgState) bool { if !state.ToBeDeleted { states = append(states, &state) } return false }) return states } // set swap batch msgs of the liquidity pool batch, with current state using pointers func (k Keeper) SetPoolBatchSwapMsgStatesByPointer(ctx sdk.Context, poolID uint64, states []*types.SwapMsgState) { store := ctx.KVStore(k.storeKey) for _, state := range states { if poolID != state.Msg.PoolId { continue } b := types.MustMarshalSwapMsgState(k.cdc, *state) store.Set(types.GetPoolBatchSwapMsgStateIndexKey(poolID, state.MsgIndex), b) } } // set swap batch msgs of the liquidity pool batch, with current state func (k Keeper) SetPoolBatchSwapMsgStates(ctx sdk.Context, poolID uint64, states []types.SwapMsgState) { store := ctx.KVStore(k.storeKey) for _, state := range states { if poolID != state.Msg.PoolId { continue } b := types.MustMarshalSwapMsgState(k.cdc, state) store.Set(types.GetPoolBatchSwapMsgStateIndexKey(poolID, state.MsgIndex), b) } } ================================================ FILE: x/liquidity/keeper/swap.go ================================================ package keeper import ( "fmt" "strconv" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/liquidity/types" ) // Execute Swap of the pool batch, Collect swap messages in batch for transact the same price for each batch and run them on endblock. func (k Keeper) SwapExecution(ctx sdk.Context, poolBatch types.PoolBatch) (uint64, error) { // get all swap message batch states that are not executed, not succeeded, and not to be deleted. swapMsgStates := k.GetAllNotProcessedPoolBatchSwapMsgStates(ctx, poolBatch) if len(swapMsgStates) == 0 { return 0, nil } pool, found := k.GetPool(ctx, poolBatch.PoolId) if !found { return 0, types.ErrPoolNotExists } if k.IsDepletedPool(ctx, pool) { return 0, types.ErrDepletedPool } currentHeight := ctx.BlockHeight() // set executed states of all messages to true executedMsgCount := uint64(0) var swapMsgStatesNotToBeDeleted []*types.SwapMsgState for _, sms := range swapMsgStates { sms.Executed = true executedMsgCount++ if currentHeight > sms.OrderExpiryHeight { sms.ToBeDeleted = true } if err := k.ValidateMsgSwapWithinBatch(ctx, *sms.Msg, pool); err != nil { sms.ToBeDeleted = true } if !sms.ToBeDeleted { swapMsgStatesNotToBeDeleted = append(swapMsgStatesNotToBeDeleted, sms) } else { ctx.EventManager().EmitEvent( sdk.NewEvent( types.EventTypeSwapTransacted, sdk.NewAttribute(types.AttributeValuePoolId, strconv.FormatUint(pool.Id, 10)), sdk.NewAttribute(types.AttributeValueBatchIndex, strconv.FormatUint(poolBatch.Index, 10)), sdk.NewAttribute(types.AttributeValueMsgIndex, strconv.FormatUint(sms.MsgIndex, 10)), sdk.NewAttribute(types.AttributeValueSwapRequester, sms.Msg.GetSwapRequester().String()), sdk.NewAttribute(types.AttributeValueSwapTypeId, strconv.FormatUint(uint64(sms.Msg.SwapTypeId), 10)), sdk.NewAttribute(types.AttributeValueOfferCoinDenom, sms.Msg.OfferCoin.Denom), sdk.NewAttribute(types.AttributeValueOfferCoinAmount, sms.Msg.OfferCoin.Amount.String()), sdk.NewAttribute(types.AttributeValueDemandCoinDenom, sms.Msg.DemandCoinDenom), sdk.NewAttribute(types.AttributeValueOrderPrice, sms.Msg.OrderPrice.String()), sdk.NewAttribute(types.AttributeValueRemainingOfferCoinAmount, sms.RemainingOfferCoin.Amount.String()), sdk.NewAttribute(types.AttributeValueExchangedOfferCoinAmount, sms.ExchangedOfferCoin.Amount.String()), sdk.NewAttribute(types.AttributeValueReservedOfferCoinFeeAmount, sms.ReservedOfferCoinFee.Amount.String()), sdk.NewAttribute(types.AttributeValueOrderExpiryHeight, strconv.FormatInt(sms.OrderExpiryHeight, 10)), sdk.NewAttribute(types.AttributeValueSuccess, types.Failure), )) } } k.SetPoolBatchSwapMsgStatesByPointer(ctx, pool.Id, swapMsgStates) swapMsgStates = swapMsgStatesNotToBeDeleted types.ValidateStateAndExpireOrders(swapMsgStates, currentHeight, false) // get reserve coins from the liquidity pool and calculate the current pool price (p = x / y) reserveCoins := k.GetReserveCoins(ctx, pool) X := reserveCoins[0].Amount.ToLegacyDec() Y := reserveCoins[1].Amount.ToLegacyDec() currentPoolPrice := X.Quo(Y) denomX := reserveCoins[0].Denom denomY := reserveCoins[1].Denom // make orderMap, orderbook by sort orderMap orderMap, xToY, yToX := types.MakeOrderMap(swapMsgStates, denomX, denomY, false) orderBook := orderMap.SortOrderBook() // check orderbook validity and compute batchResult(direction, swapPrice, ..) result, found := orderBook.Match(X, Y) if !found || X.Quo(Y).IsZero() { err := k.RefundSwaps(ctx, pool, swapMsgStates) return executedMsgCount, err } // find order match, calculate pool delta with the total x, y amounts for the invariant check var matchResultXtoY, matchResultYtoX []types.MatchResult poolXDelta := sdk.ZeroDec() poolYDelta := sdk.ZeroDec() if result.MatchType != types.NoMatch { var poolXDeltaXtoY, poolXDeltaYtoX, poolYDeltaYtoX, poolYDeltaXtoY sdk.Dec matchResultXtoY, poolXDeltaXtoY, poolYDeltaXtoY = types.FindOrderMatch(types.DirectionXtoY, xToY, result.EX, result.SwapPrice, currentHeight) matchResultYtoX, poolXDeltaYtoX, poolYDeltaYtoX = types.FindOrderMatch(types.DirectionYtoX, yToX, result.EY, result.SwapPrice, currentHeight) poolXDelta = poolXDeltaXtoY.Add(poolXDeltaYtoX) poolYDelta = poolYDeltaXtoY.Add(poolYDeltaYtoX) } xToY, yToX, X, Y, poolXDelta2, poolYDelta2 := types.UpdateSwapMsgStates(X, Y, xToY, yToX, matchResultXtoY, matchResultYtoX) lastPrice := X.Quo(Y) if BatchLogicInvariantCheckFlag { SwapMatchingInvariants(xToY, yToX, matchResultXtoY, matchResultYtoX) SwapPriceInvariants(matchResultXtoY, matchResultYtoX, poolXDelta, poolYDelta, poolXDelta2, poolYDelta2, result) } types.ValidateStateAndExpireOrders(xToY, currentHeight, false) types.ValidateStateAndExpireOrders(yToX, currentHeight, false) orderMapExecuted, _, _ := types.MakeOrderMap(append(xToY, yToX...), denomX, denomY, true) orderBookExecuted := orderMapExecuted.SortOrderBook() if !orderBookExecuted.Validate(lastPrice) { return executedMsgCount, types.ErrOrderBookInvalidity } types.ValidateStateAndExpireOrders(xToY, currentHeight, true) types.ValidateStateAndExpireOrders(yToX, currentHeight, true) // make index map for match result matchResultMap := make(map[uint64]types.MatchResult) for _, match := range append(matchResultXtoY, matchResultYtoX...) { if _, ok := matchResultMap[match.SwapMsgState.MsgIndex]; ok { return executedMsgCount, fmt.Errorf("duplicate match order") } matchResultMap[match.SwapMsgState.MsgIndex] = match } if BatchLogicInvariantCheckFlag { SwapPriceDirectionInvariants(currentPoolPrice, result) SwapMsgStatesInvariants(matchResultXtoY, matchResultYtoX, matchResultMap, swapMsgStates, xToY, yToX) SwapOrdersExecutionStateInvariants(matchResultMap, swapMsgStates, result, denomX) } // execute transact, refund, expire, send coins with escrow, update state by TransactAndRefundSwapLiquidityPool if err := k.TransactAndRefundSwapLiquidityPool(ctx, swapMsgStates, matchResultMap, pool, result); err != nil { return executedMsgCount, err } return executedMsgCount, nil } ================================================ FILE: x/liquidity/migrations/v3/migrate.go ================================================ package v3 import ( "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/liquidity/exported" "github.com/cybercongress/go-cyber/v7/x/liquidity/types" ) func Migrate( ctx sdk.Context, store sdk.KVStore, legacySubspace exported.Subspace, cdc codec.BinaryCodec, ) error { var currParams types.Params legacySubspace.GetParamSet(ctx, &currParams) if err := currParams.Validate(); err != nil { return err } bz := cdc.MustMarshal(&currParams) store.Set(types.ParamsKey, bz) return nil } ================================================ FILE: x/liquidity/module.go ================================================ package liquidity import ( "context" "encoding/json" "fmt" "github.com/cybercongress/go-cyber/v7/x/liquidity/exported" abci "github.com/cometbft/cometbft/abci/types" sdkclient "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/codec" codectypes "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/spf13/cobra" "github.com/cybercongress/go-cyber/v7/x/liquidity/client/cli" "github.com/cybercongress/go-cyber/v7/x/liquidity/keeper" "github.com/cybercongress/go-cyber/v7/x/liquidity/types" ) var ( _ module.AppModule = AppModule{} _ module.AppModuleBasic = AppModuleBasic{} ) // AppModuleBasic defines the basic application module used by the liquidity module. type AppModuleBasic struct { cdc codec.Codec } // Name returns the liquidity module's name. func (AppModuleBasic) Name() string { return types.ModuleName } // RegisterLegacyAminoCodec registers the gov module's types for the given codec. func (AppModuleBasic) RegisterLegacyAminoCodec(cdc *codec.LegacyAmino) { types.RegisterLegacyAminoCodec(cdc) } // DefaultGenesis returns default genesis state as raw bytes for the liquidity module. func (AppModuleBasic) DefaultGenesis(cdc codec.JSONCodec) json.RawMessage { return cdc.MustMarshalJSON(types.DefaultGenesisState()) } // ValidateGenesis performs genesis state validation for the liquidity module. func (AppModuleBasic) ValidateGenesis(cdc codec.JSONCodec, _ sdkclient.TxEncodingConfig, bz json.RawMessage) error { var data types.GenesisState if err := cdc.UnmarshalJSON(bz, &data); err != nil { return fmt.Errorf("failed to unmarshal %s genesis state: %w", types.ModuleName, err) } return types.ValidateGenesis(data) } // GetTxCmd returns the root tx command for the liquidity module. func (AppModuleBasic) GetTxCmd() *cobra.Command { return cli.GetTxCmd() } // GetQueryCmd returns no root query command for the liquidity module. func (AppModuleBasic) GetQueryCmd() *cobra.Command { return cli.GetQueryCmd() } // RegisterInterfaces implements InterfaceModule.RegisterInterfaces func (a AppModuleBasic) RegisterInterfaces(registry codectypes.InterfaceRegistry) { types.RegisterInterfaces(registry) } // RegisterGRPCGatewayRoutes registers the gRPC Gateway routes for the liquidity module. func (AppModuleBasic) RegisterGRPCGatewayRoutes(clientCtx sdkclient.Context, mux *runtime.ServeMux) { if err := types.RegisterQueryHandlerClient(context.Background(), mux, types.NewQueryClient(clientCtx)); err != nil { panic(err) } } // RegisterServices registers module services. func (am AppModule) RegisterServices(cfg module.Configurator) { types.RegisterMsgServer(cfg.MsgServer(), keeper.NewMsgServerImpl(am.keeper)) querier := keeper.Querier{Keeper: am.keeper} types.RegisterQueryServer(cfg.QueryServer(), querier) m := keeper.NewMigrator(am.keeper, am.legacySubspace) if err := cfg.RegisterMigration(types.ModuleName, 2, m.Migrate2to3); err != nil { panic(fmt.Sprintf("failed to migrate x/%s from version 2 to 3: %v", types.ModuleName, err)) } } // AppModule implements an application module for the liquidity module. type AppModule struct { AppModuleBasic keeper keeper.Keeper accountKeeper types.AccountKeeper bankKeeper types.BankKeeper distrKeeper types.DistributionKeeper legacySubspace exported.Subspace } // NewAppModule creates a new AppModule object func NewAppModule(cdc codec.Codec, keeper keeper.Keeper, ak types.AccountKeeper, bk types.BankKeeper, dk types.DistributionKeeper, ss exported.Subspace, ) AppModule { return AppModule{ AppModuleBasic: AppModuleBasic{cdc: cdc}, keeper: keeper, accountKeeper: ak, bankKeeper: bk, distrKeeper: dk, legacySubspace: ss, } } // Name returns the liquidity module's name. func (AppModule) Name() string { return types.ModuleName } // RegisterLegacyAminoCodec registers the gov module's types for the given codec. func (AppModule) RegisterLegacyAminoCodec(cdc *codec.LegacyAmino) { types.RegisterLegacyAminoCodec(cdc) } // RegisterInvariants registers the liquidity module invariants. func (am AppModule) RegisterInvariants(ir sdk.InvariantRegistry) { keeper.RegisterInvariants(ir, am.keeper) } // InitGenesis performs genesis initialization for the liquidity module. It returns // no validator updates. func (am AppModule) InitGenesis(ctx sdk.Context, cdc codec.JSONCodec, data json.RawMessage) []abci.ValidatorUpdate { var genesisState types.GenesisState cdc.MustUnmarshalJSON(data, &genesisState) InitGenesis(ctx, am.keeper, genesisState) return []abci.ValidatorUpdate{} } // ExportGenesis returns the exported genesis state as raw bytes for the liquidity module. func (am AppModule) ExportGenesis(ctx sdk.Context, cdc codec.JSONCodec) json.RawMessage { gs := ExportGenesis(ctx, am.keeper) return cdc.MustMarshalJSON(gs) } // ConsensusVersion implements AppModule/ConsensusVersion. func (AppModule) ConsensusVersion() uint64 { return 3 } // BeginBlock performs a no-op. func (am AppModule) BeginBlock(ctx sdk.Context, _ abci.RequestBeginBlock) { BeginBlocker(ctx, am.keeper) } // EndBlock returns the end blocker for the liquidity module. It returns no validator updates. func (am AppModule) EndBlock(ctx sdk.Context, _ abci.RequestEndBlock) []abci.ValidatorUpdate { EndBlocker(ctx, am.keeper) return []abci.ValidatorUpdate{} } ================================================ FILE: x/liquidity/spec/01_concepts.md ================================================ # Concepts ## Liquidity Module The liquidity module is a module that can be used on any Cosmos SDK-based application. The liquidity module implements a decentralized exchange (DEX) that serves liquidity providing and coin swap functions. Anyone can create a liquidity pool with a pair of coins, provide liquidity by depositing reserve coins into the liquidity pool, and trade coins using the liquidity pool. All of the logic is designed to always protect the pool investors. ## Liquidity Pool A liquidity pool is a coin reserve that contains two different types of coins in a trading pair. The trading pair has to be unique. A liquidity provider can be anyone (permissionless) who provides liquidity by depositing reserve coins into the pool. The liquidity provider earns the accumulated swap fees with respect to their pool share. The pool share is represented as possession of pool coins. All matchable swap requests are expected to be executed and unmatched swap requests are removed. ## Equivalent Swap Price Model (ESPM) The liquidity module is a Cosmos SDK implementation of an AMM system with a novel economic model called the Equivalent Swap Price Model (ESPM). The key distinguishing feature of the ESPM model from the Constant Product Market Maker (CPMM) model is the implementation of a hybrid system that combines an orderbook model exchange with a simple liquidity pool model that governs the order book with a set of order rules and performs execution in batches. In the ESPM, the pool price is always equal to the last swap price which reduces opportunities for arbitrage. The ESPM model is intended to provide protection against price volatility, transaction ordering vulnerabilities, and losses due to arbitrage. AMMs such as Uniswap do not provide this level of protection. ## Batch Execution The liquidity module uses a batch execution methodology. Deposits, withdrawals, and swap orders are accumulated in a liquidity pool for a pre-defined period that is one or more blocks in length. Orders are then added to the pool and executed at the end of the batch. The size of each batch is configured by using the `UnitBatchSize` governance parameter. ## Price Discovery Swap prices in liquidity pools are determined by the current pool coin reserves and the requested swap amount. Arbitrageurs buy or sell coins in liquidity pools to gain instant profit that results in real-time price discovery of liquidity pools. ## Escrow Process The liquidity module uses a module account that acts as an escrow account. The module account holds and releases the coin amount during batch execution. ## Refund The liquidity module has refund functions when deposit, withdraw, or swap batch states are not successfully executed. Read [the batch transaction logic](https://github.com/tendermint/liquidity/blob/e8ab2f4d75079157d008eba9f310b199573eed28/x/liquidity/keeper/batch.go#L83-L127) in the code for more context. ## Fees You set liquidity module fees for pool creation, withdrawal, and swap in genesis state. These fees can be updated by the governance proposal. ### PoolCreationFee The liquidity module pool creation fee set by the `PoolCreationFee` parameter is paid on pool creation. The purpose of this fee is to prevent users from creating useless pools and making limitless transactions. The funds from this fee go to the community fund. ### WithdrawalFeeRate The liquidity module has `WithdrawFeeRate` parameter that is paid upon withdrawal. The purpose of this fee is to prevent from making limitless withdrawals. ### SwapFeeRate Swap fees are paid upon swap orders. They are accumulated in the pools and are shared among the liquidity providers. The liquidity module implements half-half-fee mechanism that minimizes the impact of fee payment process. Read [the issue about fees in half offer coins, half exchanged coins](https://github.com/tendermint/liquidity/issues/41) to have more context. ## Pool Identification The pools in the liquidity module are identified with: ### PoolName - Concatenate two different reserve coin denoms and pool type id and forward slash `/` separator. - Example: `uatom/stake/1` ### PoolReserveAccount - `sdk.AccAddress(crypto.AddressHash([]byte(PoolName)))` - Example: `cosmos16ddqestwukv0jzcyfn3fdfq9h2wrs83cr4rfm3` (`D35A0CC16EE598F90B044CE296A405BA9C381E38`) ### PoolCoinDenom - `fmt.Sprintf("%s%X", PoolCoinDenomPrefix, sha256.Sum256([]byte(PoolName)))` - Use `PoolCoinDenomPrefix` for `pool` - Example: `poolD35A0CC16EE598F90B044CE296A405BA9C381E38837599D96F2F70C2F02A23A4` ================================================ FILE: x/liquidity/spec/02_state.md ================================================ # State The liquidity module `x/liquidity` keeps track of the Pool and PoolBatch states. The state represents your app at a given moment. ## Pool Pool stores information about the liquidity pool. Pool type has the following structure. ```go type Pool struct { Id uint64 // index of this liquidity pool TypeId uint32 // pool type of this liquidity pool ReserveCoinDenoms []string // list of reserve coin denoms for this liquidity pool ReserveAccountAddress string // reserve account address for this liquidity pool to store reserve coins PoolCoinDenom string // denom of pool coin for this liquidity pool } ``` The parameters of the Pool state are: - Pool: `0x11 | Id -> ProtocolBuffer(Pool)` - PoolByReserveAccIndex: `0x12 | ReserveAccLen (1 byte) | ReserveAcc -> ProtocolBuffer(uint64)` - GlobalLiquidityPoolIdKey: `[]byte("globalLiquidityPoolId")` - ModuleName, RouterKey, StoreKey: `liquidity` - PoolCoinDenomPrefix: `pool` ## PoolBatch PoolBatch stores information about the liquidity pool batch states. PoolBatch type has the following structure. ```go type PoolBatch struct { PoolId uint64 // id of target liquidity pool Index uint64 // index of this batch BeginHeight uint64 // block height when batch is created DepositMsgIndex uint64 // last index of DepositMsgStates WithdrawMsgIndex uint64 // last index of WithdrawMsgStates SwapMsgIndex uint64 // last index of SwapMsgStates Executed bool // true if executed, false if not executed } ``` ## Batch Messages Deposit, withdrawal, or swap orders are accumulated in a liquidity pool for a pre-defined period, which can be one or more blocks in length. Orders are then added to the pool and executed at the end of the batch. The following messages are executed in batch-style. ### DepositMsgState `DepositMsgState` defines the state of deposit message as it is processed in the next batch or batches. When a user sends `MsgDepositWithinBatch` transaction to the network, it is accumulated in a batch. `DepositMsgState` contains the state information about the message; if the transaction is executed, successfully matched, and if it is to be deleted in the next block. ```go type DepositMsgState struct { MsgHeight int64 // block height where this message is appended to the batch MsgIndex uint64 // index of this deposit message in this liquidity pool Executed bool // true if executed on this batch, false if not executed Succeeded bool // true if executed successfully on this batch, false if failed ToBeDelete bool // true if ready to be deleted on kvstore, false if not ready to be deleted Msg MsgDepositWithinBatch } ``` ### WithdrawMsgState `WithdrawMsgState` defines the state of the withdraw message as it is processed in the next batch or batches. When a user sends a `MsgWithdrawWithinBatch` transaction to the network, it is accumulated in a batch. `WithdrawMsgState` contains the state information about the message: - If the transaction is executed - If the transaction is successfully matched - If the transaction will be deleted in the next block ```go type WithdrawMsgState struct { MsgHeight int64 // block height where this message is appended to the batch MsgIndex uint64 // index of this withdraw message in this liquidity pool Executed bool // true if executed on this batch, false if not executed Succeeded bool // true if executed successfully on this batch, false if failed ToBeDelete bool // true if ready to be deleted on kvstore, false if not ready to be deleted Msg MsgWithdrawWithinBatch } ``` ### SwapMsgState `SwapMsgState` defines the state of swap message as it is processed in the next batch or batches. When a user sends a `MsgSwapWithinBatch` transaction to the network, it is accumulated in a batch. `SwapMsgState` contains the state information about the message: - If the transaction is executed - If the transaction is successfully matched - If the transaction will be deleted in the next block ```go type SwapMsgState struct { MsgHeight int64 // block height where this message is appended to the batch MsgIndex uint64 // index of this swap message in this liquidity pool Executed bool // true if executed on this batch, false if not executed Succeeded bool // true if executed successfully on this batch, false if failed ToBeDelete bool // true if ready to be deleted on kvstore, false if not ready to be deleted OrderExpiryHeight int64 // swap orders are cancelled when current height is equal to or greater than ExpiryHeight ExchangedOfferCoin sdk.Coin // offer coin exchanged so far RemainingOfferCoin sdk.Coin // offer coin remaining to be exchanged Msg MsgSwapWithinBatch } ``` The parameters of the PoolBatch, DepositMsgState, WithdrawMsgState, and SwapMsgState states are: - PoolBatch: `0x22 | PoolId -> ProtocolBuffer(PoolBatch)` - PoolBatchDepositMsgStates: `0x31 | PoolId | MsgIndex -> ProtocolBuffer(DepositMsgState)` - PoolBatchWithdrawMsgStates: `0x32 | PoolId | MsgIndex -> ProtocolBuffer(WithdrawMsgState)` - PoolBatchSwapMsgStates: `0x33 | PoolId | MsgIndex -> ProtocolBuffer(SwapMsgState)` ================================================ FILE: x/liquidity/spec/03_state_transitions.md ================================================ # State Transitions These messages (Msg) in the liquidity module trigger state transitions. ## Coin Escrow for Liquidity Module Messages Transaction confirmation causes state transition on the [Bank](https://docs.cosmos.network/master/modules/bank/) module. Some messages on the liquidity module require coin escrow before confirmation. The coin escrow processes for each message type are: ### MsgDepositWithinBatch To deposit coins into an existing `Pool`, the depositor must escrow `DepositCoins` into `LiquidityModuleEscrowAccount`. ### MsgWithdrawWithinBatch To withdraw coins from a `Pool`, the withdrawer must escrow `PoolCoin` into `LiquidityModuleEscrowAccount`. ### MsgSwapWithinBatch To request a coin swap, the swap requestor must escrow `OfferCoin` into `LiquidityModuleEscrowAccount`. ## LiquidityPoolBatch Execution Batch execution causes state transitions on the `Bank` module. The following categories describe state transition executed by each process in the `PoolBatch` execution. ### Coin Swap After a successful coin swap, coins accumulated in `LiquidityModuleEscrowAccount` for coin swaps are sent to other swap requestors(self-swap) or to the `Pool`(pool-swap). Fees are also sent to the liquidity `Pool`. ### LiquidityPool Deposit After a successful deposit transaction, escrowed coins are sent to the `ReserveAccount` of the targeted `Pool` and new pool coins are minted and sent to the depositor. ### LiquidityPool Withdrawal After a successful withdraw transaction, escrowed pool coins are burned and a corresponding amount of reserve coins are sent to the withdrawer from the liquidity `Pool`. ## Pseudo Algorithm for LiquidityPoolBatch Execution If you are curious, you can see a Python simulation script on the B-Harvest [GitHub repo](https://github.com/b-harvest/Liquidity-Module-For-the-Hub/blob/master/pseudo-batch-execution-logic/batch.py). ## Swap Price Calculation Swap execution applies a universal swap ratio for all swap requests. Swap price calculations are used for these cases. **Find price direction** Variables: - `X`: Reserve of X coin - `Y`: Reserve of Y coin before this batch execution - `PoolPrice` = `X`/`Y` - `XOverLastPrice`: amount of orders that swap X for Y with order price higher than the last `PoolPrice` - `XAtLastPrice`: amount of orders that swap X for Y with order price equal to the last `PoolPrice` - `YUnderLastPrice`: amount of orders that swap Y for X with order price lower than last `PoolPrice` - `YAtLastPrice`: amount of orders that swap Y for X with order price equal to the last `PoolPrice` - **Increase**: swap price is increased from the last `PoolPrice` - `XOverLastPrice` > (`YUnderLastPrice`+`YAtLastPrice`)*`PoolPrice` - **Decrease**: swap price is decreased from the last `PoolPrice` - `YUnderLastPrice` > (`XOverLastPrice`+`XAtLastPrice`)/`PoolPrice` - **Stay**: swap price is not changed from the last `PoolPrice` when the increase and decrease inequalities do not hold ### Stay case Variables: - `swapPrice` = last `PoolPrice` - `EX`: All executable orders that swap X for Y with order price equal to or greater than last `PoolPrice` - `EY`: All executable orders that swap Y for X with order price equal or lower than last `PoolPrice` - **ExactMatch**: If `EX` == `EY`*`swapPrice` - Amount of X coins matched from swap orders = `EX` - Amount of Y coins matched from swap orders = `EY` - **FractionalMatch** - If `EX` > `EY`*`swapPrice`: Residual X order amount remains - Amount of X coins matched from swap orders = `EY`*`swapPrice` - Amount of Y coins matched from swap orders = `EY` - If `EY` > `EX`/`swapPrice`: Residual Y order amount remains - Amount of X coins matched from swap orders = `EX` - Amount of Y coins matched from swap orders = `EX`/`swapPrice` ### Increase case Iteration: iterate `orderPrice(i)` of all swap orders from low to high. Variables: - `EX(i)`: Sum of all order amount of swap orders that swap X for Y with order price equal or higher than this `orderPrice(i)` - `EY(i)`: Sum of all order amounts of swap orders that swap Y for X with order price equal or lower than this `orderPrice(i)` - ExactMatch: SwapPrice is found between two orderPrices - `swapPrice(i)` = (`X` + 2_`EX(i)`)/(`Y` + 2_`EY(i-1)`) - condition1) `orderPrice(i-1)` < `swapPrice(i)` < `orderPrice(i)` - `PoolY(i)` = (`swapPrice(i)`_`Y` - `X`) / (2_`swapPrice(i)`) - condition2) `PoolY(i)` >= 0 - If both above conditions are met, `swapPrice` is the swap price for this iteration - Amount of X coins matched = `EX(i)` - If one of these conditions doesn't hold, go to FractionalMatch - FractionalMatch: SwapPrice is found at an orderPrice - `swapPrice(i)` = `orderPrice(i)` - `PoolY(i)` = (`swapPrice(i)`_`Y` - `X`) / (2_`swapPrice(i)`) - Amount of X coins matched: - `EX(i)` ← min[ `EX(i)`, (`EY(i)`+`PoolY(i)`)*`swapPrice(i)` ] - Find optimized swapPrice: - Find `swapPrice(k)` that has the largest amount of X coins matched - this is our optimized swap price - corresponding swap result variables - `swapPrice(k)`, `EX(k)`, `EY(k)`, `PoolY(k)` ### Decrease case Iteration: iterate `orderPrice(i)` of all swap orders from high to low. Variables: - `EX(i)`: Sum of all order amount of swap orders that swap X for Y with order price equal or higher than this `orderPrice(i)` - `EY(i)`: Sum of all order amount of swap orders that swap Y for X with order price equal or lower than this `orderPrice(i)` - ExactMatch: SwapPrice is found between two orderPrices - `swapPrice(i)` = (`X` + 2_`EX(i)`)/(`Y` + 2_`EY(i-1)`) - condition1) `orderPrice(i)` < `swapPrice(i)` < `orderPrice(i-1)` - `PoolX(i)` = (`X` - `swapPrice(i)`*`Y`)/2 - condition2) `PoolX(i)` >= 0 - If both above conditions are met, `swapPrice` is the swap price for this iteration - Amount of Y coins matched = `EY(i)` - If one of these conditions doesn't hold, go to FractionalMatch - FractionalMatch: SwapPrice is found at an orderPrice - `swapPrice(i)` = `orderPrice(i)` - `PoolX(i)` = (`X` - `swapPrice(i)`*`Y`)/2 - Amount of Y coins matched: - `EY(i)` ← min[ `EY(i)`, (`EX(i)`+`PoolX(i)`)/`swapPrice(i)` ] - Find optimized swapPrice - Find `swapPrice(k)` that has the largest amount of Y coins matched - this is our optimized swap price - corresponding swap result variables - `swapPrice(k)`, `EX(k)`, `EY(k)`, `PoolX(k)` ### Calculate matching result - for swap orders from X to Y - Iteration: iterate `orderPrice(i)` of swap orders from X to Y (high to low) - sort by order price (high to low), sum all order amount with each `orderPrice(i)` - if `EX(i)` ≤ `EX(k)` - `fractionalRatio` = 1 - if `EX(i)` > `EX(k)` - `fractionalRatio(i)` = (`EX(k)` - `EX(i-1)`) / (`EX(i)` - `EX(i-1)`) - break the iteration - matching amount for swap orders with this `orderPrice(i)`: - `matchingAmt` = `offerAmt` * `fractionalRatio(i)` - for swap orders from Y to X - Iteration: iterate `orderPrice(i)` of swap orders from Y to X (low to high) - sort by order price (low to high), sum all order amount with each `orderPrice(i)` - if `EY(i)` ≤ `EY(k)` - `fractionalRatio` = 1 - if `EY(i)` > `EY(k)` - `fractionalRatio(i)` = (`EY(k)` - `EY(i-1)`) / (`EY(i)` - `EY(i-1)`) - break the iteration - matching amount for swap orders with this `orderPrice(i)`: - `matchingAmt` = `offerAmt` * `fractionalRatio(i)` ### Swap Fee Payment Rather than taking fee solely from `OfferCoin`, liquidity module is designed to take fees half from `OfferCoin`, and the other half from `ExchangedCoin`. This smooths out an impact of the fee payment process. - **OfferCoin Fee Reservation ( fee before batch process, in OfferCoin )** - when user orders 100 Xcoin, the swap message demands - `OfferCoin`(in Xcoin) : 100 - `ReservedOfferCoinFeeAmount`(in Xcoin) = `OfferCoin`*(`SwapFeeRate`/2) - user needs to have at least 100+100*(`SwapFeeRate`/2) amount of Xcoin to successfully commit this swap message - the message fails when user's balance is below this amount - **Actual Fee Payment** - if 10 Xcoin is executed - **OfferCoin Fee Payment from Reserved OfferCoin Fee** - `OfferCoinFeeAmount`(in Xcoin) = (10/100)*`ReservedOfferCoinFeeAmount` - `ReservedOfferCoinFeeAmount` is reduced from this fee payment - **ExchangedCoin Fee Payment ( fee after batch process, in ExchangedCoin )** - `ExchangedCoinFeeAmount`(in Ycoin) = `OfferCoinFeeAmount` / `SwapPrice` - this is exactly equal value compared to advance fee payment assuming the current SwapPrice, to minimize the pool price impact from fee payment process - Swap fees are proportional to the coins received from matched swap orders. - Swap fees are sent to the liquidity pool. - The decimal points of the swap fees are rounded up. ## Cancel unexecuted swap orders with expired CancelHeight After execution of `PoolBatch`, all remaining swap orders with `CancelHeight` equal to or higher than current height are cancelled. ## Refund escrowed coins Refunds are issued for escrowed coins for cancelled swap order and failed create pool, deposit, and withdraw messages. ================================================ FILE: x/liquidity/spec/04_messages.md ================================================ # Messages Messages (Msg) are objects that trigger state transitions. Msgs are wrapped in transactions (Txs) that clients submit to the network. The Cosmos SDK wraps and unwraps liquidity module messages from transactions. ## MsgCreatePool A liquidity pool is created and initial coins are deposited with the `MsgCreatePool` message. ```go type MsgCreatePool struct { PoolCreatorAddress string // account address of the origin of this message PoolTypeId uint32 // id of the new liquidity pool DepositCoins sdk.Coins // deposit initial coins for new liquidity pool } ``` ### Validity Checks Validity checks are performed for MsgCreatePool messages. The transaction that is triggered with `MsgCreatePool` fails if: - if `params.CircuitBreakerEnabled` is true - `PoolCreator` address does not exist - `PoolTypeId` does not exist in parameters - A duplicate `LiquidityPool` with same `PoolTypeId` and `ReserveCoinDenoms` exists - One or more coins in `ReserveCoinDenoms` do not exist in `bank` module - The balance of `PoolCreator` does not have enough amount of coins for `DepositCoins` - The balance of `PoolCreator` does not have enough coins for `PoolCreationFee` ## MsgDepositWithinBatch Coins are deposited in a batch to a liquidity pool with the `MsgDepositWithinBatch` message. ```go type MsgDepositWithinBatch struct { DepositorAddress string // account address of depositor that originated this message PoolId uint64 // id of the liquidity pool to receive deposit DepositCoins sdk.Coins // deposit coins } ``` ## Validity Checks The MsgDepositWithinBatch message performs validity checks. The transaction that is triggered with the `MsgDepositWithinBatch` message fails if: - if `params.CircuitBreakerEnabled` is true - `Depositor` address does not exist - `PoolId` does not exist - The denoms of `DepositCoins` are not composed of existing `ReserveCoinDenoms` of the specified `LiquidityPool` - The balance of `Depositor` does not have enough coins for `DepositCoins` ## MsgWithdrawWithinBatch Withdraw coins in batch from liquidity pool with the `MsgWithdrawWithinBatch` message. ```go type MsgWithdrawWithinBatch struct { WithdrawerAddress string // account address of the origin of this message PoolId uint64 // id of the liquidity pool to withdraw the coins from PoolCoin sdk.Coin // pool coin sent for reserve coin withdrawal } ``` ## Validity Checks The MsgWithdrawWithinBatch message performs validity checks. The transaction that is triggered with the `MsgWithdrawWithinBatch` message fails if: - `Withdrawer` address does not exist - `PoolId` does not exist - The denom of `PoolCoin` are not equal to the `PoolCoinDenom` of the `LiquidityPool` - The balance of `Depositor` does not have enough coins for `PoolCoin` ## MsgSwapWithinBatch Swap coins between liquidity pools in batch with the `MsgSwapWithinBatch` message. Offer coins are swapped with demand coins for the given order price. ```go type MsgSwapWithinBatch struct { SwapRequesterAddress string // account address of the origin of this message PoolId uint64 // id of the liquidity pool SwapTypeId uint32 // swap type id of this swap message, default 1: InstantSwap, requesting instant swap OfferCoin sdk.Coin // offer coin of this swap DemandCoinDenom string // denom of demand coin of this swap OfferCoinFee sdk.Coin // offer coin fee for pay fees in half offer coin OrderPrice sdk.Dec // limit order price where the price is the exchange ratio of X/Y where X is the amount of the first coin and Y is the amount of the second coin when their denoms are sorted alphabetically } ``` ## Validity checks The MsgSwapWithinBatch message performs validity checks. The transaction that is triggered with the `MsgSwapWithinBatch` message fails if: - if `params.CircuitBreakerEnabled` is true - `SwapRequester` address does not exist - `PoolId` does not exist - `SwapTypeId` does not exist - Denoms of `OfferCoin` or `DemandCoin` do not exist in `bank` module - The balance of `SwapRequester` does not have enough coins for `OfferCoin` - `OrderPrice` <= zero - `OfferCoinFee` equals `OfferCoin` * `params.SwapFeeRate` * `0.5` with ceiling - Has sufficient balance `OfferCoinFee` to reserve offer coin fee ================================================ FILE: x/liquidity/spec/05_begin_block.md ================================================ # Begin-Block Begin block operations for the liquidity module reinitialize batch messages that were not executed in the previous batch and delete batch messages that were executed or ready to be deleted. ## Delete pool batch messages and reset states for pool batch messages - Delete `{*action}MsgState` messages that have `ToBeDeleted` state - Reset states for the remaining `{*action}MsgState` messages to execute on `end-block` of the next batch index ## Reinitialize executed pool batch to next liquidity pool batch Reinitialize the executed `PoolBatch` for the next batch. The reinitialization process includes the following actions: - Increase state `BatchIndex` of the batch - Reset state `BeginHeight` as current block height - Reset state `Executed` as `false` ================================================ FILE: x/liquidity/spec/06_end_block.md ================================================ # Before-End-Block These operations occur before the end-block operations for the liquidity module. ## Append messages to LiquidityPoolBatch After successful message verification and coin `escrow` process, the incoming `MsgDepositWithinBatch`, `MsgWithdrawWithinBatch`, and `MsgSwapWithinBatch` messages are appended to the current `PoolBatch` of the corresponding `Pool`. # End-Block End-block operations for the Liquidity Module. ## Execute LiquidityPoolBatch upon execution heights If there are `{*action}MsgState` messages that have not yet executed in the `PoolBatch` for each `Pool`, the `PoolBatch` is executed. This batch contains one or more `DepositLiquidityPool`, `WithdrawLiquidityPool`, and `SwapExecution` processes. ### Transact and refund for each message A liquidity module escrow account holds coins temporarily and releases them when state changes. Refunds from the escrow account are made for cancellations, partial cancellations, expiration, and failed messages. ### Set states for each message according to the results After transact and refund transactions occur for each message, update the state of each `{*action}MsgState` message according to the results. Even if the message is completed or expired: 1. Set the `ToBeDeleted` state value as true instead of deleting the message directly from the `end-block` 2. Delete the messages that have `ToBeDeleted` state from the begin-block in the next block so that each message with result state in the block can be stored to kvstore. This process allows searching for the past messages that have this result state. Searching is supported when the kvstore is not pruning. ================================================ FILE: x/liquidity/spec/07_events.md ================================================ # Events The liquidity module emits the following events. ## Handlers ### MsgCreatePool Type | Attribute Key | Attribute Value ----------- | --------------- | ------------------------ create_pool | pool_id | {poolId} create_pool | pool_type_id | {poolTypeId} create_pool | pool_name | {AttributeValuePoolName} create_pool | reserve_account | {reserveAccountAddress} create_pool | deposit_coins | {depositCoins} create_pool | pool_coin_denom | {poolCoinDenom} message | module | liquidity message | action | create_pool message | sender | {senderAddress} ### MsgDepositWithinBatch Type | Attribute Key | Attribute Value -------------------- | ------------- | -------------------- deposit_within_batch | pool_id | {poolId} deposit_within_batch | batch_index | {batchIndex} deposit_within_batch | msg_index | {depositMsgIndex} deposit_within_batch | deposit_coins | {depositCoins} message | module | liquidity message | action | deposit_within_batch message | sender | {senderAddress} ### MsgWithdrawWithinBatch Type | Attribute Key | Attribute Value --------------------- | ---------------- | --------------------- withdraw_within_batch | pool_id | {poolId} withdraw_within_batch | batch_index | {batchIndex} withdraw_within_batch | msg_index | {withdrawMsgIndex} withdraw_within_batch | pool_coin_denom | {poolCoinDenom} withdraw_within_batch | pool_coin_amount | {poolCoinAmount} message | module | liquidity message | action | withdraw_within_batch message | sender | {senderAddress} ### MsgSwapWithinBatch Type | Attribute Key | Attribute Value ----------------- | ----------------- | ----------------- swap_within_batch | pool_id | {poolId} swap_within_batch | batch_index | {batchIndex} swap_within_batch | msg_index | {swapMsgIndex} swap_within_batch | swap_type_id | {swapTypeId} swap_within_batch | offer_coin_denom | {offerCoinDenom} swap_within_batch | offer_coin_amount | {offerCoinAmount} swap_within_batch | demand_coin_denom | {demandCoinDenom} swap_within_batch | order_price | {orderPrice} message | module | liquidity message | action | swap_within_batch message | sender | {senderAddress} ## EndBlocker ### Batch Result for MsgDepositWithinBatch Type | Attribute Key | Attribute Value --------------- | ---------------- | ------------------ deposit_to_pool | pool_id | {poolId} deposit_to_pool | batch_index | {batchIndex} deposit_to_pool | msg_index | {depositMsgIndex} deposit_to_pool | depositor | {depositorAddress} deposit_to_pool | accepted_coins | {acceptedCoins} deposit_to_pool | refunded_coins | {refundedCoins} deposit_to_pool | pool_coin_denom | {poolCoinDenom} deposit_to_pool | pool_coin_amount | {poolCoinAmount} deposit_to_pool | success | {success} ### Batch Result for MsgWithdrawWithinBatch | Type | Attribute Key | Attribute Value | | ------------------ | ------------------ | ------------------- | | withdraw_from_pool | pool_id | {poolId} | | withdraw_from_pool | batch_index | {batchIndex} | | withdraw_from_pool | msg_index | {withdrawMsgIndex} | | withdraw_from_pool | withdrawer | {withdrawerAddress} | | withdraw_from_pool | pool_coin_denom | {poolCoinDenom} | | withdraw_from_pool | pool_coin_amount | {poolCoinAmount} | | withdraw_from_pool | withdraw_coins | {withdrawCoins} | | withdraw_from_pool | withdraw_fee_coins | {withdrawFeeCoins} | | withdraw_from_pool | success | {success} | ### Batch Result for MsgSwapWithinBatch Type | Attribute Key | Attribute Value --------------- | ------------------------------ | ---------------------------- swap_transacted | pool_id | {poolId} swap_transacted | batch_index | {batchIndex} swap_transacted | msg_index | {swapMsgIndex} swap_transacted | swap_requester | {swapRequesterAddress} swap_transacted | swap_type_id | {swapTypeId} swap_transacted | offer_coin_denom | {offerCoinDenom} swap_transacted | offer_coin_amount | {offerCoinAmount} swap_transacted | exchanged_coin_denom | {exchangedCoinDenom} swap_transacted | order_price | {orderPrice} swap_transacted | swap_price | {swapPrice} swap_transacted | transacted_coin_amount | {transactedCoinAmount} swap_transacted | remaining_offer_coin_amount | {remainingOfferCoinAmount} swap_transacted | exchanged_offer_coin_amount | {exchangedOfferCoinAmount} swap_transacted | exchanged_demand_coin_amount | {exchangedDemandCoinAmount} swap_transacted | offer_coin_fee_amount | {offerCoinFeeAmount} swap_transacted | exchanged_coin_fee_amount | {exchangedCoinFeeAmount} swap_transacted | reserved_offer_coin_fee_amount | {reservedOfferCoinFeeAmount} swap_transacted | order_expiry_height | {orderExpiryHeight} swap_transacted | success | {success} ================================================ FILE: x/liquidity/spec/08_params.md ================================================ # Parameters The liquidity module contains the following parameters: Key | Type | Example ---------------------- | ---------------- | ------------------------------------------------------------------------------------------------------------------- PoolTypes | []PoolType | [{"id":1,"name":"StandardLiquidityPool","min_reserve_coin_num":2,"max_reserve_coin_num":2,"description":"Standard liquidity pool with pool price function X/Y, ESPM constraint, and two kinds of reserve coins"}] MinInitDepositAmount | string (math.Int) | "1000000" InitPoolCoinMintAmount | string (math.Int) | "1000000" MaxReserveCoinAmount | string (math.Int) | "0" PoolCreationFee | sdk.Coins | [{"denom":"stake","amount":"40000000"}] SwapFeeRate | string (sdk.Dec) | "0.003000000000000000" WithdrawFeeRate | string (sdk.Dec) | "0.000000000000000000" MaxOrderAmountRatio | string (sdk.Dec) | "0.100000000000000000" UnitBatchHeight | uint32 | 1 CircuitBreakerEnabled | bool | false ## PoolTypes List of available PoolType ```go type PoolType struct { Id uint32 Name string MinReserveCoinNum uint32 MaxReserveCoinNum uint32 Description string } ``` ## MinInitDepositAmount Minimum number of coins to be deposited to the liquidity pool upon pool creation. ## InitPoolCoinMintAmount Initial mint amount of pool coin on pool creation. ## MaxReserveCoinAmount Limit the size of each liquidity pool. The deposit transaction fails if the total reserve coin amount after the deposit is larger than the reserve coin amount. The default value of zero means no limit. **Note:** Especially in the early phases of liquidity module adoption, set `MaxReserveCoinAmount` to a non-zero value to minimize risk on error or exploitation. ## PoolCreationFee Fee paid for to create a LiquidityPool creation. This fee prevents spamming and is collected in the community pool of the distribution module. ## SwapFeeRate Swap fee rate for every executed swap. When a swap is requested, the swap fee is reserved: - Half reserved as `OfferCoinFee` - Half reserved as `ExchangedCoinFee` The swap fee is collected when a batch is executed. ## WithdrawFeeRate Reserve coin withdrawal with less proportion by `WithdrawFeeRate`. This fee prevents attack vectors from repeated deposit/withdraw transactions. ## MaxOrderAmountRatio Maximum ratio of reserve coins that can be ordered at a swap order. ## UnitBatchHeight The smallest unit batch size for every liquidity pool. ## CircuitBreakerEnabled The intention of circuit breaker is to have a contingency plan for a running network which maintains network liveness. This parameter enables or disables `MsgCreatePool`, `MsgDepositWithinBatch` and `MsgSwapWithinBatch` message types in liquidity module. # Constant Variables Key | Type | Constant Value ------------------- | ------ | -------------- CancelOrderLifeSpan | int64 | 0 MinReserveCoinNum | uint32 | 2 MaxReserveCoinNum | uint32 | 2 ## CancelOrderLifeSpan The life span of swap orders in block heights. ## MinReserveCoinNum, MaxReserveCoinNum The mininum and maximum number of reserveCoins for `PoolType`. ================================================ FILE: x/liquidity/spec/README.md ================================================ # `liquidity` ## Abstract This document specifies the liquidity module of the Cosmos SDK that serves AMM (Automated Market Makers) style decentralized liquidity providing and coin swap functions. The module enables you to create a liquidity pool with a pair of coins, deposit reserve coins into the pool to provide liquidity, request withdrawal from the pool, and trade coins using the liquidity pool. This module is available in the Cosmos Hub and can be used by other blockchains that are based on the Cosmos SDK. ## Contents 1. **[Concepts](01_concepts.md)** 2. **[State](02_state.md)** 3. **[State Transitions](03_state_transitions.md)** 4. **[Messages](04_messages.md)** 5. **[Begin-Block](05_begin_block.md)** 6. **[End-Block](06_end_block.md)** 7. **[Events](07_events.md)** 8. **[Parameters](08_params.md)** ## References - [Liquidity module proposal and milestone](https://github.com/b-harvest/Liquidity-Module-For-the-Hub) - [Cosmos SDK modules](https://github.com/cosmos/cosmos-sdk/tree/master/x) ================================================ FILE: x/liquidity/types/codec.go ================================================ package types import ( "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/codec/types" cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/msgservice" authzcodec "github.com/cosmos/cosmos-sdk/x/authz/codec" ) // RegisterLegacyAminoCodec registers concrete types on the codec. func RegisterLegacyAminoCodec(cdc *codec.LegacyAmino) { cdc.RegisterConcrete(&MsgCreatePool{}, "liquidity/MsgCreatePool", nil) cdc.RegisterConcrete(&MsgDepositWithinBatch{}, "liquidity/MsgDepositWithinBatch", nil) cdc.RegisterConcrete(&MsgWithdrawWithinBatch{}, "liquidity/MsgWithdrawWithinBatch", nil) cdc.RegisterConcrete(&MsgSwapWithinBatch{}, "liquidity/MsgSwapWithinBatch", nil) } // RegisterInterfaces registers the x/liquidity interface types with the // interface registry func RegisterInterfaces(registry types.InterfaceRegistry) { registry.RegisterCustomTypeURL((*sdk.Msg)(nil), "/tendermint.liquidity.v1beta1.MsgCreatePool", &MsgCreatePool{}) registry.RegisterCustomTypeURL((*sdk.Msg)(nil), "/tendermint.liquidity.v1beta1.MsgDepositWithinBatch", &MsgDepositWithinBatch{}) registry.RegisterCustomTypeURL((*sdk.Msg)(nil), "/tendermint.liquidity.v1beta1.MsgWithdrawWithinBatch", &MsgWithdrawWithinBatch{}) registry.RegisterCustomTypeURL((*sdk.Msg)(nil), "/tendermint.liquidity.v1beta1.MsgSwapWithinBatch", &MsgSwapWithinBatch{}) registry.RegisterImplementations((*sdk.Msg)(nil), &MsgCreatePool{}, &MsgDepositWithinBatch{}, &MsgWithdrawWithinBatch{}, &MsgSwapWithinBatch{}, ) msgservice.RegisterMsgServiceDesc(registry, &_Msg_serviceDesc) } // legacy amino codecs var ( amino = codec.NewLegacyAmino() // ModuleCdc references the global x/liquidity module codec. Note, the // codec should ONLY be used in certain instances of tests and for JSON // encoding as Amino is still used for that purpose. // // The actual codec used for serialization should be provided to x/liquidity // and defined at the application level. ModuleCdc = codec.NewAminoCodec(amino) ) func init() { RegisterLegacyAminoCodec(amino) cryptocodec.RegisterCrypto(amino) // Register all Amino interfaces and concrete types on the authz Amino codec so that this can later be // used to properly serialize MsgGrant and MsgExec instances sdk.RegisterLegacyAminoCodec(amino) RegisterLegacyAminoCodec(authzcodec.Amino) amino.Seal() } ================================================ FILE: x/liquidity/types/codec_test.go ================================================ package types import ( "testing" "github.com/stretchr/testify/suite" codectypes "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" ) type CodecTestSuite struct { suite.Suite } func TestCodecSuite(t *testing.T) { suite.Run(t, new(CodecTestSuite)) } func (suite *CodecTestSuite) TestRegisterInterfaces() { registry := codectypes.NewInterfaceRegistry() registry.RegisterInterface(sdk.MsgInterfaceProtoName, (*sdk.Msg)(nil)) RegisterInterfaces(registry) impls := registry.ListImplementations(sdk.MsgInterfaceProtoName) suite.Require().Equal(8, len(impls)) //suite.Require().ElementsMatch([]string{ // "/osmosis.tokenfactory.v1beta1.MsgCreateDenom", // "/osmosis.tokenfactory.v1beta1.MsgMint", // "/osmosis.tokenfactory.v1beta1.MsgBurn", // "/osmosis.tokenfactory.v1beta1.MsgChangeAdmin", // "/osmosis.tokenfactory.v1beta1.MsgSetDenomMetadata", // "/osmosis.tokenfactory.v1beta1.MsgForceTransfer", // "/osmosis.tokenfactory.v1beta1.MsgUpdateParams", //}, impls) } ================================================ FILE: x/liquidity/types/errors.go ================================================ package types import ( sdkerrors "cosmossdk.io/errors" ) // liquidity module sentinel errors var ( ErrPoolNotExists = sdkerrors.Register(ModuleName, 1, "pool not exists") ErrPoolTypeNotExists = sdkerrors.Register(ModuleName, 2, "pool type not exists") ErrEqualDenom = sdkerrors.Register(ModuleName, 3, "reserve coin denomination are equal") ErrInvalidDenom = sdkerrors.Register(ModuleName, 4, "invalid denom") ErrNumOfReserveCoin = sdkerrors.Register(ModuleName, 5, "invalid number of reserve coin") ErrNumOfPoolCoin = sdkerrors.Register(ModuleName, 6, "invalid number of pool coin") ErrInsufficientPool = sdkerrors.Register(ModuleName, 7, "insufficient pool") ErrInsufficientBalance = sdkerrors.Register(ModuleName, 8, "insufficient coin balance") ErrLessThanMinInitDeposit = sdkerrors.Register(ModuleName, 9, "deposit coin less than MinInitDepositAmount") ErrNotImplementedYet = sdkerrors.Register(ModuleName, 10, "not implemented yet") ErrPoolAlreadyExists = sdkerrors.Register(ModuleName, 11, "the pool already exists") ErrPoolBatchNotExists = sdkerrors.Register(ModuleName, 12, "pool batch not exists") ErrOrderBookInvalidity = sdkerrors.Register(ModuleName, 13, "orderbook is not validity") ErrBatchNotExecuted = sdkerrors.Register(ModuleName, 14, "the liquidity pool batch is not executed") ErrInvalidPoolCreatorAddr = sdkerrors.Register(ModuleName, 15, "invalid pool creator address") ErrInvalidDepositorAddr = sdkerrors.Register(ModuleName, 16, "invalid pool depositor address") ErrInvalidWithdrawerAddr = sdkerrors.Register(ModuleName, 17, "invalid pool withdrawer address") ErrInvalidSwapRequesterAddr = sdkerrors.Register(ModuleName, 18, "invalid pool swap requester address") ErrBadPoolCoinAmount = sdkerrors.Register(ModuleName, 19, "invalid pool coin amount") ErrBadDepositCoinsAmount = sdkerrors.Register(ModuleName, 20, "invalid deposit coins amount") ErrBadOfferCoinAmount = sdkerrors.Register(ModuleName, 21, "invalid offer coin amount") ErrBadOrderingReserveCoin = sdkerrors.Register(ModuleName, 22, "reserve coin denoms not ordered alphabetical") ErrBadOrderPrice = sdkerrors.Register(ModuleName, 23, "invalid order price") ErrNumOfReserveCoinDenoms = sdkerrors.Register(ModuleName, 24, "invalid reserve coin denoms") ErrEmptyReserveAccountAddress = sdkerrors.Register(ModuleName, 25, "empty reserve account address") ErrEmptyPoolCoinDenom = sdkerrors.Register(ModuleName, 26, "empty pool coin denom") ErrBadOrderingReserveCoinDenoms = sdkerrors.Register(ModuleName, 27, "bad ordering reserve coin denoms") ErrBadReserveAccountAddress = sdkerrors.Register(ModuleName, 28, "bad reserve account address") ErrBadPoolCoinDenom = sdkerrors.Register(ModuleName, 29, "bad pool coin denom") ErrInsufficientPoolCreationFee = sdkerrors.Register(ModuleName, 30, "insufficient balances for pool creation fee") ErrExceededMaxOrderable = sdkerrors.Register(ModuleName, 31, "can not exceed max order ratio of reserve coins that can be ordered at a order") ErrBadBatchMsgIndex = sdkerrors.Register(ModuleName, 32, "bad msg index of the batch") ErrSwapTypeNotExists = sdkerrors.Register(ModuleName, 33, "swap type not exists") ErrLessThanMinOfferAmount = sdkerrors.Register(ModuleName, 34, "offer amount should be over 100 micro") ErrBadOfferCoinFee = sdkerrors.Register(ModuleName, 35, "bad offer coin fee") ErrNotMatchedReserveCoin = sdkerrors.Register(ModuleName, 36, "does not match the reserve coin of the pool") ErrBadPoolTypeID = sdkerrors.Register(ModuleName, 37, "invalid index of the pool type") ErrExceededReserveCoinLimit = sdkerrors.Register(ModuleName, 38, "can not exceed reserve coin limit amount") ErrDepletedPool = sdkerrors.Register(ModuleName, 39, "the pool is depleted of reserve coin, reinitializing is required by deposit") ErrCircuitBreakerEnabled = sdkerrors.Register(ModuleName, 40, "circuit breaker is triggered") ErrOverflowAmount = sdkerrors.Register(ModuleName, 41, "invalid amount that can cause overflow") ) ================================================ FILE: x/liquidity/types/events.go ================================================ package types // Event types for the liquidity module. const ( EventTypeCreatePool = TypeMsgCreatePool EventTypeDepositWithinBatch = TypeMsgDepositWithinBatch EventTypeWithdrawWithinBatch = TypeMsgWithdrawWithinBatch EventTypeSwapWithinBatch = TypeMsgSwapWithinBatch EventTypeDepositToPool = "deposit_to_pool" EventTypeWithdrawFromPool = "withdraw_from_pool" EventTypeSwapTransacted = "swap_transacted" AttributeValuePoolId = "pool_id" //nolint:revive AttributeValuePoolTypeId = "pool_type_id" //nolint:revive AttributeValuePoolName = "pool_name" AttributeValueReserveAccount = "reserve_account" AttributeValuePoolCoinDenom = "pool_coin_denom" AttributeValuePoolCoinAmount = "pool_coin_amount" AttributeValueBatchIndex = "batch_index" AttributeValueMsgIndex = "msg_index" AttributeValueDepositCoins = "deposit_coins" AttributeValueOfferCoinDenom = "offer_coin_denom" AttributeValueOfferCoinAmount = "offer_coin_amount" AttributeValueOfferCoinFeeAmount = "offer_coin_fee_amount" AttributeValueExchangedCoinFeeAmount = "exchanged_coin_fee_amount" AttributeValueDemandCoinDenom = "demand_coin_denom" AttributeValueOrderPrice = "order_price" AttributeValueDepositor = "depositor" AttributeValueRefundedCoins = "refunded_coins" AttributeValueAcceptedCoins = "accepted_coins" AttributeValueSuccess = "success" AttributeValueWithdrawer = "withdrawer" AttributeValueWithdrawCoins = "withdraw_coins" AttributeValueWithdrawFeeCoins = "withdraw_fee_coins" AttributeValueSwapRequester = "swap_requester" AttributeValueSwapTypeId = "swap_type_id" //nolint:revive AttributeValueSwapPrice = "swap_price" AttributeValueTransactedCoinAmount = "transacted_coin_amount" AttributeValueRemainingOfferCoinAmount = "remaining_offer_coin_amount" AttributeValueExchangedOfferCoinAmount = "exchanged_offer_coin_amount" AttributeValueExchangedDemandCoinAmount = "exchanged_demand_coin_amount" AttributeValueReservedOfferCoinFeeAmount = "reserved_offer_coin_fee_amount" AttributeValueOrderExpiryHeight = "order_expiry_height" AttributeValueCategory = ModuleName Success = "success" Failure = "failure" ) ================================================ FILE: x/liquidity/types/expected_keepers.go ================================================ package types import ( sdk "github.com/cosmos/cosmos-sdk/types" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" ) // BankKeeper defines the expected bank send keeper type BankKeeper interface { InputOutputCoins(ctx sdk.Context, inputs []banktypes.Input, outputs []banktypes.Output) error SendCoins(ctx sdk.Context, fromAddr sdk.AccAddress, toAddr sdk.AccAddress, amt sdk.Coins) error GetAllBalances(ctx sdk.Context, addr sdk.AccAddress) sdk.Coins GetBalance(ctx sdk.Context, addr sdk.AccAddress, denom string) sdk.Coin SpendableCoins(ctx sdk.Context, addr sdk.AccAddress) sdk.Coins GetSupply(ctx sdk.Context, denom string) sdk.Coin SendCoinsFromModuleToAccount(ctx sdk.Context, senderModule string, recipientAddr sdk.AccAddress, amt sdk.Coins) error SendCoinsFromAccountToModule(ctx sdk.Context, senderAddr sdk.AccAddress, recipientModule string, amt sdk.Coins) error BurnCoins(ctx sdk.Context, name string, amt sdk.Coins) error MintCoins(ctx sdk.Context, name string, amt sdk.Coins) error } // AccountKeeper defines the expected account keeper type AccountKeeper interface { GetAccount(ctx sdk.Context, addr sdk.AccAddress) authtypes.AccountI GetModuleAddress(name string) sdk.AccAddress } // DistributionKeeper defines the expected distribution keeper type DistributionKeeper interface { FundCommunityPool(ctx sdk.Context, amount sdk.Coins, sender sdk.AccAddress) error } ================================================ FILE: x/liquidity/types/genesis.go ================================================ package types // NewGenesisState returns new GenesisState. func NewGenesisState(params Params, liquidityPoolRecords []PoolRecord) *GenesisState { return &GenesisState{ Params: params, PoolRecords: liquidityPoolRecords, } } // DefaultGenesisState returns the default genesis state. func DefaultGenesisState() *GenesisState { return NewGenesisState(DefaultParams(), []PoolRecord{}) } // ValidateGenesis validates GenesisState. func ValidateGenesis(data GenesisState) error { if err := data.Params.Validate(); err != nil { return err } for _, record := range data.PoolRecords { if err := record.Validate(); err != nil { return err } } return nil } // Validate validates PoolRecord. func (record PoolRecord) Validate() error { if record.PoolBatch.DepositMsgIndex == 0 || (len(record.DepositMsgStates) > 0 && record.PoolBatch.DepositMsgIndex != record.DepositMsgStates[len(record.DepositMsgStates)-1].MsgIndex+1) { return ErrBadBatchMsgIndex } if record.PoolBatch.WithdrawMsgIndex == 0 || (len(record.WithdrawMsgStates) != 0 && record.PoolBatch.WithdrawMsgIndex != record.WithdrawMsgStates[len(record.WithdrawMsgStates)-1].MsgIndex+1) { return ErrBadBatchMsgIndex } if record.PoolBatch.SwapMsgIndex == 0 || (len(record.SwapMsgStates) != 0 && record.PoolBatch.SwapMsgIndex != record.SwapMsgStates[len(record.SwapMsgStates)-1].MsgIndex+1) { return ErrBadBatchMsgIndex } return nil } ================================================ FILE: x/liquidity/types/genesis.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: cyber/liquidity/v1beta1/genesis.proto package types import ( fmt "fmt" io "io" math "math" math_bits "math/bits" _ "github.com/cosmos/gogoproto/gogoproto" proto "github.com/cosmos/gogoproto/proto" ) // Reference imports to suppress errors if they are not otherwise used. var ( _ = proto.Marshal _ = fmt.Errorf _ = math.Inf ) // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package // records the state of each pool after genesis export or import, used to check // variables type PoolRecord struct { Pool Pool `protobuf:"bytes,1,opt,name=pool,proto3" json:"pool" yaml:"pool"` PoolMetadata PoolMetadata `protobuf:"bytes,2,opt,name=pool_metadata,json=poolMetadata,proto3" json:"pool_metadata" yaml:"pool_metadata"` PoolBatch PoolBatch `protobuf:"bytes,3,opt,name=pool_batch,json=poolBatch,proto3" json:"pool_batch" yaml:"pool_batch"` DepositMsgStates []DepositMsgState `protobuf:"bytes,4,rep,name=deposit_msg_states,json=depositMsgStates,proto3" json:"deposit_msg_states" yaml:"deposit_msg_states"` WithdrawMsgStates []WithdrawMsgState `protobuf:"bytes,5,rep,name=withdraw_msg_states,json=withdrawMsgStates,proto3" json:"withdraw_msg_states" yaml:"withdraw_msg_states"` SwapMsgStates []SwapMsgState `protobuf:"bytes,6,rep,name=swap_msg_states,json=swapMsgStates,proto3" json:"swap_msg_states" yaml:"swap_msg_states"` } func (m *PoolRecord) Reset() { *m = PoolRecord{} } func (m *PoolRecord) String() string { return proto.CompactTextString(m) } func (*PoolRecord) ProtoMessage() {} func (*PoolRecord) Descriptor() ([]byte, []int) { return fileDescriptor_84edef6e81b0c617, []int{0} } func (m *PoolRecord) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *PoolRecord) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_PoolRecord.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *PoolRecord) XXX_Merge(src proto.Message) { xxx_messageInfo_PoolRecord.Merge(m, src) } func (m *PoolRecord) XXX_Size() int { return m.Size() } func (m *PoolRecord) XXX_DiscardUnknown() { xxx_messageInfo_PoolRecord.DiscardUnknown(m) } var xxx_messageInfo_PoolRecord proto.InternalMessageInfo func (m *PoolRecord) GetPool() Pool { if m != nil { return m.Pool } return Pool{} } func (m *PoolRecord) GetPoolMetadata() PoolMetadata { if m != nil { return m.PoolMetadata } return PoolMetadata{} } func (m *PoolRecord) GetPoolBatch() PoolBatch { if m != nil { return m.PoolBatch } return PoolBatch{} } func (m *PoolRecord) GetDepositMsgStates() []DepositMsgState { if m != nil { return m.DepositMsgStates } return nil } func (m *PoolRecord) GetWithdrawMsgStates() []WithdrawMsgState { if m != nil { return m.WithdrawMsgStates } return nil } func (m *PoolRecord) GetSwapMsgStates() []SwapMsgState { if m != nil { return m.SwapMsgStates } return nil } // GenesisState defines the liquidity module's genesis state. type GenesisState struct { // params defines all the parameters for the liquidity module. Params Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params"` PoolRecords []PoolRecord `protobuf:"bytes,2,rep,name=pool_records,json=poolRecords,proto3" json:"pool_records" yaml:"pools"` } func (m *GenesisState) Reset() { *m = GenesisState{} } func (m *GenesisState) String() string { return proto.CompactTextString(m) } func (*GenesisState) ProtoMessage() {} func (*GenesisState) Descriptor() ([]byte, []int) { return fileDescriptor_84edef6e81b0c617, []int{1} } func (m *GenesisState) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *GenesisState) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_GenesisState.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *GenesisState) XXX_Merge(src proto.Message) { xxx_messageInfo_GenesisState.Merge(m, src) } func (m *GenesisState) XXX_Size() int { return m.Size() } func (m *GenesisState) XXX_DiscardUnknown() { xxx_messageInfo_GenesisState.DiscardUnknown(m) } var xxx_messageInfo_GenesisState proto.InternalMessageInfo func init() { proto.RegisterType((*PoolRecord)(nil), "cyber.liquidity.v1beta1.PoolRecord") proto.RegisterType((*GenesisState)(nil), "cyber.liquidity.v1beta1.GenesisState") } func init() { proto.RegisterFile("cyber/liquidity/v1beta1/genesis.proto", fileDescriptor_84edef6e81b0c617) } var fileDescriptor_84edef6e81b0c617 = []byte{ // 503 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x7c, 0x93, 0x41, 0x6b, 0xd4, 0x4e, 0x18, 0xc6, 0x93, 0x76, 0xbb, 0xfc, 0xff, 0xb3, 0x5b, 0xb4, 0xd3, 0x45, 0xb7, 0x8b, 0x26, 0x75, 0xa4, 0xb8, 0x1e, 0x4c, 0x68, 0x7b, 0x2b, 0x78, 0x09, 0xa2, 0xa7, 0x05, 0x49, 0x0f, 0x82, 0x14, 0x96, 0x49, 0x32, 0x64, 0x03, 0x9b, 0xce, 0x98, 0x77, 0x6a, 0xcc, 0xc1, 0xa3, 0xe0, 0xd1, 0x8f, 0xd0, 0x2f, 0xe1, 0x77, 0xe8, 0xb1, 0x47, 0x4f, 0x45, 0x76, 0x2f, 0x9e, 0xfd, 0x04, 0x92, 0xc9, 0x98, 0x8d, 0xd5, 0xec, 0x29, 0xc3, 0xe4, 0x79, 0x9e, 0xdf, 0x0b, 0xf3, 0xbc, 0xe8, 0x20, 0x2c, 0x02, 0x96, 0xb9, 0xf3, 0xe4, 0xdd, 0x45, 0x12, 0x25, 0xb2, 0x70, 0xdf, 0x1f, 0x06, 0x4c, 0xd2, 0x43, 0x37, 0x66, 0xe7, 0x0c, 0x12, 0x70, 0x44, 0xc6, 0x25, 0xc7, 0xf7, 0x95, 0xcc, 0xa9, 0x65, 0x8e, 0x96, 0x8d, 0x9e, 0xb4, 0xf9, 0x57, 0x52, 0x95, 0x30, 0x1a, 0xc4, 0x3c, 0xe6, 0xea, 0xe8, 0x96, 0xa7, 0xea, 0x96, 0x7c, 0xda, 0x42, 0xe8, 0x35, 0xe7, 0x73, 0x9f, 0x85, 0x3c, 0x8b, 0xf0, 0x4b, 0xd4, 0x11, 0x9c, 0xcf, 0x87, 0xe6, 0xbe, 0x39, 0xee, 0x1d, 0x3d, 0x74, 0x5a, 0xa8, 0x4e, 0x69, 0xf1, 0x76, 0xaf, 0x6e, 0x6c, 0xe3, 0xe7, 0x8d, 0xdd, 0x2b, 0x68, 0x3a, 0x3f, 0x21, 0xa5, 0x91, 0xf8, 0xca, 0x8f, 0x67, 0x68, 0xbb, 0xfc, 0x4e, 0x53, 0x26, 0x69, 0x44, 0x25, 0x1d, 0x6e, 0xa8, 0xc0, 0x83, 0xb5, 0x81, 0x13, 0x2d, 0xf6, 0x1e, 0xe8, 0xe0, 0xc1, 0x2a, 0xb8, 0x4e, 0x22, 0x7e, 0x5f, 0x34, 0xb4, 0xf8, 0x0c, 0x21, 0xf5, 0x3f, 0xa0, 0x32, 0x9c, 0x0d, 0x37, 0x15, 0x86, 0xac, 0x9f, 0xbb, 0x54, 0x7a, 0x7b, 0x9a, 0xb1, 0xd3, 0x60, 0xa8, 0x0c, 0xe2, 0xff, 0x2f, 0x7e, 0xab, 0x70, 0x81, 0x70, 0xc4, 0x04, 0x87, 0x44, 0x4e, 0x53, 0x88, 0xa7, 0x20, 0xa9, 0x64, 0x30, 0xec, 0xec, 0x6f, 0x8e, 0x7b, 0x47, 0xe3, 0x56, 0xca, 0x8b, 0xca, 0x32, 0x81, 0xf8, 0xb4, 0x34, 0x78, 0x8f, 0x34, 0x6b, 0xaf, 0x62, 0xfd, 0x9d, 0x48, 0xfc, 0xbb, 0xd1, 0x9f, 0x1e, 0xc0, 0x1f, 0xd1, 0x6e, 0x9e, 0xc8, 0x59, 0x94, 0xd1, 0xbc, 0xc9, 0xde, 0x52, 0xec, 0xa7, 0xad, 0xec, 0x37, 0xda, 0x53, 0xc3, 0x89, 0x86, 0x8f, 0x2a, 0xf8, 0x3f, 0x32, 0x89, 0xbf, 0x93, 0xdf, 0x72, 0x01, 0x4e, 0xd1, 0x1d, 0xc8, 0xa9, 0x68, 0xa2, 0xbb, 0x0a, 0xdd, 0xfe, 0x86, 0xa7, 0x39, 0x15, 0x35, 0xd6, 0xd2, 0xd8, 0x7b, 0x15, 0xf6, 0x56, 0x16, 0xf1, 0xb7, 0xa1, 0xa1, 0x06, 0xf2, 0xd5, 0x44, 0xfd, 0x57, 0x55, 0xe3, 0xd5, 0x0d, 0x7e, 0x8e, 0xba, 0x82, 0x66, 0x34, 0x05, 0xdd, 0x45, 0xbb, 0xfd, 0x4d, 0x95, 0xcc, 0xeb, 0x94, 0x40, 0x5f, 0x9b, 0xf0, 0x19, 0x52, 0x35, 0x99, 0x66, 0xaa, 0xd7, 0x30, 0xdc, 0x50, 0xb3, 0x3f, 0x5e, 0x5b, 0x8c, 0x6a, 0x07, 0xbc, 0x81, 0x9e, 0xbc, 0xbf, 0x6a, 0x06, 0x10, 0xbf, 0x27, 0x6a, 0x05, 0x9c, 0xfc, 0xf7, 0xf9, 0xd2, 0x36, 0x7e, 0x5c, 0xda, 0x86, 0x37, 0xb9, 0x5a, 0x58, 0xe6, 0xf5, 0xc2, 0x32, 0xbf, 0x2f, 0x2c, 0xf3, 0xcb, 0xd2, 0x32, 0xae, 0x97, 0x96, 0xf1, 0x6d, 0x69, 0x19, 0x6f, 0x8f, 0xe3, 0x44, 0xce, 0x2e, 0x02, 0x27, 0xe4, 0xa9, 0xab, 0xa8, 0x21, 0x3f, 0x8f, 0x33, 0x06, 0xe0, 0xc6, 0xfc, 0x59, 0xb5, 0xb4, 0x1f, 0x1a, 0x6b, 0x2b, 0x0b, 0xc1, 0x20, 0xe8, 0xaa, 0xad, 0x3c, 0xfe, 0x15, 0x00, 0x00, 0xff, 0xff, 0x5f, 0x85, 0x58, 0xc8, 0x16, 0x04, 0x00, 0x00, } func (m *PoolRecord) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *PoolRecord) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *PoolRecord) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.SwapMsgStates) > 0 { for iNdEx := len(m.SwapMsgStates) - 1; iNdEx >= 0; iNdEx-- { { size, err := m.SwapMsgStates[iNdEx].MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintGenesis(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x32 } } if len(m.WithdrawMsgStates) > 0 { for iNdEx := len(m.WithdrawMsgStates) - 1; iNdEx >= 0; iNdEx-- { { size, err := m.WithdrawMsgStates[iNdEx].MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintGenesis(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x2a } } if len(m.DepositMsgStates) > 0 { for iNdEx := len(m.DepositMsgStates) - 1; iNdEx >= 0; iNdEx-- { { size, err := m.DepositMsgStates[iNdEx].MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintGenesis(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x22 } } { size, err := m.PoolBatch.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintGenesis(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x1a { size, err := m.PoolMetadata.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintGenesis(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 { size, err := m.Pool.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintGenesis(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa return len(dAtA) - i, nil } func (m *GenesisState) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *GenesisState) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *GenesisState) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.PoolRecords) > 0 { for iNdEx := len(m.PoolRecords) - 1; iNdEx >= 0; iNdEx-- { { size, err := m.PoolRecords[iNdEx].MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintGenesis(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 } } { size, err := m.Params.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintGenesis(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa return len(dAtA) - i, nil } func encodeVarintGenesis(dAtA []byte, offset int, v uint64) int { offset -= sovGenesis(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *PoolRecord) Size() (n int) { if m == nil { return 0 } var l int _ = l l = m.Pool.Size() n += 1 + l + sovGenesis(uint64(l)) l = m.PoolMetadata.Size() n += 1 + l + sovGenesis(uint64(l)) l = m.PoolBatch.Size() n += 1 + l + sovGenesis(uint64(l)) if len(m.DepositMsgStates) > 0 { for _, e := range m.DepositMsgStates { l = e.Size() n += 1 + l + sovGenesis(uint64(l)) } } if len(m.WithdrawMsgStates) > 0 { for _, e := range m.WithdrawMsgStates { l = e.Size() n += 1 + l + sovGenesis(uint64(l)) } } if len(m.SwapMsgStates) > 0 { for _, e := range m.SwapMsgStates { l = e.Size() n += 1 + l + sovGenesis(uint64(l)) } } return n } func (m *GenesisState) Size() (n int) { if m == nil { return 0 } var l int _ = l l = m.Params.Size() n += 1 + l + sovGenesis(uint64(l)) if len(m.PoolRecords) > 0 { for _, e := range m.PoolRecords { l = e.Size() n += 1 + l + sovGenesis(uint64(l)) } } return n } func sovGenesis(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozGenesis(x uint64) (n int) { return sovGenesis(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *PoolRecord) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenesis } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: PoolRecord: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: PoolRecord: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Pool", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenesis } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthGenesis } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenesis } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Pool.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field PoolMetadata", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenesis } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthGenesis } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenesis } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.PoolMetadata.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 3: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field PoolBatch", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenesis } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthGenesis } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenesis } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.PoolBatch.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 4: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field DepositMsgStates", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenesis } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthGenesis } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenesis } if postIndex > l { return io.ErrUnexpectedEOF } m.DepositMsgStates = append(m.DepositMsgStates, DepositMsgState{}) if err := m.DepositMsgStates[len(m.DepositMsgStates)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 5: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field WithdrawMsgStates", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenesis } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthGenesis } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenesis } if postIndex > l { return io.ErrUnexpectedEOF } m.WithdrawMsgStates = append(m.WithdrawMsgStates, WithdrawMsgState{}) if err := m.WithdrawMsgStates[len(m.WithdrawMsgStates)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 6: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field SwapMsgStates", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenesis } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthGenesis } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenesis } if postIndex > l { return io.ErrUnexpectedEOF } m.SwapMsgStates = append(m.SwapMsgStates, SwapMsgState{}) if err := m.SwapMsgStates[len(m.SwapMsgStates)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipGenesis(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthGenesis } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *GenesisState) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenesis } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: GenesisState: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: GenesisState: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenesis } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthGenesis } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenesis } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Params.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field PoolRecords", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenesis } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthGenesis } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenesis } if postIndex > l { return io.ErrUnexpectedEOF } m.PoolRecords = append(m.PoolRecords, PoolRecord{}) if err := m.PoolRecords[len(m.PoolRecords)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipGenesis(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthGenesis } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipGenesis(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowGenesis } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowGenesis } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowGenesis } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthGenesis } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupGenesis } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthGenesis } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthGenesis = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowGenesis = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupGenesis = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/liquidity/types/keys.go ================================================ package types import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/address" ) const ( // ModuleName is the name of the liquidity module ModuleName = "liquidity" // RouterKey is the message router key for the liquidity module RouterKey = ModuleName // StoreKey is the default store key for the liquidity module StoreKey = ModuleName // PoolCoinDenomPrefix is the prefix used for liquidity pool coin representation PoolCoinDenomPrefix = "pool" ) var ( // param key for global Liquidity Pool IDs GlobalLiquidityPoolIDKey = []byte("globalLiquidityPoolId") ParamsKey = []byte{0x01} PoolKeyPrefix = []byte{0x11} PoolByReserveAccIndexKeyPrefix = []byte{0x12} PoolBatchKeyPrefix = []byte{0x22} PoolBatchDepositMsgStateIndexKeyPrefix = []byte{0x31} PoolBatchWithdrawMsgStateIndexKeyPrefix = []byte{0x32} PoolBatchSwapMsgStateIndexKeyPrefix = []byte{0x33} ) // GetPoolKey returns kv indexing key of the pool func GetPoolKey(poolID uint64) []byte { key := make([]byte, 9) key[0] = PoolKeyPrefix[0] copy(key[1:], sdk.Uint64ToBigEndian(poolID)) return key } // GetPoolByReserveAccIndexKey returns kv indexing key of the pool indexed by reserve account func GetPoolByReserveAccIndexKey(reserveAcc sdk.AccAddress) []byte { return append(PoolByReserveAccIndexKeyPrefix, address.MustLengthPrefix(reserveAcc.Bytes())...) } // GetPoolBatchKey returns kv indexing key of the pool batch indexed by pool id func GetPoolBatchKey(poolID uint64) []byte { key := make([]byte, 9) key[0] = PoolBatchKeyPrefix[0] copy(key[1:9], sdk.Uint64ToBigEndian(poolID)) return key } // GetPoolBatchDepositMsgStatesPrefix returns prefix of deposit message states in the pool's latest batch for iteration func GetPoolBatchDepositMsgStatesPrefix(poolID uint64) []byte { key := make([]byte, 9) key[0] = PoolBatchDepositMsgStateIndexKeyPrefix[0] copy(key[1:9], sdk.Uint64ToBigEndian(poolID)) return key } // GetPoolBatchWithdrawMsgsPrefix returns prefix of withdraw message states in the pool's latest batch for iteration func GetPoolBatchWithdrawMsgsPrefix(poolID uint64) []byte { key := make([]byte, 9) key[0] = PoolBatchWithdrawMsgStateIndexKeyPrefix[0] copy(key[1:9], sdk.Uint64ToBigEndian(poolID)) return key } // GetPoolBatchSwapMsgStatesPrefix returns prefix of swap message states in the pool's latest batch for iteration func GetPoolBatchSwapMsgStatesPrefix(poolID uint64) []byte { key := make([]byte, 9) key[0] = PoolBatchSwapMsgStateIndexKeyPrefix[0] copy(key[1:9], sdk.Uint64ToBigEndian(poolID)) return key } // GetPoolBatchDepositMsgStateIndexKey returns kv indexing key of the latest index value of the msg index func GetPoolBatchDepositMsgStateIndexKey(poolID, msgIndex uint64) []byte { key := make([]byte, 17) key[0] = PoolBatchDepositMsgStateIndexKeyPrefix[0] copy(key[1:9], sdk.Uint64ToBigEndian(poolID)) copy(key[9:17], sdk.Uint64ToBigEndian(msgIndex)) return key } // GetPoolBatchWithdrawMsgStateIndexKey returns kv indexing key of the latest index value of the msg index func GetPoolBatchWithdrawMsgStateIndexKey(poolID, msgIndex uint64) []byte { key := make([]byte, 17) key[0] = PoolBatchWithdrawMsgStateIndexKeyPrefix[0] copy(key[1:9], sdk.Uint64ToBigEndian(poolID)) copy(key[9:17], sdk.Uint64ToBigEndian(msgIndex)) return key } // GetPoolBatchSwapMsgStateIndexKey returns kv indexing key of the latest index value of the msg index func GetPoolBatchSwapMsgStateIndexKey(poolID, msgIndex uint64) []byte { key := make([]byte, 17) key[0] = PoolBatchSwapMsgStateIndexKeyPrefix[0] copy(key[1:9], sdk.Uint64ToBigEndian(poolID)) copy(key[9:17], sdk.Uint64ToBigEndian(msgIndex)) return key } ================================================ FILE: x/liquidity/types/liquidity.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: cyber/liquidity/v1beta1/liquidity.proto package types import ( fmt "fmt" io "io" math "math" math_bits "math/bits" _ "github.com/cosmos/cosmos-proto" github_com_cosmos_cosmos_sdk_types "github.com/cosmos/cosmos-sdk/types" types "github.com/cosmos/cosmos-sdk/types" _ "github.com/cosmos/gogoproto/gogoproto" proto "github.com/cosmos/gogoproto/proto" ) // Reference imports to suppress errors if they are not otherwise used. var ( _ = proto.Marshal _ = fmt.Errorf _ = math.Inf ) // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package // Structure for the pool type to distinguish the characteristics of the reserve // pools. type PoolType struct { // This is the id of the pool_type that is used as pool_type_id for pool // creation. In this version, only pool-type-id 1 is supported. // {"id":1,"name":"ConstantProductLiquidityPool","min_reserve_coin_num":2,"max_reserve_coin_num":2,"description":""} Id uint32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty" yaml:"id"` // name of the pool type. Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty" yaml:"name"` // minimum number of reserveCoins for LiquidityPoolType, only 2 reserve coins // are supported. MinReserveCoinNum uint32 `protobuf:"varint,3,opt,name=min_reserve_coin_num,json=minReserveCoinNum,proto3" json:"min_reserve_coin_num,omitempty" yaml:"min_reserve_coin_num"` // maximum number of reserveCoins for LiquidityPoolType, only 2 reserve coins // are supported. MaxReserveCoinNum uint32 `protobuf:"varint,4,opt,name=max_reserve_coin_num,json=maxReserveCoinNum,proto3" json:"max_reserve_coin_num,omitempty" yaml:"max_reserve_coin_num"` // description of the pool type. Description string `protobuf:"bytes,5,opt,name=description,proto3" json:"description,omitempty" yaml:"description"` } func (m *PoolType) Reset() { *m = PoolType{} } func (m *PoolType) String() string { return proto.CompactTextString(m) } func (*PoolType) ProtoMessage() {} func (*PoolType) Descriptor() ([]byte, []int) { return fileDescriptor_67b6d59e96092d89, []int{0} } func (m *PoolType) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *PoolType) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_PoolType.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *PoolType) XXX_Merge(src proto.Message) { xxx_messageInfo_PoolType.Merge(m, src) } func (m *PoolType) XXX_Size() int { return m.Size() } func (m *PoolType) XXX_DiscardUnknown() { xxx_messageInfo_PoolType.DiscardUnknown(m) } var xxx_messageInfo_PoolType proto.InternalMessageInfo // Params defines the parameters for the liquidity module. type Params struct { // list of available pool types PoolTypes []PoolType `protobuf:"bytes,1,rep,name=pool_types,json=poolTypes,proto3" json:"pool_types" yaml:"pool_types"` // Minimum number of coins to be deposited to the liquidity pool on pool // creation. MinInitDepositAmount github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,2,opt,name=min_init_deposit_amount,json=minInitDepositAmount,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"min_init_deposit_amount" yaml:"min_init_deposit_amount"` // Initial mint amount of pool coins upon pool creation. InitPoolCoinMintAmount github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,3,opt,name=init_pool_coin_mint_amount,json=initPoolCoinMintAmount,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"init_pool_coin_mint_amount" yaml:"init_pool_coin_mint_amount"` // Limit the size of each liquidity pool to minimize risk. In development, set // to 0 for no limit. In production, set a limit. MaxReserveCoinAmount github_com_cosmos_cosmos_sdk_types.Int `protobuf:"bytes,4,opt,name=max_reserve_coin_amount,json=maxReserveCoinAmount,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Int" json:"max_reserve_coin_amount" yaml:"max_reserve_coin_amount"` // Fee paid to create a Liquidity Pool. Set a fee to prevent spamming. PoolCreationFee github_com_cosmos_cosmos_sdk_types.Coins `protobuf:"bytes,5,rep,name=pool_creation_fee,json=poolCreationFee,proto3,castrepeated=github.com/cosmos/cosmos-sdk/types.Coins" json:"pool_creation_fee" yaml:"pool_creation_fee"` // Swap fee rate for every executed swap. SwapFeeRate github_com_cosmos_cosmos_sdk_types.Dec `protobuf:"bytes,6,opt,name=swap_fee_rate,json=swapFeeRate,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Dec" json:"swap_fee_rate" yaml:"swap_fee_rate"` // Reserve coin withdrawal with less proportion by withdrawFeeRate. WithdrawFeeRate github_com_cosmos_cosmos_sdk_types.Dec `protobuf:"bytes,7,opt,name=withdraw_fee_rate,json=withdrawFeeRate,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Dec" json:"withdraw_fee_rate" yaml:"withdraw_fee_rate"` // Maximum ratio of reserve coins that can be ordered at a swap order. MaxOrderAmountRatio github_com_cosmos_cosmos_sdk_types.Dec `protobuf:"bytes,8,opt,name=max_order_amount_ratio,json=maxOrderAmountRatio,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Dec" json:"max_order_amount_ratio" yaml:"max_order_amount_ratio"` // The smallest unit batch height for every liquidity pool. UnitBatchHeight uint32 `protobuf:"varint,9,opt,name=unit_batch_height,json=unitBatchHeight,proto3" json:"unit_batch_height,omitempty" yaml:"unit_batch_height"` // Circuit breaker enables or disables transaction messages in liquidity // module. CircuitBreakerEnabled bool `protobuf:"varint,10,opt,name=circuit_breaker_enabled,json=circuitBreakerEnabled,proto3" json:"circuit_breaker_enabled,omitempty" yaml:"circuit_breaker_enabled"` } func (m *Params) Reset() { *m = Params{} } func (*Params) ProtoMessage() {} func (*Params) Descriptor() ([]byte, []int) { return fileDescriptor_67b6d59e96092d89, []int{1} } func (m *Params) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *Params) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_Params.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *Params) XXX_Merge(src proto.Message) { xxx_messageInfo_Params.Merge(m, src) } func (m *Params) XXX_Size() int { return m.Size() } func (m *Params) XXX_DiscardUnknown() { xxx_messageInfo_Params.DiscardUnknown(m) } var xxx_messageInfo_Params proto.InternalMessageInfo // Pool defines the liquidity pool that contains pool information. type Pool struct { // id of the pool Id uint64 `protobuf:"varint,1,opt,name=id,proto3" json:"id" yaml:"id"` // id of the pool_type TypeId uint32 `protobuf:"varint,2,opt,name=type_id,json=typeId,proto3" json:"type_id,omitempty" yaml:"type_id"` // denoms of reserve coin pair of the pool ReserveCoinDenoms []string `protobuf:"bytes,3,rep,name=reserve_coin_denoms,json=reserveCoinDenoms,proto3" json:"reserve_coin_denoms,omitempty" yaml:"reserve_coin_denoms"` // reserve account address of the pool ReserveAccountAddress string `protobuf:"bytes,4,opt,name=reserve_account_address,json=reserveAccountAddress,proto3" json:"reserve_account_address,omitempty" yaml:"reserve_account_address"` // denom of pool coin of the pool PoolCoinDenom string `protobuf:"bytes,5,opt,name=pool_coin_denom,json=poolCoinDenom,proto3" json:"pool_coin_denom,omitempty" yaml:"pool_coin_denom"` } func (m *Pool) Reset() { *m = Pool{} } func (m *Pool) String() string { return proto.CompactTextString(m) } func (*Pool) ProtoMessage() {} func (*Pool) Descriptor() ([]byte, []int) { return fileDescriptor_67b6d59e96092d89, []int{2} } func (m *Pool) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *Pool) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_Pool.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *Pool) XXX_Merge(src proto.Message) { xxx_messageInfo_Pool.Merge(m, src) } func (m *Pool) XXX_Size() int { return m.Size() } func (m *Pool) XXX_DiscardUnknown() { xxx_messageInfo_Pool.DiscardUnknown(m) } var xxx_messageInfo_Pool proto.InternalMessageInfo // Metadata for the state of each pool for invariant checking after genesis // export or import. type PoolMetadata struct { // id of the pool PoolId uint64 `protobuf:"varint,1,opt,name=pool_id,json=poolId,proto3" json:"pool_id" yaml:"pool_id"` // pool coin issued at the pool PoolCoinTotalSupply types.Coin `protobuf:"bytes,2,opt,name=pool_coin_total_supply,json=poolCoinTotalSupply,proto3,castrepeated=github.com/cosmos/cosmos-sdk/types.Coin" json:"pool_coin_total_supply" yaml:"pool_coin"` // reserve coins deposited in the pool ReserveCoins github_com_cosmos_cosmos_sdk_types.Coins `protobuf:"bytes,3,rep,name=reserve_coins,json=reserveCoins,proto3,castrepeated=github.com/cosmos/cosmos-sdk/types.Coins" json:"reserve_coins" yaml:"deposit_coins"` } func (m *PoolMetadata) Reset() { *m = PoolMetadata{} } func (m *PoolMetadata) String() string { return proto.CompactTextString(m) } func (*PoolMetadata) ProtoMessage() {} func (*PoolMetadata) Descriptor() ([]byte, []int) { return fileDescriptor_67b6d59e96092d89, []int{3} } func (m *PoolMetadata) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *PoolMetadata) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_PoolMetadata.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *PoolMetadata) XXX_Merge(src proto.Message) { xxx_messageInfo_PoolMetadata.Merge(m, src) } func (m *PoolMetadata) XXX_Size() int { return m.Size() } func (m *PoolMetadata) XXX_DiscardUnknown() { xxx_messageInfo_PoolMetadata.DiscardUnknown(m) } var xxx_messageInfo_PoolMetadata proto.InternalMessageInfo // PoolBatch defines the batch or batches of a given liquidity pool that // contains indexes of deposit, withdraw, and swap messages. Index param // increments by 1 if the pool id is same. type PoolBatch struct { // id of the pool PoolId uint64 `protobuf:"varint,1,opt,name=pool_id,json=poolId,proto3" json:"pool_id" yaml:"pool_id"` // index of this batch Index uint64 `protobuf:"varint,2,opt,name=index,proto3" json:"index,omitempty" yaml:"index"` // height where this batch is started BeginHeight int64 `protobuf:"varint,3,opt,name=begin_height,json=beginHeight,proto3" json:"begin_height,omitempty" yaml:"begin_height"` // last index of DepositMsgStates DepositMsgIndex uint64 `protobuf:"varint,4,opt,name=deposit_msg_index,json=depositMsgIndex,proto3" json:"deposit_msg_index,omitempty" yaml:"deposit_msg_index"` // last index of WithdrawMsgStates WithdrawMsgIndex uint64 `protobuf:"varint,5,opt,name=withdraw_msg_index,json=withdrawMsgIndex,proto3" json:"withdraw_msg_index,omitempty" yaml:"withdraw_msg_index"` // last index of SwapMsgStates SwapMsgIndex uint64 `protobuf:"varint,6,opt,name=swap_msg_index,json=swapMsgIndex,proto3" json:"swap_msg_index,omitempty" yaml:"swap_msg_index"` // true if executed, false if not executed Executed bool `protobuf:"varint,7,opt,name=executed,proto3" json:"executed,omitempty" yaml:"executed"` } func (m *PoolBatch) Reset() { *m = PoolBatch{} } func (m *PoolBatch) String() string { return proto.CompactTextString(m) } func (*PoolBatch) ProtoMessage() {} func (*PoolBatch) Descriptor() ([]byte, []int) { return fileDescriptor_67b6d59e96092d89, []int{4} } func (m *PoolBatch) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *PoolBatch) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_PoolBatch.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *PoolBatch) XXX_Merge(src proto.Message) { xxx_messageInfo_PoolBatch.Merge(m, src) } func (m *PoolBatch) XXX_Size() int { return m.Size() } func (m *PoolBatch) XXX_DiscardUnknown() { xxx_messageInfo_PoolBatch.DiscardUnknown(m) } var xxx_messageInfo_PoolBatch proto.InternalMessageInfo // DepositMsgState defines the state of deposit message that contains state // information as it is processed in the next batch or batches. type DepositMsgState struct { // height where this message is appended to the batch MsgHeight int64 `protobuf:"varint,1,opt,name=msg_height,json=msgHeight,proto3" json:"msg_height,omitempty" yaml:"msg_height"` // index of this deposit message in this liquidity pool MsgIndex uint64 `protobuf:"varint,2,opt,name=msg_index,json=msgIndex,proto3" json:"msg_index,omitempty" yaml:"msg_index"` // true if executed on this batch, false if not executed Executed bool `protobuf:"varint,3,opt,name=executed,proto3" json:"executed,omitempty" yaml:"executed"` // true if executed successfully on this batch, false if failed Succeeded bool `protobuf:"varint,4,opt,name=succeeded,proto3" json:"succeeded,omitempty" yaml:"succeeded"` // true if ready to be deleted on kvstore, false if not ready to be deleted ToBeDeleted bool `protobuf:"varint,5,opt,name=to_be_deleted,json=toBeDeleted,proto3" json:"to_be_deleted,omitempty" yaml:"to_be_deleted"` // MsgDepositWithinBatch Msg *MsgDepositWithinBatch `protobuf:"bytes,6,opt,name=msg,proto3" json:"msg,omitempty" yaml:"msg"` } func (m *DepositMsgState) Reset() { *m = DepositMsgState{} } func (m *DepositMsgState) String() string { return proto.CompactTextString(m) } func (*DepositMsgState) ProtoMessage() {} func (*DepositMsgState) Descriptor() ([]byte, []int) { return fileDescriptor_67b6d59e96092d89, []int{5} } func (m *DepositMsgState) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *DepositMsgState) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_DepositMsgState.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *DepositMsgState) XXX_Merge(src proto.Message) { xxx_messageInfo_DepositMsgState.Merge(m, src) } func (m *DepositMsgState) XXX_Size() int { return m.Size() } func (m *DepositMsgState) XXX_DiscardUnknown() { xxx_messageInfo_DepositMsgState.DiscardUnknown(m) } var xxx_messageInfo_DepositMsgState proto.InternalMessageInfo // WithdrawMsgState defines the state of the withdraw message that contains // state information as the message is processed in the next batch or batches. type WithdrawMsgState struct { // height where this message is appended to the batch MsgHeight int64 `protobuf:"varint,1,opt,name=msg_height,json=msgHeight,proto3" json:"msg_height,omitempty" yaml:"msg_height"` // index of this withdraw message in this liquidity pool MsgIndex uint64 `protobuf:"varint,2,opt,name=msg_index,json=msgIndex,proto3" json:"msg_index,omitempty" yaml:"msg_index"` // true if executed on this batch, false if not executed Executed bool `protobuf:"varint,3,opt,name=executed,proto3" json:"executed,omitempty" yaml:"executed"` // true if executed successfully on this batch, false if failed Succeeded bool `protobuf:"varint,4,opt,name=succeeded,proto3" json:"succeeded,omitempty" yaml:"succeeded"` // true if ready to be deleted on kvstore, false if not ready to be deleted ToBeDeleted bool `protobuf:"varint,5,opt,name=to_be_deleted,json=toBeDeleted,proto3" json:"to_be_deleted,omitempty" yaml:"to_be_deleted"` // MsgWithdrawWithinBatch Msg *MsgWithdrawWithinBatch `protobuf:"bytes,6,opt,name=msg,proto3" json:"msg,omitempty" yaml:"msg"` } func (m *WithdrawMsgState) Reset() { *m = WithdrawMsgState{} } func (m *WithdrawMsgState) String() string { return proto.CompactTextString(m) } func (*WithdrawMsgState) ProtoMessage() {} func (*WithdrawMsgState) Descriptor() ([]byte, []int) { return fileDescriptor_67b6d59e96092d89, []int{6} } func (m *WithdrawMsgState) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *WithdrawMsgState) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_WithdrawMsgState.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *WithdrawMsgState) XXX_Merge(src proto.Message) { xxx_messageInfo_WithdrawMsgState.Merge(m, src) } func (m *WithdrawMsgState) XXX_Size() int { return m.Size() } func (m *WithdrawMsgState) XXX_DiscardUnknown() { xxx_messageInfo_WithdrawMsgState.DiscardUnknown(m) } var xxx_messageInfo_WithdrawMsgState proto.InternalMessageInfo // SwapMsgState defines the state of the swap message that contains state // information as the message is processed in the next batch or batches. type SwapMsgState struct { // height where this message is appended to the batch MsgHeight int64 `protobuf:"varint,1,opt,name=msg_height,json=msgHeight,proto3" json:"msg_height,omitempty" yaml:"msg_height"` // index of this swap message in this liquidity pool MsgIndex uint64 `protobuf:"varint,2,opt,name=msg_index,json=msgIndex,proto3" json:"msg_index,omitempty" yaml:"msg_index"` // true if executed on this batch, false if not executed Executed bool `protobuf:"varint,3,opt,name=executed,proto3" json:"executed,omitempty" yaml:"executed"` // true if executed successfully on this batch, false if failed Succeeded bool `protobuf:"varint,4,opt,name=succeeded,proto3" json:"succeeded,omitempty" yaml:"succeeded"` // true if ready to be deleted on kvstore, false if not ready to be deleted ToBeDeleted bool `protobuf:"varint,5,opt,name=to_be_deleted,json=toBeDeleted,proto3" json:"to_be_deleted,omitempty" yaml:"to_be_deleted"` // swap orders are cancelled when current height is equal to or higher than // ExpiryHeight OrderExpiryHeight int64 `protobuf:"varint,6,opt,name=order_expiry_height,json=orderExpiryHeight,proto3" json:"order_expiry_height,omitempty" yaml:"order_expiry_height"` // offer coin exchanged until now ExchangedOfferCoin types.Coin `protobuf:"bytes,7,opt,name=exchanged_offer_coin,json=exchangedOfferCoin,proto3,castrepeated=github.com/cosmos/cosmos-sdk/types.Coin" json:"exchanged_offer_coin" yaml:"exchanged_offer_coin"` // offer coin currently remaining to be exchanged RemainingOfferCoin types.Coin `protobuf:"bytes,8,opt,name=remaining_offer_coin,json=remainingOfferCoin,proto3,castrepeated=github.com/cosmos/cosmos-sdk/types.Coin" json:"remaining_offer_coin" yaml:"remaining_offer_coin"` // reserve fee for pays fee in half offer coin ReservedOfferCoinFee types.Coin `protobuf:"bytes,9,opt,name=reserved_offer_coin_fee,json=reservedOfferCoinFee,proto3,castrepeated=github.com/cosmos/cosmos-sdk/types.Coin" json:"reserved_offer_coin_fee" yaml:"reserved_offer_coin_fee"` // MsgSwapWithinBatch Msg *MsgSwapWithinBatch `protobuf:"bytes,10,opt,name=msg,proto3" json:"msg,omitempty" yaml:"msg"` } func (m *SwapMsgState) Reset() { *m = SwapMsgState{} } func (m *SwapMsgState) String() string { return proto.CompactTextString(m) } func (*SwapMsgState) ProtoMessage() {} func (*SwapMsgState) Descriptor() ([]byte, []int) { return fileDescriptor_67b6d59e96092d89, []int{7} } func (m *SwapMsgState) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *SwapMsgState) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_SwapMsgState.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *SwapMsgState) XXX_Merge(src proto.Message) { xxx_messageInfo_SwapMsgState.Merge(m, src) } func (m *SwapMsgState) XXX_Size() int { return m.Size() } func (m *SwapMsgState) XXX_DiscardUnknown() { xxx_messageInfo_SwapMsgState.DiscardUnknown(m) } var xxx_messageInfo_SwapMsgState proto.InternalMessageInfo func init() { proto.RegisterType((*PoolType)(nil), "cyber.liquidity.v1beta1.PoolType") proto.RegisterType((*Params)(nil), "cyber.liquidity.v1beta1.Params") proto.RegisterType((*Pool)(nil), "cyber.liquidity.v1beta1.Pool") proto.RegisterType((*PoolMetadata)(nil), "cyber.liquidity.v1beta1.PoolMetadata") proto.RegisterType((*PoolBatch)(nil), "cyber.liquidity.v1beta1.PoolBatch") proto.RegisterType((*DepositMsgState)(nil), "cyber.liquidity.v1beta1.DepositMsgState") proto.RegisterType((*WithdrawMsgState)(nil), "cyber.liquidity.v1beta1.WithdrawMsgState") proto.RegisterType((*SwapMsgState)(nil), "cyber.liquidity.v1beta1.SwapMsgState") } func init() { proto.RegisterFile("cyber/liquidity/v1beta1/liquidity.proto", fileDescriptor_67b6d59e96092d89) } var fileDescriptor_67b6d59e96092d89 = []byte{ // 1553 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x58, 0xcd, 0x6b, 0x1b, 0xc7, 0x1b, 0xf6, 0x4a, 0xb2, 0x2d, 0x8d, 0xed, 0xc8, 0x5a, 0xcb, 0xb6, 0xec, 0xfc, 0xa2, 0x75, 0x36, 0x90, 0x18, 0x42, 0x24, 0x92, 0xfc, 0x28, 0xc5, 0x14, 0x4a, 0x36, 0x4e, 0xb0, 0x69, 0xed, 0x38, 0xe3, 0x40, 0x4a, 0x4a, 0xbb, 0xac, 0x76, 0x27, 0xab, 0x21, 0xda, 0x5d, 0x75, 0x77, 0x94, 0x48, 0xf7, 0x1e, 0x7a, 0xec, 0x07, 0x85, 0x42, 0x28, 0x04, 0x7a, 0xeb, 0xb1, 0xf4, 0xd4, 0xbf, 0x20, 0xc7, 0xd0, 0x53, 0xe9, 0x61, 0xdb, 0x26, 0x97, 0x92, 0x4b, 0xe9, 0xfe, 0x05, 0x65, 0x3e, 0xf6, 0xc3, 0x92, 0xec, 0x44, 0xed, 0x35, 0x27, 0x4b, 0xef, 0xc7, 0x33, 0xcf, 0x3c, 0xef, 0xbc, 0xef, 0x8c, 0x05, 0x2e, 0x98, 0x83, 0x16, 0xf2, 0x9b, 0x1d, 0xfc, 0x49, 0x0f, 0x5b, 0x98, 0x0c, 0x9a, 0x0f, 0x2f, 0xb7, 0x10, 0x31, 0x2e, 0xa7, 0x96, 0x46, 0xd7, 0xf7, 0x88, 0x27, 0xaf, 0xb2, 0xc0, 0x46, 0x6a, 0x16, 0x81, 0xeb, 0x1b, 0xc7, 0x21, 0x90, 0x3e, 0x4f, 0x5d, 0xaf, 0xda, 0x9e, 0xed, 0xb1, 0x8f, 0x4d, 0xfa, 0x49, 0x58, 0xeb, 0xa6, 0x17, 0x38, 0x5e, 0xd0, 0x6c, 0x19, 0x01, 0x4a, 0x72, 0x4c, 0x0f, 0xbb, 0xc2, 0xbf, 0xc6, 0xfd, 0x3a, 0x4f, 0xe4, 0x5f, 0xb8, 0x4b, 0xfd, 0x21, 0x07, 0x8a, 0x07, 0x9e, 0xd7, 0xb9, 0x33, 0xe8, 0x22, 0xf9, 0x0c, 0xc8, 0x61, 0xab, 0x26, 0x6d, 0x48, 0x9b, 0x0b, 0xda, 0x42, 0x14, 0x2a, 0xa5, 0x81, 0xe1, 0x74, 0xb6, 0x54, 0x6c, 0xa9, 0x30, 0x87, 0x2d, 0xf9, 0x1c, 0x28, 0xb8, 0x86, 0x83, 0x6a, 0xb9, 0x0d, 0x69, 0xb3, 0xa4, 0x95, 0xa3, 0x50, 0x99, 0xe3, 0x01, 0xd4, 0xaa, 0x42, 0xe6, 0x94, 0x0f, 0x40, 0xd5, 0xc1, 0xae, 0xee, 0xa3, 0x00, 0xf9, 0x0f, 0x91, 0x4e, 0x59, 0xe8, 0x6e, 0xcf, 0xa9, 0xe5, 0x19, 0xaa, 0x12, 0x85, 0xca, 0x69, 0x9e, 0x34, 0x2e, 0x4a, 0x85, 0x15, 0x07, 0xbb, 0x90, 0x5b, 0xaf, 0x7b, 0xd8, 0xdd, 0xef, 0x39, 0x0c, 0xd1, 0xe8, 0x8f, 0x22, 0x16, 0x46, 0x10, 0xc7, 0x44, 0x51, 0x44, 0xa3, 0x3f, 0x84, 0xf8, 0x36, 0x98, 0xb3, 0x50, 0x60, 0xfa, 0xb8, 0x4b, 0xb0, 0xe7, 0xd6, 0xa6, 0xd9, 0x7e, 0x56, 0xa2, 0x50, 0x91, 0x39, 0x50, 0xc6, 0xa9, 0xc2, 0x6c, 0xe8, 0x56, 0xe1, 0xcf, 0x27, 0x8a, 0xa4, 0x7e, 0x01, 0xc0, 0xcc, 0x81, 0xe1, 0x1b, 0x4e, 0x20, 0x7f, 0x08, 0x40, 0xd7, 0xf3, 0x3a, 0x3a, 0x19, 0x74, 0x51, 0x50, 0x93, 0x36, 0xf2, 0x9b, 0x73, 0x57, 0xce, 0x36, 0x8e, 0x29, 0x70, 0x23, 0x56, 0x5a, 0x5b, 0x7b, 0x1a, 0x2a, 0x53, 0x51, 0xa8, 0x54, 0xf8, 0x82, 0x29, 0x84, 0x0a, 0x4b, 0x5d, 0x11, 0x14, 0xc8, 0x5f, 0x4b, 0x60, 0x95, 0xca, 0x84, 0x5d, 0x4c, 0x74, 0x0b, 0x75, 0xbd, 0x00, 0x13, 0xdd, 0x70, 0xbc, 0x9e, 0x4b, 0x44, 0x11, 0x3e, 0xa6, 0x38, 0xbf, 0x86, 0xca, 0x79, 0x1b, 0x93, 0x76, 0xaf, 0xd5, 0x30, 0x3d, 0x47, 0xd4, 0x57, 0xfc, 0xb9, 0x14, 0x58, 0x0f, 0x9a, 0x0c, 0xb9, 0xb1, 0xeb, 0x92, 0x28, 0x54, 0xea, 0xa9, 0xfa, 0x63, 0x60, 0xd5, 0x9f, 0x7f, 0xbc, 0x04, 0xc4, 0x01, 0xd9, 0x75, 0x09, 0xa4, 0xb5, 0xdc, 0x75, 0x31, 0xd9, 0xe6, 0x51, 0xd7, 0x58, 0x90, 0xfc, 0xad, 0x04, 0xd6, 0x59, 0x32, 0xe3, 0xcd, 0xa4, 0x76, 0xb0, 0x9b, 0x50, 0xcb, 0x33, 0x6a, 0xc6, 0xc4, 0xd4, 0xce, 0x8a, 0xe3, 0x76, 0x2c, 0xf2, 0x30, 0xbb, 0x15, 0x1a, 0x4a, 0x35, 0xa5, 0x85, 0xdd, 0xc3, 0x6e, 0xcc, 0x8f, 0xe9, 0x36, 0x7c, 0x18, 0x04, 0xb9, 0xc2, 0x7f, 0xd4, 0x6d, 0x3c, 0xec, 0xa8, 0x6e, 0x47, 0x0e, 0x9d, 0xe0, 0xf5, 0x95, 0x04, 0x2a, 0x7c, 0x63, 0x3e, 0x32, 0xe8, 0x79, 0xd2, 0xef, 0x23, 0x54, 0x9b, 0x66, 0x87, 0x66, 0xad, 0x21, 0xd2, 0x69, 0x13, 0x27, 0x07, 0x86, 0x26, 0x6b, 0xef, 0x8b, 0xc3, 0x52, 0xcb, 0x1c, 0x96, 0x2c, 0x82, 0xfa, 0xfd, 0x6f, 0xca, 0xe6, 0x6b, 0x6c, 0x84, 0x82, 0x05, 0xb0, 0x4c, 0xf3, 0xaf, 0x8b, 0xf4, 0x9b, 0x08, 0xc9, 0x7d, 0xb0, 0x10, 0x3c, 0x32, 0xba, 0x14, 0x49, 0xf7, 0x0d, 0x82, 0x6a, 0x33, 0x4c, 0xa2, 0x3b, 0x13, 0x48, 0xb4, 0x8d, 0xcc, 0x28, 0x54, 0xaa, 0x9c, 0xdf, 0x11, 0xb0, 0xac, 0x30, 0xdb, 0xc8, 0x84, 0x73, 0xd4, 0x7b, 0x13, 0x21, 0x68, 0x10, 0x24, 0x7f, 0x2a, 0x81, 0xca, 0x23, 0x4c, 0xda, 0x96, 0x6f, 0x3c, 0x4a, 0x97, 0x9f, 0x65, 0xcb, 0x7f, 0x30, 0xf1, 0xf2, 0x42, 0x9e, 0x11, 0xc0, 0x61, 0x0a, 0xe5, 0x38, 0x22, 0xa6, 0xf1, 0xa5, 0x04, 0x56, 0x68, 0x5d, 0x3d, 0xdf, 0x42, 0xbe, 0x28, 0x28, 0xcd, 0xc4, 0x5e, 0xad, 0xc8, 0xb8, 0x7c, 0x34, 0x31, 0x97, 0x33, 0xe9, 0x69, 0x19, 0x45, 0x1d, 0x26, 0xb4, 0xe4, 0x18, 0xfd, 0x5b, 0x34, 0x8a, 0x1f, 0x13, 0x48, 0x63, 0xe4, 0x1d, 0x50, 0xe9, 0xd1, 0x46, 0x68, 0x19, 0xc4, 0x6c, 0xeb, 0x6d, 0x84, 0xed, 0x36, 0xa9, 0x95, 0xd8, 0xc8, 0xfb, 0x5f, 0xba, 0xd9, 0x91, 0x10, 0x15, 0x96, 0xa9, 0x4d, 0xa3, 0xa6, 0x1d, 0x66, 0x91, 0xef, 0x81, 0x55, 0x13, 0xfb, 0x66, 0x8f, 0x46, 0xfa, 0xc8, 0x78, 0x80, 0x7c, 0x1d, 0xb9, 0x46, 0xab, 0x83, 0xac, 0x1a, 0xd8, 0x90, 0x36, 0x8b, 0x9a, 0x9a, 0x1e, 0xef, 0x63, 0x02, 0x55, 0xb8, 0x2c, 0x3c, 0x1a, 0x77, 0xdc, 0xe0, 0xf6, 0xad, 0xe2, 0x37, 0x4f, 0x94, 0x29, 0x36, 0x13, 0x5f, 0xe6, 0x40, 0x81, 0xb6, 0xa2, 0x7c, 0x2e, 0xb9, 0x44, 0x0a, 0xda, 0xd2, 0xcb, 0x50, 0xc9, 0x61, 0x6b, 0xf4, 0x2a, 0xb9, 0x08, 0x66, 0xa9, 0x5c, 0x3a, 0xb6, 0xd8, 0x20, 0x5b, 0xd0, 0xe4, 0x28, 0x54, 0x4e, 0xf1, 0x18, 0xe1, 0x50, 0xe1, 0x0c, 0xfd, 0xb4, 0x6b, 0xc9, 0xfb, 0x60, 0xe9, 0x48, 0xcb, 0x59, 0xc8, 0xf5, 0x9c, 0xa0, 0x96, 0xdf, 0xc8, 0x6f, 0x96, 0xb4, 0x7a, 0x14, 0x2a, 0xeb, 0x3c, 0x71, 0x4c, 0x90, 0x0a, 0x2b, 0x7e, 0xda, 0x86, 0xdb, 0xcc, 0x26, 0xfb, 0x60, 0x35, 0x0e, 0x35, 0x4c, 0x93, 0xd5, 0xc5, 0xb0, 0x2c, 0x1f, 0x05, 0x81, 0x98, 0x0e, 0x5b, 0xa9, 0x20, 0xc7, 0x04, 0xd2, 0x12, 0x56, 0x45, 0x09, 0xaf, 0x71, 0xd3, 0x21, 0xf1, 0xb1, 0x6b, 0xc3, 0x65, 0x91, 0x71, 0x8d, 0x27, 0x08, 0xa7, 0xac, 0x81, 0x72, 0x3a, 0xd2, 0x18, 0x37, 0x71, 0xed, 0xac, 0x47, 0xa1, 0xb2, 0x92, 0x6d, 0xec, 0x24, 0x40, 0x85, 0x0b, 0x5d, 0x31, 0xdb, 0x18, 0x71, 0x26, 0xb6, 0xc4, 0xc4, 0xfe, 0x3b, 0x07, 0xe6, 0xa9, 0xd8, 0x7b, 0x88, 0x18, 0x96, 0x41, 0x0c, 0xf9, 0x2d, 0x30, 0xcb, 0xb2, 0x13, 0xe5, 0xcf, 0xbc, 0x0c, 0x95, 0xd8, 0x94, 0x4a, 0x2b, 0x0c, 0x2a, 0x9c, 0xa1, 0x9f, 0x76, 0x2d, 0x3a, 0x91, 0x56, 0xd2, 0x65, 0x89, 0x47, 0x8c, 0x8e, 0x1e, 0xf4, 0xba, 0xdd, 0xce, 0x80, 0xd5, 0xe5, 0xc4, 0xb1, 0x74, 0x5d, 0x8c, 0xa5, 0xc5, 0x21, 0xf6, 0x74, 0x1c, 0x5d, 0x78, 0xcd, 0x71, 0x04, 0x97, 0xe2, 0x2d, 0xde, 0xa1, 0x6b, 0x1f, 0xb2, 0xa5, 0xe5, 0xcf, 0x24, 0xb0, 0x90, 0x2d, 0x26, 0xaf, 0xf5, 0x89, 0x64, 0x76, 0x04, 0x99, 0x6a, 0x7c, 0x83, 0xf3, 0x5b, 0x8d, 0x65, 0x4f, 0x36, 0x1f, 0xe7, 0x33, 0x07, 0x26, 0xc8, 0x68, 0xfe, 0x53, 0x1e, 0x94, 0xa8, 0xe6, 0xac, 0xb5, 0xfe, 0xb5, 0xe0, 0xe7, 0xc1, 0x34, 0x76, 0x2d, 0xd4, 0x67, 0xf2, 0x16, 0xb4, 0xc5, 0x28, 0x54, 0xe6, 0xe3, 0x6b, 0xcf, 0x42, 0x7d, 0x15, 0x72, 0xb7, 0xbc, 0x05, 0xe6, 0x5b, 0xc8, 0xc6, 0x6e, 0xdc, 0xf9, 0xf4, 0x4e, 0xcd, 0x6b, 0xab, 0x51, 0xa8, 0x2c, 0xf1, 0xf0, 0xac, 0x57, 0x85, 0x73, 0xec, 0xab, 0x68, 0xf8, 0x1d, 0x50, 0x89, 0xf7, 0xef, 0x04, 0xb6, 0xce, 0xd7, 0x2b, 0xb0, 0xf5, 0x32, 0xa3, 0x63, 0x24, 0x44, 0x85, 0x65, 0x61, 0xdb, 0x0b, 0xec, 0x5d, 0xc6, 0xe2, 0x3d, 0x20, 0x27, 0xe3, 0x34, 0x85, 0x9a, 0xe6, 0x1b, 0x8e, 0x42, 0x65, 0x6d, 0x68, 0xe4, 0x66, 0xb0, 0x16, 0x63, 0x63, 0x02, 0xf6, 0x2e, 0x38, 0xc5, 0xae, 0x86, 0x14, 0x68, 0x86, 0x01, 0xad, 0x45, 0xa1, 0xb2, 0x9c, 0xb9, 0x3a, 0x32, 0x20, 0xf3, 0xd4, 0x90, 0x00, 0x34, 0x41, 0x11, 0xf5, 0x91, 0xd9, 0x23, 0xc8, 0x62, 0x97, 0x44, 0x51, 0x5b, 0x8a, 0x42, 0xa5, 0xcc, 0x53, 0x63, 0x8f, 0x0a, 0x93, 0xa0, 0x4c, 0xf1, 0xfe, 0xca, 0x81, 0xf2, 0x76, 0xb2, 0xb9, 0x43, 0x42, 0xc7, 0xfe, 0xff, 0x01, 0xa0, 0x4b, 0x09, 0x81, 0x25, 0x26, 0xf0, 0x72, 0xfa, 0x26, 0x4b, 0x7d, 0x2a, 0x2c, 0x39, 0x81, 0x2d, 0xc4, 0xbd, 0x0c, 0x4a, 0xe9, 0x06, 0x78, 0x11, 0xab, 0x69, 0x13, 0x64, 0xb8, 0x17, 0x9d, 0x71, 0xbc, 0xf3, 0xaf, 0xc1, 0x5b, 0xbe, 0x02, 0x4a, 0x41, 0xcf, 0x34, 0x11, 0xb2, 0x90, 0xc5, 0x0a, 0x57, 0xcc, 0xae, 0x91, 0xb8, 0x54, 0x98, 0x86, 0xc9, 0xef, 0x80, 0x05, 0xe2, 0xe9, 0x2d, 0xa4, 0x5b, 0xa8, 0x83, 0xe8, 0x4a, 0xd3, 0x2c, 0xaf, 0x96, 0xf6, 0xc4, 0x11, 0xb7, 0x0a, 0xe7, 0x88, 0xa7, 0xa1, 0x6d, 0xfe, 0x4d, 0x3e, 0x00, 0x79, 0x27, 0xb0, 0x59, 0x41, 0xe6, 0xae, 0x34, 0x8e, 0x7d, 0xbf, 0xee, 0x05, 0xb6, 0x50, 0xf1, 0x2e, 0x26, 0x6d, 0xec, 0xb2, 0x5e, 0xd0, 0x4e, 0x45, 0xa1, 0x02, 0x92, 0xfd, 0xab, 0x90, 0x42, 0xd1, 0x11, 0xb5, 0x78, 0x37, 0x3d, 0x02, 0x6f, 0x24, 0x1f, 0x96, 0xfc, 0x76, 0x56, 0xf2, 0xe6, 0x49, 0x92, 0xc7, 0x32, 0xbe, 0x52, 0xf3, 0xc7, 0xb3, 0x60, 0xfe, 0x90, 0x77, 0xcc, 0x1b, 0xbd, 0x87, 0xf5, 0xde, 0x07, 0x4b, 0xfc, 0x29, 0x86, 0xfa, 0x5d, 0xec, 0x0f, 0x62, 0x51, 0x66, 0x98, 0x28, 0x99, 0x57, 0xc4, 0x98, 0x20, 0x15, 0x56, 0x98, 0xf5, 0x06, 0x33, 0x0a, 0x95, 0x1e, 0x4b, 0xa0, 0x8a, 0xfa, 0x66, 0xdb, 0x70, 0x6d, 0x64, 0xe9, 0xde, 0xfd, 0xfb, 0xc8, 0x67, 0xd7, 0x0d, 0x1b, 0x4d, 0x27, 0xde, 0x55, 0xfb, 0xe2, 0xae, 0x3a, 0x1d, 0xcb, 0x33, 0x0a, 0x32, 0xd1, 0x1d, 0x2a, 0x27, 0x08, 0xb7, 0x28, 0x00, 0xb5, 0x31, 0x76, 0x3e, 0x72, 0x0c, 0xec, 0x62, 0xd7, 0xce, 0xb2, 0x2b, 0x4e, 0xc8, 0x6e, 0x1c, 0xc8, 0x64, 0xec, 0x12, 0x84, 0x94, 0xdd, 0x77, 0x52, 0xf2, 0x04, 0xcb, 0xee, 0x9a, 0xfd, 0x3b, 0x54, 0x7a, 0x15, 0xc1, 0xdb, 0x82, 0xe0, 0xd1, 0x17, 0xda, 0x30, 0xce, 0x44, 0x1c, 0xab, 0x31, 0x48, 0x42, 0x91, 0xfe, 0x63, 0xb4, 0xc7, 0x3b, 0x14, 0x30, 0x42, 0x17, 0x4f, 0xea, 0x50, 0xda, 0x74, 0xaf, 0xea, 0x4e, 0xed, 0xf6, 0xd3, 0x3f, 0xea, 0x53, 0x4f, 0x9f, 0xd7, 0xa5, 0x67, 0xcf, 0xeb, 0xd2, 0xef, 0xcf, 0xeb, 0xd2, 0xe7, 0x2f, 0xea, 0x53, 0xcf, 0x5e, 0xd4, 0xa7, 0x7e, 0x79, 0x51, 0x9f, 0xba, 0x77, 0x35, 0xcb, 0x95, 0xae, 0x64, 0x7a, 0xae, 0x4d, 0x9f, 0x8e, 0x4d, 0xdb, 0xbb, 0xc4, 0x7f, 0x17, 0xea, 0x67, 0x7e, 0x19, 0x62, 0xe4, 0x5b, 0x33, 0xec, 0x47, 0x9c, 0xab, 0xff, 0x04, 0x00, 0x00, 0xff, 0xff, 0xe2, 0x7c, 0x06, 0x55, 0x7b, 0x12, 0x00, 0x00, } func (this *PoolType) Equal(that interface{}) bool { if that == nil { return this == nil } that1, ok := that.(*PoolType) if !ok { that2, ok := that.(PoolType) if ok { that1 = &that2 } else { return false } } if that1 == nil { return this == nil } else if this == nil { return false } if this.Id != that1.Id { return false } if this.Name != that1.Name { return false } if this.MinReserveCoinNum != that1.MinReserveCoinNum { return false } if this.MaxReserveCoinNum != that1.MaxReserveCoinNum { return false } if this.Description != that1.Description { return false } return true } func (this *Params) Equal(that interface{}) bool { if that == nil { return this == nil } that1, ok := that.(*Params) if !ok { that2, ok := that.(Params) if ok { that1 = &that2 } else { return false } } if that1 == nil { return this == nil } else if this == nil { return false } if len(this.PoolTypes) != len(that1.PoolTypes) { return false } for i := range this.PoolTypes { if !this.PoolTypes[i].Equal(&that1.PoolTypes[i]) { return false } } if !this.MinInitDepositAmount.Equal(that1.MinInitDepositAmount) { return false } if !this.InitPoolCoinMintAmount.Equal(that1.InitPoolCoinMintAmount) { return false } if !this.MaxReserveCoinAmount.Equal(that1.MaxReserveCoinAmount) { return false } if len(this.PoolCreationFee) != len(that1.PoolCreationFee) { return false } for i := range this.PoolCreationFee { if !this.PoolCreationFee[i].Equal(&that1.PoolCreationFee[i]) { return false } } if !this.SwapFeeRate.Equal(that1.SwapFeeRate) { return false } if !this.WithdrawFeeRate.Equal(that1.WithdrawFeeRate) { return false } if !this.MaxOrderAmountRatio.Equal(that1.MaxOrderAmountRatio) { return false } if this.UnitBatchHeight != that1.UnitBatchHeight { return false } if this.CircuitBreakerEnabled != that1.CircuitBreakerEnabled { return false } return true } func (this *Pool) Equal(that interface{}) bool { if that == nil { return this == nil } that1, ok := that.(*Pool) if !ok { that2, ok := that.(Pool) if ok { that1 = &that2 } else { return false } } if that1 == nil { return this == nil } else if this == nil { return false } if this.Id != that1.Id { return false } if this.TypeId != that1.TypeId { return false } if len(this.ReserveCoinDenoms) != len(that1.ReserveCoinDenoms) { return false } for i := range this.ReserveCoinDenoms { if this.ReserveCoinDenoms[i] != that1.ReserveCoinDenoms[i] { return false } } if this.ReserveAccountAddress != that1.ReserveAccountAddress { return false } if this.PoolCoinDenom != that1.PoolCoinDenom { return false } return true } func (this *PoolMetadata) Equal(that interface{}) bool { if that == nil { return this == nil } that1, ok := that.(*PoolMetadata) if !ok { that2, ok := that.(PoolMetadata) if ok { that1 = &that2 } else { return false } } if that1 == nil { return this == nil } else if this == nil { return false } if this.PoolId != that1.PoolId { return false } if !this.PoolCoinTotalSupply.Equal(&that1.PoolCoinTotalSupply) { return false } if len(this.ReserveCoins) != len(that1.ReserveCoins) { return false } for i := range this.ReserveCoins { if !this.ReserveCoins[i].Equal(&that1.ReserveCoins[i]) { return false } } return true } func (this *PoolBatch) Equal(that interface{}) bool { if that == nil { return this == nil } that1, ok := that.(*PoolBatch) if !ok { that2, ok := that.(PoolBatch) if ok { that1 = &that2 } else { return false } } if that1 == nil { return this == nil } else if this == nil { return false } if this.PoolId != that1.PoolId { return false } if this.Index != that1.Index { return false } if this.BeginHeight != that1.BeginHeight { return false } if this.DepositMsgIndex != that1.DepositMsgIndex { return false } if this.WithdrawMsgIndex != that1.WithdrawMsgIndex { return false } if this.SwapMsgIndex != that1.SwapMsgIndex { return false } if this.Executed != that1.Executed { return false } return true } func (m *PoolType) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *PoolType) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *PoolType) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.Description) > 0 { i -= len(m.Description) copy(dAtA[i:], m.Description) i = encodeVarintLiquidity(dAtA, i, uint64(len(m.Description))) i-- dAtA[i] = 0x2a } if m.MaxReserveCoinNum != 0 { i = encodeVarintLiquidity(dAtA, i, uint64(m.MaxReserveCoinNum)) i-- dAtA[i] = 0x20 } if m.MinReserveCoinNum != 0 { i = encodeVarintLiquidity(dAtA, i, uint64(m.MinReserveCoinNum)) i-- dAtA[i] = 0x18 } if len(m.Name) > 0 { i -= len(m.Name) copy(dAtA[i:], m.Name) i = encodeVarintLiquidity(dAtA, i, uint64(len(m.Name))) i-- dAtA[i] = 0x12 } if m.Id != 0 { i = encodeVarintLiquidity(dAtA, i, uint64(m.Id)) i-- dAtA[i] = 0x8 } return len(dAtA) - i, nil } func (m *Params) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *Params) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *Params) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.CircuitBreakerEnabled { i-- if m.CircuitBreakerEnabled { dAtA[i] = 1 } else { dAtA[i] = 0 } i-- dAtA[i] = 0x50 } if m.UnitBatchHeight != 0 { i = encodeVarintLiquidity(dAtA, i, uint64(m.UnitBatchHeight)) i-- dAtA[i] = 0x48 } { size := m.MaxOrderAmountRatio.Size() i -= size if _, err := m.MaxOrderAmountRatio.MarshalTo(dAtA[i:]); err != nil { return 0, err } i = encodeVarintLiquidity(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x42 { size := m.WithdrawFeeRate.Size() i -= size if _, err := m.WithdrawFeeRate.MarshalTo(dAtA[i:]); err != nil { return 0, err } i = encodeVarintLiquidity(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x3a { size := m.SwapFeeRate.Size() i -= size if _, err := m.SwapFeeRate.MarshalTo(dAtA[i:]); err != nil { return 0, err } i = encodeVarintLiquidity(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x32 if len(m.PoolCreationFee) > 0 { for iNdEx := len(m.PoolCreationFee) - 1; iNdEx >= 0; iNdEx-- { { size, err := m.PoolCreationFee[iNdEx].MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintLiquidity(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x2a } } { size := m.MaxReserveCoinAmount.Size() i -= size if _, err := m.MaxReserveCoinAmount.MarshalTo(dAtA[i:]); err != nil { return 0, err } i = encodeVarintLiquidity(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x22 { size := m.InitPoolCoinMintAmount.Size() i -= size if _, err := m.InitPoolCoinMintAmount.MarshalTo(dAtA[i:]); err != nil { return 0, err } i = encodeVarintLiquidity(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x1a { size := m.MinInitDepositAmount.Size() i -= size if _, err := m.MinInitDepositAmount.MarshalTo(dAtA[i:]); err != nil { return 0, err } i = encodeVarintLiquidity(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 if len(m.PoolTypes) > 0 { for iNdEx := len(m.PoolTypes) - 1; iNdEx >= 0; iNdEx-- { { size, err := m.PoolTypes[iNdEx].MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintLiquidity(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa } } return len(dAtA) - i, nil } func (m *Pool) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *Pool) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *Pool) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.PoolCoinDenom) > 0 { i -= len(m.PoolCoinDenom) copy(dAtA[i:], m.PoolCoinDenom) i = encodeVarintLiquidity(dAtA, i, uint64(len(m.PoolCoinDenom))) i-- dAtA[i] = 0x2a } if len(m.ReserveAccountAddress) > 0 { i -= len(m.ReserveAccountAddress) copy(dAtA[i:], m.ReserveAccountAddress) i = encodeVarintLiquidity(dAtA, i, uint64(len(m.ReserveAccountAddress))) i-- dAtA[i] = 0x22 } if len(m.ReserveCoinDenoms) > 0 { for iNdEx := len(m.ReserveCoinDenoms) - 1; iNdEx >= 0; iNdEx-- { i -= len(m.ReserveCoinDenoms[iNdEx]) copy(dAtA[i:], m.ReserveCoinDenoms[iNdEx]) i = encodeVarintLiquidity(dAtA, i, uint64(len(m.ReserveCoinDenoms[iNdEx]))) i-- dAtA[i] = 0x1a } } if m.TypeId != 0 { i = encodeVarintLiquidity(dAtA, i, uint64(m.TypeId)) i-- dAtA[i] = 0x10 } if m.Id != 0 { i = encodeVarintLiquidity(dAtA, i, uint64(m.Id)) i-- dAtA[i] = 0x8 } return len(dAtA) - i, nil } func (m *PoolMetadata) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *PoolMetadata) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *PoolMetadata) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.ReserveCoins) > 0 { for iNdEx := len(m.ReserveCoins) - 1; iNdEx >= 0; iNdEx-- { { size, err := m.ReserveCoins[iNdEx].MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintLiquidity(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x1a } } { size, err := m.PoolCoinTotalSupply.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintLiquidity(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 if m.PoolId != 0 { i = encodeVarintLiquidity(dAtA, i, uint64(m.PoolId)) i-- dAtA[i] = 0x8 } return len(dAtA) - i, nil } func (m *PoolBatch) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *PoolBatch) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *PoolBatch) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.Executed { i-- if m.Executed { dAtA[i] = 1 } else { dAtA[i] = 0 } i-- dAtA[i] = 0x38 } if m.SwapMsgIndex != 0 { i = encodeVarintLiquidity(dAtA, i, uint64(m.SwapMsgIndex)) i-- dAtA[i] = 0x30 } if m.WithdrawMsgIndex != 0 { i = encodeVarintLiquidity(dAtA, i, uint64(m.WithdrawMsgIndex)) i-- dAtA[i] = 0x28 } if m.DepositMsgIndex != 0 { i = encodeVarintLiquidity(dAtA, i, uint64(m.DepositMsgIndex)) i-- dAtA[i] = 0x20 } if m.BeginHeight != 0 { i = encodeVarintLiquidity(dAtA, i, uint64(m.BeginHeight)) i-- dAtA[i] = 0x18 } if m.Index != 0 { i = encodeVarintLiquidity(dAtA, i, uint64(m.Index)) i-- dAtA[i] = 0x10 } if m.PoolId != 0 { i = encodeVarintLiquidity(dAtA, i, uint64(m.PoolId)) i-- dAtA[i] = 0x8 } return len(dAtA) - i, nil } func (m *DepositMsgState) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *DepositMsgState) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *DepositMsgState) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.Msg != nil { { size, err := m.Msg.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintLiquidity(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x32 } if m.ToBeDeleted { i-- if m.ToBeDeleted { dAtA[i] = 1 } else { dAtA[i] = 0 } i-- dAtA[i] = 0x28 } if m.Succeeded { i-- if m.Succeeded { dAtA[i] = 1 } else { dAtA[i] = 0 } i-- dAtA[i] = 0x20 } if m.Executed { i-- if m.Executed { dAtA[i] = 1 } else { dAtA[i] = 0 } i-- dAtA[i] = 0x18 } if m.MsgIndex != 0 { i = encodeVarintLiquidity(dAtA, i, uint64(m.MsgIndex)) i-- dAtA[i] = 0x10 } if m.MsgHeight != 0 { i = encodeVarintLiquidity(dAtA, i, uint64(m.MsgHeight)) i-- dAtA[i] = 0x8 } return len(dAtA) - i, nil } func (m *WithdrawMsgState) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *WithdrawMsgState) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *WithdrawMsgState) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.Msg != nil { { size, err := m.Msg.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintLiquidity(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x32 } if m.ToBeDeleted { i-- if m.ToBeDeleted { dAtA[i] = 1 } else { dAtA[i] = 0 } i-- dAtA[i] = 0x28 } if m.Succeeded { i-- if m.Succeeded { dAtA[i] = 1 } else { dAtA[i] = 0 } i-- dAtA[i] = 0x20 } if m.Executed { i-- if m.Executed { dAtA[i] = 1 } else { dAtA[i] = 0 } i-- dAtA[i] = 0x18 } if m.MsgIndex != 0 { i = encodeVarintLiquidity(dAtA, i, uint64(m.MsgIndex)) i-- dAtA[i] = 0x10 } if m.MsgHeight != 0 { i = encodeVarintLiquidity(dAtA, i, uint64(m.MsgHeight)) i-- dAtA[i] = 0x8 } return len(dAtA) - i, nil } func (m *SwapMsgState) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *SwapMsgState) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *SwapMsgState) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.Msg != nil { { size, err := m.Msg.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintLiquidity(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x52 } { size, err := m.ReservedOfferCoinFee.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintLiquidity(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x4a { size, err := m.RemainingOfferCoin.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintLiquidity(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x42 { size, err := m.ExchangedOfferCoin.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintLiquidity(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x3a if m.OrderExpiryHeight != 0 { i = encodeVarintLiquidity(dAtA, i, uint64(m.OrderExpiryHeight)) i-- dAtA[i] = 0x30 } if m.ToBeDeleted { i-- if m.ToBeDeleted { dAtA[i] = 1 } else { dAtA[i] = 0 } i-- dAtA[i] = 0x28 } if m.Succeeded { i-- if m.Succeeded { dAtA[i] = 1 } else { dAtA[i] = 0 } i-- dAtA[i] = 0x20 } if m.Executed { i-- if m.Executed { dAtA[i] = 1 } else { dAtA[i] = 0 } i-- dAtA[i] = 0x18 } if m.MsgIndex != 0 { i = encodeVarintLiquidity(dAtA, i, uint64(m.MsgIndex)) i-- dAtA[i] = 0x10 } if m.MsgHeight != 0 { i = encodeVarintLiquidity(dAtA, i, uint64(m.MsgHeight)) i-- dAtA[i] = 0x8 } return len(dAtA) - i, nil } func encodeVarintLiquidity(dAtA []byte, offset int, v uint64) int { offset -= sovLiquidity(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *PoolType) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.Id != 0 { n += 1 + sovLiquidity(uint64(m.Id)) } l = len(m.Name) if l > 0 { n += 1 + l + sovLiquidity(uint64(l)) } if m.MinReserveCoinNum != 0 { n += 1 + sovLiquidity(uint64(m.MinReserveCoinNum)) } if m.MaxReserveCoinNum != 0 { n += 1 + sovLiquidity(uint64(m.MaxReserveCoinNum)) } l = len(m.Description) if l > 0 { n += 1 + l + sovLiquidity(uint64(l)) } return n } func (m *Params) Size() (n int) { if m == nil { return 0 } var l int _ = l if len(m.PoolTypes) > 0 { for _, e := range m.PoolTypes { l = e.Size() n += 1 + l + sovLiquidity(uint64(l)) } } l = m.MinInitDepositAmount.Size() n += 1 + l + sovLiquidity(uint64(l)) l = m.InitPoolCoinMintAmount.Size() n += 1 + l + sovLiquidity(uint64(l)) l = m.MaxReserveCoinAmount.Size() n += 1 + l + sovLiquidity(uint64(l)) if len(m.PoolCreationFee) > 0 { for _, e := range m.PoolCreationFee { l = e.Size() n += 1 + l + sovLiquidity(uint64(l)) } } l = m.SwapFeeRate.Size() n += 1 + l + sovLiquidity(uint64(l)) l = m.WithdrawFeeRate.Size() n += 1 + l + sovLiquidity(uint64(l)) l = m.MaxOrderAmountRatio.Size() n += 1 + l + sovLiquidity(uint64(l)) if m.UnitBatchHeight != 0 { n += 1 + sovLiquidity(uint64(m.UnitBatchHeight)) } if m.CircuitBreakerEnabled { n += 2 } return n } func (m *Pool) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.Id != 0 { n += 1 + sovLiquidity(uint64(m.Id)) } if m.TypeId != 0 { n += 1 + sovLiquidity(uint64(m.TypeId)) } if len(m.ReserveCoinDenoms) > 0 { for _, s := range m.ReserveCoinDenoms { l = len(s) n += 1 + l + sovLiquidity(uint64(l)) } } l = len(m.ReserveAccountAddress) if l > 0 { n += 1 + l + sovLiquidity(uint64(l)) } l = len(m.PoolCoinDenom) if l > 0 { n += 1 + l + sovLiquidity(uint64(l)) } return n } func (m *PoolMetadata) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.PoolId != 0 { n += 1 + sovLiquidity(uint64(m.PoolId)) } l = m.PoolCoinTotalSupply.Size() n += 1 + l + sovLiquidity(uint64(l)) if len(m.ReserveCoins) > 0 { for _, e := range m.ReserveCoins { l = e.Size() n += 1 + l + sovLiquidity(uint64(l)) } } return n } func (m *PoolBatch) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.PoolId != 0 { n += 1 + sovLiquidity(uint64(m.PoolId)) } if m.Index != 0 { n += 1 + sovLiquidity(uint64(m.Index)) } if m.BeginHeight != 0 { n += 1 + sovLiquidity(uint64(m.BeginHeight)) } if m.DepositMsgIndex != 0 { n += 1 + sovLiquidity(uint64(m.DepositMsgIndex)) } if m.WithdrawMsgIndex != 0 { n += 1 + sovLiquidity(uint64(m.WithdrawMsgIndex)) } if m.SwapMsgIndex != 0 { n += 1 + sovLiquidity(uint64(m.SwapMsgIndex)) } if m.Executed { n += 2 } return n } func (m *DepositMsgState) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.MsgHeight != 0 { n += 1 + sovLiquidity(uint64(m.MsgHeight)) } if m.MsgIndex != 0 { n += 1 + sovLiquidity(uint64(m.MsgIndex)) } if m.Executed { n += 2 } if m.Succeeded { n += 2 } if m.ToBeDeleted { n += 2 } if m.Msg != nil { l = m.Msg.Size() n += 1 + l + sovLiquidity(uint64(l)) } return n } func (m *WithdrawMsgState) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.MsgHeight != 0 { n += 1 + sovLiquidity(uint64(m.MsgHeight)) } if m.MsgIndex != 0 { n += 1 + sovLiquidity(uint64(m.MsgIndex)) } if m.Executed { n += 2 } if m.Succeeded { n += 2 } if m.ToBeDeleted { n += 2 } if m.Msg != nil { l = m.Msg.Size() n += 1 + l + sovLiquidity(uint64(l)) } return n } func (m *SwapMsgState) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.MsgHeight != 0 { n += 1 + sovLiquidity(uint64(m.MsgHeight)) } if m.MsgIndex != 0 { n += 1 + sovLiquidity(uint64(m.MsgIndex)) } if m.Executed { n += 2 } if m.Succeeded { n += 2 } if m.ToBeDeleted { n += 2 } if m.OrderExpiryHeight != 0 { n += 1 + sovLiquidity(uint64(m.OrderExpiryHeight)) } l = m.ExchangedOfferCoin.Size() n += 1 + l + sovLiquidity(uint64(l)) l = m.RemainingOfferCoin.Size() n += 1 + l + sovLiquidity(uint64(l)) l = m.ReservedOfferCoinFee.Size() n += 1 + l + sovLiquidity(uint64(l)) if m.Msg != nil { l = m.Msg.Size() n += 1 + l + sovLiquidity(uint64(l)) } return n } func sovLiquidity(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozLiquidity(x uint64) (n int) { return sovLiquidity(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *PoolType) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: PoolType: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: PoolType: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field Id", wireType) } m.Id = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.Id |= uint32(b&0x7F) << shift if b < 0x80 { break } } case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthLiquidity } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthLiquidity } if postIndex > l { return io.ErrUnexpectedEOF } m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field MinReserveCoinNum", wireType) } m.MinReserveCoinNum = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.MinReserveCoinNum |= uint32(b&0x7F) << shift if b < 0x80 { break } } case 4: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field MaxReserveCoinNum", wireType) } m.MaxReserveCoinNum = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.MaxReserveCoinNum |= uint32(b&0x7F) << shift if b < 0x80 { break } } case 5: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Description", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthLiquidity } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthLiquidity } if postIndex > l { return io.ErrUnexpectedEOF } m.Description = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipLiquidity(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthLiquidity } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *Params) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: Params: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: Params: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field PoolTypes", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthLiquidity } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthLiquidity } if postIndex > l { return io.ErrUnexpectedEOF } m.PoolTypes = append(m.PoolTypes, PoolType{}) if err := m.PoolTypes[len(m.PoolTypes)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field MinInitDepositAmount", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthLiquidity } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthLiquidity } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.MinInitDepositAmount.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 3: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field InitPoolCoinMintAmount", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthLiquidity } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthLiquidity } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.InitPoolCoinMintAmount.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 4: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field MaxReserveCoinAmount", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthLiquidity } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthLiquidity } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.MaxReserveCoinAmount.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 5: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field PoolCreationFee", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthLiquidity } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthLiquidity } if postIndex > l { return io.ErrUnexpectedEOF } m.PoolCreationFee = append(m.PoolCreationFee, types.Coin{}) if err := m.PoolCreationFee[len(m.PoolCreationFee)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 6: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field SwapFeeRate", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthLiquidity } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthLiquidity } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.SwapFeeRate.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 7: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field WithdrawFeeRate", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthLiquidity } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthLiquidity } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.WithdrawFeeRate.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 8: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field MaxOrderAmountRatio", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthLiquidity } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthLiquidity } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.MaxOrderAmountRatio.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 9: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field UnitBatchHeight", wireType) } m.UnitBatchHeight = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.UnitBatchHeight |= uint32(b&0x7F) << shift if b < 0x80 { break } } case 10: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field CircuitBreakerEnabled", wireType) } var v int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ v |= int(b&0x7F) << shift if b < 0x80 { break } } m.CircuitBreakerEnabled = bool(v != 0) default: iNdEx = preIndex skippy, err := skipLiquidity(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthLiquidity } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *Pool) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: Pool: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: Pool: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field Id", wireType) } m.Id = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.Id |= uint64(b&0x7F) << shift if b < 0x80 { break } } case 2: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field TypeId", wireType) } m.TypeId = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.TypeId |= uint32(b&0x7F) << shift if b < 0x80 { break } } case 3: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field ReserveCoinDenoms", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthLiquidity } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthLiquidity } if postIndex > l { return io.ErrUnexpectedEOF } m.ReserveCoinDenoms = append(m.ReserveCoinDenoms, string(dAtA[iNdEx:postIndex])) iNdEx = postIndex case 4: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field ReserveAccountAddress", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthLiquidity } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthLiquidity } if postIndex > l { return io.ErrUnexpectedEOF } m.ReserveAccountAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 5: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field PoolCoinDenom", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthLiquidity } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthLiquidity } if postIndex > l { return io.ErrUnexpectedEOF } m.PoolCoinDenom = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipLiquidity(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthLiquidity } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *PoolMetadata) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: PoolMetadata: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: PoolMetadata: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field PoolId", wireType) } m.PoolId = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.PoolId |= uint64(b&0x7F) << shift if b < 0x80 { break } } case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field PoolCoinTotalSupply", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthLiquidity } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthLiquidity } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.PoolCoinTotalSupply.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 3: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field ReserveCoins", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthLiquidity } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthLiquidity } if postIndex > l { return io.ErrUnexpectedEOF } m.ReserveCoins = append(m.ReserveCoins, types.Coin{}) if err := m.ReserveCoins[len(m.ReserveCoins)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipLiquidity(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthLiquidity } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *PoolBatch) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: PoolBatch: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: PoolBatch: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field PoolId", wireType) } m.PoolId = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.PoolId |= uint64(b&0x7F) << shift if b < 0x80 { break } } case 2: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field Index", wireType) } m.Index = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.Index |= uint64(b&0x7F) << shift if b < 0x80 { break } } case 3: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field BeginHeight", wireType) } m.BeginHeight = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.BeginHeight |= int64(b&0x7F) << shift if b < 0x80 { break } } case 4: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field DepositMsgIndex", wireType) } m.DepositMsgIndex = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.DepositMsgIndex |= uint64(b&0x7F) << shift if b < 0x80 { break } } case 5: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field WithdrawMsgIndex", wireType) } m.WithdrawMsgIndex = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.WithdrawMsgIndex |= uint64(b&0x7F) << shift if b < 0x80 { break } } case 6: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field SwapMsgIndex", wireType) } m.SwapMsgIndex = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.SwapMsgIndex |= uint64(b&0x7F) << shift if b < 0x80 { break } } case 7: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field Executed", wireType) } var v int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ v |= int(b&0x7F) << shift if b < 0x80 { break } } m.Executed = bool(v != 0) default: iNdEx = preIndex skippy, err := skipLiquidity(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthLiquidity } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *DepositMsgState) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: DepositMsgState: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: DepositMsgState: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field MsgHeight", wireType) } m.MsgHeight = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.MsgHeight |= int64(b&0x7F) << shift if b < 0x80 { break } } case 2: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field MsgIndex", wireType) } m.MsgIndex = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.MsgIndex |= uint64(b&0x7F) << shift if b < 0x80 { break } } case 3: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field Executed", wireType) } var v int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ v |= int(b&0x7F) << shift if b < 0x80 { break } } m.Executed = bool(v != 0) case 4: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field Succeeded", wireType) } var v int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ v |= int(b&0x7F) << shift if b < 0x80 { break } } m.Succeeded = bool(v != 0) case 5: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field ToBeDeleted", wireType) } var v int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ v |= int(b&0x7F) << shift if b < 0x80 { break } } m.ToBeDeleted = bool(v != 0) case 6: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Msg", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthLiquidity } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthLiquidity } if postIndex > l { return io.ErrUnexpectedEOF } if m.Msg == nil { m.Msg = &MsgDepositWithinBatch{} } if err := m.Msg.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipLiquidity(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthLiquidity } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *WithdrawMsgState) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: WithdrawMsgState: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: WithdrawMsgState: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field MsgHeight", wireType) } m.MsgHeight = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.MsgHeight |= int64(b&0x7F) << shift if b < 0x80 { break } } case 2: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field MsgIndex", wireType) } m.MsgIndex = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.MsgIndex |= uint64(b&0x7F) << shift if b < 0x80 { break } } case 3: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field Executed", wireType) } var v int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ v |= int(b&0x7F) << shift if b < 0x80 { break } } m.Executed = bool(v != 0) case 4: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field Succeeded", wireType) } var v int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ v |= int(b&0x7F) << shift if b < 0x80 { break } } m.Succeeded = bool(v != 0) case 5: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field ToBeDeleted", wireType) } var v int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ v |= int(b&0x7F) << shift if b < 0x80 { break } } m.ToBeDeleted = bool(v != 0) case 6: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Msg", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthLiquidity } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthLiquidity } if postIndex > l { return io.ErrUnexpectedEOF } if m.Msg == nil { m.Msg = &MsgWithdrawWithinBatch{} } if err := m.Msg.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipLiquidity(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthLiquidity } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *SwapMsgState) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: SwapMsgState: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: SwapMsgState: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field MsgHeight", wireType) } m.MsgHeight = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.MsgHeight |= int64(b&0x7F) << shift if b < 0x80 { break } } case 2: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field MsgIndex", wireType) } m.MsgIndex = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.MsgIndex |= uint64(b&0x7F) << shift if b < 0x80 { break } } case 3: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field Executed", wireType) } var v int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ v |= int(b&0x7F) << shift if b < 0x80 { break } } m.Executed = bool(v != 0) case 4: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field Succeeded", wireType) } var v int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ v |= int(b&0x7F) << shift if b < 0x80 { break } } m.Succeeded = bool(v != 0) case 5: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field ToBeDeleted", wireType) } var v int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ v |= int(b&0x7F) << shift if b < 0x80 { break } } m.ToBeDeleted = bool(v != 0) case 6: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field OrderExpiryHeight", wireType) } m.OrderExpiryHeight = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.OrderExpiryHeight |= int64(b&0x7F) << shift if b < 0x80 { break } } case 7: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field ExchangedOfferCoin", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthLiquidity } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthLiquidity } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.ExchangedOfferCoin.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 8: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field RemainingOfferCoin", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthLiquidity } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthLiquidity } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.RemainingOfferCoin.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 9: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field ReservedOfferCoinFee", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthLiquidity } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthLiquidity } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.ReservedOfferCoinFee.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 10: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Msg", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowLiquidity } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthLiquidity } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthLiquidity } if postIndex > l { return io.ErrUnexpectedEOF } if m.Msg == nil { m.Msg = &MsgSwapWithinBatch{} } if err := m.Msg.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipLiquidity(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthLiquidity } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipLiquidity(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowLiquidity } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowLiquidity } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowLiquidity } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthLiquidity } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupLiquidity } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthLiquidity } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthLiquidity = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowLiquidity = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupLiquidity = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/liquidity/types/liquidity_pool.go ================================================ package types import ( "strconv" "strings" "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" ) // PoolName returns unique name of the pool consists of given reserve coin denoms and type id. func PoolName(reserveCoinDenoms []string, poolTypeID uint32) string { return strings.Join(append(SortDenoms(reserveCoinDenoms), strconv.FormatUint(uint64(poolTypeID), 10)), "/") } // Name returns the pool's name. func (pool Pool) Name() string { return PoolName(pool.ReserveCoinDenoms, pool.TypeId) } // Validate validates Pool. func (pool Pool) Validate() error { if pool.Id == 0 { return ErrPoolNotExists } if pool.TypeId == 0 { return ErrPoolTypeNotExists } if pool.ReserveCoinDenoms == nil || len(pool.ReserveCoinDenoms) == 0 { return ErrNumOfReserveCoinDenoms } if uint32(len(pool.ReserveCoinDenoms)) > MaxReserveCoinNum || uint32(len(pool.ReserveCoinDenoms)) < MinReserveCoinNum { return ErrNumOfReserveCoinDenoms } sortedDenomA, sortedDenomB := AlphabeticalDenomPair(pool.ReserveCoinDenoms[0], pool.ReserveCoinDenoms[1]) if sortedDenomA != pool.ReserveCoinDenoms[0] || sortedDenomB != pool.ReserveCoinDenoms[1] { return ErrBadOrderingReserveCoinDenoms } if pool.ReserveAccountAddress == "" { return ErrEmptyReserveAccountAddress } if pool.ReserveAccountAddress != GetPoolReserveAcc(pool.Name(), false).String() { return ErrBadReserveAccountAddress } if pool.PoolCoinDenom == "" { return ErrEmptyPoolCoinDenom } if pool.PoolCoinDenom != pool.Name() { return ErrBadPoolCoinDenom } return nil } // NewPoolBatch creates a new PoolBatch object. func NewPoolBatch(poolID, batchIndex uint64) PoolBatch { return PoolBatch{ PoolId: poolID, Index: batchIndex, BeginHeight: 0, DepositMsgIndex: 1, WithdrawMsgIndex: 1, SwapMsgIndex: 1, Executed: false, } } // MustMarshalPool returns the Pool bytes. Panics if fails. func MustMarshalPool(cdc codec.BinaryCodec, liquidityPool Pool) []byte { return cdc.MustMarshal(&liquidityPool) } // MustUnmarshalPool returns the Pool from bytes. Panics if fails. func MustUnmarshalPool(cdc codec.BinaryCodec, value []byte) Pool { liquidityPool, err := UnmarshalPool(cdc, value) if err != nil { panic(err) } return liquidityPool } // UnmarshalPool returns the Pool from bytes. func UnmarshalPool(cdc codec.BinaryCodec, value []byte) (liquidityPool Pool, err error) { err = cdc.Unmarshal(value, &liquidityPool) return liquidityPool, err } // GetReserveAccount returns sdk.AccAddress of the pool's reserve account. func (pool Pool) GetReserveAccount() sdk.AccAddress { addr, err := sdk.AccAddressFromBech32(pool.ReserveAccountAddress) if err != nil { panic(err) } return addr } // GetPoolCoinDenom returns the pool coin's denom. func (pool Pool) GetPoolCoinDenom() string { return pool.PoolCoinDenom } // GetId returns id of the pool. func (pool Pool) GetId() uint64 { return pool.Id } //nolint:revive // Pools is a collection of pools. type Pools []Pool func (pools Pools) String() (out string) { for _, del := range pools { out += del.String() + "\n" } return strings.TrimSpace(out) } // MustMarshalPoolBatch returns the PoolBatch bytes. Panics if fails. func MustMarshalPoolBatch(cdc codec.BinaryCodec, poolBatch PoolBatch) []byte { return cdc.MustMarshal(&poolBatch) } // UnmarshalPoolBatch returns the PoolBatch from bytes. func UnmarshalPoolBatch(cdc codec.BinaryCodec, value []byte) (poolBatch PoolBatch, err error) { err = cdc.Unmarshal(value, &poolBatch) return poolBatch, err } // MustUnmarshalPoolBatch returns the PoolBatch from bytes. Panics if fails. func MustUnmarshalPoolBatch(cdc codec.BinaryCodec, value []byte) PoolBatch { poolBatch, err := UnmarshalPoolBatch(cdc, value) if err != nil { panic(err) } return poolBatch } // MustMarshalDepositMsgState returns the DepositMsgState bytes. Panics if fails. func MustMarshalDepositMsgState(cdc codec.BinaryCodec, msg DepositMsgState) []byte { return cdc.MustMarshal(&msg) } // UnmarshalDepositMsgState returns the DepositMsgState from bytes. func UnmarshalDepositMsgState(cdc codec.BinaryCodec, value []byte) (msg DepositMsgState, err error) { err = cdc.Unmarshal(value, &msg) return msg, err } // MustUnmarshalDepositMsgState returns the DepositMsgState from bytes. Panics if fails. func MustUnmarshalDepositMsgState(cdc codec.BinaryCodec, value []byte) DepositMsgState { msg, err := UnmarshalDepositMsgState(cdc, value) if err != nil { panic(err) } return msg } // MustMarshalWithdrawMsgState returns the WithdrawMsgState bytes. Panics if fails. func MustMarshalWithdrawMsgState(cdc codec.BinaryCodec, msg WithdrawMsgState) []byte { return cdc.MustMarshal(&msg) } // UnmarshalWithdrawMsgState returns the WithdrawMsgState from bytes. func UnmarshalWithdrawMsgState(cdc codec.BinaryCodec, value []byte) (msg WithdrawMsgState, err error) { err = cdc.Unmarshal(value, &msg) return msg, err } // MustUnmarshalWithdrawMsgState returns the WithdrawMsgState from bytes. Panics if fails. func MustUnmarshalWithdrawMsgState(cdc codec.BinaryCodec, value []byte) WithdrawMsgState { msg, err := UnmarshalWithdrawMsgState(cdc, value) if err != nil { panic(err) } return msg } // MustMarshalSwapMsgState returns the SwapMsgState bytes. Panics if fails. func MustMarshalSwapMsgState(cdc codec.BinaryCodec, msg SwapMsgState) []byte { return cdc.MustMarshal(&msg) } // UnmarshalSwapMsgState returns the UnmarshalSwapMsgState from bytes. func UnmarshalSwapMsgState(cdc codec.BinaryCodec, value []byte) (msg SwapMsgState, err error) { err = cdc.Unmarshal(value, &msg) return msg, err } // MustUnmarshalSwapMsgState returns the SwapMsgState from bytes. Panics if fails. func MustUnmarshalSwapMsgState(cdc codec.BinaryCodec, value []byte) SwapMsgState { msg, err := UnmarshalSwapMsgState(cdc, value) if err != nil { panic(err) } return msg } ================================================ FILE: x/liquidity/types/msgs.go ================================================ package types import ( sdk "github.com/cosmos/cosmos-sdk/types" ) var ( _ sdk.Msg = (*MsgCreatePool)(nil) _ sdk.Msg = (*MsgDepositWithinBatch)(nil) _ sdk.Msg = (*MsgWithdrawWithinBatch)(nil) _ sdk.Msg = (*MsgSwapWithinBatch)(nil) ) // Message types for the liquidity module // //nolint:gosec const ( TypeMsgCreatePool = "create_pool" TypeMsgDepositWithinBatch = "deposit_within_batch" TypeMsgWithdrawWithinBatch = "withdraw_within_batch" TypeMsgSwapWithinBatch = "swap_within_batch" ) // NewMsgCreatePool creates a new MsgCreatePool. func NewMsgCreatePool(poolCreator sdk.AccAddress, poolTypeID uint32, depositCoins sdk.Coins) *MsgCreatePool { return &MsgCreatePool{ PoolCreatorAddress: poolCreator.String(), PoolTypeId: poolTypeID, DepositCoins: depositCoins, } } func (msg MsgCreatePool) Route() string { return RouterKey } func (msg MsgCreatePool) Type() string { return TypeMsgCreatePool } func (msg MsgCreatePool) ValidateBasic() error { if 1 > msg.PoolTypeId { return ErrBadPoolTypeID } if _, err := sdk.AccAddressFromBech32(msg.PoolCreatorAddress); err != nil { return ErrInvalidPoolCreatorAddr } if err := msg.DepositCoins.Validate(); err != nil { return err } if n := uint32(len(msg.DepositCoins)); n > MaxReserveCoinNum || n < MinReserveCoinNum { return ErrNumOfReserveCoin } return nil } func (msg MsgCreatePool) GetSignBytes() []byte { return sdk.MustSortJSON(ModuleCdc.MustMarshalJSON(&msg)) } func (msg MsgCreatePool) GetSigners() []sdk.AccAddress { addr, err := sdk.AccAddressFromBech32(msg.PoolCreatorAddress) if err != nil { panic(err) } return []sdk.AccAddress{addr} } func (msg MsgCreatePool) GetPoolCreator() sdk.AccAddress { addr, err := sdk.AccAddressFromBech32(msg.PoolCreatorAddress) if err != nil { panic(err) } return addr } // NewMsgDepositWithinBatch creates a new MsgDepositWithinBatch. func NewMsgDepositWithinBatch(depositor sdk.AccAddress, poolID uint64, depositCoins sdk.Coins) *MsgDepositWithinBatch { return &MsgDepositWithinBatch{ DepositorAddress: depositor.String(), PoolId: poolID, DepositCoins: depositCoins, } } func (msg MsgDepositWithinBatch) Route() string { return RouterKey } func (msg MsgDepositWithinBatch) Type() string { return TypeMsgDepositWithinBatch } func (msg MsgDepositWithinBatch) ValidateBasic() error { if _, err := sdk.AccAddressFromBech32(msg.DepositorAddress); err != nil { return ErrInvalidDepositorAddr } if err := msg.DepositCoins.Validate(); err != nil { return err } if !msg.DepositCoins.IsAllPositive() { return ErrBadDepositCoinsAmount } if n := uint32(len(msg.DepositCoins)); n > MaxReserveCoinNum || n < MinReserveCoinNum { return ErrNumOfReserveCoin } return nil } func (msg MsgDepositWithinBatch) GetSignBytes() []byte { return sdk.MustSortJSON(ModuleCdc.MustMarshalJSON(&msg)) } func (msg MsgDepositWithinBatch) GetSigners() []sdk.AccAddress { addr, err := sdk.AccAddressFromBech32(msg.DepositorAddress) if err != nil { panic(err) } return []sdk.AccAddress{addr} } func (msg MsgDepositWithinBatch) GetDepositor() sdk.AccAddress { addr, err := sdk.AccAddressFromBech32(msg.DepositorAddress) if err != nil { panic(err) } return addr } // NewMsgWithdrawWithinBatch creates a new MsgWithdrawWithinBatch. func NewMsgWithdrawWithinBatch(withdrawer sdk.AccAddress, poolID uint64, poolCoin sdk.Coin) *MsgWithdrawWithinBatch { return &MsgWithdrawWithinBatch{ WithdrawerAddress: withdrawer.String(), PoolId: poolID, PoolCoin: poolCoin, } } func (msg MsgWithdrawWithinBatch) Route() string { return RouterKey } func (msg MsgWithdrawWithinBatch) Type() string { return TypeMsgWithdrawWithinBatch } func (msg MsgWithdrawWithinBatch) ValidateBasic() error { if _, err := sdk.AccAddressFromBech32(msg.WithdrawerAddress); err != nil { return ErrInvalidWithdrawerAddr } if err := msg.PoolCoin.Validate(); err != nil { return err } if !msg.PoolCoin.IsPositive() { return ErrBadPoolCoinAmount } return nil } func (msg MsgWithdrawWithinBatch) GetSignBytes() []byte { return sdk.MustSortJSON(ModuleCdc.MustMarshalJSON(&msg)) } func (msg MsgWithdrawWithinBatch) GetSigners() []sdk.AccAddress { addr, err := sdk.AccAddressFromBech32(msg.WithdrawerAddress) if err != nil { panic(err) } return []sdk.AccAddress{addr} } func (msg MsgWithdrawWithinBatch) GetWithdrawer() sdk.AccAddress { addr, err := sdk.AccAddressFromBech32(msg.WithdrawerAddress) if err != nil { panic(err) } return addr } // NewMsgSwapWithinBatch creates a new MsgSwapWithinBatch. func NewMsgSwapWithinBatch( swapRequester sdk.AccAddress, poolID uint64, swapTypeID uint32, offerCoin sdk.Coin, demandCoinDenom string, orderPrice sdk.Dec, swapFeeRate sdk.Dec, ) *MsgSwapWithinBatch { return &MsgSwapWithinBatch{ SwapRequesterAddress: swapRequester.String(), PoolId: poolID, SwapTypeId: swapTypeID, OfferCoin: offerCoin, OfferCoinFee: GetOfferCoinFee(offerCoin, swapFeeRate), DemandCoinDenom: demandCoinDenom, OrderPrice: orderPrice, } } func (msg MsgSwapWithinBatch) Route() string { return RouterKey } func (msg MsgSwapWithinBatch) Type() string { return TypeMsgSwapWithinBatch } func (msg MsgSwapWithinBatch) ValidateBasic() error { if _, err := sdk.AccAddressFromBech32(msg.SwapRequesterAddress); err != nil { return ErrInvalidSwapRequesterAddr } if err := msg.OfferCoin.Validate(); err != nil { return err } if !msg.OfferCoin.IsPositive() { return ErrBadOfferCoinAmount } if !msg.OrderPrice.IsPositive() { return ErrBadOrderPrice } if !msg.OfferCoin.Amount.GTE(MinOfferCoinAmount) { return ErrLessThanMinOfferAmount } return nil } func (msg MsgSwapWithinBatch) GetSignBytes() []byte { return sdk.MustSortJSON(ModuleCdc.MustMarshalJSON(&msg)) } func (msg MsgSwapWithinBatch) GetSigners() []sdk.AccAddress { addr, err := sdk.AccAddressFromBech32(msg.SwapRequesterAddress) if err != nil { panic(err) } return []sdk.AccAddress{addr} } func (msg MsgSwapWithinBatch) GetSwapRequester() sdk.AccAddress { addr, err := sdk.AccAddressFromBech32(msg.SwapRequesterAddress) if err != nil { panic(err) } return addr } ================================================ FILE: x/liquidity/types/params.go ================================================ package types import ( "fmt" "cosmossdk.io/math" sdk "github.com/cosmos/cosmos-sdk/types" "gopkg.in/yaml.v2" ) const ( // CancelOrderLifeSpan is the lifespan of order cancellation. CancelOrderLifeSpan int64 = 0 // MinReserveCoinNum is the minimum number of reserve coins in each liquidity pool. MinReserveCoinNum uint32 = 2 // MaxReserveCoinNum is the maximum number of reserve coins in each liquidity pool. MaxReserveCoinNum uint32 = 2 // DefaultUnitBatchHeight is the default number of blocks in one batch. This param is used for scalability. DefaultUnitBatchHeight uint32 = 1 // DefaultPoolTypeID is the default pool type id. The only supported pool type id is 1. DefaultPoolTypeID uint32 = 1 // DefaultSwapTypeID is the default swap type id. The only supported swap type (instant swap) id is 1. DefaultSwapTypeID uint32 = 1 // DefaultCircuitBreakerEnabled is the default circuit breaker status. This param is used for a contingency plan. DefaultCircuitBreakerEnabled = false ) // Parameter store keys var ( KeyPoolTypes = []byte("PoolTypes") KeyMinInitDepositAmount = []byte("MinInitDepositAmount") KeyInitPoolCoinMintAmount = []byte("InitPoolCoinMintAmount") KeyMaxReserveCoinAmount = []byte("MaxReserveCoinAmount") KeySwapFeeRate = []byte("SwapFeeRate") KeyPoolCreationFee = []byte("PoolCreationFee") KeyUnitBatchHeight = []byte("UnitBatchHeight") KeyWithdrawFeeRate = []byte("WithdrawFeeRate") KeyMaxOrderAmountRatio = []byte("MaxOrderAmountRatio") KeyCircuitBreakerEnabled = []byte("CircuitBreakerEnabled") ) var ( DefaultMinInitDepositAmount = sdk.NewInt(1000000) DefaultInitPoolCoinMintAmount = sdk.NewInt(1000000) DefaultMaxReserveCoinAmount = sdk.ZeroInt() DefaultSwapFeeRate = sdk.NewDecWithPrec(3, 3) // "0.003000000000000000" DefaultWithdrawFeeRate = sdk.ZeroDec() DefaultMaxOrderAmountRatio = sdk.NewDecWithPrec(1, 1) // "0.100000000000000000" DefaultPoolCreationFee = sdk.NewCoins(sdk.NewCoin(sdk.DefaultBondDenom, sdk.NewInt(40000000))) DefaultPoolType = PoolType{ Id: 1, Name: "StandardLiquidityPool", MinReserveCoinNum: MinReserveCoinNum, MaxReserveCoinNum: MaxReserveCoinNum, Description: "Standard liquidity pool with pool price function X/Y, ESPM constraint, and two kinds of reserve coins", } DefaultPoolTypes = []PoolType{DefaultPoolType} MinOfferCoinAmount = sdk.NewInt(100) ) // DefaultParams returns the default liquidity module parameters. func DefaultParams() Params { return Params{ PoolTypes: DefaultPoolTypes, MinInitDepositAmount: DefaultMinInitDepositAmount, InitPoolCoinMintAmount: DefaultInitPoolCoinMintAmount, MaxReserveCoinAmount: DefaultMaxReserveCoinAmount, PoolCreationFee: DefaultPoolCreationFee, SwapFeeRate: DefaultSwapFeeRate, WithdrawFeeRate: DefaultWithdrawFeeRate, MaxOrderAmountRatio: DefaultMaxOrderAmountRatio, UnitBatchHeight: DefaultUnitBatchHeight, CircuitBreakerEnabled: DefaultCircuitBreakerEnabled, } } // String returns a human readable string representation of the parameters. func (p Params) String() string { out, _ := yaml.Marshal(p) return string(out) } // Validate validates parameters. func (p Params) Validate() error { for _, v := range []struct { value interface{} validator func(interface{}) error }{ {p.PoolTypes, validatePoolTypes}, {p.MinInitDepositAmount, validateMinInitDepositAmount}, {p.InitPoolCoinMintAmount, validateInitPoolCoinMintAmount}, {p.MaxReserveCoinAmount, validateMaxReserveCoinAmount}, {p.PoolCreationFee, validatePoolCreationFee}, {p.SwapFeeRate, validateSwapFeeRate}, {p.WithdrawFeeRate, validateWithdrawFeeRate}, {p.MaxOrderAmountRatio, validateMaxOrderAmountRatio}, {p.UnitBatchHeight, validateUnitBatchHeight}, {p.CircuitBreakerEnabled, validateCircuitBreakerEnabled}, } { if err := v.validator(v.value); err != nil { return err } } return nil } func validatePoolTypes(i interface{}) error { v, ok := i.([]PoolType) if !ok { return fmt.Errorf("invalid parameter type: %T", i) } if len(v) == 0 { return fmt.Errorf("pool types must not be empty") } for i, p := range v { if int(p.Id) != i+1 { return fmt.Errorf("pool type ids must be sorted") } if p.MaxReserveCoinNum > MaxReserveCoinNum || MinReserveCoinNum > p.MinReserveCoinNum { return fmt.Errorf("min, max reserve coin num value of pool types are out of bounds") } } if len(v) > 1 || !v[0].Equal(DefaultPoolType) { return fmt.Errorf("the only supported pool type is 1") } return nil } //nolint:staticcheck,nolintlint func validateMinInitDepositAmount(i interface{}) error { v, ok := i.(math.Int) if !ok { return fmt.Errorf("invalid parameter type: %T", i) } if v.IsNil() { return fmt.Errorf("minimum initial deposit amount must not be nil") } if !v.IsPositive() { return fmt.Errorf("minimum initial deposit amount must be positive: %s", v) } return nil } //nolint:staticcheck,nolintlint func validateInitPoolCoinMintAmount(i interface{}) error { v, ok := i.(math.Int) if !ok { return fmt.Errorf("invalid parameter type: %T", i) } if v.IsNil() { return fmt.Errorf("initial pool coin mint amount must not be nil") } if !v.IsPositive() { return fmt.Errorf("initial pool coin mint amount must be positive: %s", v) } if v.LT(DefaultInitPoolCoinMintAmount) { return fmt.Errorf("initial pool coin mint amount must be greater than or equal to 1000000: %s", v) } return nil } //nolint:staticcheck,nolintlint func validateMaxReserveCoinAmount(i interface{}) error { v, ok := i.(math.Int) if !ok { return fmt.Errorf("invalid parameter type: %T", i) } if v.IsNil() { return fmt.Errorf("max reserve coin amount must not be nil") } if v.IsNegative() { return fmt.Errorf("max reserve coin amount must not be negative: %s", v) } return nil } func validateSwapFeeRate(i interface{}) error { v, ok := i.(sdk.Dec) //nolint:nolintlint if !ok { return fmt.Errorf("invalid parameter type: %T", i) } if v.IsNil() { return fmt.Errorf("swap fee rate must not be nil") } if v.IsNegative() { return fmt.Errorf("swap fee rate must not be negative: %s", v) } if v.GT(sdk.OneDec()) { return fmt.Errorf("swap fee rate too large: %s", v) } return nil } func validateWithdrawFeeRate(i interface{}) error { v, ok := i.(sdk.Dec) //nolint:nolintlint if !ok { return fmt.Errorf("invalid parameter type: %T", i) } if v.IsNil() { return fmt.Errorf("withdraw fee rate must not be nil") } if v.IsNegative() { return fmt.Errorf("withdraw fee rate must not be negative: %s", v) } if v.GT(sdk.OneDec()) { return fmt.Errorf("withdraw fee rate too large: %s", v) } return nil } func validateMaxOrderAmountRatio(i interface{}) error { v, ok := i.(sdk.Dec) //nolint:nolintlint if !ok { return fmt.Errorf("invalid parameter type: %T", i) } if v.IsNil() { return fmt.Errorf("max order amount ratio must not be nil") } if v.IsNegative() { return fmt.Errorf("max order amount ratio must not be negative: %s", v) } if v.GT(sdk.OneDec()) { return fmt.Errorf("max order amount ratio too large: %s", v) } return nil } func validatePoolCreationFee(i interface{}) error { v, ok := i.(sdk.Coins) if !ok { return fmt.Errorf("invalid parameter type: %T", i) } if err := v.Validate(); err != nil { return err } if v.Empty() { return fmt.Errorf("pool creation fee must not be empty") } return nil } func validateUnitBatchHeight(i interface{}) error { v, ok := i.(uint32) if !ok { return fmt.Errorf("invalid parameter type: %T", i) } if v == 0 { return fmt.Errorf("unit batch height must be positive: %d", v) } return nil } func validateCircuitBreakerEnabled(i interface{}) error { _, ok := i.(bool) if !ok { return fmt.Errorf("invalid parameter type: %T", i) } return nil } ================================================ FILE: x/liquidity/types/params_legacy.go ================================================ package types import paramstypes "github.com/cosmos/cosmos-sdk/x/params/types" // Deprecated: Type declaration for parameters func ParamKeyTable() paramstypes.KeyTable { return paramstypes.NewKeyTable().RegisterParamSet(&Params{}) } // ParamSetPairs implements paramstypes.ParamSet. func (p *Params) ParamSetPairs() paramstypes.ParamSetPairs { return paramstypes.ParamSetPairs{ paramstypes.NewParamSetPair(KeyPoolTypes, &p.PoolTypes, validatePoolTypes), paramstypes.NewParamSetPair(KeyMinInitDepositAmount, &p.MinInitDepositAmount, validateMinInitDepositAmount), paramstypes.NewParamSetPair(KeyInitPoolCoinMintAmount, &p.InitPoolCoinMintAmount, validateInitPoolCoinMintAmount), paramstypes.NewParamSetPair(KeyMaxReserveCoinAmount, &p.MaxReserveCoinAmount, validateMaxReserveCoinAmount), paramstypes.NewParamSetPair(KeyPoolCreationFee, &p.PoolCreationFee, validatePoolCreationFee), paramstypes.NewParamSetPair(KeySwapFeeRate, &p.SwapFeeRate, validateSwapFeeRate), paramstypes.NewParamSetPair(KeyWithdrawFeeRate, &p.WithdrawFeeRate, validateWithdrawFeeRate), paramstypes.NewParamSetPair(KeyMaxOrderAmountRatio, &p.MaxOrderAmountRatio, validateMaxOrderAmountRatio), paramstypes.NewParamSetPair(KeyUnitBatchHeight, &p.UnitBatchHeight, validateUnitBatchHeight), paramstypes.NewParamSetPair(KeyCircuitBreakerEnabled, &p.CircuitBreakerEnabled, validateCircuitBreakerEnabled), } } ================================================ FILE: x/liquidity/types/querier.go ================================================ package types // DONTCOVER // client is excluded from test coverage in the poc phase milestone 1 and will be included in milestone 2 with completeness // QueryLiquidityPool liquidity query endpoint supported by the liquidity querier const ( QueryLiquidityPool = "liquidityPool" QueryLiquidityPools = "liquidityPools" ) // QueryLiquidityPoolParams is the query parameters for 'custom/liquidity' type QueryLiquidityPoolParams struct { PoolId uint64 `json:"pool_id" yaml:"pool_id"` // nolint:revive,nolintlint } // return params of Liquidity Pool Query func NewQueryLiquidityPoolParams(poolID uint64) QueryLiquidityPoolParams { return QueryLiquidityPoolParams{ PoolId: poolID, } } // QueryLiquidityPoolsParams defines the params for the following queries: // - 'custom/liquidity/liquidityPools' type QueryLiquidityPoolsParams struct { Page, Limit int } // return params of Liquidity Pools Query func NewQueryLiquidityPoolsParams(page, limit int) QueryLiquidityPoolsParams { return QueryLiquidityPoolsParams{page, limit} } ================================================ FILE: x/liquidity/types/query.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: cyber/liquidity/v1beta1/query.proto package types import ( context "context" fmt "fmt" io "io" math "math" math_bits "math/bits" query "github.com/cosmos/cosmos-sdk/types/query" _ "github.com/cosmos/gogoproto/gogoproto" grpc1 "github.com/cosmos/gogoproto/grpc" proto "github.com/cosmos/gogoproto/proto" _ "google.golang.org/genproto/googleapis/api/annotations" grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" ) // Reference imports to suppress errors if they are not otherwise used. var ( _ = proto.Marshal _ = fmt.Errorf _ = math.Inf ) // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package // the request type for the QueryLiquidityPool RPC method. requestable specified // pool_id. type QueryLiquidityPoolRequest struct { PoolId uint64 `protobuf:"varint,1,opt,name=pool_id,json=poolId,proto3" json:"pool_id,omitempty"` } func (m *QueryLiquidityPoolRequest) Reset() { *m = QueryLiquidityPoolRequest{} } func (m *QueryLiquidityPoolRequest) String() string { return proto.CompactTextString(m) } func (*QueryLiquidityPoolRequest) ProtoMessage() {} func (*QueryLiquidityPoolRequest) Descriptor() ([]byte, []int) { return fileDescriptor_456c121a8965f63a, []int{0} } func (m *QueryLiquidityPoolRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryLiquidityPoolRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryLiquidityPoolRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryLiquidityPoolRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryLiquidityPoolRequest.Merge(m, src) } func (m *QueryLiquidityPoolRequest) XXX_Size() int { return m.Size() } func (m *QueryLiquidityPoolRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryLiquidityPoolRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryLiquidityPoolRequest proto.InternalMessageInfo func (m *QueryLiquidityPoolRequest) GetPoolId() uint64 { if m != nil { return m.PoolId } return 0 } // the response type for the QueryLiquidityPoolResponse RPC method. Returns the // liquidity pool that corresponds to the requested pool_id. type QueryLiquidityPoolResponse struct { Pool Pool `protobuf:"bytes,1,opt,name=pool,proto3" json:"pool"` } func (m *QueryLiquidityPoolResponse) Reset() { *m = QueryLiquidityPoolResponse{} } func (m *QueryLiquidityPoolResponse) String() string { return proto.CompactTextString(m) } func (*QueryLiquidityPoolResponse) ProtoMessage() {} func (*QueryLiquidityPoolResponse) Descriptor() ([]byte, []int) { return fileDescriptor_456c121a8965f63a, []int{1} } func (m *QueryLiquidityPoolResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryLiquidityPoolResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryLiquidityPoolResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryLiquidityPoolResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryLiquidityPoolResponse.Merge(m, src) } func (m *QueryLiquidityPoolResponse) XXX_Size() int { return m.Size() } func (m *QueryLiquidityPoolResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryLiquidityPoolResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryLiquidityPoolResponse proto.InternalMessageInfo func (m *QueryLiquidityPoolResponse) GetPool() Pool { if m != nil { return m.Pool } return Pool{} } // the request type for the QueryLiquidityByPoolCoinDenomPool RPC method. // Requestable specified pool_coin_denom. type QueryLiquidityPoolByPoolCoinDenomRequest struct { PoolCoinDenom string `protobuf:"bytes,1,opt,name=pool_coin_denom,json=poolCoinDenom,proto3" json:"pool_coin_denom,omitempty"` } func (m *QueryLiquidityPoolByPoolCoinDenomRequest) Reset() { *m = QueryLiquidityPoolByPoolCoinDenomRequest{} } func (m *QueryLiquidityPoolByPoolCoinDenomRequest) String() string { return proto.CompactTextString(m) } func (*QueryLiquidityPoolByPoolCoinDenomRequest) ProtoMessage() {} func (*QueryLiquidityPoolByPoolCoinDenomRequest) Descriptor() ([]byte, []int) { return fileDescriptor_456c121a8965f63a, []int{2} } func (m *QueryLiquidityPoolByPoolCoinDenomRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryLiquidityPoolByPoolCoinDenomRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryLiquidityPoolByPoolCoinDenomRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryLiquidityPoolByPoolCoinDenomRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryLiquidityPoolByPoolCoinDenomRequest.Merge(m, src) } func (m *QueryLiquidityPoolByPoolCoinDenomRequest) XXX_Size() int { return m.Size() } func (m *QueryLiquidityPoolByPoolCoinDenomRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryLiquidityPoolByPoolCoinDenomRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryLiquidityPoolByPoolCoinDenomRequest proto.InternalMessageInfo func (m *QueryLiquidityPoolByPoolCoinDenomRequest) GetPoolCoinDenom() string { if m != nil { return m.PoolCoinDenom } return "" } // the request type for the QueryLiquidityByReserveAcc RPC method. Requestable // specified reserve_acc. type QueryLiquidityPoolByReserveAccRequest struct { ReserveAcc string `protobuf:"bytes,1,opt,name=reserve_acc,json=reserveAcc,proto3" json:"reserve_acc,omitempty"` } func (m *QueryLiquidityPoolByReserveAccRequest) Reset() { *m = QueryLiquidityPoolByReserveAccRequest{} } func (m *QueryLiquidityPoolByReserveAccRequest) String() string { return proto.CompactTextString(m) } func (*QueryLiquidityPoolByReserveAccRequest) ProtoMessage() {} func (*QueryLiquidityPoolByReserveAccRequest) Descriptor() ([]byte, []int) { return fileDescriptor_456c121a8965f63a, []int{3} } func (m *QueryLiquidityPoolByReserveAccRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryLiquidityPoolByReserveAccRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryLiquidityPoolByReserveAccRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryLiquidityPoolByReserveAccRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryLiquidityPoolByReserveAccRequest.Merge(m, src) } func (m *QueryLiquidityPoolByReserveAccRequest) XXX_Size() int { return m.Size() } func (m *QueryLiquidityPoolByReserveAccRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryLiquidityPoolByReserveAccRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryLiquidityPoolByReserveAccRequest proto.InternalMessageInfo func (m *QueryLiquidityPoolByReserveAccRequest) GetReserveAcc() string { if m != nil { return m.ReserveAcc } return "" } // the request type for the QueryLiquidityPoolBatch RPC method. requestable // including specified pool_id. type QueryLiquidityPoolBatchRequest struct { // id of the target pool for query PoolId uint64 `protobuf:"varint,1,opt,name=pool_id,json=poolId,proto3" json:"pool_id,omitempty"` } func (m *QueryLiquidityPoolBatchRequest) Reset() { *m = QueryLiquidityPoolBatchRequest{} } func (m *QueryLiquidityPoolBatchRequest) String() string { return proto.CompactTextString(m) } func (*QueryLiquidityPoolBatchRequest) ProtoMessage() {} func (*QueryLiquidityPoolBatchRequest) Descriptor() ([]byte, []int) { return fileDescriptor_456c121a8965f63a, []int{4} } func (m *QueryLiquidityPoolBatchRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryLiquidityPoolBatchRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryLiquidityPoolBatchRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryLiquidityPoolBatchRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryLiquidityPoolBatchRequest.Merge(m, src) } func (m *QueryLiquidityPoolBatchRequest) XXX_Size() int { return m.Size() } func (m *QueryLiquidityPoolBatchRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryLiquidityPoolBatchRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryLiquidityPoolBatchRequest proto.InternalMessageInfo func (m *QueryLiquidityPoolBatchRequest) GetPoolId() uint64 { if m != nil { return m.PoolId } return 0 } // the response type for the QueryLiquidityPoolBatchResponse RPC method. Returns // the liquidity pool batch that corresponds to the requested pool_id. type QueryLiquidityPoolBatchResponse struct { Batch PoolBatch `protobuf:"bytes,1,opt,name=batch,proto3" json:"batch"` } func (m *QueryLiquidityPoolBatchResponse) Reset() { *m = QueryLiquidityPoolBatchResponse{} } func (m *QueryLiquidityPoolBatchResponse) String() string { return proto.CompactTextString(m) } func (*QueryLiquidityPoolBatchResponse) ProtoMessage() {} func (*QueryLiquidityPoolBatchResponse) Descriptor() ([]byte, []int) { return fileDescriptor_456c121a8965f63a, []int{5} } func (m *QueryLiquidityPoolBatchResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryLiquidityPoolBatchResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryLiquidityPoolBatchResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryLiquidityPoolBatchResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryLiquidityPoolBatchResponse.Merge(m, src) } func (m *QueryLiquidityPoolBatchResponse) XXX_Size() int { return m.Size() } func (m *QueryLiquidityPoolBatchResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryLiquidityPoolBatchResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryLiquidityPoolBatchResponse proto.InternalMessageInfo func (m *QueryLiquidityPoolBatchResponse) GetBatch() PoolBatch { if m != nil { return m.Batch } return PoolBatch{} } // the request type for the QueryLiquidityPools RPC method. Requestable // including pagination offset, limit, key. type QueryLiquidityPoolsRequest struct { // pagination defines an optional pagination for the request. Pagination *query.PageRequest `protobuf:"bytes,1,opt,name=pagination,proto3" json:"pagination,omitempty"` } func (m *QueryLiquidityPoolsRequest) Reset() { *m = QueryLiquidityPoolsRequest{} } func (m *QueryLiquidityPoolsRequest) String() string { return proto.CompactTextString(m) } func (*QueryLiquidityPoolsRequest) ProtoMessage() {} func (*QueryLiquidityPoolsRequest) Descriptor() ([]byte, []int) { return fileDescriptor_456c121a8965f63a, []int{6} } func (m *QueryLiquidityPoolsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryLiquidityPoolsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryLiquidityPoolsRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryLiquidityPoolsRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryLiquidityPoolsRequest.Merge(m, src) } func (m *QueryLiquidityPoolsRequest) XXX_Size() int { return m.Size() } func (m *QueryLiquidityPoolsRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryLiquidityPoolsRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryLiquidityPoolsRequest proto.InternalMessageInfo func (m *QueryLiquidityPoolsRequest) GetPagination() *query.PageRequest { if m != nil { return m.Pagination } return nil } // the response type for the QueryLiquidityPoolsResponse RPC method. This // includes a list of all existing liquidity pools and paging results that // contain next_key and total count. type QueryLiquidityPoolsResponse struct { Pools []Pool `protobuf:"bytes,1,rep,name=pools,proto3" json:"pools"` // pagination defines the pagination in the response. not working on this // version. Pagination *query.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` } func (m *QueryLiquidityPoolsResponse) Reset() { *m = QueryLiquidityPoolsResponse{} } func (m *QueryLiquidityPoolsResponse) String() string { return proto.CompactTextString(m) } func (*QueryLiquidityPoolsResponse) ProtoMessage() {} func (*QueryLiquidityPoolsResponse) Descriptor() ([]byte, []int) { return fileDescriptor_456c121a8965f63a, []int{7} } func (m *QueryLiquidityPoolsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryLiquidityPoolsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryLiquidityPoolsResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryLiquidityPoolsResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryLiquidityPoolsResponse.Merge(m, src) } func (m *QueryLiquidityPoolsResponse) XXX_Size() int { return m.Size() } func (m *QueryLiquidityPoolsResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryLiquidityPoolsResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryLiquidityPoolsResponse proto.InternalMessageInfo func (m *QueryLiquidityPoolsResponse) GetPools() []Pool { if m != nil { return m.Pools } return nil } func (m *QueryLiquidityPoolsResponse) GetPagination() *query.PageResponse { if m != nil { return m.Pagination } return nil } // QueryParamsRequest is request type for the QueryParams RPC method. type QueryParamsRequest struct{} func (m *QueryParamsRequest) Reset() { *m = QueryParamsRequest{} } func (m *QueryParamsRequest) String() string { return proto.CompactTextString(m) } func (*QueryParamsRequest) ProtoMessage() {} func (*QueryParamsRequest) Descriptor() ([]byte, []int) { return fileDescriptor_456c121a8965f63a, []int{8} } func (m *QueryParamsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryParamsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryParamsRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryParamsRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryParamsRequest.Merge(m, src) } func (m *QueryParamsRequest) XXX_Size() int { return m.Size() } func (m *QueryParamsRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryParamsRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryParamsRequest proto.InternalMessageInfo // the response type for the QueryParamsResponse RPC method. This includes // current parameter of the liquidity module. type QueryParamsResponse struct { // params holds all the parameters of this module. Params Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params"` } func (m *QueryParamsResponse) Reset() { *m = QueryParamsResponse{} } func (m *QueryParamsResponse) String() string { return proto.CompactTextString(m) } func (*QueryParamsResponse) ProtoMessage() {} func (*QueryParamsResponse) Descriptor() ([]byte, []int) { return fileDescriptor_456c121a8965f63a, []int{9} } func (m *QueryParamsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryParamsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryParamsResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryParamsResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryParamsResponse.Merge(m, src) } func (m *QueryParamsResponse) XXX_Size() int { return m.Size() } func (m *QueryParamsResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryParamsResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryParamsResponse proto.InternalMessageInfo func (m *QueryParamsResponse) GetParams() Params { if m != nil { return m.Params } return Params{} } // the request type for the QueryPoolBatchSwapMsgs RPC method. Requestable // including specified pool_id and pagination offset, limit, key. type QueryPoolBatchSwapMsgsRequest struct { // id of the target pool for query PoolId uint64 `protobuf:"varint,1,opt,name=pool_id,json=poolId,proto3" json:"pool_id,omitempty"` // pagination defines an optional pagination for the request. Pagination *query.PageRequest `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` } func (m *QueryPoolBatchSwapMsgsRequest) Reset() { *m = QueryPoolBatchSwapMsgsRequest{} } func (m *QueryPoolBatchSwapMsgsRequest) String() string { return proto.CompactTextString(m) } func (*QueryPoolBatchSwapMsgsRequest) ProtoMessage() {} func (*QueryPoolBatchSwapMsgsRequest) Descriptor() ([]byte, []int) { return fileDescriptor_456c121a8965f63a, []int{10} } func (m *QueryPoolBatchSwapMsgsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryPoolBatchSwapMsgsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryPoolBatchSwapMsgsRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryPoolBatchSwapMsgsRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryPoolBatchSwapMsgsRequest.Merge(m, src) } func (m *QueryPoolBatchSwapMsgsRequest) XXX_Size() int { return m.Size() } func (m *QueryPoolBatchSwapMsgsRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryPoolBatchSwapMsgsRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryPoolBatchSwapMsgsRequest proto.InternalMessageInfo func (m *QueryPoolBatchSwapMsgsRequest) GetPoolId() uint64 { if m != nil { return m.PoolId } return 0 } func (m *QueryPoolBatchSwapMsgsRequest) GetPagination() *query.PageRequest { if m != nil { return m.Pagination } return nil } // the request type for the QueryPoolBatchSwap RPC method. Requestable including // specified pool_id and msg_index. type QueryPoolBatchSwapMsgRequest struct { // id of the target pool for query PoolId uint64 `protobuf:"varint,1,opt,name=pool_id,json=poolId,proto3" json:"pool_id,omitempty"` // target msg_index of the pool MsgIndex uint64 `protobuf:"varint,2,opt,name=msg_index,json=msgIndex,proto3" json:"msg_index,omitempty"` } func (m *QueryPoolBatchSwapMsgRequest) Reset() { *m = QueryPoolBatchSwapMsgRequest{} } func (m *QueryPoolBatchSwapMsgRequest) String() string { return proto.CompactTextString(m) } func (*QueryPoolBatchSwapMsgRequest) ProtoMessage() {} func (*QueryPoolBatchSwapMsgRequest) Descriptor() ([]byte, []int) { return fileDescriptor_456c121a8965f63a, []int{11} } func (m *QueryPoolBatchSwapMsgRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryPoolBatchSwapMsgRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryPoolBatchSwapMsgRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryPoolBatchSwapMsgRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryPoolBatchSwapMsgRequest.Merge(m, src) } func (m *QueryPoolBatchSwapMsgRequest) XXX_Size() int { return m.Size() } func (m *QueryPoolBatchSwapMsgRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryPoolBatchSwapMsgRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryPoolBatchSwapMsgRequest proto.InternalMessageInfo func (m *QueryPoolBatchSwapMsgRequest) GetPoolId() uint64 { if m != nil { return m.PoolId } return 0 } func (m *QueryPoolBatchSwapMsgRequest) GetMsgIndex() uint64 { if m != nil { return m.MsgIndex } return 0 } // the response type for the QueryPoolBatchSwapMsgs RPC method. This includes // list of all currently existing swap messages of the batch and paging results // that contain next_key and total count. type QueryPoolBatchSwapMsgsResponse struct { Swaps []SwapMsgState `protobuf:"bytes,1,rep,name=swaps,proto3" json:"swaps"` // pagination defines the pagination in the response. not working on this // version. Pagination *query.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` } func (m *QueryPoolBatchSwapMsgsResponse) Reset() { *m = QueryPoolBatchSwapMsgsResponse{} } func (m *QueryPoolBatchSwapMsgsResponse) String() string { return proto.CompactTextString(m) } func (*QueryPoolBatchSwapMsgsResponse) ProtoMessage() {} func (*QueryPoolBatchSwapMsgsResponse) Descriptor() ([]byte, []int) { return fileDescriptor_456c121a8965f63a, []int{12} } func (m *QueryPoolBatchSwapMsgsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryPoolBatchSwapMsgsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryPoolBatchSwapMsgsResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryPoolBatchSwapMsgsResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryPoolBatchSwapMsgsResponse.Merge(m, src) } func (m *QueryPoolBatchSwapMsgsResponse) XXX_Size() int { return m.Size() } func (m *QueryPoolBatchSwapMsgsResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryPoolBatchSwapMsgsResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryPoolBatchSwapMsgsResponse proto.InternalMessageInfo func (m *QueryPoolBatchSwapMsgsResponse) GetSwaps() []SwapMsgState { if m != nil { return m.Swaps } return nil } func (m *QueryPoolBatchSwapMsgsResponse) GetPagination() *query.PageResponse { if m != nil { return m.Pagination } return nil } // the response type for the QueryPoolBatchSwapMsg RPC method. This includes a // batch swap message of the batch. type QueryPoolBatchSwapMsgResponse struct { Swap SwapMsgState `protobuf:"bytes,1,opt,name=swap,proto3" json:"swap"` } func (m *QueryPoolBatchSwapMsgResponse) Reset() { *m = QueryPoolBatchSwapMsgResponse{} } func (m *QueryPoolBatchSwapMsgResponse) String() string { return proto.CompactTextString(m) } func (*QueryPoolBatchSwapMsgResponse) ProtoMessage() {} func (*QueryPoolBatchSwapMsgResponse) Descriptor() ([]byte, []int) { return fileDescriptor_456c121a8965f63a, []int{13} } func (m *QueryPoolBatchSwapMsgResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryPoolBatchSwapMsgResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryPoolBatchSwapMsgResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryPoolBatchSwapMsgResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryPoolBatchSwapMsgResponse.Merge(m, src) } func (m *QueryPoolBatchSwapMsgResponse) XXX_Size() int { return m.Size() } func (m *QueryPoolBatchSwapMsgResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryPoolBatchSwapMsgResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryPoolBatchSwapMsgResponse proto.InternalMessageInfo func (m *QueryPoolBatchSwapMsgResponse) GetSwap() SwapMsgState { if m != nil { return m.Swap } return SwapMsgState{} } // the request type for the QueryPoolBatchDeposit RPC method. Requestable // including specified pool_id and pagination offset, limit, key. type QueryPoolBatchDepositMsgsRequest struct { // id of the target pool for query PoolId uint64 `protobuf:"varint,1,opt,name=pool_id,json=poolId,proto3" json:"pool_id,omitempty"` // pagination defines an optional pagination for the request. Pagination *query.PageRequest `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` } func (m *QueryPoolBatchDepositMsgsRequest) Reset() { *m = QueryPoolBatchDepositMsgsRequest{} } func (m *QueryPoolBatchDepositMsgsRequest) String() string { return proto.CompactTextString(m) } func (*QueryPoolBatchDepositMsgsRequest) ProtoMessage() {} func (*QueryPoolBatchDepositMsgsRequest) Descriptor() ([]byte, []int) { return fileDescriptor_456c121a8965f63a, []int{14} } func (m *QueryPoolBatchDepositMsgsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryPoolBatchDepositMsgsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryPoolBatchDepositMsgsRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryPoolBatchDepositMsgsRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryPoolBatchDepositMsgsRequest.Merge(m, src) } func (m *QueryPoolBatchDepositMsgsRequest) XXX_Size() int { return m.Size() } func (m *QueryPoolBatchDepositMsgsRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryPoolBatchDepositMsgsRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryPoolBatchDepositMsgsRequest proto.InternalMessageInfo func (m *QueryPoolBatchDepositMsgsRequest) GetPoolId() uint64 { if m != nil { return m.PoolId } return 0 } func (m *QueryPoolBatchDepositMsgsRequest) GetPagination() *query.PageRequest { if m != nil { return m.Pagination } return nil } // the request type for the QueryPoolBatchDeposit RPC method. requestable // including specified pool_id and msg_index. type QueryPoolBatchDepositMsgRequest struct { // id of the target pool for query PoolId uint64 `protobuf:"varint,1,opt,name=pool_id,json=poolId,proto3" json:"pool_id,omitempty"` // target msg_index of the pool MsgIndex uint64 `protobuf:"varint,2,opt,name=msg_index,json=msgIndex,proto3" json:"msg_index,omitempty"` } func (m *QueryPoolBatchDepositMsgRequest) Reset() { *m = QueryPoolBatchDepositMsgRequest{} } func (m *QueryPoolBatchDepositMsgRequest) String() string { return proto.CompactTextString(m) } func (*QueryPoolBatchDepositMsgRequest) ProtoMessage() {} func (*QueryPoolBatchDepositMsgRequest) Descriptor() ([]byte, []int) { return fileDescriptor_456c121a8965f63a, []int{15} } func (m *QueryPoolBatchDepositMsgRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryPoolBatchDepositMsgRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryPoolBatchDepositMsgRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryPoolBatchDepositMsgRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryPoolBatchDepositMsgRequest.Merge(m, src) } func (m *QueryPoolBatchDepositMsgRequest) XXX_Size() int { return m.Size() } func (m *QueryPoolBatchDepositMsgRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryPoolBatchDepositMsgRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryPoolBatchDepositMsgRequest proto.InternalMessageInfo func (m *QueryPoolBatchDepositMsgRequest) GetPoolId() uint64 { if m != nil { return m.PoolId } return 0 } func (m *QueryPoolBatchDepositMsgRequest) GetMsgIndex() uint64 { if m != nil { return m.MsgIndex } return 0 } // the response type for the QueryPoolBatchDeposit RPC method. This includes a // list of all currently existing deposit messages of the batch and paging // results that contain next_key and total count. type QueryPoolBatchDepositMsgsResponse struct { Deposits []DepositMsgState `protobuf:"bytes,1,rep,name=deposits,proto3" json:"deposits"` // pagination defines the pagination in the response. not working on this // version. Pagination *query.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` } func (m *QueryPoolBatchDepositMsgsResponse) Reset() { *m = QueryPoolBatchDepositMsgsResponse{} } func (m *QueryPoolBatchDepositMsgsResponse) String() string { return proto.CompactTextString(m) } func (*QueryPoolBatchDepositMsgsResponse) ProtoMessage() {} func (*QueryPoolBatchDepositMsgsResponse) Descriptor() ([]byte, []int) { return fileDescriptor_456c121a8965f63a, []int{16} } func (m *QueryPoolBatchDepositMsgsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryPoolBatchDepositMsgsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryPoolBatchDepositMsgsResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryPoolBatchDepositMsgsResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryPoolBatchDepositMsgsResponse.Merge(m, src) } func (m *QueryPoolBatchDepositMsgsResponse) XXX_Size() int { return m.Size() } func (m *QueryPoolBatchDepositMsgsResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryPoolBatchDepositMsgsResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryPoolBatchDepositMsgsResponse proto.InternalMessageInfo func (m *QueryPoolBatchDepositMsgsResponse) GetDeposits() []DepositMsgState { if m != nil { return m.Deposits } return nil } func (m *QueryPoolBatchDepositMsgsResponse) GetPagination() *query.PageResponse { if m != nil { return m.Pagination } return nil } // the response type for the QueryPoolBatchDepositMsg RPC method. This includes // a batch swap message of the batch. type QueryPoolBatchDepositMsgResponse struct { Deposit DepositMsgState `protobuf:"bytes,1,opt,name=deposit,proto3" json:"deposit"` } func (m *QueryPoolBatchDepositMsgResponse) Reset() { *m = QueryPoolBatchDepositMsgResponse{} } func (m *QueryPoolBatchDepositMsgResponse) String() string { return proto.CompactTextString(m) } func (*QueryPoolBatchDepositMsgResponse) ProtoMessage() {} func (*QueryPoolBatchDepositMsgResponse) Descriptor() ([]byte, []int) { return fileDescriptor_456c121a8965f63a, []int{17} } func (m *QueryPoolBatchDepositMsgResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryPoolBatchDepositMsgResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryPoolBatchDepositMsgResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryPoolBatchDepositMsgResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryPoolBatchDepositMsgResponse.Merge(m, src) } func (m *QueryPoolBatchDepositMsgResponse) XXX_Size() int { return m.Size() } func (m *QueryPoolBatchDepositMsgResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryPoolBatchDepositMsgResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryPoolBatchDepositMsgResponse proto.InternalMessageInfo func (m *QueryPoolBatchDepositMsgResponse) GetDeposit() DepositMsgState { if m != nil { return m.Deposit } return DepositMsgState{} } // the request type for the QueryPoolBatchWithdraw RPC method. Requestable // including specified pool_id and pagination offset, limit, key. type QueryPoolBatchWithdrawMsgsRequest struct { // id of the target pool for query PoolId uint64 `protobuf:"varint,1,opt,name=pool_id,json=poolId,proto3" json:"pool_id,omitempty"` // pagination defines an optional pagination for the request. Pagination *query.PageRequest `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` } func (m *QueryPoolBatchWithdrawMsgsRequest) Reset() { *m = QueryPoolBatchWithdrawMsgsRequest{} } func (m *QueryPoolBatchWithdrawMsgsRequest) String() string { return proto.CompactTextString(m) } func (*QueryPoolBatchWithdrawMsgsRequest) ProtoMessage() {} func (*QueryPoolBatchWithdrawMsgsRequest) Descriptor() ([]byte, []int) { return fileDescriptor_456c121a8965f63a, []int{18} } func (m *QueryPoolBatchWithdrawMsgsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryPoolBatchWithdrawMsgsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryPoolBatchWithdrawMsgsRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryPoolBatchWithdrawMsgsRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryPoolBatchWithdrawMsgsRequest.Merge(m, src) } func (m *QueryPoolBatchWithdrawMsgsRequest) XXX_Size() int { return m.Size() } func (m *QueryPoolBatchWithdrawMsgsRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryPoolBatchWithdrawMsgsRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryPoolBatchWithdrawMsgsRequest proto.InternalMessageInfo func (m *QueryPoolBatchWithdrawMsgsRequest) GetPoolId() uint64 { if m != nil { return m.PoolId } return 0 } func (m *QueryPoolBatchWithdrawMsgsRequest) GetPagination() *query.PageRequest { if m != nil { return m.Pagination } return nil } // the request type for the QueryPoolBatchWithdraw RPC method. requestable // including specified pool_id and msg_index. type QueryPoolBatchWithdrawMsgRequest struct { // id of the target pool for query PoolId uint64 `protobuf:"varint,1,opt,name=pool_id,json=poolId,proto3" json:"pool_id,omitempty"` // target msg_index of the pool MsgIndex uint64 `protobuf:"varint,2,opt,name=msg_index,json=msgIndex,proto3" json:"msg_index,omitempty"` } func (m *QueryPoolBatchWithdrawMsgRequest) Reset() { *m = QueryPoolBatchWithdrawMsgRequest{} } func (m *QueryPoolBatchWithdrawMsgRequest) String() string { return proto.CompactTextString(m) } func (*QueryPoolBatchWithdrawMsgRequest) ProtoMessage() {} func (*QueryPoolBatchWithdrawMsgRequest) Descriptor() ([]byte, []int) { return fileDescriptor_456c121a8965f63a, []int{19} } func (m *QueryPoolBatchWithdrawMsgRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryPoolBatchWithdrawMsgRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryPoolBatchWithdrawMsgRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryPoolBatchWithdrawMsgRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryPoolBatchWithdrawMsgRequest.Merge(m, src) } func (m *QueryPoolBatchWithdrawMsgRequest) XXX_Size() int { return m.Size() } func (m *QueryPoolBatchWithdrawMsgRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryPoolBatchWithdrawMsgRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryPoolBatchWithdrawMsgRequest proto.InternalMessageInfo func (m *QueryPoolBatchWithdrawMsgRequest) GetPoolId() uint64 { if m != nil { return m.PoolId } return 0 } func (m *QueryPoolBatchWithdrawMsgRequest) GetMsgIndex() uint64 { if m != nil { return m.MsgIndex } return 0 } // the response type for the QueryPoolBatchWithdraw RPC method. This includes a // list of all currently existing withdraw messages of the batch and paging // results that contain next_key and total count. type QueryPoolBatchWithdrawMsgsResponse struct { Withdraws []WithdrawMsgState `protobuf:"bytes,1,rep,name=withdraws,proto3" json:"withdraws"` // pagination defines the pagination in the response. Not supported on this // version. Pagination *query.PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` } func (m *QueryPoolBatchWithdrawMsgsResponse) Reset() { *m = QueryPoolBatchWithdrawMsgsResponse{} } func (m *QueryPoolBatchWithdrawMsgsResponse) String() string { return proto.CompactTextString(m) } func (*QueryPoolBatchWithdrawMsgsResponse) ProtoMessage() {} func (*QueryPoolBatchWithdrawMsgsResponse) Descriptor() ([]byte, []int) { return fileDescriptor_456c121a8965f63a, []int{20} } func (m *QueryPoolBatchWithdrawMsgsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryPoolBatchWithdrawMsgsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryPoolBatchWithdrawMsgsResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryPoolBatchWithdrawMsgsResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryPoolBatchWithdrawMsgsResponse.Merge(m, src) } func (m *QueryPoolBatchWithdrawMsgsResponse) XXX_Size() int { return m.Size() } func (m *QueryPoolBatchWithdrawMsgsResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryPoolBatchWithdrawMsgsResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryPoolBatchWithdrawMsgsResponse proto.InternalMessageInfo func (m *QueryPoolBatchWithdrawMsgsResponse) GetWithdraws() []WithdrawMsgState { if m != nil { return m.Withdraws } return nil } func (m *QueryPoolBatchWithdrawMsgsResponse) GetPagination() *query.PageResponse { if m != nil { return m.Pagination } return nil } // the response type for the QueryPoolBatchWithdrawMsg RPC method. This includes // a batch swap message of the batch. type QueryPoolBatchWithdrawMsgResponse struct { Withdraw WithdrawMsgState `protobuf:"bytes,1,opt,name=withdraw,proto3" json:"withdraw"` } func (m *QueryPoolBatchWithdrawMsgResponse) Reset() { *m = QueryPoolBatchWithdrawMsgResponse{} } func (m *QueryPoolBatchWithdrawMsgResponse) String() string { return proto.CompactTextString(m) } func (*QueryPoolBatchWithdrawMsgResponse) ProtoMessage() {} func (*QueryPoolBatchWithdrawMsgResponse) Descriptor() ([]byte, []int) { return fileDescriptor_456c121a8965f63a, []int{21} } func (m *QueryPoolBatchWithdrawMsgResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryPoolBatchWithdrawMsgResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryPoolBatchWithdrawMsgResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryPoolBatchWithdrawMsgResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryPoolBatchWithdrawMsgResponse.Merge(m, src) } func (m *QueryPoolBatchWithdrawMsgResponse) XXX_Size() int { return m.Size() } func (m *QueryPoolBatchWithdrawMsgResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryPoolBatchWithdrawMsgResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryPoolBatchWithdrawMsgResponse proto.InternalMessageInfo func (m *QueryPoolBatchWithdrawMsgResponse) GetWithdraw() WithdrawMsgState { if m != nil { return m.Withdraw } return WithdrawMsgState{} } func init() { proto.RegisterType((*QueryLiquidityPoolRequest)(nil), "cyber.liquidity.v1beta1.QueryLiquidityPoolRequest") proto.RegisterType((*QueryLiquidityPoolResponse)(nil), "cyber.liquidity.v1beta1.QueryLiquidityPoolResponse") proto.RegisterType((*QueryLiquidityPoolByPoolCoinDenomRequest)(nil), "cyber.liquidity.v1beta1.QueryLiquidityPoolByPoolCoinDenomRequest") proto.RegisterType((*QueryLiquidityPoolByReserveAccRequest)(nil), "cyber.liquidity.v1beta1.QueryLiquidityPoolByReserveAccRequest") proto.RegisterType((*QueryLiquidityPoolBatchRequest)(nil), "cyber.liquidity.v1beta1.QueryLiquidityPoolBatchRequest") proto.RegisterType((*QueryLiquidityPoolBatchResponse)(nil), "cyber.liquidity.v1beta1.QueryLiquidityPoolBatchResponse") proto.RegisterType((*QueryLiquidityPoolsRequest)(nil), "cyber.liquidity.v1beta1.QueryLiquidityPoolsRequest") proto.RegisterType((*QueryLiquidityPoolsResponse)(nil), "cyber.liquidity.v1beta1.QueryLiquidityPoolsResponse") proto.RegisterType((*QueryParamsRequest)(nil), "cyber.liquidity.v1beta1.QueryParamsRequest") proto.RegisterType((*QueryParamsResponse)(nil), "cyber.liquidity.v1beta1.QueryParamsResponse") proto.RegisterType((*QueryPoolBatchSwapMsgsRequest)(nil), "cyber.liquidity.v1beta1.QueryPoolBatchSwapMsgsRequest") proto.RegisterType((*QueryPoolBatchSwapMsgRequest)(nil), "cyber.liquidity.v1beta1.QueryPoolBatchSwapMsgRequest") proto.RegisterType((*QueryPoolBatchSwapMsgsResponse)(nil), "cyber.liquidity.v1beta1.QueryPoolBatchSwapMsgsResponse") proto.RegisterType((*QueryPoolBatchSwapMsgResponse)(nil), "cyber.liquidity.v1beta1.QueryPoolBatchSwapMsgResponse") proto.RegisterType((*QueryPoolBatchDepositMsgsRequest)(nil), "cyber.liquidity.v1beta1.QueryPoolBatchDepositMsgsRequest") proto.RegisterType((*QueryPoolBatchDepositMsgRequest)(nil), "cyber.liquidity.v1beta1.QueryPoolBatchDepositMsgRequest") proto.RegisterType((*QueryPoolBatchDepositMsgsResponse)(nil), "cyber.liquidity.v1beta1.QueryPoolBatchDepositMsgsResponse") proto.RegisterType((*QueryPoolBatchDepositMsgResponse)(nil), "cyber.liquidity.v1beta1.QueryPoolBatchDepositMsgResponse") proto.RegisterType((*QueryPoolBatchWithdrawMsgsRequest)(nil), "cyber.liquidity.v1beta1.QueryPoolBatchWithdrawMsgsRequest") proto.RegisterType((*QueryPoolBatchWithdrawMsgRequest)(nil), "cyber.liquidity.v1beta1.QueryPoolBatchWithdrawMsgRequest") proto.RegisterType((*QueryPoolBatchWithdrawMsgsResponse)(nil), "cyber.liquidity.v1beta1.QueryPoolBatchWithdrawMsgsResponse") proto.RegisterType((*QueryPoolBatchWithdrawMsgResponse)(nil), "cyber.liquidity.v1beta1.QueryPoolBatchWithdrawMsgResponse") } func init() { proto.RegisterFile("cyber/liquidity/v1beta1/query.proto", fileDescriptor_456c121a8965f63a) } var fileDescriptor_456c121a8965f63a = []byte{ // 1129 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xbc, 0x58, 0xdf, 0x6f, 0xdb, 0x54, 0x14, 0xee, 0x1d, 0x69, 0xd7, 0x9e, 0x69, 0xfc, 0xb8, 0x2b, 0xda, 0xe6, 0x75, 0x49, 0x67, 0xb4, 0xb5, 0x63, 0x10, 0xab, 0xed, 0xb6, 0x34, 0x9d, 0x36, 0xc8, 0x56, 0xb6, 0x15, 0x56, 0x69, 0x64, 0x43, 0x43, 0xbc, 0x14, 0xc7, 0xb9, 0x72, 0x2d, 0x25, 0xbe, 0x6e, 0xae, 0xbb, 0xae, 0xaa, 0x2a, 0x21, 0xe0, 0x15, 0x09, 0x89, 0xbf, 0x00, 0x89, 0x37, 0xf8, 0x03, 0x78, 0xe0, 0x01, 0x89, 0x97, 0x3d, 0x20, 0x31, 0xa9, 0x2f, 0x7b, 0x40, 0x68, 0xb4, 0xfc, 0x21, 0xc8, 0xf7, 0x5e, 0x3b, 0x4e, 0x62, 0x27, 0xb9, 0x5e, 0xb5, 0x97, 0xaa, 0xbe, 0x39, 0xdf, 0x39, 0xdf, 0x77, 0xce, 0x49, 0xfc, 0xd9, 0xf0, 0x8e, 0xb5, 0x5d, 0x23, 0x2d, 0xa3, 0xe1, 0x6c, 0x6c, 0x3a, 0x75, 0xc7, 0xdf, 0x36, 0x1e, 0xcf, 0xd5, 0x88, 0x6f, 0xce, 0x19, 0x1b, 0x9b, 0xa4, 0xb5, 0x5d, 0xf4, 0x5a, 0xd4, 0xa7, 0xf8, 0x24, 0x0f, 0x2a, 0x46, 0x41, 0x45, 0x19, 0xa4, 0x4d, 0xda, 0xd4, 0xa6, 0x3c, 0xc6, 0x08, 0xfe, 0x13, 0xe1, 0xda, 0x4c, 0x5a, 0xce, 0x76, 0x02, 0x11, 0x38, 0x65, 0x53, 0x6a, 0x37, 0x88, 0x61, 0x7a, 0x8e, 0x61, 0xba, 0x2e, 0xf5, 0x4d, 0xdf, 0xa1, 0x2e, 0x93, 0x9f, 0xbe, 0x6b, 0x51, 0xd6, 0xa4, 0xcc, 0xa8, 0x99, 0x8c, 0x08, 0x3a, 0x51, 0x22, 0xcf, 0xb4, 0x1d, 0x97, 0x07, 0x8b, 0x58, 0xfd, 0x32, 0x9c, 0xfe, 0x34, 0x88, 0xb8, 0x17, 0x56, 0xb8, 0x4f, 0x69, 0xa3, 0x4a, 0x36, 0x36, 0x09, 0xf3, 0xf1, 0x49, 0x38, 0xea, 0x51, 0xda, 0x58, 0x73, 0xea, 0xa7, 0xd0, 0x34, 0x9a, 0xcd, 0x55, 0xc7, 0x82, 0xcb, 0x95, 0xba, 0xfe, 0x19, 0x68, 0x49, 0x28, 0xe6, 0x51, 0x97, 0x11, 0x5c, 0x82, 0x5c, 0x10, 0xc7, 0x31, 0xc7, 0xe6, 0xcf, 0x16, 0x53, 0x9a, 0x50, 0x0c, 0x40, 0x37, 0x73, 0x4f, 0xff, 0x29, 0x8c, 0x54, 0x39, 0x40, 0xaf, 0xc2, 0x6c, 0x6f, 0xda, 0x9b, 0xfc, 0xef, 0x2d, 0xea, 0xb8, 0xcb, 0xc4, 0xa5, 0xcd, 0x90, 0xdb, 0x05, 0x78, 0x83, 0x73, 0xb3, 0xa8, 0xe3, 0xae, 0xd5, 0x83, 0x4f, 0x78, 0xbd, 0x89, 0xea, 0x71, 0x2f, 0x1e, 0xae, 0xdf, 0x85, 0xf3, 0x49, 0x39, 0xab, 0x84, 0x91, 0xd6, 0x63, 0x52, 0xb1, 0xac, 0x30, 0x61, 0x01, 0x8e, 0xb5, 0xc4, 0xe1, 0x9a, 0x69, 0x59, 0x32, 0x19, 0xb4, 0xa2, 0x38, 0xbd, 0x0c, 0xf9, 0x84, 0x4c, 0xa6, 0x6f, 0xad, 0x0f, 0xec, 0x97, 0x09, 0x85, 0x54, 0xa8, 0x6c, 0xda, 0x0d, 0x18, 0xad, 0x05, 0x07, 0xb2, 0x6b, 0x7a, 0xff, 0xae, 0x05, 0x91, 0xb2, 0x75, 0x02, 0xa6, 0xd7, 0x93, 0x46, 0xc2, 0x42, 0x66, 0xb7, 0x01, 0xda, 0xa3, 0x97, 0x25, 0x2e, 0x14, 0xc5, 0x9e, 0x14, 0x83, 0x3d, 0x29, 0x8a, 0xb5, 0x8d, 0x8a, 0x98, 0x36, 0x91, 0xd8, 0x6a, 0x0c, 0xa9, 0xff, 0x88, 0xe0, 0x4c, 0x62, 0x19, 0xa9, 0xa2, 0x0c, 0xa3, 0x81, 0x64, 0x76, 0x0a, 0x4d, 0xbf, 0x36, 0xec, 0xec, 0x05, 0x02, 0xdf, 0xe9, 0xa0, 0x78, 0x84, 0x53, 0x9c, 0x19, 0x48, 0x51, 0xd4, 0xed, 0xe0, 0x38, 0x09, 0x98, 0x53, 0xbc, 0x6f, 0xb6, 0xcc, 0x66, 0xd8, 0x01, 0xfd, 0x21, 0x9c, 0xe8, 0x38, 0x95, 0x84, 0xaf, 0xc3, 0x98, 0xc7, 0x4f, 0x64, 0x53, 0x0a, 0xe9, 0x8c, 0x79, 0x98, 0xe4, 0x2c, 0x41, 0xfa, 0x57, 0x08, 0xce, 0x8a, 0xb4, 0xe1, 0x54, 0x1e, 0x6c, 0x99, 0xde, 0x2a, 0xb3, 0xd9, 0xa0, 0x9d, 0xe8, 0x1a, 0xc9, 0x91, 0xcc, 0x23, 0x79, 0x08, 0x53, 0x89, 0x0c, 0x06, 0x12, 0x38, 0x03, 0x13, 0x4d, 0x66, 0xaf, 0x39, 0x6e, 0x9d, 0x3c, 0xe1, 0xf5, 0x73, 0xd5, 0xf1, 0x26, 0xb3, 0x57, 0x82, 0x6b, 0xfd, 0x17, 0x24, 0xb7, 0x3d, 0x41, 0x98, 0x6c, 0x5d, 0x05, 0x46, 0xd9, 0x96, 0xe9, 0x85, 0xb3, 0x3e, 0x9f, 0xda, 0x39, 0x89, 0x7c, 0xe0, 0x9b, 0x3e, 0x09, 0x67, 0xce, 0x91, 0x87, 0x37, 0xf3, 0x2f, 0x53, 0xc6, 0x10, 0x91, 0xfd, 0x00, 0x72, 0x41, 0x49, 0x39, 0x65, 0x25, 0xae, 0x1c, 0xa8, 0x7f, 0x83, 0x60, 0xba, 0xb3, 0xc4, 0x32, 0xf1, 0x28, 0x73, 0xfc, 0x57, 0x3a, 0xec, 0x47, 0xf2, 0x87, 0x24, 0x81, 0xc4, 0xcb, 0xcd, 0xfb, 0x57, 0x04, 0xe7, 0xfa, 0xc8, 0x93, 0x5d, 0xfc, 0x18, 0xc6, 0xeb, 0xe2, 0x38, 0x9c, 0xfa, 0x6c, 0x6a, 0x27, 0xdb, 0xf8, 0x78, 0x33, 0x23, 0xfc, 0xe1, 0xcd, 0xbe, 0x91, 0x3e, 0x98, 0x88, 0xf8, 0x5d, 0x38, 0x2a, 0x0b, 0xcb, 0x0d, 0x50, 0xe5, 0x1d, 0xc2, 0xf5, 0x6f, 0x7b, 0x1a, 0xf5, 0xc8, 0xf1, 0xd7, 0xeb, 0x2d, 0x73, 0xeb, 0x95, 0x2e, 0xc2, 0xe7, 0xdd, 0xa2, 0x63, 0x2c, 0x5e, 0x6e, 0x13, 0x7e, 0x43, 0xa0, 0xf7, 0x13, 0x28, 0x3b, 0xba, 0x0a, 0x13, 0x5b, 0xf2, 0x3c, 0xdc, 0x85, 0x8b, 0xa9, 0x3d, 0x8d, 0x65, 0x88, 0x37, 0xb5, 0x9d, 0xe1, 0xf0, 0xb6, 0xc1, 0xeb, 0x33, 0x9e, 0x88, 0xfc, 0x27, 0x30, 0x1e, 0x96, 0x96, 0xfb, 0xa0, 0xcc, 0x3d, 0x4a, 0x30, 0xff, 0x02, 0xc3, 0x28, 0x2f, 0x89, 0x7f, 0x42, 0xf0, 0x7a, 0xe7, 0x8d, 0x11, 0x2f, 0xa4, 0xe6, 0x4d, 0xbf, 0x5b, 0x6b, 0x97, 0xd5, 0x40, 0x42, 0x94, 0x3e, 0xf3, 0xf5, 0xde, 0x7f, 0x3f, 0x1c, 0x39, 0x87, 0x0b, 0x86, 0xf4, 0x7f, 0xbd, 0x3e, 0x52, 0xdc, 0x69, 0x7f, 0x46, 0x70, 0xbc, 0x23, 0x07, 0x9e, 0x57, 0x28, 0x18, 0x92, 0x5c, 0x50, 0xc2, 0x48, 0x8e, 0x73, 0x9c, 0xe3, 0x25, 0x7c, 0x71, 0x00, 0x47, 0x63, 0x47, 0x6e, 0xee, 0x2e, 0xfe, 0x17, 0xc1, 0x54, 0x3f, 0x43, 0x88, 0x2b, 0x0a, 0x44, 0x92, 0xcd, 0x64, 0x36, 0x2d, 0x2b, 0x5c, 0xcb, 0x2d, 0x5c, 0x19, 0xa4, 0xa5, 0xcb, 0xa7, 0x4a, 0x6d, 0xed, 0x83, 0x5d, 0xbc, 0x87, 0xe0, 0x74, 0xaa, 0x41, 0xc5, 0x37, 0x94, 0x04, 0xf6, 0x38, 0xdb, 0x6c, 0xea, 0x2a, 0x5c, 0xdd, 0x35, 0x5c, 0x1e, 0xa4, 0x2e, 0x66, 0x9a, 0x8d, 0x9d, 0xd8, 0xc5, 0x2e, 0xfe, 0x1d, 0x01, 0xee, 0x75, 0xbc, 0xb8, 0xa4, 0x22, 0x27, 0x66, 0xaf, 0xb5, 0x45, 0x75, 0xa0, 0x14, 0x53, 0xe2, 0x62, 0xe6, 0xb0, 0x31, 0xf4, 0xda, 0x19, 0xdc, 0x55, 0xe3, 0x3f, 0x10, 0xbc, 0xd5, 0xe3, 0x80, 0xf0, 0xd5, 0xfe, 0x44, 0xd2, 0xbc, 0xa0, 0x56, 0x52, 0xc6, 0x49, 0xfe, 0xd7, 0x39, 0xff, 0x12, 0xbe, 0xa2, 0xc8, 0xdf, 0x10, 0x36, 0xeb, 0x4f, 0x04, 0x6f, 0x76, 0x27, 0xc7, 0x57, 0xd4, 0xc8, 0x84, 0x1a, 0xae, 0xaa, 0xc2, 0x54, 0xbf, 0x2d, 0x89, 0x12, 0x8c, 0x9d, 0xe8, 0x86, 0xb5, 0x8b, 0xff, 0x42, 0x30, 0x99, 0x64, 0x53, 0x70, 0x79, 0x48, 0x6e, 0xbd, 0xce, 0x4d, 0x5b, 0xca, 0x02, 0x95, 0xd2, 0x3e, 0xe4, 0xd2, 0x96, 0xf0, 0xa2, 0xaa, 0xb4, 0xc8, 0x0b, 0x3d, 0x47, 0x70, 0x22, 0xa1, 0x04, 0x5e, 0x54, 0x66, 0x15, 0xea, 0x29, 0x67, 0x40, 0x4a, 0x39, 0xf7, 0xb8, 0x9c, 0xdb, 0x78, 0x39, 0xab, 0x9c, 0x8e, 0x61, 0xed, 0x21, 0x78, 0x3b, 0xd1, 0x49, 0xe0, 0x61, 0x5b, 0x9e, 0xe0, 0xaf, 0xb4, 0x6b, 0x99, 0xb0, 0xaa, 0x3f, 0x6d, 0xdd, 0x02, 0xdb, 0x76, 0xe5, 0xef, 0xf8, 0x0a, 0xc6, 0x8a, 0x0c, 0xbd, 0x82, 0xbd, 0x76, 0x4d, 0x5b, 0xca, 0x02, 0x95, 0x92, 0x56, 0xb9, 0xa4, 0x3b, 0xf8, 0xa3, 0xcc, 0x92, 0x3a, 0x86, 0xf6, 0x1d, 0x82, 0x31, 0xf1, 0xbc, 0x8b, 0x2f, 0x0d, 0x60, 0x15, 0x7f, 0xc8, 0xd6, 0xde, 0x1b, 0x2e, 0x58, 0x92, 0x9e, 0xe5, 0xa4, 0x75, 0x3c, 0xdd, 0x87, 0xb4, 0x78, 0xe8, 0x5e, 0x7d, 0xba, 0x9f, 0x47, 0xcf, 0xf6, 0xf3, 0xe8, 0xc5, 0x7e, 0x1e, 0x7d, 0x7f, 0x90, 0x1f, 0x79, 0x76, 0x90, 0x1f, 0x79, 0x7e, 0x90, 0x1f, 0xf9, 0x62, 0xc1, 0x76, 0xfc, 0xf5, 0xcd, 0x5a, 0xd1, 0xa2, 0x4d, 0x83, 0xd7, 0xb6, 0xa8, 0x6b, 0xb7, 0x08, 0x63, 0x86, 0x4d, 0xdf, 0x17, 0xaf, 0xd3, 0x9e, 0xc4, 0xf2, 0xfa, 0xdb, 0x1e, 0x61, 0xb5, 0x31, 0xfe, 0xee, 0x6b, 0xe1, 0xff, 0x00, 0x00, 0x00, 0xff, 0xff, 0xa6, 0xdb, 0xfb, 0x91, 0xc4, 0x13, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. var ( _ context.Context _ grpc.ClientConn ) // This is a compile-time assertion to ensure that this generated file // is compatible with the grpc package it is being compiled against. const _ = grpc.SupportPackageIsVersion4 // QueryClient is the client API for Query service. // // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. type QueryClient interface { // Get existing liquidity pools. LiquidityPools(ctx context.Context, in *QueryLiquidityPoolsRequest, opts ...grpc.CallOption) (*QueryLiquidityPoolsResponse, error) // Get specific liquidity pool. LiquidityPool(ctx context.Context, in *QueryLiquidityPoolRequest, opts ...grpc.CallOption) (*QueryLiquidityPoolResponse, error) // Get specific liquidity pool corresponding to the pool_coin_denom. LiquidityPoolByPoolCoinDenom(ctx context.Context, in *QueryLiquidityPoolByPoolCoinDenomRequest, opts ...grpc.CallOption) (*QueryLiquidityPoolResponse, error) // Get specific liquidity pool corresponding to the reserve account. LiquidityPoolByReserveAcc(ctx context.Context, in *QueryLiquidityPoolByReserveAccRequest, opts ...grpc.CallOption) (*QueryLiquidityPoolResponse, error) // Get the pool's current batch. LiquidityPoolBatch(ctx context.Context, in *QueryLiquidityPoolBatchRequest, opts ...grpc.CallOption) (*QueryLiquidityPoolBatchResponse, error) // Get all swap messages in the pool's current batch. PoolBatchSwapMsgs(ctx context.Context, in *QueryPoolBatchSwapMsgsRequest, opts ...grpc.CallOption) (*QueryPoolBatchSwapMsgsResponse, error) // Get a specific swap message in the pool's current batch. PoolBatchSwapMsg(ctx context.Context, in *QueryPoolBatchSwapMsgRequest, opts ...grpc.CallOption) (*QueryPoolBatchSwapMsgResponse, error) // Get all deposit messages in the pool's current batch. PoolBatchDepositMsgs(ctx context.Context, in *QueryPoolBatchDepositMsgsRequest, opts ...grpc.CallOption) (*QueryPoolBatchDepositMsgsResponse, error) // Get a specific deposit message in the pool's current batch. PoolBatchDepositMsg(ctx context.Context, in *QueryPoolBatchDepositMsgRequest, opts ...grpc.CallOption) (*QueryPoolBatchDepositMsgResponse, error) // Get all withdraw messages in the pool's current batch. PoolBatchWithdrawMsgs(ctx context.Context, in *QueryPoolBatchWithdrawMsgsRequest, opts ...grpc.CallOption) (*QueryPoolBatchWithdrawMsgsResponse, error) // Get a specific withdraw message in the pool's current batch. PoolBatchWithdrawMsg(ctx context.Context, in *QueryPoolBatchWithdrawMsgRequest, opts ...grpc.CallOption) (*QueryPoolBatchWithdrawMsgResponse, error) // Get all parameters of the liquidity module. Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) } type queryClient struct { cc grpc1.ClientConn } func NewQueryClient(cc grpc1.ClientConn) QueryClient { return &queryClient{cc} } func (c *queryClient) LiquidityPools(ctx context.Context, in *QueryLiquidityPoolsRequest, opts ...grpc.CallOption) (*QueryLiquidityPoolsResponse, error) { out := new(QueryLiquidityPoolsResponse) err := c.cc.Invoke(ctx, "/cyber.liquidity.v1beta1.Query/LiquidityPools", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) LiquidityPool(ctx context.Context, in *QueryLiquidityPoolRequest, opts ...grpc.CallOption) (*QueryLiquidityPoolResponse, error) { out := new(QueryLiquidityPoolResponse) err := c.cc.Invoke(ctx, "/cyber.liquidity.v1beta1.Query/LiquidityPool", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) LiquidityPoolByPoolCoinDenom(ctx context.Context, in *QueryLiquidityPoolByPoolCoinDenomRequest, opts ...grpc.CallOption) (*QueryLiquidityPoolResponse, error) { out := new(QueryLiquidityPoolResponse) err := c.cc.Invoke(ctx, "/cyber.liquidity.v1beta1.Query/LiquidityPoolByPoolCoinDenom", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) LiquidityPoolByReserveAcc(ctx context.Context, in *QueryLiquidityPoolByReserveAccRequest, opts ...grpc.CallOption) (*QueryLiquidityPoolResponse, error) { out := new(QueryLiquidityPoolResponse) err := c.cc.Invoke(ctx, "/cyber.liquidity.v1beta1.Query/LiquidityPoolByReserveAcc", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) LiquidityPoolBatch(ctx context.Context, in *QueryLiquidityPoolBatchRequest, opts ...grpc.CallOption) (*QueryLiquidityPoolBatchResponse, error) { out := new(QueryLiquidityPoolBatchResponse) err := c.cc.Invoke(ctx, "/cyber.liquidity.v1beta1.Query/LiquidityPoolBatch", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) PoolBatchSwapMsgs(ctx context.Context, in *QueryPoolBatchSwapMsgsRequest, opts ...grpc.CallOption) (*QueryPoolBatchSwapMsgsResponse, error) { out := new(QueryPoolBatchSwapMsgsResponse) err := c.cc.Invoke(ctx, "/cyber.liquidity.v1beta1.Query/PoolBatchSwapMsgs", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) PoolBatchSwapMsg(ctx context.Context, in *QueryPoolBatchSwapMsgRequest, opts ...grpc.CallOption) (*QueryPoolBatchSwapMsgResponse, error) { out := new(QueryPoolBatchSwapMsgResponse) err := c.cc.Invoke(ctx, "/cyber.liquidity.v1beta1.Query/PoolBatchSwapMsg", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) PoolBatchDepositMsgs(ctx context.Context, in *QueryPoolBatchDepositMsgsRequest, opts ...grpc.CallOption) (*QueryPoolBatchDepositMsgsResponse, error) { out := new(QueryPoolBatchDepositMsgsResponse) err := c.cc.Invoke(ctx, "/cyber.liquidity.v1beta1.Query/PoolBatchDepositMsgs", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) PoolBatchDepositMsg(ctx context.Context, in *QueryPoolBatchDepositMsgRequest, opts ...grpc.CallOption) (*QueryPoolBatchDepositMsgResponse, error) { out := new(QueryPoolBatchDepositMsgResponse) err := c.cc.Invoke(ctx, "/cyber.liquidity.v1beta1.Query/PoolBatchDepositMsg", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) PoolBatchWithdrawMsgs(ctx context.Context, in *QueryPoolBatchWithdrawMsgsRequest, opts ...grpc.CallOption) (*QueryPoolBatchWithdrawMsgsResponse, error) { out := new(QueryPoolBatchWithdrawMsgsResponse) err := c.cc.Invoke(ctx, "/cyber.liquidity.v1beta1.Query/PoolBatchWithdrawMsgs", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) PoolBatchWithdrawMsg(ctx context.Context, in *QueryPoolBatchWithdrawMsgRequest, opts ...grpc.CallOption) (*QueryPoolBatchWithdrawMsgResponse, error) { out := new(QueryPoolBatchWithdrawMsgResponse) err := c.cc.Invoke(ctx, "/cyber.liquidity.v1beta1.Query/PoolBatchWithdrawMsg", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) { out := new(QueryParamsResponse) err := c.cc.Invoke(ctx, "/cyber.liquidity.v1beta1.Query/Params", in, out, opts...) if err != nil { return nil, err } return out, nil } // QueryServer is the server API for Query service. type QueryServer interface { // Get existing liquidity pools. LiquidityPools(context.Context, *QueryLiquidityPoolsRequest) (*QueryLiquidityPoolsResponse, error) // Get specific liquidity pool. LiquidityPool(context.Context, *QueryLiquidityPoolRequest) (*QueryLiquidityPoolResponse, error) // Get specific liquidity pool corresponding to the pool_coin_denom. LiquidityPoolByPoolCoinDenom(context.Context, *QueryLiquidityPoolByPoolCoinDenomRequest) (*QueryLiquidityPoolResponse, error) // Get specific liquidity pool corresponding to the reserve account. LiquidityPoolByReserveAcc(context.Context, *QueryLiquidityPoolByReserveAccRequest) (*QueryLiquidityPoolResponse, error) // Get the pool's current batch. LiquidityPoolBatch(context.Context, *QueryLiquidityPoolBatchRequest) (*QueryLiquidityPoolBatchResponse, error) // Get all swap messages in the pool's current batch. PoolBatchSwapMsgs(context.Context, *QueryPoolBatchSwapMsgsRequest) (*QueryPoolBatchSwapMsgsResponse, error) // Get a specific swap message in the pool's current batch. PoolBatchSwapMsg(context.Context, *QueryPoolBatchSwapMsgRequest) (*QueryPoolBatchSwapMsgResponse, error) // Get all deposit messages in the pool's current batch. PoolBatchDepositMsgs(context.Context, *QueryPoolBatchDepositMsgsRequest) (*QueryPoolBatchDepositMsgsResponse, error) // Get a specific deposit message in the pool's current batch. PoolBatchDepositMsg(context.Context, *QueryPoolBatchDepositMsgRequest) (*QueryPoolBatchDepositMsgResponse, error) // Get all withdraw messages in the pool's current batch. PoolBatchWithdrawMsgs(context.Context, *QueryPoolBatchWithdrawMsgsRequest) (*QueryPoolBatchWithdrawMsgsResponse, error) // Get a specific withdraw message in the pool's current batch. PoolBatchWithdrawMsg(context.Context, *QueryPoolBatchWithdrawMsgRequest) (*QueryPoolBatchWithdrawMsgResponse, error) // Get all parameters of the liquidity module. Params(context.Context, *QueryParamsRequest) (*QueryParamsResponse, error) } // UnimplementedQueryServer can be embedded to have forward compatible implementations. type UnimplementedQueryServer struct{} func (*UnimplementedQueryServer) LiquidityPools(ctx context.Context, req *QueryLiquidityPoolsRequest) (*QueryLiquidityPoolsResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method LiquidityPools not implemented") } func (*UnimplementedQueryServer) LiquidityPool(ctx context.Context, req *QueryLiquidityPoolRequest) (*QueryLiquidityPoolResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method LiquidityPool not implemented") } func (*UnimplementedQueryServer) LiquidityPoolByPoolCoinDenom(ctx context.Context, req *QueryLiquidityPoolByPoolCoinDenomRequest) (*QueryLiquidityPoolResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method LiquidityPoolByPoolCoinDenom not implemented") } func (*UnimplementedQueryServer) LiquidityPoolByReserveAcc(ctx context.Context, req *QueryLiquidityPoolByReserveAccRequest) (*QueryLiquidityPoolResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method LiquidityPoolByReserveAcc not implemented") } func (*UnimplementedQueryServer) LiquidityPoolBatch(ctx context.Context, req *QueryLiquidityPoolBatchRequest) (*QueryLiquidityPoolBatchResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method LiquidityPoolBatch not implemented") } func (*UnimplementedQueryServer) PoolBatchSwapMsgs(ctx context.Context, req *QueryPoolBatchSwapMsgsRequest) (*QueryPoolBatchSwapMsgsResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method PoolBatchSwapMsgs not implemented") } func (*UnimplementedQueryServer) PoolBatchSwapMsg(ctx context.Context, req *QueryPoolBatchSwapMsgRequest) (*QueryPoolBatchSwapMsgResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method PoolBatchSwapMsg not implemented") } func (*UnimplementedQueryServer) PoolBatchDepositMsgs(ctx context.Context, req *QueryPoolBatchDepositMsgsRequest) (*QueryPoolBatchDepositMsgsResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method PoolBatchDepositMsgs not implemented") } func (*UnimplementedQueryServer) PoolBatchDepositMsg(ctx context.Context, req *QueryPoolBatchDepositMsgRequest) (*QueryPoolBatchDepositMsgResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method PoolBatchDepositMsg not implemented") } func (*UnimplementedQueryServer) PoolBatchWithdrawMsgs(ctx context.Context, req *QueryPoolBatchWithdrawMsgsRequest) (*QueryPoolBatchWithdrawMsgsResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method PoolBatchWithdrawMsgs not implemented") } func (*UnimplementedQueryServer) PoolBatchWithdrawMsg(ctx context.Context, req *QueryPoolBatchWithdrawMsgRequest) (*QueryPoolBatchWithdrawMsgResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method PoolBatchWithdrawMsg not implemented") } func (*UnimplementedQueryServer) Params(ctx context.Context, req *QueryParamsRequest) (*QueryParamsResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method Params not implemented") } func RegisterQueryServer(s grpc1.Server, srv QueryServer) { s.RegisterService(&_Query_serviceDesc, srv) } func _Query_LiquidityPools_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryLiquidityPoolsRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).LiquidityPools(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.liquidity.v1beta1.Query/LiquidityPools", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).LiquidityPools(ctx, req.(*QueryLiquidityPoolsRequest)) } return interceptor(ctx, in, info, handler) } func _Query_LiquidityPool_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryLiquidityPoolRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).LiquidityPool(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.liquidity.v1beta1.Query/LiquidityPool", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).LiquidityPool(ctx, req.(*QueryLiquidityPoolRequest)) } return interceptor(ctx, in, info, handler) } func _Query_LiquidityPoolByPoolCoinDenom_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryLiquidityPoolByPoolCoinDenomRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).LiquidityPoolByPoolCoinDenom(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.liquidity.v1beta1.Query/LiquidityPoolByPoolCoinDenom", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).LiquidityPoolByPoolCoinDenom(ctx, req.(*QueryLiquidityPoolByPoolCoinDenomRequest)) } return interceptor(ctx, in, info, handler) } func _Query_LiquidityPoolByReserveAcc_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryLiquidityPoolByReserveAccRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).LiquidityPoolByReserveAcc(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.liquidity.v1beta1.Query/LiquidityPoolByReserveAcc", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).LiquidityPoolByReserveAcc(ctx, req.(*QueryLiquidityPoolByReserveAccRequest)) } return interceptor(ctx, in, info, handler) } func _Query_LiquidityPoolBatch_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryLiquidityPoolBatchRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).LiquidityPoolBatch(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.liquidity.v1beta1.Query/LiquidityPoolBatch", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).LiquidityPoolBatch(ctx, req.(*QueryLiquidityPoolBatchRequest)) } return interceptor(ctx, in, info, handler) } func _Query_PoolBatchSwapMsgs_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryPoolBatchSwapMsgsRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).PoolBatchSwapMsgs(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.liquidity.v1beta1.Query/PoolBatchSwapMsgs", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).PoolBatchSwapMsgs(ctx, req.(*QueryPoolBatchSwapMsgsRequest)) } return interceptor(ctx, in, info, handler) } func _Query_PoolBatchSwapMsg_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryPoolBatchSwapMsgRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).PoolBatchSwapMsg(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.liquidity.v1beta1.Query/PoolBatchSwapMsg", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).PoolBatchSwapMsg(ctx, req.(*QueryPoolBatchSwapMsgRequest)) } return interceptor(ctx, in, info, handler) } func _Query_PoolBatchDepositMsgs_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryPoolBatchDepositMsgsRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).PoolBatchDepositMsgs(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.liquidity.v1beta1.Query/PoolBatchDepositMsgs", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).PoolBatchDepositMsgs(ctx, req.(*QueryPoolBatchDepositMsgsRequest)) } return interceptor(ctx, in, info, handler) } func _Query_PoolBatchDepositMsg_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryPoolBatchDepositMsgRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).PoolBatchDepositMsg(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.liquidity.v1beta1.Query/PoolBatchDepositMsg", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).PoolBatchDepositMsg(ctx, req.(*QueryPoolBatchDepositMsgRequest)) } return interceptor(ctx, in, info, handler) } func _Query_PoolBatchWithdrawMsgs_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryPoolBatchWithdrawMsgsRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).PoolBatchWithdrawMsgs(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.liquidity.v1beta1.Query/PoolBatchWithdrawMsgs", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).PoolBatchWithdrawMsgs(ctx, req.(*QueryPoolBatchWithdrawMsgsRequest)) } return interceptor(ctx, in, info, handler) } func _Query_PoolBatchWithdrawMsg_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryPoolBatchWithdrawMsgRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).PoolBatchWithdrawMsg(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.liquidity.v1beta1.Query/PoolBatchWithdrawMsg", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).PoolBatchWithdrawMsg(ctx, req.(*QueryPoolBatchWithdrawMsgRequest)) } return interceptor(ctx, in, info, handler) } func _Query_Params_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryParamsRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).Params(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.liquidity.v1beta1.Query/Params", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Params(ctx, req.(*QueryParamsRequest)) } return interceptor(ctx, in, info, handler) } var _Query_serviceDesc = grpc.ServiceDesc{ ServiceName: "cyber.liquidity.v1beta1.Query", HandlerType: (*QueryServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "LiquidityPools", Handler: _Query_LiquidityPools_Handler, }, { MethodName: "LiquidityPool", Handler: _Query_LiquidityPool_Handler, }, { MethodName: "LiquidityPoolByPoolCoinDenom", Handler: _Query_LiquidityPoolByPoolCoinDenom_Handler, }, { MethodName: "LiquidityPoolByReserveAcc", Handler: _Query_LiquidityPoolByReserveAcc_Handler, }, { MethodName: "LiquidityPoolBatch", Handler: _Query_LiquidityPoolBatch_Handler, }, { MethodName: "PoolBatchSwapMsgs", Handler: _Query_PoolBatchSwapMsgs_Handler, }, { MethodName: "PoolBatchSwapMsg", Handler: _Query_PoolBatchSwapMsg_Handler, }, { MethodName: "PoolBatchDepositMsgs", Handler: _Query_PoolBatchDepositMsgs_Handler, }, { MethodName: "PoolBatchDepositMsg", Handler: _Query_PoolBatchDepositMsg_Handler, }, { MethodName: "PoolBatchWithdrawMsgs", Handler: _Query_PoolBatchWithdrawMsgs_Handler, }, { MethodName: "PoolBatchWithdrawMsg", Handler: _Query_PoolBatchWithdrawMsg_Handler, }, { MethodName: "Params", Handler: _Query_Params_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "cyber/liquidity/v1beta1/query.proto", } func (m *QueryLiquidityPoolRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryLiquidityPoolRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryLiquidityPoolRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.PoolId != 0 { i = encodeVarintQuery(dAtA, i, uint64(m.PoolId)) i-- dAtA[i] = 0x8 } return len(dAtA) - i, nil } func (m *QueryLiquidityPoolResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryLiquidityPoolResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryLiquidityPoolResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.Pool.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa return len(dAtA) - i, nil } func (m *QueryLiquidityPoolByPoolCoinDenomRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryLiquidityPoolByPoolCoinDenomRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryLiquidityPoolByPoolCoinDenomRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.PoolCoinDenom) > 0 { i -= len(m.PoolCoinDenom) copy(dAtA[i:], m.PoolCoinDenom) i = encodeVarintQuery(dAtA, i, uint64(len(m.PoolCoinDenom))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *QueryLiquidityPoolByReserveAccRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryLiquidityPoolByReserveAccRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryLiquidityPoolByReserveAccRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.ReserveAcc) > 0 { i -= len(m.ReserveAcc) copy(dAtA[i:], m.ReserveAcc) i = encodeVarintQuery(dAtA, i, uint64(len(m.ReserveAcc))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *QueryLiquidityPoolBatchRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryLiquidityPoolBatchRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryLiquidityPoolBatchRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.PoolId != 0 { i = encodeVarintQuery(dAtA, i, uint64(m.PoolId)) i-- dAtA[i] = 0x8 } return len(dAtA) - i, nil } func (m *QueryLiquidityPoolBatchResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryLiquidityPoolBatchResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryLiquidityPoolBatchResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.Batch.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa return len(dAtA) - i, nil } func (m *QueryLiquidityPoolsRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryLiquidityPoolsRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryLiquidityPoolsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.Pagination != nil { { size, err := m.Pagination.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *QueryLiquidityPoolsResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryLiquidityPoolsResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryLiquidityPoolsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.Pagination != nil { { size, err := m.Pagination.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 } if len(m.Pools) > 0 { for iNdEx := len(m.Pools) - 1; iNdEx >= 0; iNdEx-- { { size, err := m.Pools[iNdEx].MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa } } return len(dAtA) - i, nil } func (m *QueryParamsRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryParamsRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryParamsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *QueryParamsResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryParamsResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryParamsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.Params.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa return len(dAtA) - i, nil } func (m *QueryPoolBatchSwapMsgsRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryPoolBatchSwapMsgsRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryPoolBatchSwapMsgsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.Pagination != nil { { size, err := m.Pagination.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 } if m.PoolId != 0 { i = encodeVarintQuery(dAtA, i, uint64(m.PoolId)) i-- dAtA[i] = 0x8 } return len(dAtA) - i, nil } func (m *QueryPoolBatchSwapMsgRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryPoolBatchSwapMsgRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryPoolBatchSwapMsgRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.MsgIndex != 0 { i = encodeVarintQuery(dAtA, i, uint64(m.MsgIndex)) i-- dAtA[i] = 0x10 } if m.PoolId != 0 { i = encodeVarintQuery(dAtA, i, uint64(m.PoolId)) i-- dAtA[i] = 0x8 } return len(dAtA) - i, nil } func (m *QueryPoolBatchSwapMsgsResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryPoolBatchSwapMsgsResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryPoolBatchSwapMsgsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.Pagination != nil { { size, err := m.Pagination.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 } if len(m.Swaps) > 0 { for iNdEx := len(m.Swaps) - 1; iNdEx >= 0; iNdEx-- { { size, err := m.Swaps[iNdEx].MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa } } return len(dAtA) - i, nil } func (m *QueryPoolBatchSwapMsgResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryPoolBatchSwapMsgResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryPoolBatchSwapMsgResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.Swap.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa return len(dAtA) - i, nil } func (m *QueryPoolBatchDepositMsgsRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryPoolBatchDepositMsgsRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryPoolBatchDepositMsgsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.Pagination != nil { { size, err := m.Pagination.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 } if m.PoolId != 0 { i = encodeVarintQuery(dAtA, i, uint64(m.PoolId)) i-- dAtA[i] = 0x8 } return len(dAtA) - i, nil } func (m *QueryPoolBatchDepositMsgRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryPoolBatchDepositMsgRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryPoolBatchDepositMsgRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.MsgIndex != 0 { i = encodeVarintQuery(dAtA, i, uint64(m.MsgIndex)) i-- dAtA[i] = 0x10 } if m.PoolId != 0 { i = encodeVarintQuery(dAtA, i, uint64(m.PoolId)) i-- dAtA[i] = 0x8 } return len(dAtA) - i, nil } func (m *QueryPoolBatchDepositMsgsResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryPoolBatchDepositMsgsResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryPoolBatchDepositMsgsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.Pagination != nil { { size, err := m.Pagination.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 } if len(m.Deposits) > 0 { for iNdEx := len(m.Deposits) - 1; iNdEx >= 0; iNdEx-- { { size, err := m.Deposits[iNdEx].MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa } } return len(dAtA) - i, nil } func (m *QueryPoolBatchDepositMsgResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryPoolBatchDepositMsgResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryPoolBatchDepositMsgResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.Deposit.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa return len(dAtA) - i, nil } func (m *QueryPoolBatchWithdrawMsgsRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryPoolBatchWithdrawMsgsRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryPoolBatchWithdrawMsgsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.Pagination != nil { { size, err := m.Pagination.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 } if m.PoolId != 0 { i = encodeVarintQuery(dAtA, i, uint64(m.PoolId)) i-- dAtA[i] = 0x8 } return len(dAtA) - i, nil } func (m *QueryPoolBatchWithdrawMsgRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryPoolBatchWithdrawMsgRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryPoolBatchWithdrawMsgRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.MsgIndex != 0 { i = encodeVarintQuery(dAtA, i, uint64(m.MsgIndex)) i-- dAtA[i] = 0x10 } if m.PoolId != 0 { i = encodeVarintQuery(dAtA, i, uint64(m.PoolId)) i-- dAtA[i] = 0x8 } return len(dAtA) - i, nil } func (m *QueryPoolBatchWithdrawMsgsResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryPoolBatchWithdrawMsgsResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryPoolBatchWithdrawMsgsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.Pagination != nil { { size, err := m.Pagination.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 } if len(m.Withdraws) > 0 { for iNdEx := len(m.Withdraws) - 1; iNdEx >= 0; iNdEx-- { { size, err := m.Withdraws[iNdEx].MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa } } return len(dAtA) - i, nil } func (m *QueryPoolBatchWithdrawMsgResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryPoolBatchWithdrawMsgResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryPoolBatchWithdrawMsgResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.Withdraw.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa return len(dAtA) - i, nil } func encodeVarintQuery(dAtA []byte, offset int, v uint64) int { offset -= sovQuery(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *QueryLiquidityPoolRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.PoolId != 0 { n += 1 + sovQuery(uint64(m.PoolId)) } return n } func (m *QueryLiquidityPoolResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l l = m.Pool.Size() n += 1 + l + sovQuery(uint64(l)) return n } func (m *QueryLiquidityPoolByPoolCoinDenomRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.PoolCoinDenom) if l > 0 { n += 1 + l + sovQuery(uint64(l)) } return n } func (m *QueryLiquidityPoolByReserveAccRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.ReserveAcc) if l > 0 { n += 1 + l + sovQuery(uint64(l)) } return n } func (m *QueryLiquidityPoolBatchRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.PoolId != 0 { n += 1 + sovQuery(uint64(m.PoolId)) } return n } func (m *QueryLiquidityPoolBatchResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l l = m.Batch.Size() n += 1 + l + sovQuery(uint64(l)) return n } func (m *QueryLiquidityPoolsRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.Pagination != nil { l = m.Pagination.Size() n += 1 + l + sovQuery(uint64(l)) } return n } func (m *QueryLiquidityPoolsResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l if len(m.Pools) > 0 { for _, e := range m.Pools { l = e.Size() n += 1 + l + sovQuery(uint64(l)) } } if m.Pagination != nil { l = m.Pagination.Size() n += 1 + l + sovQuery(uint64(l)) } return n } func (m *QueryParamsRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *QueryParamsResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l l = m.Params.Size() n += 1 + l + sovQuery(uint64(l)) return n } func (m *QueryPoolBatchSwapMsgsRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.PoolId != 0 { n += 1 + sovQuery(uint64(m.PoolId)) } if m.Pagination != nil { l = m.Pagination.Size() n += 1 + l + sovQuery(uint64(l)) } return n } func (m *QueryPoolBatchSwapMsgRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.PoolId != 0 { n += 1 + sovQuery(uint64(m.PoolId)) } if m.MsgIndex != 0 { n += 1 + sovQuery(uint64(m.MsgIndex)) } return n } func (m *QueryPoolBatchSwapMsgsResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l if len(m.Swaps) > 0 { for _, e := range m.Swaps { l = e.Size() n += 1 + l + sovQuery(uint64(l)) } } if m.Pagination != nil { l = m.Pagination.Size() n += 1 + l + sovQuery(uint64(l)) } return n } func (m *QueryPoolBatchSwapMsgResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l l = m.Swap.Size() n += 1 + l + sovQuery(uint64(l)) return n } func (m *QueryPoolBatchDepositMsgsRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.PoolId != 0 { n += 1 + sovQuery(uint64(m.PoolId)) } if m.Pagination != nil { l = m.Pagination.Size() n += 1 + l + sovQuery(uint64(l)) } return n } func (m *QueryPoolBatchDepositMsgRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.PoolId != 0 { n += 1 + sovQuery(uint64(m.PoolId)) } if m.MsgIndex != 0 { n += 1 + sovQuery(uint64(m.MsgIndex)) } return n } func (m *QueryPoolBatchDepositMsgsResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l if len(m.Deposits) > 0 { for _, e := range m.Deposits { l = e.Size() n += 1 + l + sovQuery(uint64(l)) } } if m.Pagination != nil { l = m.Pagination.Size() n += 1 + l + sovQuery(uint64(l)) } return n } func (m *QueryPoolBatchDepositMsgResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l l = m.Deposit.Size() n += 1 + l + sovQuery(uint64(l)) return n } func (m *QueryPoolBatchWithdrawMsgsRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.PoolId != 0 { n += 1 + sovQuery(uint64(m.PoolId)) } if m.Pagination != nil { l = m.Pagination.Size() n += 1 + l + sovQuery(uint64(l)) } return n } func (m *QueryPoolBatchWithdrawMsgRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.PoolId != 0 { n += 1 + sovQuery(uint64(m.PoolId)) } if m.MsgIndex != 0 { n += 1 + sovQuery(uint64(m.MsgIndex)) } return n } func (m *QueryPoolBatchWithdrawMsgsResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l if len(m.Withdraws) > 0 { for _, e := range m.Withdraws { l = e.Size() n += 1 + l + sovQuery(uint64(l)) } } if m.Pagination != nil { l = m.Pagination.Size() n += 1 + l + sovQuery(uint64(l)) } return n } func (m *QueryPoolBatchWithdrawMsgResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l l = m.Withdraw.Size() n += 1 + l + sovQuery(uint64(l)) return n } func sovQuery(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozQuery(x uint64) (n int) { return sovQuery(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *QueryLiquidityPoolRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryLiquidityPoolRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryLiquidityPoolRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field PoolId", wireType) } m.PoolId = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.PoolId |= uint64(b&0x7F) << shift if b < 0x80 { break } } default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryLiquidityPoolResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryLiquidityPoolResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryLiquidityPoolResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Pool", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Pool.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryLiquidityPoolByPoolCoinDenomRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryLiquidityPoolByPoolCoinDenomRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryLiquidityPoolByPoolCoinDenomRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field PoolCoinDenom", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } m.PoolCoinDenom = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryLiquidityPoolByReserveAccRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryLiquidityPoolByReserveAccRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryLiquidityPoolByReserveAccRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field ReserveAcc", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } m.ReserveAcc = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryLiquidityPoolBatchRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryLiquidityPoolBatchRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryLiquidityPoolBatchRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field PoolId", wireType) } m.PoolId = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.PoolId |= uint64(b&0x7F) << shift if b < 0x80 { break } } default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryLiquidityPoolBatchResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryLiquidityPoolBatchResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryLiquidityPoolBatchResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Batch", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Batch.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryLiquidityPoolsRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryLiquidityPoolsRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryLiquidityPoolsRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if m.Pagination == nil { m.Pagination = &query.PageRequest{} } if err := m.Pagination.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryLiquidityPoolsResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryLiquidityPoolsResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryLiquidityPoolsResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Pools", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } m.Pools = append(m.Pools, Pool{}) if err := m.Pools[len(m.Pools)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if m.Pagination == nil { m.Pagination = &query.PageResponse{} } if err := m.Pagination.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryParamsRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryParamsRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryParamsRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryParamsResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryParamsResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryParamsResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Params.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryPoolBatchSwapMsgsRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryPoolBatchSwapMsgsRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryPoolBatchSwapMsgsRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field PoolId", wireType) } m.PoolId = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.PoolId |= uint64(b&0x7F) << shift if b < 0x80 { break } } case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if m.Pagination == nil { m.Pagination = &query.PageRequest{} } if err := m.Pagination.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryPoolBatchSwapMsgRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryPoolBatchSwapMsgRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryPoolBatchSwapMsgRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field PoolId", wireType) } m.PoolId = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.PoolId |= uint64(b&0x7F) << shift if b < 0x80 { break } } case 2: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field MsgIndex", wireType) } m.MsgIndex = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.MsgIndex |= uint64(b&0x7F) << shift if b < 0x80 { break } } default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryPoolBatchSwapMsgsResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryPoolBatchSwapMsgsResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryPoolBatchSwapMsgsResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Swaps", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } m.Swaps = append(m.Swaps, SwapMsgState{}) if err := m.Swaps[len(m.Swaps)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if m.Pagination == nil { m.Pagination = &query.PageResponse{} } if err := m.Pagination.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryPoolBatchSwapMsgResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryPoolBatchSwapMsgResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryPoolBatchSwapMsgResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Swap", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Swap.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryPoolBatchDepositMsgsRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryPoolBatchDepositMsgsRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryPoolBatchDepositMsgsRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field PoolId", wireType) } m.PoolId = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.PoolId |= uint64(b&0x7F) << shift if b < 0x80 { break } } case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if m.Pagination == nil { m.Pagination = &query.PageRequest{} } if err := m.Pagination.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryPoolBatchDepositMsgRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryPoolBatchDepositMsgRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryPoolBatchDepositMsgRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field PoolId", wireType) } m.PoolId = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.PoolId |= uint64(b&0x7F) << shift if b < 0x80 { break } } case 2: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field MsgIndex", wireType) } m.MsgIndex = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.MsgIndex |= uint64(b&0x7F) << shift if b < 0x80 { break } } default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryPoolBatchDepositMsgsResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryPoolBatchDepositMsgsResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryPoolBatchDepositMsgsResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Deposits", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } m.Deposits = append(m.Deposits, DepositMsgState{}) if err := m.Deposits[len(m.Deposits)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if m.Pagination == nil { m.Pagination = &query.PageResponse{} } if err := m.Pagination.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryPoolBatchDepositMsgResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryPoolBatchDepositMsgResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryPoolBatchDepositMsgResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Deposit", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Deposit.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryPoolBatchWithdrawMsgsRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryPoolBatchWithdrawMsgsRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryPoolBatchWithdrawMsgsRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field PoolId", wireType) } m.PoolId = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.PoolId |= uint64(b&0x7F) << shift if b < 0x80 { break } } case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if m.Pagination == nil { m.Pagination = &query.PageRequest{} } if err := m.Pagination.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryPoolBatchWithdrawMsgRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryPoolBatchWithdrawMsgRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryPoolBatchWithdrawMsgRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field PoolId", wireType) } m.PoolId = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.PoolId |= uint64(b&0x7F) << shift if b < 0x80 { break } } case 2: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field MsgIndex", wireType) } m.MsgIndex = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.MsgIndex |= uint64(b&0x7F) << shift if b < 0x80 { break } } default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryPoolBatchWithdrawMsgsResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryPoolBatchWithdrawMsgsResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryPoolBatchWithdrawMsgsResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Withdraws", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } m.Withdraws = append(m.Withdraws, WithdrawMsgState{}) if err := m.Withdraws[len(m.Withdraws)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if m.Pagination == nil { m.Pagination = &query.PageResponse{} } if err := m.Pagination.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryPoolBatchWithdrawMsgResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryPoolBatchWithdrawMsgResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryPoolBatchWithdrawMsgResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Withdraw", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Withdraw.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipQuery(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowQuery } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowQuery } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowQuery } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthQuery } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupQuery } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthQuery } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthQuery = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowQuery = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupQuery = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/liquidity/types/query.pb.gw.go ================================================ // Code generated by protoc-gen-grpc-gateway. DO NOT EDIT. // source: cyber/liquidity/v1beta1/query.proto /* Package types is a reverse proxy. It translates gRPC into RESTful JSON APIs. */ package types import ( "context" "io" "net/http" "github.com/golang/protobuf/descriptor" "github.com/golang/protobuf/proto" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/grpc-ecosystem/grpc-gateway/utilities" "google.golang.org/grpc" "google.golang.org/grpc/codes" "google.golang.org/grpc/grpclog" "google.golang.org/grpc/metadata" "google.golang.org/grpc/status" ) // Suppress "imported and not used" errors var ( _ codes.Code _ io.Reader _ status.Status _ = runtime.String _ = utilities.NewDoubleArray _ = descriptor.ForMessage _ = metadata.Join ) var filter_Query_LiquidityPools_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} func request_Query_LiquidityPools_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryLiquidityPoolsRequest var metadata runtime.ServerMetadata if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_LiquidityPools_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := client.LiquidityPools(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_LiquidityPools_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryLiquidityPoolsRequest var metadata runtime.ServerMetadata if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_LiquidityPools_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := server.LiquidityPools(ctx, &protoReq) return msg, metadata, err } func request_Query_LiquidityPool_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryLiquidityPoolRequest var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["pool_id"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "pool_id") } protoReq.PoolId, err = runtime.Uint64(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "pool_id", err) } msg, err := client.LiquidityPool(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_LiquidityPool_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryLiquidityPoolRequest var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["pool_id"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "pool_id") } protoReq.PoolId, err = runtime.Uint64(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "pool_id", err) } msg, err := server.LiquidityPool(ctx, &protoReq) return msg, metadata, err } func request_Query_LiquidityPoolByPoolCoinDenom_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryLiquidityPoolByPoolCoinDenomRequest var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["pool_coin_denom"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "pool_coin_denom") } protoReq.PoolCoinDenom, err = runtime.String(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "pool_coin_denom", err) } msg, err := client.LiquidityPoolByPoolCoinDenom(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_LiquidityPoolByPoolCoinDenom_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryLiquidityPoolByPoolCoinDenomRequest var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["pool_coin_denom"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "pool_coin_denom") } protoReq.PoolCoinDenom, err = runtime.String(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "pool_coin_denom", err) } msg, err := server.LiquidityPoolByPoolCoinDenom(ctx, &protoReq) return msg, metadata, err } func request_Query_LiquidityPoolByReserveAcc_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryLiquidityPoolByReserveAccRequest var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["reserve_acc"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "reserve_acc") } protoReq.ReserveAcc, err = runtime.String(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "reserve_acc", err) } msg, err := client.LiquidityPoolByReserveAcc(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_LiquidityPoolByReserveAcc_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryLiquidityPoolByReserveAccRequest var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["reserve_acc"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "reserve_acc") } protoReq.ReserveAcc, err = runtime.String(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "reserve_acc", err) } msg, err := server.LiquidityPoolByReserveAcc(ctx, &protoReq) return msg, metadata, err } func request_Query_LiquidityPoolBatch_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryLiquidityPoolBatchRequest var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["pool_id"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "pool_id") } protoReq.PoolId, err = runtime.Uint64(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "pool_id", err) } msg, err := client.LiquidityPoolBatch(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_LiquidityPoolBatch_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryLiquidityPoolBatchRequest var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["pool_id"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "pool_id") } protoReq.PoolId, err = runtime.Uint64(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "pool_id", err) } msg, err := server.LiquidityPoolBatch(ctx, &protoReq) return msg, metadata, err } var filter_Query_PoolBatchSwapMsgs_0 = &utilities.DoubleArray{Encoding: map[string]int{"pool_id": 0}, Base: []int{1, 1, 0}, Check: []int{0, 1, 2}} func request_Query_PoolBatchSwapMsgs_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryPoolBatchSwapMsgsRequest var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["pool_id"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "pool_id") } protoReq.PoolId, err = runtime.Uint64(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "pool_id", err) } if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_PoolBatchSwapMsgs_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := client.PoolBatchSwapMsgs(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_PoolBatchSwapMsgs_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryPoolBatchSwapMsgsRequest var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["pool_id"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "pool_id") } protoReq.PoolId, err = runtime.Uint64(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "pool_id", err) } if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_PoolBatchSwapMsgs_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := server.PoolBatchSwapMsgs(ctx, &protoReq) return msg, metadata, err } func request_Query_PoolBatchSwapMsg_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryPoolBatchSwapMsgRequest var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["pool_id"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "pool_id") } protoReq.PoolId, err = runtime.Uint64(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "pool_id", err) } val, ok = pathParams["msg_index"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "msg_index") } protoReq.MsgIndex, err = runtime.Uint64(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "msg_index", err) } msg, err := client.PoolBatchSwapMsg(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_PoolBatchSwapMsg_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryPoolBatchSwapMsgRequest var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["pool_id"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "pool_id") } protoReq.PoolId, err = runtime.Uint64(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "pool_id", err) } val, ok = pathParams["msg_index"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "msg_index") } protoReq.MsgIndex, err = runtime.Uint64(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "msg_index", err) } msg, err := server.PoolBatchSwapMsg(ctx, &protoReq) return msg, metadata, err } var filter_Query_PoolBatchDepositMsgs_0 = &utilities.DoubleArray{Encoding: map[string]int{"pool_id": 0}, Base: []int{1, 1, 0}, Check: []int{0, 1, 2}} func request_Query_PoolBatchDepositMsgs_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryPoolBatchDepositMsgsRequest var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["pool_id"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "pool_id") } protoReq.PoolId, err = runtime.Uint64(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "pool_id", err) } if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_PoolBatchDepositMsgs_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := client.PoolBatchDepositMsgs(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_PoolBatchDepositMsgs_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryPoolBatchDepositMsgsRequest var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["pool_id"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "pool_id") } protoReq.PoolId, err = runtime.Uint64(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "pool_id", err) } if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_PoolBatchDepositMsgs_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := server.PoolBatchDepositMsgs(ctx, &protoReq) return msg, metadata, err } func request_Query_PoolBatchDepositMsg_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryPoolBatchDepositMsgRequest var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["pool_id"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "pool_id") } protoReq.PoolId, err = runtime.Uint64(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "pool_id", err) } val, ok = pathParams["msg_index"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "msg_index") } protoReq.MsgIndex, err = runtime.Uint64(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "msg_index", err) } msg, err := client.PoolBatchDepositMsg(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_PoolBatchDepositMsg_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryPoolBatchDepositMsgRequest var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["pool_id"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "pool_id") } protoReq.PoolId, err = runtime.Uint64(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "pool_id", err) } val, ok = pathParams["msg_index"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "msg_index") } protoReq.MsgIndex, err = runtime.Uint64(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "msg_index", err) } msg, err := server.PoolBatchDepositMsg(ctx, &protoReq) return msg, metadata, err } var filter_Query_PoolBatchWithdrawMsgs_0 = &utilities.DoubleArray{Encoding: map[string]int{"pool_id": 0}, Base: []int{1, 1, 0}, Check: []int{0, 1, 2}} func request_Query_PoolBatchWithdrawMsgs_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryPoolBatchWithdrawMsgsRequest var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["pool_id"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "pool_id") } protoReq.PoolId, err = runtime.Uint64(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "pool_id", err) } if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_PoolBatchWithdrawMsgs_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := client.PoolBatchWithdrawMsgs(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_PoolBatchWithdrawMsgs_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryPoolBatchWithdrawMsgsRequest var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["pool_id"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "pool_id") } protoReq.PoolId, err = runtime.Uint64(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "pool_id", err) } if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_PoolBatchWithdrawMsgs_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := server.PoolBatchWithdrawMsgs(ctx, &protoReq) return msg, metadata, err } func request_Query_PoolBatchWithdrawMsg_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryPoolBatchWithdrawMsgRequest var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["pool_id"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "pool_id") } protoReq.PoolId, err = runtime.Uint64(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "pool_id", err) } val, ok = pathParams["msg_index"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "msg_index") } protoReq.MsgIndex, err = runtime.Uint64(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "msg_index", err) } msg, err := client.PoolBatchWithdrawMsg(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_PoolBatchWithdrawMsg_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryPoolBatchWithdrawMsgRequest var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["pool_id"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "pool_id") } protoReq.PoolId, err = runtime.Uint64(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "pool_id", err) } val, ok = pathParams["msg_index"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "msg_index") } protoReq.MsgIndex, err = runtime.Uint64(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "msg_index", err) } msg, err := server.PoolBatchWithdrawMsg(ctx, &protoReq) return msg, metadata, err } func request_Query_Params_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryParamsRequest var metadata runtime.ServerMetadata msg, err := client.Params(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_Params_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryParamsRequest var metadata runtime.ServerMetadata msg, err := server.Params(ctx, &protoReq) return msg, metadata, err } // RegisterQueryHandlerServer registers the http handlers for service Query to "mux". // UnaryRPC :call QueryServer directly. // StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. // Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterQueryHandlerFromEndpoint instead. func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, server QueryServer) error { mux.Handle("GET", pattern_Query_LiquidityPools_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_LiquidityPools_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_LiquidityPools_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_LiquidityPool_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_LiquidityPool_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_LiquidityPool_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_LiquidityPoolByPoolCoinDenom_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_LiquidityPoolByPoolCoinDenom_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_LiquidityPoolByPoolCoinDenom_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_LiquidityPoolByReserveAcc_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_LiquidityPoolByReserveAcc_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_LiquidityPoolByReserveAcc_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_LiquidityPoolBatch_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_LiquidityPoolBatch_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_LiquidityPoolBatch_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_PoolBatchSwapMsgs_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_PoolBatchSwapMsgs_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_PoolBatchSwapMsgs_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_PoolBatchSwapMsg_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_PoolBatchSwapMsg_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_PoolBatchSwapMsg_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_PoolBatchDepositMsgs_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_PoolBatchDepositMsgs_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_PoolBatchDepositMsgs_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_PoolBatchDepositMsg_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_PoolBatchDepositMsg_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_PoolBatchDepositMsg_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_PoolBatchWithdrawMsgs_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_PoolBatchWithdrawMsgs_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_PoolBatchWithdrawMsgs_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_PoolBatchWithdrawMsg_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_PoolBatchWithdrawMsg_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_PoolBatchWithdrawMsg_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_Params_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_Params_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Params_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) return nil } // RegisterQueryHandlerFromEndpoint is same as RegisterQueryHandler but // automatically dials to "endpoint" and closes the connection when "ctx" gets done. func RegisterQueryHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error) { conn, err := grpc.Dial(endpoint, opts...) if err != nil { return err } defer func() { if err != nil { if cerr := conn.Close(); cerr != nil { grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr) } return } go func() { <-ctx.Done() if cerr := conn.Close(); cerr != nil { grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr) } }() }() return RegisterQueryHandler(ctx, mux, conn) } // RegisterQueryHandler registers the http handlers for service Query to "mux". // The handlers forward requests to the grpc endpoint over "conn". func RegisterQueryHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error { return RegisterQueryHandlerClient(ctx, mux, NewQueryClient(conn)) } // RegisterQueryHandlerClient registers the http handlers for service Query // to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "QueryClient". // Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "QueryClient" // doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in // "QueryClient" to call the correct interceptors. func RegisterQueryHandlerClient(ctx context.Context, mux *runtime.ServeMux, client QueryClient) error { mux.Handle("GET", pattern_Query_LiquidityPools_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_LiquidityPools_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_LiquidityPools_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_LiquidityPool_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_LiquidityPool_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_LiquidityPool_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_LiquidityPoolByPoolCoinDenom_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_LiquidityPoolByPoolCoinDenom_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_LiquidityPoolByPoolCoinDenom_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_LiquidityPoolByReserveAcc_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_LiquidityPoolByReserveAcc_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_LiquidityPoolByReserveAcc_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_LiquidityPoolBatch_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_LiquidityPoolBatch_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_LiquidityPoolBatch_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_PoolBatchSwapMsgs_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_PoolBatchSwapMsgs_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_PoolBatchSwapMsgs_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_PoolBatchSwapMsg_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_PoolBatchSwapMsg_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_PoolBatchSwapMsg_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_PoolBatchDepositMsgs_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_PoolBatchDepositMsgs_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_PoolBatchDepositMsgs_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_PoolBatchDepositMsg_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_PoolBatchDepositMsg_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_PoolBatchDepositMsg_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_PoolBatchWithdrawMsgs_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_PoolBatchWithdrawMsgs_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_PoolBatchWithdrawMsgs_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_PoolBatchWithdrawMsg_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_PoolBatchWithdrawMsg_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_PoolBatchWithdrawMsg_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_Params_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_Params_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Params_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) return nil } var ( pattern_Query_LiquidityPools_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"cosmos", "liquidity", "v1beta1", "pools"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_LiquidityPool_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4}, []string{"cosmos", "liquidity", "v1beta1", "pools", "pool_id"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_LiquidityPoolByPoolCoinDenom_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4, 1, 0, 4, 1, 5, 4}, []string{"cosmos", "liquidity", "v1beta1", "pools", "pool_coin_denom"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_LiquidityPoolByReserveAcc_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 2, 4, 1, 0, 4, 1, 5, 4}, []string{"cosmos", "liquidity", "v1beta1", "pools", "reserve_acc"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_LiquidityPoolBatch_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4, 2, 5}, []string{"cosmos", "liquidity", "v1beta1", "pools", "pool_id", "batch"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_PoolBatchSwapMsgs_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4, 2, 5, 2, 6}, []string{"cosmos", "liquidity", "v1beta1", "pools", "pool_id", "batch", "swaps"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_PoolBatchSwapMsg_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4, 2, 5, 2, 6, 1, 0, 4, 1, 5, 7}, []string{"cosmos", "liquidity", "v1beta1", "pools", "pool_id", "batch", "swaps", "msg_index"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_PoolBatchDepositMsgs_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4, 2, 5, 2, 6}, []string{"cosmos", "liquidity", "v1beta1", "pools", "pool_id", "batch", "deposits"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_PoolBatchDepositMsg_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4, 2, 5, 2, 6, 1, 0, 4, 1, 5, 7}, []string{"cosmos", "liquidity", "v1beta1", "pools", "pool_id", "batch", "deposits", "msg_index"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_PoolBatchWithdrawMsgs_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4, 2, 5, 2, 6}, []string{"cosmos", "liquidity", "v1beta1", "pools", "pool_id", "batch", "withdraws"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_PoolBatchWithdrawMsg_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4, 2, 5, 2, 6, 1, 0, 4, 1, 5, 7}, []string{"cosmos", "liquidity", "v1beta1", "pools", "pool_id", "batch", "withdraws", "msg_index"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_Params_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"cosmos", "liquidity", "v1beta1", "params"}, "", runtime.AssumeColonVerbOpt(false))) ) var ( forward_Query_LiquidityPools_0 = runtime.ForwardResponseMessage forward_Query_LiquidityPool_0 = runtime.ForwardResponseMessage forward_Query_LiquidityPoolByPoolCoinDenom_0 = runtime.ForwardResponseMessage forward_Query_LiquidityPoolByReserveAcc_0 = runtime.ForwardResponseMessage forward_Query_LiquidityPoolBatch_0 = runtime.ForwardResponseMessage forward_Query_PoolBatchSwapMsgs_0 = runtime.ForwardResponseMessage forward_Query_PoolBatchSwapMsg_0 = runtime.ForwardResponseMessage forward_Query_PoolBatchDepositMsgs_0 = runtime.ForwardResponseMessage forward_Query_PoolBatchDepositMsg_0 = runtime.ForwardResponseMessage forward_Query_PoolBatchWithdrawMsgs_0 = runtime.ForwardResponseMessage forward_Query_PoolBatchWithdrawMsg_0 = runtime.ForwardResponseMessage forward_Query_Params_0 = runtime.ForwardResponseMessage ) ================================================ FILE: x/liquidity/types/swap.go ================================================ package types import ( "sort" sdk "github.com/cosmos/cosmos-sdk/types" ) // Type of match type MatchType int const ( ExactMatch MatchType = iota + 1 NoMatch FractionalMatch ) // Direction of price type PriceDirection int const ( Increasing PriceDirection = iota + 1 Decreasing Staying ) // Direction of order type OrderDirection int const ( DirectionXtoY OrderDirection = iota + 1 DirectionYtoX ) // Type of order map to index at price, having the pointer list of the swap batch message. type Order struct { Price sdk.Dec BuyOfferAmt sdk.Int SellOfferAmt sdk.Int SwapMsgStates []*SwapMsgState } // OrderBook is a list of orders type OrderBook []Order // Len implements sort.Interface for OrderBook func (orderBook OrderBook) Len() int { return len(orderBook) } // Less implements sort.Interface for OrderBook func (orderBook OrderBook) Less(i, j int) bool { return orderBook[i].Price.LT(orderBook[j].Price) } // Swap implements sort.Interface for OrderBook func (orderBook OrderBook) Swap(i, j int) { orderBook[i], orderBook[j] = orderBook[j], orderBook[i] } // increasing sort orderbook by order price func (orderBook OrderBook) Sort() { sort.Slice(orderBook, func(i, j int) bool { return orderBook[i].Price.LT(orderBook[j].Price) }) } // decreasing sort orderbook by order price func (orderBook OrderBook) Reverse() { sort.Slice(orderBook, func(i, j int) bool { return orderBook[i].Price.GT(orderBook[j].Price) }) } // Get number of not matched messages on the list. func CountNotMatchedMsgs(swapMsgStates []*SwapMsgState) int { cnt := 0 for _, m := range swapMsgStates { if m.Executed && !m.Succeeded { cnt++ } } return cnt } // Get number of fractional matched messages on the list. func CountFractionalMatchedMsgs(swapMsgStates []*SwapMsgState) int { cnt := 0 for _, m := range swapMsgStates { if m.Executed && m.Succeeded && !m.ToBeDeleted { cnt++ } } return cnt } // Order map type indexed by order price at price type OrderMap map[string]Order // Make orderbook by sort orderMap. func (orderMap OrderMap) SortOrderBook() (orderBook OrderBook) { for _, o := range orderMap { orderBook = append(orderBook, o) } orderBook.Sort() return orderBook } // struct of swap matching result of the batch type BatchResult struct { MatchType MatchType PriceDirection PriceDirection SwapPrice sdk.Dec EX sdk.Dec EY sdk.Dec OriginalEX sdk.Int OriginalEY sdk.Int PoolX sdk.Dec PoolY sdk.Dec TransactAmt sdk.Dec } // return of zero object, to avoid nil func NewBatchResult() BatchResult { return BatchResult{ SwapPrice: sdk.ZeroDec(), EX: sdk.ZeroDec(), EY: sdk.ZeroDec(), OriginalEX: sdk.ZeroInt(), OriginalEY: sdk.ZeroInt(), PoolX: sdk.ZeroDec(), PoolY: sdk.ZeroDec(), TransactAmt: sdk.ZeroDec(), } } // struct of swap matching result of each Batch swap message type MatchResult struct { OrderDirection OrderDirection OrderMsgIndex uint64 OrderPrice sdk.Dec OfferCoinAmt sdk.Dec TransactedCoinAmt sdk.Dec ExchangedDemandCoinAmt sdk.Dec OfferCoinFeeAmt sdk.Dec ExchangedCoinFeeAmt sdk.Dec SwapMsgState *SwapMsgState } // The price and coins of swap messages in orderbook are calculated // to derive match result with the price direction. func (orderBook OrderBook) Match(x, y sdk.Dec) (BatchResult, bool) { currentPrice := x.Quo(y) priceDirection := orderBook.PriceDirection(currentPrice) if priceDirection == Staying { return orderBook.CalculateMatchStay(currentPrice), true } return orderBook.CalculateMatch(priceDirection, x, y) } // Check orderbook validity naively func (orderBook OrderBook) Validate(currentPrice sdk.Dec) bool { if !currentPrice.IsPositive() { return false } maxBuyOrderPrice := sdk.ZeroDec() minSellOrderPrice := sdk.NewDec(1000000000000) for _, order := range orderBook { if order.BuyOfferAmt.IsPositive() && order.Price.GT(maxBuyOrderPrice) { maxBuyOrderPrice = order.Price } if order.SellOfferAmt.IsPositive() && (order.Price.LT(minSellOrderPrice)) { minSellOrderPrice = order.Price } } if maxBuyOrderPrice.GT(minSellOrderPrice) || maxBuyOrderPrice.Quo(currentPrice).GT(sdk.MustNewDecFromStr("1.10")) || minSellOrderPrice.Quo(currentPrice).LT(sdk.MustNewDecFromStr("0.90")) { return false } return true } // Calculate results for orderbook matching with unchanged price case func (orderBook OrderBook) CalculateMatchStay(currentPrice sdk.Dec) (r BatchResult) { r = NewBatchResult() r.SwapPrice = currentPrice r.OriginalEX, r.OriginalEY = orderBook.ExecutableAmt(r.SwapPrice) r.EX = r.OriginalEX.ToLegacyDec() r.EY = r.OriginalEY.ToLegacyDec() r.PriceDirection = Staying s := r.SwapPrice.Mul(r.EY) if r.EX.IsZero() || r.EY.IsZero() { r.MatchType = NoMatch } else if r.EX.Equal(s) { // Normalization to an integrator for easy determination of exactMatch r.MatchType = ExactMatch } else { // Decimal Error, When calculating the Executable value, conservatively Truncated decimal r.MatchType = FractionalMatch if r.EX.GT(s) { r.EX = s } else if r.EX.LT(s) { r.EY = r.EX.Quo(r.SwapPrice) } } return } // Calculates the batch results with the logic for each direction func (orderBook OrderBook) CalculateMatch(direction PriceDirection, x, y sdk.Dec) (maxScenario BatchResult, found bool) { currentPrice := x.Quo(y) lastOrderPrice := currentPrice var matchScenarios []BatchResult start, end, delta := 0, len(orderBook)-1, 1 if direction == Decreasing { start, end, delta = end, start, -1 } for i := start; i != end+delta; i += delta { order := orderBook[i] if (direction == Increasing && order.Price.LT(currentPrice)) || (direction == Decreasing && order.Price.GT(currentPrice)) { continue } else { orderPrice := order.Price r := orderBook.CalculateSwap(direction, x, y, orderPrice, lastOrderPrice) // Check to see if it exceeds a value that can be a decimal error if (direction == Increasing && r.PoolY.Sub(r.EX.Quo(r.SwapPrice)).GTE(sdk.OneDec())) || (direction == Decreasing && r.PoolX.Sub(r.EY.Mul(r.SwapPrice)).GTE(sdk.OneDec())) { continue } matchScenarios = append(matchScenarios, r) lastOrderPrice = orderPrice } } maxScenario = NewBatchResult() for _, s := range matchScenarios { MEX, MEY := orderBook.MustExecutableAmt(s.SwapPrice) if s.EX.GTE(MEX.ToLegacyDec()) && s.EY.GTE(MEY.ToLegacyDec()) { if s.MatchType == ExactMatch && s.TransactAmt.IsPositive() { maxScenario = s found = true break } else if s.TransactAmt.GT(maxScenario.TransactAmt) { maxScenario = s found = true } } } maxScenario.PriceDirection = direction return maxScenario, found } // CalculateSwap calculates the batch result. func (orderBook OrderBook) CalculateSwap(direction PriceDirection, x, y, orderPrice, lastOrderPrice sdk.Dec) BatchResult { r := NewBatchResult() r.OriginalEX, r.OriginalEY = orderBook.ExecutableAmt(lastOrderPrice.Add(orderPrice).Quo(sdk.NewDec(2))) r.EX = r.OriginalEX.ToLegacyDec() r.EY = r.OriginalEY.ToLegacyDec() r.SwapPrice = x.Add(r.EX.MulInt64(2)).Quo(y.Add(r.EY.MulInt64(2))) // P_s = (X + 2EX) / (Y + 2EY) if direction == Increasing { r.PoolY = r.SwapPrice.Mul(y).Sub(x).Quo(r.SwapPrice.MulInt64(2)) // (P_s * Y - X / 2P_s) if lastOrderPrice.LT(r.SwapPrice) && r.SwapPrice.LT(orderPrice) && !r.PoolY.IsNegative() { if r.EX.IsZero() && r.EY.IsZero() { r.MatchType = NoMatch } else { r.MatchType = ExactMatch } } } else if direction == Decreasing { r.PoolX = x.Sub(r.SwapPrice.Mul(y)).QuoInt64(2) // (X - P_s * Y) / 2 if orderPrice.LT(r.SwapPrice) && r.SwapPrice.LT(lastOrderPrice) && !r.PoolX.IsNegative() { if r.EX.IsZero() && r.EY.IsZero() { r.MatchType = NoMatch } else { r.MatchType = ExactMatch } } } if r.MatchType == 0 { r.OriginalEX, r.OriginalEY = orderBook.ExecutableAmt(orderPrice) r.EX = r.OriginalEX.ToLegacyDec() r.EY = r.OriginalEY.ToLegacyDec() r.SwapPrice = orderPrice // When calculating the Pool value, conservatively Truncated decimal, so Ceil it to reduce the decimal error if direction == Increasing { r.PoolY = r.SwapPrice.Mul(y).Sub(x).Quo(r.SwapPrice.MulInt64(2)) // (P_s * Y - X) / 2P_s r.EX = sdk.MinDec(r.EX, r.EY.Add(r.PoolY).Mul(r.SwapPrice)).Ceil() r.EY = sdk.MaxDec(sdk.MinDec(r.EY, r.EX.Quo(r.SwapPrice).Sub(r.PoolY)), sdk.ZeroDec()).Ceil() } else if direction == Decreasing { r.PoolX = x.Sub(r.SwapPrice.Mul(y)).QuoInt64(2) // (X - P_s * Y) / 2 r.EY = sdk.MinDec(r.EY, r.EX.Add(r.PoolX).Quo(r.SwapPrice)).Ceil() r.EX = sdk.MaxDec(sdk.MinDec(r.EX, r.EY.Mul(r.SwapPrice).Sub(r.PoolX)), sdk.ZeroDec()).Ceil() } r.MatchType = FractionalMatch } if direction == Increasing { if r.SwapPrice.LT(x.Quo(y)) || r.PoolY.IsNegative() { r.TransactAmt = sdk.ZeroDec() } else { r.TransactAmt = sdk.MinDec(r.EX, r.EY.Add(r.PoolY).Mul(r.SwapPrice)) } } else if direction == Decreasing { if r.SwapPrice.GT(x.Quo(y)) || r.PoolX.IsNegative() { r.TransactAmt = sdk.ZeroDec() } else { r.TransactAmt = sdk.MinDec(r.EY, r.EX.Add(r.PoolX).Quo(r.SwapPrice)) } } return r } // Get Price direction of the orderbook with current Price func (orderBook OrderBook) PriceDirection(currentPrice sdk.Dec) PriceDirection { buyAmtOverCurrentPrice := sdk.ZeroDec() buyAmtAtCurrentPrice := sdk.ZeroDec() sellAmtUnderCurrentPrice := sdk.ZeroDec() sellAmtAtCurrentPrice := sdk.ZeroDec() for _, order := range orderBook { if order.Price.GT(currentPrice) { buyAmtOverCurrentPrice = buyAmtOverCurrentPrice.Add(order.BuyOfferAmt.ToLegacyDec()) } else if order.Price.Equal(currentPrice) { buyAmtAtCurrentPrice = buyAmtAtCurrentPrice.Add(order.BuyOfferAmt.ToLegacyDec()) sellAmtAtCurrentPrice = sellAmtAtCurrentPrice.Add(order.SellOfferAmt.ToLegacyDec()) } else if order.Price.LT(currentPrice) { sellAmtUnderCurrentPrice = sellAmtUnderCurrentPrice.Add(order.SellOfferAmt.ToLegacyDec()) } } if buyAmtOverCurrentPrice.GT(currentPrice.Mul(sellAmtUnderCurrentPrice.Add(sellAmtAtCurrentPrice))) { return Increasing } else if currentPrice.Mul(sellAmtUnderCurrentPrice).GT(buyAmtOverCurrentPrice.Add(buyAmtAtCurrentPrice)) { return Decreasing } return Staying } // calculate the executable amount of the orderbook for each X, Y func (orderBook OrderBook) ExecutableAmt(swapPrice sdk.Dec) (executableBuyAmtX, executableSellAmtY sdk.Int) { executableBuyAmtX = sdk.ZeroInt() executableSellAmtY = sdk.ZeroInt() for _, order := range orderBook { if order.Price.GTE(swapPrice) { executableBuyAmtX = executableBuyAmtX.Add(order.BuyOfferAmt) } if order.Price.LTE(swapPrice) { executableSellAmtY = executableSellAmtY.Add(order.SellOfferAmt) } } return } // Check swap executable amount validity of the orderbook func (orderBook OrderBook) MustExecutableAmt(swapPrice sdk.Dec) (mustExecutableBuyAmtX, mustExecutableSellAmtY sdk.Int) { mustExecutableBuyAmtX = sdk.ZeroInt() mustExecutableSellAmtY = sdk.ZeroInt() for _, order := range orderBook { if order.Price.GT(swapPrice) { mustExecutableBuyAmtX = mustExecutableBuyAmtX.Add(order.BuyOfferAmt) } if order.Price.LT(swapPrice) { mustExecutableSellAmtY = mustExecutableSellAmtY.Add(order.SellOfferAmt) } } return } // make orderMap key as swap price, value as Buy, Sell Amount from swap msgs, with split as Buy xToY, Sell yToX msg list. func MakeOrderMap(swapMsgs []*SwapMsgState, denomX, denomY string, onlyNotMatched bool) (OrderMap, []*SwapMsgState, []*SwapMsgState) { orderMap := make(OrderMap) var xToY []*SwapMsgState // buying Y from X var yToX []*SwapMsgState // selling Y for X for _, m := range swapMsgs { if onlyNotMatched && (m.ToBeDeleted || m.RemainingOfferCoin.IsZero()) { continue } order := Order{ Price: m.Msg.OrderPrice, BuyOfferAmt: sdk.ZeroInt(), SellOfferAmt: sdk.ZeroInt(), } orderPriceString := m.Msg.OrderPrice.String() switch { // buying Y from X case m.Msg.OfferCoin.Denom == denomX: xToY = append(xToY, m) if o, ok := orderMap[orderPriceString]; ok { order = o order.BuyOfferAmt = o.BuyOfferAmt.Add(m.RemainingOfferCoin.Amount) } else { order.BuyOfferAmt = m.RemainingOfferCoin.Amount } // selling Y for X case m.Msg.OfferCoin.Denom == denomY: yToX = append(yToX, m) if o, ok := orderMap[orderPriceString]; ok { order = o order.SellOfferAmt = o.SellOfferAmt.Add(m.RemainingOfferCoin.Amount) } else { order.SellOfferAmt = m.RemainingOfferCoin.Amount } default: panic(ErrInvalidDenom) } order.SwapMsgStates = append(order.SwapMsgStates, m) orderMap[orderPriceString] = order } return orderMap, xToY, yToX } // check validity state of the batch swap messages, and set to delete state to height timeout expired order func ValidateStateAndExpireOrders(swapMsgStates []*SwapMsgState, currentHeight int64, expireThisHeight bool) { for _, order := range swapMsgStates { if !order.Executed { panic("not executed") } if order.RemainingOfferCoin.IsZero() { if !order.Succeeded || !order.ToBeDeleted { panic("broken state consistency for not matched order") } continue } // set toDelete, expired msgs if currentHeight > order.OrderExpiryHeight { if order.Succeeded || !order.ToBeDeleted { panic("broken state consistency for fractional matched order") } continue } if expireThisHeight && currentHeight == order.OrderExpiryHeight { order.ToBeDeleted = true } } } // Check swap price validity using list of match result. func CheckSwapPrice(matchResultXtoY, matchResultYtoX []MatchResult, swapPrice sdk.Dec) bool { if len(matchResultXtoY) == 0 && len(matchResultYtoX) == 0 { return true } // Check if it is greater than a value that can be a decimal error for _, m := range matchResultXtoY { if m.TransactedCoinAmt.Quo(swapPrice).Sub(m.ExchangedDemandCoinAmt).Abs().GT(sdk.OneDec()) { return false } } for _, m := range matchResultYtoX { if m.TransactedCoinAmt.Mul(swapPrice).Sub(m.ExchangedDemandCoinAmt).Abs().GT(sdk.OneDec()) { return false } } return !swapPrice.IsZero() } // Find matched orders and set status for msgs func FindOrderMatch(direction OrderDirection, swapMsgStates []*SwapMsgState, executableAmt, swapPrice sdk.Dec, height int64) ( matchResults []MatchResult, poolXDelta, poolYDelta sdk.Dec, ) { poolXDelta = sdk.ZeroDec() poolYDelta = sdk.ZeroDec() if executableAmt.IsZero() { return } if direction == DirectionXtoY { sort.SliceStable(swapMsgStates, func(i, j int) bool { return swapMsgStates[i].Msg.OrderPrice.GT(swapMsgStates[j].Msg.OrderPrice) }) } else if direction == DirectionYtoX { sort.SliceStable(swapMsgStates, func(i, j int) bool { return swapMsgStates[i].Msg.OrderPrice.LT(swapMsgStates[j].Msg.OrderPrice) }) } matchAmt := sdk.ZeroInt() accumMatchAmt := sdk.ZeroInt() var matchedSwapMsgStates []*SwapMsgState //nolint:prealloc for i, order := range swapMsgStates { // include the matched order in matchAmt, matchedSwapMsgStates if (direction == DirectionXtoY && order.Msg.OrderPrice.LT(swapPrice)) || (direction == DirectionYtoX && order.Msg.OrderPrice.GT(swapPrice)) { break } matchAmt = matchAmt.Add(order.RemainingOfferCoin.Amount) matchedSwapMsgStates = append(matchedSwapMsgStates, order) if i == len(swapMsgStates)-1 || !swapMsgStates[i+1].Msg.OrderPrice.Equal(order.Msg.OrderPrice) { if matchAmt.IsPositive() { var fractionalMatchRatio sdk.Dec if accumMatchAmt.Add(matchAmt).ToLegacyDec().GTE(executableAmt) { fractionalMatchRatio = executableAmt.Sub(accumMatchAmt.ToLegacyDec()).Quo(matchAmt.ToLegacyDec()) if fractionalMatchRatio.GT(sdk.NewDec(1)) { panic("fractionalMatchRatio should be between 0 and 1") } } else { fractionalMatchRatio = sdk.OneDec() } if !fractionalMatchRatio.IsPositive() { fractionalMatchRatio = sdk.OneDec() } for _, matchOrder := range matchedSwapMsgStates { offerAmt := matchOrder.RemainingOfferCoin.Amount.ToLegacyDec() matchResult := MatchResult{ OrderDirection: direction, OfferCoinAmt: offerAmt, // TransactedCoinAmt is a value that should not be lost, so Ceil it conservatively considering the decimal error. TransactedCoinAmt: offerAmt.Mul(fractionalMatchRatio).Ceil(), SwapMsgState: matchOrder, } if matchResult.OfferCoinAmt.Sub(matchResult.TransactedCoinAmt).LTE(sdk.OneDec()) { // Use ReservedOfferCoinFee to avoid decimal errors when OfferCoinAmt and TransactedCoinAmt are almost equal in value. matchResult.OfferCoinFeeAmt = matchResult.SwapMsgState.ReservedOfferCoinFee.Amount.ToLegacyDec() } else { matchResult.OfferCoinFeeAmt = matchResult.SwapMsgState.ReservedOfferCoinFee.Amount.ToLegacyDec().Mul(fractionalMatchRatio) } if direction == DirectionXtoY { matchResult.ExchangedDemandCoinAmt = matchResult.TransactedCoinAmt.Quo(swapPrice) matchResult.ExchangedCoinFeeAmt = matchResult.OfferCoinFeeAmt.Quo(swapPrice) } else if direction == DirectionYtoX { matchResult.ExchangedDemandCoinAmt = matchResult.TransactedCoinAmt.Mul(swapPrice) matchResult.ExchangedCoinFeeAmt = matchResult.OfferCoinFeeAmt.Mul(swapPrice) } // Check for differences above maximum decimal error if matchResult.TransactedCoinAmt.GT(matchResult.OfferCoinAmt) { panic("bad TransactedCoinAmt") } if matchResult.OfferCoinFeeAmt.GT(matchResult.OfferCoinAmt) && matchResult.OfferCoinFeeAmt.GT(sdk.OneDec()) { panic("bad OfferCoinFeeAmt") } matchResults = append(matchResults, matchResult) if direction == DirectionXtoY { poolXDelta = poolXDelta.Add(matchResult.TransactedCoinAmt) poolYDelta = poolYDelta.Sub(matchResult.ExchangedDemandCoinAmt) } else if direction == DirectionYtoX { poolXDelta = poolXDelta.Sub(matchResult.ExchangedDemandCoinAmt) poolYDelta = poolYDelta.Add(matchResult.TransactedCoinAmt) } } accumMatchAmt = accumMatchAmt.Add(matchAmt) } matchAmt = sdk.ZeroInt() matchedSwapMsgStates = matchedSwapMsgStates[:0] } } return matchResults, poolXDelta, poolYDelta } // UpdateSwapMsgStates updates SwapMsgStates using the MatchResults. func UpdateSwapMsgStates(x, y sdk.Dec, xToY, yToX []*SwapMsgState, matchResultXtoY, matchResultYtoX []MatchResult) ( []*SwapMsgState, []*SwapMsgState, sdk.Dec, sdk.Dec, sdk.Dec, sdk.Dec, ) { sort.SliceStable(xToY, func(i, j int) bool { return xToY[i].Msg.OrderPrice.GT(xToY[j].Msg.OrderPrice) }) sort.SliceStable(yToX, func(i, j int) bool { return yToX[i].Msg.OrderPrice.LT(yToX[j].Msg.OrderPrice) }) poolXDelta := sdk.ZeroDec() poolYDelta := sdk.ZeroDec() // Variables to accumulate and offset the values of int 1 caused by decimal error decimalErrorX := sdk.ZeroDec() decimalErrorY := sdk.ZeroDec() for _, match := range append(matchResultXtoY, matchResultYtoX...) { sms := match.SwapMsgState if match.OrderDirection == DirectionXtoY { poolXDelta = poolXDelta.Add(match.TransactedCoinAmt) poolYDelta = poolYDelta.Sub(match.ExchangedDemandCoinAmt) } else { poolXDelta = poolXDelta.Sub(match.ExchangedDemandCoinAmt) poolYDelta = poolYDelta.Add(match.TransactedCoinAmt) } if sms.RemainingOfferCoin.Amount.ToLegacyDec().Sub(match.TransactedCoinAmt).LTE(sdk.OneDec()) { // when RemainingOfferCoin and TransactedCoinAmt are almost equal in value, corrects the decimal error and processes as a exact match. sms.ExchangedOfferCoin.Amount = sms.ExchangedOfferCoin.Amount.Add(match.TransactedCoinAmt.TruncateInt()) sms.RemainingOfferCoin.Amount = sms.RemainingOfferCoin.Amount.Sub(match.TransactedCoinAmt.TruncateInt()) sms.ReservedOfferCoinFee.Amount = sms.ReservedOfferCoinFee.Amount.Sub(match.OfferCoinFeeAmt.TruncateInt()) if sms.ExchangedOfferCoin.IsNegative() || sms.RemainingOfferCoin.IsNegative() || sms.ReservedOfferCoinFee.IsNegative() { panic("negative coin amount after update") } if sms.RemainingOfferCoin.Amount.Equal(sdk.OneInt()) { decimalErrorY = decimalErrorY.Add(sdk.OneDec()) sms.RemainingOfferCoin.Amount = sdk.ZeroInt() } if !sms.RemainingOfferCoin.IsZero() || sms.ExchangedOfferCoin.Amount.GT(sms.Msg.OfferCoin.Amount) || sms.ReservedOfferCoinFee.Amount.GT(sdk.OneInt()) { panic("invalid state after update") } else { sms.Succeeded = true sms.ToBeDeleted = true } } else { // fractional match sms.ExchangedOfferCoin.Amount = sms.ExchangedOfferCoin.Amount.Add(match.TransactedCoinAmt.TruncateInt()) sms.RemainingOfferCoin.Amount = sms.RemainingOfferCoin.Amount.Sub(match.TransactedCoinAmt.TruncateInt()) sms.ReservedOfferCoinFee.Amount = sms.ReservedOfferCoinFee.Amount.Sub(match.OfferCoinFeeAmt.TruncateInt()) if sms.ExchangedOfferCoin.IsNegative() || sms.RemainingOfferCoin.IsNegative() || sms.ReservedOfferCoinFee.IsNegative() { panic("negative coin amount after update") } sms.Succeeded = true sms.ToBeDeleted = false } } // Offset accumulated decimal error values poolXDelta = poolXDelta.Add(decimalErrorX) poolYDelta = poolYDelta.Add(decimalErrorY) x = x.Add(poolXDelta) y = y.Add(poolYDelta) return xToY, yToX, x, y, poolXDelta, poolYDelta } ================================================ FILE: x/liquidity/types/tx.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: cyber/liquidity/v1beta1/tx.proto package types import ( context "context" fmt "fmt" io "io" math "math" math_bits "math/bits" _ "github.com/cosmos/cosmos-proto" github_com_cosmos_cosmos_sdk_types "github.com/cosmos/cosmos-sdk/types" types "github.com/cosmos/cosmos-sdk/types" _ "github.com/cosmos/gogoproto/gogoproto" grpc1 "github.com/cosmos/gogoproto/grpc" proto "github.com/cosmos/gogoproto/proto" grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" ) // Reference imports to suppress errors if they are not otherwise used. var ( _ = proto.Marshal _ = fmt.Errorf _ = math.Inf ) // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package // MsgCreatePool defines an sdk.Msg type that supports submitting a create // liquidity pool tx. // // See: // https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md type MsgCreatePool struct { PoolCreatorAddress string `protobuf:"bytes,1,opt,name=pool_creator_address,json=poolCreatorAddress,proto3" json:"pool_creator_address,omitempty" yaml:"pool_creator_address"` // id of the target pool type, must match the value in the pool. Only // pool-type-id 1 is supported. PoolTypeId uint32 `protobuf:"varint,2,opt,name=pool_type_id,json=poolTypeId,proto3" json:"pool_type_id,omitempty" yaml:"pool_type_id"` // reserve coin pair of the pool to deposit. DepositCoins github_com_cosmos_cosmos_sdk_types.Coins `protobuf:"bytes,4,rep,name=deposit_coins,json=depositCoins,proto3,castrepeated=github.com/cosmos/cosmos-sdk/types.Coins" json:"deposit_coins" yaml:"deposit_coins"` } func (m *MsgCreatePool) Reset() { *m = MsgCreatePool{} } func (m *MsgCreatePool) String() string { return proto.CompactTextString(m) } func (*MsgCreatePool) ProtoMessage() {} func (*MsgCreatePool) Descriptor() ([]byte, []int) { return fileDescriptor_d6c6519f5f802cc0, []int{0} } func (m *MsgCreatePool) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgCreatePool) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgCreatePool.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgCreatePool) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgCreatePool.Merge(m, src) } func (m *MsgCreatePool) XXX_Size() int { return m.Size() } func (m *MsgCreatePool) XXX_DiscardUnknown() { xxx_messageInfo_MsgCreatePool.DiscardUnknown(m) } var xxx_messageInfo_MsgCreatePool proto.InternalMessageInfo // MsgCreatePoolResponse defines the Msg/CreatePool response type. type MsgCreatePoolResponse struct{} func (m *MsgCreatePoolResponse) Reset() { *m = MsgCreatePoolResponse{} } func (m *MsgCreatePoolResponse) String() string { return proto.CompactTextString(m) } func (*MsgCreatePoolResponse) ProtoMessage() {} func (*MsgCreatePoolResponse) Descriptor() ([]byte, []int) { return fileDescriptor_d6c6519f5f802cc0, []int{1} } func (m *MsgCreatePoolResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgCreatePoolResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgCreatePoolResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgCreatePoolResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgCreatePoolResponse.Merge(m, src) } func (m *MsgCreatePoolResponse) XXX_Size() int { return m.Size() } func (m *MsgCreatePoolResponse) XXX_DiscardUnknown() { xxx_messageInfo_MsgCreatePoolResponse.DiscardUnknown(m) } var xxx_messageInfo_MsgCreatePoolResponse proto.InternalMessageInfo // `MsgDepositWithinBatch defines` an `sdk.Msg` type that supports submitting // a deposit request to the batch of the liquidity pool. // Deposit is submitted to the batch of the Liquidity pool with the specified // `pool_id`, `deposit_coins` for reserve. // This request is stacked in the batch of the liquidity pool, is not processed // immediately, and is processed in the `endblock` at the same time as other // requests. // // See: // https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md type MsgDepositWithinBatch struct { DepositorAddress string `protobuf:"bytes,1,opt,name=depositor_address,json=depositorAddress,proto3" json:"depositor_address,omitempty" yaml:"depositor_address"` // id of the target pool PoolId uint64 `protobuf:"varint,2,opt,name=pool_id,json=poolId,proto3" json:"pool_id,omitempty" yaml:"pool_id"` // reserve coin pair of the pool to deposit DepositCoins github_com_cosmos_cosmos_sdk_types.Coins `protobuf:"bytes,3,rep,name=deposit_coins,json=depositCoins,proto3,castrepeated=github.com/cosmos/cosmos-sdk/types.Coins" json:"deposit_coins" yaml:"deposit_coins"` } func (m *MsgDepositWithinBatch) Reset() { *m = MsgDepositWithinBatch{} } func (m *MsgDepositWithinBatch) String() string { return proto.CompactTextString(m) } func (*MsgDepositWithinBatch) ProtoMessage() {} func (*MsgDepositWithinBatch) Descriptor() ([]byte, []int) { return fileDescriptor_d6c6519f5f802cc0, []int{2} } func (m *MsgDepositWithinBatch) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgDepositWithinBatch) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgDepositWithinBatch.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgDepositWithinBatch) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgDepositWithinBatch.Merge(m, src) } func (m *MsgDepositWithinBatch) XXX_Size() int { return m.Size() } func (m *MsgDepositWithinBatch) XXX_DiscardUnknown() { xxx_messageInfo_MsgDepositWithinBatch.DiscardUnknown(m) } var xxx_messageInfo_MsgDepositWithinBatch proto.InternalMessageInfo // MsgDepositWithinBatchResponse defines the Msg/DepositWithinBatch response // type. type MsgDepositWithinBatchResponse struct{} func (m *MsgDepositWithinBatchResponse) Reset() { *m = MsgDepositWithinBatchResponse{} } func (m *MsgDepositWithinBatchResponse) String() string { return proto.CompactTextString(m) } func (*MsgDepositWithinBatchResponse) ProtoMessage() {} func (*MsgDepositWithinBatchResponse) Descriptor() ([]byte, []int) { return fileDescriptor_d6c6519f5f802cc0, []int{3} } func (m *MsgDepositWithinBatchResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgDepositWithinBatchResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgDepositWithinBatchResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgDepositWithinBatchResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgDepositWithinBatchResponse.Merge(m, src) } func (m *MsgDepositWithinBatchResponse) XXX_Size() int { return m.Size() } func (m *MsgDepositWithinBatchResponse) XXX_DiscardUnknown() { xxx_messageInfo_MsgDepositWithinBatchResponse.DiscardUnknown(m) } var xxx_messageInfo_MsgDepositWithinBatchResponse proto.InternalMessageInfo // `MsgWithdrawWithinBatch` defines an `sdk.Msg` type that supports submitting // a withdraw request to the batch of the liquidity pool. // Withdraw is submitted to the batch from the Liquidity pool with the // specified `pool_id`, `pool_coin` of the pool. // This request is stacked in the batch of the liquidity pool, is not processed // immediately, and is processed in the `endblock` at the same time as other // requests. // // See: // https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md type MsgWithdrawWithinBatch struct { WithdrawerAddress string `protobuf:"bytes,1,opt,name=withdrawer_address,json=withdrawerAddress,proto3" json:"withdrawer_address,omitempty" yaml:"withdrawer_address"` // id of the target pool PoolId uint64 `protobuf:"varint,2,opt,name=pool_id,json=poolId,proto3" json:"pool_id,omitempty" yaml:"pool_id"` PoolCoin types.Coin `protobuf:"bytes,3,opt,name=pool_coin,json=poolCoin,proto3,castrepeated=github.com/cosmos/cosmos-sdk/types.Coin" json:"pool_coin" yaml:"pool_coin"` } func (m *MsgWithdrawWithinBatch) Reset() { *m = MsgWithdrawWithinBatch{} } func (m *MsgWithdrawWithinBatch) String() string { return proto.CompactTextString(m) } func (*MsgWithdrawWithinBatch) ProtoMessage() {} func (*MsgWithdrawWithinBatch) Descriptor() ([]byte, []int) { return fileDescriptor_d6c6519f5f802cc0, []int{4} } func (m *MsgWithdrawWithinBatch) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgWithdrawWithinBatch) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgWithdrawWithinBatch.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgWithdrawWithinBatch) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgWithdrawWithinBatch.Merge(m, src) } func (m *MsgWithdrawWithinBatch) XXX_Size() int { return m.Size() } func (m *MsgWithdrawWithinBatch) XXX_DiscardUnknown() { xxx_messageInfo_MsgWithdrawWithinBatch.DiscardUnknown(m) } var xxx_messageInfo_MsgWithdrawWithinBatch proto.InternalMessageInfo // MsgWithdrawWithinBatchResponse defines the Msg/WithdrawWithinBatch response // type. type MsgWithdrawWithinBatchResponse struct{} func (m *MsgWithdrawWithinBatchResponse) Reset() { *m = MsgWithdrawWithinBatchResponse{} } func (m *MsgWithdrawWithinBatchResponse) String() string { return proto.CompactTextString(m) } func (*MsgWithdrawWithinBatchResponse) ProtoMessage() {} func (*MsgWithdrawWithinBatchResponse) Descriptor() ([]byte, []int) { return fileDescriptor_d6c6519f5f802cc0, []int{5} } func (m *MsgWithdrawWithinBatchResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgWithdrawWithinBatchResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgWithdrawWithinBatchResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgWithdrawWithinBatchResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgWithdrawWithinBatchResponse.Merge(m, src) } func (m *MsgWithdrawWithinBatchResponse) XXX_Size() int { return m.Size() } func (m *MsgWithdrawWithinBatchResponse) XXX_DiscardUnknown() { xxx_messageInfo_MsgWithdrawWithinBatchResponse.DiscardUnknown(m) } var xxx_messageInfo_MsgWithdrawWithinBatchResponse proto.InternalMessageInfo // `MsgSwapWithinBatch` defines an sdk.Msg type that supports submitting a swap // offer request to the batch of the liquidity pool. Submit swap offer to the // liquidity pool batch with the specified the `pool_id`, `swap_type_id`, // `demand_coin_denom` with the coin and the price you're offering // and `offer_coin_fee` must be half of offer coin amount * current // `params.swap_fee_rate` and ceil for reservation to pay fees. This request is // stacked in the batch of the liquidity pool, is not processed immediately, and // is processed in the `endblock` at the same time as other requests. You must // request the same fields as the pool. Only the default `swap_type_id` 1 is // supported. // // See: https://github.com/gravity-devs/liquidity/tree/develop/doc // https://github.com/gravity-devs/liquidity/blob/develop/x/liquidity/spec/04_messages.md type MsgSwapWithinBatch struct { // address of swap requester SwapRequesterAddress string `protobuf:"bytes,1,opt,name=swap_requester_address,json=swapRequesterAddress,proto3" json:"swap_requester_address,omitempty" yaml:"swap_requester_address"` // id of swap type, must match the value in the pool. Only `swap_type_id` 1 is // supported. PoolId uint64 `protobuf:"varint,2,opt,name=pool_id,json=poolId,proto3" json:"pool_id,omitempty" yaml:"pool_id"` // id of swap type. Must match the value in the pool. SwapTypeId uint32 `protobuf:"varint,3,opt,name=swap_type_id,json=swapTypeId,proto3" json:"swap_type_id,omitempty" yaml:"swap_type_id"` // offer sdk.coin for the swap request, must match the denom in the pool. OfferCoin types.Coin `protobuf:"bytes,4,opt,name=offer_coin,json=offerCoin,proto3,castrepeated=github.com/cosmos/cosmos-sdk/types.Coin" json:"offer_coin" yaml:"offer_coin"` // denom of demand coin to be exchanged on the swap request, must match the // denom in the pool. DemandCoinDenom string `protobuf:"bytes,5,opt,name=demand_coin_denom,json=demandCoinDenom,proto3" json:"demand_coin_denom,omitempty" yaml:"demand_coin_denom"` // half of offer coin amount * params.swap_fee_rate and ceil for reservation // to pay fees. OfferCoinFee types.Coin `protobuf:"bytes,6,opt,name=offer_coin_fee,json=offerCoinFee,proto3,castrepeated=github.com/cosmos/cosmos-sdk/types.Coin" json:"offer_coin_fee" yaml:"offer_coin_fee"` // limit order price for the order, the price is the exchange ratio of X/Y // where X is the amount of the first coin and Y is the amount // of the second coin when their denoms are sorted alphabetically. OrderPrice github_com_cosmos_cosmos_sdk_types.Dec `protobuf:"bytes,7,opt,name=order_price,json=orderPrice,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Dec" json:"order_price" yaml:"order_price"` } func (m *MsgSwapWithinBatch) Reset() { *m = MsgSwapWithinBatch{} } func (m *MsgSwapWithinBatch) String() string { return proto.CompactTextString(m) } func (*MsgSwapWithinBatch) ProtoMessage() {} func (*MsgSwapWithinBatch) Descriptor() ([]byte, []int) { return fileDescriptor_d6c6519f5f802cc0, []int{6} } func (m *MsgSwapWithinBatch) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgSwapWithinBatch) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgSwapWithinBatch.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgSwapWithinBatch) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgSwapWithinBatch.Merge(m, src) } func (m *MsgSwapWithinBatch) XXX_Size() int { return m.Size() } func (m *MsgSwapWithinBatch) XXX_DiscardUnknown() { xxx_messageInfo_MsgSwapWithinBatch.DiscardUnknown(m) } var xxx_messageInfo_MsgSwapWithinBatch proto.InternalMessageInfo // MsgSwapWithinBatchResponse defines the Msg/Swap response type. type MsgSwapWithinBatchResponse struct{} func (m *MsgSwapWithinBatchResponse) Reset() { *m = MsgSwapWithinBatchResponse{} } func (m *MsgSwapWithinBatchResponse) String() string { return proto.CompactTextString(m) } func (*MsgSwapWithinBatchResponse) ProtoMessage() {} func (*MsgSwapWithinBatchResponse) Descriptor() ([]byte, []int) { return fileDescriptor_d6c6519f5f802cc0, []int{7} } func (m *MsgSwapWithinBatchResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgSwapWithinBatchResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgSwapWithinBatchResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgSwapWithinBatchResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgSwapWithinBatchResponse.Merge(m, src) } func (m *MsgSwapWithinBatchResponse) XXX_Size() int { return m.Size() } func (m *MsgSwapWithinBatchResponse) XXX_DiscardUnknown() { xxx_messageInfo_MsgSwapWithinBatchResponse.DiscardUnknown(m) } var xxx_messageInfo_MsgSwapWithinBatchResponse proto.InternalMessageInfo func init() { proto.RegisterType((*MsgCreatePool)(nil), "cyber.liquidity.v1beta1.MsgCreatePool") proto.RegisterType((*MsgCreatePoolResponse)(nil), "cyber.liquidity.v1beta1.MsgCreatePoolResponse") proto.RegisterType((*MsgDepositWithinBatch)(nil), "cyber.liquidity.v1beta1.MsgDepositWithinBatch") proto.RegisterType((*MsgDepositWithinBatchResponse)(nil), "cyber.liquidity.v1beta1.MsgDepositWithinBatchResponse") proto.RegisterType((*MsgWithdrawWithinBatch)(nil), "cyber.liquidity.v1beta1.MsgWithdrawWithinBatch") proto.RegisterType((*MsgWithdrawWithinBatchResponse)(nil), "cyber.liquidity.v1beta1.MsgWithdrawWithinBatchResponse") proto.RegisterType((*MsgSwapWithinBatch)(nil), "cyber.liquidity.v1beta1.MsgSwapWithinBatch") proto.RegisterType((*MsgSwapWithinBatchResponse)(nil), "cyber.liquidity.v1beta1.MsgSwapWithinBatchResponse") } func init() { proto.RegisterFile("cyber/liquidity/v1beta1/tx.proto", fileDescriptor_d6c6519f5f802cc0) } var fileDescriptor_d6c6519f5f802cc0 = []byte{ // 864 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xc4, 0x96, 0xbf, 0x6f, 0xdb, 0x46, 0x14, 0xc7, 0x45, 0xcb, 0x71, 0xe2, 0x8b, 0x9d, 0xc6, 0x17, 0x25, 0xa6, 0xd5, 0x84, 0x14, 0x38, 0xa4, 0x06, 0x02, 0x93, 0x48, 0xdc, 0x36, 0x70, 0xb6, 0xca, 0x42, 0x91, 0x0e, 0x02, 0x02, 0xa6, 0x40, 0x81, 0x2e, 0x04, 0x45, 0x9e, 0xa9, 0x43, 0x25, 0x1e, 0xc3, 0xa3, 0xab, 0x08, 0x2d, 0xda, 0x35, 0xdd, 0xfa, 0x27, 0x64, 0xee, 0x58, 0x74, 0xec, 0xd4, 0x29, 0xe8, 0x14, 0x14, 0x1d, 0x8a, 0x0e, 0x6c, 0x61, 0x2f, 0x9d, 0xf9, 0x17, 0x14, 0xf7, 0x83, 0x14, 0x25, 0xd1, 0x8a, 0x94, 0x25, 0x13, 0x79, 0xf7, 0xbe, 0xef, 0xbd, 0x7b, 0x9f, 0xbb, 0x7b, 0x24, 0x68, 0x79, 0xe3, 0x1e, 0x8a, 0xad, 0x01, 0x7e, 0x76, 0x8a, 0x7d, 0x9c, 0x8c, 0xad, 0xaf, 0xef, 0xf7, 0x50, 0xe2, 0xde, 0xb7, 0x92, 0xe7, 0x66, 0x14, 0x93, 0x84, 0xc0, 0x5d, 0xae, 0x30, 0x0b, 0x85, 0x29, 0x15, 0xcd, 0x46, 0x40, 0x02, 0xc2, 0x35, 0x16, 0x7b, 0x13, 0xf2, 0xa6, 0xe6, 0x11, 0x3a, 0x24, 0xd4, 0xea, 0xb9, 0x14, 0x15, 0xc1, 0x3c, 0x82, 0x43, 0x69, 0xdf, 0x13, 0x76, 0x47, 0x38, 0x8a, 0x81, 0x30, 0x19, 0xbf, 0xaf, 0x81, 0xed, 0x2e, 0x0d, 0x8e, 0x63, 0xe4, 0x26, 0xe8, 0x09, 0x21, 0x03, 0x88, 0x41, 0x23, 0x22, 0x64, 0xe0, 0x78, 0x6c, 0x8a, 0xc4, 0x8e, 0xeb, 0xfb, 0x31, 0xa2, 0x54, 0x55, 0x5a, 0xca, 0xfe, 0x66, 0xfb, 0x61, 0x96, 0xea, 0xef, 0x8f, 0xdd, 0xe1, 0xe0, 0x91, 0x51, 0xa5, 0x32, 0xfe, 0xf8, 0xe5, 0xa0, 0x21, 0x13, 0x7c, 0x22, 0xa6, 0x9e, 0x26, 0x31, 0x0e, 0x03, 0x1b, 0x32, 0xf9, 0xb1, 0x50, 0x4b, 0x0b, 0x3c, 0x02, 0x5b, 0x3c, 0x48, 0x32, 0x8e, 0x90, 0x83, 0x7d, 0x75, 0xad, 0xa5, 0xec, 0x6f, 0xb7, 0x77, 0xb3, 0x54, 0xbf, 0x51, 0x4a, 0x21, 0xad, 0x86, 0x0d, 0xd8, 0xf0, 0xf3, 0x71, 0x84, 0x3e, 0xf3, 0xe1, 0x0b, 0x05, 0x6c, 0xfb, 0x28, 0x22, 0x14, 0x27, 0x0e, 0xab, 0x94, 0xaa, 0xeb, 0xad, 0xfa, 0xfe, 0xd5, 0x07, 0x7b, 0xa6, 0xcc, 0xce, 0x58, 0xe4, 0xd8, 0xcc, 0x63, 0x82, 0xc3, 0xf6, 0xe3, 0x57, 0xa9, 0x5e, 0xcb, 0x52, 0xbd, 0x21, 0x62, 0x4f, 0x79, 0x1b, 0x3f, 0xfd, 0xa3, 0xef, 0x07, 0x38, 0xe9, 0x9f, 0xf6, 0x4c, 0x8f, 0x0c, 0x25, 0x23, 0xf9, 0x38, 0xa0, 0xfe, 0x57, 0x16, 0x5b, 0x05, 0xe5, 0x81, 0xa8, 0xbd, 0x25, 0x7d, 0xf9, 0xe8, 0xd1, 0x95, 0x17, 0x2f, 0xf5, 0xda, 0x7f, 0x2f, 0xf5, 0x9a, 0xb1, 0x0b, 0x6e, 0x4e, 0xb1, 0xb4, 0x11, 0x8d, 0x48, 0x48, 0x91, 0xf1, 0xeb, 0x1a, 0xb7, 0x74, 0x84, 0xdb, 0x17, 0x38, 0xe9, 0xe3, 0xb0, 0xed, 0x26, 0x5e, 0x1f, 0xba, 0x60, 0x47, 0x06, 0x9b, 0x43, 0xfd, 0x61, 0x96, 0xea, 0xea, 0xd4, 0x5a, 0x97, 0xe1, 0x7c, 0xbd, 0xd0, 0xe6, 0x94, 0xef, 0x81, 0xcb, 0x9c, 0xa3, 0x04, 0xbc, 0xde, 0x86, 0x59, 0xaa, 0x5f, 0x2b, 0x01, 0x66, 0x6c, 0x37, 0xd8, 0x5b, 0x25, 0xd7, 0xfa, 0xbb, 0xe7, 0xaa, 0x83, 0x3b, 0x95, 0xf4, 0x0a, 0xbe, 0x3f, 0xaf, 0x81, 0x5b, 0x5d, 0x1a, 0x30, 0x93, 0x1f, 0xbb, 0xa3, 0x32, 0x60, 0x1f, 0xc0, 0x91, 0x9c, 0x46, 0xb3, 0x84, 0x3f, 0xca, 0x52, 0x7d, 0x4f, 0xac, 0x7a, 0x5e, 0x73, 0x31, 0xe2, 0x9d, 0x89, 0xf8, 0xad, 0x18, 0x7f, 0x03, 0x36, 0xc5, 0xdd, 0x21, 0x38, 0x54, 0xeb, 0x2d, 0x65, 0x31, 0xde, 0x63, 0x89, 0xf7, 0x7a, 0xf9, 0xd6, 0x11, 0x1c, 0x32, 0xb4, 0x1f, 0x2c, 0x89, 0xd6, 0xbe, 0xc2, 0x6f, 0x1f, 0xc1, 0x61, 0x89, 0x6a, 0x0b, 0x68, 0xd5, 0xcc, 0x0a, 0xac, 0xbf, 0x5d, 0x02, 0xb0, 0x4b, 0x83, 0xa7, 0x23, 0x37, 0x2a, 0x23, 0x25, 0xe0, 0x16, 0x1d, 0xb9, 0x91, 0x13, 0xa3, 0x67, 0xa7, 0x88, 0x26, 0x73, 0x58, 0x8f, 0xb2, 0x54, 0xbf, 0x23, 0x56, 0x5b, 0xad, 0xbb, 0x18, 0x6d, 0x83, 0x39, 0xd8, 0xb9, 0xfe, 0xad, 0xe8, 0x1e, 0x81, 0x2d, 0x9e, 0x35, 0x6f, 0x2a, 0xf5, 0xd9, 0xa6, 0x52, 0xb6, 0x1a, 0x36, 0x60, 0x43, 0xd9, 0x54, 0xbe, 0x03, 0x80, 0x9c, 0x9c, 0xa0, 0x58, 0xec, 0xcc, 0xfa, 0x9b, 0x76, 0xa6, 0x23, 0x77, 0x66, 0x47, 0xc4, 0x9d, 0xb8, 0xae, 0xb4, 0x35, 0x9b, 0xdc, 0x8f, 0xbd, 0xc2, 0xc7, 0xac, 0x19, 0x0c, 0xdd, 0xd0, 0xe7, 0x51, 0x1c, 0x1f, 0x85, 0x64, 0xa8, 0x5e, 0xe2, 0x4c, 0x6f, 0x97, 0x9b, 0xc1, 0x8c, 0xc4, 0xb0, 0xdf, 0x13, 0x73, 0x2c, 0x48, 0x87, 0xcd, 0xc0, 0x1f, 0x14, 0x70, 0x6d, 0xb2, 0x1e, 0xe7, 0x04, 0x21, 0x75, 0xe3, 0x4d, 0xe5, 0xe4, 0xf7, 0xf8, 0xe6, 0x6c, 0x39, 0xcc, 0x7d, 0xa5, 0x92, 0xb6, 0x8a, 0x92, 0x3e, 0x45, 0x08, 0x52, 0x70, 0x95, 0xc4, 0x3e, 0x8a, 0x9d, 0x28, 0xc6, 0x1e, 0x52, 0x2f, 0xf3, 0x7a, 0x6c, 0x96, 0xec, 0xef, 0x54, 0xbf, 0xbb, 0x44, 0xcc, 0x0e, 0xf2, 0xb2, 0x54, 0x87, 0x72, 0x59, 0x93, 0x50, 0xec, 0x18, 0x01, 0x59, 0x4e, 0x07, 0x79, 0x36, 0xe0, 0xb6, 0x27, 0xcc, 0x54, 0x3a, 0xe6, 0xb7, 0x41, 0x73, 0xfe, 0x0c, 0xe7, 0x47, 0xfc, 0xc1, 0x9f, 0x75, 0x50, 0xef, 0xd2, 0x00, 0xfa, 0x00, 0x94, 0xbe, 0x81, 0x77, 0xcd, 0x0b, 0x3e, 0xc0, 0xe6, 0x54, 0x7f, 0x6f, 0x9a, 0xcb, 0xe9, 0xf2, 0x6c, 0xf0, 0x5b, 0x00, 0x2b, 0xbe, 0x01, 0x0b, 0xa3, 0xcc, 0xeb, 0x9b, 0x1f, 0xaf, 0xa6, 0x2f, 0xb2, 0x7f, 0x0f, 0x6e, 0x54, 0x75, 0x48, 0x6b, 0x51, 0xb8, 0x0a, 0x87, 0xe6, 0xc3, 0x15, 0x1d, 0x8a, 0x05, 0xf4, 0xc1, 0x3a, 0xdb, 0x07, 0x78, 0x6f, 0x51, 0x80, 0x99, 0x9d, 0x6a, 0x1e, 0xae, 0x20, 0xce, 0x33, 0xb5, 0xbb, 0xaf, 0xce, 0x34, 0xe5, 0xf5, 0x99, 0xa6, 0xfc, 0x7b, 0xa6, 0x29, 0x3f, 0x9e, 0x6b, 0xb5, 0xd7, 0xe7, 0x5a, 0xed, 0xaf, 0x73, 0xad, 0xf6, 0xe5, 0x61, 0xf9, 0xc0, 0xb1, 0xc0, 0x1e, 0x09, 0x03, 0xd6, 0x65, 0xac, 0x80, 0x1c, 0x88, 0x1f, 0xb3, 0xe7, 0xa5, 0x5f, 0x33, 0x7e, 0x02, 0x7b, 0x1b, 0xfc, 0x67, 0xe9, 0xf0, 0xff, 0x00, 0x00, 0x00, 0xff, 0xff, 0x7a, 0x2f, 0xd4, 0x33, 0xba, 0x09, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. var ( _ context.Context _ grpc.ClientConn ) // This is a compile-time assertion to ensure that this generated file // is compatible with the grpc package it is being compiled against. const _ = grpc.SupportPackageIsVersion4 // MsgClient is the client API for Msg service. // // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. type MsgClient interface { // Submit a create liquidity pool message. CreatePool(ctx context.Context, in *MsgCreatePool, opts ...grpc.CallOption) (*MsgCreatePoolResponse, error) // Submit a deposit to the liquidity pool batch. DepositWithinBatch(ctx context.Context, in *MsgDepositWithinBatch, opts ...grpc.CallOption) (*MsgDepositWithinBatchResponse, error) // Submit a withdraw from the liquidity pool batch. WithdrawWithinBatch(ctx context.Context, in *MsgWithdrawWithinBatch, opts ...grpc.CallOption) (*MsgWithdrawWithinBatchResponse, error) // Submit a swap to the liquidity pool batch. Swap(ctx context.Context, in *MsgSwapWithinBatch, opts ...grpc.CallOption) (*MsgSwapWithinBatchResponse, error) } type msgClient struct { cc grpc1.ClientConn } func NewMsgClient(cc grpc1.ClientConn) MsgClient { return &msgClient{cc} } func (c *msgClient) CreatePool(ctx context.Context, in *MsgCreatePool, opts ...grpc.CallOption) (*MsgCreatePoolResponse, error) { out := new(MsgCreatePoolResponse) err := c.cc.Invoke(ctx, "/cyber.liquidity.v1beta1.Msg/CreatePool", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *msgClient) DepositWithinBatch(ctx context.Context, in *MsgDepositWithinBatch, opts ...grpc.CallOption) (*MsgDepositWithinBatchResponse, error) { out := new(MsgDepositWithinBatchResponse) err := c.cc.Invoke(ctx, "/cyber.liquidity.v1beta1.Msg/DepositWithinBatch", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *msgClient) WithdrawWithinBatch(ctx context.Context, in *MsgWithdrawWithinBatch, opts ...grpc.CallOption) (*MsgWithdrawWithinBatchResponse, error) { out := new(MsgWithdrawWithinBatchResponse) err := c.cc.Invoke(ctx, "/cyber.liquidity.v1beta1.Msg/WithdrawWithinBatch", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *msgClient) Swap(ctx context.Context, in *MsgSwapWithinBatch, opts ...grpc.CallOption) (*MsgSwapWithinBatchResponse, error) { out := new(MsgSwapWithinBatchResponse) err := c.cc.Invoke(ctx, "/cyber.liquidity.v1beta1.Msg/Swap", in, out, opts...) if err != nil { return nil, err } return out, nil } // MsgServer is the server API for Msg service. type MsgServer interface { // Submit a create liquidity pool message. CreatePool(context.Context, *MsgCreatePool) (*MsgCreatePoolResponse, error) // Submit a deposit to the liquidity pool batch. DepositWithinBatch(context.Context, *MsgDepositWithinBatch) (*MsgDepositWithinBatchResponse, error) // Submit a withdraw from the liquidity pool batch. WithdrawWithinBatch(context.Context, *MsgWithdrawWithinBatch) (*MsgWithdrawWithinBatchResponse, error) // Submit a swap to the liquidity pool batch. Swap(context.Context, *MsgSwapWithinBatch) (*MsgSwapWithinBatchResponse, error) } // UnimplementedMsgServer can be embedded to have forward compatible implementations. type UnimplementedMsgServer struct{} func (*UnimplementedMsgServer) CreatePool(ctx context.Context, req *MsgCreatePool) (*MsgCreatePoolResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method CreatePool not implemented") } func (*UnimplementedMsgServer) DepositWithinBatch(ctx context.Context, req *MsgDepositWithinBatch) (*MsgDepositWithinBatchResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method DepositWithinBatch not implemented") } func (*UnimplementedMsgServer) WithdrawWithinBatch(ctx context.Context, req *MsgWithdrawWithinBatch) (*MsgWithdrawWithinBatchResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method WithdrawWithinBatch not implemented") } func (*UnimplementedMsgServer) Swap(ctx context.Context, req *MsgSwapWithinBatch) (*MsgSwapWithinBatchResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method Swap not implemented") } func RegisterMsgServer(s grpc1.Server, srv MsgServer) { s.RegisterService(&_Msg_serviceDesc, srv) } func _Msg_CreatePool_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgCreatePool) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(MsgServer).CreatePool(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.liquidity.v1beta1.Msg/CreatePool", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).CreatePool(ctx, req.(*MsgCreatePool)) } return interceptor(ctx, in, info, handler) } func _Msg_DepositWithinBatch_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgDepositWithinBatch) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(MsgServer).DepositWithinBatch(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.liquidity.v1beta1.Msg/DepositWithinBatch", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).DepositWithinBatch(ctx, req.(*MsgDepositWithinBatch)) } return interceptor(ctx, in, info, handler) } func _Msg_WithdrawWithinBatch_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgWithdrawWithinBatch) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(MsgServer).WithdrawWithinBatch(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.liquidity.v1beta1.Msg/WithdrawWithinBatch", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).WithdrawWithinBatch(ctx, req.(*MsgWithdrawWithinBatch)) } return interceptor(ctx, in, info, handler) } func _Msg_Swap_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgSwapWithinBatch) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(MsgServer).Swap(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.liquidity.v1beta1.Msg/Swap", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).Swap(ctx, req.(*MsgSwapWithinBatch)) } return interceptor(ctx, in, info, handler) } var _Msg_serviceDesc = grpc.ServiceDesc{ ServiceName: "cyber.liquidity.v1beta1.Msg", HandlerType: (*MsgServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "CreatePool", Handler: _Msg_CreatePool_Handler, }, { MethodName: "DepositWithinBatch", Handler: _Msg_DepositWithinBatch_Handler, }, { MethodName: "WithdrawWithinBatch", Handler: _Msg_WithdrawWithinBatch_Handler, }, { MethodName: "Swap", Handler: _Msg_Swap_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "cyber/liquidity/v1beta1/tx.proto", } func (m *MsgCreatePool) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgCreatePool) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgCreatePool) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.DepositCoins) > 0 { for iNdEx := len(m.DepositCoins) - 1; iNdEx >= 0; iNdEx-- { { size, err := m.DepositCoins[iNdEx].MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintTx(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x22 } } if m.PoolTypeId != 0 { i = encodeVarintTx(dAtA, i, uint64(m.PoolTypeId)) i-- dAtA[i] = 0x10 } if len(m.PoolCreatorAddress) > 0 { i -= len(m.PoolCreatorAddress) copy(dAtA[i:], m.PoolCreatorAddress) i = encodeVarintTx(dAtA, i, uint64(len(m.PoolCreatorAddress))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *MsgCreatePoolResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgCreatePoolResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgCreatePoolResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *MsgDepositWithinBatch) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgDepositWithinBatch) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgDepositWithinBatch) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.DepositCoins) > 0 { for iNdEx := len(m.DepositCoins) - 1; iNdEx >= 0; iNdEx-- { { size, err := m.DepositCoins[iNdEx].MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintTx(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x1a } } if m.PoolId != 0 { i = encodeVarintTx(dAtA, i, uint64(m.PoolId)) i-- dAtA[i] = 0x10 } if len(m.DepositorAddress) > 0 { i -= len(m.DepositorAddress) copy(dAtA[i:], m.DepositorAddress) i = encodeVarintTx(dAtA, i, uint64(len(m.DepositorAddress))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *MsgDepositWithinBatchResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgDepositWithinBatchResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgDepositWithinBatchResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *MsgWithdrawWithinBatch) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgWithdrawWithinBatch) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgWithdrawWithinBatch) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.PoolCoin.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintTx(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x1a if m.PoolId != 0 { i = encodeVarintTx(dAtA, i, uint64(m.PoolId)) i-- dAtA[i] = 0x10 } if len(m.WithdrawerAddress) > 0 { i -= len(m.WithdrawerAddress) copy(dAtA[i:], m.WithdrawerAddress) i = encodeVarintTx(dAtA, i, uint64(len(m.WithdrawerAddress))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *MsgWithdrawWithinBatchResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgWithdrawWithinBatchResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgWithdrawWithinBatchResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *MsgSwapWithinBatch) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgSwapWithinBatch) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgSwapWithinBatch) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size := m.OrderPrice.Size() i -= size if _, err := m.OrderPrice.MarshalTo(dAtA[i:]); err != nil { return 0, err } i = encodeVarintTx(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x3a { size, err := m.OfferCoinFee.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintTx(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x32 if len(m.DemandCoinDenom) > 0 { i -= len(m.DemandCoinDenom) copy(dAtA[i:], m.DemandCoinDenom) i = encodeVarintTx(dAtA, i, uint64(len(m.DemandCoinDenom))) i-- dAtA[i] = 0x2a } { size, err := m.OfferCoin.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintTx(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x22 if m.SwapTypeId != 0 { i = encodeVarintTx(dAtA, i, uint64(m.SwapTypeId)) i-- dAtA[i] = 0x18 } if m.PoolId != 0 { i = encodeVarintTx(dAtA, i, uint64(m.PoolId)) i-- dAtA[i] = 0x10 } if len(m.SwapRequesterAddress) > 0 { i -= len(m.SwapRequesterAddress) copy(dAtA[i:], m.SwapRequesterAddress) i = encodeVarintTx(dAtA, i, uint64(len(m.SwapRequesterAddress))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *MsgSwapWithinBatchResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgSwapWithinBatchResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgSwapWithinBatchResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func encodeVarintTx(dAtA []byte, offset int, v uint64) int { offset -= sovTx(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *MsgCreatePool) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.PoolCreatorAddress) if l > 0 { n += 1 + l + sovTx(uint64(l)) } if m.PoolTypeId != 0 { n += 1 + sovTx(uint64(m.PoolTypeId)) } if len(m.DepositCoins) > 0 { for _, e := range m.DepositCoins { l = e.Size() n += 1 + l + sovTx(uint64(l)) } } return n } func (m *MsgCreatePoolResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *MsgDepositWithinBatch) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.DepositorAddress) if l > 0 { n += 1 + l + sovTx(uint64(l)) } if m.PoolId != 0 { n += 1 + sovTx(uint64(m.PoolId)) } if len(m.DepositCoins) > 0 { for _, e := range m.DepositCoins { l = e.Size() n += 1 + l + sovTx(uint64(l)) } } return n } func (m *MsgDepositWithinBatchResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *MsgWithdrawWithinBatch) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.WithdrawerAddress) if l > 0 { n += 1 + l + sovTx(uint64(l)) } if m.PoolId != 0 { n += 1 + sovTx(uint64(m.PoolId)) } l = m.PoolCoin.Size() n += 1 + l + sovTx(uint64(l)) return n } func (m *MsgWithdrawWithinBatchResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *MsgSwapWithinBatch) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.SwapRequesterAddress) if l > 0 { n += 1 + l + sovTx(uint64(l)) } if m.PoolId != 0 { n += 1 + sovTx(uint64(m.PoolId)) } if m.SwapTypeId != 0 { n += 1 + sovTx(uint64(m.SwapTypeId)) } l = m.OfferCoin.Size() n += 1 + l + sovTx(uint64(l)) l = len(m.DemandCoinDenom) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = m.OfferCoinFee.Size() n += 1 + l + sovTx(uint64(l)) l = m.OrderPrice.Size() n += 1 + l + sovTx(uint64(l)) return n } func (m *MsgSwapWithinBatchResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func sovTx(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozTx(x uint64) (n int) { return sovTx(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *MsgCreatePool) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgCreatePool: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgCreatePool: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field PoolCreatorAddress", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.PoolCreatorAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field PoolTypeId", wireType) } m.PoolTypeId = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.PoolTypeId |= uint32(b&0x7F) << shift if b < 0x80 { break } } case 4: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field DepositCoins", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.DepositCoins = append(m.DepositCoins, types.Coin{}) if err := m.DepositCoins[len(m.DepositCoins)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgCreatePoolResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgCreatePoolResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgCreatePoolResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgDepositWithinBatch) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgDepositWithinBatch: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgDepositWithinBatch: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field DepositorAddress", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.DepositorAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field PoolId", wireType) } m.PoolId = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.PoolId |= uint64(b&0x7F) << shift if b < 0x80 { break } } case 3: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field DepositCoins", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.DepositCoins = append(m.DepositCoins, types.Coin{}) if err := m.DepositCoins[len(m.DepositCoins)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgDepositWithinBatchResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgDepositWithinBatchResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgDepositWithinBatchResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgWithdrawWithinBatch) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgWithdrawWithinBatch: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgWithdrawWithinBatch: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field WithdrawerAddress", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.WithdrawerAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field PoolId", wireType) } m.PoolId = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.PoolId |= uint64(b&0x7F) << shift if b < 0x80 { break } } case 3: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field PoolCoin", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.PoolCoin.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgWithdrawWithinBatchResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgWithdrawWithinBatchResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgWithdrawWithinBatchResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgSwapWithinBatch) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgSwapWithinBatch: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgSwapWithinBatch: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field SwapRequesterAddress", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.SwapRequesterAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field PoolId", wireType) } m.PoolId = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.PoolId |= uint64(b&0x7F) << shift if b < 0x80 { break } } case 3: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field SwapTypeId", wireType) } m.SwapTypeId = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.SwapTypeId |= uint32(b&0x7F) << shift if b < 0x80 { break } } case 4: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field OfferCoin", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.OfferCoin.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 5: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field DemandCoinDenom", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.DemandCoinDenom = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 6: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field OfferCoinFee", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.OfferCoinFee.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 7: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field OrderPrice", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.OrderPrice.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgSwapWithinBatchResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgSwapWithinBatchResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgSwapWithinBatchResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipTx(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTx } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTx } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTx } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthTx } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupTx } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthTx } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthTx = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowTx = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupTx = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/liquidity/types/utils.go ================================================ package types import ( "crypto/sha256" "fmt" "sort" "strings" "cosmossdk.io/math" "github.com/cometbft/cometbft/crypto" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/address" ) // AlphabeticalDenomPair returns denom pairs that are alphabetically sorted. func AlphabeticalDenomPair(denom1, denom2 string) (resDenom1, resDenom2 string) { if denom1 > denom2 { return denom2, denom1 } return denom1, denom2 } // SortDenoms sorts denoms in alphabetical order. func SortDenoms(denoms []string) []string { sort.Strings(denoms) return denoms } // GetPoolReserveAcc returns the address of the pool's reserve account. func GetPoolReserveAcc(poolName string, len32 bool) sdk.AccAddress { if len32 { // The rules are temporarily added for testing on 32-length bytes addresses of ADR-28 and are subject to change. poolCoinDenom := GetPoolCoinDenom(poolName) poolCoinDenom = strings.TrimPrefix(poolCoinDenom, PoolCoinDenomPrefix) return sdk.AccAddress(address.Module(ModuleName, []byte(poolCoinDenom))) } return sdk.AccAddress(crypto.AddressHash([]byte(poolName))) } // GetPoolCoinDenom returns the denomination of the pool coin. func GetPoolCoinDenom(poolName string) string { // Originally pool coin denom has prefix with / splitter, but removed prefix for pass validation of ibc-transfer return fmt.Sprintf("%s%X", PoolCoinDenomPrefix, sha256.Sum256([]byte(poolName))) } // GetReserveAcc extracts and returns reserve account from pool coin denom. func GetReserveAcc(poolCoinDenom string, len32 bool) (sdk.AccAddress, error) { if err := sdk.ValidateDenom(poolCoinDenom); err != nil { return nil, err } if !strings.HasPrefix(poolCoinDenom, PoolCoinDenomPrefix) { return nil, ErrInvalidDenom } poolCoinDenom = strings.TrimPrefix(poolCoinDenom, PoolCoinDenomPrefix) if len(poolCoinDenom) != 64 { return nil, ErrInvalidDenom } if len32 { // The rules are temporarily added for testing on 32-length bytes addresses of ADR-28 and are subject to change. return sdk.AccAddress(address.Module(ModuleName, []byte(poolCoinDenom))), nil } return sdk.AccAddressFromHexUnsafe(poolCoinDenom[:40]) } // GetCoinsTotalAmount returns total amount of all coins in sdk.Coins. func GetCoinsTotalAmount(coins sdk.Coins) math.Int { totalAmount := sdk.ZeroInt() for _, coin := range coins { totalAmount = totalAmount.Add(coin.Amount) } return totalAmount } // ValidateReserveCoinLimit checks if total amounts of depositCoins exceed maxReserveCoinAmount. func ValidateReserveCoinLimit(maxReserveCoinAmount math.Int, depositCoins sdk.Coins) error { totalAmount := GetCoinsTotalAmount(depositCoins) if maxReserveCoinAmount.IsZero() { return nil } else if totalAmount.GT(maxReserveCoinAmount) { return ErrExceededReserveCoinLimit } else { return nil } } func GetOfferCoinFee(offerCoin sdk.Coin, swapFeeRate sdk.Dec) sdk.Coin { if swapFeeRate.IsZero() { return sdk.NewCoin(offerCoin.Denom, sdk.ZeroInt()) } // apply half-ratio swap fee rate and ceiling // see https://github.com/tendermint/liquidity/issues/41 for details return sdk.NewCoin(offerCoin.Denom, sdk.NewDecFromInt(offerCoin.Amount).Mul(swapFeeRate.QuoInt64(2)).Ceil().TruncateInt()) // Ceil(offerCoin.Amount * (swapFeeRate/2)) } func MustParseCoinsNormalized(coinStr string) sdk.Coins { coins, err := sdk.ParseCoinsNormalized(coinStr) if err != nil { panic(err) } return coins } //nolint:staticcheck func CheckOverflow(a, b math.Int) (err error) { defer func() { if r := recover(); r != nil { err = ErrOverflowAmount } }() a.Mul(b) a.Quo(b) b.Quo(a) return nil } func CheckOverflowWithDec(a, b sdk.Dec) (err error) { defer func() { if r := recover(); r != nil { err = ErrOverflowAmount } }() a.Mul(b) a.Quo(b) b.Quo(a) return nil } ================================================ FILE: x/liquidity/wasm/liquidity.go ================================================ package wasm import ( "encoding/json" wasmkeeper "github.com/CosmWasm/wasmd/x/wasm/keeper" wasmvmtypes "github.com/CosmWasm/wasmvm/types" liquiditytypes "github.com/cybercongress/go-cyber/v7/x/liquidity/types" "github.com/CosmWasm/wasmd/x/wasm" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" "github.com/cybercongress/go-cyber/v7/x/liquidity/keeper" ) // TODO refactor to the new query and message handler or remove var ( // _ WasmQuerierInterface = WasmQuerier{} // _ WasmMsgParserInterface = WasmMsgParser{} ) //-------------------------------------------------- type WasmMsgParser struct{} func NewLiquidityWasmMsgParser() WasmMsgParser { return WasmMsgParser{} } func (WasmMsgParser) Parse(_ sdk.AccAddress, _ wasmvmtypes.CosmosMsg) ([]sdk.Msg, error) { return nil, nil } type CosmosMsg struct { CreatePool *liquiditytypes.MsgCreatePool `json:"create_pool,omitempty"` DepositWithinBatch *liquiditytypes.MsgDepositWithinBatch `json:"deposit_within_batch,omitempty"` WithdrawWithinBatch *liquiditytypes.MsgWithdrawWithinBatch `json:"withdraw_within_batch,omitempty"` SwapWithinBatch *liquiditytypes.MsgSwapWithinBatch `json:"swap_within_batch,omitempty"` } // Deprecated func (WasmMsgParser) ParseCustom(contractAddr sdk.AccAddress, data json.RawMessage) ([]sdk.Msg, error) { var sdkMsg CosmosMsg err := json.Unmarshal(data, &sdkMsg) if err != nil { return nil, sdkerrors.Wrap(err, "failed to parse link custom msg") } switch { case sdkMsg.SwapWithinBatch != nil: return []sdk.Msg{sdkMsg.SwapWithinBatch}, sdkMsg.SwapWithinBatch.ValidateBasic() case sdkMsg.DepositWithinBatch != nil: return []sdk.Msg{sdkMsg.DepositWithinBatch}, sdkMsg.DepositWithinBatch.ValidateBasic() case sdkMsg.WithdrawWithinBatch != nil: return []sdk.Msg{sdkMsg.WithdrawWithinBatch}, sdkMsg.WithdrawWithinBatch.ValidateBasic() case sdkMsg.CreatePool != nil: return []sdk.Msg{sdkMsg.CreatePool}, sdkMsg.CreatePool.ValidateBasic() default: return nil, sdkerrors.Wrap(wasm.ErrInvalidMsg, "Unknown variant of Liquidity") } } //-------------------------------------------------- type WasmQuerier struct { keeper.Keeper } func NewLiquidityWasmQuerier(keeper keeper.Keeper) WasmQuerier { return WasmQuerier{keeper} } func (WasmQuerier) Query(_ sdk.Context, _ wasmvmtypes.QueryRequest) ([]byte, error) { return nil, nil } type CosmosQuery struct { PoolParams *QueryPoolParams `json:"pool_params,omitempty"` PoolLiquidity *QueryPoolParams `json:"pool_liquidity,omitempty"` PoolSupply *QueryPoolParams `json:"pool_supply,omitempty"` PoolPrice *QueryPoolParams `json:"pool_price,omitempty"` PoolAddress *QueryPoolParams `json:"pool_address,omitempty"` } type QueryPoolParams struct { PoolID uint64 `json:"pool_id"` } type PoolParamsResponse struct { TypeID uint32 `json:"type_id"` ReserveCoinDenoms []string `json:"reserve_coin_denoms"` ReserveAccountAddress string `json:"reserve_account_address"` PoolCoinDenom string `json:"pool_coin_denom"` } type PoolLiquidityResponse struct { Liquidity wasmvmtypes.Coins `json:"liquidity"` } type PoolSupplyResponse struct { Supply wasmvmtypes.Coin `json:"supply"` } type PoolPriceResponse struct { Price string `json:"price"` } type PoolAddressResponse struct { Address string `json:"address"` } // Deprecated func (querier WasmQuerier) QueryCustom(ctx sdk.Context, data json.RawMessage) ([]byte, error) { var query CosmosQuery err := json.Unmarshal(data, &query) if err != nil { return nil, sdkerrors.Wrap(sdkerrors.ErrJSONUnmarshal, err.Error()) } var bz []byte switch { case query.PoolParams != nil: pool, found := querier.Keeper.GetPool(ctx, query.PoolParams.PoolID) if !found { return nil, sdkerrors.ErrInvalidRequest } bz, err = json.Marshal( PoolParamsResponse{ TypeID: pool.TypeId, ReserveCoinDenoms: pool.ReserveCoinDenoms, ReserveAccountAddress: pool.ReserveAccountAddress, PoolCoinDenom: pool.PoolCoinDenom, }, ) case query.PoolLiquidity != nil: pool, found := querier.Keeper.GetPool(ctx, query.PoolLiquidity.PoolID) if !found { return nil, sdkerrors.ErrInvalidRequest } reserveCoins := querier.Keeper.GetReserveCoins(ctx, pool) bz, err = json.Marshal( PoolLiquidityResponse{ Liquidity: wasmkeeper.ConvertSdkCoinsToWasmCoins(reserveCoins), }, ) case query.PoolSupply != nil: pool, found := querier.Keeper.GetPool(ctx, query.PoolSupply.PoolID) if !found { return nil, sdkerrors.ErrInvalidRequest } poolSupply := querier.Keeper.GetPoolCoinTotal(ctx, pool) bz, err = json.Marshal( PoolSupplyResponse{ Supply: wasmkeeper.ConvertSdkCoinToWasmCoin(poolSupply), }, ) case query.PoolPrice != nil: pool, found := querier.Keeper.GetPool(ctx, query.PoolPrice.PoolID) if !found { return nil, sdkerrors.ErrInvalidRequest } reserveCoins := querier.Keeper.GetReserveCoins(ctx, pool) X := reserveCoins[0].Amount.ToLegacyDec() Y := reserveCoins[1].Amount.ToLegacyDec() bz, err = json.Marshal( PoolPriceResponse{ Price: X.Quo(Y).String(), }, ) case query.PoolAddress != nil: pool, found := querier.Keeper.GetPool(ctx, query.PoolAddress.PoolID) if !found { return nil, sdkerrors.ErrInvalidRequest } bz, err = json.Marshal( PoolAddressResponse{ Address: pool.ReserveAccountAddress, }, ) default: return nil, wasmvmtypes.UnsupportedRequest{Kind: "unknown Liquidity variant"} } if err != nil { return nil, sdkerrors.Wrap(sdkerrors.ErrJSONMarshal, err.Error()) } return bz, nil } ================================================ FILE: x/rank/abci.go ================================================ package rank import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/rank/keeper" ) func EndBlocker(ctx sdk.Context, k *keeper.StateKeeper) { k.EndBlocker(ctx) } ================================================ FILE: x/rank/client/cli/query.go ================================================ package cli import ( "context" "strconv" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/ipfs/go-cid" "github.com/spf13/cobra" graphtypes "github.com/cybercongress/go-cyber/v7/x/graph/types" "github.com/cybercongress/go-cyber/v7/x/rank/types" ) func GetQueryCmd() *cobra.Command { queryCmd := &cobra.Command{ Use: types.ModuleName, Short: "Querying commands for the rank module", DisableFlagParsing: true, SuggestionsMinimumDistance: 2, RunE: client.ValidateCmd, } queryCmd.AddCommand( GetCmdQueryParams(), GetCmdQueryRank(), GetCmdQuerySearch(), GetCmdQueryBacklinks(), GetCmdQueryTop(), GetCmdQueryIsLinkExist(), GetCmdQueryIsAnyLinkExist(), GetCmdQueryNegentropyParticle(), GetCmdQueryNegentropy(), ) return queryCmd } func GetCmdQueryParams() *cobra.Command { cmd := &cobra.Command{ Use: "params", Short: "Query the current rank parameters", Args: cobra.NoArgs, RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientQueryContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) res, err := queryClient.Params( context.Background(), &types.QueryParamsRequest{}, ) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } func GetCmdQueryRank() *cobra.Command { cmd := &cobra.Command{ Use: "rank [particle]", Short: "Query the current rank of given particle", Args: cobra.ExactArgs(1), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientQueryContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) if _, err := cid.Decode(args[0]); err != nil { return graphtypes.ErrInvalidParticle } res, err := queryClient.Rank( context.Background(), &types.QueryRankRequest{Particle: args[0]}, ) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } func GetCmdQuerySearch() *cobra.Command { cmd := &cobra.Command{ Use: "search [particle] [page] [limit]", Short: "Query search of given particle", Args: cobra.MinimumNArgs(1), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientQueryContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) if _, err := cid.Decode(args[0]); err != nil { return graphtypes.ErrInvalidParticle } var page, limit uint32 if len(args) == 3 { p, err := strconv.ParseUint(args[1], 10, 32) if err != nil { return err } page = uint32(p) l, err := strconv.ParseUint(args[2], 10, 32) if err != nil { return err } limit = uint32(l) } else { page = 0 limit = 10 } res, err := queryClient.Search( context.Background(), &types.QuerySearchRequest{Particle: args[0], Pagination: &types.PageRequest{Page: page, PerPage: limit}}, ) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } func GetCmdQueryBacklinks() *cobra.Command { cmd := &cobra.Command{ Use: "backlinks [particle] [page] [limit]", Short: "Query backlinks of given particle", Args: cobra.MinimumNArgs(1), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientQueryContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) if _, err := cid.Decode(args[0]); err != nil { return graphtypes.ErrInvalidParticle } var page, limit uint32 if len(args) == 3 { p, err := strconv.ParseUint(args[1], 10, 32) if err != nil { return err } page = uint32(p) l, err := strconv.ParseUint(args[2], 10, 32) if err != nil { return err } limit = uint32(l) } else { page = 0 limit = 10 } res, err := queryClient.Backlinks( context.Background(), &types.QuerySearchRequest{Particle: args[0], Pagination: &types.PageRequest{Page: page, PerPage: limit}}, ) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } func GetCmdQueryTop() *cobra.Command { cmd := &cobra.Command{ Use: "top", Short: "Query top", Args: cobra.MinimumNArgs(0), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientQueryContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) var page, limit uint32 if len(args) == 2 { p, err := strconv.ParseUint(args[1], 10, 32) if err != nil { return err } page = uint32(p) l, err := strconv.ParseUint(args[2], 10, 32) if err != nil { return err } limit = uint32(l) } else { page = 0 limit = 10 } res, err := queryClient.Top( context.Background(), &types.QueryTopRequest{ Pagination: &types.PageRequest{Page: page, PerPage: limit}, }, ) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } func GetCmdQueryIsLinkExist() *cobra.Command { cmd := &cobra.Command{ Use: "is-exist [from] [to] [account]", Short: "Query is link exist between particles for given account", Args: cobra.ExactArgs(3), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientQueryContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) if _, err := cid.Decode(args[0]); err != nil { return graphtypes.ErrInvalidParticle } if _, err := cid.Decode(args[1]); err != nil { return graphtypes.ErrInvalidParticle } address, err := sdk.AccAddressFromBech32(args[2]) if err != nil { return err } res, err := queryClient.IsLinkExist( context.Background(), &types.QueryIsLinkExistRequest{From: args[0], To: args[1], Address: address.String()}, ) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } func GetCmdQueryIsAnyLinkExist() *cobra.Command { cmd := &cobra.Command{ Use: "is-exist-any [from] [to]", Short: "Query is any link exist between particles", Args: cobra.ExactArgs(2), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientQueryContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) if _, err := cid.Decode(args[0]); err != nil { return graphtypes.ErrInvalidParticle } if _, err := cid.Decode(args[1]); err != nil { return graphtypes.ErrInvalidParticle } res, err := queryClient.IsAnyLinkExist( context.Background(), &types.QueryIsAnyLinkExistRequest{From: args[0], To: args[1]}, ) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } func GetCmdQueryNegentropyParticle() *cobra.Command { cmd := &cobra.Command{ Use: "negentropy [particle]", Short: "Query focus entropy contribution of a particle: -pi*log2(pi)", Args: cobra.ExactArgs(1), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientQueryContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) if _, err := cid.Decode(args[0]); err != nil { return graphtypes.ErrInvalidParticle } res, err := queryClient.ParticleNegentropy( context.Background(), &types.QueryNegentropyPartilceRequest{Particle: args[0]}, ) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } func GetCmdQueryNegentropy() *cobra.Command { cmd := &cobra.Command{ Use: "negentropy-total", Short: "Query system-wide negentropy: J(pi) = log2(n) - H(pi)", Args: cobra.NoArgs, RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientQueryContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) res, err := queryClient.Negentropy( context.Background(), &types.QueryNegentropyRequest{}, ) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } ================================================ FILE: x/rank/cuda/Makefile ================================================ # NVCC is path to nvcc. Here it is assumed /usr/local/cuda is on one's PATH. NVCC = nvcc BUILD_DIR = build NVCCFLAGS = -fmad=false --compiler-options '-fPIC -frounding-math -fsignaling-nans' all: build build: build_dir build_gpu install_gpu build_dir: mkdir -p $(BUILD_DIR) build_gpu: $(NVCC) $(NVCCFLAGS) -o $(BUILD_DIR)/libcbdrank.so -shared ./rank.cu install_gpu: cp $(BUILD_DIR)/libcbdrank.so /usr/lib cp ./cbdrank.h /usr/lib clean: rm $(BUILD_DIR) ================================================ FILE: x/rank/cuda/cbdrank.h ================================================ #include void calculate_rank( uint64_t *stakes, uint64_t stakesSize, /* user stakes and corresponding array size */ uint64_t cidsSize, uint64_t linksSize, /* cids and links array size */ uint32_t *inLinksCount, uint32_t *outLinksCount, /* array index - cid index*/ uint64_t *inLinksOuts, uint64_t *outLinksIns, uint64_t *inLinksUsers, /*all incoming links from all users*/ uint64_t *outLinksUsers, /*all outgoing links from all users*/ double dampingFactor, /* value of damping factor*/ double tolerance, /* value of needed tolerance */ double *rank /* array index - cid index*/ ); ================================================ FILE: x/rank/cuda/rank.cu ================================================ #include #include #include #include #include #include #include #include "types.h" const int CUDA_THREAD_BLOCK_SIZE = 256; /*****************************************************/ /* KERNEL: RUN SINGLE RANK ITERATION */ /*****************************************************/ /* All in links used here are compressed in links */ /*****************************************************/ __global__ void run_rank_iteration( CompressedInLink *inLinks, /* all compressed in links */ double *prevRank, double *rank, uint64_t rankSize, /* array index - cid index */ uint64_t *inLinksStartIndex, uint32_t *inLinksCount, /* array index - cid index */ double defaultRankWithCorrection, /* default rank + inner product correction */ double dampingFactor ) { int index = blockIdx.x * blockDim.x + threadIdx.x; uint64_t stride = blockDim.x * gridDim.x; for (uint64_t i = index; i < rankSize; i += stride) { if(inLinksCount[i] == 0) { continue; } double ksum = 0; for (uint64_t j = inLinksStartIndex[i]; j < inLinksStartIndex[i] + inLinksCount[i]; j++) { if (inLinks[j].weight == 0) {continue;} ksum = prevRank[inLinks[j].fromIndex] * inLinks[j].weight + ksum; } rank[i] = ksum * dampingFactor + defaultRankWithCorrection; } } /*****************************************************/ /* KERNEL: DOUBLE ABS FUNCTOR */ /*****************************************************/ /* Return absolute value for double */ /*****************************************************/ struct absolute_value { __device__ double operator()(const double &x) const { return x < 0.0 ? -x : x; } }; /*****************************************************/ /* HOST: FINDS MAXIMUM RANKS DIFFERENCE */ /*****************************************************/ /* Finds maximum rank difference for single element */ /* */ /*****************************************************/ double find_max_ranks_diff(double *prevRank, double *newRank, uint64_t rankSize) { thrust::device_vector ranksDiff(rankSize); thrust::device_ptr newRankBegin(newRank); thrust::device_ptr prevRankBegin(prevRank); thrust::device_ptr prevRankEnd(prevRank + rankSize); thrust::transform(thrust::device, prevRankBegin, prevRankEnd, newRankBegin, ranksDiff.begin(), thrust::minus() ); return thrust::transform_reduce(thrust::device, ranksDiff.begin(), ranksDiff.end(), absolute_value(), 0.0, thrust::maximum() ); } /*******************************************************/ /* KERNEL: CALCULATE PARTICLE STAKE BY IN OR OUT LINKS */ /*******************************************************/ __global__ void get_particle_stake_by_links( uint64_t cidsSize, uint64_t *stakes, /*array index - user index*/ uint64_t *linksStartIndex, uint32_t *linksCount, /*array index - cid index*/ uint64_t *linksUsers, /*all links from all users*/ /*returns*/ uint64_t *cidsTotalOutStakes /*array index - cid index*/ ) { int index = blockIdx.x * blockDim.x + threadIdx.x; uint64_t stride = blockDim.x * gridDim.x; for (uint64_t i = index; i < cidsSize; i += stride) { uint64_t totalOutStake = 0; for (uint64_t j = linksStartIndex[i]; j < linksStartIndex[i] + linksCount[i]; j++) { totalOutStake = __dadd_rn(totalOutStake, stakes[linksUsers[j]]); } cidsTotalOutStakes[i] = totalOutStake; } } /*********************************************************/ /* DEVICE: USER TO DIVIDE TWO uint64 */ /*********************************************************/ __device__ __forceinline__ double ddiv_rn(uint64_t *a, uint64_t *b) { return __ddiv_rn(__ull2double_rn(*a), __ull2double_rn(*b)); } /*********************************************************/ /* KERNEL: CALCULATE COMPRESSED IN LINKS COUNT FOR CIDS */ /*********************************************************/ __global__ void get_compressed_in_links_count( uint64_t cidsSize, uint64_t *inLinksStartIndex, uint32_t *inLinksCount, /*array index - cid index*/ uint64_t *inLinksOuts, /*all incoming links from all users*/ /*returns*/ uint32_t *compressedInLinksCount /*array index - cid index*/ ) { int index = blockIdx.x * blockDim.x + threadIdx.x; uint64_t stride = blockDim.x * gridDim.x; for (uint64_t i = index; i < cidsSize; i += stride) { if(inLinksCount[i] == 0) { compressedInLinksCount[i]=0; continue; } uint32_t compressedLinksCount = 0; for(uint64_t j = inLinksStartIndex[i]; j < inLinksStartIndex[i]+inLinksCount[i]; j++) { if(j == inLinksStartIndex[i] || inLinksOuts[j] != inLinksOuts[j-1]) { compressedLinksCount++; } } compressedInLinksCount[i] = compressedLinksCount; } } /*********************************************************/ /* KERNEL: CALCULATE COMPRESSED IN LINKS */ /*********************************************************/ __global__ void get_compressed_in_links( uint64_t cidsSize, uint64_t *inLinksStartIndex, uint32_t *inLinksCount, uint64_t *cidsTotalOutStakes, /*array index - cid index*/ uint64_t *inLinksOuts, uint64_t *inLinksUsers, /*all incoming links from all users*/ uint64_t *stakes, /*array index - user index*/ uint64_t *compressedInLinksStartIndex, uint32_t *compressedInLinksCount, /*array index - cid index*/ /*returns*/ CompressedInLink *compressedInLinks /*all incoming compressed links*/ ) { int index = blockIdx.x * blockDim.x + threadIdx.x; uint64_t stride = blockDim.x * gridDim.x; for (uint64_t i = index; i < cidsSize; i += stride) { if(inLinksCount[i] == 0) { continue; } uint32_t compressedLinksIndex = compressedInLinksStartIndex[i]; if(inLinksCount[i] == 1) { uint64_t oppositeCid = inLinksOuts[inLinksStartIndex[i]]; uint64_t compressedLinkStake = stakes[inLinksUsers[inLinksStartIndex[i]]]; double weight = ddiv_rn(&compressedLinkStake, &cidsTotalOutStakes[oppositeCid]); if (isnan(weight)) { weight = 0; } compressedInLinks[compressedLinksIndex] = CompressedInLink {oppositeCid, weight}; continue; } uint64_t compressedLinkStake = 0; uint64_t lastLinkIndex = inLinksStartIndex[i] + inLinksCount[i] - 1; for(uint64_t j = inLinksStartIndex[i]; j < lastLinkIndex + 1; j++) { compressedLinkStake += stakes[inLinksUsers[j]]; if(j == lastLinkIndex || inLinksOuts[j] != inLinksOuts[j+1]) { uint64_t oppositeCid = inLinksOuts[j]; double weight = ddiv_rn(&compressedLinkStake, &cidsTotalOutStakes[oppositeCid]); if (isnan(weight)) { weight = 0; } compressedInLinks[compressedLinksIndex] = CompressedInLink {oppositeCid, weight}; compressedLinksIndex++; compressedLinkStake=0; } } } } /************************************************************/ /* HOST: CALCULATE COMPRESSED IN LINKS START INDEXES */ /************************************************************/ /* SEQUENTIAL LOGIC -> CALCULATE ON CPU */ /* RETURNS TOTAL COMPRESSED LINKS SIZE */ /************************************************************/ __host__ uint64_t get_links_start_index( uint64_t cidsSize, uint32_t *linksCount, /*array index - cid index*/ /*returns*/ uint64_t *linksStartIndex /*array index - cid index*/ ) { uint64_t index = 0; for (uint64_t i = 0; i < cidsSize; i++) { linksStartIndex[i] = index; index += linksCount[i]; } return index; } void swap(double* &a, double* &b){ double *temp = a; a = b; b = temp; } extern "C" { void calculate_rank( uint64_t *stakes, uint64_t stakesSize, /* User stakes and corresponding array size */ uint64_t cidsSize, uint64_t linksSize, /* Cids count */ uint32_t *inLinksCount, uint32_t *outLinksCount, /* array index - cid index*/ uint64_t *inLinksOuts, uint64_t *outLinksIns, uint64_t *inLinksUsers, /*all incoming links from all users*/ uint64_t *outLinksUsers, /*all outgoing links from all users*/ double dampingFactor, /* value of damping factor*/ double tolerance, /* value of needed tolerance */ double *rank /* array index - cid index*/ ) { int CUDA_BLOCKS_NUMBER = (cidsSize + CUDA_THREAD_BLOCK_SIZE - 1) / CUDA_THREAD_BLOCK_SIZE; // STEP0: Calculate compressed in/out links start indexes /*-------------------------------------------------------------------*/ uint64_t *inLinksStartIndex = (uint64_t*) malloc(cidsSize*sizeof(uint64_t)); uint64_t *outLinksStartIndex = (uint64_t*) malloc(cidsSize*sizeof(uint64_t)); get_links_start_index(cidsSize, inLinksCount, inLinksStartIndex); get_links_start_index(cidsSize, outLinksCount, outLinksStartIndex); /*-------------------------------------------------------------------*/ // STEP1: Calculate for each particle stake by OUT cyberlinks /*-------------------------------------------------------------------*/ uint64_t *d_outLinksStartIndex; uint32_t *d_outLinksCount; uint64_t *d_outLinksUsers; uint64_t *d_stakes; uint64_t *d_cidsTotalOutStakes; cudaMalloc(&d_outLinksStartIndex, cidsSize*sizeof(uint64_t)); cudaMalloc(&d_outLinksCount, cidsSize*sizeof(uint32_t)); cudaMalloc(&d_outLinksUsers, linksSize*sizeof(uint64_t)); cudaMalloc(&d_stakes, stakesSize*sizeof(uint64_t)); cudaMalloc(&d_cidsTotalOutStakes, cidsSize*sizeof(uint64_t)); cudaMemcpy(d_outLinksStartIndex, outLinksStartIndex, cidsSize*sizeof(uint64_t), cudaMemcpyHostToDevice); cudaMemcpy(d_outLinksCount, outLinksCount, cidsSize*sizeof(uint32_t), cudaMemcpyHostToDevice); cudaMemcpy(d_outLinksUsers, outLinksUsers, linksSize*sizeof(uint64_t), cudaMemcpyHostToDevice); cudaMemcpy(d_stakes, stakes, stakesSize*sizeof(uint64_t), cudaMemcpyHostToDevice); get_particle_stake_by_links<<>>( cidsSize, d_stakes, d_outLinksStartIndex, d_outLinksCount, d_outLinksUsers, d_cidsTotalOutStakes ); cudaFree(d_outLinksStartIndex); cudaFree(d_outLinksCount); cudaFree(d_outLinksUsers); /*-------------------------------------------------------------------*/ // STEP2: Calculate compressed in links count /*-------------------------------------------------------------------*/ uint64_t *d_inLinksStartIndex; uint32_t *d_inLinksCount; uint64_t *d_inLinksOuts; uint32_t *d_compressedInLinksCount; cudaMalloc(&d_inLinksStartIndex, cidsSize*sizeof(uint64_t)); cudaMalloc(&d_inLinksCount, cidsSize*sizeof(uint32_t)); cudaMalloc(&d_inLinksOuts, linksSize*sizeof(uint64_t)); cudaMalloc(&d_compressedInLinksCount, cidsSize*sizeof(uint32_t)); cudaMemcpy(d_inLinksStartIndex, inLinksStartIndex, cidsSize*sizeof(uint64_t), cudaMemcpyHostToDevice); cudaMemcpy(d_inLinksCount, inLinksCount, cidsSize*sizeof(uint32_t), cudaMemcpyHostToDevice); cudaMemcpy(d_inLinksOuts, inLinksOuts, linksSize*sizeof(uint64_t), cudaMemcpyHostToDevice); get_compressed_in_links_count<<>>( cidsSize, d_inLinksStartIndex, d_inLinksCount, d_inLinksOuts, d_compressedInLinksCount ); /*-------------------------------------------------------------------*/ // STEP3: Calculate compressed in links start indexes /*-------------------------------------------------------------------*/ uint32_t *compressedInLinksCount = (uint32_t*) malloc(cidsSize*sizeof(uint32_t)); uint64_t *compressedInLinksStartIndex = (uint64_t*) malloc(cidsSize*sizeof(uint64_t)); cudaMemcpy(compressedInLinksCount, d_compressedInLinksCount, cidsSize * sizeof(uint32_t), cudaMemcpyDeviceToHost); uint64_t compressedInLinksSize = get_links_start_index( cidsSize, compressedInLinksCount, compressedInLinksStartIndex ); uint64_t *d_compressedInLinksStartIndex; cudaMalloc(&d_compressedInLinksStartIndex, cidsSize*sizeof(uint64_t)); cudaMemcpy(d_compressedInLinksStartIndex, compressedInLinksStartIndex, cidsSize*sizeof(uint64_t), cudaMemcpyHostToDevice); free(compressedInLinksStartIndex); /*-------------------------------------------------------------------*/ // STEP4: Calculate compressed in links /*-------------------------------------------------------------------*/ uint64_t *d_inLinksUsers; cudaMalloc(&d_inLinksUsers, linksSize*sizeof(uint64_t)); cudaMemcpy(d_inLinksUsers, inLinksUsers, linksSize*sizeof(uint64_t), cudaMemcpyHostToDevice); CompressedInLink *d_compressedInLinks; cudaMalloc(&d_compressedInLinks, compressedInLinksSize*sizeof(CompressedInLink)); get_compressed_in_links<<>>( cidsSize, d_inLinksStartIndex, d_inLinksCount, d_cidsTotalOutStakes, d_inLinksOuts, d_inLinksUsers, d_stakes, d_compressedInLinksStartIndex, d_compressedInLinksCount, d_compressedInLinks ); cudaFree(d_inLinksStartIndex); cudaFree(d_inLinksCount); cudaFree(d_inLinksUsers); cudaFree(d_inLinksOuts); cudaFree(d_stakes); cudaFree(d_cidsTotalOutStakes); /*-------------------------------------------------------------------*/ // STEP5: Calculate dangling nodes rank, and default rank /*-------------------------------------------------------------------*/ double defaultRank = (1.0 - dampingFactor) / cidsSize; uint64_t danglingNodesSize = 0; for(uint64_t i=0; i< cidsSize; i++){ rank[i] = defaultRank; if(inLinksCount[i] == 0) { danglingNodesSize++; } } double innerProductOverSize = defaultRank * ((double) danglingNodesSize / (double)cidsSize); double defaultRankWithCorrection = (dampingFactor * innerProductOverSize) + defaultRank; /*-------------------------------------------------------------------*/ // STEP6: Calculate Rank /*-------------------------------------------------------------------*/ double *d_rank, *d_prevRank; cudaMalloc(&d_rank, cidsSize*sizeof(double)); cudaMalloc(&d_prevRank, cidsSize*sizeof(double)); cudaMemcpy(d_rank, rank, cidsSize*sizeof(double), cudaMemcpyHostToDevice); cudaMemcpy(d_prevRank, rank, cidsSize*sizeof(double), cudaMemcpyHostToDevice); int steps = 0; double change = tolerance + 1.0; while(change > tolerance) { swap(d_rank, d_prevRank); steps++; run_rank_iteration<<>>( d_compressedInLinks, d_prevRank, d_rank, cidsSize, d_compressedInLinksStartIndex, d_compressedInLinksCount, defaultRankWithCorrection, dampingFactor ); change = find_max_ranks_diff(d_prevRank, d_rank, cidsSize); cudaDeviceSynchronize(); } cudaMemcpy(rank, d_rank, cidsSize * sizeof(double), cudaMemcpyDeviceToHost); cudaFree(d_prevRank); cudaFree(d_rank); cudaFree(d_compressedInLinksStartIndex); cudaFree(d_compressedInLinksCount); cudaFree(d_compressedInLinks); /*-------------------------------------------------------------------*/ free(inLinksStartIndex); free(outLinksStartIndex); free(compressedInLinksCount); } }; ================================================ FILE: x/rank/cuda/test_rank.cu ================================================ #include "rank.cu" #include void test_getCompressedInLinksStartIndex() { uint32_t compressedInLinksCount [6] = { 0, 2, 0, 40, 13, 0 }; uint64_t compressedInLinksStartIndex [6] = { }; uint64_t size = get_links_start_index(6, compressedInLinksCount, compressedInLinksStartIndex); if (size != 55) { printf("getCompressedInLinksStartIndex() wrong composed in links size!\n"); } uint64_t expected [6] = {0,0,2,2,42,55}; if (std::equal(std::begin(expected), std::end(expected), std::begin(compressedInLinksStartIndex))) printf("getCompressedInLinksStartIndex() works as expected!\n"); else { printf("getCompressedInLinksStartIndex() doesn't works :(\n"); for (int i = sizeof(expected) / sizeof(expected[0])-1; i >= 0; i--) std::cout << compressedInLinksStartIndex[i] << ' ' << expected[i] << '\n'; } } void test_getCompressedInLinksCount() { uint64_t cidsSize = 6; uint32_t inLinksCount [6] = { 0, 2, 0, 1, 3, 3 }; uint64_t inLinksStartIndex [6] = { 0, 0, 2, 2, 3, 6 }; uint64_t inLinksOuts [] = { 1, 1, 2, 2, 2, 1, 2, 1, 1}; int outSize = (sizeof(inLinksOuts)/sizeof(*inLinksOuts)); uint32_t *dev_inLinksCount; uint32_t *dev_compressedInLinksCount; uint64_t *dev_inLinksStartIndex; uint64_t *dev_inLinksOuts; cudaMalloc(&dev_inLinksCount, cidsSize*sizeof(uint32_t)); cudaMalloc(&dev_compressedInLinksCount, cidsSize*sizeof(uint32_t)); cudaMalloc(&dev_inLinksStartIndex, cidsSize*sizeof(uint64_t)); cudaMalloc(&dev_inLinksOuts, outSize*sizeof(uint64_t)); cudaMemcpy(dev_inLinksCount, inLinksCount, cidsSize*sizeof(uint32_t), cudaMemcpyHostToDevice); cudaMemcpy(dev_inLinksStartIndex, inLinksStartIndex, cidsSize*sizeof(uint64_t), cudaMemcpyHostToDevice); cudaMemcpy(dev_inLinksOuts, inLinksOuts, outSize*sizeof(uint64_t), cudaMemcpyHostToDevice); cudaDeviceSynchronize(); get_compressed_in_links_count<<<2,3>>>( cidsSize, dev_inLinksStartIndex, dev_inLinksCount, dev_inLinksOuts, dev_compressedInLinksCount ); cudaDeviceSynchronize(); uint32_t actual[6] = {}; cudaMemcpy(actual, dev_compressedInLinksCount, cidsSize*sizeof(uint32_t), cudaMemcpyDeviceToHost); uint64_t expected[6] = {0,1,0,1,2,2}; if (std::equal(std::begin(expected), std::end(expected), std::begin(actual))) printf("getCompressedInLinksCount() works as expected!\n"); else { printf("getCompressedInLinksCount() doesn't works :(\n"); for (int i = sizeof(actual) / sizeof(actual[0])-1; i >= 0; i--) std::cout << actual[i] << ' ' << expected[i] << '\n'; } } void test_calculateCidTotalOutStake() { int cidsSize = 6; int linksSize = 9; int usersSize = 3; uint32_t outLinksCount [6] = { 0, 2, 0, 1, 3, 3 }; uint64_t outLinksStartIndex [6] = { 0, 0, 2, 2, 3, 6 }; uint64_t outLinksUsers [9] = { 1, 0, 2, 0, 2, 1, 2, 1, 0}; uint64_t stakes [3] = { 1, 2, 3}; uint32_t *dev_outLinksCount; uint64_t *dev_outLinksStartIndex; uint64_t *dev_outLinksUsers; uint64_t *dev_stakes; uint64_t *dev_cidsTotalOutStakes; cudaMalloc(&dev_outLinksCount, cidsSize*sizeof(uint32_t)); cudaMalloc(&dev_outLinksStartIndex, cidsSize*sizeof(uint64_t)); cudaMalloc(&dev_outLinksUsers, linksSize*sizeof(uint64_t)); cudaMalloc(&dev_stakes, usersSize*sizeof(uint64_t)); cudaMalloc(&dev_cidsTotalOutStakes, cidsSize*sizeof(uint64_t)); cudaMemcpy(dev_outLinksCount, outLinksCount, cidsSize*sizeof(uint32_t), cudaMemcpyHostToDevice); cudaMemcpy(dev_outLinksStartIndex, outLinksStartIndex, cidsSize*sizeof(uint64_t), cudaMemcpyHostToDevice); cudaMemcpy(dev_outLinksUsers, outLinksUsers, linksSize*sizeof(uint64_t), cudaMemcpyHostToDevice); cudaMemcpy(dev_stakes, stakes, usersSize*sizeof(uint64_t), cudaMemcpyHostToDevice); cudaDeviceSynchronize(); get_particle_stake_by_links<<<2,3>>>( cidsSize, dev_stakes, dev_outLinksStartIndex, dev_outLinksCount, dev_outLinksUsers, dev_cidsTotalOutStakes ); cudaDeviceSynchronize(); uint64_t actual[6] = {}; cudaMemcpy(actual, dev_cidsTotalOutStakes, cidsSize*sizeof(uint64_t), cudaMemcpyDeviceToHost); uint64_t expected[6] = {0,3,0,3,6,6}; if (std::equal(std::begin(expected), std::end(expected), std::begin(actual))) printf("calculateCidTotalOutStake() works as expected!\n"); else { printf("calculateCidTotalOutStake() doesn't works :(\n"); for (int i = sizeof(actual) / sizeof(actual[0])-1; i >= 0; i--) std::cout << actual[i] << ' ' << expected[i] << '\n'; } } void test_find_max_ranks_diff() { double prevRank [6] = { -1.324, 32.1, 0.001, 2.231, -3.22, -0.02 }; double newRank [6] = {1.3242, 32.22, 0.032, 2.231, -3.232, 0.02 }; double *dev_prevRank; double *dev_newRank; cudaMalloc(&dev_prevRank, 6*sizeof(double)); cudaMalloc(&dev_newRank, 6*sizeof(double)); cudaMemcpy(dev_prevRank, prevRank, 6*sizeof(double), cudaMemcpyHostToDevice); cudaMemcpy(dev_newRank, newRank, 6*sizeof(double), cudaMemcpyHostToDevice); double maxDiff = find_max_ranks_diff(dev_prevRank, dev_newRank, 6); if (maxDiff == 2.6482) printf("find_max_ranks_diff() works as expected!\n"); else { printf("find_max_ranks_diff() doesn't works :(\n"); std::cout << maxDiff << ' ' << 2.6482 << '\n'; } } void test_getCompressedInLinks() { int cidsSize = 8; int linksSize = 11; int compressedLinksSize = 8; int usersSize = 3; uint32_t inLinksCount [8] = {0,0,1,5,4,0,1,0}; uint32_t compressedInLinksCount [8] = {0,0,1,3,3,0,1,0}; uint64_t inLinksStartIndex [8] = {0,0,0,1,6,10,10,11}; uint64_t compressedInLinksStartIndex [8] = {0,0,0,1,4,7,7,8}; uint64_t cidsTotalOutStakes [8] = {3,3,3,1,6,1,0,3}; uint64_t inLinksOuts [11] = {7,1,4,4,4,2,5,0,0,1,3}; uint64_t inLinksUsers [11] = {0,2,0,1,2,0,1,1,2,1,1}; uint64_t stakes [3] = {3,1,2}; uint64_t *dev_inLinksStartIndex; uint32_t *dev_inLinksCount; uint64_t *dev_cidsTotalOutStakes; uint64_t *dev_inLinksOuts; uint64_t *dev_inLinksUsers; uint64_t *dev_stakes; uint64_t *dev_compressedInLinksStartIndex; uint32_t *dev_compressedInLinksCount; CompressedInLink *dev_compressedInLinks; cudaMalloc(&dev_inLinksStartIndex, cidsSize*sizeof(uint64_t)); cudaMalloc(&dev_inLinksCount, cidsSize*sizeof(uint32_t)); cudaMalloc(&dev_cidsTotalOutStakes, cidsSize*sizeof(uint64_t)); cudaMalloc(&dev_inLinksOuts, linksSize*sizeof(uint64_t)); cudaMalloc(&dev_inLinksUsers, linksSize*sizeof(uint64_t)); cudaMalloc(&dev_stakes, usersSize*sizeof(uint64_t)); cudaMalloc(&dev_compressedInLinksStartIndex, cidsSize*sizeof(uint64_t)); cudaMalloc(&dev_compressedInLinksCount, cidsSize*sizeof(uint32_t)); cudaMalloc(&dev_compressedInLinks, compressedLinksSize*sizeof(CompressedInLink)); cudaMemcpy(dev_inLinksStartIndex, inLinksStartIndex, cidsSize*sizeof(uint64_t), cudaMemcpyHostToDevice); cudaMemcpy(dev_inLinksCount, inLinksCount, cidsSize*sizeof(uint32_t), cudaMemcpyHostToDevice); cudaMemcpy(dev_cidsTotalOutStakes, cidsTotalOutStakes, cidsSize*sizeof(uint64_t), cudaMemcpyHostToDevice); cudaMemcpy(dev_inLinksOuts, inLinksOuts, linksSize*sizeof(uint64_t), cudaMemcpyHostToDevice); cudaMemcpy(dev_inLinksUsers, inLinksUsers, linksSize*sizeof(uint64_t), cudaMemcpyHostToDevice); cudaMemcpy(dev_stakes, stakes, usersSize*sizeof(uint64_t), cudaMemcpyHostToDevice); cudaMemcpy(dev_compressedInLinksStartIndex, compressedInLinksStartIndex, cidsSize*sizeof(uint64_t), cudaMemcpyHostToDevice); cudaMemcpy(dev_compressedInLinksCount, compressedInLinksCount, cidsSize*sizeof(uint32_t), cudaMemcpyHostToDevice); cudaDeviceSynchronize(); get_compressed_in_links<<<4,2>>>( cidsSize, dev_inLinksStartIndex, dev_inLinksCount, dev_cidsTotalOutStakes, dev_inLinksOuts, dev_inLinksUsers, dev_stakes, dev_compressedInLinksStartIndex, compressedInLinksCount, dev_compressedInLinks ); cudaDeviceSynchronize(); CompressedInLink actual[8] = {}; cudaMemcpy(actual, dev_compressedInLinks, compressedLinksSize*sizeof(CompressedInLink), cudaMemcpyDeviceToHost); CompressedInLink expected[8] = { {7,1.0},{1,0.666667},{4,1},{2,1},{5,1},{0,1},{1,0.333333},{3,1} }; printf("calculateCidTotalOutStake() output\n"); for (int i = sizeof(actual) / sizeof(actual[0])-1; i >= 0; i--) { std::cout << actual[i].fromIndex <<'_'<< actual[i].weight << " "; std::cout << expected[i].fromIndex <<'_'<< expected[i].weight << '\n'; } } // To run use `nvcc test_rank.cu -o test && ./test && rm test` command. int main(void) { printf("Start testing !!!!!!!!!!!!!!!!!!\n"); test_getCompressedInLinksStartIndex(); test_getCompressedInLinksCount(); test_calculateCidTotalOutStake(); test_find_max_ranks_diff(); test_getCompressedInLinks(); } ================================================ FILE: x/rank/cuda/types.h ================================================ #ifndef TYPES_HEADER_FILE #define TYPES_HEADER_FILE #include /*******************************************/ /* REPRESENTS INCOMING LINK WITH IT WEIGHT */ /*******************************************/ /* Finds maximum rank difference for single element */ /* */ /*****************************************************/ typedef struct { /* Index of opposite cid in cids array */ uint64_t fromIndex; /* Index of user stake in stakes array */ double weight; } CompressedInLink; #endif ================================================ FILE: x/rank/exported/exported.go ================================================ package exported import ( sdk "github.com/cosmos/cosmos-sdk/types" paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" ) type ( ParamSet = paramtypes.ParamSet // Subspace defines an interface that implements the legacy x/params Subspace // type. // // NOTE: This is used solely for migration of x/params managed parameters. Subspace interface { GetParamSet(ctx sdk.Context, ps ParamSet) } ) ================================================ FILE: x/rank/keeper/calculate.go ================================================ package keeper import ( "fmt" "runtime/debug" "time" "github.com/cosmos/cosmos-sdk/telemetry" "github.com/cybercongress/go-cyber/v7/x/rank/types" "github.com/cometbft/cometbft/libs/log" ) func CalculateRank(ctx *types.CalculationContext, unit types.ComputeUnit, mock bool, logger log.Logger) (rank types.Rank) { defer telemetry.ModuleMeasureSince(types.ModuleName, time.Now(), "rank_calculation") if mock { rank = types.NewRank(mockRank(ctx), logger, ctx.FullTree) return } start := time.Now() if unit == types.CPU { // used only for development rank = types.NewRank(calculateRankCPU(ctx), logger, ctx.FullTree) } else { rank = types.NewRank(calculateRankGPU(ctx, logger), logger, ctx.FullTree) } diff := time.Since(start) logger.Info( "cyber~Rank calculated", "duration", diff.String(), "cyberlinks", ctx.LinksCount, "particles", ctx.CidsCount, ) return } func CalculateRankInParallel( ctx *types.CalculationContext, rankChan chan types.Rank, err chan error, unit types.ComputeUnit, mock bool, logger log.Logger, ) { defer func() { if r := recover(); r != nil { fmt.Println("trace from panic: \n" + string(debug.Stack())) err <- r.(error) } }() rank := CalculateRank(ctx, unit, mock, logger) rankChan <- rank } ================================================ FILE: x/rank/keeper/calculate_cpu.go ================================================ package keeper import ( graphtypes "github.com/cybercongress/go-cyber/v7/x/graph/types" "github.com/cybercongress/go-cyber/v7/x/rank/types" ) func calculateRankCPU(ctx *types.CalculationContext) types.EMState { inLinks := ctx.GetInLinks() tolerance := ctx.GetTolerance() dampingFactor := ctx.GetDampingFactor() size := ctx.GetCidsCount() if size == 0 || len(ctx.GetStakes()) == 0 { return types.EMState{ RankValues: []float64{}, } } rank := make([]float64, size) defaultRank := (1.0 - dampingFactor) / float64(size) danglingNodesSize := uint64(0) for i := range rank { rank[i] = defaultRank if len(inLinks[graphtypes.CidNumber(i)]) == 0 { danglingNodesSize++ } } innerProductOverSize := defaultRank * (float64(danglingNodesSize) / float64(size)) defaultRankWithCorrection := dampingFactor*innerProductOverSize + defaultRank change := tolerance + 1 steps := 0 prevrank := make([]float64, 0) prevrank = append(prevrank, rank...) for change > tolerance { rank = step(ctx, defaultRankWithCorrection, dampingFactor, prevrank) change = calculateChange(prevrank, rank) prevrank = rank steps++ } return types.EMState{ RankValues: rank, } } func step(ctx *types.CalculationContext, defaultRankWithCorrection float64, dampingFactor float64, prevrank []float64) []float64 { rank := append(make([]float64, 0, len(prevrank)), prevrank...) for cid := range ctx.GetInLinks() { _, sortedCids, ok := ctx.GetSortedInLinks(cid) if !ok { continue } else { ksum := float64(0) for _, j := range sortedCids { linkStake := getOverallLinkStake(ctx, j, cid) jCidOutStake := getOverallOutLinksStake(ctx, j) if linkStake == 0 || jCidOutStake == 0 { continue } weight := float64(linkStake) / float64(jCidOutStake) ksum = prevrank[j]*weight + ksum // force no-fma here by explicit conversion } rank[cid] = ksum*dampingFactor + defaultRankWithCorrection // force no-fma here by explicit conversion } } return rank } func getOverallLinkStake(ctx *types.CalculationContext, from graphtypes.CidNumber, to graphtypes.CidNumber) uint64 { stake := uint64(0) users := ctx.GetOutLinks()[from][to] for user := range users { stake += getNormalizedStake(ctx, uint64(user)) } return stake } func getOverallOutLinksStake(ctx *types.CalculationContext, from graphtypes.CidNumber) uint64 { stake := uint64(0) for to := range ctx.GetOutLinks()[from] { stake += getOverallLinkStake(ctx, from, to) } return stake } func getNormalizedStake(ctx *types.CalculationContext, agent uint64) uint64 { return ctx.GetStakes()[agent] / ctx.GetNeudegs()[agent] } func calculateChange(prevrank, rank []float64) float64 { maxDiff := 0.0 diff := 0.0 for i, pForI := range prevrank { if pForI > rank[i] { diff = pForI - rank[i] } else { diff = rank[i] - pForI } if diff > maxDiff { maxDiff = diff } } return maxDiff } ================================================ FILE: x/rank/keeper/calculate_gpu.go ================================================ //go:build cuda // +build cuda package keeper import ( "time" "github.com/cometbft/cometbft/libs/log" graphtypes "github.com/cybercongress/go-cyber/v7/x/graph/types" "github.com/cybercongress/go-cyber/v7/x/rank/types" ) /* #cgo CFLAGS: -I/usr/lib/ #cgo LDFLAGS: -L/usr/local/cuda/lib64 -lcbdrank -lcudart #include "cbdrank.h" */ import "C" func calculateRankGPU(ctx *types.CalculationContext, logger log.Logger) types.EMState { start := time.Now() if ctx.GetCidsCount() == 0 { return types.EMState{ RankValues: make([]float64, 0), } } tolerance := ctx.GetTolerance() dampingFactor := ctx.GetDampingFactor() cidsCount := ctx.GetCidsCount() stakesCount := ctx.GetNeuronsCount() rank := make([]float64, cidsCount) inLinksCount := make([]uint32, cidsCount) outLinksCount := make([]uint32, cidsCount) outLinksIns := make([]uint64, 0) inLinksOuts := make([]uint64, 0) inLinksUsers := make([]uint64, 0) outLinksUsers := make([]uint64, 0) // will fail if amount of indexed accounts will not equal all accounts // distribute current flow through all neuron's cyberlinks stakes := make([]uint64, stakesCount) for neuron, stake := range ctx.GetStakes() { neudeg := ctx.GetNeudegs()[neuron] if neudeg != 0 { stakes[neuron] = stake / neudeg } else { stakes[neuron] = 0 } } for i := int64(0); i < cidsCount; i++ { if inLinks, sortedCids, ok := ctx.GetSortedInLinks(graphtypes.CidNumber(i)); ok { for _, cid := range sortedCids { inLinksCount[i] += uint32(len(inLinks[cid])) for acc := range inLinks[cid] { inLinksOuts = append(inLinksOuts, uint64(cid)) inLinksUsers = append(inLinksUsers, uint64(acc)) } } } if outLinks, sortedCids, ok := ctx.GetSortedOutLinks(graphtypes.CidNumber(i)); ok { for _, cid := range sortedCids { outLinksCount[i] += uint32(len(outLinks[cid])) for acc := range outLinks[cid] { outLinksIns = append(outLinksIns, uint64(cid)) outLinksUsers = append(outLinksUsers, uint64(acc)) } } } } /* Convert to C types */ cStakes := (*C.ulong)(&stakes[0]) cStakesSize := C.ulong(len(stakes)) cCidsSize := C.ulong(len(inLinksCount)) cLinksSize := C.ulong(len(inLinksOuts)) cInLinksCount := (*C.uint)(&inLinksCount[0]) cOutLinksCount := (*C.uint)(&outLinksCount[0]) cOutLinksIns := (*C.ulong)(&outLinksIns[0]) cInLinksOuts := (*C.ulong)(&inLinksOuts[0]) cInLinksUsers := (*C.ulong)(&inLinksUsers[0]) cOutLinksUsers := (*C.ulong)(&outLinksUsers[0]) cDampingFactor := C.double(dampingFactor) cTolerance := C.double(tolerance) logger.Info("Data transform", "duration", time.Since(start).String()) start = time.Now() cRank := (*C.double)(&rank[0]) C.calculate_rank( cStakes, cStakesSize, cCidsSize, cLinksSize, cInLinksCount, cOutLinksCount, cInLinksOuts, cOutLinksIns, cInLinksUsers, cOutLinksUsers, cDampingFactor, cTolerance, cRank, ) logger.Info("Rank computation", "duration", time.Since(start).String()) return types.EMState{ RankValues: rank, } } ================================================ FILE: x/rank/keeper/calculate_gpu_nop.go ================================================ //go:build !cuda // +build !cuda package keeper import ( "github.com/cybercongress/go-cyber/v7/x/rank/types" "github.com/cometbft/cometbft/libs/log" ) func calculateRankGPU(ctx *types.CalculationContext, logger log.Logger) types.EMState { panic("Daemon compiled without gpu support, but started in gpu mode") } ================================================ FILE: x/rank/keeper/calculate_mock.go ================================================ package keeper import ( "github.com/cybercongress/go-cyber/v7/x/rank/types" ) func mockRank(ctx *types.CalculationContext) types.EMState { size := ctx.GetCidsCount() if size == 0 || len(ctx.GetStakes()) == 0 { return types.EMState{ RankValues: []float64{}, } } rank := make([]float64, size) // Rank: deterministic descending normalized distribution denom := float64(size * (size + 1) / 2) for i := int64(0); i < size; i++ { rank[i] = float64(size-i) / denom } return types.EMState{ RankValues: rank, } } ================================================ FILE: x/rank/keeper/genesis.go ================================================ package keeper import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/rank/types" ) func InitGenesis(ctx sdk.Context, sk StateKeeper, data types.GenesisState) { if err := sk.SetParams(ctx, data.Params); err != nil { panic(err) } } func ExportGenesis(ctx sdk.Context, keeper StateKeeper) *types.GenesisState { return types.NewGenesisState(keeper.GetParams(ctx)) } ================================================ FILE: x/rank/keeper/grpc_query.go ================================================ package keeper import ( "context" "math" errorsmod "cosmossdk.io/errors" "github.com/ipfs/go-cid" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" "google.golang.org/grpc/codes" "google.golang.org/grpc/status" graphtypes "github.com/cybercongress/go-cyber/v7/x/graph/types" "github.com/cybercongress/go-cyber/v7/x/rank/types" querytypes "github.com/cybercongress/go-cyber/v7/x/rank/types" ) var _ types.QueryServer = &StateKeeper{} func (sk StateKeeper) Params(goCtx context.Context, _ *types.QueryParamsRequest) (*types.QueryParamsResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) params := sk.GetParams(ctx) return &types.QueryParamsResponse{Params: params}, nil } func (sk StateKeeper) Rank(goCtx context.Context, req *types.QueryRankRequest) (*types.QueryRankResponse, error) { if req == nil { return nil, status.Errorf(codes.InvalidArgument, "empty request") } ctx := sdk.UnwrapSDKContext(goCtx) particle, err := cid.Decode(req.Particle) if err != nil { return nil, graphtypes.ErrInvalidParticle } if particle.Version() != 0 { return nil, graphtypes.ErrCidVersion } cidNum, exist := sk.graphKeeper.GetCidNumber(ctx, graphtypes.Cid(req.Particle)) if !exist { return nil, errorsmod.Wrap(graphtypes.ErrCidNotFound, req.Particle) } // rankValue := sk.index.GetRankValue(cidNum) // TODO it was the bug, test wasm rankValue := sk.networkCidRank.RankValues[cidNum] return &types.QueryRankResponse{Rank: rankValue}, nil } func (sk *StateKeeper) Search(goCtx context.Context, req *types.QuerySearchRequest) (*types.QuerySearchResponse, error) { if req == nil { return nil, status.Errorf(codes.InvalidArgument, "empty request") } ctx := sdk.UnwrapSDKContext(goCtx) cidNum, exist := sk.graphKeeper.GetCidNumber(ctx, graphtypes.Cid(req.Particle)) if !exist { return nil, errorsmod.Wrap(graphtypes.ErrCidNotFound, "") } page, limit := uint32(0), uint32(10) if req.Pagination != nil { page, limit = req.Pagination.Page, req.Pagination.PerPage } rankedCidNumbers, totalSize, err := sk.index.Search(cidNum, page, limit) if err != nil { panic(err) } result := make([]types.RankedParticle, 0, len(rankedCidNumbers)) for _, c := range rankedCidNumbers { result = append(result, types.RankedParticle{Particle: string(sk.graphKeeper.GetCid(ctx, c.GetNumber())), Rank: c.GetRank()}) } return &types.QuerySearchResponse{Result: result, Pagination: &querytypes.PageResponse{Total: totalSize}}, nil } func (sk *StateKeeper) Backlinks(goCtx context.Context, req *types.QuerySearchRequest) (*types.QuerySearchResponse, error) { if req == nil { return nil, status.Errorf(codes.InvalidArgument, "empty request") } ctx := sdk.UnwrapSDKContext(goCtx) cidNum, exist := sk.graphKeeper.GetCidNumber(ctx, graphtypes.Cid(req.Particle)) if !exist { return nil, errorsmod.Wrap(graphtypes.ErrCidNotFound, req.Particle) } page, limit := uint32(0), uint32(10) if req.Pagination != nil { page, limit = req.Pagination.Page, req.Pagination.PerPage } rankedCidNumbers, totalSize, err := sk.index.Backlinks(cidNum, page, limit) if err != nil { panic(err) } result := make([]types.RankedParticle, 0, len(rankedCidNumbers)) for _, c := range rankedCidNumbers { result = append(result, types.RankedParticle{Particle: string(sk.graphKeeper.GetCid(ctx, c.GetNumber())), Rank: c.GetRank()}) } return &types.QuerySearchResponse{Result: result, Pagination: &querytypes.PageResponse{Total: totalSize}}, nil } func (sk *StateKeeper) Top(goCtx context.Context, req *querytypes.QueryTopRequest) (*types.QuerySearchResponse, error) { if req == nil { return nil, status.Errorf(codes.InvalidArgument, "empty request") } ctx := sdk.UnwrapSDKContext(goCtx) if req.Pagination.PerPage > uint32(1000) { return nil, sdkerrors.ErrInvalidRequest } page, limit := req.Pagination.Page, req.Pagination.PerPage topRankedCidNumbers, totalSize, err := sk.index.Top(page, limit) if err != nil { panic(err) } result := make([]types.RankedParticle, 0, len(topRankedCidNumbers)) for _, c := range topRankedCidNumbers { result = append(result, types.RankedParticle{Particle: string(sk.graphKeeper.GetCid(ctx, c.GetNumber())), Rank: c.GetRank()}) } return &types.QuerySearchResponse{Result: result, Pagination: &querytypes.PageResponse{Total: totalSize}}, nil } func (sk StateKeeper) IsLinkExist(goCtx context.Context, req *types.QueryIsLinkExistRequest) (*types.QueryLinkExistResponse, error) { if req == nil { return nil, status.Errorf(codes.InvalidArgument, "empty request") } addr, err := sdk.AccAddressFromBech32(req.Address) if err != nil { return nil, errorsmod.Wrap(sdkerrors.ErrInvalidAddress, err.Error()) } ctx := sdk.UnwrapSDKContext(goCtx) cidNumFrom, exist := sk.graphKeeper.GetCidNumber(ctx, graphtypes.Cid(req.From)) if !exist { return nil, errorsmod.Wrap(graphtypes.ErrCidNotFound, req.From) } cidNumTo, exist := sk.graphKeeper.GetCidNumber(ctx, graphtypes.Cid(req.To)) if !exist { return nil, errorsmod.Wrap(graphtypes.ErrCidNotFound, req.To) } var accountNum uint64 account := sk.accountKeeper.GetAccount(ctx, addr) if account != nil { accountNum = account.GetAccountNumber() } else { return nil, errorsmod.Wrap(sdkerrors.ErrInvalidAddress, "Invalid neuron address") } exists := sk.graphIndexedKeeper.IsLinkExist(graphtypes.CompactLink{ From: uint64(cidNumFrom), To: uint64(cidNumTo), Account: accountNum, }) return &types.QueryLinkExistResponse{Exist: exists}, nil } func (sk StateKeeper) IsAnyLinkExist(goCtx context.Context, req *types.QueryIsAnyLinkExistRequest) (*types.QueryLinkExistResponse, error) { if req == nil { return nil, status.Errorf(codes.InvalidArgument, "empty request") } ctx := sdk.UnwrapSDKContext(goCtx) cidNumFrom, exist := sk.graphKeeper.GetCidNumber(ctx, graphtypes.Cid(req.From)) if !exist { return nil, errorsmod.Wrap(graphtypes.ErrCidNotFound, req.From) } cidNumTo, exist := sk.graphKeeper.GetCidNumber(ctx, graphtypes.Cid(req.To)) if !exist { return nil, errorsmod.Wrap(graphtypes.ErrCidNotFound, req.To) } exists := sk.graphIndexedKeeper.IsAnyLinkExist(cidNumFrom, cidNumTo) return &types.QueryLinkExistResponse{Exist: exists}, nil } // ParticleNegentropy returns the per-particle contribution to focus entropy. // Computed at query time from RankValues: -πi × log2(πi) scaled by 1e15. // No state is stored; this is a pure function of the current rank distribution. func (sk *StateKeeper) ParticleNegentropy(goCtx context.Context, req *types.QueryNegentropyPartilceRequest) (*types.QueryNegentropyParticleResponse, error) { if req == nil { return nil, status.Errorf(codes.InvalidArgument, "empty request") } ctx := sdk.UnwrapSDKContext(goCtx) cidNum, exist := sk.graphKeeper.GetCidNumber(ctx, graphtypes.Cid(req.Particle)) if !exist { return nil, errorsmod.Wrap(graphtypes.ErrCidNotFound, req.Particle) } rankValues := sk.networkCidRank.RankValues if rankValues == nil || uint64(cidNum) >= uint64(len(rankValues)) { return &types.QueryNegentropyParticleResponse{Entropy: 0}, nil } totalRank := uint64(0) for _, r := range rankValues { totalRank += r } if totalRank == 0 { return &types.QueryNegentropyParticleResponse{Entropy: 0}, nil } ri := rankValues[cidNum] if ri == 0 { return &types.QueryNegentropyParticleResponse{Entropy: 0}, nil } // -πi × log2(πi), scaled to uint64 by 1e15 pi := float64(ri) / float64(totalRank) contribution := -pi * math.Log2(pi) entropy := uint64(contribution * 1e15) return &types.QueryNegentropyParticleResponse{Entropy: entropy}, nil } // Negentropy returns system-wide negentropy: J(π) = log2(n) − H(π). // Computed at query time from RankValues. No state is stored. // H(π) = −Σ πi × log2(πi), where πi = rankValue_i / Σ rankValues. // J(π) measures how far the focus distribution deviates from uniform. func (sk *StateKeeper) Negentropy(_ context.Context, _ *types.QueryNegentropyRequest) (*types.QueryNegentropyResponse, error) { rankValues := sk.networkCidRank.RankValues n := uint64(len(rankValues)) if n == 0 { return &types.QueryNegentropyResponse{Negentropy: 0}, nil } totalRank := uint64(0) for _, r := range rankValues { totalRank += r } if totalRank == 0 { return &types.QueryNegentropyResponse{Negentropy: 0}, nil } // H(π) = −Σ πi × log2(πi) h := 0.0 for _, r := range rankValues { if r == 0 { continue } pi := float64(r) / float64(totalRank) h -= pi * math.Log2(pi) } // J(π) = log2(n) − H(π) logN := math.Log2(float64(n)) negentropy := logN - h if negentropy < 0 { negentropy = 0 } // Scale to uint64 by 1e15 (same convention as rank values) result := uint64(negentropy * 1e15) return &types.QueryNegentropyResponse{Negentropy: result}, nil } // Deprecated: karma removed. Stub kept for protobuf interface compatibility. func (sk *StateKeeper) Karma(_ context.Context, _ *types.QueryKarmaRequest) (*types.QueryKarmaResponse, error) { return nil, status.Errorf(codes.Unimplemented, "karma removed") } ================================================ FILE: x/rank/keeper/keeper.go ================================================ package keeper import ( "bytes" "crypto/sha256" "encoding/binary" "fmt" "strconv" "time" "github.com/cosmos/cosmos-sdk/codec" storetypes "github.com/cosmos/cosmos-sdk/store/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" "github.com/cosmos/cosmos-sdk/x/auth/keeper" "github.com/cybercongress/go-cyber/v7/merkle" graphkeeper "github.com/cybercongress/go-cyber/v7/x/graph/keeper" graphtypes "github.com/cybercongress/go-cyber/v7/x/graph/types" "github.com/cybercongress/go-cyber/v7/x/rank/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cometbft/cometbft/libs/log" ) type StateKeeper struct { cdc codec.BinaryCodec storeKey storetypes.StoreKey networkCidRank types.Rank nextCidRank types.Rank rankCalculationFinished bool //cidCount int64 hasNewLinksForPeriod bool rankCalcChan chan types.Rank rankErrChan chan error allowSearch bool computeUnit types.ComputeUnit computeMock bool // only for tests stakeKeeper types.StakeKeeper graphKeeper types.GraphKeeper graphIndexedKeeper *graphkeeper.IndexKeeper accountKeeper keeper.AccountKeeper index types.SearchIndex getIndexError types.GetError authority string } func NewKeeper( cdc codec.BinaryCodec, key storetypes.StoreKey, allowSearch bool, stakeIndex types.StakeKeeper, graphIndexedKeeper *graphkeeper.IndexKeeper, graphKeeper types.GraphKeeper, accountKeeper keeper.AccountKeeper, unit types.ComputeUnit, mock bool, authority string, ) *StateKeeper { return &StateKeeper{ storeKey: key, cdc: cdc, allowSearch: allowSearch, rankCalcChan: make(chan types.Rank, 1), rankErrChan: make(chan error), rankCalculationFinished: true, stakeKeeper: stakeIndex, graphIndexedKeeper: graphIndexedKeeper, graphKeeper: graphKeeper, accountKeeper: accountKeeper, computeUnit: unit, computeMock: mock, hasNewLinksForPeriod: true, authority: authority, } } func (sk *StateKeeper) GetAuthority() string { return sk.authority } func (sk *StateKeeper) Logger(ctx sdk.Context) log.Logger { return ctx.Logger().With("module", "x/"+types.ModuleName) } func (k *StateKeeper) SetParams(ctx sdk.Context, p types.Params) error { if err := p.Validate(); err != nil { return err } store := ctx.KVStore(k.storeKey) bz := k.cdc.MustMarshal(&p) store.Set(types.ParamsKey, bz) return nil } func (k *StateKeeper) GetParams(ctx sdk.Context) (p types.Params) { store := ctx.KVStore(k.storeKey) bz := store.Get(types.ParamsKey) if bz == nil { return p } k.cdc.MustUnmarshal(bz, &p) return p } func (sk *StateKeeper) LoadState(ctx sdk.Context) { sk.networkCidRank = types.NewFromMerkle(sk.graphKeeper.GetCidsCount(ctx), sk.GetLatestMerkleTree(ctx)) sk.nextCidRank = types.NewFromMerkle(sk.GetNextRankCidCount(ctx), sk.GetNextMerkleTree(ctx)) sk.index = sk.BuildSearchIndex(sk.Logger(ctx)) sk.index.Load(sk.graphIndexedKeeper.GetOutLinks()) sk.getIndexError = sk.index.Run() } func (sk *StateKeeper) StartRankCalculation(ctx sdk.Context) { params := sk.GetParams(ctx) dampingFactor, err := strconv.ParseFloat(params.DampingFactor.String(), 64) if err != nil { panic(err) } tolerance, err := strconv.ParseFloat(params.Tolerance.String(), 64) if err != nil { panic(err) } sk.startRankCalculation(ctx, dampingFactor, tolerance) sk.rankCalculationFinished = false } func (sk *StateKeeper) BuildSearchIndex(logger log.Logger) types.SearchIndex { if sk.allowSearch { return types.NewBaseSearchIndex(logger) } return types.NoopSearchIndex{} } func (sk *StateKeeper) EndBlocker(ctx sdk.Context) { sk.StoreLatestBlockNumber(ctx, uint64(ctx.BlockHeight())) currentCidsCount := sk.graphKeeper.GetCidsCount(ctx) sk.index.PutNewLinks(sk.graphIndexedKeeper.GetCurrentBlockNewLinks(ctx)) // TODO MergeContextLinks need to be in graph'sk end blocker // but need to get new links here before nextRankLinks will be updated sk.graphIndexedKeeper.MergeContextLinks(ctx) blockHasNewLinks := sk.graphIndexedKeeper.HasNewLinks(ctx) sk.hasNewLinksForPeriod = sk.hasNewLinksForPeriod || blockHasNewLinks params := sk.GetParams(ctx) if ctx.BlockHeight()%params.CalculationPeriod == 0 || ctx.BlockHeight() == 1 { dampingFactor, err := strconv.ParseFloat(params.DampingFactor.String(), 64) if err != nil { panic(err) } tolerance, err := strconv.ParseFloat(params.Tolerance.String(), 64) if err != nil { panic(err) } sk.checkRankCalcFinished(ctx, true) sk.applyNextRank() stakeChanged := sk.stakeKeeper.DetectUsersStakeAmpereChange(ctx) // start new calculation if sk.hasNewLinksForPeriod || stakeChanged { sk.graphIndexedKeeper.UpdateRankLinks() sk.graphKeeper.UpdateRankNeudegs() sk.rankCalculationFinished = false sk.hasNewLinksForPeriod = false sk.prepareContext(ctx) sk.startRankCalculation(ctx, dampingFactor, tolerance) } } sk.networkCidRank.AddNewCids(currentCidsCount) networkMerkleTreeAsBytes := sk.getNetworkMerkleTreeAsBytes() sk.Logger(ctx).Info( "Latest Rank", "hash", fmt.Sprintf("%X", networkMerkleTreeAsBytes), ) sk.StoreLatestMerkleTree(ctx, networkMerkleTreeAsBytes) } func (sk *StateKeeper) startRankCalculation(ctx sdk.Context, dampingFactor float64, tolerance float64) { calcCtx := types.NewCalcContext( sk.graphIndexedKeeper, sk.graphKeeper, sk.stakeKeeper, sk.allowSearch, dampingFactor, tolerance, sk.GetContextCidCount(ctx), sk.GetContextLinkCount(ctx), sk.GetAccountCount(ctx), ) go CalculateRankInParallel(calcCtx, sk.rankCalcChan, sk.rankErrChan, sk.computeUnit, sk.computeMock, sk.Logger(ctx)) } func (sk *StateKeeper) checkRankCalcFinished(ctx sdk.Context, block bool) { if !sk.rankCalculationFinished { for { select { case newRank := <-sk.rankCalcChan: sk.handleNextRank(ctx, newRank) return case err := <-sk.rankErrChan: sk.Logger(ctx).Error("Error during cyber~Rank calculation, call cyber_devs! " + err.Error()) panic(err.Error()) default: if !block { return } } sk.Logger(ctx).Info("Waiting for cyber~Rank calculation to finish") time.Sleep(2000 * time.Millisecond) } } } func (sk *StateKeeper) handleNextRank(ctx sdk.Context, newRank types.Rank) { sk.nextCidRank = newRank nextMerkleTreeAsBytes := sk.getNextMerkleTreeAsBytes() sk.Logger(ctx).Info( "Next Rank", "hash", fmt.Sprintf("%X", nextMerkleTreeAsBytes), ) sk.StoreNextMerkleTree(ctx, nextMerkleTreeAsBytes) sk.StoreNextRankCidCount(ctx, newRank.CidCount) sk.rankCalculationFinished = true } func (sk *StateKeeper) applyNextRank() { if !sk.nextCidRank.IsEmpty() { sk.networkCidRank = sk.nextCidRank sk.index.PutNewRank(sk.networkCidRank) } sk.nextCidRank.Clear() } func (sk *StateKeeper) GetRankValueByNumber(number uint64) uint64 { if number >= uint64(len(sk.networkCidRank.RankValues)) { return 0 } return sk.networkCidRank.RankValues[number] } func (sk *StateKeeper) GetRankValueByParticle(ctx sdk.Context, particle string) (uint64, error) { number, exist := sk.graphKeeper.GetCidNumber(ctx, graphtypes.Cid(particle)) if !exist { return 0, sdkerrors.ErrInvalidRequest } return sk.networkCidRank.RankValues[number], nil } func (sk *StateKeeper) GetNextNetworkRankHash() []byte { return sk.nextCidRank.MerkleTree.RootHash() } func (sk *StateKeeper) GetNetworkRankHash() []byte { return sk.networkCidRank.MerkleTree.RootHash() } func (sk *StateKeeper) getNetworkMerkleTreeAsBytes() []byte { return sk.networkCidRank.MerkleTree.ExportSubtreesRoots() } func (sk *StateKeeper) getNextMerkleTreeAsBytes() []byte { return sk.nextCidRank.MerkleTree.ExportSubtreesRoots() } func (sk *StateKeeper) GetLastCidNum() graphtypes.CidNumber { return graphtypes.CidNumber(len(sk.networkCidRank.RankValues) - 1) } func (sk *StateKeeper) GetMerkleTree() *merkle.Tree { return sk.networkCidRank.MerkleTree } func (sk *StateKeeper) GetIndexError() error { return sk.getIndexError() } func (sk StateKeeper) GetLatestBlockNumber(ctx sdk.Context) uint64 { store := ctx.KVStore(sk.storeKey) numberAsBytes := store.Get(types.LatestBlockNumber) if numberAsBytes == nil { return 0 } return binary.LittleEndian.Uint64(numberAsBytes) } func (sk StateKeeper) StoreLatestBlockNumber(ctx sdk.Context, number uint64) { store := ctx.KVStore(sk.storeKey) numberAsBytes := make([]byte, 8) binary.LittleEndian.PutUint64(numberAsBytes, number) store.Set(types.LatestBlockNumber, numberAsBytes) } func (sk StateKeeper) GetLatestMerkleTree(ctx sdk.Context) []byte { store := ctx.KVStore(sk.storeKey) return store.Get(types.LatestMerkleTree) } func (sk StateKeeper) StoreLatestMerkleTree(ctx sdk.Context, treeAsBytes []byte) { store := ctx.KVStore(sk.storeKey) if bytes.Compare(sk.GetLatestMerkleTree(ctx), treeAsBytes) != 0 { //nolint:gosimple store.Set(types.LatestMerkleTree, treeAsBytes) } } func (sk StateKeeper) GetNextMerkleTree(ctx sdk.Context) []byte { store := ctx.KVStore(sk.storeKey) return store.Get(types.NextMerkleTree) } func (sk StateKeeper) StoreNextMerkleTree(ctx sdk.Context, treeAsBytes []byte) { store := ctx.KVStore(sk.storeKey) if bytes.Compare(sk.GetNextMerkleTree(ctx), treeAsBytes) != 0 { //nolint:gosimple store.Set(types.NextMerkleTree, treeAsBytes) } } func (sk StateKeeper) SetDebugMerkleTrees(ctx sdk.Context, cidCount uint64) { merkleTree := merkle.NewTree(sha256.New(), false) zeroRankBytes := make([]byte, 8) for i := uint64(0); i < cidCount; i++ { merkleTree.Push(zeroRankBytes) } treeBytes := merkleTree.ExportSubtreesRoots() store := ctx.KVStore(sk.storeKey) store.Set(types.LatestMerkleTree, treeBytes) store.Set(types.NextMerkleTree, treeBytes) } func (sk StateKeeper) GetNextRankCidCount(ctx sdk.Context) uint64 { store := ctx.KVStore(sk.storeKey) numberAsBytes := store.Get(types.NextRankCidCount) if numberAsBytes == nil { return sk.graphKeeper.GetCidsCount(ctx) } return binary.LittleEndian.Uint64(numberAsBytes) } func (sk StateKeeper) StoreNextRankCidCount(ctx sdk.Context, number uint64) { if sk.GetNextRankCidCount(ctx) != number { store := ctx.KVStore(sk.storeKey) numberAsBytes := make([]byte, 8) binary.LittleEndian.PutUint64(numberAsBytes, number) store.Set(types.NextRankCidCount, numberAsBytes) } } func (sk StateKeeper) GetContextCidCount(ctx sdk.Context) uint64 { store := ctx.KVStore(sk.storeKey) numberAsBytes := store.Get(types.ContextCidCount) if numberAsBytes == nil { return 0 } return binary.LittleEndian.Uint64(numberAsBytes) } func (sk StateKeeper) StoreContextCidCount(ctx sdk.Context, number uint64) { if sk.GetContextCidCount(ctx) != number { store := ctx.KVStore(sk.storeKey) numberAsBytes := make([]byte, 8) binary.LittleEndian.PutUint64(numberAsBytes, number) store.Set(types.ContextCidCount, numberAsBytes) } } func (sk StateKeeper) GetContextLinkCount(ctx sdk.Context) uint64 { store := ctx.KVStore(sk.storeKey) numberAsBytes := store.Get(types.ContextLinkCount) if numberAsBytes == nil { return 0 } return binary.LittleEndian.Uint64(numberAsBytes) } func (sk StateKeeper) StoreContextLinkCount(ctx sdk.Context, number uint64) { if sk.GetContextLinkCount(ctx) != number { store := ctx.KVStore(sk.storeKey) numberAsBytes := make([]byte, 8) binary.LittleEndian.PutUint64(numberAsBytes, number) store.Set(types.ContextLinkCount, numberAsBytes) } } func (sk *StateKeeper) prepareContext(ctx sdk.Context) { sk.StoreContextCidCount(ctx, sk.graphKeeper.GetCidsCount(ctx)) sk.StoreContextLinkCount(ctx, sk.graphIndexedKeeper.GetLinksCount(ctx)) } func (sk *StateKeeper) GetAccountCount(ctx sdk.Context) uint64 { return sk.stakeKeeper.GetNextAccountNumber(ctx) } ================================================ FILE: x/rank/keeper/migrator.go ================================================ package keeper import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/rank/exported" v2 "github.com/cybercongress/go-cyber/v7/x/rank/migrations/v2" ) // Migrator is a struct for handling in-place state migrations. type Migrator struct { keeper StateKeeper legacySubspace exported.Subspace } func NewMigrator(k StateKeeper, ss exported.Subspace) Migrator { return Migrator{ keeper: k, legacySubspace: ss, } } func (m Migrator) Migrate1to2(ctx sdk.Context) error { return v2.Migrate(ctx, ctx.KVStore(m.keeper.storeKey), m.legacySubspace, m.keeper.cdc) } ================================================ FILE: x/rank/keeper/msg_server.go ================================================ package keeper import ( "context" govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" "cosmossdk.io/errors" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/rank/types" ) type msgServer struct { StateKeeper } func NewMsgServerImpl(sk StateKeeper) types.MsgServer { return &msgServer{StateKeeper: sk} } var _ types.MsgServer = msgServer{} func (server msgServer) UpdateParams(goCtx context.Context, req *types.MsgUpdateParams) (*types.MsgUpdateParamsResponse, error) { if server.authority != req.Authority { return nil, errors.Wrapf(govtypes.ErrInvalidSigner, "invalid authority; expected %s, got %s", server.authority, req.Authority) } ctx := sdk.UnwrapSDKContext(goCtx) if err := server.SetParams(ctx, req.Params); err != nil { return nil, err } return &types.MsgUpdateParamsResponse{}, nil } ================================================ FILE: x/rank/keeper/snapshotter.go ================================================ package keeper import ( "github.com/cometbft/cometbft/libs/log" tmproto "github.com/cometbft/cometbft/proto/tendermint/types" snapshot "github.com/cosmos/cosmos-sdk/snapshots/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/rank/types" ) var _ snapshot.ExtensionSnapshotter = &RankSnapshotter{} const SnapshotFormat = 1 type RankSnapshotter struct { keeper *StateKeeper cms sdk.MultiStore } func NewRankSnapshotter(cms sdk.MultiStore, keeper *StateKeeper) *RankSnapshotter { return &RankSnapshotter{ keeper: keeper, cms: cms, } } func (rs *RankSnapshotter) SnapshotName() string { return types.ModuleName } func (rs *RankSnapshotter) SnapshotFormat() uint32 { return SnapshotFormat } func (rs *RankSnapshotter) SupportedFormats() []uint32 { // If we support older formats, add them here and handle them in Restore return []uint32{SnapshotFormat} } func (rs *RankSnapshotter) SnapshotExtension(_ uint64, _ snapshot.ExtensionPayloadWriter) error { return nil } func (rs *RankSnapshotter) RestoreExtension(height uint64, format uint32, _ snapshot.ExtensionPayloadReader) error { if format == SnapshotFormat { freshCtx := sdk.NewContext(rs.cms, tmproto.Header{Height: int64(height)}, false, log.NewNopLogger()) rs.keeper.LoadState(freshCtx) rs.keeper.StartRankCalculation(freshCtx) return nil } return snapshot.ErrUnknownFormat } ================================================ FILE: x/rank/migrations/v2/migrate.go ================================================ package v2 import ( "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/rank/exported" "github.com/cybercongress/go-cyber/v7/x/rank/types" ) func Migrate( ctx sdk.Context, store sdk.KVStore, legacySubspace exported.Subspace, cdc codec.BinaryCodec, ) error { var currParams types.Params legacySubspace.GetParamSet(ctx, &currParams) if err := currParams.Validate(); err != nil { return err } bz := cdc.MustMarshal(&currParams) store.Set(types.ParamsKey, bz) return nil } ================================================ FILE: x/rank/module.go ================================================ package rank import ( "context" "encoding/json" "fmt" "github.com/cosmos/cosmos-sdk/client" codectypes "github.com/cosmos/cosmos-sdk/codec/types" "github.com/grpc-ecosystem/grpc-gateway/runtime" abci "github.com/cometbft/cometbft/abci/types" "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" "github.com/spf13/cobra" "github.com/cybercongress/go-cyber/v7/x/rank/client/cli" "github.com/cybercongress/go-cyber/v7/x/rank/exported" "github.com/cybercongress/go-cyber/v7/x/rank/keeper" "github.com/cybercongress/go-cyber/v7/x/rank/types" ) var ( _ module.AppModule = AppModule{} _ module.AppModuleBasic = AppModuleBasic{} ) const ( FlagComputeGPU = "compute-gpu" FlagComputeMock = "compute-mock" FlagSearchAPI = "search-api" ) type AppModuleBasic struct { cdc codec.Codec } func (AppModuleBasic) Name() string { return types.ModuleName } func (AppModuleBasic) RegisterLegacyAminoCodec(cdc *codec.LegacyAmino) { types.RegisterLegacyAminoCodec(cdc) } func (AppModuleBasic) DefaultGenesis(cdc codec.JSONCodec) json.RawMessage { return cdc.MustMarshalJSON(types.DefaultGenesisState()) } func (AppModuleBasic) ValidateGenesis(cdc codec.JSONCodec, _ client.TxEncodingConfig, bz json.RawMessage) error { var data types.GenesisState if err := cdc.UnmarshalJSON(bz, &data); err != nil { return fmt.Errorf("failed to unmarshal %s genesis state: %w", types.ModuleName, err) } return types.ValidateGenesis(&data) } func (AppModuleBasic) RegisterGRPCGatewayRoutes(clientCtx client.Context, mux *runtime.ServeMux) { if err := types.RegisterQueryHandlerClient(context.Background(), mux, types.NewQueryClient(clientCtx)); err != nil { panic(err) } } func (AppModuleBasic) GetTxCmd() *cobra.Command { return nil } func (AppModuleBasic) GetQueryCmd() *cobra.Command { return cli.GetQueryCmd() } func (AppModuleBasic) RegisterInterfaces(registry codectypes.InterfaceRegistry) { types.RegisterInterfaces(registry) } type AppModule struct { AppModuleBasic cdc codec.Codec rk *keeper.StateKeeper legacySubspace exported.Subspace } func NewAppModule( cdc codec.Codec, rankKeeper *keeper.StateKeeper, ss exported.Subspace, ) AppModule { return AppModule{ AppModuleBasic: AppModuleBasic{cdc: cdc}, cdc: cdc, rk: rankKeeper, legacySubspace: ss, } } func AddModuleInitFlags(startCmd *cobra.Command) { startCmd.Flags().Bool(FlagComputeGPU, true, "Compute on GPU") startCmd.Flags().Bool(FlagComputeMock, false, "Compute mock data") startCmd.Flags().Bool(FlagSearchAPI, false, "Run search API") } func (AppModule) Name() string { return types.ModuleName } func (am AppModule) RegisterInvariants(_ sdk.InvariantRegistry) {} func (am AppModule) RegisterServices(cfg module.Configurator) { types.RegisterQueryServer(cfg.QueryServer(), am.rk) types.RegisterMsgServer(cfg.MsgServer(), keeper.NewMsgServerImpl(*am.rk)) m := keeper.NewMigrator(*am.rk, am.legacySubspace) if err := cfg.RegisterMigration(types.ModuleName, 1, m.Migrate1to2); err != nil { panic(fmt.Sprintf("failed to migrate x/%s from version 1 to 2: %v", types.ModuleName, err)) } } func (am AppModule) InitGenesis(ctx sdk.Context, cdc codec.JSONCodec, data json.RawMessage) []abci.ValidatorUpdate { var genesisState types.GenesisState cdc.MustUnmarshalJSON(data, &genesisState) keeper.InitGenesis(ctx, *am.rk, genesisState) return []abci.ValidatorUpdate{} } func (am AppModule) ExportGenesis(ctx sdk.Context, cdc codec.JSONCodec) json.RawMessage { gs := keeper.ExportGenesis(ctx, *am.rk) return cdc.MustMarshalJSON(gs) } func (am AppModule) ConsensusVersion() uint64 { return 2 } func (am AppModule) BeginBlock(_ sdk.Context, _ abci.RequestBeginBlock) {} func (am AppModule) EndBlock(ctx sdk.Context, _ abci.RequestEndBlock) []abci.ValidatorUpdate { EndBlocker(ctx, am.rk) return []abci.ValidatorUpdate{} } ================================================ FILE: x/rank/types/codec.go ================================================ package types import ( "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/codec/legacy" "github.com/cosmos/cosmos-sdk/codec/types" cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/msgservice" authzcodec "github.com/cosmos/cosmos-sdk/x/authz/codec" govcodec "github.com/cosmos/cosmos-sdk/x/gov/codec" ) func RegisterLegacyAminoCodec(cdc *codec.LegacyAmino) { legacy.RegisterAminoMsg(cdc, &MsgUpdateParams{}, "cyber/rank/MsgUpdateParams") cdc.RegisterConcrete(Params{}, "cyber/rank/Params", nil) } func RegisterInterfaces(registry types.InterfaceRegistry) { registry.RegisterImplementations((*sdk.Msg)(nil), &MsgUpdateParams{}, ) msgservice.RegisterMsgServiceDesc(registry, &_Msg_serviceDesc) } var ( amino = codec.NewLegacyAmino() ModuleCdc = codec.NewAminoCodec(amino) ) func init() { RegisterLegacyAminoCodec(amino) cryptocodec.RegisterCrypto(amino) sdk.RegisterLegacyAminoCodec(amino) RegisterLegacyAminoCodec(authzcodec.Amino) RegisterLegacyAminoCodec(govcodec.Amino) } ================================================ FILE: x/rank/types/compute.go ================================================ package types type ComputeUnit int const ( CPU ComputeUnit = iota GPU ComputeUnit = iota ) ================================================ FILE: x/rank/types/context.go ================================================ package types import ( "sort" graphtypes "github.com/cybercongress/go-cyber/v7/x/graph/types" ) type CalculationContext struct { CidsCount int64 LinksCount int64 NeuronsCount int64 inLinks map[graphtypes.CidNumber]graphtypes.CidLinks outLinks map[graphtypes.CidNumber]graphtypes.CidLinks stakes map[uint64]uint64 neudegs map[uint64]uint64 FullTree bool DampingFactor float64 Tolerance float64 } func NewCalcContext( linkIndex GraphIndexedKeeper, graphKeeper GraphKeeper, stakeKeeper StakeKeeper, fullTree bool, dampingFactor float64, tolerance float64, cidsCount, linksCount, neuronsCount uint64, ) *CalculationContext { return &CalculationContext{ CidsCount: int64(cidsCount), LinksCount: int64(linksCount), NeuronsCount: int64(neuronsCount), inLinks: linkIndex.GetInLinks(), outLinks: linkIndex.GetOutLinks(), stakes: stakeKeeper.GetTotalStakesAmpere(), neudegs: graphKeeper.GetNeudegs(), FullTree: fullTree, DampingFactor: dampingFactor, Tolerance: tolerance, } } func (calctx *CalculationContext) GetInLinks() map[graphtypes.CidNumber]graphtypes.CidLinks { return calctx.inLinks } func (calctx *CalculationContext) GetOutLinks() map[graphtypes.CidNumber]graphtypes.CidLinks { return calctx.outLinks } func (calctx *CalculationContext) GetCidsCount() int64 { return calctx.CidsCount } func (calctx *CalculationContext) GetNeuronsCount() int64 { return calctx.NeuronsCount } func (calctx *CalculationContext) GetStakes() map[uint64]uint64 { return calctx.stakes } func (calctx *CalculationContext) GetNeudegs() map[uint64]uint64 { return calctx.neudegs } func (calctx *CalculationContext) GetTolerance() float64 { return calctx.Tolerance } func (calctx *CalculationContext) GetDampingFactor() float64 { return calctx.DampingFactor } func (calctx *CalculationContext) GetSortedInLinks(cid graphtypes.CidNumber) (graphtypes.CidLinks, []graphtypes.CidNumber, bool) { links := calctx.inLinks[cid] if len(links) == 0 { return nil, nil, false } numbers := make([]graphtypes.CidNumber, 0, len(links)) for num := range links { numbers = append(numbers, num) } sort.Slice(numbers, func(i, j int) bool { return numbers[i] < numbers[j] }) return links, numbers, true } func (calctx *CalculationContext) GetSortedOutLinks(cid graphtypes.CidNumber) (graphtypes.CidLinks, []graphtypes.CidNumber, bool) { links := calctx.outLinks[cid] if len(links) == 0 { return nil, nil, false } numbers := make([]graphtypes.CidNumber, 0, len(links)) for num := range links { numbers = append(numbers, num) } sort.Slice(numbers, func(i, j int) bool { return numbers[i] < numbers[j] }) return links, numbers, true } ================================================ FILE: x/rank/types/expected_keepers.go ================================================ package types import ( sdk "github.com/cosmos/cosmos-sdk/types" graphtypes "github.com/cybercongress/go-cyber/v7/x/graph/types" ) type StakeKeeper interface { DetectUsersStakeAmpereChange(ctx sdk.Context) bool GetTotalStakesAmpere() map[uint64]uint64 GetNextAccountNumber(ctx sdk.Context) uint64 } type GraphIndexedKeeper interface { UpdateRankLinks() MergeContextLinks(sdk.Context) GetOutLinks() graphtypes.Links GetInLinks() graphtypes.Links GetLinksCount(sdk.Context) uint64 GetCurrentBlockNewLinks(ctx sdk.Context) []graphtypes.CompactLink GetCidsCount(sdk.Context) uint64 } type GraphKeeper interface { GetCidsCount(sdk.Context) uint64 GetCidNumber(sdk.Context, graphtypes.Cid) (graphtypes.CidNumber, bool) GetCid(ctx sdk.Context, num graphtypes.CidNumber) graphtypes.Cid GetNeudegs() map[uint64]uint64 UpdateRankNeudegs() } ================================================ FILE: x/rank/types/genesis.go ================================================ package types func NewGenesisState(params Params) *GenesisState { return &GenesisState{ Params: params, } } func DefaultGenesisState() *GenesisState { return NewGenesisState(DefaultParams()) } func ValidateGenesis(data *GenesisState) error { return data.Params.Validate() } ================================================ FILE: x/rank/types/genesis.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: cyber/rank/v1beta1/genesis.proto package types import ( fmt "fmt" io "io" math "math" math_bits "math/bits" _ "github.com/cosmos/gogoproto/gogoproto" proto "github.com/cosmos/gogoproto/proto" ) // Reference imports to suppress errors if they are not otherwise used. var ( _ = proto.Marshal _ = fmt.Errorf _ = math.Inf ) // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package type GenesisState struct { Params Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params"` } func (m *GenesisState) Reset() { *m = GenesisState{} } func (m *GenesisState) String() string { return proto.CompactTextString(m) } func (*GenesisState) ProtoMessage() {} func (*GenesisState) Descriptor() ([]byte, []int) { return fileDescriptor_2c3626db1bd06e3d, []int{0} } func (m *GenesisState) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *GenesisState) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_GenesisState.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *GenesisState) XXX_Merge(src proto.Message) { xxx_messageInfo_GenesisState.Merge(m, src) } func (m *GenesisState) XXX_Size() int { return m.Size() } func (m *GenesisState) XXX_DiscardUnknown() { xxx_messageInfo_GenesisState.DiscardUnknown(m) } var xxx_messageInfo_GenesisState proto.InternalMessageInfo func (m *GenesisState) GetParams() Params { if m != nil { return m.Params } return Params{} } func init() { proto.RegisterType((*GenesisState)(nil), "cyber.rank.v1beta1.GenesisState") } func init() { proto.RegisterFile("cyber/rank/v1beta1/genesis.proto", fileDescriptor_2c3626db1bd06e3d) } var fileDescriptor_2c3626db1bd06e3d = []byte{ // 205 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x48, 0xae, 0x4c, 0x4a, 0x2d, 0xd2, 0x2f, 0x4a, 0xcc, 0xcb, 0xd6, 0x2f, 0x33, 0x4c, 0x4a, 0x2d, 0x49, 0x34, 0xd4, 0x4f, 0x4f, 0xcd, 0x4b, 0x2d, 0xce, 0x2c, 0xd6, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x02, 0xab, 0xd0, 0x03, 0xa9, 0xd0, 0x83, 0xaa, 0x90, 0x12, 0x49, 0xcf, 0x4f, 0xcf, 0x07, 0x4b, 0xeb, 0x83, 0x58, 0x10, 0x95, 0x52, 0x72, 0x58, 0xcc, 0x2a, 0xa9, 0x2c, 0x48, 0x85, 0x9a, 0xa4, 0xe4, 0xc1, 0xc5, 0xe3, 0x0e, 0x31, 0x3a, 0xb8, 0x24, 0xb1, 0x24, 0x55, 0xc8, 0x82, 0x8b, 0xad, 0x20, 0xb1, 0x28, 0x31, 0xb7, 0x58, 0x82, 0x51, 0x81, 0x51, 0x83, 0xdb, 0x48, 0x4a, 0x0f, 0xd3, 0x2a, 0xbd, 0x00, 0xb0, 0x0a, 0x27, 0x96, 0x13, 0xf7, 0xe4, 0x19, 0x82, 0xa0, 0xea, 0x9d, 0x3c, 0x4e, 0x3c, 0x92, 0x63, 0xbc, 0xf0, 0x48, 0x8e, 0xf1, 0xc1, 0x23, 0x39, 0xc6, 0x09, 0x8f, 0xe5, 0x18, 0x2e, 0x3c, 0x96, 0x63, 0xb8, 0xf1, 0x58, 0x8e, 0x21, 0x4a, 0x2f, 0x3d, 0xb3, 0x24, 0xa3, 0x34, 0x49, 0x2f, 0x39, 0x3f, 0x57, 0x1f, 0x6c, 0x5a, 0x72, 0x7e, 0x5e, 0x7a, 0x51, 0x6a, 0x71, 0xb1, 0x7e, 0x7a, 0xbe, 0x2e, 0xc4, 0x7d, 0x15, 0x10, 0x17, 0x82, 0x5d, 0x96, 0xc4, 0x06, 0x76, 0x9a, 0x31, 0x20, 0x00, 0x00, 0xff, 0xff, 0x2e, 0xb5, 0x91, 0x33, 0x08, 0x01, 0x00, 0x00, } func (m *GenesisState) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *GenesisState) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *GenesisState) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.Params.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintGenesis(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa return len(dAtA) - i, nil } func encodeVarintGenesis(dAtA []byte, offset int, v uint64) int { offset -= sovGenesis(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *GenesisState) Size() (n int) { if m == nil { return 0 } var l int _ = l l = m.Params.Size() n += 1 + l + sovGenesis(uint64(l)) return n } func sovGenesis(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozGenesis(x uint64) (n int) { return sovGenesis(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *GenesisState) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenesis } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: GenesisState: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: GenesisState: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenesis } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthGenesis } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenesis } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Params.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipGenesis(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthGenesis } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipGenesis(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowGenesis } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowGenesis } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowGenesis } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthGenesis } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupGenesis } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthGenesis } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthGenesis = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowGenesis = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupGenesis = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/rank/types/index.go ================================================ package types import ( "errors" "sort" "time" "github.com/cometbft/cometbft/libs/log" graphtypes "github.com/cybercongress/go-cyber/v7/x/graph/types" ) type BaseSearchIndex struct { links []CidLinks backlinks []CidLinks rank Rank linksChan chan graphtypes.CompactLink rankChan chan Rank errChan chan error locked bool logger log.Logger } func NewBaseSearchIndex(log log.Logger) *BaseSearchIndex { return &BaseSearchIndex{ linksChan: make(chan graphtypes.CompactLink, 1000), rankChan: make(chan Rank, 1), errChan: make(chan error), locked: true, logger: log, } } func (i *BaseSearchIndex) Run() GetError { go i.startListenNewLinks() go i.startListenNewRank() return i.checkIndexError } // LoadState links with zero rank values. No sorting. Index should be unavailable for read func (i *BaseSearchIndex) Load(links graphtypes.Links) { startTime := time.Now() i.lock() // lock index for read i.links = make([]CidLinks, 0, 1000000) i.backlinks = make([]CidLinks, 0, 1000000) for from, toCids := range links { i.extendIndex(uint64(from)) for to := range toCids { i.putLinkIntoIndex(from, to) i.extendReverseIndex(uint64(to)) i.putBacklinkIntoIndex(from, to) } } i.logger.Info("The node search index is loaded", "time", time.Since(startTime)) } func (i *BaseSearchIndex) PutNewLinks(links []graphtypes.CompactLink) { for _, link := range links { i.linksChan <- link } } func (i *BaseSearchIndex) PutNewRank(rank Rank) { i.rankChan <- rank.CopyWithoutTree() } func (i *BaseSearchIndex) Search(cidNumber graphtypes.CidNumber, page, perPage uint32) ([]RankedCidNumber, uint32, error) { i.logger.Info("Search query", "particle", cidNumber, "page", page, "perPage", perPage) if i.locked { return nil, 0, errors.New("search index currently unavailable after node restart") } if uint64(cidNumber) >= uint64(len(i.links)) { return []RankedCidNumber{}, 0, nil } cidLinks := i.links[cidNumber] if cidLinks.sortedLinks == nil || len(cidLinks.sortedLinks) == 0 { return []RankedCidNumber{}, 0, nil } totalSize := uint32(len(cidLinks.sortedLinks)) startIndex := page * perPage if startIndex >= totalSize { return nil, totalSize, errors.New("page not found") } endIndex := startIndex + perPage if endIndex > totalSize { endIndex = startIndex + (totalSize % perPage) } resultSet := cidLinks.sortedLinks[startIndex:endIndex] return resultSet, totalSize, nil } func (i *BaseSearchIndex) Backlinks(cidNumber graphtypes.CidNumber, page, perPage uint32) ([]RankedCidNumber, uint32, error) { i.logger.Info("Backlinks query", "cid", cidNumber, "page", page, "perPage", perPage) if i.locked { return nil, 0, errors.New("the search index is currently unavailable after node restart") } if uint64(cidNumber) >= uint64(len(i.backlinks)) { return []RankedCidNumber{}, 0, nil } cidLinks := i.backlinks[cidNumber] if cidLinks.sortedLinks == nil || len(cidLinks.sortedLinks) == 0 { return []RankedCidNumber{}, 0, nil } totalSize := uint32(len(cidLinks.sortedLinks)) startIndex := page * perPage if startIndex >= totalSize { return nil, totalSize, errors.New("page not found") } endIndex := startIndex + perPage if endIndex > totalSize { endIndex = startIndex + (totalSize % perPage) } resultSet := cidLinks.sortedLinks[startIndex:endIndex] return resultSet, totalSize, nil } func (i *BaseSearchIndex) Top(page, perPage uint32) ([]RankedCidNumber, uint32, error) { if i.locked { return nil, 0, errors.New("the search index is currently unavailable after node restart") } totalSize := uint32(len(i.rank.TopCIDs)) startIndex := page * perPage if startIndex >= totalSize { return nil, totalSize, errors.New("page not found") } endIndex := startIndex + perPage if endIndex > totalSize { endIndex = startIndex + (totalSize % perPage) } resultSet := i.rank.TopCIDs[startIndex:endIndex] return resultSet, totalSize, nil } // make sure that this link (from-to) is new func (i *BaseSearchIndex) handleLink(link graphtypes.CompactLink) { i.extendIndex(link.From) fromIndex := i.links[link.From] // in case unlock signal received we could operate on this index otherwise put link in the end of queue and finish select { case <-fromIndex.unlockSignal: i.putLinkIntoIndex(graphtypes.CidNumber(link.From), graphtypes.CidNumber(link.To)) fromIndex.Unlock() break default: i.linksChan <- link } } func (i *BaseSearchIndex) handleBacklink(link graphtypes.CompactLink) { i.extendReverseIndex(link.To) toIndex := i.backlinks[link.To] // in case unlock signal received we could operate on this index otherwise put link in the end of queue and finish select { case <-toIndex.unlockSignal: i.putBacklinkIntoIndex(graphtypes.CidNumber(link.From), graphtypes.CidNumber(link.To)) toIndex.Unlock() break default: i.linksChan <- link } } func (i *BaseSearchIndex) GetRankValue(cid graphtypes.CidNumber) uint64 { if i.rank.RankValues == nil || uint64(len(i.rank.RankValues)) <= uint64(cid) { return 0 } return i.rank.RankValues[cid] } func (i *BaseSearchIndex) extendIndex(fromCidNumber uint64) { indexLen := uint64(len(i.links)) if fromCidNumber >= indexLen { for j := indexLen; j <= fromCidNumber; j++ { links := NewCidLinks() links.Unlock() // allow operations on this index i.links = append(i.links, links) } } } func (i *BaseSearchIndex) extendReverseIndex(fromCidNumber uint64) { indexLen := uint64(len(i.backlinks)) if fromCidNumber >= indexLen { for j := indexLen; j <= fromCidNumber; j++ { backlinks := NewCidLinks() backlinks.Unlock() // allow operations on this index i.backlinks = append(i.backlinks, backlinks) } } } func (i *BaseSearchIndex) putLinkIntoIndex(from graphtypes.CidNumber, to graphtypes.CidNumber) { fromLinks := i.links[uint64(from)].sortedLinks rankedTo := RankedCidNumber{to, i.GetRankValue(to)} pos := sort.Search(len(fromLinks), func(i int) bool { return fromLinks[i].rank < rankedTo.rank }) fromLinks = append(fromLinks, RankedCidNumber{}) copy(fromLinks[pos+1:], fromLinks[pos:]) fromLinks[pos] = rankedTo i.links[uint64(from)].sortedLinks = fromLinks } func (i *BaseSearchIndex) putBacklinkIntoIndex(from graphtypes.CidNumber, to graphtypes.CidNumber) { toLinks := i.backlinks[uint64(to)].sortedLinks rankedFrom := RankedCidNumber{from, i.GetRankValue(from)} pos := sort.Search(len(toLinks), func(i int) bool { return toLinks[i].rank < rankedFrom.rank }) toLinks = append(toLinks, RankedCidNumber{}) copy(toLinks[pos+1:], toLinks[pos:]) toLinks[pos] = rankedFrom i.backlinks[uint64(to)].sortedLinks = toLinks } // for parallel usage func (i *BaseSearchIndex) startListenNewLinks() { defer func() { if r := recover(); r != nil { i.errChan <- r.(error) } }() // i.logger.Info("The search index is starting to listen to new links") for { link := <-i.linksChan i.handleLink(link) i.handleBacklink(link) } } // for parallel usage func (i *BaseSearchIndex) startListenNewRank() { defer func() { if r := recover(); r != nil { i.errChan <- r.(error) } }() // i.logger.Info("The search index is starting to listen to new rank") for { rank := <-i.rankChan // TODO could be problems if recalculation lasts more than rank period i.rank = rank i.recalculateIndices() } } func (i *BaseSearchIndex) recalculateIndices() { defer i.unlock() n := len(i.links) // TODO: fix index length to avoid concurrency modification // TODO: run in parallel for j := 0; j < n; j++ { <-i.links[j].unlockSignal // wait till some operations done on this index currentSortedLinks := i.links[j].sortedLinks newSortedLinks := make(sortableCidNumbers, 0, len(currentSortedLinks)) for _, cidNumber := range currentSortedLinks { newRankedCid := RankedCidNumber{cidNumber.number, i.GetRankValue(cidNumber.number)} newSortedLinks = append(newSortedLinks, newRankedCid) } sort.Stable(sort.Reverse(newSortedLinks)) i.links[j].sortedLinks = newSortedLinks i.links[j].Unlock() } // same process for backlinks n = len(i.backlinks) for j := 0; j < n; j++ { <-i.backlinks[j].unlockSignal // wait till some operations done on this index currentSortedLinks := i.backlinks[j].sortedLinks newSortedLinks := make(sortableCidNumbers, 0, len(currentSortedLinks)) for _, cidNumber := range currentSortedLinks { newRankedCid := RankedCidNumber{cidNumber.number, i.GetRankValue(cidNumber.number)} newSortedLinks = append(newSortedLinks, newRankedCid) } sort.Stable(sort.Reverse(newSortedLinks)) i.backlinks[j].sortedLinks = newSortedLinks i.backlinks[j].Unlock() } } func (i *BaseSearchIndex) lock() { i.locked = true } func (i *BaseSearchIndex) unlock() { i.locked = false } func (i *BaseSearchIndex) checkIndexError() error { select { case err := <-i.errChan: return err default: } return nil } ================================================ FILE: x/rank/types/index_types.go ================================================ package types import ( "errors" graphtypes "github.com/cybercongress/go-cyber/v7/x/graph/types" ) type RankedCidNumber struct { number graphtypes.CidNumber rank uint64 } func (c RankedCidNumber) GetNumber() graphtypes.CidNumber { return c.number } func (c RankedCidNumber) GetRank() uint64 { return c.rank } // Local type for sorting type CidLinks struct { sortedLinks sortableCidNumbers unlockSignal chan struct{} } func NewCidLinks() CidLinks { return CidLinks{ sortedLinks: make(sortableCidNumbers, 0), unlockSignal: make(chan struct{}, 1), } } type sortableCidNumbers []RankedCidNumber // Sort Interface functions func (links sortableCidNumbers) Len() int { return len(links) } func (links sortableCidNumbers) Less(i, j int) bool { return links[i].rank < links[j].rank } func (links sortableCidNumbers) Swap(i, j int) { links[i], links[j] = links[j], links[i] } // Send unlock signal so others could operate on this index func (links CidLinks) Unlock() { links.unlockSignal <- struct{}{} } type GetError func() error type SearchIndex interface { Run() GetError Load(links graphtypes.Links) Search(cidNumber graphtypes.CidNumber, page, perPage uint32) ([]RankedCidNumber, uint32, error) Backlinks(cidNumber graphtypes.CidNumber, page, perPage uint32) ([]RankedCidNumber, uint32, error) Top(page, perPage uint32) ([]RankedCidNumber, uint32, error) GetRankValue(cidNumber graphtypes.CidNumber) uint64 PutNewLinks(links []graphtypes.CompactLink) PutNewRank(rank Rank) } type NoopSearchIndex struct{} func (i NoopSearchIndex) Run() GetError { return func() error { return nil } } func (i NoopSearchIndex) Load(links graphtypes.Links) {} func (i NoopSearchIndex) Search(cidNumber graphtypes.CidNumber, page, perPage uint32) ([]RankedCidNumber, uint32, error) { return nil, 0, errors.New("the search API is not enabled on this node") } func (i NoopSearchIndex) Backlinks(cidNumber graphtypes.CidNumber, page, perPage uint32) ([]RankedCidNumber, uint32, error) { return nil, 0, errors.New("the search API is not enabled on this node") } func (i NoopSearchIndex) Top(page, perPage uint32) ([]RankedCidNumber, uint32, error) { return nil, 0, errors.New("the search API is not enabled on this node") } func (i NoopSearchIndex) PutNewLinks(links []graphtypes.CompactLink) {} func (i NoopSearchIndex) PutNewRank(rank Rank) {} func (i NoopSearchIndex) GetRankValue(cidNumber graphtypes.CidNumber) uint64 { return 0 } ================================================ FILE: x/rank/types/keys.go ================================================ package types const ( ModuleName = "rank" StoreKey = ModuleName ) var ( GlobalStoreKeyPrefix = []byte{0x00} ParamsKey = []byte{0x01} LatestBlockNumber = append(GlobalStoreKeyPrefix, []byte("latestBlockNumber")...) LatestMerkleTree = append(GlobalStoreKeyPrefix, []byte("latestMerkleTree")...) NextMerkleTree = append(GlobalStoreKeyPrefix, []byte("nextMerkleTree")...) NextRankCidCount = append(GlobalStoreKeyPrefix, []byte("nextRankParticlesAmount")...) ContextCidCount = append(GlobalStoreKeyPrefix, []byte("contextParticlesAmount")...) ContextLinkCount = append(GlobalStoreKeyPrefix, []byte("contextLinkAmount")...) ) ================================================ FILE: x/rank/types/msgs.go ================================================ package types import ( errorsmod "cosmossdk.io/errors" sdk "github.com/cosmos/cosmos-sdk/types" ) var _ sdk.Msg = &MsgUpdateParams{} // GetSignBytes implements the LegacyMsg interface. func (m MsgUpdateParams) GetSignBytes() []byte { return sdk.MustSortJSON(ModuleCdc.MustMarshalJSON(&m)) } // GetSigners returns the expected signers for a MsgUpdateParams message. func (m *MsgUpdateParams) GetSigners() []sdk.AccAddress { addr, _ := sdk.AccAddressFromBech32(m.Authority) return []sdk.AccAddress{addr} } // ValidateBasic does a sanity check on the provided data. func (m *MsgUpdateParams) ValidateBasic() error { if _, err := sdk.AccAddressFromBech32(m.Authority); err != nil { return errorsmod.Wrap(err, "invalid authority address") } return m.Params.Validate() } ================================================ FILE: x/rank/types/pagination.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: cyber/rank/v1beta1/pagination.proto package types import ( fmt "fmt" io "io" math "math" math_bits "math/bits" proto "github.com/cosmos/gogoproto/proto" ) // Reference imports to suppress errors if they are not otherwise used. var ( _ = proto.Marshal _ = fmt.Errorf _ = math.Inf ) // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package type PageRequest struct { Page uint32 `protobuf:"varint,1,opt,name=page,proto3" json:"page,omitempty"` PerPage uint32 `protobuf:"varint,2,opt,name=per_page,json=perPage,proto3" json:"per_page,omitempty"` } func (m *PageRequest) Reset() { *m = PageRequest{} } func (m *PageRequest) String() string { return proto.CompactTextString(m) } func (*PageRequest) ProtoMessage() {} func (*PageRequest) Descriptor() ([]byte, []int) { return fileDescriptor_c6472f2c93262fe3, []int{0} } func (m *PageRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *PageRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_PageRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *PageRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_PageRequest.Merge(m, src) } func (m *PageRequest) XXX_Size() int { return m.Size() } func (m *PageRequest) XXX_DiscardUnknown() { xxx_messageInfo_PageRequest.DiscardUnknown(m) } var xxx_messageInfo_PageRequest proto.InternalMessageInfo func (m *PageRequest) GetPage() uint32 { if m != nil { return m.Page } return 0 } func (m *PageRequest) GetPerPage() uint32 { if m != nil { return m.PerPage } return 0 } type PageResponse struct { Total uint32 `protobuf:"varint,1,opt,name=total,proto3" json:"total,omitempty"` } func (m *PageResponse) Reset() { *m = PageResponse{} } func (m *PageResponse) String() string { return proto.CompactTextString(m) } func (*PageResponse) ProtoMessage() {} func (*PageResponse) Descriptor() ([]byte, []int) { return fileDescriptor_c6472f2c93262fe3, []int{1} } func (m *PageResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *PageResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_PageResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *PageResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_PageResponse.Merge(m, src) } func (m *PageResponse) XXX_Size() int { return m.Size() } func (m *PageResponse) XXX_DiscardUnknown() { xxx_messageInfo_PageResponse.DiscardUnknown(m) } var xxx_messageInfo_PageResponse proto.InternalMessageInfo func (m *PageResponse) GetTotal() uint32 { if m != nil { return m.Total } return 0 } func init() { proto.RegisterType((*PageRequest)(nil), "cyber.rank.v1beta1.PageRequest") proto.RegisterType((*PageResponse)(nil), "cyber.rank.v1beta1.PageResponse") } func init() { proto.RegisterFile("cyber/rank/v1beta1/pagination.proto", fileDescriptor_c6472f2c93262fe3) } var fileDescriptor_c6472f2c93262fe3 = []byte{ // 214 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x2c, 0x8f, 0xbd, 0x4a, 0xc0, 0x30, 0x14, 0x46, 0x1b, 0xf1, 0x8f, 0xa8, 0x4b, 0x70, 0xd0, 0x25, 0x48, 0x75, 0x70, 0x31, 0xa1, 0xb8, 0x3a, 0x39, 0x39, 0x4a, 0x47, 0x17, 0x49, 0xca, 0x25, 0x16, 0x35, 0x37, 0x26, 0xb7, 0x62, 0xdf, 0xc2, 0xc7, 0x72, 0xec, 0xe8, 0x28, 0xed, 0x8b, 0x48, 0x93, 0x6e, 0xc9, 0xc7, 0x39, 0x70, 0x0f, 0xbf, 0xec, 0x46, 0x0b, 0x51, 0x47, 0xe3, 0x5f, 0xf5, 0x67, 0x63, 0x81, 0x4c, 0xa3, 0x83, 0x71, 0xbd, 0x37, 0xd4, 0xa3, 0x57, 0x21, 0x22, 0xa1, 0x10, 0x19, 0x52, 0x2b, 0xa4, 0x36, 0xa8, 0xbe, 0xe3, 0x47, 0x8f, 0xc6, 0x41, 0x0b, 0x1f, 0x03, 0x24, 0x12, 0x82, 0xef, 0x06, 0xe3, 0xe0, 0x8c, 0x5d, 0xb0, 0xeb, 0x93, 0x36, 0xbf, 0xc5, 0x39, 0x3f, 0x0c, 0x10, 0x9f, 0xf3, 0xbe, 0x93, 0xf7, 0x83, 0x00, 0x71, 0xb5, 0xea, 0x2b, 0x7e, 0x5c, 0xec, 0x14, 0xd0, 0x27, 0x10, 0xa7, 0x7c, 0x8f, 0x90, 0xcc, 0xdb, 0xe6, 0x97, 0xcf, 0xfd, 0xc3, 0xcf, 0x2c, 0xd9, 0x34, 0x4b, 0xf6, 0x37, 0x4b, 0xf6, 0xbd, 0xc8, 0x6a, 0x5a, 0x64, 0xf5, 0xbb, 0xc8, 0xea, 0x49, 0xb9, 0x9e, 0x5e, 0x06, 0xab, 0x3a, 0x7c, 0xd7, 0xf9, 0xb8, 0x0e, 0xbd, 0x8b, 0x90, 0x92, 0x76, 0x78, 0x53, 0x92, 0xbe, 0x4a, 0x14, 0x8d, 0x01, 0x92, 0xdd, 0xcf, 0x21, 0xb7, 0xff, 0x01, 0x00, 0x00, 0xff, 0xff, 0x15, 0x7d, 0x86, 0xe3, 0xef, 0x00, 0x00, 0x00, } func (m *PageRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *PageRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *PageRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.PerPage != 0 { i = encodeVarintPagination(dAtA, i, uint64(m.PerPage)) i-- dAtA[i] = 0x10 } if m.Page != 0 { i = encodeVarintPagination(dAtA, i, uint64(m.Page)) i-- dAtA[i] = 0x8 } return len(dAtA) - i, nil } func (m *PageResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *PageResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *PageResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.Total != 0 { i = encodeVarintPagination(dAtA, i, uint64(m.Total)) i-- dAtA[i] = 0x8 } return len(dAtA) - i, nil } func encodeVarintPagination(dAtA []byte, offset int, v uint64) int { offset -= sovPagination(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *PageRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.Page != 0 { n += 1 + sovPagination(uint64(m.Page)) } if m.PerPage != 0 { n += 1 + sovPagination(uint64(m.PerPage)) } return n } func (m *PageResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.Total != 0 { n += 1 + sovPagination(uint64(m.Total)) } return n } func sovPagination(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozPagination(x uint64) (n int) { return sovPagination(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *PageRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowPagination } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: PageRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: PageRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field Page", wireType) } m.Page = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowPagination } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.Page |= uint32(b&0x7F) << shift if b < 0x80 { break } } case 2: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field PerPage", wireType) } m.PerPage = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowPagination } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.PerPage |= uint32(b&0x7F) << shift if b < 0x80 { break } } default: iNdEx = preIndex skippy, err := skipPagination(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthPagination } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *PageResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowPagination } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: PageResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: PageResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field Total", wireType) } m.Total = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowPagination } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.Total |= uint32(b&0x7F) << shift if b < 0x80 { break } } default: iNdEx = preIndex skippy, err := skipPagination(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthPagination } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipPagination(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowPagination } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowPagination } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowPagination } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthPagination } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupPagination } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthPagination } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthPagination = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowPagination = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupPagination = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/rank/types/params.go ================================================ package types import ( "fmt" sdk "github.com/cosmos/cosmos-sdk/types" ) func DefaultParams() Params { return Params{ CalculationPeriod: int64(5), DampingFactor: sdk.NewDecWithPrec(85, 2), Tolerance: sdk.NewDecWithPrec(1, 3), } } func (p Params) Validate() error { if err := validateCalculationPeriod(p.CalculationPeriod); err != nil { return err } if err := validateDampingFactor(p.DampingFactor); err != nil { return err } if err := validateTolerance(p.Tolerance); err != nil { return err } return nil } func validateCalculationPeriod(i interface{}) error { v, ok := i.(int64) if !ok { return fmt.Errorf("invalid parameter type: %T", i) } if v < int64(5) { return fmt.Errorf("calculation period should be equal or more than 5 blocks: %d", v) } return nil } func validateDampingFactor(i interface{}) error { v, ok := i.(sdk.Dec) if !ok { return fmt.Errorf("invalid parameter type: %T", i) } if v.LTE(sdk.NewDecWithPrec(7, 1)) { return fmt.Errorf("damping factor should be equal or more than 0.7: %s", v) } if v.GTE(sdk.NewDecWithPrec(9, 1)) { return fmt.Errorf("damping factor should be equal or less than 0.9: %s", v) } return nil } func validateTolerance(i interface{}) error { v, ok := i.(sdk.Dec) if !ok { return fmt.Errorf("invalid parameter type: %T", i) } if v.GT(sdk.NewDecWithPrec(1, 3)) { return fmt.Errorf("tolerance is too low: %s", v) } if v.LT(sdk.NewDecWithPrec(1, 5)) { return fmt.Errorf("tolerance is too big: %s", v) } return nil } ================================================ FILE: x/rank/types/params_legacy.go ================================================ package types import paramstypes "github.com/cosmos/cosmos-sdk/x/params/types" var ( KeyCalculationPeriod = []byte("CalculationPeriod") KeyDampingFactor = []byte("DampingFactor") KeyTolerance = []byte("Tolerance") ) // Deprecated: Type declaration for parameters func ParamKeyTable() paramstypes.KeyTable { return paramstypes.NewKeyTable().RegisterParamSet(&Params{}) } func (p *Params) ParamSetPairs() paramstypes.ParamSetPairs { return paramstypes.ParamSetPairs{ paramstypes.NewParamSetPair(KeyCalculationPeriod, &p.CalculationPeriod, validateCalculationPeriod), paramstypes.NewParamSetPair(KeyDampingFactor, &p.DampingFactor, validateDampingFactor), paramstypes.NewParamSetPair(KeyTolerance, &p.Tolerance, validateTolerance), } } ================================================ FILE: x/rank/types/querier.go ================================================ package types import sdk "github.com/cosmos/cosmos-sdk/types" const ( QueryParameters = "params" QueryRank = "rank" QuerySearch = "search" QueryBacklinks = "backlinks" QueryTop = "top" QueryIsLinkExist = "is_link_exist" QueryIsAnyLinkExist = "is_any_link_exist" ) type QueryRankParams struct { Cid string } func NewQueryRankParams(cid string) QueryRankParams { return QueryRankParams{cid} } type QuerySearchParams struct { Cid string Page, PerPage uint32 } func NewQuerySearchParams(cid string, page, perPage uint32) QuerySearchParams { return QuerySearchParams{cid, page, perPage} } type QueryTopParams struct { Page, PerPage uint32 } func NewQueryTopParams(page, perPage uint32) QueryTopParams { return QueryTopParams{page, perPage} } type QueryIsLinkExistParams struct { From, To string Address sdk.AccAddress } func NewQueryIsLinkExistParams(from, to string, account sdk.AccAddress) QueryIsLinkExistParams { return QueryIsLinkExistParams{from, to, account} } type QueryIsAnyLinkExistParams struct { From, To string } func NewQueryIsAnyLinkExistParams(from, to string) QueryIsAnyLinkExistParams { return QueryIsAnyLinkExistParams{from, to} } ================================================ FILE: x/rank/types/query.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: cyber/rank/v1beta1/query.proto package types import ( context "context" fmt "fmt" io "io" math "math" math_bits "math/bits" _ "github.com/cosmos/gogoproto/gogoproto" grpc1 "github.com/cosmos/gogoproto/grpc" proto "github.com/cosmos/gogoproto/proto" _ "google.golang.org/genproto/googleapis/api/annotations" grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" ) // Reference imports to suppress errors if they are not otherwise used. var ( _ = proto.Marshal _ = fmt.Errorf _ = math.Inf ) // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package type QueryParamsRequest struct{} func (m *QueryParamsRequest) Reset() { *m = QueryParamsRequest{} } func (m *QueryParamsRequest) String() string { return proto.CompactTextString(m) } func (*QueryParamsRequest) ProtoMessage() {} func (*QueryParamsRequest) Descriptor() ([]byte, []int) { return fileDescriptor_f72c23904714eae6, []int{0} } func (m *QueryParamsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryParamsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryParamsRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryParamsRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryParamsRequest.Merge(m, src) } func (m *QueryParamsRequest) XXX_Size() int { return m.Size() } func (m *QueryParamsRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryParamsRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryParamsRequest proto.InternalMessageInfo type QueryParamsResponse struct { Params Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params"` } func (m *QueryParamsResponse) Reset() { *m = QueryParamsResponse{} } func (m *QueryParamsResponse) String() string { return proto.CompactTextString(m) } func (*QueryParamsResponse) ProtoMessage() {} func (*QueryParamsResponse) Descriptor() ([]byte, []int) { return fileDescriptor_f72c23904714eae6, []int{1} } func (m *QueryParamsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryParamsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryParamsResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryParamsResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryParamsResponse.Merge(m, src) } func (m *QueryParamsResponse) XXX_Size() int { return m.Size() } func (m *QueryParamsResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryParamsResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryParamsResponse proto.InternalMessageInfo func (m *QueryParamsResponse) GetParams() Params { if m != nil { return m.Params } return Params{} } type QueryRankRequest struct { Particle string `protobuf:"bytes,1,opt,name=particle,proto3" json:"particle,omitempty"` } func (m *QueryRankRequest) Reset() { *m = QueryRankRequest{} } func (m *QueryRankRequest) String() string { return proto.CompactTextString(m) } func (*QueryRankRequest) ProtoMessage() {} func (*QueryRankRequest) Descriptor() ([]byte, []int) { return fileDescriptor_f72c23904714eae6, []int{2} } func (m *QueryRankRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryRankRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryRankRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryRankRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryRankRequest.Merge(m, src) } func (m *QueryRankRequest) XXX_Size() int { return m.Size() } func (m *QueryRankRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryRankRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryRankRequest proto.InternalMessageInfo func (m *QueryRankRequest) GetParticle() string { if m != nil { return m.Particle } return "" } type QueryRankResponse struct { Rank uint64 `protobuf:"varint,1,opt,name=rank,proto3" json:"rank,omitempty"` } func (m *QueryRankResponse) Reset() { *m = QueryRankResponse{} } func (m *QueryRankResponse) String() string { return proto.CompactTextString(m) } func (*QueryRankResponse) ProtoMessage() {} func (*QueryRankResponse) Descriptor() ([]byte, []int) { return fileDescriptor_f72c23904714eae6, []int{3} } func (m *QueryRankResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryRankResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryRankResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryRankResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryRankResponse.Merge(m, src) } func (m *QueryRankResponse) XXX_Size() int { return m.Size() } func (m *QueryRankResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryRankResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryRankResponse proto.InternalMessageInfo func (m *QueryRankResponse) GetRank() uint64 { if m != nil { return m.Rank } return 0 } type QuerySearchRequest struct { Particle string `protobuf:"bytes,1,opt,name=particle,proto3" json:"particle,omitempty"` Pagination *PageRequest `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` } func (m *QuerySearchRequest) Reset() { *m = QuerySearchRequest{} } func (m *QuerySearchRequest) String() string { return proto.CompactTextString(m) } func (*QuerySearchRequest) ProtoMessage() {} func (*QuerySearchRequest) Descriptor() ([]byte, []int) { return fileDescriptor_f72c23904714eae6, []int{4} } func (m *QuerySearchRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QuerySearchRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QuerySearchRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QuerySearchRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QuerySearchRequest.Merge(m, src) } func (m *QuerySearchRequest) XXX_Size() int { return m.Size() } func (m *QuerySearchRequest) XXX_DiscardUnknown() { xxx_messageInfo_QuerySearchRequest.DiscardUnknown(m) } var xxx_messageInfo_QuerySearchRequest proto.InternalMessageInfo func (m *QuerySearchRequest) GetParticle() string { if m != nil { return m.Particle } return "" } func (m *QuerySearchRequest) GetPagination() *PageRequest { if m != nil { return m.Pagination } return nil } type QuerySearchResponse struct { Result []RankedParticle `protobuf:"bytes,1,rep,name=result,proto3" json:"result"` Pagination *PageResponse `protobuf:"bytes,2,opt,name=pagination,proto3" json:"pagination,omitempty"` } func (m *QuerySearchResponse) Reset() { *m = QuerySearchResponse{} } func (m *QuerySearchResponse) String() string { return proto.CompactTextString(m) } func (*QuerySearchResponse) ProtoMessage() {} func (*QuerySearchResponse) Descriptor() ([]byte, []int) { return fileDescriptor_f72c23904714eae6, []int{5} } func (m *QuerySearchResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QuerySearchResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QuerySearchResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QuerySearchResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QuerySearchResponse.Merge(m, src) } func (m *QuerySearchResponse) XXX_Size() int { return m.Size() } func (m *QuerySearchResponse) XXX_DiscardUnknown() { xxx_messageInfo_QuerySearchResponse.DiscardUnknown(m) } var xxx_messageInfo_QuerySearchResponse proto.InternalMessageInfo func (m *QuerySearchResponse) GetResult() []RankedParticle { if m != nil { return m.Result } return nil } func (m *QuerySearchResponse) GetPagination() *PageResponse { if m != nil { return m.Pagination } return nil } type QueryTopRequest struct { Pagination *PageRequest `protobuf:"bytes,1,opt,name=pagination,proto3" json:"pagination,omitempty"` } func (m *QueryTopRequest) Reset() { *m = QueryTopRequest{} } func (m *QueryTopRequest) String() string { return proto.CompactTextString(m) } func (*QueryTopRequest) ProtoMessage() {} func (*QueryTopRequest) Descriptor() ([]byte, []int) { return fileDescriptor_f72c23904714eae6, []int{6} } func (m *QueryTopRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryTopRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryTopRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryTopRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryTopRequest.Merge(m, src) } func (m *QueryTopRequest) XXX_Size() int { return m.Size() } func (m *QueryTopRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryTopRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryTopRequest proto.InternalMessageInfo func (m *QueryTopRequest) GetPagination() *PageRequest { if m != nil { return m.Pagination } return nil } type QueryIsLinkExistRequest struct { From string `protobuf:"bytes,1,opt,name=from,proto3" json:"from,omitempty"` To string `protobuf:"bytes,2,opt,name=to,proto3" json:"to,omitempty"` Address string `protobuf:"bytes,3,opt,name=address,proto3" json:"address,omitempty"` } func (m *QueryIsLinkExistRequest) Reset() { *m = QueryIsLinkExistRequest{} } func (m *QueryIsLinkExistRequest) String() string { return proto.CompactTextString(m) } func (*QueryIsLinkExistRequest) ProtoMessage() {} func (*QueryIsLinkExistRequest) Descriptor() ([]byte, []int) { return fileDescriptor_f72c23904714eae6, []int{7} } func (m *QueryIsLinkExistRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryIsLinkExistRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryIsLinkExistRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryIsLinkExistRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryIsLinkExistRequest.Merge(m, src) } func (m *QueryIsLinkExistRequest) XXX_Size() int { return m.Size() } func (m *QueryIsLinkExistRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryIsLinkExistRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryIsLinkExistRequest proto.InternalMessageInfo func (m *QueryIsLinkExistRequest) GetFrom() string { if m != nil { return m.From } return "" } func (m *QueryIsLinkExistRequest) GetTo() string { if m != nil { return m.To } return "" } func (m *QueryIsLinkExistRequest) GetAddress() string { if m != nil { return m.Address } return "" } type QueryIsAnyLinkExistRequest struct { From string `protobuf:"bytes,1,opt,name=from,proto3" json:"from,omitempty"` To string `protobuf:"bytes,2,opt,name=to,proto3" json:"to,omitempty"` } func (m *QueryIsAnyLinkExistRequest) Reset() { *m = QueryIsAnyLinkExistRequest{} } func (m *QueryIsAnyLinkExistRequest) String() string { return proto.CompactTextString(m) } func (*QueryIsAnyLinkExistRequest) ProtoMessage() {} func (*QueryIsAnyLinkExistRequest) Descriptor() ([]byte, []int) { return fileDescriptor_f72c23904714eae6, []int{8} } func (m *QueryIsAnyLinkExistRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryIsAnyLinkExistRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryIsAnyLinkExistRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryIsAnyLinkExistRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryIsAnyLinkExistRequest.Merge(m, src) } func (m *QueryIsAnyLinkExistRequest) XXX_Size() int { return m.Size() } func (m *QueryIsAnyLinkExistRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryIsAnyLinkExistRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryIsAnyLinkExistRequest proto.InternalMessageInfo func (m *QueryIsAnyLinkExistRequest) GetFrom() string { if m != nil { return m.From } return "" } func (m *QueryIsAnyLinkExistRequest) GetTo() string { if m != nil { return m.To } return "" } type QueryLinkExistResponse struct { Exist bool `protobuf:"varint,1,opt,name=exist,proto3" json:"exist,omitempty"` } func (m *QueryLinkExistResponse) Reset() { *m = QueryLinkExistResponse{} } func (m *QueryLinkExistResponse) String() string { return proto.CompactTextString(m) } func (*QueryLinkExistResponse) ProtoMessage() {} func (*QueryLinkExistResponse) Descriptor() ([]byte, []int) { return fileDescriptor_f72c23904714eae6, []int{9} } func (m *QueryLinkExistResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryLinkExistResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryLinkExistResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryLinkExistResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryLinkExistResponse.Merge(m, src) } func (m *QueryLinkExistResponse) XXX_Size() int { return m.Size() } func (m *QueryLinkExistResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryLinkExistResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryLinkExistResponse proto.InternalMessageInfo func (m *QueryLinkExistResponse) GetExist() bool { if m != nil { return m.Exist } return false } type QueryNegentropyPartilceRequest struct { Particle string `protobuf:"bytes,1,opt,name=particle,proto3" json:"particle,omitempty"` } func (m *QueryNegentropyPartilceRequest) Reset() { *m = QueryNegentropyPartilceRequest{} } func (m *QueryNegentropyPartilceRequest) String() string { return proto.CompactTextString(m) } func (*QueryNegentropyPartilceRequest) ProtoMessage() {} func (*QueryNegentropyPartilceRequest) Descriptor() ([]byte, []int) { return fileDescriptor_f72c23904714eae6, []int{10} } func (m *QueryNegentropyPartilceRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryNegentropyPartilceRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryNegentropyPartilceRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryNegentropyPartilceRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryNegentropyPartilceRequest.Merge(m, src) } func (m *QueryNegentropyPartilceRequest) XXX_Size() int { return m.Size() } func (m *QueryNegentropyPartilceRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryNegentropyPartilceRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryNegentropyPartilceRequest proto.InternalMessageInfo func (m *QueryNegentropyPartilceRequest) GetParticle() string { if m != nil { return m.Particle } return "" } type QueryNegentropyParticleResponse struct { Entropy uint64 `protobuf:"varint,1,opt,name=entropy,proto3" json:"entropy,omitempty"` } func (m *QueryNegentropyParticleResponse) Reset() { *m = QueryNegentropyParticleResponse{} } func (m *QueryNegentropyParticleResponse) String() string { return proto.CompactTextString(m) } func (*QueryNegentropyParticleResponse) ProtoMessage() {} func (*QueryNegentropyParticleResponse) Descriptor() ([]byte, []int) { return fileDescriptor_f72c23904714eae6, []int{11} } func (m *QueryNegentropyParticleResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryNegentropyParticleResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryNegentropyParticleResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryNegentropyParticleResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryNegentropyParticleResponse.Merge(m, src) } func (m *QueryNegentropyParticleResponse) XXX_Size() int { return m.Size() } func (m *QueryNegentropyParticleResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryNegentropyParticleResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryNegentropyParticleResponse proto.InternalMessageInfo func (m *QueryNegentropyParticleResponse) GetEntropy() uint64 { if m != nil { return m.Entropy } return 0 } type QueryNegentropyRequest struct{} func (m *QueryNegentropyRequest) Reset() { *m = QueryNegentropyRequest{} } func (m *QueryNegentropyRequest) String() string { return proto.CompactTextString(m) } func (*QueryNegentropyRequest) ProtoMessage() {} func (*QueryNegentropyRequest) Descriptor() ([]byte, []int) { return fileDescriptor_f72c23904714eae6, []int{12} } func (m *QueryNegentropyRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryNegentropyRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryNegentropyRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryNegentropyRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryNegentropyRequest.Merge(m, src) } func (m *QueryNegentropyRequest) XXX_Size() int { return m.Size() } func (m *QueryNegentropyRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryNegentropyRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryNegentropyRequest proto.InternalMessageInfo type QueryNegentropyResponse struct { Negentropy uint64 `protobuf:"varint,1,opt,name=negentropy,proto3" json:"negentropy,omitempty"` } func (m *QueryNegentropyResponse) Reset() { *m = QueryNegentropyResponse{} } func (m *QueryNegentropyResponse) String() string { return proto.CompactTextString(m) } func (*QueryNegentropyResponse) ProtoMessage() {} func (*QueryNegentropyResponse) Descriptor() ([]byte, []int) { return fileDescriptor_f72c23904714eae6, []int{13} } func (m *QueryNegentropyResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryNegentropyResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryNegentropyResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryNegentropyResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryNegentropyResponse.Merge(m, src) } func (m *QueryNegentropyResponse) XXX_Size() int { return m.Size() } func (m *QueryNegentropyResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryNegentropyResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryNegentropyResponse proto.InternalMessageInfo func (m *QueryNegentropyResponse) GetNegentropy() uint64 { if m != nil { return m.Negentropy } return 0 } type QueryKarmaRequest struct { Neuron string `protobuf:"bytes,1,opt,name=neuron,proto3" json:"neuron,omitempty"` } func (m *QueryKarmaRequest) Reset() { *m = QueryKarmaRequest{} } func (m *QueryKarmaRequest) String() string { return proto.CompactTextString(m) } func (*QueryKarmaRequest) ProtoMessage() {} func (*QueryKarmaRequest) Descriptor() ([]byte, []int) { return fileDescriptor_f72c23904714eae6, []int{14} } func (m *QueryKarmaRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryKarmaRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryKarmaRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryKarmaRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryKarmaRequest.Merge(m, src) } func (m *QueryKarmaRequest) XXX_Size() int { return m.Size() } func (m *QueryKarmaRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryKarmaRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryKarmaRequest proto.InternalMessageInfo func (m *QueryKarmaRequest) GetNeuron() string { if m != nil { return m.Neuron } return "" } type QueryKarmaResponse struct { Karma uint64 `protobuf:"varint,1,opt,name=karma,proto3" json:"karma,omitempty"` } func (m *QueryKarmaResponse) Reset() { *m = QueryKarmaResponse{} } func (m *QueryKarmaResponse) String() string { return proto.CompactTextString(m) } func (*QueryKarmaResponse) ProtoMessage() {} func (*QueryKarmaResponse) Descriptor() ([]byte, []int) { return fileDescriptor_f72c23904714eae6, []int{15} } func (m *QueryKarmaResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryKarmaResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryKarmaResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryKarmaResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryKarmaResponse.Merge(m, src) } func (m *QueryKarmaResponse) XXX_Size() int { return m.Size() } func (m *QueryKarmaResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryKarmaResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryKarmaResponse proto.InternalMessageInfo func (m *QueryKarmaResponse) GetKarma() uint64 { if m != nil { return m.Karma } return 0 } func init() { proto.RegisterType((*QueryParamsRequest)(nil), "cyber.rank.v1beta1.QueryParamsRequest") proto.RegisterType((*QueryParamsResponse)(nil), "cyber.rank.v1beta1.QueryParamsResponse") proto.RegisterType((*QueryRankRequest)(nil), "cyber.rank.v1beta1.QueryRankRequest") proto.RegisterType((*QueryRankResponse)(nil), "cyber.rank.v1beta1.QueryRankResponse") proto.RegisterType((*QuerySearchRequest)(nil), "cyber.rank.v1beta1.QuerySearchRequest") proto.RegisterType((*QuerySearchResponse)(nil), "cyber.rank.v1beta1.QuerySearchResponse") proto.RegisterType((*QueryTopRequest)(nil), "cyber.rank.v1beta1.QueryTopRequest") proto.RegisterType((*QueryIsLinkExistRequest)(nil), "cyber.rank.v1beta1.QueryIsLinkExistRequest") proto.RegisterType((*QueryIsAnyLinkExistRequest)(nil), "cyber.rank.v1beta1.QueryIsAnyLinkExistRequest") proto.RegisterType((*QueryLinkExistResponse)(nil), "cyber.rank.v1beta1.QueryLinkExistResponse") proto.RegisterType((*QueryNegentropyPartilceRequest)(nil), "cyber.rank.v1beta1.QueryNegentropyPartilceRequest") proto.RegisterType((*QueryNegentropyParticleResponse)(nil), "cyber.rank.v1beta1.QueryNegentropyParticleResponse") proto.RegisterType((*QueryNegentropyRequest)(nil), "cyber.rank.v1beta1.QueryNegentropyRequest") proto.RegisterType((*QueryNegentropyResponse)(nil), "cyber.rank.v1beta1.QueryNegentropyResponse") proto.RegisterType((*QueryKarmaRequest)(nil), "cyber.rank.v1beta1.QueryKarmaRequest") proto.RegisterType((*QueryKarmaResponse)(nil), "cyber.rank.v1beta1.QueryKarmaResponse") } func init() { proto.RegisterFile("cyber/rank/v1beta1/query.proto", fileDescriptor_f72c23904714eae6) } var fileDescriptor_f72c23904714eae6 = []byte{ // 890 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x96, 0x51, 0x8b, 0xe3, 0x54, 0x14, 0xc7, 0x9b, 0x4e, 0xa7, 0x6e, 0x4f, 0x61, 0xd5, 0xe3, 0xb0, 0x96, 0xb0, 0xa4, 0xdd, 0x3b, 0xb3, 0xd3, 0xd9, 0xd6, 0x49, 0x9c, 0x2e, 0x82, 0xa2, 0xe0, 0x38, 0x20, 0x28, 0x8a, 0xae, 0x71, 0x41, 0xf0, 0x65, 0xb9, 0xcd, 0x5c, 0xb3, 0xa1, 0x6d, 0x6e, 0x26, 0x49, 0x65, 0xcb, 0xb2, 0x2f, 0x0b, 0x3e, 0x0a, 0xca, 0x3e, 0x89, 0x1f, 0x42, 0x3f, 0xc6, 0x3c, 0x0e, 0xf8, 0xe2, 0x93, 0xc8, 0x8c, 0x1f, 0x44, 0x72, 0x72, 0x33, 0x4d, 0x6d, 0xd2, 0xe9, 0xc8, 0xbe, 0x0c, 0xb9, 0xf7, 0x9c, 0xf3, 0x3f, 0xbf, 0x7b, 0x92, 0xfb, 0x9f, 0x82, 0xe1, 0xcc, 0x86, 0x22, 0xb4, 0x42, 0xee, 0x8f, 0xac, 0xef, 0x0f, 0x86, 0x22, 0xe6, 0x07, 0xd6, 0xc9, 0x54, 0x84, 0x33, 0x33, 0x08, 0x65, 0x2c, 0x11, 0x29, 0x6e, 0x26, 0x71, 0x53, 0xc5, 0xf5, 0x2d, 0x57, 0xba, 0x92, 0xc2, 0x56, 0xf2, 0x94, 0x66, 0xea, 0xb7, 0x5d, 0x29, 0xdd, 0xb1, 0xb0, 0x78, 0xe0, 0x59, 0xdc, 0xf7, 0x65, 0xcc, 0x63, 0x4f, 0xfa, 0x91, 0x8a, 0x16, 0xf5, 0x89, 0x67, 0x81, 0xc8, 0xe2, 0xdb, 0x05, 0xf1, 0x80, 0xbb, 0x9e, 0x4f, 0x2a, 0x69, 0x12, 0xdb, 0x02, 0xfc, 0x2a, 0x61, 0x7b, 0xc0, 0x43, 0x3e, 0x89, 0x6c, 0x71, 0x32, 0x15, 0x51, 0xcc, 0xbe, 0x84, 0x37, 0x16, 0x76, 0xa3, 0x40, 0xfa, 0x91, 0xc0, 0x77, 0xa1, 0x1e, 0xd0, 0x4e, 0x4b, 0xeb, 0x68, 0x7b, 0xcd, 0x81, 0x6e, 0x2e, 0x1f, 0xc5, 0x4c, 0x6b, 0x8e, 0x6a, 0xa7, 0x7f, 0xb5, 0x2b, 0xb6, 0xca, 0x67, 0x26, 0xbc, 0x46, 0x82, 0x36, 0xf7, 0x47, 0xaa, 0x09, 0xea, 0x70, 0x23, 0xe0, 0x61, 0xec, 0x39, 0x63, 0x41, 0x7a, 0x0d, 0xfb, 0x72, 0xcd, 0xba, 0xf0, 0x7a, 0x2e, 0x5f, 0xb5, 0x47, 0xa8, 0x25, 0x9d, 0x28, 0xb9, 0x66, 0xd3, 0x33, 0x3b, 0x51, 0xfc, 0x5f, 0x0b, 0x1e, 0x3a, 0x8f, 0xd7, 0x90, 0xc6, 0x0f, 0x01, 0xe6, 0x53, 0x68, 0x55, 0xe9, 0x20, 0xed, 0xe2, 0x83, 0xb8, 0x42, 0x09, 0xda, 0xb9, 0x12, 0xf6, 0x8b, 0xa6, 0xa6, 0x93, 0xf5, 0x54, 0x78, 0x87, 0x50, 0x0f, 0x45, 0x34, 0x1d, 0xc7, 0x2d, 0xad, 0xb3, 0xb1, 0xd7, 0x1c, 0xb0, 0x22, 0xd1, 0xe4, 0x40, 0xe2, 0xf8, 0x81, 0x82, 0xc9, 0xa6, 0x94, 0xd6, 0xe1, 0x61, 0x01, 0x5a, 0xa7, 0x1c, 0x2d, 0xed, 0xbb, 0xc0, 0x66, 0xc3, 0xab, 0x84, 0xf6, 0x50, 0x06, 0xd9, 0x2c, 0x16, 0xcf, 0xab, 0x5d, 0xff, 0xbc, 0xdf, 0xc0, 0x9b, 0xa4, 0xf9, 0x69, 0xf4, 0xb9, 0xe7, 0x8f, 0x3e, 0x7e, 0xe2, 0x45, 0x71, 0xa6, 0x8d, 0x50, 0xfb, 0x2e, 0x94, 0x13, 0x35, 0x63, 0x7a, 0xc6, 0x9b, 0x50, 0x8d, 0x25, 0xc1, 0x37, 0xec, 0x6a, 0x2c, 0xb1, 0x05, 0xaf, 0xf0, 0xe3, 0xe3, 0x50, 0x44, 0x51, 0x6b, 0x83, 0x36, 0xb3, 0x25, 0x3b, 0x04, 0x5d, 0x09, 0x7f, 0xe4, 0xcf, 0xfe, 0x8f, 0x36, 0x33, 0xe1, 0x16, 0x29, 0xe4, 0x8a, 0xd5, 0xcb, 0xd8, 0x82, 0x4d, 0x91, 0x6c, 0x50, 0xf9, 0x0d, 0x3b, 0x5d, 0xb0, 0x0f, 0xc0, 0xa0, 0xfc, 0x2f, 0x84, 0x2b, 0xfc, 0x38, 0x94, 0xc1, 0x8c, 0xde, 0xc4, 0xd8, 0x11, 0xeb, 0x7c, 0x94, 0xef, 0x43, 0xbb, 0xa8, 0xda, 0x19, 0x5f, 0xbe, 0x8b, 0xe4, 0xb0, 0x2a, 0xa4, 0xbe, 0xd2, 0x6c, 0xc9, 0x5a, 0x0a, 0x75, 0x5e, 0x9c, 0x5d, 0xb6, 0xf7, 0xd4, 0x7c, 0xf3, 0x11, 0x25, 0x67, 0x00, 0xf8, 0x97, 0xbb, 0x4a, 0x31, 0xb7, 0xc3, 0xfa, 0xea, 0x9a, 0x7c, 0xc6, 0xc3, 0x09, 0xcf, 0x8e, 0x70, 0x0b, 0xea, 0xbe, 0x98, 0x86, 0xea, 0x65, 0x37, 0x6c, 0xb5, 0x62, 0x3d, 0x75, 0x55, 0x54, 0xf2, 0x7c, 0x50, 0xa3, 0x64, 0x43, 0xa9, 0xa7, 0x8b, 0xc1, 0x6f, 0x4d, 0xd8, 0xa4, 0x64, 0x7c, 0xae, 0x41, 0x3d, 0xbd, 0xd2, 0xb8, 0x5b, 0xf4, 0xd5, 0x2c, 0xbb, 0x87, 0xde, 0xbd, 0x32, 0x2f, 0xed, 0xcd, 0xba, 0xcf, 0xff, 0xf8, 0xe7, 0x45, 0xf5, 0x0e, 0xb6, 0xad, 0x02, 0xab, 0xa2, 0x45, 0x6a, 0x1f, 0xf8, 0x83, 0x06, 0xb5, 0xe4, 0xe6, 0xe0, 0x4e, 0xa9, 0x74, 0xce, 0x59, 0xf4, 0xbb, 0x57, 0x64, 0xa9, 0xf6, 0x6f, 0x53, 0xfb, 0x1e, 0xee, 0x95, 0xb6, 0xa7, 0x3f, 0x4f, 0xb3, 0x0f, 0xe0, 0x19, 0xfe, 0xa8, 0x41, 0x3d, 0xbd, 0xf5, 0x2b, 0x86, 0xb1, 0x60, 0x45, 0x2b, 0x86, 0xb1, 0x68, 0x1f, 0x6c, 0x40, 0x34, 0x6f, 0x61, 0xaf, 0x94, 0x26, 0xa2, 0x82, 0x3c, 0xcf, 0x0b, 0x0d, 0x1a, 0x47, 0xdc, 0x19, 0x8d, 0x3d, 0x7f, 0x14, 0xbd, 0x7c, 0xa4, 0x77, 0x08, 0xc9, 0xc2, 0xfd, 0x52, 0xa4, 0x61, 0xd6, 0x3c, 0x4f, 0x35, 0x83, 0x8d, 0x87, 0x32, 0xc0, 0xed, 0xd2, 0x36, 0x73, 0x77, 0x5a, 0x9f, 0x65, 0x87, 0x58, 0x0c, 0xbc, 0x5d, 0xca, 0x12, 0xcb, 0x00, 0x7f, 0xd6, 0xa0, 0x99, 0xf3, 0x29, 0xec, 0x97, 0xca, 0x2f, 0xbb, 0x99, 0xde, 0x2b, 0x4d, 0x5e, 0xf2, 0x17, 0x76, 0x8f, 0x70, 0xb6, 0xf1, 0x4e, 0x11, 0x8e, 0x17, 0x3d, 0x4a, 0x86, 0xf2, 0x88, 0x4c, 0x07, 0x7f, 0xd5, 0xe0, 0xe6, 0xa2, 0xc5, 0xa1, 0xb9, 0x02, 0xab, 0xc0, 0x0b, 0xaf, 0x45, 0xb6, 0x4f, 0x64, 0x5d, 0xbc, 0x5b, 0x42, 0xc6, 0xfd, 0x59, 0x9e, 0xee, 0x77, 0x0d, 0x30, 0xb3, 0xb1, 0xb9, 0x03, 0xe1, 0xa0, 0xb4, 0x63, 0xa9, 0x77, 0xea, 0xf7, 0xd7, 0xad, 0xc9, 0x39, 0x26, 0x3b, 0x20, 0xdc, 0x3e, 0xde, 0x2b, 0xc2, 0x9d, 0x5b, 0xdd, 0x7f, 0x6e, 0x21, 0xe4, 0x50, 0x7b, 0x6b, 0xb4, 0xcd, 0x10, 0xfb, 0x6b, 0xe5, 0x2a, 0xb4, 0x5d, 0x42, 0xeb, 0xa0, 0xb1, 0x1a, 0x2d, 0xb1, 0xc8, 0x4d, 0x32, 0x55, 0x2c, 0x37, 0x9e, 0xbc, 0x43, 0xeb, 0xbb, 0x57, 0xa5, 0x29, 0x80, 0x1e, 0x01, 0xec, 0x20, 0x2b, 0x02, 0x20, 0xa3, 0xb6, 0x9e, 0xa6, 0xe6, 0xfe, 0xec, 0xe8, 0x93, 0xd3, 0x73, 0x43, 0x3b, 0x3b, 0x37, 0xb4, 0xbf, 0xcf, 0x0d, 0xed, 0xa7, 0x0b, 0xa3, 0x72, 0x76, 0x61, 0x54, 0xfe, 0xbc, 0x30, 0x2a, 0xdf, 0x9a, 0xae, 0x17, 0x3f, 0x9e, 0x0e, 0x4d, 0x47, 0x4e, 0x52, 0x1d, 0x47, 0xfa, 0x6e, 0xf2, 0x0f, 0xd8, 0x72, 0xe5, 0x7e, 0x2a, 0xfc, 0x44, 0xdd, 0xa0, 0xe4, 0xd7, 0xe3, 0xb0, 0x4e, 0xbf, 0x0c, 0xef, 0xff, 0x1b, 0x00, 0x00, 0xff, 0xff, 0x7b, 0x7c, 0x05, 0xe7, 0xc8, 0x0a, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. var ( _ context.Context _ grpc.ClientConn ) // This is a compile-time assertion to ensure that this generated file // is compatible with the grpc package it is being compiled against. const _ = grpc.SupportPackageIsVersion4 // QueryClient is the client API for Query service. // // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. type QueryClient interface { Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) Rank(ctx context.Context, in *QueryRankRequest, opts ...grpc.CallOption) (*QueryRankResponse, error) Search(ctx context.Context, in *QuerySearchRequest, opts ...grpc.CallOption) (*QuerySearchResponse, error) Backlinks(ctx context.Context, in *QuerySearchRequest, opts ...grpc.CallOption) (*QuerySearchResponse, error) Top(ctx context.Context, in *QueryTopRequest, opts ...grpc.CallOption) (*QuerySearchResponse, error) IsLinkExist(ctx context.Context, in *QueryIsLinkExistRequest, opts ...grpc.CallOption) (*QueryLinkExistResponse, error) IsAnyLinkExist(ctx context.Context, in *QueryIsAnyLinkExistRequest, opts ...grpc.CallOption) (*QueryLinkExistResponse, error) ParticleNegentropy(ctx context.Context, in *QueryNegentropyPartilceRequest, opts ...grpc.CallOption) (*QueryNegentropyParticleResponse, error) Negentropy(ctx context.Context, in *QueryNegentropyRequest, opts ...grpc.CallOption) (*QueryNegentropyResponse, error) Karma(ctx context.Context, in *QueryKarmaRequest, opts ...grpc.CallOption) (*QueryKarmaResponse, error) } type queryClient struct { cc grpc1.ClientConn } func NewQueryClient(cc grpc1.ClientConn) QueryClient { return &queryClient{cc} } func (c *queryClient) Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) { out := new(QueryParamsResponse) err := c.cc.Invoke(ctx, "/cyber.rank.v1beta1.Query/Params", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) Rank(ctx context.Context, in *QueryRankRequest, opts ...grpc.CallOption) (*QueryRankResponse, error) { out := new(QueryRankResponse) err := c.cc.Invoke(ctx, "/cyber.rank.v1beta1.Query/Rank", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) Search(ctx context.Context, in *QuerySearchRequest, opts ...grpc.CallOption) (*QuerySearchResponse, error) { out := new(QuerySearchResponse) err := c.cc.Invoke(ctx, "/cyber.rank.v1beta1.Query/Search", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) Backlinks(ctx context.Context, in *QuerySearchRequest, opts ...grpc.CallOption) (*QuerySearchResponse, error) { out := new(QuerySearchResponse) err := c.cc.Invoke(ctx, "/cyber.rank.v1beta1.Query/Backlinks", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) Top(ctx context.Context, in *QueryTopRequest, opts ...grpc.CallOption) (*QuerySearchResponse, error) { out := new(QuerySearchResponse) err := c.cc.Invoke(ctx, "/cyber.rank.v1beta1.Query/Top", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) IsLinkExist(ctx context.Context, in *QueryIsLinkExistRequest, opts ...grpc.CallOption) (*QueryLinkExistResponse, error) { out := new(QueryLinkExistResponse) err := c.cc.Invoke(ctx, "/cyber.rank.v1beta1.Query/IsLinkExist", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) IsAnyLinkExist(ctx context.Context, in *QueryIsAnyLinkExistRequest, opts ...grpc.CallOption) (*QueryLinkExistResponse, error) { out := new(QueryLinkExistResponse) err := c.cc.Invoke(ctx, "/cyber.rank.v1beta1.Query/IsAnyLinkExist", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) ParticleNegentropy(ctx context.Context, in *QueryNegentropyPartilceRequest, opts ...grpc.CallOption) (*QueryNegentropyParticleResponse, error) { out := new(QueryNegentropyParticleResponse) err := c.cc.Invoke(ctx, "/cyber.rank.v1beta1.Query/ParticleNegentropy", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) Negentropy(ctx context.Context, in *QueryNegentropyRequest, opts ...grpc.CallOption) (*QueryNegentropyResponse, error) { out := new(QueryNegentropyResponse) err := c.cc.Invoke(ctx, "/cyber.rank.v1beta1.Query/Negentropy", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) Karma(ctx context.Context, in *QueryKarmaRequest, opts ...grpc.CallOption) (*QueryKarmaResponse, error) { out := new(QueryKarmaResponse) err := c.cc.Invoke(ctx, "/cyber.rank.v1beta1.Query/Karma", in, out, opts...) if err != nil { return nil, err } return out, nil } // QueryServer is the server API for Query service. type QueryServer interface { Params(context.Context, *QueryParamsRequest) (*QueryParamsResponse, error) Rank(context.Context, *QueryRankRequest) (*QueryRankResponse, error) Search(context.Context, *QuerySearchRequest) (*QuerySearchResponse, error) Backlinks(context.Context, *QuerySearchRequest) (*QuerySearchResponse, error) Top(context.Context, *QueryTopRequest) (*QuerySearchResponse, error) IsLinkExist(context.Context, *QueryIsLinkExistRequest) (*QueryLinkExistResponse, error) IsAnyLinkExist(context.Context, *QueryIsAnyLinkExistRequest) (*QueryLinkExistResponse, error) ParticleNegentropy(context.Context, *QueryNegentropyPartilceRequest) (*QueryNegentropyParticleResponse, error) Negentropy(context.Context, *QueryNegentropyRequest) (*QueryNegentropyResponse, error) Karma(context.Context, *QueryKarmaRequest) (*QueryKarmaResponse, error) } // UnimplementedQueryServer can be embedded to have forward compatible implementations. type UnimplementedQueryServer struct{} func (*UnimplementedQueryServer) Params(ctx context.Context, req *QueryParamsRequest) (*QueryParamsResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method Params not implemented") } func (*UnimplementedQueryServer) Rank(ctx context.Context, req *QueryRankRequest) (*QueryRankResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method Rank not implemented") } func (*UnimplementedQueryServer) Search(ctx context.Context, req *QuerySearchRequest) (*QuerySearchResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method Search not implemented") } func (*UnimplementedQueryServer) Backlinks(ctx context.Context, req *QuerySearchRequest) (*QuerySearchResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method Backlinks not implemented") } func (*UnimplementedQueryServer) Top(ctx context.Context, req *QueryTopRequest) (*QuerySearchResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method Top not implemented") } func (*UnimplementedQueryServer) IsLinkExist(ctx context.Context, req *QueryIsLinkExistRequest) (*QueryLinkExistResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method IsLinkExist not implemented") } func (*UnimplementedQueryServer) IsAnyLinkExist(ctx context.Context, req *QueryIsAnyLinkExistRequest) (*QueryLinkExistResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method IsAnyLinkExist not implemented") } func (*UnimplementedQueryServer) ParticleNegentropy(ctx context.Context, req *QueryNegentropyPartilceRequest) (*QueryNegentropyParticleResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method ParticleNegentropy not implemented") } func (*UnimplementedQueryServer) Negentropy(ctx context.Context, req *QueryNegentropyRequest) (*QueryNegentropyResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method Negentropy not implemented") } func (*UnimplementedQueryServer) Karma(ctx context.Context, req *QueryKarmaRequest) (*QueryKarmaResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method Karma not implemented") } func RegisterQueryServer(s grpc1.Server, srv QueryServer) { s.RegisterService(&_Query_serviceDesc, srv) } func _Query_Params_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryParamsRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).Params(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.rank.v1beta1.Query/Params", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Params(ctx, req.(*QueryParamsRequest)) } return interceptor(ctx, in, info, handler) } func _Query_Rank_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryRankRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).Rank(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.rank.v1beta1.Query/Rank", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Rank(ctx, req.(*QueryRankRequest)) } return interceptor(ctx, in, info, handler) } func _Query_Search_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QuerySearchRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).Search(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.rank.v1beta1.Query/Search", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Search(ctx, req.(*QuerySearchRequest)) } return interceptor(ctx, in, info, handler) } func _Query_Backlinks_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QuerySearchRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).Backlinks(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.rank.v1beta1.Query/Backlinks", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Backlinks(ctx, req.(*QuerySearchRequest)) } return interceptor(ctx, in, info, handler) } func _Query_Top_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryTopRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).Top(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.rank.v1beta1.Query/Top", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Top(ctx, req.(*QueryTopRequest)) } return interceptor(ctx, in, info, handler) } func _Query_IsLinkExist_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryIsLinkExistRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).IsLinkExist(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.rank.v1beta1.Query/IsLinkExist", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).IsLinkExist(ctx, req.(*QueryIsLinkExistRequest)) } return interceptor(ctx, in, info, handler) } func _Query_IsAnyLinkExist_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryIsAnyLinkExistRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).IsAnyLinkExist(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.rank.v1beta1.Query/IsAnyLinkExist", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).IsAnyLinkExist(ctx, req.(*QueryIsAnyLinkExistRequest)) } return interceptor(ctx, in, info, handler) } func _Query_ParticleNegentropy_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryNegentropyPartilceRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).ParticleNegentropy(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.rank.v1beta1.Query/ParticleNegentropy", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).ParticleNegentropy(ctx, req.(*QueryNegentropyPartilceRequest)) } return interceptor(ctx, in, info, handler) } func _Query_Negentropy_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryNegentropyRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).Negentropy(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.rank.v1beta1.Query/Negentropy", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Negentropy(ctx, req.(*QueryNegentropyRequest)) } return interceptor(ctx, in, info, handler) } func _Query_Karma_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryKarmaRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).Karma(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.rank.v1beta1.Query/Karma", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Karma(ctx, req.(*QueryKarmaRequest)) } return interceptor(ctx, in, info, handler) } var _Query_serviceDesc = grpc.ServiceDesc{ ServiceName: "cyber.rank.v1beta1.Query", HandlerType: (*QueryServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "Params", Handler: _Query_Params_Handler, }, { MethodName: "Rank", Handler: _Query_Rank_Handler, }, { MethodName: "Search", Handler: _Query_Search_Handler, }, { MethodName: "Backlinks", Handler: _Query_Backlinks_Handler, }, { MethodName: "Top", Handler: _Query_Top_Handler, }, { MethodName: "IsLinkExist", Handler: _Query_IsLinkExist_Handler, }, { MethodName: "IsAnyLinkExist", Handler: _Query_IsAnyLinkExist_Handler, }, { MethodName: "ParticleNegentropy", Handler: _Query_ParticleNegentropy_Handler, }, { MethodName: "Negentropy", Handler: _Query_Negentropy_Handler, }, { MethodName: "Karma", Handler: _Query_Karma_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "cyber/rank/v1beta1/query.proto", } func (m *QueryParamsRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryParamsRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryParamsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *QueryParamsResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryParamsResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryParamsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.Params.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa return len(dAtA) - i, nil } func (m *QueryRankRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryRankRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryRankRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.Particle) > 0 { i -= len(m.Particle) copy(dAtA[i:], m.Particle) i = encodeVarintQuery(dAtA, i, uint64(len(m.Particle))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *QueryRankResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryRankResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryRankResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.Rank != 0 { i = encodeVarintQuery(dAtA, i, uint64(m.Rank)) i-- dAtA[i] = 0x8 } return len(dAtA) - i, nil } func (m *QuerySearchRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QuerySearchRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QuerySearchRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.Pagination != nil { { size, err := m.Pagination.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 } if len(m.Particle) > 0 { i -= len(m.Particle) copy(dAtA[i:], m.Particle) i = encodeVarintQuery(dAtA, i, uint64(len(m.Particle))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *QuerySearchResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QuerySearchResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QuerySearchResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.Pagination != nil { { size, err := m.Pagination.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 } if len(m.Result) > 0 { for iNdEx := len(m.Result) - 1; iNdEx >= 0; iNdEx-- { { size, err := m.Result[iNdEx].MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa } } return len(dAtA) - i, nil } func (m *QueryTopRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryTopRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryTopRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.Pagination != nil { { size, err := m.Pagination.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *QueryIsLinkExistRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryIsLinkExistRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryIsLinkExistRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.Address) > 0 { i -= len(m.Address) copy(dAtA[i:], m.Address) i = encodeVarintQuery(dAtA, i, uint64(len(m.Address))) i-- dAtA[i] = 0x1a } if len(m.To) > 0 { i -= len(m.To) copy(dAtA[i:], m.To) i = encodeVarintQuery(dAtA, i, uint64(len(m.To))) i-- dAtA[i] = 0x12 } if len(m.From) > 0 { i -= len(m.From) copy(dAtA[i:], m.From) i = encodeVarintQuery(dAtA, i, uint64(len(m.From))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *QueryIsAnyLinkExistRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryIsAnyLinkExistRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryIsAnyLinkExistRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.To) > 0 { i -= len(m.To) copy(dAtA[i:], m.To) i = encodeVarintQuery(dAtA, i, uint64(len(m.To))) i-- dAtA[i] = 0x12 } if len(m.From) > 0 { i -= len(m.From) copy(dAtA[i:], m.From) i = encodeVarintQuery(dAtA, i, uint64(len(m.From))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *QueryLinkExistResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryLinkExistResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryLinkExistResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.Exist { i-- if m.Exist { dAtA[i] = 1 } else { dAtA[i] = 0 } i-- dAtA[i] = 0x8 } return len(dAtA) - i, nil } func (m *QueryNegentropyPartilceRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryNegentropyPartilceRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryNegentropyPartilceRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.Particle) > 0 { i -= len(m.Particle) copy(dAtA[i:], m.Particle) i = encodeVarintQuery(dAtA, i, uint64(len(m.Particle))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *QueryNegentropyParticleResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryNegentropyParticleResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryNegentropyParticleResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.Entropy != 0 { i = encodeVarintQuery(dAtA, i, uint64(m.Entropy)) i-- dAtA[i] = 0x8 } return len(dAtA) - i, nil } func (m *QueryNegentropyRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryNegentropyRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryNegentropyRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *QueryNegentropyResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryNegentropyResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryNegentropyResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.Negentropy != 0 { i = encodeVarintQuery(dAtA, i, uint64(m.Negentropy)) i-- dAtA[i] = 0x8 } return len(dAtA) - i, nil } func (m *QueryKarmaRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryKarmaRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryKarmaRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.Neuron) > 0 { i -= len(m.Neuron) copy(dAtA[i:], m.Neuron) i = encodeVarintQuery(dAtA, i, uint64(len(m.Neuron))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *QueryKarmaResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryKarmaResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryKarmaResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.Karma != 0 { i = encodeVarintQuery(dAtA, i, uint64(m.Karma)) i-- dAtA[i] = 0x8 } return len(dAtA) - i, nil } func encodeVarintQuery(dAtA []byte, offset int, v uint64) int { offset -= sovQuery(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *QueryParamsRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *QueryParamsResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l l = m.Params.Size() n += 1 + l + sovQuery(uint64(l)) return n } func (m *QueryRankRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Particle) if l > 0 { n += 1 + l + sovQuery(uint64(l)) } return n } func (m *QueryRankResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.Rank != 0 { n += 1 + sovQuery(uint64(m.Rank)) } return n } func (m *QuerySearchRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Particle) if l > 0 { n += 1 + l + sovQuery(uint64(l)) } if m.Pagination != nil { l = m.Pagination.Size() n += 1 + l + sovQuery(uint64(l)) } return n } func (m *QuerySearchResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l if len(m.Result) > 0 { for _, e := range m.Result { l = e.Size() n += 1 + l + sovQuery(uint64(l)) } } if m.Pagination != nil { l = m.Pagination.Size() n += 1 + l + sovQuery(uint64(l)) } return n } func (m *QueryTopRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.Pagination != nil { l = m.Pagination.Size() n += 1 + l + sovQuery(uint64(l)) } return n } func (m *QueryIsLinkExistRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.From) if l > 0 { n += 1 + l + sovQuery(uint64(l)) } l = len(m.To) if l > 0 { n += 1 + l + sovQuery(uint64(l)) } l = len(m.Address) if l > 0 { n += 1 + l + sovQuery(uint64(l)) } return n } func (m *QueryIsAnyLinkExistRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.From) if l > 0 { n += 1 + l + sovQuery(uint64(l)) } l = len(m.To) if l > 0 { n += 1 + l + sovQuery(uint64(l)) } return n } func (m *QueryLinkExistResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.Exist { n += 2 } return n } func (m *QueryNegentropyPartilceRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Particle) if l > 0 { n += 1 + l + sovQuery(uint64(l)) } return n } func (m *QueryNegentropyParticleResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.Entropy != 0 { n += 1 + sovQuery(uint64(m.Entropy)) } return n } func (m *QueryNegentropyRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *QueryNegentropyResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.Negentropy != 0 { n += 1 + sovQuery(uint64(m.Negentropy)) } return n } func (m *QueryKarmaRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Neuron) if l > 0 { n += 1 + l + sovQuery(uint64(l)) } return n } func (m *QueryKarmaResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.Karma != 0 { n += 1 + sovQuery(uint64(m.Karma)) } return n } func sovQuery(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozQuery(x uint64) (n int) { return sovQuery(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *QueryParamsRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryParamsRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryParamsRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryParamsResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryParamsResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryParamsResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Params.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryRankRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryRankRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryRankRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Particle", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } m.Particle = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryRankResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryRankResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryRankResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field Rank", wireType) } m.Rank = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.Rank |= uint64(b&0x7F) << shift if b < 0x80 { break } } default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QuerySearchRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QuerySearchRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QuerySearchRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Particle", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } m.Particle = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if m.Pagination == nil { m.Pagination = &PageRequest{} } if err := m.Pagination.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QuerySearchResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QuerySearchResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QuerySearchResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Result", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } m.Result = append(m.Result, RankedParticle{}) if err := m.Result[len(m.Result)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if m.Pagination == nil { m.Pagination = &PageResponse{} } if err := m.Pagination.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryTopRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryTopRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryTopRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Pagination", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if m.Pagination == nil { m.Pagination = &PageRequest{} } if err := m.Pagination.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryIsLinkExistRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryIsLinkExistRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryIsLinkExistRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field From", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } m.From = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field To", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } m.To = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Address", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } m.Address = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryIsAnyLinkExistRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryIsAnyLinkExistRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryIsAnyLinkExistRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field From", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } m.From = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field To", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } m.To = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryLinkExistResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryLinkExistResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryLinkExistResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field Exist", wireType) } var v int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ v |= int(b&0x7F) << shift if b < 0x80 { break } } m.Exist = bool(v != 0) default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryNegentropyPartilceRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryNegentropyPartilceRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryNegentropyPartilceRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Particle", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } m.Particle = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryNegentropyParticleResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryNegentropyParticleResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryNegentropyParticleResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field Entropy", wireType) } m.Entropy = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.Entropy |= uint64(b&0x7F) << shift if b < 0x80 { break } } default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryNegentropyRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryNegentropyRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryNegentropyRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryNegentropyResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryNegentropyResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryNegentropyResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field Negentropy", wireType) } m.Negentropy = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.Negentropy |= uint64(b&0x7F) << shift if b < 0x80 { break } } default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryKarmaRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryKarmaRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryKarmaRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Neuron", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } m.Neuron = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryKarmaResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryKarmaResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryKarmaResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field Karma", wireType) } m.Karma = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.Karma |= uint64(b&0x7F) << shift if b < 0x80 { break } } default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipQuery(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowQuery } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowQuery } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowQuery } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthQuery } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupQuery } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthQuery } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthQuery = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowQuery = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupQuery = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/rank/types/query.pb.gw.go ================================================ // Code generated by protoc-gen-grpc-gateway. DO NOT EDIT. // source: cyber/rank/v1beta1/query.proto /* Package types is a reverse proxy. It translates gRPC into RESTful JSON APIs. */ package types import ( "context" "io" "net/http" "github.com/golang/protobuf/descriptor" "github.com/golang/protobuf/proto" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/grpc-ecosystem/grpc-gateway/utilities" "google.golang.org/grpc" "google.golang.org/grpc/codes" "google.golang.org/grpc/grpclog" "google.golang.org/grpc/metadata" "google.golang.org/grpc/status" ) // Suppress "imported and not used" errors var ( _ codes.Code _ io.Reader _ status.Status _ = runtime.String _ = utilities.NewDoubleArray _ = descriptor.ForMessage _ = metadata.Join ) func request_Query_Params_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryParamsRequest var metadata runtime.ServerMetadata msg, err := client.Params(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_Params_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryParamsRequest var metadata runtime.ServerMetadata msg, err := server.Params(ctx, &protoReq) return msg, metadata, err } func request_Query_Rank_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryRankRequest var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["particle"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "particle") } protoReq.Particle, err = runtime.String(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "particle", err) } msg, err := client.Rank(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_Rank_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryRankRequest var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["particle"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "particle") } protoReq.Particle, err = runtime.String(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "particle", err) } msg, err := server.Rank(ctx, &protoReq) return msg, metadata, err } var filter_Query_Search_0 = &utilities.DoubleArray{Encoding: map[string]int{"particle": 0}, Base: []int{1, 1, 0}, Check: []int{0, 1, 2}} func request_Query_Search_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QuerySearchRequest var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["particle"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "particle") } protoReq.Particle, err = runtime.String(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "particle", err) } if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_Search_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := client.Search(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_Search_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QuerySearchRequest var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["particle"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "particle") } protoReq.Particle, err = runtime.String(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "particle", err) } if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_Search_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := server.Search(ctx, &protoReq) return msg, metadata, err } var filter_Query_Backlinks_0 = &utilities.DoubleArray{Encoding: map[string]int{"particle": 0}, Base: []int{1, 1, 0}, Check: []int{0, 1, 2}} func request_Query_Backlinks_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QuerySearchRequest var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["particle"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "particle") } protoReq.Particle, err = runtime.String(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "particle", err) } if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_Backlinks_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := client.Backlinks(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_Backlinks_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QuerySearchRequest var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["particle"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "particle") } protoReq.Particle, err = runtime.String(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "particle", err) } if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_Backlinks_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := server.Backlinks(ctx, &protoReq) return msg, metadata, err } var filter_Query_Top_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} func request_Query_Top_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryTopRequest var metadata runtime.ServerMetadata if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_Top_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := client.Top(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_Top_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryTopRequest var metadata runtime.ServerMetadata if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_Top_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := server.Top(ctx, &protoReq) return msg, metadata, err } var filter_Query_IsLinkExist_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} func request_Query_IsLinkExist_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryIsLinkExistRequest var metadata runtime.ServerMetadata if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_IsLinkExist_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := client.IsLinkExist(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_IsLinkExist_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryIsLinkExistRequest var metadata runtime.ServerMetadata if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_IsLinkExist_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := server.IsLinkExist(ctx, &protoReq) return msg, metadata, err } var filter_Query_IsAnyLinkExist_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} func request_Query_IsAnyLinkExist_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryIsAnyLinkExistRequest var metadata runtime.ServerMetadata if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_IsAnyLinkExist_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := client.IsAnyLinkExist(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_IsAnyLinkExist_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryIsAnyLinkExistRequest var metadata runtime.ServerMetadata if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_IsAnyLinkExist_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := server.IsAnyLinkExist(ctx, &protoReq) return msg, metadata, err } func request_Query_ParticleNegentropy_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryNegentropyPartilceRequest var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["particle"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "particle") } protoReq.Particle, err = runtime.String(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "particle", err) } msg, err := client.ParticleNegentropy(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_ParticleNegentropy_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryNegentropyPartilceRequest var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["particle"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "particle") } protoReq.Particle, err = runtime.String(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "particle", err) } msg, err := server.ParticleNegentropy(ctx, &protoReq) return msg, metadata, err } func request_Query_Negentropy_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryNegentropyRequest var metadata runtime.ServerMetadata msg, err := client.Negentropy(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_Negentropy_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryNegentropyRequest var metadata runtime.ServerMetadata msg, err := server.Negentropy(ctx, &protoReq) return msg, metadata, err } func request_Query_Karma_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryKarmaRequest var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["neuron"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "neuron") } protoReq.Neuron, err = runtime.String(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "neuron", err) } msg, err := client.Karma(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_Karma_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryKarmaRequest var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["neuron"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "neuron") } protoReq.Neuron, err = runtime.String(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "neuron", err) } msg, err := server.Karma(ctx, &protoReq) return msg, metadata, err } // RegisterQueryHandlerServer registers the http handlers for service Query to "mux". // UnaryRPC :call QueryServer directly. // StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. // Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterQueryHandlerFromEndpoint instead. func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, server QueryServer) error { mux.Handle("GET", pattern_Query_Params_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_Params_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Params_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_Rank_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_Rank_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Rank_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_Search_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_Search_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Search_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_Backlinks_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_Backlinks_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Backlinks_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_Top_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_Top_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Top_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_IsLinkExist_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_IsLinkExist_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_IsLinkExist_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_IsAnyLinkExist_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_IsAnyLinkExist_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_IsAnyLinkExist_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_ParticleNegentropy_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_ParticleNegentropy_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_ParticleNegentropy_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_Negentropy_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_Negentropy_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Negentropy_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_Karma_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_Karma_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Karma_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) return nil } // RegisterQueryHandlerFromEndpoint is same as RegisterQueryHandler but // automatically dials to "endpoint" and closes the connection when "ctx" gets done. func RegisterQueryHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error) { conn, err := grpc.Dial(endpoint, opts...) if err != nil { return err } defer func() { if err != nil { if cerr := conn.Close(); cerr != nil { grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr) } return } go func() { <-ctx.Done() if cerr := conn.Close(); cerr != nil { grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr) } }() }() return RegisterQueryHandler(ctx, mux, conn) } // RegisterQueryHandler registers the http handlers for service Query to "mux". // The handlers forward requests to the grpc endpoint over "conn". func RegisterQueryHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error { return RegisterQueryHandlerClient(ctx, mux, NewQueryClient(conn)) } // RegisterQueryHandlerClient registers the http handlers for service Query // to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "QueryClient". // Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "QueryClient" // doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in // "QueryClient" to call the correct interceptors. func RegisterQueryHandlerClient(ctx context.Context, mux *runtime.ServeMux, client QueryClient) error { mux.Handle("GET", pattern_Query_Params_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_Params_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Params_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_Rank_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_Rank_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Rank_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_Search_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_Search_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Search_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_Backlinks_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_Backlinks_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Backlinks_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_Top_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_Top_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Top_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_IsLinkExist_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_IsLinkExist_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_IsLinkExist_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_IsAnyLinkExist_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_IsAnyLinkExist_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_IsAnyLinkExist_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_ParticleNegentropy_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_ParticleNegentropy_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_ParticleNegentropy_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_Negentropy_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_Negentropy_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Negentropy_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_Karma_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_Karma_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Karma_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) return nil } var ( pattern_Query_Params_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 1, 2, 3}, []string{"cyber", "rank", "v1beta1", "params"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_Rank_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 1, 2, 1, 1, 0, 4, 1, 5, 3}, []string{"cyber", "rank", "v1beta1", "particle"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_Search_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 1, 2, 3, 1, 0, 4, 1, 5, 4}, []string{"cyber", "rank", "v1beta1", "search", "particle"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_Backlinks_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 1, 2, 3, 1, 0, 4, 1, 5, 4}, []string{"cyber", "rank", "v1beta1", "backlinks", "particle"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_Top_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 1, 2, 3}, []string{"cyber", "rank", "v1beta1", "top"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_IsLinkExist_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"cyber", "rank", "v1beta1", "is_link_exist"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_IsAnyLinkExist_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"cyber", "rank", "v1beta1", "is_any_link_exist"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_ParticleNegentropy_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4}, []string{"cyber", "rank", "v1beta1", "negentropy", "particle"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_Negentropy_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"cyber", "rank", "v1beta1", "negentropy"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_Karma_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4}, []string{"cyber", "rank", "v1beta1", "karma", "neuron"}, "", runtime.AssumeColonVerbOpt(false))) ) var ( forward_Query_Params_0 = runtime.ForwardResponseMessage forward_Query_Rank_0 = runtime.ForwardResponseMessage forward_Query_Search_0 = runtime.ForwardResponseMessage forward_Query_Backlinks_0 = runtime.ForwardResponseMessage forward_Query_Top_0 = runtime.ForwardResponseMessage forward_Query_IsLinkExist_0 = runtime.ForwardResponseMessage forward_Query_IsAnyLinkExist_0 = runtime.ForwardResponseMessage forward_Query_ParticleNegentropy_0 = runtime.ForwardResponseMessage forward_Query_Negentropy_0 = runtime.ForwardResponseMessage forward_Query_Karma_0 = runtime.ForwardResponseMessage ) ================================================ FILE: x/rank/types/rank.go ================================================ package types import ( "crypto/sha256" "sort" "time" "github.com/cybercongress/go-cyber/v7/merkle" graphtypes "github.com/cybercongress/go-cyber/v7/x/graph/types" "github.com/cometbft/cometbft/libs/log" ) type EMState struct { RankValues []float64 } type Rank struct { RankValues []uint64 MerkleTree *merkle.Tree // ranks merkle CidCount uint64 TopCIDs []RankedCidNumber } func NewRank(state EMState, logger log.Logger, fullTree bool) Rank { start := time.Now() particlesCount := uint64(len(state.RankValues)) rankValues := make([]uint64, particlesCount) for i, f64 := range state.RankValues { rankValues[i] = uint64(f64 * 1e15) } state.RankValues = nil logger.Info("State processing to integers", "duration", time.Since(start).String()) start = time.Now() merkleTree := merkle.NewTree(sha256.New(), fullTree) zeroRankBytes := make([]byte, 8) for range rankValues { merkleTree.Push(zeroRankBytes) } logger.Info("Rank constructing tree", "duration", time.Since(start).String()) // NOTE fulltree true if search index enabled start = time.Now() var newSortedCIDs []RankedCidNumber if fullTree { newSortedCIDs = BuildTop(rankValues, 1000) logger.Info("Build top", "duration", time.Since(start).String()) } return Rank{ RankValues: rankValues, MerkleTree: merkleTree, CidCount: particlesCount, TopCIDs: newSortedCIDs, } } func NewFromMerkle(cidCount uint64, treeBytes []byte) Rank { rank := Rank{ RankValues: nil, MerkleTree: merkle.NewTree(sha256.New(), false), CidCount: cidCount, TopCIDs: nil, } rank.MerkleTree.ImportSubtreesRoots(treeBytes) if cidCount > 0 { rank.RankValues = make([]uint64, cidCount) } return rank } func (r Rank) IsEmpty() bool { return (r.RankValues == nil || len(r.RankValues) == 0) && r.MerkleTree == nil } func (r *Rank) Clear() { r.RankValues = nil r.MerkleTree = nil r.CidCount = 0 r.TopCIDs = nil } func (r *Rank) CopyWithoutTree() Rank { if r.RankValues == nil { return Rank{ RankValues: nil, MerkleTree: nil, CidCount: 0, TopCIDs: nil, } } copiedRankValues := make([]uint64, r.CidCount) n := copy(copiedRankValues, r.RankValues) // SHOULD NOT HAPPEN if n != len(r.RankValues) { panic("Not all rank values have been copied") } copiedTopCIDs := make([]RankedCidNumber, len(r.TopCIDs)) n = copy(copiedTopCIDs, r.TopCIDs) if n != len(r.TopCIDs) { panic("Not all sorted particles have been copied") } return Rank{ RankValues: copiedRankValues, MerkleTree: nil, CidCount: r.CidCount, TopCIDs: copiedTopCIDs, } } // TODO: optimize. Possible solution: adjust capacity of rank values slice after rank calculation func (r *Rank) AddNewCids(currentCidCount uint64) { newCidsCount := currentCidCount - r.CidCount // add new cids with rank = 0 if r.RankValues != nil { r.RankValues = append(r.RankValues, make([]uint64, newCidsCount)...) } // extend merkle tree zeroRankBytes := make([]byte, 8) for i := uint64(0); i < newCidsCount; i++ { r.MerkleTree.Push(zeroRankBytes) } r.CidCount = currentCidCount } func BuildTop(values []uint64, size int) []RankedCidNumber { newSortedCIDs := make(sortableCidNumbers, 0, len(values)) for cid, rank := range values { if rank == 0 { continue } newRankedCid := RankedCidNumber{graphtypes.CidNumber(cid), rank} newSortedCIDs = append(newSortedCIDs, newRankedCid) } sort.Stable(sort.Reverse(newSortedCIDs)) if len(values) > size { newSortedCIDs = newSortedCIDs[0:(size - 1)] } return newSortedCIDs } ================================================ FILE: x/rank/types/tx.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: cyber/rank/v1beta1/tx.proto package types import ( context "context" fmt "fmt" io "io" math "math" math_bits "math/bits" _ "github.com/cosmos/cosmos-proto" _ "github.com/cosmos/cosmos-sdk/types/msgservice" _ "github.com/cosmos/gogoproto/gogoproto" grpc1 "github.com/cosmos/gogoproto/grpc" proto "github.com/cosmos/gogoproto/proto" grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" ) // Reference imports to suppress errors if they are not otherwise used. var ( _ = proto.Marshal _ = fmt.Errorf _ = math.Inf ) // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package type MsgUpdateParams struct { Authority string `protobuf:"bytes,1,opt,name=authority,proto3" json:"authority,omitempty"` Params Params `protobuf:"bytes,2,opt,name=params,proto3" json:"params"` } func (m *MsgUpdateParams) Reset() { *m = MsgUpdateParams{} } func (m *MsgUpdateParams) String() string { return proto.CompactTextString(m) } func (*MsgUpdateParams) ProtoMessage() {} func (*MsgUpdateParams) Descriptor() ([]byte, []int) { return fileDescriptor_77ab52c5f2c8eb9f, []int{0} } func (m *MsgUpdateParams) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgUpdateParams) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgUpdateParams.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgUpdateParams) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgUpdateParams.Merge(m, src) } func (m *MsgUpdateParams) XXX_Size() int { return m.Size() } func (m *MsgUpdateParams) XXX_DiscardUnknown() { xxx_messageInfo_MsgUpdateParams.DiscardUnknown(m) } var xxx_messageInfo_MsgUpdateParams proto.InternalMessageInfo func (m *MsgUpdateParams) GetAuthority() string { if m != nil { return m.Authority } return "" } func (m *MsgUpdateParams) GetParams() Params { if m != nil { return m.Params } return Params{} } type MsgUpdateParamsResponse struct{} func (m *MsgUpdateParamsResponse) Reset() { *m = MsgUpdateParamsResponse{} } func (m *MsgUpdateParamsResponse) String() string { return proto.CompactTextString(m) } func (*MsgUpdateParamsResponse) ProtoMessage() {} func (*MsgUpdateParamsResponse) Descriptor() ([]byte, []int) { return fileDescriptor_77ab52c5f2c8eb9f, []int{1} } func (m *MsgUpdateParamsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgUpdateParamsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgUpdateParamsResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgUpdateParamsResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgUpdateParamsResponse.Merge(m, src) } func (m *MsgUpdateParamsResponse) XXX_Size() int { return m.Size() } func (m *MsgUpdateParamsResponse) XXX_DiscardUnknown() { xxx_messageInfo_MsgUpdateParamsResponse.DiscardUnknown(m) } var xxx_messageInfo_MsgUpdateParamsResponse proto.InternalMessageInfo func init() { proto.RegisterType((*MsgUpdateParams)(nil), "cyber.rank.v1beta1.MsgUpdateParams") proto.RegisterType((*MsgUpdateParamsResponse)(nil), "cyber.rank.v1beta1.MsgUpdateParamsResponse") } func init() { proto.RegisterFile("cyber/rank/v1beta1/tx.proto", fileDescriptor_77ab52c5f2c8eb9f) } var fileDescriptor_77ab52c5f2c8eb9f = []byte{ // 321 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0x4e, 0xae, 0x4c, 0x4a, 0x2d, 0xd2, 0x2f, 0x4a, 0xcc, 0xcb, 0xd6, 0x2f, 0x33, 0x4c, 0x4a, 0x2d, 0x49, 0x34, 0xd4, 0x2f, 0xa9, 0xd0, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x02, 0x4b, 0xea, 0x81, 0x24, 0xf5, 0xa0, 0x92, 0x52, 0x22, 0xe9, 0xf9, 0xe9, 0xf9, 0x60, 0x69, 0x7d, 0x10, 0x0b, 0xa2, 0x52, 0x4a, 0x3c, 0x39, 0xbf, 0x38, 0x37, 0xbf, 0x58, 0x3f, 0xb7, 0x38, 0x5d, 0xbf, 0xcc, 0x10, 0x44, 0x41, 0x25, 0x24, 0x21, 0x12, 0xf1, 0x10, 0x1d, 0x10, 0x0e, 0x54, 0x4a, 0x0e, 0x9b, 0xd5, 0x95, 0x05, 0xa9, 0x50, 0x79, 0xa5, 0xc9, 0x8c, 0x5c, 0xfc, 0xbe, 0xc5, 0xe9, 0xa1, 0x05, 0x29, 0x89, 0x25, 0xa9, 0x01, 0x89, 0x45, 0x89, 0xb9, 0xc5, 0x42, 0x66, 0x5c, 0x9c, 0x89, 0xa5, 0x25, 0x19, 0xf9, 0x45, 0x99, 0x25, 0x95, 0x12, 0x8c, 0x0a, 0x8c, 0x1a, 0x9c, 0x4e, 0x12, 0x97, 0xb6, 0xe8, 0x8a, 0x40, 0x0d, 0x76, 0x4c, 0x49, 0x29, 0x4a, 0x2d, 0x2e, 0x0e, 0x2e, 0x29, 0xca, 0xcc, 0x4b, 0x0f, 0x42, 0x28, 0x15, 0xb2, 0xe0, 0x62, 0x2b, 0x00, 0x9b, 0x20, 0xc1, 0xa4, 0xc0, 0xa8, 0xc1, 0x6d, 0x24, 0xa5, 0x87, 0xe9, 0x35, 0x3d, 0x88, 0x1d, 0x4e, 0x2c, 0x27, 0xee, 0xc9, 0x33, 0x04, 0x41, 0xd5, 0x5b, 0xf1, 0x35, 0x3d, 0xdf, 0xa0, 0x85, 0x30, 0x49, 0x49, 0x92, 0x4b, 0x1c, 0xcd, 0x51, 0x41, 0xa9, 0xc5, 0x05, 0xf9, 0x79, 0xc5, 0xa9, 0x46, 0xe9, 0x5c, 0xcc, 0xbe, 0xc5, 0xe9, 0x42, 0x09, 0x5c, 0x3c, 0x28, 0x6e, 0x56, 0xc6, 0x66, 0x17, 0x9a, 0x19, 0x52, 0xda, 0x44, 0x28, 0x82, 0x59, 0xe4, 0xe4, 0x71, 0xe2, 0x91, 0x1c, 0xe3, 0x85, 0x47, 0x72, 0x8c, 0x0f, 0x1e, 0xc9, 0x31, 0x4e, 0x78, 0x2c, 0xc7, 0x70, 0xe1, 0xb1, 0x1c, 0xc3, 0x8d, 0xc7, 0x72, 0x0c, 0x51, 0x7a, 0xe9, 0x99, 0x25, 0x19, 0xa5, 0x49, 0x7a, 0xc9, 0xf9, 0xb9, 0xfa, 0x60, 0x03, 0x93, 0xf3, 0xf3, 0xd2, 0x41, 0x41, 0xa2, 0x9f, 0x9e, 0xaf, 0x0b, 0x09, 0xef, 0x0a, 0x48, 0x88, 0x83, 0x43, 0x3a, 0x89, 0x0d, 0x1c, 0xd4, 0xc6, 0x80, 0x00, 0x00, 0x00, 0xff, 0xff, 0x32, 0x67, 0xef, 0xc9, 0x07, 0x02, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. var ( _ context.Context _ grpc.ClientConn ) // This is a compile-time assertion to ensure that this generated file // is compatible with the grpc package it is being compiled against. const _ = grpc.SupportPackageIsVersion4 // MsgClient is the client API for Msg service. // // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. type MsgClient interface { UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) } type msgClient struct { cc grpc1.ClientConn } func NewMsgClient(cc grpc1.ClientConn) MsgClient { return &msgClient{cc} } func (c *msgClient) UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) { out := new(MsgUpdateParamsResponse) err := c.cc.Invoke(ctx, "/cyber.rank.v1beta1.Msg/UpdateParams", in, out, opts...) if err != nil { return nil, err } return out, nil } // MsgServer is the server API for Msg service. type MsgServer interface { UpdateParams(context.Context, *MsgUpdateParams) (*MsgUpdateParamsResponse, error) } // UnimplementedMsgServer can be embedded to have forward compatible implementations. type UnimplementedMsgServer struct{} func (*UnimplementedMsgServer) UpdateParams(ctx context.Context, req *MsgUpdateParams) (*MsgUpdateParamsResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method UpdateParams not implemented") } func RegisterMsgServer(s grpc1.Server, srv MsgServer) { s.RegisterService(&_Msg_serviceDesc, srv) } func _Msg_UpdateParams_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgUpdateParams) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(MsgServer).UpdateParams(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.rank.v1beta1.Msg/UpdateParams", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).UpdateParams(ctx, req.(*MsgUpdateParams)) } return interceptor(ctx, in, info, handler) } var _Msg_serviceDesc = grpc.ServiceDesc{ ServiceName: "cyber.rank.v1beta1.Msg", HandlerType: (*MsgServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "UpdateParams", Handler: _Msg_UpdateParams_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "cyber/rank/v1beta1/tx.proto", } func (m *MsgUpdateParams) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgUpdateParams) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgUpdateParams) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.Params.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintTx(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 if len(m.Authority) > 0 { i -= len(m.Authority) copy(dAtA[i:], m.Authority) i = encodeVarintTx(dAtA, i, uint64(len(m.Authority))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *MsgUpdateParamsResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgUpdateParamsResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgUpdateParamsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func encodeVarintTx(dAtA []byte, offset int, v uint64) int { offset -= sovTx(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *MsgUpdateParams) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Authority) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = m.Params.Size() n += 1 + l + sovTx(uint64(l)) return n } func (m *MsgUpdateParamsResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func sovTx(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozTx(x uint64) (n int) { return sovTx(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *MsgUpdateParams) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgUpdateParams: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgUpdateParams: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Authority", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Authority = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Params.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgUpdateParamsResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgUpdateParamsResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgUpdateParamsResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipTx(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTx } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTx } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTx } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthTx } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupTx } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthTx } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthTx = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowTx = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupTx = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/rank/types/types.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: cyber/rank/v1beta1/types.proto package types import ( fmt "fmt" io "io" math "math" math_bits "math/bits" github_com_cosmos_cosmos_sdk_types "github.com/cosmos/cosmos-sdk/types" _ "github.com/cosmos/gogoproto/gogoproto" proto "github.com/cosmos/gogoproto/proto" ) // Reference imports to suppress errors if they are not otherwise used. var ( _ = proto.Marshal _ = fmt.Errorf _ = math.Inf ) // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package type Params struct { CalculationPeriod int64 `protobuf:"varint,1,opt,name=calculation_period,json=calculationPeriod,proto3" json:"calculation_period,omitempty"` DampingFactor github_com_cosmos_cosmos_sdk_types.Dec `protobuf:"bytes,2,opt,name=damping_factor,json=dampingFactor,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Dec" json:"damping_factor"` Tolerance github_com_cosmos_cosmos_sdk_types.Dec `protobuf:"bytes,3,opt,name=tolerance,proto3,customtype=github.com/cosmos/cosmos-sdk/types.Dec" json:"tolerance"` } func (m *Params) Reset() { *m = Params{} } func (m *Params) String() string { return proto.CompactTextString(m) } func (*Params) ProtoMessage() {} func (*Params) Descriptor() ([]byte, []int) { return fileDescriptor_5e38a68eff7d025f, []int{0} } func (m *Params) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *Params) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_Params.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *Params) XXX_Merge(src proto.Message) { xxx_messageInfo_Params.Merge(m, src) } func (m *Params) XXX_Size() int { return m.Size() } func (m *Params) XXX_DiscardUnknown() { xxx_messageInfo_Params.DiscardUnknown(m) } var xxx_messageInfo_Params proto.InternalMessageInfo func (m *Params) GetCalculationPeriod() int64 { if m != nil { return m.CalculationPeriod } return 0 } type RankedParticle struct { Particle string `protobuf:"bytes,1,opt,name=particle,proto3" json:"particle,omitempty"` Rank uint64 `protobuf:"varint,2,opt,name=rank,proto3" json:"rank,omitempty"` } func (m *RankedParticle) Reset() { *m = RankedParticle{} } func (m *RankedParticle) String() string { return proto.CompactTextString(m) } func (*RankedParticle) ProtoMessage() {} func (*RankedParticle) Descriptor() ([]byte, []int) { return fileDescriptor_5e38a68eff7d025f, []int{1} } func (m *RankedParticle) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *RankedParticle) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_RankedParticle.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *RankedParticle) XXX_Merge(src proto.Message) { xxx_messageInfo_RankedParticle.Merge(m, src) } func (m *RankedParticle) XXX_Size() int { return m.Size() } func (m *RankedParticle) XXX_DiscardUnknown() { xxx_messageInfo_RankedParticle.DiscardUnknown(m) } var xxx_messageInfo_RankedParticle proto.InternalMessageInfo func (m *RankedParticle) GetParticle() string { if m != nil { return m.Particle } return "" } func (m *RankedParticle) GetRank() uint64 { if m != nil { return m.Rank } return 0 } func init() { proto.RegisterType((*Params)(nil), "cyber.rank.v1beta1.Params") proto.RegisterType((*RankedParticle)(nil), "cyber.rank.v1beta1.RankedParticle") } func init() { proto.RegisterFile("cyber/rank/v1beta1/types.proto", fileDescriptor_5e38a68eff7d025f) } var fileDescriptor_5e38a68eff7d025f = []byte{ // 309 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x91, 0xc1, 0x4a, 0x33, 0x31, 0x14, 0x85, 0x27, 0x7f, 0x4b, 0xf9, 0x1b, 0xb0, 0x60, 0x70, 0x51, 0xba, 0x48, 0x4b, 0x17, 0xd2, 0x4d, 0x13, 0x8a, 0x2f, 0x20, 0x45, 0xc4, 0x85, 0x8b, 0x32, 0xe0, 0xc6, 0x4d, 0xc9, 0x64, 0x62, 0x1c, 0x3a, 0x93, 0x3b, 0x24, 0xa9, 0xd8, 0xb7, 0xf0, 0xb1, 0xba, 0xec, 0x52, 0x44, 0x8a, 0xb4, 0x2f, 0x22, 0x93, 0x19, 0xb4, 0x6b, 0x57, 0x39, 0xe1, 0xbb, 0x1c, 0xce, 0x3d, 0x17, 0x53, 0xb9, 0x49, 0x94, 0xe5, 0x56, 0x98, 0x15, 0x7f, 0x99, 0x25, 0xca, 0x8b, 0x19, 0xf7, 0x9b, 0x52, 0x39, 0x56, 0x5a, 0xf0, 0x40, 0x48, 0xe0, 0xac, 0xe2, 0xac, 0xe1, 0x83, 0x0b, 0x0d, 0x1a, 0x02, 0xe6, 0x95, 0xaa, 0x27, 0xc7, 0x9f, 0x08, 0x77, 0x16, 0xc2, 0x8a, 0xc2, 0x91, 0x29, 0x26, 0x52, 0xe4, 0x72, 0x9d, 0x0b, 0x9f, 0x81, 0x59, 0x96, 0xca, 0x66, 0x90, 0xf6, 0xd1, 0x08, 0x4d, 0x5a, 0xf1, 0xf9, 0x09, 0x59, 0x04, 0x40, 0x1e, 0x70, 0x2f, 0x15, 0x45, 0x99, 0x19, 0xbd, 0x7c, 0x12, 0xd2, 0x83, 0xed, 0xff, 0x1b, 0xa1, 0x49, 0x77, 0xce, 0xb6, 0xfb, 0x61, 0xf4, 0xb1, 0x1f, 0x5e, 0xea, 0xcc, 0x3f, 0xaf, 0x13, 0x26, 0xa1, 0xe0, 0x12, 0x5c, 0x01, 0xae, 0x79, 0xa6, 0x2e, 0x5d, 0x35, 0x69, 0x6f, 0x94, 0x8c, 0xcf, 0x1a, 0x97, 0xdb, 0x60, 0x42, 0xee, 0x71, 0xd7, 0x43, 0xae, 0xac, 0x30, 0x52, 0xf5, 0x5b, 0x7f, 0x72, 0xfc, 0x35, 0x18, 0x5f, 0xe3, 0x5e, 0x2c, 0xcc, 0x4a, 0xa5, 0x0b, 0x61, 0x7d, 0x26, 0x73, 0x45, 0x06, 0xf8, 0x7f, 0xd9, 0xe8, 0xb0, 0x5b, 0x37, 0xfe, 0xf9, 0x13, 0x82, 0xdb, 0x55, 0x65, 0x61, 0x91, 0x76, 0x1c, 0xf4, 0xfc, 0x6e, 0x7b, 0xa0, 0x68, 0x77, 0xa0, 0xe8, 0xeb, 0x40, 0xd1, 0xdb, 0x91, 0x46, 0xbb, 0x23, 0x8d, 0xde, 0x8f, 0x34, 0x7a, 0x64, 0xa7, 0x71, 0xaa, 0xbe, 0x25, 0x18, 0x6d, 0x95, 0x73, 0x5c, 0xc3, 0xb4, 0x3e, 0xd0, 0x6b, 0x7d, 0xa2, 0x10, 0x2d, 0xe9, 0x84, 0xc6, 0xaf, 0xbe, 0x03, 0x00, 0x00, 0xff, 0xff, 0xdd, 0xa7, 0x39, 0x44, 0xbd, 0x01, 0x00, 0x00, } func (m *Params) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *Params) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *Params) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size := m.Tolerance.Size() i -= size if _, err := m.Tolerance.MarshalTo(dAtA[i:]); err != nil { return 0, err } i = encodeVarintTypes(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x1a { size := m.DampingFactor.Size() i -= size if _, err := m.DampingFactor.MarshalTo(dAtA[i:]); err != nil { return 0, err } i = encodeVarintTypes(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 if m.CalculationPeriod != 0 { i = encodeVarintTypes(dAtA, i, uint64(m.CalculationPeriod)) i-- dAtA[i] = 0x8 } return len(dAtA) - i, nil } func (m *RankedParticle) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *RankedParticle) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *RankedParticle) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.Rank != 0 { i = encodeVarintTypes(dAtA, i, uint64(m.Rank)) i-- dAtA[i] = 0x10 } if len(m.Particle) > 0 { i -= len(m.Particle) copy(dAtA[i:], m.Particle) i = encodeVarintTypes(dAtA, i, uint64(len(m.Particle))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func encodeVarintTypes(dAtA []byte, offset int, v uint64) int { offset -= sovTypes(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *Params) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.CalculationPeriod != 0 { n += 1 + sovTypes(uint64(m.CalculationPeriod)) } l = m.DampingFactor.Size() n += 1 + l + sovTypes(uint64(l)) l = m.Tolerance.Size() n += 1 + l + sovTypes(uint64(l)) return n } func (m *RankedParticle) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Particle) if l > 0 { n += 1 + l + sovTypes(uint64(l)) } if m.Rank != 0 { n += 1 + sovTypes(uint64(m.Rank)) } return n } func sovTypes(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozTypes(x uint64) (n int) { return sovTypes(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *Params) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: Params: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: Params: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field CalculationPeriod", wireType) } m.CalculationPeriod = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.CalculationPeriod |= int64(b&0x7F) << shift if b < 0x80 { break } } case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field DampingFactor", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTypes } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTypes } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.DampingFactor.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 3: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Tolerance", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTypes } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTypes } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Tolerance.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTypes(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTypes } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *RankedParticle) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: RankedParticle: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: RankedParticle: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Particle", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTypes } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTypes } if postIndex > l { return io.ErrUnexpectedEOF } m.Particle = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field Rank", wireType) } m.Rank = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.Rank |= uint64(b&0x7F) << shift if b < 0x80 { break } } default: iNdEx = preIndex skippy, err := skipTypes(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTypes } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipTypes(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTypes } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTypes } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTypes } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthTypes } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupTypes } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthTypes } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthTypes = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowTypes = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupTypes = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/rank/wasm/interface.go ================================================ package wasm import ( "encoding/json" errorsmod "cosmossdk.io/errors" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/rank/keeper" pluginstypes "github.com/cybercongress/go-cyber/v7/plugins/types" ) type Querier struct { keeper *keeper.StateKeeper } func NewWasmQuerier(keeper *keeper.StateKeeper) *Querier { return &Querier{keeper} } func (querier *Querier) HandleQuery(ctx sdk.Context, query pluginstypes.CyberQuery) ([]byte, error) { switch { case query.ParticleRank != nil: res, err := querier.keeper.Rank(ctx, query.ParticleRank) if err != nil { return nil, errorsmod.Wrap(err, "failed to get particle rank") } responseBytes, err := json.Marshal(res) if err != nil { return nil, errorsmod.Wrap(err, "failed to serialize particle rank response") } return responseBytes, nil default: return nil, pluginstypes.ErrHandleQuery } } ================================================ FILE: x/resources/client/cli/query.go ================================================ package cli import ( "context" "fmt" "strconv" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/spf13/cobra" ctypes "github.com/cybercongress/go-cyber/v7/types" "github.com/cybercongress/go-cyber/v7/x/resources/types" ) func GetQueryCmd() *cobra.Command { queryCmd := &cobra.Command{ Use: types.ModuleName, Short: fmt.Sprintf("Querying commands for the %s module", types.ModuleName), DisableFlagParsing: true, SuggestionsMinimumDistance: 2, RunE: client.ValidateCmd, } queryCmd.AddCommand( GetCmdQueryParams(), GetCmdQueryInvestmintAmount(), ) return queryCmd } func GetCmdQueryParams() *cobra.Command { cmd := &cobra.Command{ Use: "params", Short: "Query the current resources module parameters information", Args: cobra.NoArgs, RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientQueryContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) res, err := queryClient.Params( context.Background(), &types.QueryParamsRequest{}, ) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } func GetCmdQueryInvestmintAmount() *cobra.Command { cmd := &cobra.Command{ Use: "investmint [amount] [resource] [length]", Short: "Query resources return on investmint", Args: cobra.ExactArgs(3), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientQueryContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) amount, err := sdk.ParseCoinNormalized(args[0]) if err != nil { return fmt.Errorf("coin %s not a valid coin, please input a valid coin", args[0]) } if amount.Denom != ctypes.SCYB { return fmt.Errorf("coin %s not a valid coin, please input a valid coin", args[0]) } if args[1] != ctypes.VOLT && args[1] != ctypes.AMPERE { return fmt.Errorf("resource %s not a valid resource, please input a valid resource", args[1]) } length, err := strconv.ParseUint(args[2], 10, 64) if err != nil { return fmt.Errorf("block period %s not a valid uint, please input a valid block period", args[1]) } res, err := queryClient.Investmint( context.Background(), &types.QueryInvestmintRequest{ Amount: amount, Resource: args[1], Length: length, }, ) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } ================================================ FILE: x/resources/client/cli/tx.go ================================================ package cli import ( "fmt" "strconv" "strings" "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/client/tx" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/version" "github.com/spf13/cobra" "github.com/cosmos/cosmos-sdk/client" ctypes "github.com/cybercongress/go-cyber/v7/types" "github.com/cybercongress/go-cyber/v7/x/resources/types" ) func NewTxCmd() *cobra.Command { txCmd := &cobra.Command{ Use: types.ModuleName, Short: fmt.Sprintf("%s transactions subcommands", types.ModuleName), DisableFlagParsing: true, SuggestionsMinimumDistance: 2, RunE: client.ValidateCmd, } txCmd.AddCommand( GetCmdInvestmint(), ) return txCmd } func GetCmdInvestmint() *cobra.Command { cmd := &cobra.Command{ Use: "investmint [amount] [resource] [length]", Args: cobra.ExactArgs(3), Short: "Investmint basic resource with the return of advanced system resource", Long: strings.TrimSpace( fmt.Sprintf(`Long. Example: $ %s tx resources investmint 1000000000hydrogen millivolt 2500000 --from `, version.Version, ), ), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientTxContext(cmd) if err != nil { return err } agent := clientCtx.GetFromAddress() amount, err := sdk.ParseCoinNormalized(args[0]) if err != nil { return fmt.Errorf("coin %s not a valid coin, please input a valid coin", args[0]) } if amount.Denom != ctypes.SCYB { return fmt.Errorf("coin %s not a valid coin, please input a valid coin", args[0]) } if args[1] != ctypes.VOLT && args[1] != ctypes.AMPERE { return fmt.Errorf("resource %s not a valid resource, please input a valid resource", args[1]) } length, err := strconv.ParseUint(args[2], 10, 64) if err != nil { return fmt.Errorf("block period %s not a valid uint, please input a valid block period", args[1]) } msg := types.NewMsgInvestmint(agent, amount, args[1], length) if err := msg.ValidateBasic(); err != nil { return err } return tx.GenerateOrBroadcastTxCLI(clientCtx, cmd.Flags(), msg) }, } flags.AddTxFlagsToCmd(cmd) return cmd } ================================================ FILE: x/resources/exported/exported.go ================================================ package exported import ( sdk "github.com/cosmos/cosmos-sdk/types" paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" ) type ( ParamSet = paramtypes.ParamSet // Subspace defines an interface that implements the legacy x/params Subspace // type. // // NOTE: This is used solely for migration of x/params managed parameters. Subspace interface { GetParamSet(ctx sdk.Context, ps ParamSet) } ) type GraphKeeper interface { GetBurnedVolts(ctx sdk.Context) uint64 GetBurnedAmperes(ctx sdk.Context) uint64 } ================================================ FILE: x/resources/keeper/genesis.go ================================================ package keeper import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/resources/types" ) func InitGenesis(ctx sdk.Context, k Keeper, data types.GenesisState) { if err := k.SetParams(ctx, data.Params); err != nil { panic(err) } } func ExportGenesis(ctx sdk.Context, k Keeper) *types.GenesisState { params := k.GetParams(ctx) return types.NewGenesisState(params) } ================================================ FILE: x/resources/keeper/grpc_query.go ================================================ package keeper import ( "context" errorsmod "cosmossdk.io/errors" sdk "github.com/cosmos/cosmos-sdk/types" "google.golang.org/grpc/codes" "google.golang.org/grpc/status" ctypes "github.com/cybercongress/go-cyber/v7/types" "github.com/cybercongress/go-cyber/v7/x/resources/types" ) var _ types.QueryServer = Keeper{} func (k Keeper) Params(goCtx context.Context, request *types.QueryParamsRequest) (*types.QueryParamsResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) params := k.GetParams(ctx) return &types.QueryParamsResponse{Params: params}, nil } func (k Keeper) Investmint(goCtx context.Context, request *types.QueryInvestmintRequest) (*types.QueryInvestmintResponse, error) { if request == nil { return nil, status.Errorf(codes.InvalidArgument, "empty request") } if request.Amount.Denom != ctypes.SCYB { return nil, errorsmod.Wrap(types.ErrInvalidBaseResource, request.Amount.String()) } if request.Resource != ctypes.VOLT && request.Resource != ctypes.AMPERE { return nil, errorsmod.Wrap(types.ErrResourceNotExist, request.Resource) } ctx := sdk.UnwrapSDKContext(goCtx) maxPeriod := k.GetMaxPeriod(ctx, request.Resource) amount := k.CalculateInvestmint(ctx, request.Amount, request.Resource, maxPeriod) amount = k.applySupplyExponentialAdjustment(ctx, request.Resource, amount) return &types.QueryInvestmintResponse{Amount: amount}, nil } func (k Keeper) AdjustedPrice(goCtx context.Context, request *types.QueryAdjustedPriceRequest) (*types.QueryAdjustedPriceResponse, error) { if request == nil { return nil, status.Errorf(codes.InvalidArgument, "empty request") } if request.Resource != ctypes.VOLT && request.Resource != ctypes.AMPERE { return nil, errorsmod.Wrap(types.ErrResourceNotExist, request.Resource) } ctx := sdk.UnwrapSDKContext(goCtx) amount := k.applySupplyExponentialAdjustment(ctx, request.Resource, request.Base) return &types.QueryAdjustedPriceResponse{Adjusted: amount}, nil } ================================================ FILE: x/resources/keeper/keeper.go ================================================ package keeper import ( "fmt" "github.com/cybercongress/go-cyber/v7/x/resources/exported" "math" errorsmod "cosmossdk.io/errors" storetypes "github.com/cosmos/cosmos-sdk/store/types" "github.com/cometbft/cometbft/libs/log" "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" vestingtypes "github.com/cosmos/cosmos-sdk/x/auth/vesting/types" ctypes "github.com/cybercongress/go-cyber/v7/types" bandwithkeeper "github.com/cybercongress/go-cyber/v7/x/bandwidth/keeper" "github.com/cybercongress/go-cyber/v7/x/resources/types" ) type Keeper struct { cdc codec.BinaryCodec storeKey storetypes.StoreKey accountKeeper types.AccountKeeper graphKeeper exported.GraphKeeper bankKeeper types.BankKeeper bandwidthMeter *bandwithkeeper.BandwidthMeter authority string } // Exponential supply half-life controls: mint factor = 0.5^(supply / halfLife) // Larger halfLife -> slower decay (more mint per same supply) var ( expHalfLifeVolt = sdk.NewInt(4000000000) // 4*1e9 expHalfLifeAmp = sdk.NewInt(32000000000) // 3.2*1e10 ) func NewKeeper( cdc codec.BinaryCodec, key storetypes.StoreKey, ak types.AccountKeeper, bk types.BankKeeper, bm *bandwithkeeper.BandwidthMeter, gk exported.GraphKeeper, authority string, ) Keeper { if addr := ak.GetModuleAddress(types.ResourcesName); addr == nil { panic(fmt.Sprintf("%s module account has not been set", types.ResourcesName)) } keeper := Keeper{ cdc: cdc, storeKey: key, accountKeeper: ak, bankKeeper: bk, bandwidthMeter: bm, graphKeeper: gk, authority: authority, } return keeper } func (k Keeper) GetAuthority() string { return k.authority } func (k Keeper) Logger(ctx sdk.Context) log.Logger { return ctx.Logger().With("module", fmt.Sprintf("x/%s", types.ModuleName)) } func (k Keeper) SetParams(ctx sdk.Context, p types.Params) error { if err := p.Validate(); err != nil { return err } store := ctx.KVStore(k.storeKey) bz := k.cdc.MustMarshal(&p) store.Set(types.ParamsKey, bz) return nil } func (k Keeper) GetParams(ctx sdk.Context) (p types.Params) { store := ctx.KVStore(k.storeKey) bz := store.Get(types.ParamsKey) if bz == nil { return p } k.cdc.MustUnmarshal(bz, &p) return p } func (k Keeper) ConvertResource( ctx sdk.Context, neuron sdk.AccAddress, amount sdk.Coin, resource string, _ uint64, ) (sdk.Coin, error) { // mint volts or amperes based on current max period and rate // burn hydrogen (not vesting) // put newly minted volts/amperes to vesting schedule with minimal period (1 second) for backward compatibility maxPeriod := k.GetMaxPeriod(ctx, resource) if k.bankKeeper.SpendableCoins(ctx, neuron).AmountOf(ctypes.SCYB).LT(amount.Amount) { return sdk.Coin{}, sdkerrors.ErrInsufficientFunds } err := k.bankKeeper.SendCoinsFromAccountToModule(ctx, neuron, types.ResourcesName, sdk.NewCoins(amount)) if err != nil { return sdk.Coin{}, errorsmod.Wrapf(types.ErrTimeLockCoins, err.Error()) } err = k.bankKeeper.BurnCoins(ctx, types.ResourcesName, sdk.NewCoins(amount)) if err != nil { return sdk.Coin{}, errorsmod.Wrapf(types.ErrBurnCoins, err.Error()) } minted, err := k.Mint(ctx, neuron, amount, resource, maxPeriod) if err != nil { return sdk.Coin{}, errorsmod.Wrapf(types.ErrIssueCoins, err.Error()) } return minted, err } func (k Keeper) AddTimeLockedCoinsToAccount(ctx sdk.Context, recipientAddr sdk.AccAddress, amt sdk.Coins, length int64) error { acc := k.accountKeeper.GetAccount(ctx, recipientAddr) if acc == nil { return errorsmod.Wrapf(types.ErrAccountNotFound, recipientAddr.String()) } switch acc.(type) { case *vestingtypes.PeriodicVestingAccount: return k.AddTimeLockedCoinsToPeriodicVestingAccount(ctx, recipientAddr, amt, length, false) case *authtypes.BaseAccount: return k.AddTimeLockedCoinsToBaseAccount(ctx, recipientAddr, amt, length) default: return errorsmod.Wrapf(types.ErrInvalidAccountType, "%T", acc) } } func (k Keeper) AddTimeLockedCoinsToPeriodicVestingAccount(ctx sdk.Context, recipientAddr sdk.AccAddress, amt sdk.Coins, length int64, mergeSlot bool) error { err := k.addCoinsToVestingSchedule(ctx, recipientAddr, amt, length, mergeSlot) if err != nil { return err } return nil } func (k Keeper) AddTimeLockedCoinsToBaseAccount(ctx sdk.Context, recipientAddr sdk.AccAddress, amt sdk.Coins, length int64) error { acc := k.accountKeeper.GetAccount(ctx, recipientAddr) bacc := authtypes.NewBaseAccount(acc.GetAddress(), acc.GetPubKey(), acc.GetAccountNumber(), acc.GetSequence()) newPeriods := vestingtypes.Periods{types.NewPeriod(amt, length)} bva := vestingtypes.NewBaseVestingAccount(bacc, amt, ctx.BlockTime().Unix()+length) pva := vestingtypes.NewPeriodicVestingAccountRaw(bva, ctx.BlockTime().Unix(), newPeriods) k.accountKeeper.SetAccount(ctx, pva) return nil } func (k Keeper) addCoinsToVestingSchedule(ctx sdk.Context, addr sdk.AccAddress, amt sdk.Coins, length int64, mergeSlot bool) error { acc := k.accountKeeper.GetAccount(ctx, addr) vacc := acc.(*vestingtypes.PeriodicVestingAccount) // just mock short vesting period for backward compatibility with ui newPeriod := types.NewPeriod(amt, length) vacc.VestingPeriods = append(vestingtypes.Periods{}, newPeriod) vacc.StartTime = ctx.BlockTime().Unix() vacc.EndTime = ctx.BlockTime().Unix() + length vacc.OriginalVesting = newPeriod.Amount k.accountKeeper.SetAccount(ctx, vacc) return nil } func (k Keeper) Mint(ctx sdk.Context, recipientAddr sdk.AccAddress, amt sdk.Coin, resource string, length uint64) (sdk.Coin, error) { acc := k.accountKeeper.GetAccount(ctx, recipientAddr) if acc == nil { return sdk.Coin{}, errorsmod.Wrapf(types.ErrAccountNotFound, recipientAddr.String()) } toMint := k.CalculateInvestmint(ctx, amt, resource, length) // Apply exponential supply-based decreasing adjustment so each next minter mints less toMint = k.applySupplyExponentialAdjustment(ctx, resource, toMint) if toMint.Amount.LT(sdk.NewInt(1000)) { return sdk.Coin{}, errorsmod.Wrapf(types.ErrSmallReturn, recipientAddr.String()) } err := k.bankKeeper.MintCoins(ctx, types.ResourcesName, sdk.NewCoins(toMint)) if err != nil { return sdk.Coin{}, errorsmod.Wrapf(types.ErrMintCoins, recipientAddr.String()) } err = k.bankKeeper.SendCoinsFromModuleToAccount(ctx, types.ResourcesName, recipientAddr, sdk.NewCoins(toMint)) if err != nil { return sdk.Coin{}, errorsmod.Wrapf(types.ErrSendMintedCoins, recipientAddr.String()) } // adding converted resources to vesting schedule err = k.AddTimeLockedCoinsToAccount(ctx, recipientAddr, sdk.NewCoins(toMint), int64(1)) if err != nil { return sdk.Coin{}, errorsmod.Wrapf(types.ErrTimeLockCoins, err.Error()) } if resource == ctypes.VOLT { k.bandwidthMeter.AddToDesirableBandwidth(ctx, toMint.Amount.Uint64()) } return toMint, nil } func (k Keeper) CalculateInvestmint(ctx sdk.Context, amt sdk.Coin, resource string, length uint64) sdk.Coin { var toMint sdk.Coin var halving sdk.Dec params := k.GetParams(ctx) switch resource { case ctypes.VOLT: cycles := sdk.NewDec(int64(length)).QuoInt64(int64(params.BaseInvestmintPeriodVolt)) base := sdk.NewDec(amt.Amount.Int64()).QuoInt64(params.BaseInvestmintAmountVolt.Amount.Int64()) // NOTE out of parametrization, custom code is applied here in order to shift the HALVINGS START 6M BLOCKS LATER but keep base halving parameter same if ctx.BlockHeight() > 15000000 { halving = sdk.NewDecWithPrec(int64(math.Pow(0.5, float64((ctx.BlockHeight()-6000000)/int64(params.HalvingPeriodVoltBlocks)))*10000), 4) } else { halving = sdk.OneDec() } if halving.LT(sdk.NewDecWithPrec(1, 2)) { halving = sdk.NewDecWithPrec(1, 2) } toMint = ctypes.NewVoltCoin(base.Mul(cycles).Mul(halving).Mul(sdk.NewDec(1000)).TruncateInt64()) k.Logger(ctx).Info("Investmint", "cycles", cycles.String(), "base", base.String(), "halving", halving.String(), "mint", toMint.String()) case ctypes.AMPERE: cycles := sdk.NewDec(int64(length)).QuoInt64(int64(params.BaseInvestmintPeriodAmpere)) base := sdk.NewDec(amt.Amount.Int64()).QuoInt64(params.BaseInvestmintAmountAmpere.Amount.Int64()) // NOTE out of parametrization, custom code is applied here in order to shift the HALVINGS START 6M BLOCKS LATER but keep base halving parameter same if ctx.BlockHeight() > 15000000 { halving = sdk.NewDecWithPrec(int64(math.Pow(0.5, float64((ctx.BlockHeight()-6000000)/int64(params.HalvingPeriodAmpereBlocks)))*10000), 4) } else { halving = sdk.OneDec() } if halving.LT(sdk.NewDecWithPrec(1, 2)) { halving = sdk.NewDecWithPrec(1, 2) } toMint = ctypes.NewAmpereCoin(base.Mul(cycles).Mul(halving).Mul(sdk.NewDec(1000)).TruncateInt64()) k.Logger(ctx).Info("Investmint", "cycles", cycles.String(), "base", base.String(), "halving", halving.String(), "mint", toMint.String()) } return toMint } // applySupplyExponentialAdjustment reduces base mint using f = 0.5^(supply / halfLife) // where halfLife is resource-specific. Returns a coin with the same denom adjusted by f. func (k Keeper) applySupplyExponentialAdjustment(ctx sdk.Context, resource string, base sdk.Coin) sdk.Coin { if !base.Amount.IsPositive() { return base } totalSupply := k.bankKeeper.GetSupply(ctx, resource).Amount if resource == ctypes.VOLT { totalSupply = totalSupply.Add(sdk.NewInt(int64(k.graphKeeper.GetBurnedVolts(ctx)))) } if resource == ctypes.AMPERE { totalSupply = totalSupply.Add(sdk.NewInt(int64(k.graphKeeper.GetBurnedAmperes(ctx)))) } var halfLife sdk.Int switch resource { case ctypes.VOLT: halfLife = expHalfLifeVolt case ctypes.AMPERE: halfLife = expHalfLifeAmp default: return base } if !halfLife.IsPositive() { return base } // factor = 0.5 ^ (supply / halfLife) // compute using high-precision decimals supplyDec := sdk.NewDecFromInt(totalSupply) halfLifeDec := sdk.NewDecFromInt(halfLife) ratio := supplyDec.Quo(halfLifeDec) // Convert to float64 for exponent; bounded to avoid NaN/Inf r64 := ratio.MustFloat64() if math.IsNaN(r64) || math.IsInf(r64, 0) || r64 < 0 { return base } factor := math.Pow(0.5, r64) if factor < 0 { factor = 0 } if factor > 1 { factor = 1 } // Apply factor on base.Amount baseDec := sdk.NewDecFromInt(base.Amount) // Use big.Rat via String to minimize precision drift when multiplying factorDec, err := sdk.NewDecFromStr(fmt.Sprintf("%.18f", factor)) if err != nil { return base } adjustedDec := baseDec.Mul(factorDec) adjusted := base adjusted.Amount = adjustedDec.TruncateInt() // Ensure we don't drop to zero unexpectedly if base was small but positive if base.Amount.IsPositive() && adjusted.Amount.IsZero() { adjusted.Amount = sdk.OneInt() } k.Logger(ctx).Info("Supply exponential adjust", "resource", resource, "supply", totalSupply.String(), "halfLife", halfLife.String(), "factor", fmt.Sprintf("%.10f", factor), "base", base.Amount.String(), "adjusted", adjusted.Amount.String()) return adjusted } func (k Keeper) GetMaxPeriod(ctx sdk.Context, resource string) uint64 { var availableLength uint64 passed := ctx.BlockHeight() params := k.GetParams(ctx) switch resource { case ctypes.VOLT: halvingVolt := params.HalvingPeriodVoltBlocks doubling := uint32(math.Pow(2, float64(passed/int64(halvingVolt)))) availableLength = uint64(doubling * halvingVolt * 6) case ctypes.AMPERE: halvingAmpere := params.HalvingPeriodAmpereBlocks doubling := uint32(math.Pow(2, float64(passed/int64(halvingAmpere)))) availableLength = uint64(doubling * halvingAmpere * 6) } return availableLength } ================================================ FILE: x/resources/keeper/migrator.go ================================================ package keeper import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/resources/exported" v2 "github.com/cybercongress/go-cyber/v7/x/resources/migrations/v2" ) // Migrator is a struct for handling in-place state migrations. type Migrator struct { keeper Keeper legacySubspace exported.Subspace } func NewMigrator(k Keeper, ss exported.Subspace) Migrator { return Migrator{ keeper: k, legacySubspace: ss, } } func (m Migrator) Migrate1to2(ctx sdk.Context) error { return v2.Migrate(ctx, ctx.KVStore(m.keeper.storeKey), m.legacySubspace, m.keeper.cdc) } ================================================ FILE: x/resources/keeper/msg_server.go ================================================ package keeper import ( "context" "strconv" govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" "cosmossdk.io/errors" "github.com/armon/go-metrics" "github.com/cosmos/cosmos-sdk/telemetry" ctypes "github.com/cybercongress/go-cyber/v7/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/resources/types" ) type msgServer struct { Keeper } func NewMsgServerImpl(keeper Keeper) types.MsgServer { return &msgServer{keeper} } var _ types.MsgServer = msgServer{} func (server msgServer) Investmint(goCtx context.Context, msg *types.MsgInvestmint) (*types.MsgInvestmintResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) neuron, err := sdk.AccAddressFromBech32(msg.Neuron) if err != nil { return nil, err } switch msg.Resource { case ctypes.VOLT: if msg.Amount.Denom != server.GetParams(ctx).BaseInvestmintAmountVolt.Denom { return nil, errors.Wrap(types.ErrInvalidBaseResource, msg.Amount.Denom) } case ctypes.AMPERE: if msg.Amount.Denom != server.GetParams(ctx).BaseInvestmintAmountAmpere.Denom { return nil, errors.Wrap(types.ErrInvalidBaseResource, msg.Amount.Denom) } } minted, err := server.ConvertResource(ctx, neuron, msg.Amount, msg.Resource, msg.Length) if err != nil { return nil, err } defer telemetry.IncrCounterWithLabels( []string{types.ModuleName, "investmint"}, 1, []metrics.Label{ telemetry.NewLabel("resource", msg.Resource), }, ) ctx.EventManager().EmitEvents(sdk.Events{ sdk.NewEvent( sdk.EventTypeMessage, sdk.NewAttribute(sdk.AttributeKeyModule, types.AttributeValueCategory), sdk.NewAttribute(sdk.AttributeKeySender, msg.Neuron), ), sdk.NewEvent( types.EventTypeInvestmint, sdk.NewAttribute(types.AttributeKeyNeuron, msg.Neuron), sdk.NewAttribute(types.AttributeKeyAmount, msg.Amount.String()), sdk.NewAttribute(types.AttributeKeyResource, msg.Resource), sdk.NewAttribute(types.AttributeKeyLength, strconv.FormatUint(msg.Length, 10)), sdk.NewAttribute(types.AttributeKeyMinted, minted.Amount.String()), ), }) return &types.MsgInvestmintResponse{}, nil } func (server msgServer) UpdateParams(goCtx context.Context, req *types.MsgUpdateParams) (*types.MsgUpdateParamsResponse, error) { if server.authority != req.Authority { return nil, errors.Wrapf(govtypes.ErrInvalidSigner, "invalid authority; expected %s, got %s", server.authority, req.Authority) } ctx := sdk.UnwrapSDKContext(goCtx) if err := server.SetParams(ctx, req.Params); err != nil { return nil, err } return &types.MsgUpdateParamsResponse{}, nil } ================================================ FILE: x/resources/migrations/v2/migrate.go ================================================ package v2 import ( "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/resources/exported" "github.com/cybercongress/go-cyber/v7/x/resources/types" ) func Migrate( ctx sdk.Context, store sdk.KVStore, legacySubspace exported.Subspace, cdc codec.BinaryCodec, ) error { var currParams types.Params legacySubspace.GetParamSet(ctx, &currParams) if err := currParams.Validate(); err != nil { return err } bz := cdc.MustMarshal(&currParams) store.Set(types.ParamsKey, bz) return nil } ================================================ FILE: x/resources/module.go ================================================ package resources import ( "context" "encoding/json" "fmt" "github.com/cosmos/cosmos-sdk/client" codectypes "github.com/cosmos/cosmos-sdk/codec/types" "github.com/grpc-ecosystem/grpc-gateway/runtime" abci "github.com/cometbft/cometbft/abci/types" "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" "github.com/spf13/cobra" "github.com/cybercongress/go-cyber/v7/x/resources/client/cli" "github.com/cybercongress/go-cyber/v7/x/resources/exported" "github.com/cybercongress/go-cyber/v7/x/resources/keeper" "github.com/cybercongress/go-cyber/v7/x/resources/types" ) var ( _ module.AppModule = AppModule{} _ module.AppModuleBasic = AppModuleBasic{} ) type AppModuleBasic struct { cdc codec.Codec } func (AppModuleBasic) Name() string { return types.ModuleName } func (AppModuleBasic) RegisterLegacyAminoCodec(cdc *codec.LegacyAmino) { types.RegisterLegacyAminoCodec(cdc) } func (AppModuleBasic) DefaultGenesis(cdc codec.JSONCodec) json.RawMessage { return cdc.MustMarshalJSON(types.DefaultGenesisState()) } func (AppModuleBasic) ValidateGenesis(cdc codec.JSONCodec, _ client.TxEncodingConfig, bz json.RawMessage) error { var data types.GenesisState err := cdc.UnmarshalJSON(bz, &data) if err != nil { return fmt.Errorf("failed to unmarshal %s genesis state: %w", types.ModuleName, err) } return types.ValidateGenesis(data) } func (AppModuleBasic) RegisterGRPCGatewayRoutes(clientCtx client.Context, mux *runtime.ServeMux) { if err := types.RegisterQueryHandlerClient(context.Background(), mux, types.NewQueryClient(clientCtx)); err != nil { panic(err) } } func (AppModuleBasic) GetTxCmd() *cobra.Command { return cli.NewTxCmd() } func (AppModuleBasic) GetQueryCmd() *cobra.Command { return cli.GetQueryCmd() } func (AppModuleBasic) RegisterInterfaces(registry codectypes.InterfaceRegistry) { types.RegisterInterfaces(registry) } type AppModule struct { AppModuleBasic cdc codec.Codec keeper keeper.Keeper legacySubspace exported.Subspace } func NewAppModule( cdc codec.Codec, k keeper.Keeper, ss exported.Subspace, ) AppModule { return AppModule{ AppModuleBasic: AppModuleBasic{cdc: cdc}, cdc: cdc, keeper: k, legacySubspace: ss, } } func (AppModule) Name() string { return types.ModuleName } func (am AppModule) RegisterInvariants(_ sdk.InvariantRegistry) {} func (am AppModule) RegisterServices(cfg module.Configurator) { types.RegisterMsgServer(cfg.MsgServer(), keeper.NewMsgServerImpl(am.keeper)) types.RegisterQueryServer(cfg.QueryServer(), am.keeper) m := keeper.NewMigrator(am.keeper, am.legacySubspace) if err := cfg.RegisterMigration(types.ModuleName, 1, m.Migrate1to2); err != nil { panic(fmt.Sprintf("failed to migrate x/%s from version 1 to 2: %v", types.ModuleName, err)) } } func (am AppModule) InitGenesis(ctx sdk.Context, cdc codec.JSONCodec, data json.RawMessage) []abci.ValidatorUpdate { var genesisState types.GenesisState cdc.MustUnmarshalJSON(data, &genesisState) keeper.InitGenesis(ctx, am.keeper, genesisState) return []abci.ValidatorUpdate{} } func (am AppModule) ExportGenesis(ctx sdk.Context, cdc codec.JSONCodec) json.RawMessage { gs := keeper.ExportGenesis(ctx, am.keeper) return cdc.MustMarshalJSON(gs) } func (am AppModule) ConsensusVersion() uint64 { return 2 } func (am AppModule) BeginBlock(_ sdk.Context, _ abci.RequestBeginBlock) {} func (AppModule) EndBlock(_ sdk.Context, _ abci.RequestEndBlock) []abci.ValidatorUpdate { return []abci.ValidatorUpdate{} } ================================================ FILE: x/resources/spec/00_concepts.md ================================================ # Concepts ## Vesting ## Investmint ## Resource Slots ## Resources Economy ================================================ FILE: x/resources/spec/01_api.md ================================================ # API # REST | Path | Parameters | Description | | --------------------------------------| ----------------------------- | ------------------------------ | | /resources/parameters | | get module params | | /resources/investmint_amount | amount, resource and length | get potential return amount | # GRPC | Path | Parameters | Description | | ------------------------------------------------------| --------------------------- | --------------------------- | | /cyber/resources/v1beta1/resources/params | | get module params | | /cyber/resources/v1beta1/resources/investmint_amount | amount, resource and length | get potential return amount | ================================================ FILE: x/resources/spec/02_state.md ================================================ # State ## Periodic Vesting Account (auth) A vesting account implementation that vests coins according to a custom vesting schedule. ``` type PeriodicVestingAccount struct { base_vesting_account BaseVestingAccount start_time uint64 vesting_periods []Period } ``` ## Period (auth) ``` type Period struct { length int64 amount []sdk.Coin } ``` ## Keys - ModuleName, RouterKey: `energy` ================================================ FILE: x/resources/spec/03_state_transitions.md ================================================ # State Transitions These messages (Msg) in the resources module trigger state transitions. ## Investmint 1. Check that the desirable period of lock is less than the currently available maximum period of lock 2. Check that the spendable balance is more than or equal to the desired amount to lock 3. Check that the desirable period of lock is more than the current minimum period of lock 4. Initialize periodic vesting account on the first investmint 6. Put provided neuron's basis resources (BOOT) into vesting schedule to desirable period to empty slot - add vesting period and update periodic vesting account (auth module) 7. Calculate the amount of resources to mint (VOLT/AMPERE/...) 8. Check that calculated amount more than 1000 units (1000 milliampere or 1000 millivolt for example) 9. Mint calculated amount of given resource to neuron and lock that resource to same lock period to the same slot - mint tokens to module `resources` account (bank module) - transfer from module account `resource` to neuron's account (bank module) - add and save vesting period to same slot and update periodic vesting account (auth module) 10. Check if it's first neuron's investmint operation and if so then charge personal neuron's bandwidth with 1000 bandwidth units (bandwidth module) 11. Increase desirable bandwidth if there was investmint operation to VOLT resource (bandwidth module) Note: neuron will be initially charged only if it will be first investmint operation to VOLT resource. This removes the gap to start neuron activity as soon as possible. Note: total supply of VOLT resource is desirable bandwidth of the network. ## Slots logic (simplified) 1. Basic resource (BOOT) and desirable resource (VOLT/AMPERE/...) goes to the same vesting slot 2. If there are empty slots and all current slots are active then add a new one as active and reorder slots 3. If there are some expired slots then clean them and reorder currently active slots and add a new one as an active slot 4. If there are all slots active (amount of active slots is equal to max_slots parameter) then return an error 5. If all slots are passed then clean all of them and put new as active slot Note: active slot => unlock time at future, expired slot => unlock time in past Note: for fully understanding of slots logic do research of `addCoinsToVestingSchedule` function ## Investmints calculation ``` cycle = neuron's desirable period of lock / base period for given resource base = neurons's desirable amount to lock / base amount for given resource halving = 2^(current block height / halving period) => mint and lock (cycles * base * halving) VOLT or AMPERES to given neuron ``` Note: VOLT and AMPERE as basic native computer's resources have separated base period/amount/halving parameters that adjustable with governance and dynamic cybernetic feedback loops (in a future release) Note: for fully understanding of resources economy do research of `Mint` function ================================================ FILE: x/resources/spec/04_messages.md ================================================ # Messages Messages (Msg) are objects that trigger state transitions. Msgs are wrapped in transactions (Txs) that clients submit to the network. The Cosmos SDK wraps and unwraps resources module messages from transactions. ## MsgInvestmint Neuron make investmint operation and lock base resource amount to given length with return of desired advanced resource locked to same length. ```go type MsgInvestmint struct { agent string // agent's address amount sdk.Coin // amount of basic resource to invesmint resource string // desirable resource length uint32 // desirable lock period in seconds } ``` The message will fail under the following conditions: - Stateless - if msg.Agent is not valid address - if msg.Amount is invalid (not positive or wrong denom) - if msg.Resource is invalid (resource not exist) - if msg.Length is equal to 0 - Stateful - if Msg.Length is more than available maximum lock period - if Msg.Length is less than available minimum lock period - if account have less spendable balance that Msg.Amount - if there are no empty or expired slots - if amount of resource in return less than 1000 milli{volt,amper} ================================================ FILE: x/resources/spec/05_events.md ================================================ # Events The resources module emits the following events: ## Msg's ### MsgInvestmint | Type | Attribute Key | Attribute Value | | ---------------- | ------------- | ---------------------- | | message | module | energy | | message | action | investmint | | investmint | agent | {agentAddress} | | investmint | amount | {baseResourceAmount} | | investmint | resource | {resourceDenom} | | investmint | length | {seconds} | | investmint | minted | {mintedResourceAmount} | ================================================ FILE: x/resources/spec/06_params.md ================================================ # Parameters The resources module contains the following parameters: | Key | Type | Example | | --------------------------- | -------------- | ---------------------- | | MaxSlots | uint32 | 8 | | BaseHalvingPeriodVolt | uint32 | 12000000 (blocks) | | BaseHalvingPeriodAmpere | uint32 | 12000000 (blocks) | | BaseInvestmintPeriodVolt | uint32 | 3000000 (seconds) | | BaseInvestmintPeriodAmpere | uint32 | 3000000 (seconds) | | BaseInvestmintAmountVolt | sdk.Coin | 1000000000 BOOT | | BaseInvestmintAmountAmpere | sdk.Coin | 1000000000 BOOT | | MinInvestmintPeriodSec | uint32 | 86400 (seconds) | ## Max Slots Maximum amount of active slots at same amount of time ## Base Halving Period Volt Period of blocks to mint rate' halving for VOLT resource ## Base Halving Period Ampere Period of blocks to mint rate' halving for AMPERE resource ## Base Investmint Period Volt Base amount of basic resource (BOOT) to invesmint to get VOLT resource ## Base Investmint Period Ampere Base amount of basic resource (BOOT) to invesmint to get AMPERE resource ## Base Investmint Amount Volt Base length of lock period in seconds of basic resource (BOOT) to get VOLT resource ## Base Investmint Amount Ampere Base length of lock period in seconds of basic resource (BOOT) to get AMPERE resource ## Min Investmint Period Sec Minimum length of lock period for all investmint operations ================================================ FILE: x/resources/spec/07_wasm.md ================================================ # WASM LINE In addition to the core CosmWasm functionality, the resources module bindings include ## Messages Encoding - MsgInvestmint -------- Hack with [cw-cyber](https://github.com/cybercongress/cw-cyber) library ================================================ FILE: x/resources/spec/08_errors.md ================================================ # Errors The resources module may return the following errors: | Type | Code | Description | | ------------------------ | ------| ----------------------------------- | | ErrTimeLockCoins | 2 | error time lock coins | | ErrIssueCoins | 3 | error issue coins | | ErrMintCoins | 4 | error mint coins | | ErrBurnCoins | 5 | error burn coins | | ErrSendMintedCoins | 6 | error send minted coins | | ErrNotAvailablePeriod | 7 | not available period | | ErrInvalidAccountType | 8 | receiver account type not supported | | ErrAccountNotFound | 9 | account not found | | ErrResourceNotExist | 10 | resource not exist | | ErrFullSlots | 11 | all slots are full | | ErrSmallReturn | 12 | small resource's return amount | | ErrInvalidBaseResource | 13 | invalid base resource | ================================================ FILE: x/resources/spec/09_cli.md ================================================ # CLI ## Queries Query the current resources module parameters information: ```bash cyber query resources params ``` Query potential resources return on investmint with current rates: ```bash cyber query resources investmint [amount] [resource] [length] ``` ## Transactions Investmint basic resource with the return of advanced system' resource: ```bash cyber tx resources investmint [amount] [resource] [length] ``` ================================================ FILE: x/resources/spec/README.md ================================================ # `Resources` ## Abstract The resources module allows neurons to invest into computer's resources. ### Examples: I would like to `investmint` 1000000000 BOOT (1 GBOOT) to VOLT resource with lock for 30 DAYS (no spendable) and I will get newly minted 1 VOLT to my account locked for 30 DAYS (no spendable). ``` (1 GBOOT | 30 DAYS | VOLT) ---investmint---> locked (1 GBOOT | 30 DAYS) + minted and locked (1 VOLT | 30 DAYS) ``` I would like to `investmint` 4000000000 BOOT (4 GBOOT) to AMPERE resource with lock for 7 DAYS (no spendable) and I will get newly minted 1 AMPERE to my account locked for 7 DAYS (no spendable). ``` (4.2 GBOOT | 7 DAYS | AMPERE) ---investmint---> locked (4.2 GBOOT | 7 DAYS) + minted and locked (1 AMPERE | 7 DAYS) ``` ## Contents 1. **[Concepts](00_concepts.md)** 2. **[API](01_api.md)** 3. **[State](02_state.md)** 4. **[State Transitions](03_state_transitions.md)** 5. **[Messages](04_messages.md)** 6. **[Events](05_events.md)** 7. **[Parameters](06_params.md)** 8. **[WASM](07_wasm.md)** 9. **[Errors](08_errors.md)** 10. **[CLI](09_cli.md)** ================================================ FILE: x/resources/types/account.go ================================================ package types import ( vestingtypes "github.com/cosmos/cosmos-sdk/x/auth/vesting/types" ) // GetTotalVestingPeriodLength returns the summed length of all vesting periods func GetTotalVestingPeriodLength(periods vestingtypes.Periods) int64 { length := int64(0) for _, period := range periods { length += period.Length } return length } ================================================ FILE: x/resources/types/codec.go ================================================ package types import ( "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/codec/legacy" "github.com/cosmos/cosmos-sdk/codec/types" cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/msgservice" authzcodec "github.com/cosmos/cosmos-sdk/x/authz/codec" govcodec "github.com/cosmos/cosmos-sdk/x/gov/codec" ) func RegisterLegacyAminoCodec(cdc *codec.LegacyAmino) { legacy.RegisterAminoMsg(cdc, &MsgInvestmint{}, "cyber/resources/MsgInvestmint") cdc.RegisterConcrete(Params{}, "cyber/resources/Params", nil) } func RegisterInterfaces(registry types.InterfaceRegistry) { registry.RegisterImplementations((*sdk.Msg)(nil), &MsgInvestmint{}, &MsgUpdateParams{}, ) msgservice.RegisterMsgServiceDesc(registry, &_Msg_serviceDesc) } var ( amino = codec.NewLegacyAmino() ModuleCdc = codec.NewAminoCodec(amino) ) func init() { RegisterLegacyAminoCodec(amino) cryptocodec.RegisterCrypto(amino) sdk.RegisterLegacyAminoCodec(amino) RegisterLegacyAminoCodec(authzcodec.Amino) RegisterLegacyAminoCodec(govcodec.Amino) } ================================================ FILE: x/resources/types/errors.go ================================================ package types import ( errorsmod "cosmossdk.io/errors" ) var ( ErrTimeLockCoins = errorsmod.Register(ModuleName, 2, "error timelock coins") ErrIssueCoins = errorsmod.Register(ModuleName, 3, "error issue coins") ErrMintCoins = errorsmod.Register(ModuleName, 4, "error mint coins") ErrBurnCoins = errorsmod.Register(ModuleName, 5, "error burn coins") ErrSendMintedCoins = errorsmod.Register(ModuleName, 6, "error send minted coins") ErrNotAvailablePeriod = errorsmod.Register(ModuleName, 7, "period not available") ErrInvalidAccountType = errorsmod.Register(ModuleName, 8, "receiver account type not supported") ErrAccountNotFound = errorsmod.Register(ModuleName, 9, "account not found") ErrResourceNotExist = errorsmod.Register(ModuleName, 10, "resource does not exist") ErrFullSlots = errorsmod.Register(ModuleName, 11, "all slots are full") ErrSmallReturn = errorsmod.Register(ModuleName, 12, "insufficient resources return amount") ErrInvalidBaseResource = errorsmod.Register(ModuleName, 13, "invalid base resource") ) ================================================ FILE: x/resources/types/events.go ================================================ package types const ( EventTypeInvestmint = "investmint" AttributeKeyNeuron = "neuron" AttributeKeyAmount = "amount" AttributeKeyResource = "resource" AttributeKeyLength = "length" AttributeKeyMinted = "minted" AttributeValueCategory = ModuleName ) ================================================ FILE: x/resources/types/expected_keepers.go ================================================ package types import ( sdk "github.com/cosmos/cosmos-sdk/types" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" ) type AccountKeeper interface { GetAccount(ctx sdk.Context, addr sdk.AccAddress) authtypes.AccountI SetAccount(ctx sdk.Context, acc authtypes.AccountI) GetModuleAddress(name string) sdk.AccAddress } type BankKeeper interface { SendCoinsFromModuleToAccount(ctx sdk.Context, senderModule string, recipientAddr sdk.AccAddress, amt sdk.Coins) error SendCoinsFromAccountToModule(ctx sdk.Context, senderAddr sdk.AccAddress, recipientModule string, amt sdk.Coins) error MintCoins(ctx sdk.Context, name string, amt sdk.Coins) error SpendableCoins(ctx sdk.Context, addr sdk.AccAddress) sdk.Coins BurnCoins(ctx sdk.Context, name string, amt sdk.Coins) error GetSupply(ctx sdk.Context, denom string) sdk.Coin } ================================================ FILE: x/resources/types/genesis.go ================================================ package types func NewGenesisState(params Params) *GenesisState { return &GenesisState{ Params: params, } } func DefaultGenesisState() *GenesisState { return &GenesisState{ Params: DefaultParams(), } } func ValidateGenesis(state GenesisState) error { return state.Params.Validate() } ================================================ FILE: x/resources/types/genesis.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: cyber/resources/v1beta1/genesis.proto package types import ( fmt "fmt" io "io" math "math" math_bits "math/bits" _ "github.com/cosmos/gogoproto/gogoproto" proto "github.com/cosmos/gogoproto/proto" ) // Reference imports to suppress errors if they are not otherwise used. var ( _ = proto.Marshal _ = fmt.Errorf _ = math.Inf ) // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package type GenesisState struct { Params Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params"` } func (m *GenesisState) Reset() { *m = GenesisState{} } func (m *GenesisState) String() string { return proto.CompactTextString(m) } func (*GenesisState) ProtoMessage() {} func (*GenesisState) Descriptor() ([]byte, []int) { return fileDescriptor_72c3da48739423c6, []int{0} } func (m *GenesisState) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *GenesisState) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_GenesisState.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *GenesisState) XXX_Merge(src proto.Message) { xxx_messageInfo_GenesisState.Merge(m, src) } func (m *GenesisState) XXX_Size() int { return m.Size() } func (m *GenesisState) XXX_DiscardUnknown() { xxx_messageInfo_GenesisState.DiscardUnknown(m) } var xxx_messageInfo_GenesisState proto.InternalMessageInfo func (m *GenesisState) GetParams() Params { if m != nil { return m.Params } return Params{} } func init() { proto.RegisterType((*GenesisState)(nil), "cyber.resources.v1beta1.GenesisState") } func init() { proto.RegisterFile("cyber/resources/v1beta1/genesis.proto", fileDescriptor_72c3da48739423c6) } var fileDescriptor_72c3da48739423c6 = []byte{ // 211 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x4d, 0xae, 0x4c, 0x4a, 0x2d, 0xd2, 0x2f, 0x4a, 0x2d, 0xce, 0x2f, 0x2d, 0x4a, 0x4e, 0x2d, 0xd6, 0x2f, 0x33, 0x4c, 0x4a, 0x2d, 0x49, 0x34, 0xd4, 0x4f, 0x4f, 0xcd, 0x4b, 0x2d, 0xce, 0x2c, 0xd6, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x07, 0x2b, 0xd3, 0x83, 0x2b, 0xd3, 0x83, 0x2a, 0x93, 0x12, 0x49, 0xcf, 0x4f, 0xcf, 0x07, 0xab, 0xd1, 0x07, 0xb1, 0x20, 0xca, 0xa5, 0x94, 0x71, 0x99, 0x5a, 0x52, 0x59, 0x90, 0x0a, 0x35, 0x53, 0xc9, 0x97, 0x8b, 0xc7, 0x1d, 0x62, 0x49, 0x70, 0x49, 0x62, 0x49, 0xaa, 0x90, 0x2d, 0x17, 0x5b, 0x41, 0x62, 0x51, 0x62, 0x6e, 0xb1, 0x04, 0xa3, 0x02, 0xa3, 0x06, 0xb7, 0x91, 0xbc, 0x1e, 0x0e, 0x4b, 0xf5, 0x02, 0xc0, 0xca, 0x9c, 0x58, 0x4e, 0xdc, 0x93, 0x67, 0x08, 0x82, 0x6a, 0x72, 0xf2, 0x3d, 0xf1, 0x48, 0x8e, 0xf1, 0xc2, 0x23, 0x39, 0xc6, 0x07, 0x8f, 0xe4, 0x18, 0x27, 0x3c, 0x96, 0x63, 0xb8, 0xf0, 0x58, 0x8e, 0xe1, 0xc6, 0x63, 0x39, 0x86, 0x28, 0xe3, 0xf4, 0xcc, 0x92, 0x8c, 0xd2, 0x24, 0xbd, 0xe4, 0xfc, 0x5c, 0x7d, 0xb0, 0x91, 0xc9, 0xf9, 0x79, 0xe9, 0x45, 0xa9, 0xc5, 0xc5, 0xfa, 0xe9, 0xf9, 0xba, 0x10, 0x97, 0x56, 0x20, 0xb9, 0x15, 0xec, 0xc6, 0x24, 0x36, 0xb0, 0x23, 0x8d, 0x01, 0x01, 0x00, 0x00, 0xff, 0xff, 0xa8, 0xf5, 0x8f, 0xfc, 0x21, 0x01, 0x00, 0x00, } func (m *GenesisState) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *GenesisState) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *GenesisState) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.Params.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintGenesis(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa return len(dAtA) - i, nil } func encodeVarintGenesis(dAtA []byte, offset int, v uint64) int { offset -= sovGenesis(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *GenesisState) Size() (n int) { if m == nil { return 0 } var l int _ = l l = m.Params.Size() n += 1 + l + sovGenesis(uint64(l)) return n } func sovGenesis(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozGenesis(x uint64) (n int) { return sovGenesis(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *GenesisState) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenesis } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: GenesisState: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: GenesisState: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenesis } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthGenesis } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenesis } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Params.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipGenesis(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthGenesis } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipGenesis(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowGenesis } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowGenesis } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowGenesis } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthGenesis } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupGenesis } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthGenesis } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthGenesis = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowGenesis = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupGenesis = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/resources/types/keys.go ================================================ package types const ( ModuleName = "resources" StoreKey = ModuleName RouterKey = ModuleName ResourcesName = "resources" ) var ParamsKey = []byte{0x00} ================================================ FILE: x/resources/types/msgs.go ================================================ package types import ( errorsmod "cosmossdk.io/errors" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" ctypes "github.com/cybercongress/go-cyber/v7/types" ) const ( TypeMsgInvestmint = "investmint" ) var ( _ sdk.Msg = &MsgInvestmint{} _ sdk.Msg = &MsgUpdateParams{} ) func NewMsgInvestmint( neuron sdk.AccAddress, amount sdk.Coin, resource string, length uint64, ) *MsgInvestmint { return &MsgInvestmint{ Neuron: neuron.String(), Amount: amount, Resource: resource, Length: length, } } func (msg MsgInvestmint) Route() string { return RouterKey } func (msg MsgInvestmint) Type() string { return TypeMsgInvestmint } func (msg MsgInvestmint) ValidateBasic() error { _, err := sdk.AccAddressFromBech32(msg.Neuron) if err != nil { return errorsmod.Wrapf(sdkerrors.ErrInvalidAddress, "invalid neuron address: %s", err) } if !msg.Amount.IsValid() || !msg.Amount.IsPositive() { return errorsmod.Wrap(sdkerrors.ErrInvalidCoins, msg.Amount.String()) } if msg.Resource != ctypes.VOLT && msg.Resource != ctypes.AMPERE { return errorsmod.Wrap(ErrResourceNotExist, msg.Resource) } if msg.Length == 0 { return ErrNotAvailablePeriod } return nil } func (msg MsgInvestmint) GetSignBytes() []byte { bz := ModuleCdc.MustMarshalJSON(&msg) return sdk.MustSortJSON(bz) } func (msg MsgInvestmint) GetSigners() []sdk.AccAddress { addr, err := sdk.AccAddressFromBech32(msg.Neuron) if err != nil { panic(err) } return []sdk.AccAddress{addr} } // GetSignBytes implements the LegacyMsg interface. func (m MsgUpdateParams) GetSignBytes() []byte { return sdk.MustSortJSON(ModuleCdc.MustMarshalJSON(&m)) } // GetSigners returns the expected signers for a MsgUpdateParams message. func (m *MsgUpdateParams) GetSigners() []sdk.AccAddress { addr, _ := sdk.AccAddressFromBech32(m.Authority) return []sdk.AccAddress{addr} } // ValidateBasic does a sanity check on the provided data. func (m *MsgUpdateParams) ValidateBasic() error { if _, err := sdk.AccAddressFromBech32(m.Authority); err != nil { return errorsmod.Wrap(err, "invalid authority address") } return m.Params.Validate() } ================================================ FILE: x/resources/types/params.go ================================================ package types import ( "fmt" sdk "github.com/cosmos/cosmos-sdk/types" ctypes "github.com/cybercongress/go-cyber/v7/types" ) const ( DefaultMaxSlots = uint32(8) DefaultHalvingPeriodVolt = uint32(9000000) DefaultHalvingPeriodAmpere = uint32(9000000) DefaultInvestmintPeriodVolt = uint32(2592000) DefaultInvestmintPeriodAmpere = uint32(2592000) DefaultMinInvestmintPeriod = uint32(86400) ) func DefaultParams() Params { return Params{ MaxSlots: DefaultMaxSlots, HalvingPeriodVoltBlocks: DefaultHalvingPeriodVolt, HalvingPeriodAmpereBlocks: DefaultHalvingPeriodAmpere, BaseInvestmintPeriodVolt: DefaultInvestmintPeriodVolt, BaseInvestmintPeriodAmpere: DefaultInvestmintPeriodAmpere, BaseInvestmintAmountVolt: ctypes.NewSCybCoin(ctypes.Mega * 1000), BaseInvestmintAmountAmpere: ctypes.NewSCybCoin(ctypes.Mega * 100), MinInvestmintPeriod: DefaultMinInvestmintPeriod, } } func (p Params) Validate() error { if err := validateMaxSlots(p.MaxSlots); err != nil { return err } if err := validateHalvingPeriodVoltBlocks(p.HalvingPeriodVoltBlocks); err != nil { return err } if err := validateHalvingPeriodAmpereBlocks(p.HalvingPeriodAmpereBlocks); err != nil { return err } if err := validateBaseInvestmintPeriodVolt(p.BaseInvestmintPeriodVolt); err != nil { return err } if err := validateBaseInvestmintPeriodAmpere(p.BaseInvestmintPeriodAmpere); err != nil { return err } if err := validateBaseInvestmintAmountVolt(p.BaseInvestmintAmountVolt); err != nil { return err } if err := validateBaseInvestmintAmountAmpere(p.BaseInvestmintAmountAmpere); err != nil { return err } if err := validateMinInvestmintPeriod(p.MinInvestmintPeriod); err != nil { return err } return nil } func validateMaxSlots(i interface{}) error { v, ok := i.(uint32) if !ok { return fmt.Errorf("invalid parameter type: %T", i) } if v == 0 { return fmt.Errorf("max entries must be positive: %d", v) } if v > 16 { return fmt.Errorf("max resources slots must be less or equal to 16: %d", v) } return nil } func validateHalvingPeriodVoltBlocks(i interface{}) error { v, ok := i.(uint32) if !ok { return fmt.Errorf("invalid parameter type: %T", i) } if v < 6000000 { return fmt.Errorf("base halving period for Volt must be more than 6000000 blocks: %d", v) } return nil } func validateHalvingPeriodAmpereBlocks(i interface{}) error { v, ok := i.(uint32) if !ok { return fmt.Errorf("invalid parameter type: %T", i) } if v < 6000000 { return fmt.Errorf("base halving period for Ampere must be more than 6000000 blocks: %d", v) } return nil } func validateBaseInvestmintPeriodVolt(i interface{}) error { v, ok := i.(uint32) if !ok { return fmt.Errorf("invalid parameter type: %T", i) } if v < 604800 { return fmt.Errorf("base investmint period for Volt must be more than 604800 seconds: %d", v) } return nil } func validateBaseInvestmintPeriodAmpere(i interface{}) error { v, ok := i.(uint32) if !ok { return fmt.Errorf("invalid parameter type: %T", i) } if v < 604800 { return fmt.Errorf("base investmint period for Ampere must be more than 604800 seconds: %d", v) } return nil } func validateBaseInvestmintAmountVolt(i interface{}) error { v, ok := i.(sdk.Coin) if !ok { return fmt.Errorf("invalid parameter type: %T", i) } if v.IsLT(ctypes.NewSCybCoin(ctypes.Mega * 10)) { return fmt.Errorf("base investmint amount for Volt must be more than 10000000: %d", v.Amount.Int64()) } return nil } func validateBaseInvestmintAmountAmpere(i interface{}) error { v, ok := i.(sdk.Coin) if !ok { return fmt.Errorf("invalid parameter type: %T", i) } if v.IsLT(ctypes.NewSCybCoin(ctypes.Mega * 10)) { return fmt.Errorf("base investmint amount for Ampere must be more than 10000000: %d", v.Amount.Int64()) } return nil } func validateMinInvestmintPeriod(i interface{}) error { v, ok := i.(uint32) if !ok { return fmt.Errorf("invalid parameter type: %T", i) } if v < 86400 { return fmt.Errorf("min investmint period must be more than 86400 seconds: %d", v) } return nil } ================================================ FILE: x/resources/types/params_legacy.go ================================================ package types import paramstypes "github.com/cosmos/cosmos-sdk/x/params/types" var ( KeyMaxSlots = []byte("MaxSlots") KeyHalvingPeriodVoltBlocks = []byte("HalvingPeriodVoltBlocks") KeyHalvingPeriodAmpereBlocks = []byte("HalvingPeriodAmpereBlocks") KeyBaseInvestmintPeriodVolt = []byte("BaseInvestmintPeriodVolt") KeyBaseInvestmintPeriodAmpere = []byte("BaseInvestmintPeriodAmpere") KeyBaseInvestmintAmountVolt = []byte("BaseInvestmintAmountVolt") KeyBaseInvestmintAmountAmpere = []byte("BaseInvestmintAmountAmpere") KeyMinInvestmintPeriod = []byte("MinInvestmintPeriod") ) // Deprecated: Type declaration for parameters func ParamKeyTable() paramstypes.KeyTable { return paramstypes.NewKeyTable().RegisterParamSet(&Params{}) } func (p *Params) ParamSetPairs() paramstypes.ParamSetPairs { return paramstypes.ParamSetPairs{ paramstypes.NewParamSetPair(KeyMaxSlots, &p.MaxSlots, validateMaxSlots), paramstypes.NewParamSetPair(KeyHalvingPeriodVoltBlocks, &p.HalvingPeriodVoltBlocks, validateHalvingPeriodVoltBlocks), paramstypes.NewParamSetPair(KeyHalvingPeriodAmpereBlocks, &p.HalvingPeriodAmpereBlocks, validateHalvingPeriodAmpereBlocks), paramstypes.NewParamSetPair(KeyBaseInvestmintPeriodVolt, &p.BaseInvestmintPeriodVolt, validateBaseInvestmintPeriodVolt), paramstypes.NewParamSetPair(KeyBaseInvestmintPeriodAmpere, &p.BaseInvestmintPeriodAmpere, validateBaseInvestmintPeriodAmpere), paramstypes.NewParamSetPair(KeyBaseInvestmintAmountVolt, &p.BaseInvestmintAmountVolt, validateBaseInvestmintAmountVolt), paramstypes.NewParamSetPair(KeyBaseInvestmintAmountAmpere, &p.BaseInvestmintAmountAmpere, validateBaseInvestmintAmountAmpere), paramstypes.NewParamSetPair(KeyMinInvestmintPeriod, &p.MinInvestmintPeriod, validateMinInvestmintPeriod), } } ================================================ FILE: x/resources/types/period.go ================================================ package types import ( sdk "github.com/cosmos/cosmos-sdk/types" vestingtypes "github.com/cosmos/cosmos-sdk/x/auth/vesting/types" ) func NewPeriod(amount sdk.Coins, length int64) vestingtypes.Period { return vestingtypes.Period{Amount: amount, Length: length} } ================================================ FILE: x/resources/types/query.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: cyber/resources/v1beta1/query.proto package types import ( context "context" fmt "fmt" types "github.com/cosmos/cosmos-sdk/types" _ "github.com/cosmos/gogoproto/gogoproto" grpc1 "github.com/cosmos/gogoproto/grpc" proto "github.com/cosmos/gogoproto/proto" _ "google.golang.org/genproto/googleapis/api/annotations" grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" io "io" math "math" math_bits "math/bits" ) // Reference imports to suppress errors if they are not otherwise used. var _ = proto.Marshal var _ = fmt.Errorf var _ = math.Inf // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package type QueryParamsRequest struct { } func (m *QueryParamsRequest) Reset() { *m = QueryParamsRequest{} } func (m *QueryParamsRequest) String() string { return proto.CompactTextString(m) } func (*QueryParamsRequest) ProtoMessage() {} func (*QueryParamsRequest) Descriptor() ([]byte, []int) { return fileDescriptor_4135536742b8fe64, []int{0} } func (m *QueryParamsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryParamsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryParamsRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryParamsRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryParamsRequest.Merge(m, src) } func (m *QueryParamsRequest) XXX_Size() int { return m.Size() } func (m *QueryParamsRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryParamsRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryParamsRequest proto.InternalMessageInfo type QueryParamsResponse struct { Params Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params"` } func (m *QueryParamsResponse) Reset() { *m = QueryParamsResponse{} } func (m *QueryParamsResponse) String() string { return proto.CompactTextString(m) } func (*QueryParamsResponse) ProtoMessage() {} func (*QueryParamsResponse) Descriptor() ([]byte, []int) { return fileDescriptor_4135536742b8fe64, []int{1} } func (m *QueryParamsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryParamsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryParamsResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryParamsResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryParamsResponse.Merge(m, src) } func (m *QueryParamsResponse) XXX_Size() int { return m.Size() } func (m *QueryParamsResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryParamsResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryParamsResponse proto.InternalMessageInfo func (m *QueryParamsResponse) GetParams() Params { if m != nil { return m.Params } return Params{} } type QueryInvestmintRequest struct { Amount types.Coin `protobuf:"bytes,1,opt,name=amount,proto3" json:"amount"` Resource string `protobuf:"bytes,2,opt,name=resource,proto3" json:"resource,omitempty"` Length uint64 `protobuf:"varint,3,opt,name=length,proto3" json:"length,omitempty"` } func (m *QueryInvestmintRequest) Reset() { *m = QueryInvestmintRequest{} } func (m *QueryInvestmintRequest) String() string { return proto.CompactTextString(m) } func (*QueryInvestmintRequest) ProtoMessage() {} func (*QueryInvestmintRequest) Descriptor() ([]byte, []int) { return fileDescriptor_4135536742b8fe64, []int{2} } func (m *QueryInvestmintRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryInvestmintRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryInvestmintRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryInvestmintRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryInvestmintRequest.Merge(m, src) } func (m *QueryInvestmintRequest) XXX_Size() int { return m.Size() } func (m *QueryInvestmintRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryInvestmintRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryInvestmintRequest proto.InternalMessageInfo func (m *QueryInvestmintRequest) GetAmount() types.Coin { if m != nil { return m.Amount } return types.Coin{} } func (m *QueryInvestmintRequest) GetResource() string { if m != nil { return m.Resource } return "" } func (m *QueryInvestmintRequest) GetLength() uint64 { if m != nil { return m.Length } return 0 } type QueryInvestmintResponse struct { Amount types.Coin `protobuf:"bytes,1,opt,name=amount,proto3" json:"amount"` } func (m *QueryInvestmintResponse) Reset() { *m = QueryInvestmintResponse{} } func (m *QueryInvestmintResponse) String() string { return proto.CompactTextString(m) } func (*QueryInvestmintResponse) ProtoMessage() {} func (*QueryInvestmintResponse) Descriptor() ([]byte, []int) { return fileDescriptor_4135536742b8fe64, []int{3} } func (m *QueryInvestmintResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryInvestmintResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryInvestmintResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryInvestmintResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryInvestmintResponse.Merge(m, src) } func (m *QueryInvestmintResponse) XXX_Size() int { return m.Size() } func (m *QueryInvestmintResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryInvestmintResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryInvestmintResponse proto.InternalMessageInfo func (m *QueryInvestmintResponse) GetAmount() types.Coin { if m != nil { return m.Amount } return types.Coin{} } type QueryAdjustedPriceRequest struct { Base types.Coin `protobuf:"bytes,1,opt,name=base,proto3" json:"base"` Resource string `protobuf:"bytes,2,opt,name=resource,proto3" json:"resource,omitempty"` } func (m *QueryAdjustedPriceRequest) Reset() { *m = QueryAdjustedPriceRequest{} } func (m *QueryAdjustedPriceRequest) String() string { return proto.CompactTextString(m) } func (*QueryAdjustedPriceRequest) ProtoMessage() {} func (*QueryAdjustedPriceRequest) Descriptor() ([]byte, []int) { return fileDescriptor_4135536742b8fe64, []int{4} } func (m *QueryAdjustedPriceRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryAdjustedPriceRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryAdjustedPriceRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryAdjustedPriceRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryAdjustedPriceRequest.Merge(m, src) } func (m *QueryAdjustedPriceRequest) XXX_Size() int { return m.Size() } func (m *QueryAdjustedPriceRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryAdjustedPriceRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryAdjustedPriceRequest proto.InternalMessageInfo func (m *QueryAdjustedPriceRequest) GetBase() types.Coin { if m != nil { return m.Base } return types.Coin{} } func (m *QueryAdjustedPriceRequest) GetResource() string { if m != nil { return m.Resource } return "" } type QueryAdjustedPriceResponse struct { Adjusted types.Coin `protobuf:"bytes,1,opt,name=adjusted,proto3" json:"adjusted"` } func (m *QueryAdjustedPriceResponse) Reset() { *m = QueryAdjustedPriceResponse{} } func (m *QueryAdjustedPriceResponse) String() string { return proto.CompactTextString(m) } func (*QueryAdjustedPriceResponse) ProtoMessage() {} func (*QueryAdjustedPriceResponse) Descriptor() ([]byte, []int) { return fileDescriptor_4135536742b8fe64, []int{5} } func (m *QueryAdjustedPriceResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryAdjustedPriceResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryAdjustedPriceResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryAdjustedPriceResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryAdjustedPriceResponse.Merge(m, src) } func (m *QueryAdjustedPriceResponse) XXX_Size() int { return m.Size() } func (m *QueryAdjustedPriceResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryAdjustedPriceResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryAdjustedPriceResponse proto.InternalMessageInfo func (m *QueryAdjustedPriceResponse) GetAdjusted() types.Coin { if m != nil { return m.Adjusted } return types.Coin{} } func init() { proto.RegisterType((*QueryParamsRequest)(nil), "cyber.resources.v1beta1.QueryParamsRequest") proto.RegisterType((*QueryParamsResponse)(nil), "cyber.resources.v1beta1.QueryParamsResponse") proto.RegisterType((*QueryInvestmintRequest)(nil), "cyber.resources.v1beta1.QueryInvestmintRequest") proto.RegisterType((*QueryInvestmintResponse)(nil), "cyber.resources.v1beta1.QueryInvestmintResponse") proto.RegisterType((*QueryAdjustedPriceRequest)(nil), "cyber.resources.v1beta1.QueryAdjustedPriceRequest") proto.RegisterType((*QueryAdjustedPriceResponse)(nil), "cyber.resources.v1beta1.QueryAdjustedPriceResponse") } func init() { proto.RegisterFile("cyber/resources/v1beta1/query.proto", fileDescriptor_4135536742b8fe64) } var fileDescriptor_4135536742b8fe64 = []byte{ // 511 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x94, 0x41, 0x6b, 0xd4, 0x40, 0x14, 0xc7, 0x77, 0xda, 0x35, 0xd4, 0x11, 0x2f, 0x63, 0x69, 0xb7, 0x41, 0xd2, 0x25, 0x5e, 0x56, 0x6a, 0x33, 0xee, 0x06, 0x11, 0x11, 0x0f, 0xd6, 0x93, 0x07, 0xa1, 0x06, 0x2f, 0x7a, 0x91, 0x24, 0x1d, 0xd2, 0xc8, 0x66, 0x5e, 0x9a, 0x99, 0x14, 0xf7, 0x2a, 0x78, 0x17, 0x04, 0x3f, 0x82, 0x5f, 0xc0, 0x2f, 0xd1, 0x63, 0xc1, 0x8b, 0x27, 0x91, 0x5d, 0xbf, 0x87, 0x92, 0x99, 0x49, 0xd6, 0xb2, 0xdd, 0x25, 0xf6, 0x96, 0xcc, 0xfc, 0xdf, 0xff, 0xff, 0x7b, 0xbc, 0xc7, 0xe0, 0x3b, 0xf1, 0x24, 0x62, 0x05, 0x2d, 0x98, 0x80, 0xb2, 0x88, 0x99, 0xa0, 0xa7, 0xc3, 0x88, 0xc9, 0x70, 0x48, 0x4f, 0x4a, 0x56, 0x4c, 0xbc, 0xbc, 0x00, 0x09, 0x64, 0x5b, 0x89, 0xbc, 0x46, 0xe4, 0x19, 0x91, 0xbd, 0x99, 0x40, 0x02, 0x4a, 0x43, 0xab, 0x2f, 0x2d, 0xb7, 0x6f, 0x27, 0x00, 0xc9, 0x98, 0xd1, 0x30, 0x4f, 0x69, 0xc8, 0x39, 0xc8, 0x50, 0xa6, 0xc0, 0x85, 0xb9, 0x5d, 0x9a, 0x28, 0x27, 0x39, 0xab, 0x45, 0x4e, 0x0c, 0x22, 0x03, 0x41, 0xa3, 0x50, 0xb0, 0x46, 0x10, 0x43, 0xca, 0xf5, 0xbd, 0xbb, 0x89, 0xc9, 0xcb, 0x0a, 0xf0, 0x30, 0x2c, 0xc2, 0x4c, 0x04, 0xec, 0xa4, 0x64, 0x42, 0xba, 0xaf, 0xf0, 0xad, 0x0b, 0xa7, 0x22, 0x07, 0x2e, 0x18, 0x79, 0x82, 0xad, 0x5c, 0x9d, 0xf4, 0x50, 0x1f, 0x0d, 0x6e, 0x8c, 0x76, 0xbd, 0x25, 0xfd, 0x78, 0xba, 0xf0, 0xa0, 0x7b, 0xf6, 0x73, 0xb7, 0x13, 0x98, 0x22, 0xf7, 0x23, 0xc2, 0x5b, 0xca, 0xf6, 0x39, 0x3f, 0x65, 0x42, 0x66, 0x29, 0x97, 0x26, 0x90, 0x3c, 0xc4, 0x56, 0x98, 0x41, 0xc9, 0xa5, 0x71, 0xde, 0xf1, 0x34, 0xb7, 0x57, 0x71, 0x37, 0xae, 0xcf, 0x20, 0xe5, 0xb5, 0xa7, 0x96, 0x13, 0x1b, 0x6f, 0xd4, 0xe9, 0xbd, 0xb5, 0x3e, 0x1a, 0x5c, 0x0f, 0x9a, 0x7f, 0xb2, 0x85, 0xad, 0x31, 0xe3, 0x89, 0x3c, 0xee, 0xad, 0xf7, 0xd1, 0xa0, 0x1b, 0x98, 0x3f, 0x37, 0xc0, 0xdb, 0x0b, 0x18, 0xa6, 0xc3, 0xab, 0x72, 0xb8, 0x63, 0xbc, 0xa3, 0x3c, 0x9f, 0x1e, 0xbd, 0x2b, 0x85, 0x64, 0x47, 0x87, 0x45, 0x1a, 0xb3, 0xba, 0x3b, 0x1f, 0x77, 0xab, 0xfa, 0xb6, 0x9e, 0x4a, 0xbc, 0xaa, 0x33, 0xf7, 0x35, 0xb6, 0x2f, 0x4b, 0x33, 0x4d, 0x3c, 0xc6, 0x1b, 0xa1, 0xb9, 0x68, 0x1b, 0xd9, 0x14, 0x8c, 0xfe, 0xac, 0xe3, 0x6b, 0xca, 0x9b, 0x7c, 0x41, 0xd8, 0xd2, 0x73, 0x24, 0x7b, 0x4b, 0x07, 0xbd, 0xb8, 0x3c, 0xf6, 0xbd, 0x76, 0x62, 0x0d, 0xeb, 0x0e, 0x3f, 0x7c, 0xff, 0xfd, 0x79, 0x6d, 0x8f, 0xdc, 0xa5, 0xcb, 0xd6, 0x79, 0x7e, 0xa2, 0xf7, 0x88, 0x7c, 0x45, 0x18, 0xcf, 0x67, 0x47, 0xe8, 0xea, 0xbc, 0x85, 0x65, 0xb3, 0xef, 0xb7, 0x2f, 0x30, 0x90, 0x0f, 0x14, 0x24, 0x25, 0xfb, 0x2d, 0x20, 0xd3, 0x39, 0xd9, 0x37, 0x84, 0x6f, 0x5e, 0x18, 0x11, 0x19, 0xad, 0x8e, 0xbe, 0x6c, 0x7b, 0x6c, 0xff, 0xbf, 0x6a, 0x0c, 0xf1, 0x23, 0x45, 0xec, 0x93, 0x61, 0x0b, 0xe2, 0x7a, 0xf6, 0x6f, 0xf3, 0xca, 0xe2, 0xe0, 0xc5, 0xd9, 0xd4, 0x41, 0xe7, 0x53, 0x07, 0xfd, 0x9a, 0x3a, 0xe8, 0xd3, 0xcc, 0xe9, 0x9c, 0xcf, 0x9c, 0xce, 0x8f, 0x99, 0xd3, 0x79, 0xe3, 0x27, 0xa9, 0x3c, 0x2e, 0x23, 0x2f, 0x86, 0x4c, 0xdb, 0xc6, 0xc0, 0x93, 0x82, 0x09, 0x41, 0x13, 0xd8, 0xd7, 0x39, 0xef, 0xff, 0xf1, 0x55, 0xef, 0x50, 0x64, 0xa9, 0x87, 0xc6, 0xff, 0x1b, 0x00, 0x00, 0xff, 0xff, 0x41, 0xf7, 0xc8, 0xa5, 0x21, 0x05, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. var _ context.Context var _ grpc.ClientConn // This is a compile-time assertion to ensure that this generated file // is compatible with the grpc package it is being compiled against. const _ = grpc.SupportPackageIsVersion4 // QueryClient is the client API for Query service. // // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. type QueryClient interface { Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) Investmint(ctx context.Context, in *QueryInvestmintRequest, opts ...grpc.CallOption) (*QueryInvestmintResponse, error) AdjustedPrice(ctx context.Context, in *QueryAdjustedPriceRequest, opts ...grpc.CallOption) (*QueryAdjustedPriceResponse, error) } type queryClient struct { cc grpc1.ClientConn } func NewQueryClient(cc grpc1.ClientConn) QueryClient { return &queryClient{cc} } func (c *queryClient) Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) { out := new(QueryParamsResponse) err := c.cc.Invoke(ctx, "/cyber.resources.v1beta1.Query/Params", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) Investmint(ctx context.Context, in *QueryInvestmintRequest, opts ...grpc.CallOption) (*QueryInvestmintResponse, error) { out := new(QueryInvestmintResponse) err := c.cc.Invoke(ctx, "/cyber.resources.v1beta1.Query/Investmint", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) AdjustedPrice(ctx context.Context, in *QueryAdjustedPriceRequest, opts ...grpc.CallOption) (*QueryAdjustedPriceResponse, error) { out := new(QueryAdjustedPriceResponse) err := c.cc.Invoke(ctx, "/cyber.resources.v1beta1.Query/AdjustedPrice", in, out, opts...) if err != nil { return nil, err } return out, nil } // QueryServer is the server API for Query service. type QueryServer interface { Params(context.Context, *QueryParamsRequest) (*QueryParamsResponse, error) Investmint(context.Context, *QueryInvestmintRequest) (*QueryInvestmintResponse, error) AdjustedPrice(context.Context, *QueryAdjustedPriceRequest) (*QueryAdjustedPriceResponse, error) } // UnimplementedQueryServer can be embedded to have forward compatible implementations. type UnimplementedQueryServer struct { } func (*UnimplementedQueryServer) Params(ctx context.Context, req *QueryParamsRequest) (*QueryParamsResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method Params not implemented") } func (*UnimplementedQueryServer) Investmint(ctx context.Context, req *QueryInvestmintRequest) (*QueryInvestmintResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method Investmint not implemented") } func (*UnimplementedQueryServer) AdjustedPrice(ctx context.Context, req *QueryAdjustedPriceRequest) (*QueryAdjustedPriceResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method AdjustedPrice not implemented") } func RegisterQueryServer(s grpc1.Server, srv QueryServer) { s.RegisterService(&_Query_serviceDesc, srv) } func _Query_Params_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryParamsRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).Params(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.resources.v1beta1.Query/Params", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Params(ctx, req.(*QueryParamsRequest)) } return interceptor(ctx, in, info, handler) } func _Query_Investmint_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryInvestmintRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).Investmint(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.resources.v1beta1.Query/Investmint", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Investmint(ctx, req.(*QueryInvestmintRequest)) } return interceptor(ctx, in, info, handler) } func _Query_AdjustedPrice_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryAdjustedPriceRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).AdjustedPrice(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.resources.v1beta1.Query/AdjustedPrice", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).AdjustedPrice(ctx, req.(*QueryAdjustedPriceRequest)) } return interceptor(ctx, in, info, handler) } var _Query_serviceDesc = grpc.ServiceDesc{ ServiceName: "cyber.resources.v1beta1.Query", HandlerType: (*QueryServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "Params", Handler: _Query_Params_Handler, }, { MethodName: "Investmint", Handler: _Query_Investmint_Handler, }, { MethodName: "AdjustedPrice", Handler: _Query_AdjustedPrice_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "cyber/resources/v1beta1/query.proto", } func (m *QueryParamsRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryParamsRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryParamsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *QueryParamsResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryParamsResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryParamsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.Params.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa return len(dAtA) - i, nil } func (m *QueryInvestmintRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryInvestmintRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryInvestmintRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.Length != 0 { i = encodeVarintQuery(dAtA, i, uint64(m.Length)) i-- dAtA[i] = 0x18 } if len(m.Resource) > 0 { i -= len(m.Resource) copy(dAtA[i:], m.Resource) i = encodeVarintQuery(dAtA, i, uint64(len(m.Resource))) i-- dAtA[i] = 0x12 } { size, err := m.Amount.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa return len(dAtA) - i, nil } func (m *QueryInvestmintResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryInvestmintResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryInvestmintResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.Amount.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa return len(dAtA) - i, nil } func (m *QueryAdjustedPriceRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryAdjustedPriceRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryAdjustedPriceRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.Resource) > 0 { i -= len(m.Resource) copy(dAtA[i:], m.Resource) i = encodeVarintQuery(dAtA, i, uint64(len(m.Resource))) i-- dAtA[i] = 0x12 } { size, err := m.Base.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa return len(dAtA) - i, nil } func (m *QueryAdjustedPriceResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryAdjustedPriceResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryAdjustedPriceResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.Adjusted.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa return len(dAtA) - i, nil } func encodeVarintQuery(dAtA []byte, offset int, v uint64) int { offset -= sovQuery(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *QueryParamsRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *QueryParamsResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l l = m.Params.Size() n += 1 + l + sovQuery(uint64(l)) return n } func (m *QueryInvestmintRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l l = m.Amount.Size() n += 1 + l + sovQuery(uint64(l)) l = len(m.Resource) if l > 0 { n += 1 + l + sovQuery(uint64(l)) } if m.Length != 0 { n += 1 + sovQuery(uint64(m.Length)) } return n } func (m *QueryInvestmintResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l l = m.Amount.Size() n += 1 + l + sovQuery(uint64(l)) return n } func (m *QueryAdjustedPriceRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l l = m.Base.Size() n += 1 + l + sovQuery(uint64(l)) l = len(m.Resource) if l > 0 { n += 1 + l + sovQuery(uint64(l)) } return n } func (m *QueryAdjustedPriceResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l l = m.Adjusted.Size() n += 1 + l + sovQuery(uint64(l)) return n } func sovQuery(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozQuery(x uint64) (n int) { return sovQuery(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *QueryParamsRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryParamsRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryParamsRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryParamsResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryParamsResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryParamsResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Params.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryInvestmintRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryInvestmintRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryInvestmintRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Amount", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Amount.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Resource", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } m.Resource = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field Length", wireType) } m.Length = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.Length |= uint64(b&0x7F) << shift if b < 0x80 { break } } default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryInvestmintResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryInvestmintResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryInvestmintResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Amount", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Amount.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryAdjustedPriceRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryAdjustedPriceRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryAdjustedPriceRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Base", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Base.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Resource", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } m.Resource = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryAdjustedPriceResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryAdjustedPriceResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryAdjustedPriceResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Adjusted", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Adjusted.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipQuery(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowQuery } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowQuery } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowQuery } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthQuery } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupQuery } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthQuery } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthQuery = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowQuery = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupQuery = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/resources/types/query.pb.gw.go ================================================ // Code generated by protoc-gen-grpc-gateway. DO NOT EDIT. // source: cyber/resources/v1beta1/query.proto /* Package types is a reverse proxy. It translates gRPC into RESTful JSON APIs. */ package types import ( "context" "io" "net/http" "github.com/golang/protobuf/descriptor" "github.com/golang/protobuf/proto" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/grpc-ecosystem/grpc-gateway/utilities" "google.golang.org/grpc" "google.golang.org/grpc/codes" "google.golang.org/grpc/grpclog" "google.golang.org/grpc/metadata" "google.golang.org/grpc/status" ) // Suppress "imported and not used" errors var _ codes.Code var _ io.Reader var _ status.Status var _ = runtime.String var _ = utilities.NewDoubleArray var _ = descriptor.ForMessage var _ = metadata.Join func request_Query_Params_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryParamsRequest var metadata runtime.ServerMetadata msg, err := client.Params(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_Params_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryParamsRequest var metadata runtime.ServerMetadata msg, err := server.Params(ctx, &protoReq) return msg, metadata, err } var ( filter_Query_Investmint_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) func request_Query_Investmint_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryInvestmintRequest var metadata runtime.ServerMetadata if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_Investmint_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := client.Investmint(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_Investmint_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryInvestmintRequest var metadata runtime.ServerMetadata if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_Investmint_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := server.Investmint(ctx, &protoReq) return msg, metadata, err } var ( filter_Query_AdjustedPrice_0 = &utilities.DoubleArray{Encoding: map[string]int{}, Base: []int(nil), Check: []int(nil)} ) func request_Query_AdjustedPrice_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryAdjustedPriceRequest var metadata runtime.ServerMetadata if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_AdjustedPrice_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := client.AdjustedPrice(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_AdjustedPrice_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryAdjustedPriceRequest var metadata runtime.ServerMetadata if err := req.ParseForm(); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_Query_AdjustedPrice_0); err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err) } msg, err := server.AdjustedPrice(ctx, &protoReq) return msg, metadata, err } // RegisterQueryHandlerServer registers the http handlers for service Query to "mux". // UnaryRPC :call QueryServer directly. // StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. // Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterQueryHandlerFromEndpoint instead. func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, server QueryServer) error { mux.Handle("GET", pattern_Query_Params_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_Params_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Params_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_Investmint_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_Investmint_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Investmint_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_AdjustedPrice_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_AdjustedPrice_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_AdjustedPrice_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) return nil } // RegisterQueryHandlerFromEndpoint is same as RegisterQueryHandler but // automatically dials to "endpoint" and closes the connection when "ctx" gets done. func RegisterQueryHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error) { conn, err := grpc.Dial(endpoint, opts...) if err != nil { return err } defer func() { if err != nil { if cerr := conn.Close(); cerr != nil { grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr) } return } go func() { <-ctx.Done() if cerr := conn.Close(); cerr != nil { grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr) } }() }() return RegisterQueryHandler(ctx, mux, conn) } // RegisterQueryHandler registers the http handlers for service Query to "mux". // The handlers forward requests to the grpc endpoint over "conn". func RegisterQueryHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error { return RegisterQueryHandlerClient(ctx, mux, NewQueryClient(conn)) } // RegisterQueryHandlerClient registers the http handlers for service Query // to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "QueryClient". // Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "QueryClient" // doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in // "QueryClient" to call the correct interceptors. func RegisterQueryHandlerClient(ctx context.Context, mux *runtime.ServeMux, client QueryClient) error { mux.Handle("GET", pattern_Query_Params_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_Params_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Params_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_Investmint_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_Investmint_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Investmint_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_AdjustedPrice_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_AdjustedPrice_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_AdjustedPrice_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) return nil } var ( pattern_Query_Params_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 1, 2, 3}, []string{"cyber", "resources", "v1beta1", "params"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_Investmint_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 1, 2, 3}, []string{"cyber", "resources", "v1beta1", "investmint"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_AdjustedPrice_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 1, 2, 3}, []string{"cyber", "resources", "v1beta1", "adjusted_price"}, "", runtime.AssumeColonVerbOpt(false))) ) var ( forward_Query_Params_0 = runtime.ForwardResponseMessage forward_Query_Investmint_0 = runtime.ForwardResponseMessage forward_Query_AdjustedPrice_0 = runtime.ForwardResponseMessage ) ================================================ FILE: x/resources/types/tx.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: cyber/resources/v1beta1/tx.proto package types import ( context "context" fmt "fmt" io "io" math "math" math_bits "math/bits" _ "github.com/cosmos/cosmos-proto" _ "github.com/cosmos/cosmos-sdk/types" github_com_cosmos_cosmos_sdk_types "github.com/cosmos/cosmos-sdk/types" _ "github.com/cosmos/cosmos-sdk/types/msgservice" _ "github.com/cosmos/gogoproto/gogoproto" grpc1 "github.com/cosmos/gogoproto/grpc" proto "github.com/cosmos/gogoproto/proto" grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" ) // Reference imports to suppress errors if they are not otherwise used. var ( _ = proto.Marshal _ = fmt.Errorf _ = math.Inf ) // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package type MsgInvestmint struct { Neuron string `protobuf:"bytes,1,opt,name=neuron,proto3" json:"neuron,omitempty"` Amount github_com_cosmos_cosmos_sdk_types.Coin `protobuf:"bytes,2,opt,name=amount,proto3,casttype=github.com/cosmos/cosmos-sdk/types.Coin" json:"amount"` Resource string `protobuf:"bytes,3,opt,name=resource,proto3" json:"resource,omitempty"` Length uint64 `protobuf:"varint,4,opt,name=length,proto3" json:"length,omitempty"` } func (m *MsgInvestmint) Reset() { *m = MsgInvestmint{} } func (m *MsgInvestmint) String() string { return proto.CompactTextString(m) } func (*MsgInvestmint) ProtoMessage() {} func (*MsgInvestmint) Descriptor() ([]byte, []int) { return fileDescriptor_94512119bd1d1c33, []int{0} } func (m *MsgInvestmint) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgInvestmint) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgInvestmint.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgInvestmint) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgInvestmint.Merge(m, src) } func (m *MsgInvestmint) XXX_Size() int { return m.Size() } func (m *MsgInvestmint) XXX_DiscardUnknown() { xxx_messageInfo_MsgInvestmint.DiscardUnknown(m) } var xxx_messageInfo_MsgInvestmint proto.InternalMessageInfo type MsgUpdateParams struct { Authority string `protobuf:"bytes,1,opt,name=authority,proto3" json:"authority,omitempty"` Params Params `protobuf:"bytes,2,opt,name=params,proto3" json:"params"` } func (m *MsgUpdateParams) Reset() { *m = MsgUpdateParams{} } func (m *MsgUpdateParams) String() string { return proto.CompactTextString(m) } func (*MsgUpdateParams) ProtoMessage() {} func (*MsgUpdateParams) Descriptor() ([]byte, []int) { return fileDescriptor_94512119bd1d1c33, []int{1} } func (m *MsgUpdateParams) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgUpdateParams) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgUpdateParams.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgUpdateParams) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgUpdateParams.Merge(m, src) } func (m *MsgUpdateParams) XXX_Size() int { return m.Size() } func (m *MsgUpdateParams) XXX_DiscardUnknown() { xxx_messageInfo_MsgUpdateParams.DiscardUnknown(m) } var xxx_messageInfo_MsgUpdateParams proto.InternalMessageInfo func (m *MsgUpdateParams) GetAuthority() string { if m != nil { return m.Authority } return "" } func (m *MsgUpdateParams) GetParams() Params { if m != nil { return m.Params } return Params{} } type MsgInvestmintResponse struct{} func (m *MsgInvestmintResponse) Reset() { *m = MsgInvestmintResponse{} } func (m *MsgInvestmintResponse) String() string { return proto.CompactTextString(m) } func (*MsgInvestmintResponse) ProtoMessage() {} func (*MsgInvestmintResponse) Descriptor() ([]byte, []int) { return fileDescriptor_94512119bd1d1c33, []int{2} } func (m *MsgInvestmintResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgInvestmintResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgInvestmintResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgInvestmintResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgInvestmintResponse.Merge(m, src) } func (m *MsgInvestmintResponse) XXX_Size() int { return m.Size() } func (m *MsgInvestmintResponse) XXX_DiscardUnknown() { xxx_messageInfo_MsgInvestmintResponse.DiscardUnknown(m) } var xxx_messageInfo_MsgInvestmintResponse proto.InternalMessageInfo type MsgUpdateParamsResponse struct{} func (m *MsgUpdateParamsResponse) Reset() { *m = MsgUpdateParamsResponse{} } func (m *MsgUpdateParamsResponse) String() string { return proto.CompactTextString(m) } func (*MsgUpdateParamsResponse) ProtoMessage() {} func (*MsgUpdateParamsResponse) Descriptor() ([]byte, []int) { return fileDescriptor_94512119bd1d1c33, []int{3} } func (m *MsgUpdateParamsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgUpdateParamsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgUpdateParamsResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgUpdateParamsResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgUpdateParamsResponse.Merge(m, src) } func (m *MsgUpdateParamsResponse) XXX_Size() int { return m.Size() } func (m *MsgUpdateParamsResponse) XXX_DiscardUnknown() { xxx_messageInfo_MsgUpdateParamsResponse.DiscardUnknown(m) } var xxx_messageInfo_MsgUpdateParamsResponse proto.InternalMessageInfo func init() { proto.RegisterType((*MsgInvestmint)(nil), "cyber.resources.v1beta1.MsgInvestmint") proto.RegisterType((*MsgUpdateParams)(nil), "cyber.resources.v1beta1.MsgUpdateParams") proto.RegisterType((*MsgInvestmintResponse)(nil), "cyber.resources.v1beta1.MsgInvestmintResponse") proto.RegisterType((*MsgUpdateParamsResponse)(nil), "cyber.resources.v1beta1.MsgUpdateParamsResponse") } func init() { proto.RegisterFile("cyber/resources/v1beta1/tx.proto", fileDescriptor_94512119bd1d1c33) } var fileDescriptor_94512119bd1d1c33 = []byte{ // 484 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x92, 0xbd, 0x8e, 0xd3, 0x40, 0x10, 0xc7, 0xbd, 0x5c, 0x14, 0xdd, 0x2d, 0x5f, 0x92, 0x75, 0x10, 0xc7, 0x85, 0x1d, 0x05, 0x09, 0x22, 0xa4, 0xac, 0xc9, 0x9d, 0x44, 0x71, 0x12, 0x05, 0xa1, 0xa2, 0x88, 0x84, 0x8c, 0x68, 0x68, 0x90, 0x3f, 0x56, 0x1b, 0x03, 0xde, 0xb5, 0x76, 0xd6, 0xd1, 0xa5, 0xa5, 0xa2, 0xa4, 0xa4, 0xbc, 0x47, 0xa0, 0xe0, 0x21, 0x8e, 0xee, 0x44, 0x03, 0xd5, 0x09, 0x25, 0x05, 0x3c, 0x03, 0x15, 0xb2, 0x77, 0x9d, 0x4b, 0x90, 0x72, 0xba, 0xca, 0x1e, 0xcd, 0x6f, 0xfe, 0xf3, 0x9f, 0x9d, 0xc1, 0xbd, 0x64, 0x1e, 0x53, 0x19, 0x48, 0x0a, 0xa2, 0x94, 0x09, 0x85, 0x60, 0x36, 0x8a, 0xa9, 0x8a, 0x46, 0x81, 0x3a, 0x26, 0x85, 0x14, 0x4a, 0xd8, 0x9d, 0x9a, 0x20, 0x2b, 0x82, 0x18, 0xc2, 0xdd, 0x67, 0x82, 0x89, 0x9a, 0x09, 0xaa, 0x3f, 0x8d, 0xbb, 0x9d, 0x44, 0x40, 0x2e, 0x20, 0xc8, 0x81, 0x05, 0xb3, 0x51, 0xf5, 0x31, 0x89, 0xae, 0x4e, 0xbc, 0xd1, 0x15, 0x3a, 0x30, 0xa9, 0x7b, 0x5b, 0x4d, 0xcc, 0x0b, 0xda, 0x40, 0x9e, 0x11, 0x8e, 0x23, 0xa0, 0x2b, 0x20, 0x11, 0x19, 0xd7, 0xf9, 0xfe, 0x37, 0x84, 0x6f, 0x4e, 0x80, 0x3d, 0xe7, 0x33, 0x0a, 0x2a, 0xcf, 0xb8, 0xb2, 0xef, 0xe2, 0x36, 0xa7, 0xa5, 0x14, 0xdc, 0x41, 0x3d, 0x34, 0xd8, 0x0b, 0x4d, 0x64, 0xc7, 0xb8, 0x1d, 0xe5, 0xa2, 0xe4, 0xca, 0xb9, 0xd6, 0x43, 0x83, 0xeb, 0x07, 0x5d, 0x62, 0xdc, 0x54, 0xd2, 0xcd, 0x78, 0xe4, 0x99, 0xc8, 0xf8, 0x38, 0x38, 0x3d, 0xf7, 0xad, 0xbf, 0xe7, 0xfe, 0x03, 0x96, 0xa9, 0x69, 0x19, 0x93, 0x44, 0xe4, 0xc6, 0xba, 0xf9, 0x0c, 0x21, 0x7d, 0x67, 0x6c, 0x56, 0x05, 0xa1, 0x51, 0xb6, 0x5d, 0xbc, 0xdb, 0x8c, 0xe3, 0xec, 0xd4, 0xdd, 0x57, 0x71, 0xe5, 0xeb, 0x3d, 0xe5, 0x4c, 0x4d, 0x9d, 0x56, 0x0f, 0x0d, 0x5a, 0xa1, 0x89, 0x8e, 0x76, 0x3f, 0x9e, 0xf8, 0xd6, 0x9f, 0x13, 0xdf, 0xea, 0x7f, 0x46, 0xf8, 0xf6, 0x04, 0xd8, 0xab, 0x22, 0x8d, 0x14, 0x7d, 0x11, 0xc9, 0x28, 0x07, 0xfb, 0x31, 0xde, 0x8b, 0x4a, 0x35, 0x15, 0x32, 0x53, 0x73, 0x3d, 0xd0, 0xd8, 0xf9, 0xfe, 0x75, 0xb8, 0x6f, 0xbc, 0x3f, 0x4d, 0x53, 0x49, 0x01, 0x5e, 0x2a, 0x99, 0x71, 0x16, 0x5e, 0xa0, 0xf6, 0x13, 0xdc, 0x2e, 0x6a, 0x05, 0x33, 0xad, 0x4f, 0xb6, 0x2c, 0x94, 0xe8, 0x46, 0xe3, 0x56, 0x35, 0x73, 0x68, 0x8a, 0x8e, 0x6e, 0x7d, 0xf8, 0xfd, 0xe5, 0xe1, 0x85, 0x5c, 0xbf, 0x83, 0xef, 0x6c, 0xbc, 0x72, 0x48, 0xa1, 0x10, 0x1c, 0x68, 0xbf, 0x8b, 0x3b, 0xff, 0x59, 0x6e, 0x52, 0x07, 0x3f, 0x10, 0xde, 0x99, 0x00, 0xb3, 0x53, 0x8c, 0xd7, 0xd6, 0x73, 0x7f, 0xab, 0x91, 0x8d, 0x06, 0x2e, 0xb9, 0x1a, 0xd7, 0x74, 0xb3, 0xdf, 0xe2, 0x1b, 0x1b, 0x0f, 0x37, 0xb8, 0xac, 0x7e, 0x9d, 0x74, 0x1f, 0x5d, 0x95, 0x6c, 0x7a, 0x8d, 0x27, 0xa7, 0x0b, 0x0f, 0x9d, 0x2d, 0x3c, 0xf4, 0x6b, 0xe1, 0xa1, 0x4f, 0x4b, 0xcf, 0x3a, 0x5b, 0x7a, 0xd6, 0xcf, 0xa5, 0x67, 0xbd, 0x3e, 0x5c, 0xbf, 0x98, 0x4a, 0x35, 0x11, 0x9c, 0x55, 0x1b, 0x0a, 0x98, 0x18, 0xea, 0x7b, 0x3f, 0x5e, 0xbb, 0xf8, 0xfa, 0x84, 0xe2, 0x76, 0x7d, 0xca, 0x87, 0xff, 0x02, 0x00, 0x00, 0xff, 0xff, 0x44, 0x47, 0xf3, 0x97, 0x96, 0x03, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. var ( _ context.Context _ grpc.ClientConn ) // This is a compile-time assertion to ensure that this generated file // is compatible with the grpc package it is being compiled against. const _ = grpc.SupportPackageIsVersion4 // MsgClient is the client API for Msg service. // // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. type MsgClient interface { Investmint(ctx context.Context, in *MsgInvestmint, opts ...grpc.CallOption) (*MsgInvestmintResponse, error) UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) } type msgClient struct { cc grpc1.ClientConn } func NewMsgClient(cc grpc1.ClientConn) MsgClient { return &msgClient{cc} } func (c *msgClient) Investmint(ctx context.Context, in *MsgInvestmint, opts ...grpc.CallOption) (*MsgInvestmintResponse, error) { out := new(MsgInvestmintResponse) err := c.cc.Invoke(ctx, "/cyber.resources.v1beta1.Msg/Investmint", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *msgClient) UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) { out := new(MsgUpdateParamsResponse) err := c.cc.Invoke(ctx, "/cyber.resources.v1beta1.Msg/UpdateParams", in, out, opts...) if err != nil { return nil, err } return out, nil } // MsgServer is the server API for Msg service. type MsgServer interface { Investmint(context.Context, *MsgInvestmint) (*MsgInvestmintResponse, error) UpdateParams(context.Context, *MsgUpdateParams) (*MsgUpdateParamsResponse, error) } // UnimplementedMsgServer can be embedded to have forward compatible implementations. type UnimplementedMsgServer struct{} func (*UnimplementedMsgServer) Investmint(ctx context.Context, req *MsgInvestmint) (*MsgInvestmintResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method Investmint not implemented") } func (*UnimplementedMsgServer) UpdateParams(ctx context.Context, req *MsgUpdateParams) (*MsgUpdateParamsResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method UpdateParams not implemented") } func RegisterMsgServer(s grpc1.Server, srv MsgServer) { s.RegisterService(&_Msg_serviceDesc, srv) } func _Msg_Investmint_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgInvestmint) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(MsgServer).Investmint(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.resources.v1beta1.Msg/Investmint", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).Investmint(ctx, req.(*MsgInvestmint)) } return interceptor(ctx, in, info, handler) } func _Msg_UpdateParams_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgUpdateParams) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(MsgServer).UpdateParams(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/cyber.resources.v1beta1.Msg/UpdateParams", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).UpdateParams(ctx, req.(*MsgUpdateParams)) } return interceptor(ctx, in, info, handler) } var _Msg_serviceDesc = grpc.ServiceDesc{ ServiceName: "cyber.resources.v1beta1.Msg", HandlerType: (*MsgServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "Investmint", Handler: _Msg_Investmint_Handler, }, { MethodName: "UpdateParams", Handler: _Msg_UpdateParams_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "cyber/resources/v1beta1/tx.proto", } func (m *MsgInvestmint) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgInvestmint) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgInvestmint) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.Length != 0 { i = encodeVarintTx(dAtA, i, uint64(m.Length)) i-- dAtA[i] = 0x20 } if len(m.Resource) > 0 { i -= len(m.Resource) copy(dAtA[i:], m.Resource) i = encodeVarintTx(dAtA, i, uint64(len(m.Resource))) i-- dAtA[i] = 0x1a } { size, err := m.Amount.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintTx(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 if len(m.Neuron) > 0 { i -= len(m.Neuron) copy(dAtA[i:], m.Neuron) i = encodeVarintTx(dAtA, i, uint64(len(m.Neuron))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *MsgUpdateParams) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgUpdateParams) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgUpdateParams) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.Params.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintTx(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 if len(m.Authority) > 0 { i -= len(m.Authority) copy(dAtA[i:], m.Authority) i = encodeVarintTx(dAtA, i, uint64(len(m.Authority))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *MsgInvestmintResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgInvestmintResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgInvestmintResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *MsgUpdateParamsResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgUpdateParamsResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgUpdateParamsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func encodeVarintTx(dAtA []byte, offset int, v uint64) int { offset -= sovTx(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *MsgInvestmint) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Neuron) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = m.Amount.Size() n += 1 + l + sovTx(uint64(l)) l = len(m.Resource) if l > 0 { n += 1 + l + sovTx(uint64(l)) } if m.Length != 0 { n += 1 + sovTx(uint64(m.Length)) } return n } func (m *MsgUpdateParams) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Authority) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = m.Params.Size() n += 1 + l + sovTx(uint64(l)) return n } func (m *MsgInvestmintResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *MsgUpdateParamsResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func sovTx(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozTx(x uint64) (n int) { return sovTx(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *MsgInvestmint) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgInvestmint: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgInvestmint: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Neuron", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Neuron = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Amount", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Amount.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 3: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Resource", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Resource = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 4: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field Length", wireType) } m.Length = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.Length |= uint64(b&0x7F) << shift if b < 0x80 { break } } default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgUpdateParams) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgUpdateParams: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgUpdateParams: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Authority", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Authority = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Params.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgInvestmintResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgInvestmintResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgInvestmintResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgUpdateParamsResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgUpdateParamsResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgUpdateParamsResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipTx(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTx } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTx } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTx } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthTx } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupTx } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthTx } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthTx = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowTx = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupTx = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/resources/types/types.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: cyber/resources/v1beta1/types.proto package types import ( fmt "fmt" io "io" math "math" math_bits "math/bits" _ "github.com/cosmos/cosmos-sdk/types" github_com_cosmos_cosmos_sdk_types "github.com/cosmos/cosmos-sdk/types" _ "github.com/cosmos/gogoproto/gogoproto" proto "github.com/cosmos/gogoproto/proto" ) // Reference imports to suppress errors if they are not otherwise used. var ( _ = proto.Marshal _ = fmt.Errorf _ = math.Inf ) // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package type Params struct { MaxSlots uint32 `protobuf:"varint,1,opt,name=max_slots,json=maxSlots,proto3" json:"max_slots,omitempty"` HalvingPeriodVoltBlocks uint32 `protobuf:"varint,2,opt,name=halving_period_volt_blocks,json=halvingPeriodVoltBlocks,proto3" json:"halving_period_volt_blocks,omitempty"` HalvingPeriodAmpereBlocks uint32 `protobuf:"varint,3,opt,name=halving_period_ampere_blocks,json=halvingPeriodAmpereBlocks,proto3" json:"halving_period_ampere_blocks,omitempty"` BaseInvestmintPeriodVolt uint32 `protobuf:"varint,4,opt,name=base_investmint_period_volt,json=baseInvestmintPeriodVolt,proto3" json:"base_investmint_period_volt,omitempty"` BaseInvestmintPeriodAmpere uint32 `protobuf:"varint,5,opt,name=base_investmint_period_ampere,json=baseInvestmintPeriodAmpere,proto3" json:"base_investmint_period_ampere,omitempty"` MinInvestmintPeriod uint32 `protobuf:"varint,6,opt,name=min_investmint_period,json=minInvestmintPeriod,proto3" json:"min_investmint_period,omitempty"` BaseInvestmintAmountVolt github_com_cosmos_cosmos_sdk_types.Coin `protobuf:"bytes,7,opt,name=base_investmint_amount_volt,json=baseInvestmintAmountVolt,proto3,casttype=github.com/cosmos/cosmos-sdk/types.Coin" json:"base_investmint_amount_volt"` BaseInvestmintAmountAmpere github_com_cosmos_cosmos_sdk_types.Coin `protobuf:"bytes,8,opt,name=base_investmint_amount_ampere,json=baseInvestmintAmountAmpere,proto3,casttype=github.com/cosmos/cosmos-sdk/types.Coin" json:"base_investmint_amount_ampere"` } func (m *Params) Reset() { *m = Params{} } func (m *Params) String() string { return proto.CompactTextString(m) } func (*Params) ProtoMessage() {} func (*Params) Descriptor() ([]byte, []int) { return fileDescriptor_3be852646b47c447, []int{0} } func (m *Params) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *Params) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_Params.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *Params) XXX_Merge(src proto.Message) { xxx_messageInfo_Params.Merge(m, src) } func (m *Params) XXX_Size() int { return m.Size() } func (m *Params) XXX_DiscardUnknown() { xxx_messageInfo_Params.DiscardUnknown(m) } var xxx_messageInfo_Params proto.InternalMessageInfo func (m *Params) GetMaxSlots() uint32 { if m != nil { return m.MaxSlots } return 0 } func (m *Params) GetHalvingPeriodVoltBlocks() uint32 { if m != nil { return m.HalvingPeriodVoltBlocks } return 0 } func (m *Params) GetHalvingPeriodAmpereBlocks() uint32 { if m != nil { return m.HalvingPeriodAmpereBlocks } return 0 } func (m *Params) GetBaseInvestmintPeriodVolt() uint32 { if m != nil { return m.BaseInvestmintPeriodVolt } return 0 } func (m *Params) GetBaseInvestmintPeriodAmpere() uint32 { if m != nil { return m.BaseInvestmintPeriodAmpere } return 0 } func (m *Params) GetMinInvestmintPeriod() uint32 { if m != nil { return m.MinInvestmintPeriod } return 0 } func (m *Params) GetBaseInvestmintAmountVolt() github_com_cosmos_cosmos_sdk_types.Coin { if m != nil { return m.BaseInvestmintAmountVolt } return github_com_cosmos_cosmos_sdk_types.Coin{} } func (m *Params) GetBaseInvestmintAmountAmpere() github_com_cosmos_cosmos_sdk_types.Coin { if m != nil { return m.BaseInvestmintAmountAmpere } return github_com_cosmos_cosmos_sdk_types.Coin{} } func init() { proto.RegisterType((*Params)(nil), "cyber.resources.v1beta1.Params") } func init() { proto.RegisterFile("cyber/resources/v1beta1/types.proto", fileDescriptor_3be852646b47c447) } var fileDescriptor_3be852646b47c447 = []byte{ // 425 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x93, 0x3f, 0x8f, 0xd3, 0x30, 0x18, 0xc6, 0x63, 0x38, 0xca, 0x61, 0xc4, 0x12, 0x40, 0x97, 0xcb, 0x41, 0xee, 0x04, 0x03, 0xb7, 0x5c, 0xac, 0xbb, 0x1b, 0x11, 0x42, 0x3d, 0x26, 0x06, 0xa4, 0x0a, 0x24, 0x06, 0x96, 0xc8, 0x49, 0xad, 0xd4, 0x6a, 0xec, 0x37, 0xb2, 0xdd, 0xa8, 0xfd, 0x08, 0x0c, 0x48, 0x7c, 0xac, 0x8e, 0x1d, 0x99, 0x2a, 0xd4, 0x7e, 0x06, 0x16, 0x26, 0x14, 0xdb, 0x2d, 0xa5, 0x2d, 0xdb, 0x4d, 0x49, 0xe4, 0xdf, 0xf3, 0xf8, 0xc9, 0xfb, 0x07, 0xbf, 0x2c, 0x26, 0x39, 0x53, 0x44, 0x31, 0x0d, 0x23, 0x55, 0x30, 0x4d, 0x9a, 0xcb, 0x9c, 0x19, 0x7a, 0x49, 0xcc, 0xa4, 0x66, 0x3a, 0xad, 0x15, 0x18, 0x08, 0x8f, 0x2c, 0x94, 0xae, 0xa1, 0xd4, 0x43, 0xf1, 0x93, 0x12, 0x4a, 0xb0, 0x0c, 0x69, 0xdf, 0x1c, 0x1e, 0x27, 0x05, 0x68, 0x01, 0x9a, 0xe4, 0x54, 0xb3, 0xb5, 0x5f, 0x01, 0x5c, 0xba, 0xf3, 0x17, 0xbf, 0x0e, 0x70, 0xa7, 0x47, 0x15, 0x15, 0x3a, 0x3c, 0xc1, 0x0f, 0x04, 0x1d, 0x67, 0xba, 0x02, 0xa3, 0x23, 0x74, 0x86, 0xce, 0x1f, 0x7d, 0x3c, 0x14, 0x74, 0xfc, 0xa9, 0xfd, 0x0e, 0x5f, 0xe3, 0x78, 0x40, 0xab, 0x86, 0xcb, 0x32, 0xab, 0x99, 0xe2, 0xd0, 0xcf, 0x1a, 0xa8, 0x4c, 0x96, 0x57, 0x50, 0x0c, 0x75, 0x74, 0xc7, 0xd2, 0x47, 0x9e, 0xe8, 0x59, 0xe0, 0x33, 0x54, 0xe6, 0xc6, 0x1e, 0x87, 0x6f, 0xf1, 0xb3, 0x2d, 0x31, 0x15, 0x35, 0x53, 0x6c, 0x25, 0xbf, 0x6b, 0xe5, 0xc7, 0xff, 0xc8, 0xbb, 0x96, 0xf0, 0x06, 0x6f, 0xf0, 0x49, 0xfb, 0x03, 0x19, 0x97, 0x0d, 0xd3, 0x46, 0x70, 0x69, 0x36, 0x53, 0x44, 0x07, 0x56, 0x1f, 0xb5, 0xc8, 0xfb, 0x35, 0xf1, 0x37, 0x45, 0xd8, 0xc5, 0xcf, 0xff, 0x23, 0x77, 0x39, 0xa2, 0x7b, 0xd6, 0x20, 0xde, 0x67, 0xe0, 0x72, 0x84, 0x57, 0xf8, 0xa9, 0xe0, 0x72, 0xd7, 0x21, 0xea, 0x58, 0xe9, 0x63, 0xc1, 0xe5, 0xb6, 0x32, 0xfc, 0x8a, 0x76, 0x63, 0x53, 0x01, 0x23, 0x69, 0x5c, 0xec, 0xfb, 0x67, 0xe8, 0xfc, 0xe1, 0xd5, 0x71, 0xea, 0x5a, 0x94, 0xb6, 0xe8, 0xaa, 0x9b, 0xe9, 0x3b, 0xe0, 0xf2, 0x86, 0x4c, 0xe7, 0xa7, 0xc1, 0xef, 0xf9, 0xe9, 0xab, 0x92, 0x9b, 0xc1, 0x28, 0x4f, 0x0b, 0x10, 0xc4, 0xf7, 0xd3, 0x3d, 0x2e, 0x74, 0x7f, 0xe8, 0xa7, 0xa3, 0x15, 0x6c, 0x97, 0xa0, 0x6b, 0x2f, 0xb3, 0x25, 0xf8, 0x86, 0x76, 0x6b, 0xe0, 0xb3, 0xf8, 0x1a, 0x1c, 0xde, 0x7a, 0x9a, 0x78, 0x5f, 0x1a, 0xdf, 0xd7, 0x0f, 0xd3, 0x45, 0x82, 0x66, 0x8b, 0x04, 0xfd, 0x5c, 0x24, 0xe8, 0xfb, 0x32, 0x09, 0x66, 0xcb, 0x24, 0xf8, 0xb1, 0x4c, 0x82, 0x2f, 0xd7, 0x9b, 0xf6, 0xed, 0xac, 0x17, 0x20, 0x4b, 0xc5, 0xb4, 0x26, 0x25, 0x5c, 0xb8, 0x0d, 0x19, 0x6f, 0xec, 0x88, 0xbd, 0x2f, 0xef, 0xd8, 0x69, 0xbe, 0xfe, 0x13, 0x00, 0x00, 0xff, 0xff, 0x42, 0x8b, 0x46, 0xd6, 0x43, 0x03, 0x00, 0x00, } func (m *Params) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *Params) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *Params) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.BaseInvestmintAmountAmpere.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintTypes(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x42 { size, err := m.BaseInvestmintAmountVolt.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintTypes(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x3a if m.MinInvestmintPeriod != 0 { i = encodeVarintTypes(dAtA, i, uint64(m.MinInvestmintPeriod)) i-- dAtA[i] = 0x30 } if m.BaseInvestmintPeriodAmpere != 0 { i = encodeVarintTypes(dAtA, i, uint64(m.BaseInvestmintPeriodAmpere)) i-- dAtA[i] = 0x28 } if m.BaseInvestmintPeriodVolt != 0 { i = encodeVarintTypes(dAtA, i, uint64(m.BaseInvestmintPeriodVolt)) i-- dAtA[i] = 0x20 } if m.HalvingPeriodAmpereBlocks != 0 { i = encodeVarintTypes(dAtA, i, uint64(m.HalvingPeriodAmpereBlocks)) i-- dAtA[i] = 0x18 } if m.HalvingPeriodVoltBlocks != 0 { i = encodeVarintTypes(dAtA, i, uint64(m.HalvingPeriodVoltBlocks)) i-- dAtA[i] = 0x10 } if m.MaxSlots != 0 { i = encodeVarintTypes(dAtA, i, uint64(m.MaxSlots)) i-- dAtA[i] = 0x8 } return len(dAtA) - i, nil } func encodeVarintTypes(dAtA []byte, offset int, v uint64) int { offset -= sovTypes(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *Params) Size() (n int) { if m == nil { return 0 } var l int _ = l if m.MaxSlots != 0 { n += 1 + sovTypes(uint64(m.MaxSlots)) } if m.HalvingPeriodVoltBlocks != 0 { n += 1 + sovTypes(uint64(m.HalvingPeriodVoltBlocks)) } if m.HalvingPeriodAmpereBlocks != 0 { n += 1 + sovTypes(uint64(m.HalvingPeriodAmpereBlocks)) } if m.BaseInvestmintPeriodVolt != 0 { n += 1 + sovTypes(uint64(m.BaseInvestmintPeriodVolt)) } if m.BaseInvestmintPeriodAmpere != 0 { n += 1 + sovTypes(uint64(m.BaseInvestmintPeriodAmpere)) } if m.MinInvestmintPeriod != 0 { n += 1 + sovTypes(uint64(m.MinInvestmintPeriod)) } l = m.BaseInvestmintAmountVolt.Size() n += 1 + l + sovTypes(uint64(l)) l = m.BaseInvestmintAmountAmpere.Size() n += 1 + l + sovTypes(uint64(l)) return n } func sovTypes(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozTypes(x uint64) (n int) { return sovTypes(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *Params) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: Params: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: Params: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field MaxSlots", wireType) } m.MaxSlots = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.MaxSlots |= uint32(b&0x7F) << shift if b < 0x80 { break } } case 2: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field HalvingPeriodVoltBlocks", wireType) } m.HalvingPeriodVoltBlocks = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.HalvingPeriodVoltBlocks |= uint32(b&0x7F) << shift if b < 0x80 { break } } case 3: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field HalvingPeriodAmpereBlocks", wireType) } m.HalvingPeriodAmpereBlocks = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.HalvingPeriodAmpereBlocks |= uint32(b&0x7F) << shift if b < 0x80 { break } } case 4: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field BaseInvestmintPeriodVolt", wireType) } m.BaseInvestmintPeriodVolt = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.BaseInvestmintPeriodVolt |= uint32(b&0x7F) << shift if b < 0x80 { break } } case 5: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field BaseInvestmintPeriodAmpere", wireType) } m.BaseInvestmintPeriodAmpere = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.BaseInvestmintPeriodAmpere |= uint32(b&0x7F) << shift if b < 0x80 { break } } case 6: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field MinInvestmintPeriod", wireType) } m.MinInvestmintPeriod = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.MinInvestmintPeriod |= uint32(b&0x7F) << shift if b < 0x80 { break } } case 7: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field BaseInvestmintAmountVolt", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthTypes } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthTypes } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.BaseInvestmintAmountVolt.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 8: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field BaseInvestmintAmountAmpere", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTypes } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthTypes } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthTypes } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.BaseInvestmintAmountAmpere.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTypes(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTypes } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipTypes(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTypes } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTypes } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTypes } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthTypes } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupTypes } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthTypes } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthTypes = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowTypes = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupTypes = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/resources/wasm/interface.go ================================================ package wasm import ( "encoding/json" errorsmod "cosmossdk.io/errors" wasmvmtypes "github.com/CosmWasm/wasmvm/types" pluginstypes "github.com/cybercongress/go-cyber/v7/plugins/types" "github.com/cybercongress/go-cyber/v7/x/resources/keeper" sdk "github.com/cosmos/cosmos-sdk/types" ) type Messenger struct { keeper *keeper.Keeper } func NewMessenger( keeper *keeper.Keeper, ) *Messenger { return &Messenger{ keeper: keeper, } } func (m *Messenger) HandleMsg(ctx sdk.Context, contractAddr sdk.AccAddress, contractIBCPortID string, msg pluginstypes.CyberMsg) ([]sdk.Event, [][]byte, error) { switch { case msg.Investmint != nil: if msg.Investmint.Neuron != contractAddr.String() { return nil, nil, wasmvmtypes.InvalidRequest{Err: "investmint wrong neuron"} } msgServer := keeper.NewMsgServerImpl(*m.keeper) if err := msg.Investmint.ValidateBasic(); err != nil { return nil, nil, errorsmod.Wrap(err, "failed validating msg") } res, err := msgServer.Investmint( sdk.WrapSDKContext(ctx), msg.Investmint, ) if err != nil { return nil, nil, errorsmod.Wrap(err, "investmint msg") } responseBytes, err := json.Marshal(*res) if err != nil { return nil, nil, errorsmod.Wrap(err, "failed to serialize investmint response") } resp := [][]byte{responseBytes} return nil, resp, nil default: return nil, nil, pluginstypes.ErrHandleMsg } } ================================================ FILE: x/staking/module.go ================================================ package staking import ( "fmt" "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/types/module" authkeeper "github.com/cosmos/cosmos-sdk/x/auth/keeper" bankkeeper "github.com/cosmos/cosmos-sdk/x/bank/keeper" "github.com/cosmos/cosmos-sdk/x/staking" "github.com/cosmos/cosmos-sdk/x/staking/exported" "github.com/cosmos/cosmos-sdk/x/staking/keeper" "github.com/cosmos/cosmos-sdk/x/staking/types" ) var _ module.AppModule = AppModule{} type AppModule struct { staking.AppModule sk *keeper.Keeper bk bankkeeper.Keeper ak authkeeper.AccountKeeper // legacySubspace is used solely for migration of x/params managed parameters legacySubspace exported.Subspace } func NewAppModule( cdc codec.Codec, stakingKeeper *keeper.Keeper, accountKeeper authkeeper.AccountKeeper, bankKeeper bankkeeper.Keeper, ls exported.Subspace, ) AppModule { return AppModule{ AppModule: staking.NewAppModule(cdc, stakingKeeper, accountKeeper, bankKeeper, ls), sk: stakingKeeper, bk: bankKeeper, ak: accountKeeper, legacySubspace: ls, } } func (am AppModule) RegisterServices(cfg module.Configurator) { types.RegisterMsgServer(cfg.MsgServer(), NewMsgServerImpl(am.sk, am.bk)) querier := keeper.Querier{Keeper: am.sk} types.RegisterQueryServer(cfg.QueryServer(), querier) m := keeper.NewMigrator(am.sk, am.legacySubspace) if err := cfg.RegisterMigration(types.ModuleName, 1, m.Migrate1to2); err != nil { panic(fmt.Sprintf("failed to migrate x/%s from version 1 to 2: %v", types.ModuleName, err)) } if err := cfg.RegisterMigration(types.ModuleName, 2, m.Migrate2to3); err != nil { panic(fmt.Sprintf("failed to migrate x/%s from version 2 to 3: %v", types.ModuleName, err)) } if err := cfg.RegisterMigration(types.ModuleName, 3, m.Migrate3to4); err != nil { panic(fmt.Sprintf("failed to migrate x/%s from version 3 to 4: %v", types.ModuleName, err)) } } ================================================ FILE: x/staking/msg_server.go ================================================ package staking import ( "context" "strconv" "time" "github.com/armon/go-metrics" govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" "google.golang.org/grpc/codes" cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types" "github.com/cosmos/cosmos-sdk/telemetry" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" bankkeeper "github.com/cosmos/cosmos-sdk/x/bank/keeper" "github.com/cosmos/cosmos-sdk/x/staking/keeper" "github.com/cosmos/cosmos-sdk/x/staking/types" "google.golang.org/grpc/status" ctypes "github.com/cybercongress/go-cyber/v7/types" resourcestypes "github.com/cybercongress/go-cyber/v7/x/resources/types" ) type msgServer struct { *keeper.Keeper bk bankkeeper.Keeper } // NewMsgServerImpl returns an implementation of the bank MsgServer interface // for the provided Keeper. func NewMsgServerImpl(keeper *keeper.Keeper, bk bankkeeper.Keeper) types.MsgServer { return &msgServer{ Keeper: keeper, bk: bk, } } var _ types.MsgServer = msgServer{} // CreateValidator defines a method for creating a new validator func (k msgServer) CreateValidator(goCtx context.Context, msg *types.MsgCreateValidator) (*types.MsgCreateValidatorResponse, error) { result, err := WrapCreateValidator(goCtx, k.bk, msg) if err != nil { return nil, err } if !result { return nil, sdkerrors.Wrapf(sdkerrors.ErrUnauthorized, "unauthorized message: %T", msg) } // --------------------- ctx := sdk.UnwrapSDKContext(goCtx) valAddr, err := sdk.ValAddressFromBech32(msg.ValidatorAddress) if err != nil { return nil, err } if msg.Commission.Rate.LT(k.MinCommissionRate(ctx)) { return nil, sdkerrors.Wrapf(types.ErrCommissionLTMinRate, "cannot set validator commission to less than minimum rate of %s", k.MinCommissionRate(ctx)) } // check to see if the pubkey or sender has been registered before if _, found := k.GetValidator(ctx, valAddr); found { return nil, types.ErrValidatorOwnerExists } pk, ok := msg.Pubkey.GetCachedValue().(cryptotypes.PubKey) if !ok { return nil, sdkerrors.Wrapf(sdkerrors.ErrInvalidType, "Expecting cryptotypes.PubKey, got %T", pk) } if _, found := k.GetValidatorByConsAddr(ctx, sdk.GetConsAddress(pk)); found { return nil, types.ErrValidatorPubKeyExists } bondDenom := k.BondDenom(ctx) if msg.Value.Denom != bondDenom { return nil, sdkerrors.Wrapf( sdkerrors.ErrInvalidRequest, "invalid coin denomination: got %s, expected %s", msg.Value.Denom, bondDenom, ) } if _, err := msg.Description.EnsureLength(); err != nil { return nil, err } cp := ctx.ConsensusParams() if cp != nil && cp.Validator != nil { pkType := pk.Type() hasKeyType := false for _, keyType := range cp.Validator.PubKeyTypes { if pkType == keyType { hasKeyType = true break } } if !hasKeyType { return nil, sdkerrors.Wrapf( types.ErrValidatorPubKeyTypeNotSupported, "got: %s, expected: %s", pk.Type(), cp.Validator.PubKeyTypes, ) } } validator, err := types.NewValidator(valAddr, pk, msg.Description) if err != nil { return nil, err } commission := types.NewCommissionWithTime( msg.Commission.Rate, msg.Commission.MaxRate, msg.Commission.MaxChangeRate, ctx.BlockHeader().Time, ) validator, err = validator.SetInitialCommission(commission) if err != nil { return nil, err } delegatorAddress, err := sdk.AccAddressFromBech32(msg.DelegatorAddress) if err != nil { return nil, err } validator.MinSelfDelegation = msg.MinSelfDelegation k.SetValidator(ctx, validator) k.SetValidatorByConsAddr(ctx, validator) k.SetNewValidatorByPowerIndex(ctx, validator) // call the after-creation hook if err := k.Hooks().AfterValidatorCreated(ctx, validator.GetOperator()); err != nil { return nil, err } // move coins from the msg.Address account to a (self-delegation) delegator account // the validator account and global shares are updated within here // NOTE source will always be from a wallet which are unbonded _, err = k.Keeper.Delegate(ctx, delegatorAddress, msg.Value.Amount, types.Unbonded, validator, true) if err != nil { return nil, err } ctx.EventManager().EmitEvents(sdk.Events{ sdk.NewEvent( types.EventTypeCreateValidator, sdk.NewAttribute(types.AttributeKeyValidator, msg.ValidatorAddress), sdk.NewAttribute(sdk.AttributeKeyAmount, msg.Value.String()), ), }) return &types.MsgCreateValidatorResponse{}, nil } // EditValidator defines a method for editing an existing validator func (k msgServer) EditValidator(goCtx context.Context, msg *types.MsgEditValidator) (*types.MsgEditValidatorResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) valAddr, err := sdk.ValAddressFromBech32(msg.ValidatorAddress) if err != nil { return nil, err } // validator must already be registered validator, found := k.GetValidator(ctx, valAddr) if !found { return nil, types.ErrNoValidatorFound } // replace all editable fields (clients should autofill existing values) description, err := validator.Description.UpdateDescription(msg.Description) if err != nil { return nil, err } validator.Description = description if msg.CommissionRate != nil { commission, err := k.UpdateValidatorCommission(ctx, validator, *msg.CommissionRate) if err != nil { return nil, err } // call the before-modification hook since we're about to update the commission if err := k.Hooks().BeforeValidatorModified(ctx, valAddr); err != nil { return nil, err } validator.Commission = commission } if msg.MinSelfDelegation != nil { if !msg.MinSelfDelegation.GT(validator.MinSelfDelegation) { return nil, types.ErrMinSelfDelegationDecreased } if msg.MinSelfDelegation.GT(validator.Tokens) { return nil, types.ErrSelfDelegationBelowMinimum } validator.MinSelfDelegation = *msg.MinSelfDelegation } k.SetValidator(ctx, validator) ctx.EventManager().EmitEvents(sdk.Events{ sdk.NewEvent( types.EventTypeEditValidator, sdk.NewAttribute(types.AttributeKeyCommissionRate, validator.Commission.String()), sdk.NewAttribute(types.AttributeKeyMinSelfDelegation, validator.MinSelfDelegation.String()), ), }) return &types.MsgEditValidatorResponse{}, nil } // Delegate defines a method for performing a delegation of coins from a delegator to a validator func (k msgServer) Delegate(goCtx context.Context, msg *types.MsgDelegate) (*types.MsgDelegateResponse, error) { result, err := WrapDelegate(goCtx, k.bk, msg) if err != nil { return nil, err } if !result { return nil, sdkerrors.Wrapf(sdkerrors.ErrUnauthorized, "unauthorized message: %T", msg) } // --------------------- ctx := sdk.UnwrapSDKContext(goCtx) valAddr, valErr := sdk.ValAddressFromBech32(msg.ValidatorAddress) if valErr != nil { return nil, valErr } validator, found := k.GetValidator(ctx, valAddr) if !found { return nil, types.ErrNoValidatorFound } delegatorAddress, err := sdk.AccAddressFromBech32(msg.DelegatorAddress) if err != nil { return nil, err } bondDenom := k.BondDenom(ctx) if msg.Amount.Denom != bondDenom { return nil, sdkerrors.Wrapf( sdkerrors.ErrInvalidRequest, "invalid coin denomination: got %s, expected %s", msg.Amount.Denom, bondDenom, ) } // NOTE: source funds are always unbonded newShares, err := k.Keeper.Delegate(ctx, delegatorAddress, msg.Amount.Amount, types.Unbonded, validator, true) if err != nil { return nil, err } if msg.Amount.Amount.IsInt64() { defer func() { telemetry.IncrCounter(1, types.ModuleName, "delegate") telemetry.SetGaugeWithLabels( []string{"tx", "msg", msg.Type()}, float32(msg.Amount.Amount.Int64()), []metrics.Label{telemetry.NewLabel("denom", msg.Amount.Denom)}, ) }() } ctx.EventManager().EmitEvents(sdk.Events{ sdk.NewEvent( types.EventTypeDelegate, sdk.NewAttribute(types.AttributeKeyValidator, msg.ValidatorAddress), sdk.NewAttribute(types.AttributeKeyDelegator, msg.DelegatorAddress), sdk.NewAttribute(sdk.AttributeKeyAmount, msg.Amount.String()), sdk.NewAttribute(types.AttributeKeyNewShares, newShares.String()), ), }) return &types.MsgDelegateResponse{}, nil } // BeginRedelegate defines a method for performing a redelegation of coins from a delegator and source validator to a destination validator func (k msgServer) BeginRedelegate(goCtx context.Context, msg *types.MsgBeginRedelegate) (*types.MsgBeginRedelegateResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) valSrcAddr, err := sdk.ValAddressFromBech32(msg.ValidatorSrcAddress) if err != nil { return nil, err } delegatorAddress, err := sdk.AccAddressFromBech32(msg.DelegatorAddress) if err != nil { return nil, err } shares, err := k.ValidateUnbondAmount( ctx, delegatorAddress, valSrcAddr, msg.Amount.Amount, ) if err != nil { return nil, err } bondDenom := k.BondDenom(ctx) if msg.Amount.Denom != bondDenom { return nil, sdkerrors.Wrapf( sdkerrors.ErrInvalidRequest, "invalid coin denomination: got %s, expected %s", msg.Amount.Denom, bondDenom, ) } valDstAddr, err := sdk.ValAddressFromBech32(msg.ValidatorDstAddress) if err != nil { return nil, err } completionTime, err := k.BeginRedelegation( ctx, delegatorAddress, valSrcAddr, valDstAddr, shares, ) if err != nil { return nil, err } if msg.Amount.Amount.IsInt64() { defer func() { telemetry.IncrCounter(1, types.ModuleName, "redelegate") telemetry.SetGaugeWithLabels( []string{"tx", "msg", msg.Type()}, float32(msg.Amount.Amount.Int64()), []metrics.Label{telemetry.NewLabel("denom", msg.Amount.Denom)}, ) }() } ctx.EventManager().EmitEvents(sdk.Events{ sdk.NewEvent( types.EventTypeRedelegate, sdk.NewAttribute(types.AttributeKeySrcValidator, msg.ValidatorSrcAddress), sdk.NewAttribute(types.AttributeKeyDstValidator, msg.ValidatorDstAddress), sdk.NewAttribute(sdk.AttributeKeyAmount, msg.Amount.String()), sdk.NewAttribute(types.AttributeKeyCompletionTime, completionTime.Format(time.RFC3339)), ), }) return &types.MsgBeginRedelegateResponse{ CompletionTime: completionTime, }, nil } // Undelegate defines a method for performing an undelegation from a delegate and a validator func (k msgServer) Undelegate(goCtx context.Context, msg *types.MsgUndelegate) (*types.MsgUndelegateResponse, error) { result, err := WrapUndelegate(goCtx, k.bk, msg) if err != nil { return nil, err } if !result { return nil, sdkerrors.Wrapf(sdkerrors.ErrUnauthorized, "unauthorized message: %T", msg) } // --------------------- ctx := sdk.UnwrapSDKContext(goCtx) addr, err := sdk.ValAddressFromBech32(msg.ValidatorAddress) if err != nil { return nil, err } delegatorAddress, err := sdk.AccAddressFromBech32(msg.DelegatorAddress) if err != nil { return nil, err } shares, err := k.ValidateUnbondAmount( ctx, delegatorAddress, addr, msg.Amount.Amount, ) if err != nil { return nil, err } bondDenom := k.BondDenom(ctx) if msg.Amount.Denom != bondDenom { return nil, sdkerrors.Wrapf( sdkerrors.ErrInvalidRequest, "invalid coin denomination: got %s, expected %s", msg.Amount.Denom, bondDenom, ) } completionTime, err := k.Keeper.Undelegate(ctx, delegatorAddress, addr, shares) if err != nil { return nil, err } if msg.Amount.Amount.IsInt64() { defer func() { telemetry.IncrCounter(1, types.ModuleName, "undelegate") telemetry.SetGaugeWithLabels( []string{"tx", "msg", msg.Type()}, float32(msg.Amount.Amount.Int64()), []metrics.Label{telemetry.NewLabel("denom", msg.Amount.Denom)}, ) }() } ctx.EventManager().EmitEvents(sdk.Events{ sdk.NewEvent( types.EventTypeUnbond, sdk.NewAttribute(types.AttributeKeyValidator, msg.ValidatorAddress), sdk.NewAttribute(sdk.AttributeKeyAmount, msg.Amount.String()), sdk.NewAttribute(types.AttributeKeyDelegator, msg.DelegatorAddress), sdk.NewAttribute(types.AttributeKeyCompletionTime, completionTime.Format(time.RFC3339)), ), }) return &types.MsgUndelegateResponse{ CompletionTime: completionTime, }, nil } func (k msgServer) CancelUnbondingDelegation(goCtx context.Context, msg *types.MsgCancelUnbondingDelegation) (*types.MsgCancelUnbondingDelegationResponse, error) { result, err := WrapCancelUnbondingDelegation(goCtx, k.bk, msg) if err != nil { return nil, err } if !result { return nil, sdkerrors.Wrapf(sdkerrors.ErrUnauthorized, "unauthorized message: %T", msg) } // --------------------- ctx := sdk.UnwrapSDKContext(goCtx) valAddr, err := sdk.ValAddressFromBech32(msg.ValidatorAddress) if err != nil { return nil, err } delegatorAddress, err := sdk.AccAddressFromBech32(msg.DelegatorAddress) if err != nil { return nil, err } bondDenom := k.BondDenom(ctx) if msg.Amount.Denom != bondDenom { return nil, sdkerrors.Wrapf( sdkerrors.ErrInvalidRequest, "invalid coin denomination: got %s, expected %s", msg.Amount.Denom, bondDenom, ) } validator, found := k.GetValidator(ctx, valAddr) if !found { return nil, types.ErrNoValidatorFound } // In some situations, the exchange rate becomes invalid, e.g. if // Validator loses all tokens due to slashing. In this case, // make all future delegations invalid. if validator.InvalidExRate() { return nil, types.ErrDelegatorShareExRateInvalid } if validator.IsJailed() { return nil, types.ErrValidatorJailed } ubd, found := k.GetUnbondingDelegation(ctx, delegatorAddress, valAddr) if !found { return nil, status.Errorf( codes.NotFound, "unbonding delegation with delegator %s not found for validator %s", msg.DelegatorAddress, msg.ValidatorAddress, ) } var ( unbondEntry types.UnbondingDelegationEntry unbondEntryIndex int64 = -1 ) for i, entry := range ubd.Entries { if entry.CreationHeight == msg.CreationHeight { unbondEntry = entry unbondEntryIndex = int64(i) break } } if unbondEntryIndex == -1 { return nil, sdkerrors.ErrNotFound.Wrapf("unbonding delegation entry is not found at block height %d", msg.CreationHeight) } if unbondEntry.Balance.LT(msg.Amount.Amount) { return nil, sdkerrors.ErrInvalidRequest.Wrap("amount is greater than the unbonding delegation entry balance") } if unbondEntry.CompletionTime.Before(ctx.BlockTime()) { return nil, sdkerrors.ErrInvalidRequest.Wrap("unbonding delegation is already processed") } // delegate back the unbonding delegation amount to the validator _, err = k.Keeper.Delegate(ctx, delegatorAddress, msg.Amount.Amount, types.Unbonding, validator, false) if err != nil { return nil, err } amount := unbondEntry.Balance.Sub(msg.Amount.Amount) if amount.IsZero() { ubd.RemoveEntry(unbondEntryIndex) } else { // update the unbondingDelegationEntryBalance and InitialBalance for ubd entry unbondEntry.Balance = amount unbondEntry.InitialBalance = unbondEntry.InitialBalance.Sub(msg.Amount.Amount) ubd.Entries[unbondEntryIndex] = unbondEntry } // set the unbonding delegation or remove it if there are no more entries if len(ubd.Entries) == 0 { k.RemoveUnbondingDelegation(ctx, ubd) } else { k.SetUnbondingDelegation(ctx, ubd) } ctx.EventManager().EmitEvent( sdk.NewEvent( types.EventTypeCancelUnbondingDelegation, sdk.NewAttribute(sdk.AttributeKeyAmount, msg.Amount.String()), sdk.NewAttribute(types.AttributeKeyValidator, msg.ValidatorAddress), sdk.NewAttribute(types.AttributeKeyDelegator, msg.DelegatorAddress), sdk.NewAttribute(types.AttributeKeyCreationHeight, strconv.FormatInt(msg.CreationHeight, 10)), ), ) return &types.MsgCancelUnbondingDelegationResponse{}, nil } func (ms msgServer) UpdateParams(goCtx context.Context, msg *types.MsgUpdateParams) (*types.MsgUpdateParamsResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) if ms.GetAuthority() != msg.Authority { return nil, sdkerrors.Wrapf(govtypes.ErrInvalidSigner, "invalid authority; expected %s, got %s", ms.GetAuthority(), msg.Authority) } // store params if err := ms.SetParams(ctx, msg.Params); err != nil { return nil, err } return &types.MsgUpdateParamsResponse{}, nil } // ------------- func WrapDelegate( goCtx context.Context, bk bankkeeper.Keeper, msg *types.MsgDelegate, ) (bool, error) { ctx := sdk.UnwrapSDKContext(goCtx) delegator, err := sdk.AccAddressFromBech32(msg.DelegatorAddress) if err != nil { return false, err } toMint := sdk.NewCoin(ctypes.SCYB, msg.Amount.Amount) err = bk.MintCoins(ctx, resourcestypes.ResourcesName, sdk.NewCoins(toMint)) if err != nil { return false, err } err = bk.SendCoinsFromModuleToAccount(ctx, resourcestypes.ResourcesName, delegator, sdk.NewCoins(toMint)) if err != nil { return false, err } return true, nil } func WrapUndelegate( goCtx context.Context, bk bankkeeper.Keeper, msg *types.MsgUndelegate, ) (bool, error) { ctx := sdk.UnwrapSDKContext(goCtx) delegator, err := sdk.AccAddressFromBech32(msg.DelegatorAddress) if err != nil { return false, err } toBurn := sdk.NewCoin(ctypes.SCYB, msg.Amount.Amount) err = bk.SendCoinsFromAccountToModule(ctx, delegator, resourcestypes.ResourcesName, sdk.NewCoins(toBurn)) if err != nil { return false, err } err = bk.BurnCoins(ctx, resourcestypes.ResourcesName, sdk.NewCoins(toBurn)) if err != nil { return false, err } return true, nil } func WrapCreateValidator( goCtx context.Context, bk bankkeeper.Keeper, msg *types.MsgCreateValidator, ) (bool, error) { ctx := sdk.UnwrapSDKContext(goCtx) delegator, err := sdk.AccAddressFromBech32(msg.DelegatorAddress) if err != nil { return false, err } toMint := sdk.NewCoin(ctypes.SCYB, msg.Value.Amount) err = bk.MintCoins(ctx, resourcestypes.ResourcesName, sdk.NewCoins(toMint)) if err != nil { return false, err } err = bk.SendCoinsFromModuleToAccount(ctx, resourcestypes.ResourcesName, delegator, sdk.NewCoins(toMint)) if err != nil { return false, err } return true, nil } func WrapCancelUnbondingDelegation( goCtx context.Context, bk bankkeeper.Keeper, msg *types.MsgCancelUnbondingDelegation, ) (bool, error) { ctx := sdk.UnwrapSDKContext(goCtx) delegator, err := sdk.AccAddressFromBech32(msg.DelegatorAddress) if err != nil { return false, err } toMint := sdk.NewCoin(ctypes.SCYB, msg.Amount.Amount) err = bk.MintCoins(ctx, resourcestypes.ResourcesName, sdk.NewCoins(toMint)) if err != nil { return false, err } err = bk.SendCoinsFromModuleToAccount(ctx, resourcestypes.ResourcesName, delegator, sdk.NewCoins(toMint)) if err != nil { return false, err } return true, nil } ================================================ FILE: x/tokenfactory/README.md ================================================ # Token Factory The tokenfactory module allows any account to create a new token with the name `factory/{creator address}/{subdenom}`. Because tokens are namespaced by creator address, this allows token minting to be permissionless, due to not needing to resolve name collisions. A single account can create multiple denoms, by providing a unique subdenom for each created denom. Once a denom is created, the original creator is given "admin" privileges over the asset. This allows them to: - Mint their denom to any account - Burn their denom from any account - Create a transfer of their denom between any two accounts - Change the admin. In the future, more admin capabilities may be added. Admins can choose to share admin privileges with other accounts using the authz module. The `ChangeAdmin` functionality, allows changing the master admin account, or even setting it to `""`, meaning no account has admin privileges of the asset. ## Messages ### CreateDenom Creates a denom of `factory/{creator address}/{subdenom}` given the denom creator address and the subdenom. Subdenoms can contain `[a-zA-Z0-9./]`. ```go message MsgCreateDenom { string sender = 1 [ (gogoproto.moretags) = "yaml:\"sender\"" ]; string subdenom = 2 [ (gogoproto.moretags) = "yaml:\"subdenom\"" ]; } ``` **State Modifications:** - Fund community pool with the denom creation fee from the creator address, set in `Params`. - Set `DenomMetaData` via bank keeper. - Set `AuthorityMetadata` for the given denom to store the admin for the created denom `factory/{creator address}/{subdenom}`. Admin is automatically set as the Msg sender. - Add denom to the `CreatorPrefixStore`, where a state of denoms created per creator is kept. ### Mint Minting of a specific denom is only allowed for the current admin. Note, the current admin is defaulted to the creator of the denom. ```go message MsgMint { string sender = 1 [ (gogoproto.moretags) = "yaml:\"sender\"" ]; cosmos.base.v1beta1.Coin amount = 2 [ (gogoproto.moretags) = "yaml:\"amount\"", (gogoproto.nullable) = false ]; } ``` **State Modifications:** - Safety check the following - Check that the denom minting is created via `tokenfactory` module - Check that the sender of the message is the admin of the denom - Mint designated amount of tokens for the denom via `bank` module ### Burn Burning of a specific denom is only allowed for the current admin. Note, the current admin is defaulted to the creator of the denom. ```go message MsgBurn { string sender = 1 [ (gogoproto.moretags) = "yaml:\"sender\"" ]; cosmos.base.v1beta1.Coin amount = 2 [ (gogoproto.moretags) = "yaml:\"amount\"", (gogoproto.nullable) = false ]; } ``` **State Modifications:** - Safety check the following - Check that the denom minting is created via `tokenfactory` module - Check that the sender of the message is the admin of the denom - Burn designated amount of tokens for the denom via `bank` module ### ChangeAdmin Change the admin of a denom. Note, this is only allowed to be called by the current admin of the denom. ```go message MsgChangeAdmin { string sender = 1 [ (gogoproto.moretags) = "yaml:\"sender\"" ]; string denom = 2 [ (gogoproto.moretags) = "yaml:\"denom\"" ]; string newAdmin = 3 [ (gogoproto.moretags) = "yaml:\"new_admin\"" ]; } ``` ### SetDenomMetadata Setting of metadata for a specific denom is only allowed for the admin of the denom. It allows the overwriting of the denom metadata in the bank module. ```go message MsgChangeAdmin { string sender = 1 [ (gogoproto.moretags) = "yaml:\"sender\"" ]; cosmos.bank.v1beta1.Metadata metadata = 2 [ (gogoproto.moretags) = "yaml:\"metadata\"", (gogoproto.nullable) = false ]; } ``` **State Modifications:** - Check that sender of the message is the admin of denom - Modify `AuthorityMetadata` state entry to change the admin of the denom ## Expectations from the chain The chain's bech32 prefix for addresses can be at most 16 characters long. This comes from denoms having a 128 byte maximum length, enforced from the SDK, and us setting longest_subdenom to be 44 bytes. A token factory token's denom is: `factory/{creator address}/{subdenom}` Splitting up into sub-components, this has: - `len(factory) = 7` - `2 * len("/") = 2` - `len(longest_subdenom)` - `len(creator_address) = len(bech32(longest_addr_length, chain_addr_prefix))`. Longest addr length at the moment is `32 bytes`. Due to SDK error correction settings, this means `len(bech32(32, chain_addr_prefix)) = len(chain_addr_prefix) + 1 + 58`. Adding this all, we have a total length constraint of `128 = 7 + 2 + len(longest_subdenom) + len(longest_chain_addr_prefix) + 1 + 58`. Therefore `len(longest_subdenom) + len(longest_chain_addr_prefix) = 128 - (7 + 2 + 1 + 58) = 60`. The choice between how we standardized the split these 60 bytes between maxes from longest_subdenom and longest_chain_addr_prefix is somewhat arbitrary. Considerations going into this: - Per [BIP-0173](https://github.com/bitcoin/bips/blob/master/bip-0173.mediawiki#bech32) the technically longest HRP for a 32 byte address ('data field') is 31 bytes. (Comes from encode(data) = 59 bytes, and max length = 90 bytes) - subdenom should be at least 32 bytes so hashes can go into it - longer subdenoms are very helpful for creating human readable denoms - chain addresses should prefer being smaller. The longest HRP in cosmos to date is 11 bytes. (`persistence`) For explicitness, its currently set to `len(longest_subdenom) = 44` and `len(longest_chain_addr_prefix) = 16`. Please note, if the SDK increases the maximum length of a denom from 128 bytes, these caps should increase. So please don't make code rely on these max lengths for parsing. ================================================ FILE: x/tokenfactory/client/cli/query.go ================================================ package cli import ( "fmt" "github.com/spf13/cobra" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cybercongress/go-cyber/v7/x/tokenfactory/types" ) // GetQueryCmd returns the cli query commands for this module func GetQueryCmd() *cobra.Command { // Group tokenfactory queries under a subcommand cmd := &cobra.Command{ Use: types.ModuleName, Short: fmt.Sprintf("Querying commands for the %s module", types.ModuleName), DisableFlagParsing: true, SuggestionsMinimumDistance: 2, RunE: client.ValidateCmd, } cmd.AddCommand( GetParams(), GetCmdDenomAuthorityMetadata(), GetCmdDenomsFromCreator(), ) return cmd } // GetParams returns the params for the module func GetParams() *cobra.Command { cmd := &cobra.Command{ Use: "params [flags]", Short: "Get the params for the x/tokenfactory module", Args: cobra.ExactArgs(0), RunE: func(cmd *cobra.Command, _ []string) error { clientCtx, err := client.GetClientQueryContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) res, err := queryClient.Params(cmd.Context(), &types.QueryParamsRequest{}) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } // GetCmdDenomAuthorityMetadata returns the authority metadata for a queried denom func GetCmdDenomAuthorityMetadata() *cobra.Command { cmd := &cobra.Command{ Use: "denom-authority-metadata [denom] [flags]", Short: "Get the authority metadata for a specific denom", Args: cobra.ExactArgs(1), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientQueryContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) res, err := queryClient.DenomAuthorityMetadata(cmd.Context(), &types.QueryDenomAuthorityMetadataRequest{ Denom: args[0], }) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } // GetCmdDenomsFromCreator a command to get a list of all tokens created by a specific creator address func GetCmdDenomsFromCreator() *cobra.Command { cmd := &cobra.Command{ Use: "denoms-from-creator [creator address] [flags]", Short: "Returns a list of all tokens created by a specific creator address", Args: cobra.ExactArgs(1), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientQueryContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) res, err := queryClient.DenomsFromCreator(cmd.Context(), &types.QueryDenomsFromCreatorRequest{ Creator: args[0], }) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd } ================================================ FILE: x/tokenfactory/client/cli/tx.go ================================================ package cli import ( "fmt" "strconv" "strings" "github.com/spf13/cobra" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" "github.com/cosmos/cosmos-sdk/client/tx" sdk "github.com/cosmos/cosmos-sdk/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" "github.com/cybercongress/go-cyber/v7/x/tokenfactory/types" ) // GetTxCmd returns the transaction commands for this module func GetTxCmd() *cobra.Command { cmd := &cobra.Command{ Use: types.ModuleName, Short: fmt.Sprintf("%s transactions subcommands", types.ModuleName), DisableFlagParsing: true, SuggestionsMinimumDistance: 2, RunE: client.ValidateCmd, } cmd.AddCommand( NewCreateDenomCmd(), NewMintCmd(), NewMintToCmd(), NewBurnCmd(), NewBurnFromCmd(), NewForceTransferCmd(), NewChangeAdminCmd(), NewModifyDenomMetadataCmd(), ) return cmd } // NewCreateDenomCmd broadcast MsgCreateDenom func NewCreateDenomCmd() *cobra.Command { cmd := &cobra.Command{ Use: "create-denom [subdenom] [flags]", Short: "create a new denom from an account", Args: cobra.ExactArgs(1), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientTxContext(cmd) if err != nil { return err } txf, err := tx.NewFactoryCLI(clientCtx, cmd.Flags()) if err != nil { return err } txf = txf.WithTxConfig(clientCtx.TxConfig).WithAccountRetriever(clientCtx.AccountRetriever) msg := types.NewMsgCreateDenom( clientCtx.GetFromAddress().String(), args[0], ) return tx.GenerateOrBroadcastTxWithFactory(clientCtx, txf, msg) }, } flags.AddTxFlagsToCmd(cmd) return cmd } // NewMintCmd broadcast MsgMint func NewMintCmd() *cobra.Command { cmd := &cobra.Command{ Use: "mint [amount] [flags]", Short: "Mint a denom to your address. Must have admin authority to do so.", Args: cobra.ExactArgs(1), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientTxContext(cmd) if err != nil { return err } txf, err := tx.NewFactoryCLI(clientCtx, cmd.Flags()) if err != nil { return err } txf = txf.WithTxConfig(clientCtx.TxConfig).WithAccountRetriever(clientCtx.AccountRetriever) amount, err := sdk.ParseCoinNormalized(args[0]) if err != nil { return err } msg := types.NewMsgMint( clientCtx.GetFromAddress().String(), amount, ) return tx.GenerateOrBroadcastTxWithFactory(clientCtx, txf, msg) }, } flags.AddTxFlagsToCmd(cmd) return cmd } // NewMintToCmd broadcast MsgMintTo func NewMintToCmd() *cobra.Command { cmd := &cobra.Command{ Use: "mint-to [address] [amount] [flags]", Short: "Mint a denom to an address. Must have admin authority to do so.", Args: cobra.ExactArgs(2), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientTxContext(cmd) if err != nil { return err } txf, err := tx.NewFactoryCLI(clientCtx, cmd.Flags()) if err != nil { return err } txf = txf.WithTxConfig(clientCtx.TxConfig).WithAccountRetriever(clientCtx.AccountRetriever) toAddr, err := sdk.AccAddressFromBech32(args[0]) if err != nil { return err } amount, err := sdk.ParseCoinNormalized(args[1]) if err != nil { return err } msg := types.NewMsgMintTo( clientCtx.GetFromAddress().String(), amount, toAddr.String(), ) return tx.GenerateOrBroadcastTxWithFactory(clientCtx, txf, msg) }, } flags.AddTxFlagsToCmd(cmd) return cmd } // NewBurnCmd broadcast MsgBurn func NewBurnCmd() *cobra.Command { cmd := &cobra.Command{ Use: "burn [amount] [flags]", Short: "Burn tokens from an address. Must have admin authority to do so.", Args: cobra.ExactArgs(1), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientTxContext(cmd) if err != nil { return err } txf, err := tx.NewFactoryCLI(clientCtx, cmd.Flags()) if err != nil { return err } txf = txf.WithTxConfig(clientCtx.TxConfig).WithAccountRetriever(clientCtx.AccountRetriever) amount, err := sdk.ParseCoinNormalized(args[0]) if err != nil { return err } msg := types.NewMsgBurn( clientCtx.GetFromAddress().String(), amount, ) return tx.GenerateOrBroadcastTxWithFactory(clientCtx, txf, msg) }, } flags.AddTxFlagsToCmd(cmd) return cmd } // NewBurnFromCmd broadcast MsgBurnFrom func NewBurnFromCmd() *cobra.Command { cmd := &cobra.Command{ Use: "burn-from [address] [amount] [flags]", Short: "Burn tokens from an address. Must have admin authority to do so.", Args: cobra.ExactArgs(2), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientTxContext(cmd) if err != nil { return err } txf, err := tx.NewFactoryCLI(clientCtx, cmd.Flags()) if err != nil { return err } txf = txf.WithTxConfig(clientCtx.TxConfig).WithAccountRetriever(clientCtx.AccountRetriever) fromAddr, err := sdk.AccAddressFromBech32(args[0]) if err != nil { return err } amount, err := sdk.ParseCoinNormalized(args[1]) if err != nil { return err } msg := types.NewMsgBurnFrom( clientCtx.GetFromAddress().String(), amount, fromAddr.String(), ) return tx.GenerateOrBroadcastTxWithFactory(clientCtx, txf, msg) }, } flags.AddTxFlagsToCmd(cmd) return cmd } // NewForceTransferCmd broadcast MsgForceTransfer func NewForceTransferCmd() *cobra.Command { cmd := &cobra.Command{ Use: "force-transfer [amount] [transfer-from-address] [transfer-to-address] [flags]", Short: "Force transfer tokens from one address to another address. Must have admin authority to do so.", Args: cobra.ExactArgs(3), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientTxContext(cmd) if err != nil { return err } txf, err := tx.NewFactoryCLI(clientCtx, cmd.Flags()) if err != nil { return err } txf = txf.WithTxConfig(clientCtx.TxConfig).WithAccountRetriever(clientCtx.AccountRetriever) amount, err := sdk.ParseCoinNormalized(args[0]) if err != nil { return err } msg := types.NewMsgForceTransfer( clientCtx.GetFromAddress().String(), amount, args[1], args[2], ) return tx.GenerateOrBroadcastTxWithFactory(clientCtx, txf, msg) }, } flags.AddTxFlagsToCmd(cmd) return cmd } // NewChangeAdminCmd broadcast MsgChangeAdmin func NewChangeAdminCmd() *cobra.Command { cmd := &cobra.Command{ Use: "change-admin [denom] [new-admin-address] [flags]", Short: "Changes the admin address for a factory-created denom. Must have admin authority to do so.", Args: cobra.ExactArgs(2), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientTxContext(cmd) if err != nil { return err } txf, err := tx.NewFactoryCLI(clientCtx, cmd.Flags()) if err != nil { return err } txf = txf.WithTxConfig(clientCtx.TxConfig).WithAccountRetriever(clientCtx.AccountRetriever) msg := types.NewMsgChangeAdmin( clientCtx.GetFromAddress().String(), args[0], args[1], ) return tx.GenerateOrBroadcastTxWithFactory(clientCtx, txf, msg) }, } flags.AddTxFlagsToCmd(cmd) return cmd } // NewModifyDenomMetadataCmd broadcast a Bank Metadata modification transaction func NewModifyDenomMetadataCmd() *cobra.Command { cmd := &cobra.Command{ Use: "modify-metadata [denom] [ticker-symbol] [description] [exponent] [flags]", Short: "Changes the base data for frontends to query the data of.", Args: cobra.ExactArgs(4), RunE: func(cmd *cobra.Command, args []string) error { clientCtx, err := client.GetClientTxContext(cmd) if err != nil { return err } txf, err := tx.NewFactoryCLI(clientCtx, cmd.Flags()) if err != nil { return err } txf = txf.WithTxConfig(clientCtx.TxConfig).WithAccountRetriever(clientCtx.AccountRetriever) fullDenom, ticker, desc := args[0], strings.ToUpper(args[1]), args[2] if !strings.HasPrefix(fullDenom, "factory/") { return fmt.Errorf("denom must start with factory/") } if len(ticker) == 0 { return fmt.Errorf("ticker cannot be empty") } // Exponent Checks exponent, err := strconv.ParseUint(args[3], 10, 32) if err != nil { return err } bankMetadata := banktypes.Metadata{ Description: desc, Display: ticker, Symbol: ticker, Name: fullDenom, DenomUnits: []*banktypes.DenomUnit{ { Denom: fullDenom, Exponent: 0, // must be 0 for the base denom Aliases: []string{ticker}, }, { Denom: ticker, Exponent: uint32(exponent), Aliases: []string{fullDenom}, }, }, Base: fullDenom, } msg := types.NewMsgSetDenomMetadata( clientCtx.GetFromAddress().String(), bankMetadata, ) return tx.GenerateOrBroadcastTxWithFactory(clientCtx, txf, msg) }, } flags.AddTxFlagsToCmd(cmd) return cmd } ================================================ FILE: x/tokenfactory/exported/exported.go ================================================ package exported import ( sdk "github.com/cosmos/cosmos-sdk/types" paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" ) type ( ParamSet = paramtypes.ParamSet // Subspace defines an interface that implements the legacy x/params Subspace // type. // // NOTE: This is used solely for migration of x/params managed parameters. Subspace interface { GetParamSet(ctx sdk.Context, ps ParamSet) } ) ================================================ FILE: x/tokenfactory/keeper/admins.go ================================================ package keeper import ( "github.com/cosmos/gogoproto/proto" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/tokenfactory/types" ) // GetAuthorityMetadata returns the authority metadata for a specific denom func (k Keeper) GetAuthorityMetadata(ctx sdk.Context, denom string) (types.DenomAuthorityMetadata, error) { bz := k.GetDenomPrefixStore(ctx, denom).Get([]byte(types.DenomAuthorityMetadataKey)) metadata := types.DenomAuthorityMetadata{} err := proto.Unmarshal(bz, &metadata) if err != nil { return types.DenomAuthorityMetadata{}, err } return metadata, nil } // setAuthorityMetadata stores authority metadata for a specific denom func (k Keeper) setAuthorityMetadata(ctx sdk.Context, denom string, metadata types.DenomAuthorityMetadata) error { err := metadata.Validate() if err != nil { return err } store := k.GetDenomPrefixStore(ctx, denom) bz, err := proto.Marshal(&metadata) if err != nil { return err } store.Set([]byte(types.DenomAuthorityMetadataKey), bz) return nil } func (k Keeper) setAdmin(ctx sdk.Context, denom string, admin string) error { metadata, err := k.GetAuthorityMetadata(ctx, denom) if err != nil { return err } metadata.Admin = admin return k.setAuthorityMetadata(ctx, denom, metadata) } ================================================ FILE: x/tokenfactory/keeper/admins_test.go ================================================ package keeper_test import ( "fmt" sdk "github.com/cosmos/cosmos-sdk/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" "github.com/cybercongress/go-cyber/v7/x/tokenfactory/types" ) func (suite *KeeperTestSuite) TestAdminMsgs() { addr0bal := int64(0) addr1bal := int64(0) bankKeeper := suite.App.AppKeepers.BankKeeper suite.CreateDefaultDenom() // Make sure that the admin is set correctly queryRes, err := suite.queryClient.DenomAuthorityMetadata(suite.Ctx.Context(), &types.QueryDenomAuthorityMetadataRequest{ Denom: suite.defaultDenom, }) suite.Require().NoError(err) suite.Require().Equal(suite.TestAccs[0].String(), queryRes.AuthorityMetadata.Admin) // Test minting to admins own account _, err = suite.msgServer.Mint(sdk.WrapSDKContext(suite.Ctx), types.NewMsgMint(suite.TestAccs[0].String(), sdk.NewInt64Coin(suite.defaultDenom, 10))) addr0bal += 10 suite.Require().NoError(err) suite.Require().True(bankKeeper.GetBalance(suite.Ctx, suite.TestAccs[0], suite.defaultDenom).Amount.Int64() == addr0bal, bankKeeper.GetBalance(suite.Ctx, suite.TestAccs[0], suite.defaultDenom)) // Test minting to a different account _, err = suite.msgServer.Mint(sdk.WrapSDKContext(suite.Ctx), types.NewMsgMintTo(suite.TestAccs[0].String(), sdk.NewInt64Coin(suite.defaultDenom, 10), suite.TestAccs[1].String())) addr1bal += 10 suite.Require().NoError(err) suite.Require().True(suite.App.AppKeepers.BankKeeper.GetBalance(suite.Ctx, suite.TestAccs[1], suite.defaultDenom).Amount.Int64() == addr1bal, suite.App.AppKeepers.BankKeeper.GetBalance(suite.Ctx, suite.TestAccs[1], suite.defaultDenom)) // Test force transferring _, err = suite.msgServer.ForceTransfer(sdk.WrapSDKContext(suite.Ctx), types.NewMsgForceTransfer(suite.TestAccs[0].String(), sdk.NewInt64Coin(suite.defaultDenom, 5), suite.TestAccs[1].String(), suite.TestAccs[0].String())) addr1bal -= 5 addr0bal += 5 suite.Require().NoError(err) suite.Require().True(suite.App.AppKeepers.BankKeeper.GetBalance(suite.Ctx, suite.TestAccs[0], suite.defaultDenom).Amount.Int64() == addr0bal, suite.App.AppKeepers.BankKeeper.GetBalance(suite.Ctx, suite.TestAccs[0], suite.defaultDenom)) suite.Require().True(suite.App.AppKeepers.BankKeeper.GetBalance(suite.Ctx, suite.TestAccs[1], suite.defaultDenom).Amount.Int64() == addr1bal, suite.App.AppKeepers.BankKeeper.GetBalance(suite.Ctx, suite.TestAccs[1], suite.defaultDenom)) // Test burning from own account _, err = suite.msgServer.Burn(sdk.WrapSDKContext(suite.Ctx), types.NewMsgBurn(suite.TestAccs[0].String(), sdk.NewInt64Coin(suite.defaultDenom, 5))) suite.Require().NoError(err) suite.Require().True(bankKeeper.GetBalance(suite.Ctx, suite.TestAccs[1], suite.defaultDenom).Amount.Int64() == addr1bal) // Test Change Admin _, err = suite.msgServer.ChangeAdmin(sdk.WrapSDKContext(suite.Ctx), types.NewMsgChangeAdmin(suite.TestAccs[0].String(), suite.defaultDenom, suite.TestAccs[1].String())) suite.Require().NoError(err) queryRes, err = suite.queryClient.DenomAuthorityMetadata(suite.Ctx.Context(), &types.QueryDenomAuthorityMetadataRequest{ Denom: suite.defaultDenom, }) suite.Require().NoError(err) suite.Require().Equal(suite.TestAccs[1].String(), queryRes.AuthorityMetadata.Admin) // Make sure old admin can no longer do actions _, err = suite.msgServer.Burn(sdk.WrapSDKContext(suite.Ctx), types.NewMsgBurn(suite.TestAccs[0].String(), sdk.NewInt64Coin(suite.defaultDenom, 5))) suite.Require().Error(err) // Make sure the new admin works _, err = suite.msgServer.Mint(sdk.WrapSDKContext(suite.Ctx), types.NewMsgMint(suite.TestAccs[1].String(), sdk.NewInt64Coin(suite.defaultDenom, 5))) addr1bal += 5 suite.Require().NoError(err) suite.Require().True(bankKeeper.GetBalance(suite.Ctx, suite.TestAccs[1], suite.defaultDenom).Amount.Int64() == addr1bal) // Try setting admin to empty _, err = suite.msgServer.ChangeAdmin(sdk.WrapSDKContext(suite.Ctx), types.NewMsgChangeAdmin(suite.TestAccs[1].String(), suite.defaultDenom, "")) suite.Require().NoError(err) queryRes, err = suite.queryClient.DenomAuthorityMetadata(suite.Ctx.Context(), &types.QueryDenomAuthorityMetadataRequest{ Denom: suite.defaultDenom, }) suite.Require().NoError(err) suite.Require().Equal("", queryRes.AuthorityMetadata.Admin) } // TestMintDenom ensures the following properties of the MintMessage: // * No one can mint tokens for a denom that doesn't exist // * Only the admin of a denom can mint tokens for it // * The admin of a denom can mint tokens for it func (suite *KeeperTestSuite) TestMintDenom() { balances := make(map[string]int64) for _, acc := range suite.TestAccs { balances[acc.String()] = 0 } // Create a denom suite.CreateDefaultDenom() for _, tc := range []struct { desc string mintMsg types.MsgMint expectPass bool }{ { desc: "denom does not exist", mintMsg: *types.NewMsgMint( suite.TestAccs[0].String(), sdk.NewInt64Coin("factory/osmo1t7egva48prqmzl59x5ngv4zx0dtrwewc9m7z44/evmos", 10), ), expectPass: false, }, { desc: "mint is not by the admin", mintMsg: *types.NewMsgMintTo( suite.TestAccs[1].String(), sdk.NewInt64Coin(suite.defaultDenom, 10), suite.TestAccs[0].String(), ), expectPass: false, }, { desc: "success case - mint to self", mintMsg: *types.NewMsgMint( suite.TestAccs[0].String(), sdk.NewInt64Coin(suite.defaultDenom, 10), ), expectPass: true, }, { desc: "success case - mint to another address", mintMsg: *types.NewMsgMintTo( suite.TestAccs[0].String(), sdk.NewInt64Coin(suite.defaultDenom, 10), suite.TestAccs[1].String(), ), expectPass: true, }, } { suite.Run(fmt.Sprintf("Case %s", tc.desc), func() { tc := tc _, err := suite.msgServer.Mint(sdk.WrapSDKContext(suite.Ctx), &tc.mintMsg) if tc.expectPass { suite.Require().NoError(err) balances[tc.mintMsg.MintToAddress] += tc.mintMsg.Amount.Amount.Int64() } else { suite.Require().Error(err) } mintToAddr, _ := sdk.AccAddressFromBech32(tc.mintMsg.MintToAddress) bal := suite.App.AppKeepers.BankKeeper.GetBalance(suite.Ctx, mintToAddr, suite.defaultDenom).Amount suite.Require().Equal(bal.Int64(), balances[tc.mintMsg.MintToAddress]) }) } } func (suite *KeeperTestSuite) TestBurnDenom() { // Create a denom. suite.CreateDefaultDenom() // mint 1000 default token for all testAccs balances := make(map[string]int64) for _, acc := range suite.TestAccs { _, err := suite.msgServer.Mint(sdk.WrapSDKContext(suite.Ctx), types.NewMsgMintTo(suite.TestAccs[0].String(), sdk.NewInt64Coin(suite.defaultDenom, 1000), acc.String())) suite.Require().NoError(err) balances[acc.String()] = 1000 } for _, tc := range []struct { desc string burnMsg types.MsgBurn expectPass bool }{ { desc: "denom does not exist", burnMsg: *types.NewMsgBurn( suite.TestAccs[0].String(), sdk.NewInt64Coin("factory/osmo1t7egva48prqmzl59x5ngv4zx0dtrwewc9m7z44/evmos", 10), ), expectPass: false, }, { desc: "burn is not by the admin", burnMsg: *types.NewMsgBurnFrom( suite.TestAccs[1].String(), sdk.NewInt64Coin(suite.defaultDenom, 10), suite.TestAccs[0].String(), ), expectPass: false, }, { desc: "burn more than balance", burnMsg: *types.NewMsgBurn( suite.TestAccs[0].String(), sdk.NewInt64Coin(suite.defaultDenom, 10000), ), expectPass: false, }, { desc: "success case - burn from self", burnMsg: *types.NewMsgBurn( suite.TestAccs[0].String(), sdk.NewInt64Coin(suite.defaultDenom, 10), ), expectPass: true, }, { desc: "success case - burn from another address", burnMsg: *types.NewMsgBurnFrom( suite.TestAccs[0].String(), sdk.NewInt64Coin(suite.defaultDenom, 10), suite.TestAccs[1].String(), ), expectPass: true, }, } { suite.Run(fmt.Sprintf("Case %s", tc.desc), func() { tc := tc _, err := suite.msgServer.Burn(sdk.WrapSDKContext(suite.Ctx), &tc.burnMsg) if tc.expectPass { suite.Require().NoError(err) balances[tc.burnMsg.BurnFromAddress] -= tc.burnMsg.Amount.Amount.Int64() } else { suite.Require().Error(err) } burnFromAddr, _ := sdk.AccAddressFromBech32(tc.burnMsg.BurnFromAddress) bal := suite.App.AppKeepers.BankKeeper.GetBalance(suite.Ctx, burnFromAddr, suite.defaultDenom).Amount suite.Require().Equal(bal.Int64(), balances[tc.burnMsg.BurnFromAddress]) }) } } func (suite *KeeperTestSuite) TestForceTransferDenom() { // Create a denom. suite.CreateDefaultDenom() // mint 1000 default token for all testAccs balances := make(map[string]int64) for _, acc := range suite.TestAccs { _, err := suite.msgServer.Mint(sdk.WrapSDKContext(suite.Ctx), types.NewMsgMintTo(suite.TestAccs[0].String(), sdk.NewInt64Coin(suite.defaultDenom, 1000), acc.String())) suite.Require().NoError(err) balances[acc.String()] = 1000 } for _, tc := range []struct { desc string forceTransferMsg types.MsgForceTransfer expectPass bool }{ { desc: "valid force transfer", forceTransferMsg: *types.NewMsgForceTransfer( suite.TestAccs[0].String(), sdk.NewInt64Coin(suite.defaultDenom, 10), suite.TestAccs[1].String(), suite.TestAccs[2].String(), ), expectPass: true, }, { desc: "denom does not exist", forceTransferMsg: *types.NewMsgForceTransfer( suite.TestAccs[0].String(), sdk.NewInt64Coin("factory/osmo1t7egva48prqmzl59x5ngv4zx0dtrwewc9m7z44/evmos", 10), suite.TestAccs[1].String(), suite.TestAccs[2].String(), ), expectPass: false, }, { desc: "forceTransfer is not by the admin", forceTransferMsg: *types.NewMsgForceTransfer( suite.TestAccs[1].String(), sdk.NewInt64Coin(suite.defaultDenom, 10), suite.TestAccs[1].String(), suite.TestAccs[2].String(), ), expectPass: false, }, { desc: "forceTransfer is greater than the balance of", forceTransferMsg: *types.NewMsgForceTransfer( suite.TestAccs[0].String(), sdk.NewInt64Coin(suite.defaultDenom, 10000), suite.TestAccs[1].String(), suite.TestAccs[2].String(), ), expectPass: false, }, } { suite.Run(fmt.Sprintf("Case %s", tc.desc), func() { tc := tc _, err := suite.msgServer.ForceTransfer(sdk.WrapSDKContext(suite.Ctx), &tc.forceTransferMsg) if tc.expectPass { suite.Require().NoError(err) balances[tc.forceTransferMsg.TransferFromAddress] -= tc.forceTransferMsg.Amount.Amount.Int64() balances[tc.forceTransferMsg.TransferToAddress] += tc.forceTransferMsg.Amount.Amount.Int64() } else { suite.Require().Error(err) } fromAddr, err := sdk.AccAddressFromBech32(tc.forceTransferMsg.TransferFromAddress) suite.Require().NoError(err) fromBal := suite.App.AppKeepers.BankKeeper.GetBalance(suite.Ctx, fromAddr, suite.defaultDenom).Amount suite.Require().True(fromBal.Int64() == balances[tc.forceTransferMsg.TransferFromAddress]) toAddr, err := sdk.AccAddressFromBech32(tc.forceTransferMsg.TransferToAddress) suite.Require().NoError(err) toBal := suite.App.AppKeepers.BankKeeper.GetBalance(suite.Ctx, toAddr, suite.defaultDenom).Amount suite.Require().True(toBal.Int64() == balances[tc.forceTransferMsg.TransferToAddress]) }) } } func (suite *KeeperTestSuite) TestChangeAdminDenom() { for _, tc := range []struct { desc string msgChangeAdmin func(denom string) *types.MsgChangeAdmin expectedChangeAdminPass bool expectedAdminIndex int msgMint func(denom string) *types.MsgMint expectedMintPass bool }{ { desc: "creator admin can't mint after setting to '' ", msgChangeAdmin: func(denom string) *types.MsgChangeAdmin { return types.NewMsgChangeAdmin(suite.TestAccs[0].String(), denom, "") }, expectedChangeAdminPass: true, expectedAdminIndex: -1, msgMint: func(denom string) *types.MsgMint { return types.NewMsgMint(suite.TestAccs[0].String(), sdk.NewInt64Coin(denom, 5)) }, expectedMintPass: false, }, { desc: "non-admins can't change the existing admin", msgChangeAdmin: func(denom string) *types.MsgChangeAdmin { return types.NewMsgChangeAdmin(suite.TestAccs[1].String(), denom, suite.TestAccs[2].String()) }, expectedChangeAdminPass: false, expectedAdminIndex: 0, }, { desc: "success change admin", msgChangeAdmin: func(denom string) *types.MsgChangeAdmin { return types.NewMsgChangeAdmin(suite.TestAccs[0].String(), denom, suite.TestAccs[1].String()) }, expectedAdminIndex: 1, expectedChangeAdminPass: true, msgMint: func(denom string) *types.MsgMint { return types.NewMsgMint(suite.TestAccs[1].String(), sdk.NewInt64Coin(denom, 5)) }, expectedMintPass: true, }, } { suite.Run(fmt.Sprintf("Case %s", tc.desc), func() { // setup test suite.SetupTest() // Create a denom and mint res, err := suite.msgServer.CreateDenom(sdk.WrapSDKContext(suite.Ctx), types.NewMsgCreateDenom(suite.TestAccs[0].String(), "bitcoin")) suite.Require().NoError(err) testDenom := res.GetNewTokenDenom() _, err = suite.msgServer.Mint(sdk.WrapSDKContext(suite.Ctx), types.NewMsgMint(suite.TestAccs[0].String(), sdk.NewInt64Coin(testDenom, 10))) suite.Require().NoError(err) _, err = suite.msgServer.ChangeAdmin(sdk.WrapSDKContext(suite.Ctx), tc.msgChangeAdmin(testDenom)) if tc.expectedChangeAdminPass { suite.Require().NoError(err) } else { suite.Require().Error(err) } queryRes, err := suite.queryClient.DenomAuthorityMetadata(suite.Ctx.Context(), &types.QueryDenomAuthorityMetadataRequest{ Denom: testDenom, }) suite.Require().NoError(err) // expectedAdminIndex with negative value is assumed as admin with value of "" const emptyStringAdminIndexFlag = -1 if tc.expectedAdminIndex == emptyStringAdminIndexFlag { suite.Require().Equal("", queryRes.AuthorityMetadata.Admin) } else { suite.Require().Equal(suite.TestAccs[tc.expectedAdminIndex].String(), queryRes.AuthorityMetadata.Admin) } // we test mint to test if admin authority is performed properly after admin change. if tc.msgMint != nil { _, err := suite.msgServer.Mint(sdk.WrapSDKContext(suite.Ctx), tc.msgMint(testDenom)) if tc.expectedMintPass { suite.Require().NoError(err) } else { suite.Require().Error(err) } } }) } } func (suite *KeeperTestSuite) TestSetDenomMetaData() { // setup test suite.SetupTest() suite.CreateDefaultDenom() for _, tc := range []struct { desc string msgSetDenomMetadata types.MsgSetDenomMetadata expectedPass bool }{ { desc: "successful set denom metadata", msgSetDenomMetadata: *types.NewMsgSetDenomMetadata(suite.TestAccs[0].String(), banktypes.Metadata{ Description: "yeehaw", DenomUnits: []*banktypes.DenomUnit{ { Denom: suite.defaultDenom, Exponent: 0, }, { Denom: "uosmo", Exponent: 6, }, }, Base: suite.defaultDenom, Display: "uosmo", Name: "OSMO", Symbol: "OSMO", }), expectedPass: true, }, { desc: "non existent factory denom name", msgSetDenomMetadata: *types.NewMsgSetDenomMetadata(suite.TestAccs[0].String(), banktypes.Metadata{ Description: "yeehaw", DenomUnits: []*banktypes.DenomUnit{ { Denom: fmt.Sprintf("factory/%s/litecoin", suite.TestAccs[0].String()), Exponent: 0, }, { Denom: "uosmo", Exponent: 6, }, }, Base: fmt.Sprintf("factory/%s/litecoin", suite.TestAccs[0].String()), Display: "uosmo", Name: "OSMO", Symbol: "OSMO", }), expectedPass: false, }, { desc: "non-factory denom", msgSetDenomMetadata: *types.NewMsgSetDenomMetadata(suite.TestAccs[0].String(), banktypes.Metadata{ Description: "yeehaw", DenomUnits: []*banktypes.DenomUnit{ { Denom: "uosmo", Exponent: 0, }, { Denom: "uosmoo", Exponent: 6, }, }, Base: "uosmo", Display: "uosmoo", Name: "OSMO", Symbol: "OSMO", }), expectedPass: false, }, { desc: "wrong admin", msgSetDenomMetadata: *types.NewMsgSetDenomMetadata(suite.TestAccs[1].String(), banktypes.Metadata{ Description: "yeehaw", DenomUnits: []*banktypes.DenomUnit{ { Denom: suite.defaultDenom, Exponent: 0, }, { Denom: "uosmo", Exponent: 6, }, }, Base: suite.defaultDenom, Display: "uosmo", Name: "OSMO", Symbol: "OSMO", }), expectedPass: false, }, { desc: "invalid metadata (missing display denom unit)", msgSetDenomMetadata: *types.NewMsgSetDenomMetadata(suite.TestAccs[0].String(), banktypes.Metadata{ Description: "yeehaw", DenomUnits: []*banktypes.DenomUnit{ { Denom: suite.defaultDenom, Exponent: 0, }, }, Base: suite.defaultDenom, Display: "uosmo", Name: "OSMO", Symbol: "OSMO", }), expectedPass: false, }, } { suite.Run(fmt.Sprintf("Case %s", tc.desc), func() { tc := tc bankKeeper := suite.App.AppKeepers.BankKeeper res, err := suite.msgServer.SetDenomMetadata(sdk.WrapSDKContext(suite.Ctx), &tc.msgSetDenomMetadata) if tc.expectedPass { suite.Require().NoError(err) suite.Require().NotNil(res) md, found := bankKeeper.GetDenomMetaData(suite.Ctx, suite.defaultDenom) suite.Require().True(found) suite.Require().Equal(tc.msgSetDenomMetadata.Metadata.Name, md.Name) } else { suite.Require().Error(err) } }) } } ================================================ FILE: x/tokenfactory/keeper/bankactions.go ================================================ package keeper import ( "fmt" "sort" "google.golang.org/grpc/codes" "google.golang.org/grpc/status" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/tokenfactory/types" ) func (k Keeper) mintTo(ctx sdk.Context, amount sdk.Coin, mintTo string) error { // verify that denom is an x/tokenfactory denom _, _, err := types.DeconstructDenom(amount.Denom) if err != nil { return err } err = k.bankKeeper.MintCoins(ctx, types.ModuleName, sdk.NewCoins(amount)) if err != nil { return err } addr, err := sdk.AccAddressFromBech32(mintTo) if err != nil { return err } if k.bankKeeper.BlockedAddr(addr) { return fmt.Errorf("failed to mint to blocked address: %s", addr) } return k.bankKeeper.SendCoinsFromModuleToAccount(ctx, types.ModuleName, addr, sdk.NewCoins(amount)) } func (k Keeper) burnFrom(ctx sdk.Context, amount sdk.Coin, burnFrom string) error { // verify that denom is an x/tokenfactory denom _, _, err := types.DeconstructDenom(amount.Denom) if err != nil { return err } addr, err := sdk.AccAddressFromBech32(burnFrom) if err != nil { return err } if k.bankKeeper.BlockedAddr(addr) { return fmt.Errorf("failed to burn from blocked address: %s", addr) } err = k.bankKeeper.SendCoinsFromAccountToModule(ctx, addr, types.ModuleName, sdk.NewCoins(amount)) if err != nil { return err } return k.bankKeeper.BurnCoins(ctx, types.ModuleName, sdk.NewCoins(amount)) } func (k Keeper) forceTransfer(ctx sdk.Context, amount sdk.Coin, fromAddr string, toAddr string) error { // verify that denom is an x/tokenfactory denom _, _, err := types.DeconstructDenom(amount.Denom) if err != nil { return err } fromAcc, err := sdk.AccAddressFromBech32(fromAddr) if err != nil { return err } sortedPermAddrs := make([]string, 0, len(k.permAddrs)) for moduleName := range k.permAddrs { sortedPermAddrs = append(sortedPermAddrs, moduleName) } sort.Strings(sortedPermAddrs) for _, moduleName := range sortedPermAddrs { account := k.accountKeeper.GetModuleAccount(ctx, moduleName) if account == nil { return status.Errorf(codes.NotFound, "account %s not found", moduleName) } if account.GetAddress().Equals(fromAcc) { return status.Errorf(codes.Internal, "send from module acc not available") } } fromSdkAddr, err := sdk.AccAddressFromBech32(fromAddr) if err != nil { return err } toSdkAddr, err := sdk.AccAddressFromBech32(toAddr) if err != nil { return err } if k.bankKeeper.BlockedAddr(toSdkAddr) { return fmt.Errorf("failed to force transfer to blocked address: %s", toSdkAddr) } return k.bankKeeper.SendCoins(ctx, fromSdkAddr, toSdkAddr, sdk.NewCoins(amount)) } ================================================ FILE: x/tokenfactory/keeper/createdenom.go ================================================ package keeper import ( sdk "github.com/cosmos/cosmos-sdk/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" "github.com/cybercongress/go-cyber/v7/x/tokenfactory/types" ) // ConvertToBaseToken converts a fee amount in a whitelisted fee token to the base fee token amount func (k Keeper) CreateDenom(ctx sdk.Context, creatorAddr string, subdenom string) (newTokenDenom string, err error) { denom, err := k.validateCreateDenom(ctx, creatorAddr, subdenom) if err != nil { return "", err } err = k.chargeForCreateDenom(ctx, creatorAddr, subdenom) if err != nil { return "", err } err = k.createDenomAfterValidation(ctx, creatorAddr, denom) return denom, err } // Runs CreateDenom logic after the charge and all denom validation has been handled. // Made into a second function for genesis initialization. func (k Keeper) createDenomAfterValidation(ctx sdk.Context, creatorAddr string, denom string) (err error) { denomMetaData := banktypes.Metadata{ DenomUnits: []*banktypes.DenomUnit{{ Denom: denom, Exponent: 0, }}, Base: denom, // The following is necessary for x/bank denom validation Display: denom, Name: denom, Symbol: denom, } k.bankKeeper.SetDenomMetaData(ctx, denomMetaData) authorityMetadata := types.DenomAuthorityMetadata{ Admin: creatorAddr, } err = k.setAuthorityMetadata(ctx, denom, authorityMetadata) if err != nil { return err } k.addDenomFromCreator(ctx, creatorAddr, denom) return nil } func (k Keeper) validateCreateDenom(ctx sdk.Context, creatorAddr string, subdenom string) (newTokenDenom string, err error) { // TODO: This was a nil key on Store issue. Removed as we are upgrading IBC versions now // Temporary check until IBC bug is sorted out // if k.bankKeeper.HasSupply(ctx, subdenom) { // return "", fmt.Errorf("temporary error until IBC bug is sorted out, " + // "can't create subdenoms that are the same as a native denom") // } denom, err := types.GetTokenDenom(creatorAddr, subdenom) if err != nil { return "", err } _, found := k.bankKeeper.GetDenomMetaData(ctx, denom) if found { return "", types.ErrDenomExists } return denom, nil } func (k Keeper) chargeForCreateDenom(ctx sdk.Context, creatorAddr string, _ string) (err error) { params := k.GetParams(ctx) accAddr, err := sdk.AccAddressFromBech32(creatorAddr) if err != nil { return err } // if DenomCreationFee is non-zero, transfer the tokens from the creator // account to community pool, excluding contracts if params.DenomCreationFee != nil && len(accAddr.Bytes()) != 32 { if err := k.communityPoolKeeper.FundCommunityPool(ctx, params.DenomCreationFee, accAddr); err != nil { return err } } // if DenomCreationGasConsume is non-zero, consume the gas // if creatorAddr is contract then consume gas if params.DenomCreationGasConsume != 0 { ctx.GasMeter().ConsumeGas(params.DenomCreationGasConsume, "consume denom creation gas") } return nil } ================================================ FILE: x/tokenfactory/keeper/createdenom_test.go ================================================ package keeper_test import ( "fmt" sdk "github.com/cosmos/cosmos-sdk/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" "github.com/cybercongress/go-cyber/v7/app/apptesting" "github.com/cybercongress/go-cyber/v7/x/tokenfactory/types" ) func (suite *KeeperTestSuite) TestMsgCreateDenom() { var ( tokenFactoryKeeper = suite.App.AppKeepers.TokenFactoryKeeper bankKeeper = suite.App.AppKeepers.BankKeeper denomCreationFee = tokenFactoryKeeper.GetParams(suite.Ctx).DenomCreationFee ) // Get balance of acc 0 before creating a denom preCreateBalance := bankKeeper.GetBalance(suite.Ctx, suite.TestAccs[0], denomCreationFee[0].Denom) // Creating a denom should work res, err := suite.msgServer.CreateDenom(sdk.WrapSDKContext(suite.Ctx), types.NewMsgCreateDenom(suite.TestAccs[0].String(), "bitcoin")) suite.Require().NoError(err) suite.Require().NotEmpty(res.GetNewTokenDenom()) // Make sure that the admin is set correctly queryRes, err := suite.queryClient.DenomAuthorityMetadata(suite.Ctx.Context(), &types.QueryDenomAuthorityMetadataRequest{ Denom: res.GetNewTokenDenom(), }) suite.Require().NoError(err) suite.Require().Equal(suite.TestAccs[0].String(), queryRes.AuthorityMetadata.Admin) // Make sure that the denom is valid from the perspective of x/bank bankQueryRes, err := suite.bankQueryClient.DenomMetadata(suite.Ctx.Context(), &banktypes.QueryDenomMetadataRequest{ Denom: res.GetNewTokenDenom(), }) suite.Require().NoError(err) suite.Require().NoError(bankQueryRes.Metadata.Validate()) // Make sure that creation fee was deducted postCreateBalance := bankKeeper.GetBalance(suite.Ctx, suite.TestAccs[0], tokenFactoryKeeper.GetParams(suite.Ctx).DenomCreationFee[0].Denom) suite.Require().True(preCreateBalance.Sub(postCreateBalance).IsEqual(denomCreationFee[0])) // Make sure that a second version of the same denom can't be recreated _, err = suite.msgServer.CreateDenom(sdk.WrapSDKContext(suite.Ctx), types.NewMsgCreateDenom(suite.TestAccs[0].String(), "bitcoin")) suite.Require().Error(err) // Creating a second denom should work res, err = suite.msgServer.CreateDenom(sdk.WrapSDKContext(suite.Ctx), types.NewMsgCreateDenom(suite.TestAccs[0].String(), "litecoin")) suite.Require().NoError(err) suite.Require().NotEmpty(res.GetNewTokenDenom()) // Try querying all the denoms created by suite.TestAccs[0] queryRes2, err := suite.queryClient.DenomsFromCreator(suite.Ctx.Context(), &types.QueryDenomsFromCreatorRequest{ Creator: suite.TestAccs[0].String(), }) suite.Require().NoError(err) suite.Require().Len(queryRes2.Denoms, 2) // Make sure that a second account can create a denom with the same subdenom res, err = suite.msgServer.CreateDenom(sdk.WrapSDKContext(suite.Ctx), types.NewMsgCreateDenom(suite.TestAccs[1].String(), "bitcoin")) suite.Require().NoError(err) suite.Require().NotEmpty(res.GetNewTokenDenom()) // Make sure that an address with a "/" in it can't create denoms _, err = suite.msgServer.CreateDenom(sdk.WrapSDKContext(suite.Ctx), types.NewMsgCreateDenom("osmosis.eth/creator", "bitcoin")) suite.Require().Error(err) } func (suite *KeeperTestSuite) TestCreateDenom() { var ( primaryDenom = types.DefaultParams().DenomCreationFee[0].Denom secondaryDenom = apptesting.SecondaryDenom defaultDenomCreationFee = types.Params{DenomCreationFee: sdk.NewCoins(sdk.NewCoin(primaryDenom, sdk.NewInt(50000000)))} twoDenomCreationFee = types.Params{DenomCreationFee: sdk.NewCoins(sdk.NewCoin(primaryDenom, sdk.NewInt(50000000)), sdk.NewCoin(secondaryDenom, sdk.NewInt(50000000)))} nilCreationFee = types.Params{DenomCreationFee: nil} largeCreationFee = types.Params{DenomCreationFee: sdk.NewCoins(sdk.NewCoin(primaryDenom, sdk.NewInt(5000000000)))} ) for _, tc := range []struct { desc string denomCreationFee types.Params setup func() subdenom string valid bool }{ { desc: "subdenom too long", denomCreationFee: defaultDenomCreationFee, subdenom: "assadsadsadasdasdsadsadsadsadsadsadsklkadaskkkdasdasedskhanhassyeunganassfnlksdflksafjlkasd", valid: false, }, { desc: "subdenom and creator pair already exists", denomCreationFee: defaultDenomCreationFee, setup: func() { _, err := suite.msgServer.CreateDenom(sdk.WrapSDKContext(suite.Ctx), types.NewMsgCreateDenom(suite.TestAccs[0].String(), "bitcoin")) suite.Require().NoError(err) }, subdenom: "bitcoin", valid: false, }, { desc: "success case: defaultDenomCreationFee", denomCreationFee: defaultDenomCreationFee, subdenom: "evmos", valid: true, }, { desc: "success case: twoDenomCreationFee", denomCreationFee: twoDenomCreationFee, subdenom: "catcoin", valid: true, }, { desc: "success case: nilCreationFee", denomCreationFee: nilCreationFee, subdenom: "czcoin", valid: true, }, { desc: "account doesn't have enough to pay for denom creation fee", denomCreationFee: largeCreationFee, subdenom: "tooexpensive", valid: false, }, { desc: "subdenom having invalid characters", denomCreationFee: defaultDenomCreationFee, subdenom: "bit/***///&&&/coin", valid: false, }, } { suite.SetupTest() suite.Run(fmt.Sprintf("Case %s", tc.desc), func() { if tc.setup != nil { tc.setup() } tokenFactoryKeeper := suite.App.AppKeepers.TokenFactoryKeeper bankKeeper := suite.App.AppKeepers.BankKeeper // Set denom creation fee in params if err := tokenFactoryKeeper.SetParams(suite.Ctx, tc.denomCreationFee); err != nil { suite.Require().NoError(err) } denomCreationFee := tokenFactoryKeeper.GetParams(suite.Ctx).DenomCreationFee suite.Require().Equal(tc.denomCreationFee.DenomCreationFee, denomCreationFee) // note balance, create a tokenfactory denom, then note balance again // preCreateBalance := bankKeeper.GetAllBalances(suite.Ctx, suite.TestAccs[0]) preCreateBalance := bankKeeper.GetBalance(suite.Ctx, suite.TestAccs[0], "stake") res, err := suite.msgServer.CreateDenom(sdk.WrapSDKContext(suite.Ctx), types.NewMsgCreateDenom(suite.TestAccs[0].String(), tc.subdenom)) // postCreateBalance := bankKeeper.GetAllBalances(suite.Ctx, suite.TestAccs[0]) postCreateBalance := bankKeeper.GetBalance(suite.Ctx, suite.TestAccs[0], "stake") if tc.valid { suite.Require().NoError(err) if denomCreationFee != nil { suite.Require().True(preCreateBalance.Sub(postCreateBalance).IsEqual(denomCreationFee[0])) } // Make sure that the admin is set correctly queryRes, err := suite.queryClient.DenomAuthorityMetadata(suite.Ctx.Context(), &types.QueryDenomAuthorityMetadataRequest{ Denom: res.GetNewTokenDenom(), }) suite.Require().NoError(err) suite.Require().Equal(suite.TestAccs[0].String(), queryRes.AuthorityMetadata.Admin) } else { suite.Require().Error(err) // Ensure we don't charge if we expect an error suite.Require().True(preCreateBalance.IsEqual(postCreateBalance)) } }) } } ================================================ FILE: x/tokenfactory/keeper/creators.go ================================================ package keeper import ( sdk "github.com/cosmos/cosmos-sdk/types" ) func (k Keeper) addDenomFromCreator(ctx sdk.Context, creator, denom string) { store := k.GetCreatorPrefixStore(ctx, creator) store.Set([]byte(denom), []byte(denom)) } func (k Keeper) GetDenomsFromCreator(ctx sdk.Context, creator string) []string { store := k.GetCreatorPrefixStore(ctx, creator) iterator := store.Iterator(nil, nil) defer iterator.Close() denoms := []string{} for ; iterator.Valid(); iterator.Next() { denoms = append(denoms, string(iterator.Key())) } return denoms } func (k Keeper) GetAllDenomsIterator(ctx sdk.Context) sdk.Iterator { return k.GetCreatorsPrefixStore(ctx).Iterator(nil, nil) } // TODO: Get all denoms a user is the admin of currently ================================================ FILE: x/tokenfactory/keeper/genesis.go ================================================ package keeper import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/tokenfactory/types" ) // InitGenesis initializes the tokenfactory module's state from a provided genesis // state. func (k Keeper) InitGenesis(ctx sdk.Context, genState types.GenesisState) { k.CreateModuleAccount(ctx) if genState.Params.DenomCreationFee == nil { genState.Params.DenomCreationFee = sdk.NewCoins() } if err := k.SetParams(ctx, genState.Params); err != nil { panic(err) } for _, genDenom := range genState.GetFactoryDenoms() { creator, _, err := types.DeconstructDenom(genDenom.GetDenom()) if err != nil { panic(err) } err = k.createDenomAfterValidation(ctx, creator, genDenom.GetDenom()) if err != nil { panic(err) } err = k.setAuthorityMetadata(ctx, genDenom.GetDenom(), genDenom.GetAuthorityMetadata()) if err != nil { panic(err) } } } // ExportGenesis returns the tokenfactory module's exported genesis. func (k Keeper) ExportGenesis(ctx sdk.Context) *types.GenesisState { genDenoms := []types.GenesisDenom{} iterator := k.GetAllDenomsIterator(ctx) defer iterator.Close() for ; iterator.Valid(); iterator.Next() { denom := string(iterator.Value()) authorityMetadata, err := k.GetAuthorityMetadata(ctx, denom) if err != nil { panic(err) } genDenoms = append(genDenoms, types.GenesisDenom{ Denom: denom, AuthorityMetadata: authorityMetadata, }) } return &types.GenesisState{ FactoryDenoms: genDenoms, Params: k.GetParams(ctx), } } ================================================ FILE: x/tokenfactory/keeper/genesis_test.go ================================================ package keeper_test import ( sdk "github.com/cosmos/cosmos-sdk/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" "github.com/cybercongress/go-cyber/v7/x/tokenfactory/types" ) func (suite *KeeperTestSuite) TestGenesis() { genesisState := types.GenesisState{ FactoryDenoms: []types.GenesisDenom{ { Denom: "factory/juno1t7egva48prqmzl59x5ngv4zx0dtrwewcmjwfym/bitcoin", AuthorityMetadata: types.DenomAuthorityMetadata{ Admin: "juno1t7egva48prqmzl59x5ngv4zx0dtrwewcmjwfym", }, }, { Denom: "factory/juno1t7egva48prqmzl59x5ngv4zx0dtrwewcmjwfym/diff-admin", AuthorityMetadata: types.DenomAuthorityMetadata{ Admin: "juno15czt5nhlnvayqq37xun9s9yus0d6y26dsvkcna", }, }, { Denom: "factory/juno1t7egva48prqmzl59x5ngv4zx0dtrwewcmjwfym/litecoin", AuthorityMetadata: types.DenomAuthorityMetadata{ Admin: "juno1t7egva48prqmzl59x5ngv4zx0dtrwewcmjwfym", }, }, }, } suite.SetupTestForInitGenesis() app := suite.App // Test both with bank denom metadata set, and not set. for i, denom := range genesisState.FactoryDenoms { // hacky, sets bank metadata to exist if i != 0, to cover both cases. if i != 0 { app.AppKeepers.BankKeeper.SetDenomMetaData(suite.Ctx, banktypes.Metadata{Base: denom.GetDenom()}) } } if err := app.AppKeepers.TokenFactoryKeeper.SetParams(suite.Ctx, types.Params{DenomCreationFee: sdk.Coins{sdk.NewInt64Coin("stake", 100)}}); err != nil { panic(err) } app.AppKeepers.TokenFactoryKeeper.InitGenesis(suite.Ctx, genesisState) // check that the module account is now initialized tokenfactoryModuleAccount := app.AppKeepers.AccountKeeper.GetAccount(suite.Ctx, app.AppKeepers.AccountKeeper.GetModuleAddress(types.ModuleName)) suite.Require().NotNil(tokenfactoryModuleAccount) exportedGenesis := app.AppKeepers.TokenFactoryKeeper.ExportGenesis(suite.Ctx) suite.Require().NotNil(exportedGenesis) suite.Require().Equal(genesisState, *exportedGenesis) } ================================================ FILE: x/tokenfactory/keeper/grpc_query.go ================================================ package keeper import ( "context" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/tokenfactory/types" ) var _ types.QueryServer = Keeper{} func (k Keeper) Params(ctx context.Context, _ *types.QueryParamsRequest) (*types.QueryParamsResponse, error) { sdkCtx := sdk.UnwrapSDKContext(ctx) params := k.GetParams(sdkCtx) return &types.QueryParamsResponse{Params: params}, nil } func (k Keeper) DenomAuthorityMetadata(ctx context.Context, req *types.QueryDenomAuthorityMetadataRequest) (*types.QueryDenomAuthorityMetadataResponse, error) { sdkCtx := sdk.UnwrapSDKContext(ctx) authorityMetadata, err := k.GetAuthorityMetadata(sdkCtx, req.GetDenom()) if err != nil { return nil, err } return &types.QueryDenomAuthorityMetadataResponse{AuthorityMetadata: authorityMetadata}, nil } func (k Keeper) DenomsFromCreator(ctx context.Context, req *types.QueryDenomsFromCreatorRequest) (*types.QueryDenomsFromCreatorResponse, error) { sdkCtx := sdk.UnwrapSDKContext(ctx) denoms := k.GetDenomsFromCreator(sdkCtx, req.GetCreator()) return &types.QueryDenomsFromCreatorResponse{Denoms: denoms}, nil } ================================================ FILE: x/tokenfactory/keeper/keeper.go ================================================ package keeper import ( "fmt" "github.com/cometbft/cometbft/libs/log" "github.com/cosmos/cosmos-sdk/codec" "github.com/cosmos/cosmos-sdk/store/prefix" storetypes "github.com/cosmos/cosmos-sdk/store/types" sdk "github.com/cosmos/cosmos-sdk/types" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" "github.com/cybercongress/go-cyber/v7/x/tokenfactory/types" ) type ( Keeper struct { cdc codec.BinaryCodec storeKey storetypes.StoreKey permAddrs map[string]authtypes.PermissionsForAddress accountKeeper types.AccountKeeper bankKeeper types.BankKeeper communityPoolKeeper types.CommunityPoolKeeper enabledCapabilities []string // the address capable of executing a MsgUpdateParams message. Typically, this // should be the x/gov module account. authority string } ) // NewKeeper returns a new instance of the x/tokenfactory keeper func NewKeeper( cdc codec.BinaryCodec, storeKey storetypes.StoreKey, maccPerms map[string][]string, accountKeeper types.AccountKeeper, bankKeeper types.BankKeeper, communityPoolKeeper types.CommunityPoolKeeper, enabledCapabilities []string, authority string, ) Keeper { permAddrs := make(map[string]authtypes.PermissionsForAddress) for name, perms := range maccPerms { permAddrs[name] = authtypes.NewPermissionsForAddress(name, perms) } return Keeper{ cdc: cdc, storeKey: storeKey, permAddrs: permAddrs, accountKeeper: accountKeeper, bankKeeper: bankKeeper, communityPoolKeeper: communityPoolKeeper, enabledCapabilities: enabledCapabilities, authority: authority, } } // GetAuthority returns the x/mint module's authority. func (k Keeper) GetAuthority() string { return k.authority } // Logger returns a logger for the x/tokenfactory module func (k Keeper) Logger(ctx sdk.Context) log.Logger { return ctx.Logger().With("module", fmt.Sprintf("x/%s", types.ModuleName)) } // GetDenomPrefixStore returns the substore for a specific denom func (k Keeper) GetDenomPrefixStore(ctx sdk.Context, denom string) sdk.KVStore { store := ctx.KVStore(k.storeKey) return prefix.NewStore(store, types.GetDenomPrefixStore(denom)) } // GetCreatorPrefixStore returns the substore for a specific creator address func (k Keeper) GetCreatorPrefixStore(ctx sdk.Context, creator string) sdk.KVStore { store := ctx.KVStore(k.storeKey) return prefix.NewStore(store, types.GetCreatorPrefix(creator)) } // GetCreatorsPrefixStore returns the substore that contains a list of creators func (k Keeper) GetCreatorsPrefixStore(ctx sdk.Context) sdk.KVStore { store := ctx.KVStore(k.storeKey) return prefix.NewStore(store, types.GetCreatorsPrefix()) } // CreateModuleAccount creates a module account with minting and burning capabilities // This account isn't intended to store any coins, // it purely mints and burns them on behalf of the admin of respective denoms, // and sends to the relevant address. func (k Keeper) CreateModuleAccount(ctx sdk.Context) { // NOTE this was wrong original code witch set tokenfactory account number to 0 //moduleAcc := authtypes.NewEmptyModuleAccount(types.ModuleName, authtypes.Minter, authtypes.Burner) //k.accountKeeper.SetModuleAccount(ctx, moduleAcc) k.accountKeeper.GetModuleAccount(ctx, types.ModuleName) } ================================================ FILE: x/tokenfactory/keeper/keeper_test.go ================================================ package keeper_test import ( tmproto "github.com/cometbft/cometbft/proto/tendermint/types" sdk "github.com/cosmos/cosmos-sdk/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" "github.com/cybercongress/go-cyber/v7/app/apptesting" "github.com/cybercongress/go-cyber/v7/x/tokenfactory/types" "github.com/stretchr/testify/suite" ) type KeeperTestSuite struct { apptesting.KeeperTestHelper queryClient types.QueryClient bankQueryClient banktypes.QueryClient msgServer types.MsgServer // defaultDenom is on the suite, as it depends on the creator test address. defaultDenom string } func TestKeeperTestSuite(t *testing.T) { suite.Run(t, new(KeeperTestSuite)) } func (suite *KeeperTestSuite) SetupTest() { suite.Setup() // Fund every TestAcc with two denoms, one of which is the denom creation fee fundAccsAmount := sdk.NewCoins(sdk.NewCoin(types.DefaultParams().DenomCreationFee[0].Denom, types.DefaultParams().DenomCreationFee[0].Amount.MulRaw(100)), sdk.NewCoin(apptesting.SecondaryDenom, apptesting.SecondaryAmount)) for _, acc := range suite.TestAccs { suite.FundAcc(acc, fundAccsAmount) } suite.queryClient = types.NewQueryClient(suite.QueryHelper) suite.bankQueryClient = banktypes.NewQueryClient(suite.QueryHelper) suite.msgServer = keeper.NewMsgServerImpl(suite.App.AppKeepers.TokenFactoryKeeper) } func (suite *KeeperTestSuite) CreateDefaultDenom() { res, _ := suite.msgServer.CreateDenom(sdk.WrapSDKContext(suite.Ctx), types.NewMsgCreateDenom(suite.TestAccs[0].String(), "bitcoin")) suite.defaultDenom = res.GetNewTokenDenom() } func (suite *KeeperTestSuite) TestCreateModuleAccount() { app := suite.App // remove module account tokenfactoryModuleAccount := app.AppKeepers.AccountKeeper.GetAccount(suite.Ctx, app.AppKeepers.AccountKeeper.GetModuleAddress(types.ModuleName)) app.AppKeepers.AccountKeeper.RemoveAccount(suite.Ctx, tokenfactoryModuleAccount) // ensure module account was removed suite.Ctx = app.BaseApp.NewContext(false, tmproto.Header{ChainID: "testing"}) tokenfactoryModuleAccount = app.AppKeepers.AccountKeeper.GetAccount(suite.Ctx, app.AppKeepers.AccountKeeper.GetModuleAddress(types.ModuleName)) suite.Require().Nil(tokenfactoryModuleAccount) // create module account app.AppKeepers.TokenFactoryKeeper.CreateModuleAccount(suite.Ctx) // check that the module account is now initialized tokenfactoryModuleAccount = app.AppKeepers.AccountKeeper.GetAccount(suite.Ctx, app.AppKeepers.AccountKeeper.GetModuleAddress(types.ModuleName)) suite.Require().NotNil(tokenfactoryModuleAccount) } ================================================ FILE: x/tokenfactory/keeper/migrator.go ================================================ package keeper import ( "fmt" sdk "github.com/cosmos/cosmos-sdk/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" "github.com/cybercongress/go-cyber/v7/x/tokenfactory/exported" v2 "github.com/cybercongress/go-cyber/v7/x/tokenfactory/migrations/v2" ) // Migrator is a struct for handling in-place state migrations. type Migrator struct { keeper Keeper legacySubspace exported.Subspace } func NewMigrator(k Keeper, ss exported.Subspace) Migrator { return Migrator{ keeper: k, legacySubspace: ss, } } // Migrate1to2 migrates the x/tokenfactory module state from the consensus version 1 to // version 2. Specifically, it takes the parameters that are currently stored // and managed by the x/params modules and stores them directly into the x/tokenfactory // module state. func (m Migrator) Migrate1to2(ctx sdk.Context) error { // Fixes hard forking genesis being invalid. // https://github.com/sei-protocol/sei-chain/pull/861 iter := m.keeper.GetAllDenomsIterator(ctx) defer iter.Close() for ; iter.Valid(); iter.Next() { denom := string(iter.Value()) denomMetadata, err := m.keeper.bankKeeper.GetDenomMetaData(ctx, denom) if err { panic(fmt.Errorf("denom %s does not exist", denom)) } fmt.Printf("Migrating denom: %s\n", denom) m.SetMetadata(&denomMetadata) m.keeper.bankKeeper.SetDenomMetaData(ctx, denomMetadata) } return v2.Migrate(ctx, ctx.KVStore(m.keeper.storeKey), m.legacySubspace, m.keeper.cdc) } func (m Migrator) SetMetadata(denomMetadata *banktypes.Metadata) { if len(denomMetadata.Base) == 0 { panic(fmt.Errorf("no base exists for denom %v", denomMetadata)) } if len(denomMetadata.Display) == 0 { denomMetadata.Display = denomMetadata.Base denomMetadata.Name = denomMetadata.Base denomMetadata.Symbol = denomMetadata.Base } else { fmt.Printf("Denom %s already has denom set", denomMetadata.Base) } } ================================================ FILE: x/tokenfactory/keeper/msg_server.go ================================================ package keeper import ( "context" "cosmossdk.io/errors" sdk "github.com/cosmos/cosmos-sdk/types" govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" "github.com/cybercongress/go-cyber/v7/x/tokenfactory/types" ) type msgServer struct { Keeper } // NewMsgServerImpl returns an implementation of the MsgServer interface // for the provided Keeper. func NewMsgServerImpl(keeper Keeper) types.MsgServer { return &msgServer{Keeper: keeper} } var _ types.MsgServer = msgServer{} func (server msgServer) CreateDenom(goCtx context.Context, msg *types.MsgCreateDenom) (*types.MsgCreateDenomResponse, error) { if err := msg.ValidateBasic(); err != nil { return nil, err } ctx := sdk.UnwrapSDKContext(goCtx) denom, err := server.Keeper.CreateDenom(ctx, msg.Sender, msg.Subdenom) if err != nil { return nil, err } ctx.EventManager().EmitEvents(sdk.Events{ sdk.NewEvent( types.TypeMsgCreateDenom, sdk.NewAttribute(types.AttributeCreator, msg.Sender), sdk.NewAttribute(types.AttributeNewTokenDenom, denom), ), }) return &types.MsgCreateDenomResponse{ NewTokenDenom: denom, }, nil } func (server msgServer) Mint(goCtx context.Context, msg *types.MsgMint) (*types.MsgMintResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) // pay some extra gas cost to give a better error here. _, denomExists := server.bankKeeper.GetDenomMetaData(ctx, msg.Amount.Denom) if !denomExists { return nil, types.ErrDenomDoesNotExist.Wrapf("denom: %s", msg.Amount.Denom) } authorityMetadata, err := server.Keeper.GetAuthorityMetadata(ctx, msg.Amount.GetDenom()) if err != nil { return nil, err } if msg.Sender != authorityMetadata.GetAdmin() { return nil, types.ErrUnauthorized } if msg.MintToAddress == "" { msg.MintToAddress = msg.Sender } err = server.Keeper.mintTo(ctx, msg.Amount, msg.MintToAddress) if err != nil { return nil, err } ctx.EventManager().EmitEvents(sdk.Events{ sdk.NewEvent( types.TypeMsgMint, sdk.NewAttribute(types.AttributeMintToAddress, msg.Sender), sdk.NewAttribute(types.AttributeAmount, msg.Amount.String()), ), }) return &types.MsgMintResponse{}, nil } func (server msgServer) Burn(goCtx context.Context, msg *types.MsgBurn) (*types.MsgBurnResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) authorityMetadata, err := server.Keeper.GetAuthorityMetadata(ctx, msg.Amount.GetDenom()) if err != nil { return nil, err } if msg.Sender != authorityMetadata.GetAdmin() { return nil, types.ErrUnauthorized } if msg.BurnFromAddress == "" { msg.BurnFromAddress = msg.Sender } else if !types.IsCapabilityEnabled(server.Keeper.enabledCapabilities, types.EnableBurnFrom) { return nil, types.ErrCapabilityNotEnabled } err = server.Keeper.burnFrom(ctx, msg.Amount, msg.BurnFromAddress) if err != nil { return nil, err } ctx.EventManager().EmitEvents(sdk.Events{ sdk.NewEvent( types.TypeMsgBurn, sdk.NewAttribute(types.AttributeBurnFromAddress, msg.Sender), sdk.NewAttribute(types.AttributeAmount, msg.Amount.String()), ), }) return &types.MsgBurnResponse{}, nil } func (server msgServer) ForceTransfer(goCtx context.Context, msg *types.MsgForceTransfer) (*types.MsgForceTransferResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) if !types.IsCapabilityEnabled(server.Keeper.enabledCapabilities, types.EnableForceTransfer) { return nil, types.ErrCapabilityNotEnabled } authorityMetadata, err := server.Keeper.GetAuthorityMetadata(ctx, msg.Amount.GetDenom()) if err != nil { return nil, err } if msg.Sender != authorityMetadata.GetAdmin() { return nil, types.ErrUnauthorized } err = server.Keeper.forceTransfer(ctx, msg.Amount, msg.TransferFromAddress, msg.TransferToAddress) if err != nil { return nil, err } ctx.EventManager().EmitEvents(sdk.Events{ sdk.NewEvent( types.TypeMsgForceTransfer, sdk.NewAttribute(types.AttributeTransferFromAddress, msg.TransferFromAddress), sdk.NewAttribute(types.AttributeTransferToAddress, msg.TransferToAddress), sdk.NewAttribute(types.AttributeAmount, msg.Amount.String()), ), }) return &types.MsgForceTransferResponse{}, nil } func (server msgServer) ChangeAdmin(goCtx context.Context, msg *types.MsgChangeAdmin) (*types.MsgChangeAdminResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) authorityMetadata, err := server.Keeper.GetAuthorityMetadata(ctx, msg.Denom) if err != nil { return nil, err } if msg.Sender != authorityMetadata.GetAdmin() { return nil, types.ErrUnauthorized } err = server.Keeper.setAdmin(ctx, msg.Denom, msg.NewAdmin) if err != nil { return nil, err } ctx.EventManager().EmitEvents(sdk.Events{ sdk.NewEvent( types.TypeMsgChangeAdmin, sdk.NewAttribute(types.AttributeDenom, msg.GetDenom()), sdk.NewAttribute(types.AttributeNewAdmin, msg.NewAdmin), ), }) return &types.MsgChangeAdminResponse{}, nil } func (server msgServer) SetDenomMetadata(goCtx context.Context, msg *types.MsgSetDenomMetadata) (*types.MsgSetDenomMetadataResponse, error) { ctx := sdk.UnwrapSDKContext(goCtx) if !types.IsCapabilityEnabled(server.Keeper.enabledCapabilities, types.EnableSetMetadata) { return nil, types.ErrCapabilityNotEnabled } // Defense in depth validation of metadata err := msg.Metadata.Validate() if err != nil { return nil, err } authorityMetadata, err := server.Keeper.GetAuthorityMetadata(ctx, msg.Metadata.Base) if err != nil { return nil, err } if msg.Sender != authorityMetadata.GetAdmin() { return nil, types.ErrUnauthorized } server.Keeper.bankKeeper.SetDenomMetaData(ctx, msg.Metadata) ctx.EventManager().EmitEvents(sdk.Events{ sdk.NewEvent( types.TypeMsgSetDenomMetadata, sdk.NewAttribute(types.AttributeDenom, msg.Metadata.Base), sdk.NewAttribute(types.AttributeDenomMetadata, msg.Metadata.String()), ), }) return &types.MsgSetDenomMetadataResponse{}, nil } func (server msgServer) UpdateParams(goCtx context.Context, req *types.MsgUpdateParams) (*types.MsgUpdateParamsResponse, error) { if server.authority != req.Authority { return nil, errors.Wrapf(govtypes.ErrInvalidSigner, "invalid authority; expected %s, got %s", server.authority, req.Authority) } ctx := sdk.UnwrapSDKContext(goCtx) if err := server.SetParams(ctx, req.Params); err != nil { return nil, err } return &types.MsgUpdateParamsResponse{}, nil } ================================================ FILE: x/tokenfactory/keeper/msg_server_test.go ================================================ package keeper_test import ( "fmt" sdk "github.com/cosmos/cosmos-sdk/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" "github.com/cybercongress/go-cyber/v7/x/tokenfactory/types" ) // TestMintDenomMsg tests TypeMsgMint message is emitted on a successful mint func (suite *KeeperTestSuite) TestMintDenomMsg() { // Create a denom suite.CreateDefaultDenom() for _, tc := range []struct { desc string amount int64 mintDenom string admin string valid bool expectedMessageEvents int }{ { desc: "denom does not exist", amount: 10, mintDenom: "factory/osmo1t7egva48prqmzl59x5ngv4zx0dtrwewc9m7z44/evmos", admin: suite.TestAccs[0].String(), valid: false, }, { desc: "success case", amount: 10, mintDenom: suite.defaultDenom, admin: suite.TestAccs[0].String(), valid: true, expectedMessageEvents: 1, }, } { suite.Run(fmt.Sprintf("Case %s", tc.desc), func() { ctx := suite.Ctx.WithEventManager(sdk.NewEventManager()) suite.Require().Equal(0, len(ctx.EventManager().Events())) // Test mint message suite.msgServer.Mint(sdk.WrapSDKContext(ctx), types.NewMsgMint(tc.admin, sdk.NewInt64Coin(tc.mintDenom, 10))) //nolint:errcheck // Ensure current number and type of event is emitted suite.AssertEventEmitted(ctx, types.TypeMsgMint, tc.expectedMessageEvents) }) } } // TestBurnDenomMsg tests TypeMsgBurn message is emitted on a successful burn func (suite *KeeperTestSuite) TestBurnDenomMsg() { // Create a denom. suite.CreateDefaultDenom() // mint 10 default token for testAcc[0] suite.msgServer.Mint(sdk.WrapSDKContext(suite.Ctx), types.NewMsgMint(suite.TestAccs[0].String(), sdk.NewInt64Coin(suite.defaultDenom, 10))) //nolint:errcheck for _, tc := range []struct { desc string amount int64 burnDenom string admin string valid bool expectedMessageEvents int }{ { desc: "denom does not exist", burnDenom: "factory/osmo1t7egva48prqmzl59x5ngv4zx0dtrwewc9m7z44/evmos", admin: suite.TestAccs[0].String(), valid: false, }, { desc: "success case", burnDenom: suite.defaultDenom, admin: suite.TestAccs[0].String(), valid: true, expectedMessageEvents: 1, }, } { suite.Run(fmt.Sprintf("Case %s", tc.desc), func() { ctx := suite.Ctx.WithEventManager(sdk.NewEventManager()) suite.Require().Equal(0, len(ctx.EventManager().Events())) // Test burn message suite.msgServer.Burn(sdk.WrapSDKContext(ctx), types.NewMsgBurn(tc.admin, sdk.NewInt64Coin(tc.burnDenom, 10))) //nolint:errcheck // Ensure current number and type of event is emitted suite.AssertEventEmitted(ctx, types.TypeMsgBurn, tc.expectedMessageEvents) }) } } // TestCreateDenomMsg tests TypeMsgCreateDenom message is emitted on a successful denom creation func (suite *KeeperTestSuite) TestCreateDenomMsg() { defaultDenomCreationFee := types.Params{DenomCreationFee: sdk.NewCoins(sdk.NewCoin("stake", sdk.NewInt(50000000)))} for _, tc := range []struct { desc string denomCreationFee types.Params subdenom string valid bool expectedMessageEvents int }{ { desc: "subdenom too long", denomCreationFee: defaultDenomCreationFee, subdenom: "assadsadsadasdasdsadsadsadsadsadsadsklkadaskkkdasdasedskhanhassyeunganassfnlksdflksafjlkasd", valid: false, }, { desc: "success case: defaultDenomCreationFee", denomCreationFee: defaultDenomCreationFee, subdenom: "evmos", valid: true, expectedMessageEvents: 1, }, } { suite.SetupTest() suite.Run(fmt.Sprintf("Case %s", tc.desc), func() { tokenFactoryKeeper := suite.App.AppKeepers.TokenFactoryKeeper ctx := suite.Ctx.WithEventManager(sdk.NewEventManager()) suite.Require().Equal(0, len(ctx.EventManager().Events())) // Set denom creation fee in params if err := tokenFactoryKeeper.SetParams(suite.Ctx, tc.denomCreationFee); err != nil { suite.Require().NoError(err) } // Test create denom message suite.msgServer.CreateDenom(sdk.WrapSDKContext(ctx), types.NewMsgCreateDenom(suite.TestAccs[0].String(), tc.subdenom)) //nolint:errcheck // Ensure current number and type of event is emitted suite.AssertEventEmitted(ctx, types.TypeMsgCreateDenom, tc.expectedMessageEvents) }) } } // TestChangeAdminDenomMsg tests TypeMsgChangeAdmin message is emitted on a successful admin change func (suite *KeeperTestSuite) TestChangeAdminDenomMsg() { for _, tc := range []struct { desc string msgChangeAdmin func(denom string) *types.MsgChangeAdmin expectedChangeAdminPass bool expectedAdminIndex int msgMint func(denom string) *types.MsgMint expectedMintPass bool expectedMessageEvents int }{ { desc: "non-admins can't change the existing admin", msgChangeAdmin: func(denom string) *types.MsgChangeAdmin { return types.NewMsgChangeAdmin(suite.TestAccs[1].String(), denom, suite.TestAccs[2].String()) }, expectedChangeAdminPass: false, expectedAdminIndex: 0, }, { desc: "success change admin", msgChangeAdmin: func(denom string) *types.MsgChangeAdmin { return types.NewMsgChangeAdmin(suite.TestAccs[0].String(), denom, suite.TestAccs[1].String()) }, expectedAdminIndex: 1, expectedChangeAdminPass: true, expectedMessageEvents: 1, msgMint: func(denom string) *types.MsgMint { return types.NewMsgMint(suite.TestAccs[1].String(), sdk.NewInt64Coin(denom, 5)) }, expectedMintPass: true, }, } { suite.Run(fmt.Sprintf("Case %s", tc.desc), func() { // setup test suite.SetupTest() ctx := suite.Ctx.WithEventManager(sdk.NewEventManager()) suite.Require().Equal(0, len(ctx.EventManager().Events())) // Create a denom and mint res, err := suite.msgServer.CreateDenom(sdk.WrapSDKContext(ctx), types.NewMsgCreateDenom(suite.TestAccs[0].String(), "bitcoin")) suite.Require().NoError(err) testDenom := res.GetNewTokenDenom() suite.msgServer.Mint(sdk.WrapSDKContext(ctx), types.NewMsgMint(suite.TestAccs[0].String(), sdk.NewInt64Coin(testDenom, 10))) //nolint:errcheck // Test change admin message suite.msgServer.ChangeAdmin(sdk.WrapSDKContext(ctx), tc.msgChangeAdmin(testDenom)) //nolint:errcheck // Ensure current number and type of event is emitted suite.AssertEventEmitted(ctx, types.TypeMsgChangeAdmin, tc.expectedMessageEvents) }) } } // TestSetDenomMetaDataMsg tests TypeMsgSetDenomMetadata message is emitted on a successful denom metadata change func (suite *KeeperTestSuite) TestSetDenomMetaDataMsg() { // setup test suite.SetupTest() suite.CreateDefaultDenom() for _, tc := range []struct { desc string msgSetDenomMetadata types.MsgSetDenomMetadata expectedPass bool expectedMessageEvents int }{ { desc: "successful set denom metadata", msgSetDenomMetadata: *types.NewMsgSetDenomMetadata(suite.TestAccs[0].String(), banktypes.Metadata{ Description: "yeehaw", DenomUnits: []*banktypes.DenomUnit{ { Denom: suite.defaultDenom, Exponent: 0, }, { Denom: "uosmo", Exponent: 6, }, }, Base: suite.defaultDenom, Display: "uosmo", Name: "OSMO", Symbol: "OSMO", }), expectedPass: true, expectedMessageEvents: 1, }, { desc: "non existent factory denom name", msgSetDenomMetadata: *types.NewMsgSetDenomMetadata(suite.TestAccs[0].String(), banktypes.Metadata{ Description: "yeehaw", DenomUnits: []*banktypes.DenomUnit{ { Denom: fmt.Sprintf("factory/%s/litecoin", suite.TestAccs[0].String()), Exponent: 0, }, { Denom: "uosmo", Exponent: 6, }, }, Base: fmt.Sprintf("factory/%s/litecoin", suite.TestAccs[0].String()), Display: "uosmo", Name: "OSMO", Symbol: "OSMO", }), expectedPass: false, }, } { suite.Run(fmt.Sprintf("Case %s", tc.desc), func() { tc := tc ctx := suite.Ctx.WithEventManager(sdk.NewEventManager()) suite.Require().Equal(0, len(ctx.EventManager().Events())) // Test set denom metadata message suite.msgServer.SetDenomMetadata(sdk.WrapSDKContext(ctx), &tc.msgSetDenomMetadata) //nolint:errcheck // Ensure current number and type of event is emitted suite.AssertEventEmitted(ctx, types.TypeMsgSetDenomMetadata, tc.expectedMessageEvents) }) } } ================================================ FILE: x/tokenfactory/keeper/params.go ================================================ package keeper import ( sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/tokenfactory/types" ) // GetParams returns the total set params. func (k Keeper) GetParams(ctx sdk.Context) (p types.Params) { store := ctx.KVStore(k.storeKey) bz := store.Get(types.ParamsKey) if bz == nil { return p } k.cdc.MustUnmarshal(bz, &p) return p } // SetParams sets the total set of params. func (k Keeper) SetParams(ctx sdk.Context, p types.Params) error { if err := p.Validate(); err != nil { return err } store := ctx.KVStore(k.storeKey) bz := k.cdc.MustMarshal(&p) store.Set(types.ParamsKey, bz) return nil } ================================================ FILE: x/tokenfactory/migrations/v2/migrate.go ================================================ package v2 import ( "github.com/cosmos/cosmos-sdk/codec" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/tokenfactory/exported" "github.com/cybercongress/go-cyber/v7/x/tokenfactory/types" ) const ModuleName = "tokenfactory" var ParamsKey = []byte{0x00} // Migrate migrates the x/tokenfactory module state from the consensus version 1 to // version 2. Specifically, it takes the parameters that are currently stored // and managed by the x/params modules and stores them directly into the x/tokenfactory // module state. func Migrate( _ sdk.Context, store sdk.KVStore, _ exported.Subspace, cdc codec.BinaryCodec, ) error { // Migrates mainnet params -> the new keeper params storeKey (from x/params) currParams := types.Params{ DenomCreationFee: nil, DenomCreationGasConsume: 2_000_000, } if err := currParams.Validate(); err != nil { return err } bz := cdc.MustMarshal(&currParams) store.Set(ParamsKey, bz) return nil } ================================================ FILE: x/tokenfactory/migrations/v2/migrate_test.go ================================================ package v2_test import ( "testing" "github.com/stretchr/testify/require" "github.com/cosmos/cosmos-sdk/testutil" sdk "github.com/cosmos/cosmos-sdk/types" moduletestutil "github.com/cosmos/cosmos-sdk/types/module/testutil" "github.com/cybercongress/go-cyber/v7/x/tokenfactory" "github.com/cybercongress/go-cyber/v7/x/tokenfactory/exported" v2 "github.com/cybercongress/go-cyber/v7/x/tokenfactory/migrations/v2" "github.com/cybercongress/go-cyber/v7/x/tokenfactory/types" ) type mockSubspace struct { ps types.Params } func newMockSubspace(ps types.Params) mockSubspace { return mockSubspace{ps: ps} } func (ms mockSubspace) GetParamSet(_ sdk.Context, ps exported.ParamSet) { *ps.(*types.Params) = ms.ps } func TestMigrate(t *testing.T) { // x/param conversion encCfg := moduletestutil.MakeTestEncodingConfig(tokenfactory.AppModuleBasic{}) cdc := encCfg.Codec storeKey := sdk.NewKVStoreKey(v2.ModuleName) tKey := sdk.NewTransientStoreKey("transient_test") ctx := testutil.DefaultContext(storeKey, tKey) store := ctx.KVStore(storeKey) legacySubspace := newMockSubspace(types.Params{ DenomCreationFee: nil, DenomCreationGasConsume: 2_000_000, }) require.NoError(t, v2.Migrate(ctx, store, legacySubspace, cdc)) var res types.Params bz := store.Get(v2.ParamsKey) require.NoError(t, cdc.Unmarshal(bz, &res)) require.Equal(t, legacySubspace.ps, res) } ================================================ FILE: x/tokenfactory/module.go ================================================ /* The tokenfactory module allows any account to create a new token with the name `factory/{creator address}/{subdenom}`. - Mint and burn user denom to and form any account - Create a transfer of their denom between any two accounts - Change the admin. In the future, more admin capabilities may be added. */ package tokenfactory import ( "context" "encoding/json" "fmt" "github.com/gorilla/mux" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/spf13/cobra" abci "github.com/cometbft/cometbft/abci/types" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/codec" cdctypes "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/module" "github.com/cybercongress/go-cyber/v7/x/tokenfactory/client/cli" "github.com/cybercongress/go-cyber/v7/x/tokenfactory/exported" "github.com/cybercongress/go-cyber/v7/x/tokenfactory/keeper" "github.com/cybercongress/go-cyber/v7/x/tokenfactory/types" ) var ( _ module.AppModule = AppModule{} _ module.AppModuleBasic = AppModuleBasic{} ) // ConsensusVersion defines the current x/tokenfactory module consensus version. const ConsensusVersion = 2 // ---------------------------------------------------------------------------- // AppModuleBasic // ---------------------------------------------------------------------------- // AppModuleBasic implements the AppModuleBasic interface for the capability module. type AppModuleBasic struct{} func NewAppModuleBasic() AppModuleBasic { return AppModuleBasic{} } // Name returns the x/tokenfactory module's name. func (AppModuleBasic) Name() string { return types.ModuleName } func (AppModuleBasic) RegisterLegacyAminoCodec(cdc *codec.LegacyAmino) { types.RegisterLegacyAminoCodec(cdc) } // RegisterInterfaces registers the module's interface types func (a AppModuleBasic) RegisterInterfaces(reg cdctypes.InterfaceRegistry) { types.RegisterInterfaces(reg) } // DefaultGenesis returns the x/tokenfactory module's default genesis state. func (AppModuleBasic) DefaultGenesis(cdc codec.JSONCodec) json.RawMessage { return cdc.MustMarshalJSON(types.DefaultGenesis()) } // ValidateGenesis performs genesis state validation for the x/tokenfactory module. func (AppModuleBasic) ValidateGenesis(cdc codec.JSONCodec, _ client.TxEncodingConfig, bz json.RawMessage) error { var genState types.GenesisState if err := cdc.UnmarshalJSON(bz, &genState); err != nil { return fmt.Errorf("failed to unmarshal %s genesis state: %w", types.ModuleName, err) } return genState.Validate() } // RegisterRESTRoutes registers the capability module's REST service handlers. func (AppModuleBasic) RegisterRESTRoutes(_ client.Context, _ *mux.Router) { } // RegisterGRPCGatewayRoutes registers the gRPC Gateway routes for the module. func (AppModuleBasic) RegisterGRPCGatewayRoutes(clientCtx client.Context, mux *runtime.ServeMux) { types.RegisterQueryHandlerClient(context.Background(), mux, types.NewQueryClient(clientCtx)) //nolint:errcheck } // GetTxCmd returns the x/tokenfactory module's root tx command. func (a AppModuleBasic) GetTxCmd() *cobra.Command { return cli.GetTxCmd() } // GetQueryCmd returns the x/tokenfactory module's root query command. func (AppModuleBasic) GetQueryCmd() *cobra.Command { return cli.GetQueryCmd() } // ---------------------------------------------------------------------------- // AppModule // ---------------------------------------------------------------------------- // AppModule implements the AppModule interface for the capability module. type AppModule struct { AppModuleBasic keeper keeper.Keeper accountKeeper types.AccountKeeper bankKeeper types.BankKeeper legacySubspace exported.Subspace } func NewAppModule( keeper keeper.Keeper, accountKeeper types.AccountKeeper, bankKeeper types.BankKeeper, // legacySubspace is used solely for migration of x/params managed parameters legacySubspace exported.Subspace, ) AppModule { return AppModule{ AppModuleBasic: NewAppModuleBasic(), keeper: keeper, accountKeeper: accountKeeper, bankKeeper: bankKeeper, legacySubspace: legacySubspace, } } // Name returns the x/tokenfactory module's name. func (am AppModule) Name() string { return am.AppModuleBasic.Name() } // RegisterServices registers a GRPC query service to respond to the // module-specific GRPC queries. func (am AppModule) RegisterServices(cfg module.Configurator) { types.RegisterMsgServer(cfg.MsgServer(), keeper.NewMsgServerImpl(am.keeper)) types.RegisterQueryServer(cfg.QueryServer(), am.keeper) m := keeper.NewMigrator(am.keeper, am.legacySubspace) if err := cfg.RegisterMigration(types.ModuleName, 1, m.Migrate1to2); err != nil { panic(fmt.Sprintf("failed to migrate x/%s from version 1 to 2: %v", types.ModuleName, err)) } } // RegisterInvariants registers the x/tokenfactory module's invariants. func (am AppModule) RegisterInvariants(_ sdk.InvariantRegistry) {} // InitGenesis performs the x/tokenfactory module's genesis initialization. It // returns no validator updates. func (am AppModule) InitGenesis(ctx sdk.Context, cdc codec.JSONCodec, gs json.RawMessage) []abci.ValidatorUpdate { var genState types.GenesisState cdc.MustUnmarshalJSON(gs, &genState) am.keeper.InitGenesis(ctx, genState) return []abci.ValidatorUpdate{} } // ExportGenesis returns the x/tokenfactory module's exported genesis state as raw // JSON bytes. func (am AppModule) ExportGenesis(ctx sdk.Context, cdc codec.JSONCodec) json.RawMessage { genState := am.keeper.ExportGenesis(ctx) return cdc.MustMarshalJSON(genState) } // ConsensusVersion implements ConsensusVersion. func (AppModule) ConsensusVersion() uint64 { return ConsensusVersion } // BeginBlock executes all ABCI BeginBlock logic respective to the tokenfactory module. func (am AppModule) BeginBlock(_ sdk.Context, _ abci.RequestBeginBlock) {} // EndBlock executes all ABCI EndBlock logic respective to the tokenfactory module. It // returns no validator updates. func (am AppModule) EndBlock(_ sdk.Context, _ abci.RequestEndBlock) []abci.ValidatorUpdate { return []abci.ValidatorUpdate{} } ================================================ FILE: x/tokenfactory/testhelpers/authz.go ================================================ package testhelpers import ( "encoding/json" "testing" "time" "github.com/stretchr/testify/require" "github.com/cosmos/cosmos-sdk/codec" cdctypes "github.com/cosmos/cosmos-sdk/codec/types" cryptocodec "github.com/cosmos/cosmos-sdk/crypto/codec" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/x/authz" ) var ( Amino = codec.NewLegacyAmino() AuthzModuleCdc = codec.NewAminoCodec(Amino) ) func init() { cryptocodec.RegisterCrypto(Amino) codec.RegisterEvidences(Amino) sdk.RegisterLegacyAminoCodec(Amino) } func TestMessageAuthzSerialization(t *testing.T, msg sdk.Msg) { someDate := time.Date(1, 1, 1, 1, 1, 1, 1, time.UTC) const ( mockGranter string = "cosmos1abc" mockGrantee string = "cosmos1xyz" ) var ( mockMsgGrant authz.MsgGrant mockMsgRevoke authz.MsgRevoke mockMsgExec authz.MsgExec ) // Authz: Grant Msg typeURL := sdk.MsgTypeURL(msg) later := someDate.Add(time.Hour) grant, err := authz.NewGrant(someDate, authz.NewGenericAuthorization(typeURL), &later) require.NoError(t, err) msgGrant := authz.MsgGrant{Granter: mockGranter, Grantee: mockGrantee, Grant: grant} msgGrantBytes := json.RawMessage(sdk.MustSortJSON(AuthzModuleCdc.MustMarshalJSON(&msgGrant))) err = AuthzModuleCdc.UnmarshalJSON(msgGrantBytes, &mockMsgGrant) require.NoError(t, err) // Authz: Revoke Msg msgRevoke := authz.MsgRevoke{Granter: mockGranter, Grantee: mockGrantee, MsgTypeUrl: typeURL} msgRevokeByte := json.RawMessage(sdk.MustSortJSON(AuthzModuleCdc.MustMarshalJSON(&msgRevoke))) err = AuthzModuleCdc.UnmarshalJSON(msgRevokeByte, &mockMsgRevoke) require.NoError(t, err) // Authz: Exec Msg msgAny, err := cdctypes.NewAnyWithValue(msg) require.NoError(t, err) msgExec := authz.MsgExec{Grantee: mockGrantee, Msgs: []*cdctypes.Any{msgAny}} execMsgByte := json.RawMessage(sdk.MustSortJSON(AuthzModuleCdc.MustMarshalJSON(&msgExec))) err = AuthzModuleCdc.UnmarshalJSON(execMsgByte, &mockMsgExec) require.NoError(t, err) require.Equal(t, msgExec.Msgs[0].Value, mockMsgExec.Msgs[0].Value) } ================================================ FILE: x/tokenfactory/types/authorityMetadata.go ================================================ package types import ( sdk "github.com/cosmos/cosmos-sdk/types" ) func (metadata DenomAuthorityMetadata) Validate() error { if metadata.Admin != "" { _, err := sdk.AccAddressFromBech32(metadata.Admin) if err != nil { return err } } return nil } ================================================ FILE: x/tokenfactory/types/authorityMetadata.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: osmosis/tokenfactory/v1beta1/authorityMetadata.proto package types import ( fmt "fmt" _ "github.com/cosmos/cosmos-sdk/types" _ "github.com/cosmos/gogoproto/gogoproto" proto "github.com/cosmos/gogoproto/proto" io "io" math "math" math_bits "math/bits" ) // Reference imports to suppress errors if they are not otherwise used. var _ = proto.Marshal var _ = fmt.Errorf var _ = math.Inf // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package // DenomAuthorityMetadata specifies metadata for addresses that have specific // capabilities over a token factory denom. Right now there is only one Admin // permission, but is planned to be extended to the future. type DenomAuthorityMetadata struct { // Can be empty for no admin, or a valid osmosis address Admin string `protobuf:"bytes,1,opt,name=admin,proto3" json:"admin,omitempty" yaml:"admin"` } func (m *DenomAuthorityMetadata) Reset() { *m = DenomAuthorityMetadata{} } func (m *DenomAuthorityMetadata) String() string { return proto.CompactTextString(m) } func (*DenomAuthorityMetadata) ProtoMessage() {} func (*DenomAuthorityMetadata) Descriptor() ([]byte, []int) { return fileDescriptor_99435de88ae175f7, []int{0} } func (m *DenomAuthorityMetadata) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *DenomAuthorityMetadata) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_DenomAuthorityMetadata.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *DenomAuthorityMetadata) XXX_Merge(src proto.Message) { xxx_messageInfo_DenomAuthorityMetadata.Merge(m, src) } func (m *DenomAuthorityMetadata) XXX_Size() int { return m.Size() } func (m *DenomAuthorityMetadata) XXX_DiscardUnknown() { xxx_messageInfo_DenomAuthorityMetadata.DiscardUnknown(m) } var xxx_messageInfo_DenomAuthorityMetadata proto.InternalMessageInfo func (m *DenomAuthorityMetadata) GetAdmin() string { if m != nil { return m.Admin } return "" } func init() { proto.RegisterType((*DenomAuthorityMetadata)(nil), "osmosis.tokenfactory.v1beta1.DenomAuthorityMetadata") } func init() { proto.RegisterFile("osmosis/tokenfactory/v1beta1/authorityMetadata.proto", fileDescriptor_99435de88ae175f7) } var fileDescriptor_99435de88ae175f7 = []byte{ // 243 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x32, 0xc9, 0x2f, 0xce, 0xcd, 0x2f, 0xce, 0x2c, 0xd6, 0x2f, 0xc9, 0xcf, 0x4e, 0xcd, 0x4b, 0x4b, 0x4c, 0x2e, 0xc9, 0x2f, 0xaa, 0xd4, 0x2f, 0x33, 0x4c, 0x4a, 0x2d, 0x49, 0x34, 0xd4, 0x4f, 0x2c, 0x2d, 0xc9, 0xc8, 0x2f, 0xca, 0x2c, 0xa9, 0xf4, 0x4d, 0x2d, 0x49, 0x4c, 0x49, 0x2c, 0x49, 0xd4, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x92, 0x81, 0xea, 0xd2, 0x43, 0xd6, 0xa5, 0x07, 0xd5, 0x25, 0x25, 0x92, 0x9e, 0x9f, 0x9e, 0x0f, 0x56, 0xa8, 0x0f, 0x62, 0x41, 0xf4, 0x48, 0xc9, 0x25, 0x83, 0x35, 0xe9, 0x27, 0x25, 0x16, 0xa7, 0xc2, 0x2d, 0x48, 0xce, 0xcf, 0xcc, 0x83, 0xc8, 0x2b, 0xb9, 0x71, 0x89, 0xb9, 0xa4, 0xe6, 0xe5, 0xe7, 0x3a, 0xa2, 0xdb, 0x29, 0xa4, 0xc6, 0xc5, 0x9a, 0x98, 0x92, 0x9b, 0x99, 0x27, 0xc1, 0xa8, 0xc0, 0xa8, 0xc1, 0xe9, 0x24, 0xf0, 0xe9, 0x9e, 0x3c, 0x4f, 0x65, 0x62, 0x6e, 0x8e, 0x95, 0x12, 0x58, 0x58, 0x29, 0x08, 0x22, 0x6d, 0xc5, 0xf2, 0x62, 0x81, 0x3c, 0xa3, 0x93, 0xdf, 0x89, 0x47, 0x72, 0x8c, 0x17, 0x1e, 0xc9, 0x31, 0x3e, 0x78, 0x24, 0xc7, 0x38, 0xe1, 0xb1, 0x1c, 0xc3, 0x85, 0xc7, 0x72, 0x0c, 0x37, 0x1e, 0xcb, 0x31, 0x44, 0x99, 0xa4, 0x67, 0x96, 0x64, 0x94, 0x26, 0xe9, 0x25, 0xe7, 0xe7, 0xea, 0x3b, 0x83, 0x1d, 0xe3, 0x9c, 0x9f, 0x57, 0x52, 0x94, 0x98, 0x5c, 0x52, 0xac, 0x9f, 0x55, 0x9a, 0x97, 0xaf, 0x5f, 0x81, 0x1a, 0x0a, 0x25, 0x95, 0x05, 0xa9, 0xc5, 0x49, 0x6c, 0x60, 0xe7, 0x19, 0x03, 0x02, 0x00, 0x00, 0xff, 0xff, 0x33, 0x00, 0x78, 0xbe, 0x2a, 0x01, 0x00, 0x00, } func (this *DenomAuthorityMetadata) Equal(that interface{}) bool { if that == nil { return this == nil } that1, ok := that.(*DenomAuthorityMetadata) if !ok { that2, ok := that.(DenomAuthorityMetadata) if ok { that1 = &that2 } else { return false } } if that1 == nil { return this == nil } else if this == nil { return false } if this.Admin != that1.Admin { return false } return true } func (m *DenomAuthorityMetadata) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *DenomAuthorityMetadata) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *DenomAuthorityMetadata) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.Admin) > 0 { i -= len(m.Admin) copy(dAtA[i:], m.Admin) i = encodeVarintAuthorityMetadata(dAtA, i, uint64(len(m.Admin))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func encodeVarintAuthorityMetadata(dAtA []byte, offset int, v uint64) int { offset -= sovAuthorityMetadata(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *DenomAuthorityMetadata) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Admin) if l > 0 { n += 1 + l + sovAuthorityMetadata(uint64(l)) } return n } func sovAuthorityMetadata(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozAuthorityMetadata(x uint64) (n int) { return sovAuthorityMetadata(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *DenomAuthorityMetadata) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowAuthorityMetadata } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: DenomAuthorityMetadata: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: DenomAuthorityMetadata: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Admin", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowAuthorityMetadata } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthAuthorityMetadata } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthAuthorityMetadata } if postIndex > l { return io.ErrUnexpectedEOF } m.Admin = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipAuthorityMetadata(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthAuthorityMetadata } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipAuthorityMetadata(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowAuthorityMetadata } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowAuthorityMetadata } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowAuthorityMetadata } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthAuthorityMetadata } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupAuthorityMetadata } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthAuthorityMetadata } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthAuthorityMetadata = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowAuthorityMetadata = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupAuthorityMetadata = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/tokenfactory/types/capabilities.go ================================================ package types const ( EnableSetMetadata = "enable_metadata" EnableForceTransfer = "enable_force_transfer" EnableBurnFrom = "enable_burn_from" ) func IsCapabilityEnabled(enabledCapabilities []string, capability string) bool { if len(enabledCapabilities) == 0 { return true } for _, v := range enabledCapabilities { if v == capability { return true } } return false } ================================================ FILE: x/tokenfactory/types/codec.go ================================================ package types import ( "github.com/cosmos/cosmos-sdk/codec" codectypes "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cosmos/cosmos-sdk/types/msgservice" authzcodec "github.com/cosmos/cosmos-sdk/x/authz/codec" ) var ( amino = codec.NewLegacyAmino() // ModuleCdc references the global erc20 module codec. Note, the codec should // ONLY be used in certain instances of tests and for JSON encoding. // // The actual codec used for serialization should be provided to modules/erc20 and // defined at the application level. ModuleCdc = codec.NewProtoCodec(codectypes.NewInterfaceRegistry()) // AminoCdc is a amino codec created to support amino JSON compatible msgs. AminoCdc = codec.NewAminoCodec(amino) ) const ( // Amino names createTFDenom = "osmosis/tokenfactory/create-denom" mintTFDenom = "osmosis/tokenfactory/mint" burnTFDenom = "osmosis/tokenfactory/burn" forceTransferTFDenom = "osmosis/tokenfactory/force-transfer" changeAdminTFDenom = "osmosis/tokenfactory/change-admin" updateTFparams = "osmosis/tokenfactory/msg-update-params" ) // NOTE: This is required for the GetSignBytes function func init() { RegisterLegacyAminoCodec(amino) sdk.RegisterLegacyAminoCodec(amino) // cryptocodec.RegisterCrypto(amino) // codec.RegisterEvidences(amino) // Register all Amino interfaces and concrete types on the authz Amino codec // so that this can later be used to properly serialize MsgGrant and MsgExec // instances. RegisterLegacyAminoCodec(authzcodec.Amino) amino.Seal() } func RegisterInterfaces(registry codectypes.InterfaceRegistry) { registry.RegisterImplementations( (*sdk.Msg)(nil), &MsgCreateDenom{}, &MsgMint{}, &MsgBurn{}, &MsgForceTransfer{}, &MsgChangeAdmin{}, &MsgUpdateParams{}, ) msgservice.RegisterMsgServiceDesc(registry, &_Msg_serviceDesc) } func RegisterLegacyAminoCodec(cdc *codec.LegacyAmino) { cdc.RegisterConcrete(&MsgCreateDenom{}, createTFDenom, nil) cdc.RegisterConcrete(&MsgMint{}, mintTFDenom, nil) cdc.RegisterConcrete(&MsgBurn{}, burnTFDenom, nil) cdc.RegisterConcrete(&MsgForceTransfer{}, forceTransferTFDenom, nil) cdc.RegisterConcrete(&MsgChangeAdmin{}, changeAdminTFDenom, nil) cdc.RegisterConcrete(&MsgUpdateParams{}, updateTFparams, nil) } ================================================ FILE: x/tokenfactory/types/codec_test.go ================================================ package types import ( "testing" "github.com/stretchr/testify/suite" codectypes "github.com/cosmos/cosmos-sdk/codec/types" sdk "github.com/cosmos/cosmos-sdk/types" ) type CodecTestSuite struct { suite.Suite } func TestCodecSuite(t *testing.T) { suite.Run(t, new(CodecTestSuite)) } func (suite *CodecTestSuite) TestRegisterInterfaces() { registry := codectypes.NewInterfaceRegistry() registry.RegisterInterface(sdk.MsgInterfaceProtoName, (*sdk.Msg)(nil)) RegisterInterfaces(registry) impls := registry.ListImplementations(sdk.MsgInterfaceProtoName) suite.Require().Equal(7, len(impls)) suite.Require().ElementsMatch([]string{ "/osmosis.tokenfactory.v1beta1.MsgCreateDenom", "/osmosis.tokenfactory.v1beta1.MsgMint", "/osmosis.tokenfactory.v1beta1.MsgBurn", "/osmosis.tokenfactory.v1beta1.MsgChangeAdmin", "/osmosis.tokenfactory.v1beta1.MsgSetDenomMetadata", "/osmosis.tokenfactory.v1beta1.MsgForceTransfer", "/osmosis.tokenfactory.v1beta1.MsgUpdateParams", }, impls) } ================================================ FILE: x/tokenfactory/types/denoms.go ================================================ package types import ( "strings" errorsmod "cosmossdk.io/errors" sdk "github.com/cosmos/cosmos-sdk/types" ) const ( ModuleDenomPrefix = "factory" // See the TokenFactory readme for a derivation of these. // TL;DR, MaxSubdenomLength + MaxHrpLength = 60 comes from SDK max denom length = 128 // and the structure of tokenfactory denoms. MaxSubdenomLength = 44 MaxHrpLength = 16 // MaxCreatorLength = 59 + MaxHrpLength MaxCreatorLength = 59 + MaxHrpLength ) // GetTokenDenom constructs a denom string for tokens created by tokenfactory // based on an input creator address and a subdenom // The denom constructed is factory/{creator}/{subdenom} func GetTokenDenom(creator, subdenom string) (string, error) { if len(subdenom) > MaxSubdenomLength { return "", ErrSubdenomTooLong } if len(creator) > MaxCreatorLength { return "", ErrCreatorTooLong } if strings.Contains(creator, "/") { return "", ErrInvalidCreator } denom := strings.Join([]string{ModuleDenomPrefix, creator, subdenom}, "/") return denom, sdk.ValidateDenom(denom) } // DeconstructDenom takes a token denom string and verifies that it is a valid // denom of the tokenfactory module, and is of the form `factory/{creator}/{subdenom}` // If valid, it returns the creator address and subdenom func DeconstructDenom(denom string) (creator string, subdenom string, err error) { err = sdk.ValidateDenom(denom) if err != nil { return "", "", err } strParts := strings.Split(denom, "/") if len(strParts) < 3 { return "", "", errorsmod.Wrapf(ErrInvalidDenom, "not enough parts of denom %s", denom) } if strParts[0] != ModuleDenomPrefix { return "", "", errorsmod.Wrapf(ErrInvalidDenom, "denom prefix is incorrect. Is: %s. Should be: %s", strParts[0], ModuleDenomPrefix) } creator = strParts[1] creatorAddr, err := sdk.AccAddressFromBech32(creator) if err != nil { return "", "", errorsmod.Wrapf(ErrInvalidDenom, "Invalid creator address (%s)", err) } // Handle the case where a denom has a slash in its subdenom. For example, // when we did the split, we'd turn factory/accaddr/atomderivative/sikka into ["factory", "accaddr", "atomderivative", "sikka"] // So we have to join [2:] with a "/" as the delimiter to get back the correct subdenom which should be "atomderivative/sikka" subdenom = strings.Join(strParts[2:], "/") return creatorAddr.String(), subdenom, nil } ================================================ FILE: x/tokenfactory/types/denoms_test.go ================================================ package types_test import ( "testing" "github.com/stretchr/testify/require" "github.com/cybercongress/go-cyber/v7/x/tokenfactory/types" ) func TestDeconstructDenom(t *testing.T) { // Note: this seems to be used in osmosis to add some more checks (only 20 or 32 byte addresses), // which is good, but not required for these tests as they make code less reuable // appparams.SetAddressPrefixes() for _, tc := range []struct { desc string denom string expectedSubdenom string err error }{ { desc: "empty is invalid", denom: "", err: types.ErrInvalidDenom, }, { desc: "normal", denom: "factory/cosmos1t7egva48prqmzl59x5ngv4zx0dtrwewcdqdjr8/bitcoin", expectedSubdenom: "bitcoin", }, { desc: "multiple slashes in subdenom", denom: "factory/cosmos1t7egva48prqmzl59x5ngv4zx0dtrwewcdqdjr8/bitcoin/1", expectedSubdenom: "bitcoin/1", }, { desc: "no subdenom", denom: "factory/cosmos1t7egva48prqmzl59x5ngv4zx0dtrwewcdqdjr8/", expectedSubdenom: "", }, { desc: "incorrect prefix", denom: "ibc/cosmos1t7egva48prqmzl59x5ngv4zx0dtrwewcdqdjr8/bitcoin", err: types.ErrInvalidDenom, }, { desc: "subdenom of only slashes", denom: "factory/cosmos1t7egva48prqmzl59x5ngv4zx0dtrwewcdqdjr8/////", expectedSubdenom: "////", }, { desc: "too long name", denom: "factory/cosmos1t7egva48prqmzl59x5ngv4zx0dtrwewcdqdjr8/adsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsf", err: types.ErrInvalidDenom, }, } { t.Run(tc.desc, func(t *testing.T) { expectedCreator := "cosmos1t7egva48prqmzl59x5ngv4zx0dtrwewcdqdjr8" creator, subdenom, err := types.DeconstructDenom(tc.denom) if tc.err != nil { require.ErrorContains(t, err, tc.err.Error()) } else { require.NoError(t, err) require.Equal(t, expectedCreator, creator) require.Equal(t, tc.expectedSubdenom, subdenom) } }) } } func TestGetTokenDenom(t *testing.T) { // appparams.SetAddressPrefixes() for _, tc := range []struct { desc string creator string subdenom string valid bool }{ { desc: "normal", creator: "cosmos1t7egva48prqmzl59x5ngv4zx0dtrwewcdqdjr8", subdenom: "bitcoin", valid: true, }, { desc: "multiple slashes in subdenom", creator: "cosmos1t7egva48prqmzl59x5ngv4zx0dtrwewcdqdjr8", subdenom: "bitcoin/1", valid: true, }, { desc: "no subdenom", creator: "cosmos1t7egva48prqmzl59x5ngv4zx0dtrwewcdqdjr8", subdenom: "", valid: true, }, { desc: "subdenom of only slashes", creator: "cosmos1t7egva48prqmzl59x5ngv4zx0dtrwewcdqdjr8", subdenom: "/////", valid: true, }, { desc: "too long name", creator: "cosmos1t7egva48prqmzl59x5ngv4zx0dtrwewcdqdjr8", subdenom: "adsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsfadsf", valid: false, }, { desc: "subdenom is exactly max length", creator: "cosmos1t7egva48prqmzl59x5ngv4zx0dtrwewcdqdjr8", subdenom: "bitcoinfsadfsdfeadfsafwefsefsefsdfsdafasefsf", valid: true, }, { desc: "creator is exactly max length", creator: "cosmos1t7egva48prqmzl59x5ngv4zx0dtrwewcdqdjr8jhgjhgkhjklhkjhkjhgjhgjgjghelu", subdenom: "bitcoin", valid: true, }, } { t.Run(tc.desc, func(t *testing.T) { _, err := types.GetTokenDenom(tc.creator, tc.subdenom) if tc.valid { require.NoError(t, err) } else { require.Error(t, err) } }) } } ================================================ FILE: x/tokenfactory/types/errors.go ================================================ package types // DONTCOVER import ( fmt "fmt" errorsmod "cosmossdk.io/errors" ) // x/tokenfactory module sentinel errors var ( ErrDenomExists = errorsmod.Register(ModuleName, 2, "attempting to create a denom that already exists (has bank metadata)") ErrUnauthorized = errorsmod.Register(ModuleName, 3, "unauthorized account") ErrInvalidDenom = errorsmod.Register(ModuleName, 4, "invalid denom") ErrInvalidCreator = errorsmod.Register(ModuleName, 5, "invalid creator") ErrInvalidAuthorityMetadata = errorsmod.Register(ModuleName, 6, "invalid authority metadata") ErrInvalidGenesis = errorsmod.Register(ModuleName, 7, "invalid genesis") ErrSubdenomTooLong = errorsmod.Register(ModuleName, 8, fmt.Sprintf("subdenom too long, max length is %d bytes", MaxSubdenomLength)) ErrCreatorTooLong = errorsmod.Register(ModuleName, 9, fmt.Sprintf("creator too long, max length is %d bytes", MaxCreatorLength)) ErrDenomDoesNotExist = errorsmod.Register(ModuleName, 10, "denom does not exist") ErrCapabilityNotEnabled = errorsmod.Register(ModuleName, 11, "this capability is not enabled on chain") ) ================================================ FILE: x/tokenfactory/types/events.go ================================================ package types // event types // //nolint:gosec const ( AttributeAmount = "amount" AttributeCreator = "creator" AttributeSubdenom = "subdenom" AttributeNewTokenDenom = "new_token_denom" AttributeMintToAddress = "mint_to_address" AttributeBurnFromAddress = "burn_from_address" AttributeTransferFromAddress = "transfer_from_address" AttributeTransferToAddress = "transfer_to_address" AttributeDenom = "denom" AttributeNewAdmin = "new_admin" AttributeDenomMetadata = "denom_metadata" ) ================================================ FILE: x/tokenfactory/types/expected_keepers.go ================================================ package types import ( sdk "github.com/cosmos/cosmos-sdk/types" authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" ) type BankKeeper interface { // Methods imported from bank should be defined here GetDenomMetaData(ctx sdk.Context, denom string) (banktypes.Metadata, bool) SetDenomMetaData(ctx sdk.Context, denomMetaData banktypes.Metadata) HasSupply(ctx sdk.Context, denom string) bool IterateTotalSupply(ctx sdk.Context, cb func(sdk.Coin) bool) SendCoinsFromModuleToAccount(ctx sdk.Context, senderModule string, recipientAddr sdk.AccAddress, amt sdk.Coins) error SendCoinsFromAccountToModule(ctx sdk.Context, senderAddr sdk.AccAddress, recipientModule string, amt sdk.Coins) error MintCoins(ctx sdk.Context, moduleName string, amt sdk.Coins) error BurnCoins(ctx sdk.Context, moduleName string, amt sdk.Coins) error SendCoins(ctx sdk.Context, fromAddr sdk.AccAddress, toAddr sdk.AccAddress, amt sdk.Coins) error HasBalance(ctx sdk.Context, addr sdk.AccAddress, amt sdk.Coin) bool GetAllBalances(ctx sdk.Context, addr sdk.AccAddress) sdk.Coins SpendableCoins(ctx sdk.Context, addr sdk.AccAddress) sdk.Coins GetBalance(ctx sdk.Context, addr sdk.AccAddress, denom string) sdk.Coin BlockedAddr(addr sdk.AccAddress) bool } type AccountKeeper interface { SetModuleAccount(ctx sdk.Context, macc authtypes.ModuleAccountI) GetAccount(ctx sdk.Context, addr sdk.AccAddress) authtypes.AccountI GetModuleAccount(ctx sdk.Context, moduleName string) authtypes.ModuleAccountI } // CommunityPoolKeeper defines the contract needed to be fulfilled for community pool interactions. type CommunityPoolKeeper interface { FundCommunityPool(ctx sdk.Context, amount sdk.Coins, sender sdk.AccAddress) error } ================================================ FILE: x/tokenfactory/types/genesis.go ================================================ package types import ( errorsmod "cosmossdk.io/errors" sdk "github.com/cosmos/cosmos-sdk/types" ) // this line is used by starport scaffolding # genesis/types/import // DefaultIndex is the default capability global index const DefaultIndex uint64 = 1 // DefaultGenesis returns the default Capability genesis state func DefaultGenesis() *GenesisState { return &GenesisState{ Params: DefaultParams(), FactoryDenoms: []GenesisDenom{}, } } // Validate performs basic genesis state validation returning an error upon any // failure. func (gs GenesisState) Validate() error { err := gs.Params.Validate() if err != nil { return err } seenDenoms := map[string]bool{} for _, denom := range gs.GetFactoryDenoms() { if seenDenoms[denom.GetDenom()] { return errorsmod.Wrapf(ErrInvalidGenesis, "duplicate denom: %s", denom.GetDenom()) } seenDenoms[denom.GetDenom()] = true _, _, err := DeconstructDenom(denom.GetDenom()) if err != nil { return err } if denom.AuthorityMetadata.Admin != "" { _, err = sdk.AccAddressFromBech32(denom.AuthorityMetadata.Admin) if err != nil { return errorsmod.Wrapf(ErrInvalidAuthorityMetadata, "Invalid admin address (%s)", err) } } } return nil } ================================================ FILE: x/tokenfactory/types/genesis.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: osmosis/tokenfactory/v1beta1/genesis.proto package types import ( fmt "fmt" _ "github.com/cosmos/gogoproto/gogoproto" proto "github.com/cosmos/gogoproto/proto" io "io" math "math" math_bits "math/bits" ) // Reference imports to suppress errors if they are not otherwise used. var _ = proto.Marshal var _ = fmt.Errorf var _ = math.Inf // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package // GenesisState defines the tokenfactory module's genesis state. type GenesisState struct { // params defines the parameters of the module. Params Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params"` FactoryDenoms []GenesisDenom `protobuf:"bytes,2,rep,name=factory_denoms,json=factoryDenoms,proto3" json:"factory_denoms" yaml:"factory_denoms"` } func (m *GenesisState) Reset() { *m = GenesisState{} } func (m *GenesisState) String() string { return proto.CompactTextString(m) } func (*GenesisState) ProtoMessage() {} func (*GenesisState) Descriptor() ([]byte, []int) { return fileDescriptor_5749c3f71850298b, []int{0} } func (m *GenesisState) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *GenesisState) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_GenesisState.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *GenesisState) XXX_Merge(src proto.Message) { xxx_messageInfo_GenesisState.Merge(m, src) } func (m *GenesisState) XXX_Size() int { return m.Size() } func (m *GenesisState) XXX_DiscardUnknown() { xxx_messageInfo_GenesisState.DiscardUnknown(m) } var xxx_messageInfo_GenesisState proto.InternalMessageInfo func (m *GenesisState) GetParams() Params { if m != nil { return m.Params } return Params{} } func (m *GenesisState) GetFactoryDenoms() []GenesisDenom { if m != nil { return m.FactoryDenoms } return nil } // GenesisDenom defines a tokenfactory denom that is defined within genesis // state. The structure contains DenomAuthorityMetadata which defines the // denom's admin. type GenesisDenom struct { Denom string `protobuf:"bytes,1,opt,name=denom,proto3" json:"denom,omitempty" yaml:"denom"` AuthorityMetadata DenomAuthorityMetadata `protobuf:"bytes,2,opt,name=authority_metadata,json=authorityMetadata,proto3" json:"authority_metadata" yaml:"authority_metadata"` } func (m *GenesisDenom) Reset() { *m = GenesisDenom{} } func (m *GenesisDenom) String() string { return proto.CompactTextString(m) } func (*GenesisDenom) ProtoMessage() {} func (*GenesisDenom) Descriptor() ([]byte, []int) { return fileDescriptor_5749c3f71850298b, []int{1} } func (m *GenesisDenom) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *GenesisDenom) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_GenesisDenom.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *GenesisDenom) XXX_Merge(src proto.Message) { xxx_messageInfo_GenesisDenom.Merge(m, src) } func (m *GenesisDenom) XXX_Size() int { return m.Size() } func (m *GenesisDenom) XXX_DiscardUnknown() { xxx_messageInfo_GenesisDenom.DiscardUnknown(m) } var xxx_messageInfo_GenesisDenom proto.InternalMessageInfo func (m *GenesisDenom) GetDenom() string { if m != nil { return m.Denom } return "" } func (m *GenesisDenom) GetAuthorityMetadata() DenomAuthorityMetadata { if m != nil { return m.AuthorityMetadata } return DenomAuthorityMetadata{} } func init() { proto.RegisterType((*GenesisState)(nil), "osmosis.tokenfactory.v1beta1.GenesisState") proto.RegisterType((*GenesisDenom)(nil), "osmosis.tokenfactory.v1beta1.GenesisDenom") } func init() { proto.RegisterFile("osmosis/tokenfactory/v1beta1/genesis.proto", fileDescriptor_5749c3f71850298b) } var fileDescriptor_5749c3f71850298b = []byte{ // 369 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x7c, 0x91, 0xc1, 0x4e, 0xf2, 0x40, 0x14, 0x85, 0x3b, 0xfc, 0xfc, 0x24, 0x16, 0x34, 0xda, 0x68, 0x82, 0x44, 0x5b, 0x6c, 0x8c, 0x41, 0x16, 0x6d, 0x40, 0x56, 0xec, 0x2c, 0x24, 0xae, 0x34, 0xa6, 0xee, 0xdc, 0x90, 0x01, 0xc6, 0x52, 0xb5, 0x9d, 0xa6, 0x73, 0x31, 0xf6, 0x05, 0x5c, 0xfb, 0x08, 0x3e, 0x8c, 0x26, 0x2c, 0x59, 0xba, 0x22, 0x06, 0x36, 0xae, 0x79, 0x02, 0xc3, 0xcc, 0x44, 0x45, 0x92, 0xee, 0xda, 0x3b, 0xdf, 0x39, 0x73, 0xee, 0x1c, 0xb5, 0x4a, 0x59, 0x40, 0x99, 0xcf, 0x6c, 0xa0, 0x77, 0x24, 0xbc, 0xc1, 0x3d, 0xa0, 0x71, 0x62, 0x3f, 0xd4, 0xba, 0x04, 0x70, 0xcd, 0xf6, 0x48, 0x48, 0x98, 0xcf, 0xac, 0x28, 0xa6, 0x40, 0xb5, 0x3d, 0xc9, 0x5a, 0xbf, 0x59, 0x4b, 0xb2, 0xa5, 0x6d, 0x8f, 0x7a, 0x94, 0x83, 0xf6, 0xe2, 0x4b, 0x68, 0x4a, 0x8d, 0x54, 0x7f, 0x3c, 0x84, 0x01, 0x8d, 0x7d, 0x48, 0xce, 0x09, 0xe0, 0x3e, 0x06, 0x2c, 0x55, 0xc7, 0xa9, 0xaa, 0x08, 0xc7, 0x38, 0x90, 0xa1, 0xcc, 0x57, 0xa4, 0x16, 0xce, 0x44, 0xcc, 0x2b, 0xc0, 0x40, 0x34, 0x47, 0xcd, 0x09, 0xa0, 0x88, 0xca, 0xa8, 0x92, 0xaf, 0x1f, 0x5a, 0x69, 0xb1, 0xad, 0x4b, 0xce, 0x3a, 0xd9, 0xd1, 0xc4, 0x50, 0x5c, 0xa9, 0xd4, 0x22, 0x75, 0x43, 0x72, 0x9d, 0x3e, 0x09, 0x69, 0xc0, 0x8a, 0x99, 0xf2, 0xbf, 0x4a, 0xbe, 0x5e, 0x4d, 0xf7, 0x92, 0x39, 0xda, 0x0b, 0x89, 0xb3, 0xbf, 0x70, 0x9c, 0x4f, 0x8c, 0x9d, 0x04, 0x07, 0xf7, 0x4d, 0x73, 0xd9, 0xcf, 0x74, 0xd7, 0xe5, 0xa0, 0x2d, 0xfe, 0xdf, 0x7e, 0xd6, 0xe0, 0x13, 0xed, 0x48, 0xfd, 0xcf, 0x51, 0xbe, 0xc5, 0x9a, 0xb3, 0x39, 0x9f, 0x18, 0x05, 0xe1, 0xc4, 0xc7, 0xa6, 0x2b, 0x8e, 0xb5, 0x27, 0xa4, 0x6a, 0xdf, 0xcf, 0xd8, 0x09, 0xe4, 0x3b, 0x16, 0x33, 0x7c, 0xf7, 0x46, 0x7a, 0x5e, 0x7e, 0xd3, 0xe9, 0xdf, 0x0e, 0x9c, 0x03, 0x99, 0x7c, 0x57, 0xdc, 0xb7, 0xea, 0x6e, 0xba, 0x5b, 0x2b, 0xcd, 0x35, 0xb3, 0x9f, 0x2f, 0x06, 0x72, 0x2e, 0x46, 0x53, 0x1d, 0x8d, 0xa7, 0x3a, 0xfa, 0x98, 0xea, 0xe8, 0x79, 0xa6, 0x2b, 0xe3, 0x99, 0xae, 0xbc, 0xcf, 0x74, 0xe5, 0xba, 0xe1, 0xf9, 0x30, 0x18, 0x76, 0xad, 0x1e, 0x0d, 0xec, 0x16, 0x8f, 0xd5, 0xa2, 0x21, 0xc4, 0xb8, 0x07, 0xcc, 0xbe, 0x1d, 0x86, 0xd4, 0x7e, 0x5c, 0x6e, 0x1b, 0x92, 0x88, 0xb0, 0x6e, 0x8e, 0xb7, 0x7c, 0xf2, 0x15, 0x00, 0x00, 0xff, 0xff, 0xa0, 0x2e, 0xfa, 0xa4, 0xa8, 0x02, 0x00, 0x00, } func (this *GenesisDenom) Equal(that interface{}) bool { if that == nil { return this == nil } that1, ok := that.(*GenesisDenom) if !ok { that2, ok := that.(GenesisDenom) if ok { that1 = &that2 } else { return false } } if that1 == nil { return this == nil } else if this == nil { return false } if this.Denom != that1.Denom { return false } if !this.AuthorityMetadata.Equal(&that1.AuthorityMetadata) { return false } return true } func (m *GenesisState) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *GenesisState) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *GenesisState) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.FactoryDenoms) > 0 { for iNdEx := len(m.FactoryDenoms) - 1; iNdEx >= 0; iNdEx-- { { size, err := m.FactoryDenoms[iNdEx].MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintGenesis(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 } } { size, err := m.Params.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintGenesis(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa return len(dAtA) - i, nil } func (m *GenesisDenom) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *GenesisDenom) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *GenesisDenom) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.AuthorityMetadata.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintGenesis(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 if len(m.Denom) > 0 { i -= len(m.Denom) copy(dAtA[i:], m.Denom) i = encodeVarintGenesis(dAtA, i, uint64(len(m.Denom))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func encodeVarintGenesis(dAtA []byte, offset int, v uint64) int { offset -= sovGenesis(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *GenesisState) Size() (n int) { if m == nil { return 0 } var l int _ = l l = m.Params.Size() n += 1 + l + sovGenesis(uint64(l)) if len(m.FactoryDenoms) > 0 { for _, e := range m.FactoryDenoms { l = e.Size() n += 1 + l + sovGenesis(uint64(l)) } } return n } func (m *GenesisDenom) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Denom) if l > 0 { n += 1 + l + sovGenesis(uint64(l)) } l = m.AuthorityMetadata.Size() n += 1 + l + sovGenesis(uint64(l)) return n } func sovGenesis(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozGenesis(x uint64) (n int) { return sovGenesis(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *GenesisState) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenesis } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: GenesisState: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: GenesisState: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenesis } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthGenesis } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenesis } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Params.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field FactoryDenoms", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenesis } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthGenesis } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenesis } if postIndex > l { return io.ErrUnexpectedEOF } m.FactoryDenoms = append(m.FactoryDenoms, GenesisDenom{}) if err := m.FactoryDenoms[len(m.FactoryDenoms)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipGenesis(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthGenesis } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *GenesisDenom) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenesis } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: GenesisDenom: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: GenesisDenom: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Denom", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenesis } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthGenesis } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthGenesis } if postIndex > l { return io.ErrUnexpectedEOF } m.Denom = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field AuthorityMetadata", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenesis } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthGenesis } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthGenesis } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.AuthorityMetadata.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipGenesis(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthGenesis } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipGenesis(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowGenesis } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowGenesis } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowGenesis } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthGenesis } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupGenesis } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthGenesis } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthGenesis = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowGenesis = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupGenesis = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/tokenfactory/types/genesis_test.go ================================================ package types_test import ( "testing" "github.com/stretchr/testify/require" "github.com/cybercongress/go-cyber/v7/x/tokenfactory/types" ) func TestGenesisState_Validate(t *testing.T) { for _, tc := range []struct { desc string genState *types.GenesisState valid bool }{ { desc: "default is valid", genState: types.DefaultGenesis(), valid: true, }, { desc: "valid genesis state", genState: &types.GenesisState{ FactoryDenoms: []types.GenesisDenom{ { Denom: "factory/cosmos1t7egva48prqmzl59x5ngv4zx0dtrwewcdqdjr8/bitcoin", AuthorityMetadata: types.DenomAuthorityMetadata{ Admin: "cosmos1t7egva48prqmzl59x5ngv4zx0dtrwewcdqdjr8", }, }, }, }, valid: true, }, { desc: "different admin from creator", genState: &types.GenesisState{ FactoryDenoms: []types.GenesisDenom{ { Denom: "factory/cosmos1t7egva48prqmzl59x5ngv4zx0dtrwewcdqdjr8/bitcoin", AuthorityMetadata: types.DenomAuthorityMetadata{ Admin: "cosmos1ft6e5esdtdegnvcr3djd3ftk4kwpcr6jta8eyh", }, }, }, }, valid: true, }, { desc: "empty admin", genState: &types.GenesisState{ FactoryDenoms: []types.GenesisDenom{ { Denom: "factory/cosmos1t7egva48prqmzl59x5ngv4zx0dtrwewcdqdjr8/bitcoin", AuthorityMetadata: types.DenomAuthorityMetadata{ Admin: "", }, }, }, }, valid: true, }, { desc: "no admin", genState: &types.GenesisState{ FactoryDenoms: []types.GenesisDenom{ { Denom: "factory/cosmos1t7egva48prqmzl59x5ngv4zx0dtrwewcdqdjr8/bitcoin", }, }, }, valid: true, }, { desc: "invalid admin", genState: &types.GenesisState{ FactoryDenoms: []types.GenesisDenom{ { Denom: "factory/cosmos1t7egva48prqmzl59x5ngv4zx0dtrwewcdqdjr8/bitcoin", AuthorityMetadata: types.DenomAuthorityMetadata{ Admin: "moose", }, }, }, }, valid: false, }, { desc: "multiple denoms", genState: &types.GenesisState{ FactoryDenoms: []types.GenesisDenom{ { Denom: "factory/cosmos1t7egva48prqmzl59x5ngv4zx0dtrwewcdqdjr8/bitcoin", AuthorityMetadata: types.DenomAuthorityMetadata{ Admin: "", }, }, { Denom: "factory/cosmos1t7egva48prqmzl59x5ngv4zx0dtrwewcdqdjr8/litecoin", AuthorityMetadata: types.DenomAuthorityMetadata{ Admin: "", }, }, }, }, valid: true, }, { desc: "duplicate denoms", genState: &types.GenesisState{ FactoryDenoms: []types.GenesisDenom{ { Denom: "factory/cosmos1t7egva48prqmzl59x5ngv4zx0dtrwewcdqdjr8/bitcoin", AuthorityMetadata: types.DenomAuthorityMetadata{ Admin: "", }, }, { Denom: "factory/cosmos1t7egva48prqmzl59x5ngv4zx0dtrwewcdqdjr8/bitcoin", AuthorityMetadata: types.DenomAuthorityMetadata{ Admin: "", }, }, }, }, valid: false, }, } { t.Run(tc.desc, func(t *testing.T) { err := tc.genState.Validate() if tc.valid { require.NoError(t, err) } else { require.Error(t, err) } }) } } ================================================ FILE: x/tokenfactory/types/keys.go ================================================ package types import ( "strings" ) var ParamsKey = []byte{0x00} const ( // ModuleName defines the module name ModuleName = "tokenfactory" // StoreKey defines the primary module store key StoreKey = ModuleName // RouterKey is the message route for slashing RouterKey = ModuleName // MemStoreKey defines the in-memory store key MemStoreKey = "mem_tokenfactory" ) // KeySeparator is used to combine parts of the keys in the store const KeySeparator = "|" var ( DenomAuthorityMetadataKey = "authoritymetadata" DenomsPrefixKey = "denoms" CreatorPrefixKey = "creator" AdminPrefixKey = "admin" ) // GetDenomPrefixStore returns the store prefix where all the data associated with a specific denom // is stored func GetDenomPrefixStore(denom string) []byte { return []byte(strings.Join([]string{DenomsPrefixKey, denom, ""}, KeySeparator)) } // GetCreatorsPrefix returns the store prefix where the list of the denoms created by a specific // creator are stored func GetCreatorPrefix(creator string) []byte { return []byte(strings.Join([]string{CreatorPrefixKey, creator, ""}, KeySeparator)) } // GetCreatorsPrefix returns the store prefix where a list of all creator addresses are stored func GetCreatorsPrefix() []byte { return []byte(strings.Join([]string{CreatorPrefixKey, ""}, KeySeparator)) } ================================================ FILE: x/tokenfactory/types/msgs.go ================================================ package types import ( errorsmod "cosmossdk.io/errors" sdk "github.com/cosmos/cosmos-sdk/types" sdkerrors "github.com/cosmos/cosmos-sdk/types/errors" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" ) const ( TypeMsgCreateDenom = "create_denom" TypeMsgMint = "tf_mint" TypeMsgBurn = "tf_burn" TypeMsgForceTransfer = "force_transfer" TypeMsgChangeAdmin = "change_admin" TypeMsgSetDenomMetadata = "set_denom_metadata" ) var _ sdk.Msg = &MsgCreateDenom{} // NewMsgCreateDenom creates a msg to create a new denom func NewMsgCreateDenom(sender, subdenom string) *MsgCreateDenom { return &MsgCreateDenom{ Sender: sender, Subdenom: subdenom, } } func (m MsgCreateDenom) Route() string { return RouterKey } func (m MsgCreateDenom) Type() string { return TypeMsgCreateDenom } func (m MsgCreateDenom) ValidateBasic() error { _, err := sdk.AccAddressFromBech32(m.Sender) if err != nil { return errorsmod.Wrapf(sdkerrors.ErrInvalidAddress, "Invalid sender address (%s)", err) } _, err = GetTokenDenom(m.Sender, m.Subdenom) if err != nil { return errorsmod.Wrap(ErrInvalidDenom, err.Error()) } return nil } func (m MsgCreateDenom) GetSignBytes() []byte { return sdk.MustSortJSON(ModuleCdc.MustMarshalJSON(&m)) } func (m MsgCreateDenom) GetSigners() []sdk.AccAddress { sender, _ := sdk.AccAddressFromBech32(m.Sender) return []sdk.AccAddress{sender} } var _ sdk.Msg = &MsgMint{} // NewMsgMint creates a message to mint tokens func NewMsgMint(sender string, amount sdk.Coin) *MsgMint { return &MsgMint{ Sender: sender, Amount: amount, } } func NewMsgMintTo(sender string, amount sdk.Coin, mintToAddress string) *MsgMint { return &MsgMint{ Sender: sender, Amount: amount, MintToAddress: mintToAddress, } } func (m MsgMint) Route() string { return RouterKey } func (m MsgMint) Type() string { return TypeMsgMint } func (m MsgMint) ValidateBasic() error { _, err := sdk.AccAddressFromBech32(m.Sender) if err != nil { return errorsmod.Wrapf(sdkerrors.ErrInvalidAddress, "Invalid sender address (%s)", err) } if m.MintToAddress != "" { _, err = sdk.AccAddressFromBech32(m.MintToAddress) if err != nil { return errorsmod.Wrapf(sdkerrors.ErrInvalidAddress, "Invalid mint to address (%s)", err) } } if !m.Amount.IsValid() || m.Amount.Amount.Equal(sdk.ZeroInt()) { return errorsmod.Wrap(sdkerrors.ErrInvalidCoins, m.Amount.String()) } return nil } func (m MsgMint) GetSignBytes() []byte { return sdk.MustSortJSON(ModuleCdc.MustMarshalJSON(&m)) } func (m MsgMint) GetSigners() []sdk.AccAddress { sender, _ := sdk.AccAddressFromBech32(m.Sender) return []sdk.AccAddress{sender} } var _ sdk.Msg = &MsgBurn{} // NewMsgBurn creates a message to burn tokens func NewMsgBurn(sender string, amount sdk.Coin) *MsgBurn { return &MsgBurn{ Sender: sender, Amount: amount, } } // NewMsgBurn creates a message to burn tokens func NewMsgBurnFrom(sender string, amount sdk.Coin, burnFromAddress string) *MsgBurn { return &MsgBurn{ Sender: sender, Amount: amount, BurnFromAddress: burnFromAddress, } } func (m MsgBurn) Route() string { return RouterKey } func (m MsgBurn) Type() string { return TypeMsgBurn } func (m MsgBurn) ValidateBasic() error { _, err := sdk.AccAddressFromBech32(m.Sender) if err != nil { return errorsmod.Wrapf(sdkerrors.ErrInvalidAddress, "Invalid sender address (%s)", err) } if !m.Amount.IsValid() || m.Amount.Amount.Equal(sdk.ZeroInt()) { return errorsmod.Wrap(sdkerrors.ErrInvalidCoins, m.Amount.String()) } if m.BurnFromAddress != "" { _, err = sdk.AccAddressFromBech32(m.BurnFromAddress) if err != nil { return errorsmod.Wrapf(sdkerrors.ErrInvalidAddress, "Invalid burn from address (%s)", err) } } return nil } func (m MsgBurn) GetSignBytes() []byte { return sdk.MustSortJSON(ModuleCdc.MustMarshalJSON(&m)) } func (m MsgBurn) GetSigners() []sdk.AccAddress { sender, _ := sdk.AccAddressFromBech32(m.Sender) return []sdk.AccAddress{sender} } var _ sdk.Msg = &MsgForceTransfer{} // NewMsgForceTransfer creates a transfer funds from one account to another func NewMsgForceTransfer(sender string, amount sdk.Coin, fromAddr, toAddr string) *MsgForceTransfer { return &MsgForceTransfer{ Sender: sender, Amount: amount, TransferFromAddress: fromAddr, TransferToAddress: toAddr, } } func (m MsgForceTransfer) Route() string { return RouterKey } func (m MsgForceTransfer) Type() string { return TypeMsgForceTransfer } func (m MsgForceTransfer) ValidateBasic() error { _, err := sdk.AccAddressFromBech32(m.Sender) if err != nil { return errorsmod.Wrapf(sdkerrors.ErrInvalidAddress, "Invalid sender address (%s)", err) } _, err = sdk.AccAddressFromBech32(m.TransferFromAddress) if err != nil { return errorsmod.Wrapf(sdkerrors.ErrInvalidAddress, "Invalid from address (%s)", err) } _, err = sdk.AccAddressFromBech32(m.TransferToAddress) if err != nil { return errorsmod.Wrapf(sdkerrors.ErrInvalidAddress, "Invalid to address (%s)", err) } if !m.Amount.IsValid() { return errorsmod.Wrap(sdkerrors.ErrInvalidCoins, m.Amount.String()) } return nil } func (m MsgForceTransfer) GetSignBytes() []byte { return sdk.MustSortJSON(ModuleCdc.MustMarshalJSON(&m)) } func (m MsgForceTransfer) GetSigners() []sdk.AccAddress { sender, _ := sdk.AccAddressFromBech32(m.Sender) return []sdk.AccAddress{sender} } var _ sdk.Msg = &MsgChangeAdmin{} // NewMsgChangeAdmin creates a message to burn tokens func NewMsgChangeAdmin(sender, denom, newAdmin string) *MsgChangeAdmin { return &MsgChangeAdmin{ Sender: sender, Denom: denom, NewAdmin: newAdmin, } } func (m MsgChangeAdmin) Route() string { return RouterKey } func (m MsgChangeAdmin) Type() string { return TypeMsgChangeAdmin } func (m MsgChangeAdmin) ValidateBasic() error { _, err := sdk.AccAddressFromBech32(m.Sender) if err != nil { return errorsmod.Wrapf(sdkerrors.ErrInvalidAddress, "Invalid sender address (%s)", err) } _, err = sdk.AccAddressFromBech32(m.NewAdmin) if err != nil { return errorsmod.Wrapf(sdkerrors.ErrInvalidAddress, "Invalid address (%s)", err) } _, _, err = DeconstructDenom(m.Denom) if err != nil { return err } return nil } func (m MsgChangeAdmin) GetSignBytes() []byte { return sdk.MustSortJSON(ModuleCdc.MustMarshalJSON(&m)) } func (m MsgChangeAdmin) GetSigners() []sdk.AccAddress { sender, _ := sdk.AccAddressFromBech32(m.Sender) return []sdk.AccAddress{sender} } var _ sdk.Msg = &MsgSetDenomMetadata{} // NewMsgChangeAdmin creates a message to burn tokens func NewMsgSetDenomMetadata(sender string, metadata banktypes.Metadata) *MsgSetDenomMetadata { return &MsgSetDenomMetadata{ Sender: sender, Metadata: metadata, } } func (m MsgSetDenomMetadata) Route() string { return RouterKey } func (m MsgSetDenomMetadata) Type() string { return TypeMsgSetDenomMetadata } func (m MsgSetDenomMetadata) ValidateBasic() error { _, err := sdk.AccAddressFromBech32(m.Sender) if err != nil { return errorsmod.Wrapf(sdkerrors.ErrInvalidAddress, "Invalid sender address (%s)", err) } err = m.Metadata.Validate() if err != nil { return err } _, _, err = DeconstructDenom(m.Metadata.Base) if err != nil { return err } return nil } func (m MsgSetDenomMetadata) GetSignBytes() []byte { return sdk.MustSortJSON(ModuleCdc.MustMarshalJSON(&m)) } func (m MsgSetDenomMetadata) GetSigners() []sdk.AccAddress { sender, _ := sdk.AccAddressFromBech32(m.Sender) return []sdk.AccAddress{sender} } var _ sdk.Msg = &MsgUpdateParams{} // GetSignBytes implements the LegacyMsg interface. func (m MsgUpdateParams) GetSignBytes() []byte { return sdk.MustSortJSON(ModuleCdc.MustMarshalJSON(&m)) } // GetSigners returns the expected signers for a MsgUpdateParams message. func (m *MsgUpdateParams) GetSigners() []sdk.AccAddress { addr, _ := sdk.AccAddressFromBech32(m.Authority) return []sdk.AccAddress{addr} } // ValidateBasic does a sanity check on the provided data. func (m *MsgUpdateParams) ValidateBasic() error { if _, err := sdk.AccAddressFromBech32(m.Authority); err != nil { return errorsmod.Wrap(err, "invalid authority address") } return m.Params.Validate() } ================================================ FILE: x/tokenfactory/types/msgs_test.go ================================================ package types_test import ( fmt "fmt" "testing" "github.com/stretchr/testify/require" "github.com/cometbft/cometbft/crypto/ed25519" sdk "github.com/cosmos/cosmos-sdk/types" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" "github.com/cybercongress/go-cyber/v7/x/tokenfactory/testhelpers" "github.com/cybercongress/go-cyber/v7/x/tokenfactory/types" ) // Test authz serialize and de-serializes for tokenfactory msg. func TestAuthzMsg(t *testing.T) { t.Skip("TODO: figure out how to register authz interfaces for tests") pk1 := ed25519.GenPrivKey().PubKey() addr1 := sdk.AccAddress(pk1.Address()).String() coin := sdk.NewCoin("denom", sdk.NewInt(1)) testCases := []struct { name string msg sdk.Msg }{ { name: "MsgCreateDenom", msg: &types.MsgCreateDenom{ Sender: addr1, Subdenom: "valoper1xyz", }, }, { name: "MsgBurn", msg: &types.MsgBurn{ Sender: addr1, Amount: coin, }, }, { name: "MsgMint", msg: &types.MsgMint{ Sender: addr1, Amount: coin, }, }, { name: "MsgChangeAdmin", msg: &types.MsgChangeAdmin{ Sender: addr1, Denom: "denom", NewAdmin: "osmo1q8tq5qhrhw6t970egemuuwywhlhpnmdmts6xnu", }, }, } for _, tc := range testCases { t.Run(tc.name, func(t *testing.T) { testhelpers.TestMessageAuthzSerialization(t, tc.msg) }) } } // TestMsgCreateDenom tests if valid/invalid create denom messages are properly validated/invalidated func TestMsgCreateDenom(t *testing.T) { // generate a private/public key pair and get the respective address pk1 := ed25519.GenPrivKey().PubKey() addr1 := sdk.AccAddress(pk1.Address()) // make a proper createDenom message createMsg := func(after func(msg types.MsgCreateDenom) types.MsgCreateDenom) types.MsgCreateDenom { properMsg := *types.NewMsgCreateDenom( addr1.String(), "bitcoin", ) return after(properMsg) } // validate createDenom message was created as intended msg := createMsg(func(msg types.MsgCreateDenom) types.MsgCreateDenom { return msg }) require.Equal(t, msg.Route(), types.RouterKey) require.Equal(t, msg.Type(), "create_denom") signers := msg.GetSigners() require.Equal(t, len(signers), 1) require.Equal(t, signers[0].String(), addr1.String()) tests := []struct { name string msg types.MsgCreateDenom expectPass bool }{ { name: "proper msg", msg: createMsg(func(msg types.MsgCreateDenom) types.MsgCreateDenom { return msg }), expectPass: true, }, { name: "empty sender", msg: createMsg(func(msg types.MsgCreateDenom) types.MsgCreateDenom { msg.Sender = "" return msg }), expectPass: false, }, { name: "invalid subdenom", msg: createMsg(func(msg types.MsgCreateDenom) types.MsgCreateDenom { msg.Subdenom = "thissubdenomismuchtoolongasdkfjaasdfdsafsdlkfnmlksadmflksmdlfmlsakmfdsafasdfasdf" return msg }), expectPass: false, }, } for _, test := range tests { if test.expectPass { require.NoError(t, test.msg.ValidateBasic(), "test: %v", test.name) } else { require.Error(t, test.msg.ValidateBasic(), "test: %v", test.name) } } } // TestMsgMint tests if valid/invalid create denom messages are properly validated/invalidated func TestMsgMint(t *testing.T) { // generate a private/public key pair and get the respective address pk1 := ed25519.GenPrivKey().PubKey() addr1 := sdk.AccAddress(pk1.Address()) // make a proper mint message createMsg := func(after func(msg types.MsgMint) types.MsgMint) types.MsgMint { properMsg := *types.NewMsgMint( addr1.String(), sdk.NewCoin("bitcoin", sdk.NewInt(500000000)), ) return after(properMsg) } // validate mint message was created as intended msg := createMsg(func(msg types.MsgMint) types.MsgMint { return msg }) require.Equal(t, msg.Route(), types.RouterKey) require.Equal(t, msg.Type(), "tf_mint") signers := msg.GetSigners() require.Equal(t, len(signers), 1) require.Equal(t, signers[0].String(), addr1.String()) tests := []struct { name string msg types.MsgMint expectPass bool }{ { name: "proper msg", msg: createMsg(func(msg types.MsgMint) types.MsgMint { return msg }), expectPass: true, }, { name: "empty sender", msg: createMsg(func(msg types.MsgMint) types.MsgMint { msg.Sender = "" return msg }), expectPass: false, }, { name: "zero amount", msg: createMsg(func(msg types.MsgMint) types.MsgMint { msg.Amount = sdk.NewCoin("bitcoin", sdk.ZeroInt()) return msg }), expectPass: false, }, { name: "negative amount", msg: createMsg(func(msg types.MsgMint) types.MsgMint { msg.Amount.Amount = sdk.NewInt(-10000000) return msg }), expectPass: false, }, } for _, test := range tests { if test.expectPass { require.NoError(t, test.msg.ValidateBasic(), "test: %v", test.name) } else { require.Error(t, test.msg.ValidateBasic(), "test: %v", test.name) } } } // TestMsgBurn tests if valid/invalid create denom messages are properly validated/invalidated func TestMsgBurn(t *testing.T) { // generate a private/public key pair and get the respective address pk1 := ed25519.GenPrivKey().PubKey() addr1 := sdk.AccAddress(pk1.Address()) // make a proper burn message baseMsg := types.NewMsgBurn( addr1.String(), sdk.NewCoin("bitcoin", sdk.NewInt(500000000)), ) // validate burn message was created as intended require.Equal(t, baseMsg.Route(), types.RouterKey) require.Equal(t, baseMsg.Type(), "tf_burn") signers := baseMsg.GetSigners() require.Equal(t, len(signers), 1) require.Equal(t, signers[0].String(), addr1.String()) tests := []struct { name string msg func() *types.MsgBurn expectPass bool }{ { name: "proper msg", msg: func() *types.MsgBurn { msg := baseMsg return msg }, expectPass: true, }, { name: "empty sender", msg: func() *types.MsgBurn { msg := baseMsg msg.Sender = "" return msg }, expectPass: false, }, { name: "zero amount", msg: func() *types.MsgBurn { msg := baseMsg msg.Amount.Amount = sdk.ZeroInt() return msg }, expectPass: false, }, { name: "negative amount", msg: func() *types.MsgBurn { msg := baseMsg msg.Amount.Amount = sdk.NewInt(-10000000) return msg }, expectPass: false, }, } for _, test := range tests { if test.expectPass { require.NoError(t, test.msg().ValidateBasic(), "test: %v", test.name) } else { require.Error(t, test.msg().ValidateBasic(), "test: %v", test.name) } } } // TestMsgChangeAdmin tests if valid/invalid create denom messages are properly validated/invalidated func TestMsgChangeAdmin(t *testing.T) { // generate a private/public key pair and get the respective address pk1 := ed25519.GenPrivKey().PubKey() addr1 := sdk.AccAddress(pk1.Address()) pk2 := ed25519.GenPrivKey().PubKey() addr2 := sdk.AccAddress(pk2.Address()) tokenFactoryDenom := fmt.Sprintf("factory/%s/bitcoin", addr1.String()) // make a proper changeAdmin message baseMsg := types.NewMsgChangeAdmin( addr1.String(), tokenFactoryDenom, addr2.String(), ) // validate changeAdmin message was created as intended require.Equal(t, baseMsg.Route(), types.RouterKey) require.Equal(t, baseMsg.Type(), "change_admin") signers := baseMsg.GetSigners() require.Equal(t, len(signers), 1) require.Equal(t, signers[0].String(), addr1.String()) tests := []struct { name string msg func() *types.MsgChangeAdmin expectPass bool }{ { name: "proper msg", msg: func() *types.MsgChangeAdmin { msg := baseMsg return msg }, expectPass: true, }, { name: "empty sender", msg: func() *types.MsgChangeAdmin { msg := baseMsg msg.Sender = "" return msg }, expectPass: false, }, { name: "empty newAdmin", msg: func() *types.MsgChangeAdmin { msg := baseMsg msg.NewAdmin = "" return msg }, expectPass: false, }, { name: "invalid denom", msg: func() *types.MsgChangeAdmin { msg := baseMsg msg.Denom = "bitcoin" return msg }, expectPass: false, }, } for _, test := range tests { if test.expectPass { require.NoError(t, test.msg().ValidateBasic(), "test: %v", test.name) } else { require.Error(t, test.msg().ValidateBasic(), "test: %v", test.name) } } } // TestMsgSetDenomMetadata tests if valid/invalid create denom messages are properly validated/invalidated func TestMsgSetDenomMetadata(t *testing.T) { // generate a private/public key pair and get the respective address pk1 := ed25519.GenPrivKey().PubKey() addr1 := sdk.AccAddress(pk1.Address()) tokenFactoryDenom := fmt.Sprintf("factory/%s/bitcoin", addr1.String()) denomMetadata := banktypes.Metadata{ Description: "nakamoto", DenomUnits: []*banktypes.DenomUnit{ { Denom: tokenFactoryDenom, Exponent: 0, }, { Denom: "sats", Exponent: 6, }, }, Display: "sats", Base: tokenFactoryDenom, Name: "bitcoin", Symbol: "BTC", } invalidDenomMetadata := banktypes.Metadata{ Description: "nakamoto", DenomUnits: []*banktypes.DenomUnit{ { Denom: "bitcoin", Exponent: 0, }, { Denom: "sats", Exponent: 6, }, }, Display: "sats", Base: "bitcoin", Name: "bitcoin", Symbol: "BTC", } // make a proper setDenomMetadata message baseMsg := types.NewMsgSetDenomMetadata( addr1.String(), denomMetadata, ) // validate setDenomMetadata message was created as intended require.Equal(t, baseMsg.Route(), types.RouterKey) require.Equal(t, baseMsg.Type(), "set_denom_metadata") signers := baseMsg.GetSigners() require.Equal(t, len(signers), 1) require.Equal(t, signers[0].String(), addr1.String()) tests := []struct { name string msg func() *types.MsgSetDenomMetadata expectPass bool }{ { name: "proper msg", msg: func() *types.MsgSetDenomMetadata { msg := baseMsg return msg }, expectPass: true, }, { name: "empty sender", msg: func() *types.MsgSetDenomMetadata { msg := baseMsg msg.Sender = "" return msg }, expectPass: false, }, { name: "invalid metadata", msg: func() *types.MsgSetDenomMetadata { msg := baseMsg msg.Metadata.Name = "" return msg }, expectPass: false, }, { name: "invalid base", msg: func() *types.MsgSetDenomMetadata { msg := baseMsg msg.Metadata = invalidDenomMetadata return msg }, expectPass: false, }, } for _, test := range tests { if test.expectPass { require.NoError(t, test.msg().ValidateBasic(), "test: %v", test.name) } else { require.Error(t, test.msg().ValidateBasic(), "test: %v", test.name) } } } ================================================ FILE: x/tokenfactory/types/params.go ================================================ package types import ( "fmt" sdk "github.com/cosmos/cosmos-sdk/types" ) func NewParams(denomCreationFee sdk.Coins) Params { return Params{ DenomCreationFee: denomCreationFee, } } // default tokenfactory module parameters. func DefaultParams() Params { return Params{ DenomCreationFee: sdk.NewCoins(sdk.NewInt64Coin(sdk.DefaultBondDenom, 10_000_000)), DenomCreationGasConsume: 2_000_000, } } // validate params. func (p Params) Validate() error { err := validateDenomCreationFee(p.DenomCreationFee) return err } func validateDenomCreationFee(i interface{}) error { v, ok := i.(sdk.Coins) if !ok { return fmt.Errorf("invalid parameter type: %T", i) } if v.Validate() != nil { return fmt.Errorf("invalid denom creation fee: %+v", i) } return nil } func validateDenomCreationFeeGasConsume(i interface{}) error { _, ok := i.(uint64) if !ok { return fmt.Errorf("invalid parameter type: %T", i) } return nil } ================================================ FILE: x/tokenfactory/types/params.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: osmosis/tokenfactory/v1beta1/params.proto package types import ( fmt "fmt" _ "github.com/cosmos/cosmos-proto" github_com_cosmos_cosmos_sdk_types "github.com/cosmos/cosmos-sdk/types" types "github.com/cosmos/cosmos-sdk/types" _ "github.com/cosmos/gogoproto/gogoproto" proto "github.com/cosmos/gogoproto/proto" io "io" math "math" math_bits "math/bits" ) // Reference imports to suppress errors if they are not otherwise used. var _ = proto.Marshal var _ = fmt.Errorf var _ = math.Inf // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package // Params defines the parameters for the tokenfactory module. type Params struct { DenomCreationFee github_com_cosmos_cosmos_sdk_types.Coins `protobuf:"bytes,1,rep,name=denom_creation_fee,json=denomCreationFee,proto3,castrepeated=github.com/cosmos/cosmos-sdk/types.Coins" json:"denom_creation_fee" yaml:"denom_creation_fee"` // if denom_creation_fee is an empty array, then this field is used to add more gas consumption // to the base cost. // https://github.com/CosmWasm/token-factory/issues/11 DenomCreationGasConsume uint64 `protobuf:"varint,2,opt,name=denom_creation_gas_consume,json=denomCreationGasConsume,proto3" json:"denom_creation_gas_consume,omitempty" yaml:"denom_creation_gas_consume"` } func (m *Params) Reset() { *m = Params{} } func (m *Params) String() string { return proto.CompactTextString(m) } func (*Params) ProtoMessage() {} func (*Params) Descriptor() ([]byte, []int) { return fileDescriptor_cc8299d306f3ff47, []int{0} } func (m *Params) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *Params) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_Params.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *Params) XXX_Merge(src proto.Message) { xxx_messageInfo_Params.Merge(m, src) } func (m *Params) XXX_Size() int { return m.Size() } func (m *Params) XXX_DiscardUnknown() { xxx_messageInfo_Params.DiscardUnknown(m) } var xxx_messageInfo_Params proto.InternalMessageInfo func (m *Params) GetDenomCreationFee() github_com_cosmos_cosmos_sdk_types.Coins { if m != nil { return m.DenomCreationFee } return nil } func (m *Params) GetDenomCreationGasConsume() uint64 { if m != nil { return m.DenomCreationGasConsume } return 0 } func init() { proto.RegisterType((*Params)(nil), "osmosis.tokenfactory.v1beta1.Params") } func init() { proto.RegisterFile("osmosis/tokenfactory/v1beta1/params.proto", fileDescriptor_cc8299d306f3ff47) } var fileDescriptor_cc8299d306f3ff47 = []byte{ // 356 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x7c, 0x91, 0xc1, 0x4e, 0xea, 0x40, 0x14, 0x86, 0x5b, 0xee, 0x0d, 0x8b, 0xde, 0xcd, 0x4d, 0x73, 0x93, 0x0b, 0xc4, 0xb4, 0xd8, 0x15, 0x2c, 0xec, 0x04, 0x65, 0xe5, 0x92, 0x26, 0xba, 0xc2, 0x18, 0x96, 0x6e, 0x9a, 0xd3, 0x61, 0x28, 0x15, 0x3b, 0x87, 0x74, 0xa6, 0xc6, 0x3e, 0x82, 0x3b, 0x57, 0x3e, 0x84, 0x4f, 0xc2, 0x92, 0xa5, 0xab, 0x6a, 0xe0, 0x0d, 0x78, 0x02, 0xc3, 0x74, 0x34, 0xa0, 0xc6, 0x55, 0x7b, 0xf2, 0xff, 0xff, 0x37, 0xff, 0x99, 0xb1, 0xba, 0x28, 0x52, 0x14, 0x89, 0x20, 0x12, 0x67, 0x8c, 0x4f, 0x80, 0x4a, 0xcc, 0x0a, 0x72, 0xdb, 0x8b, 0x98, 0x84, 0x1e, 0x99, 0x43, 0x06, 0xa9, 0xf0, 0xe7, 0x19, 0x4a, 0xb4, 0x0f, 0xb4, 0xd5, 0xdf, 0xb5, 0xfa, 0xda, 0xda, 0xfa, 0x17, 0x63, 0x8c, 0xca, 0x48, 0xb6, 0x7f, 0x55, 0xa6, 0xd5, 0xff, 0x11, 0x0f, 0xb9, 0x9c, 0x62, 0x96, 0xc8, 0x62, 0xc8, 0x24, 0x8c, 0x41, 0x82, 0x4e, 0x35, 0xa9, 0x8a, 0x85, 0x15, 0xae, 0x1a, 0xb4, 0xe4, 0x54, 0x13, 0x89, 0x40, 0xb0, 0x0f, 0x0e, 0xc5, 0x84, 0x57, 0xba, 0x77, 0x5f, 0xb3, 0xea, 0x97, 0xaa, 0xb5, 0xfd, 0x68, 0x5a, 0xf6, 0x98, 0x71, 0x4c, 0x43, 0x9a, 0x31, 0x90, 0x09, 0xf2, 0x70, 0xc2, 0x58, 0xc3, 0x6c, 0xff, 0xea, 0xfc, 0x39, 0x6e, 0xfa, 0x1a, 0xbb, 0x05, 0xbd, 0x2f, 0xe1, 0x07, 0x98, 0xf0, 0xc1, 0x70, 0x51, 0xba, 0xc6, 0xa6, 0x74, 0x9b, 0x05, 0xa4, 0x37, 0xa7, 0xde, 0x57, 0x84, 0xf7, 0xf4, 0xe2, 0x76, 0xe2, 0x44, 0x4e, 0xf3, 0xc8, 0xa7, 0x98, 0xea, 0x82, 0xfa, 0x73, 0x24, 0xc6, 0x33, 0x22, 0x8b, 0x39, 0x13, 0x8a, 0x26, 0x46, 0x7f, 0x15, 0x20, 0xd0, 0xf9, 0x33, 0xc6, 0xec, 0x89, 0xd5, 0xfa, 0x04, 0x8d, 0x41, 0x84, 0x14, 0xb9, 0xc8, 0x53, 0xd6, 0xa8, 0xb5, 0xcd, 0xce, 0xef, 0x41, 0x77, 0x51, 0xba, 0xe6, 0xa6, 0x74, 0x0f, 0xbf, 0x2d, 0xb1, 0xe3, 0xf7, 0x46, 0xff, 0xf7, 0x0e, 0x38, 0x07, 0x11, 0x54, 0xca, 0xe0, 0x62, 0xb1, 0x72, 0xcc, 0xe5, 0xca, 0x31, 0x5f, 0x57, 0x8e, 0xf9, 0xb0, 0x76, 0x8c, 0xe5, 0xda, 0x31, 0x9e, 0xd7, 0x8e, 0x71, 0xd5, 0xdf, 0x69, 0x1f, 0xa8, 0xda, 0x01, 0x72, 0x99, 0x01, 0x95, 0x82, 0x5c, 0xe7, 0x1c, 0xc9, 0xdd, 0xfe, 0x83, 0xa9, 0x7d, 0xa2, 0xba, 0xba, 0xe2, 0x93, 0xb7, 0x00, 0x00, 0x00, 0xff, 0xff, 0xe4, 0xe8, 0xa8, 0x46, 0x34, 0x02, 0x00, 0x00, } func (m *Params) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *Params) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *Params) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if m.DenomCreationGasConsume != 0 { i = encodeVarintParams(dAtA, i, uint64(m.DenomCreationGasConsume)) i-- dAtA[i] = 0x10 } if len(m.DenomCreationFee) > 0 { for iNdEx := len(m.DenomCreationFee) - 1; iNdEx >= 0; iNdEx-- { { size, err := m.DenomCreationFee[iNdEx].MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintParams(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa } } return len(dAtA) - i, nil } func encodeVarintParams(dAtA []byte, offset int, v uint64) int { offset -= sovParams(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *Params) Size() (n int) { if m == nil { return 0 } var l int _ = l if len(m.DenomCreationFee) > 0 { for _, e := range m.DenomCreationFee { l = e.Size() n += 1 + l + sovParams(uint64(l)) } } if m.DenomCreationGasConsume != 0 { n += 1 + sovParams(uint64(m.DenomCreationGasConsume)) } return n } func sovParams(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozParams(x uint64) (n int) { return sovParams(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *Params) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowParams } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: Params: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: Params: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field DenomCreationFee", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowParams } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthParams } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthParams } if postIndex > l { return io.ErrUnexpectedEOF } m.DenomCreationFee = append(m.DenomCreationFee, types.Coin{}) if err := m.DenomCreationFee[len(m.DenomCreationFee)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field DenomCreationGasConsume", wireType) } m.DenomCreationGasConsume = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowParams } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ m.DenomCreationGasConsume |= uint64(b&0x7F) << shift if b < 0x80 { break } } default: iNdEx = preIndex skippy, err := skipParams(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthParams } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipParams(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowParams } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowParams } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowParams } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthParams } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupParams } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthParams } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthParams = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowParams = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupParams = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/tokenfactory/types/params_legacy.go ================================================ /* NOTE: Usage of x/params to manage parameters is deprecated in favor of x/gov controlled execution of MsgUpdateParams messages. These types remains solely for migration purposes and will be removed in a future release. */ package types import ( paramtypes "github.com/cosmos/cosmos-sdk/x/params/types" ) // Parameter legacy store keys. var ( KeyDenomCreationFee = []byte("DenomCreationFee") KeyDenomCreationGasConsume = []byte("DenomCreationGasConsume") ) // ParamTable for tokenfactory module. // Deprecated: Type declaration for parameters func ParamKeyTable() paramtypes.KeyTable { return paramtypes.NewKeyTable().RegisterParamSet(&Params{}) } // Implements params.ParamSet. // Deprecated: legacy code. Remove after v47 upgrade. func (p *Params) ParamSetPairs() paramtypes.ParamSetPairs { return paramtypes.ParamSetPairs{ paramtypes.NewParamSetPair(KeyDenomCreationFee, &p.DenomCreationFee, validateDenomCreationFee), paramtypes.NewParamSetPair(KeyDenomCreationGasConsume, &p.DenomCreationGasConsume, validateDenomCreationFeeGasConsume), } } ================================================ FILE: x/tokenfactory/types/query.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: osmosis/tokenfactory/v1beta1/query.proto package types import ( context "context" fmt "fmt" _ "github.com/cosmos/cosmos-sdk/types/query" _ "github.com/cosmos/gogoproto/gogoproto" grpc1 "github.com/cosmos/gogoproto/grpc" proto "github.com/cosmos/gogoproto/proto" _ "google.golang.org/genproto/googleapis/api/annotations" grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" io "io" math "math" math_bits "math/bits" ) // Reference imports to suppress errors if they are not otherwise used. var _ = proto.Marshal var _ = fmt.Errorf var _ = math.Inf // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package // QueryParamsRequest is the request type for the Query/Params RPC method. type QueryParamsRequest struct { } func (m *QueryParamsRequest) Reset() { *m = QueryParamsRequest{} } func (m *QueryParamsRequest) String() string { return proto.CompactTextString(m) } func (*QueryParamsRequest) ProtoMessage() {} func (*QueryParamsRequest) Descriptor() ([]byte, []int) { return fileDescriptor_6f22013ad0f72e3f, []int{0} } func (m *QueryParamsRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryParamsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryParamsRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryParamsRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryParamsRequest.Merge(m, src) } func (m *QueryParamsRequest) XXX_Size() int { return m.Size() } func (m *QueryParamsRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryParamsRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryParamsRequest proto.InternalMessageInfo // QueryParamsResponse is the response type for the Query/Params RPC method. type QueryParamsResponse struct { // params defines the parameters of the module. Params Params `protobuf:"bytes,1,opt,name=params,proto3" json:"params"` } func (m *QueryParamsResponse) Reset() { *m = QueryParamsResponse{} } func (m *QueryParamsResponse) String() string { return proto.CompactTextString(m) } func (*QueryParamsResponse) ProtoMessage() {} func (*QueryParamsResponse) Descriptor() ([]byte, []int) { return fileDescriptor_6f22013ad0f72e3f, []int{1} } func (m *QueryParamsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryParamsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryParamsResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryParamsResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryParamsResponse.Merge(m, src) } func (m *QueryParamsResponse) XXX_Size() int { return m.Size() } func (m *QueryParamsResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryParamsResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryParamsResponse proto.InternalMessageInfo func (m *QueryParamsResponse) GetParams() Params { if m != nil { return m.Params } return Params{} } // QueryDenomAuthorityMetadataRequest defines the request structure for the // DenomAuthorityMetadata gRPC query. type QueryDenomAuthorityMetadataRequest struct { Denom string `protobuf:"bytes,1,opt,name=denom,proto3" json:"denom,omitempty" yaml:"denom"` } func (m *QueryDenomAuthorityMetadataRequest) Reset() { *m = QueryDenomAuthorityMetadataRequest{} } func (m *QueryDenomAuthorityMetadataRequest) String() string { return proto.CompactTextString(m) } func (*QueryDenomAuthorityMetadataRequest) ProtoMessage() {} func (*QueryDenomAuthorityMetadataRequest) Descriptor() ([]byte, []int) { return fileDescriptor_6f22013ad0f72e3f, []int{2} } func (m *QueryDenomAuthorityMetadataRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryDenomAuthorityMetadataRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryDenomAuthorityMetadataRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryDenomAuthorityMetadataRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryDenomAuthorityMetadataRequest.Merge(m, src) } func (m *QueryDenomAuthorityMetadataRequest) XXX_Size() int { return m.Size() } func (m *QueryDenomAuthorityMetadataRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryDenomAuthorityMetadataRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryDenomAuthorityMetadataRequest proto.InternalMessageInfo func (m *QueryDenomAuthorityMetadataRequest) GetDenom() string { if m != nil { return m.Denom } return "" } // QueryDenomAuthorityMetadataResponse defines the response structure for the // DenomAuthorityMetadata gRPC query. type QueryDenomAuthorityMetadataResponse struct { AuthorityMetadata DenomAuthorityMetadata `protobuf:"bytes,1,opt,name=authority_metadata,json=authorityMetadata,proto3" json:"authority_metadata" yaml:"authority_metadata"` } func (m *QueryDenomAuthorityMetadataResponse) Reset() { *m = QueryDenomAuthorityMetadataResponse{} } func (m *QueryDenomAuthorityMetadataResponse) String() string { return proto.CompactTextString(m) } func (*QueryDenomAuthorityMetadataResponse) ProtoMessage() {} func (*QueryDenomAuthorityMetadataResponse) Descriptor() ([]byte, []int) { return fileDescriptor_6f22013ad0f72e3f, []int{3} } func (m *QueryDenomAuthorityMetadataResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryDenomAuthorityMetadataResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryDenomAuthorityMetadataResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryDenomAuthorityMetadataResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryDenomAuthorityMetadataResponse.Merge(m, src) } func (m *QueryDenomAuthorityMetadataResponse) XXX_Size() int { return m.Size() } func (m *QueryDenomAuthorityMetadataResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryDenomAuthorityMetadataResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryDenomAuthorityMetadataResponse proto.InternalMessageInfo func (m *QueryDenomAuthorityMetadataResponse) GetAuthorityMetadata() DenomAuthorityMetadata { if m != nil { return m.AuthorityMetadata } return DenomAuthorityMetadata{} } // QueryDenomsFromCreatorRequest defines the request structure for the // DenomsFromCreator gRPC query. type QueryDenomsFromCreatorRequest struct { Creator string `protobuf:"bytes,1,opt,name=creator,proto3" json:"creator,omitempty" yaml:"creator"` } func (m *QueryDenomsFromCreatorRequest) Reset() { *m = QueryDenomsFromCreatorRequest{} } func (m *QueryDenomsFromCreatorRequest) String() string { return proto.CompactTextString(m) } func (*QueryDenomsFromCreatorRequest) ProtoMessage() {} func (*QueryDenomsFromCreatorRequest) Descriptor() ([]byte, []int) { return fileDescriptor_6f22013ad0f72e3f, []int{4} } func (m *QueryDenomsFromCreatorRequest) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryDenomsFromCreatorRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryDenomsFromCreatorRequest.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryDenomsFromCreatorRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryDenomsFromCreatorRequest.Merge(m, src) } func (m *QueryDenomsFromCreatorRequest) XXX_Size() int { return m.Size() } func (m *QueryDenomsFromCreatorRequest) XXX_DiscardUnknown() { xxx_messageInfo_QueryDenomsFromCreatorRequest.DiscardUnknown(m) } var xxx_messageInfo_QueryDenomsFromCreatorRequest proto.InternalMessageInfo func (m *QueryDenomsFromCreatorRequest) GetCreator() string { if m != nil { return m.Creator } return "" } // QueryDenomsFromCreatorRequest defines the response structure for the // DenomsFromCreator gRPC query. type QueryDenomsFromCreatorResponse struct { Denoms []string `protobuf:"bytes,1,rep,name=denoms,proto3" json:"denoms,omitempty" yaml:"denoms"` } func (m *QueryDenomsFromCreatorResponse) Reset() { *m = QueryDenomsFromCreatorResponse{} } func (m *QueryDenomsFromCreatorResponse) String() string { return proto.CompactTextString(m) } func (*QueryDenomsFromCreatorResponse) ProtoMessage() {} func (*QueryDenomsFromCreatorResponse) Descriptor() ([]byte, []int) { return fileDescriptor_6f22013ad0f72e3f, []int{5} } func (m *QueryDenomsFromCreatorResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *QueryDenomsFromCreatorResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_QueryDenomsFromCreatorResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *QueryDenomsFromCreatorResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_QueryDenomsFromCreatorResponse.Merge(m, src) } func (m *QueryDenomsFromCreatorResponse) XXX_Size() int { return m.Size() } func (m *QueryDenomsFromCreatorResponse) XXX_DiscardUnknown() { xxx_messageInfo_QueryDenomsFromCreatorResponse.DiscardUnknown(m) } var xxx_messageInfo_QueryDenomsFromCreatorResponse proto.InternalMessageInfo func (m *QueryDenomsFromCreatorResponse) GetDenoms() []string { if m != nil { return m.Denoms } return nil } func init() { proto.RegisterType((*QueryParamsRequest)(nil), "osmosis.tokenfactory.v1beta1.QueryParamsRequest") proto.RegisterType((*QueryParamsResponse)(nil), "osmosis.tokenfactory.v1beta1.QueryParamsResponse") proto.RegisterType((*QueryDenomAuthorityMetadataRequest)(nil), "osmosis.tokenfactory.v1beta1.QueryDenomAuthorityMetadataRequest") proto.RegisterType((*QueryDenomAuthorityMetadataResponse)(nil), "osmosis.tokenfactory.v1beta1.QueryDenomAuthorityMetadataResponse") proto.RegisterType((*QueryDenomsFromCreatorRequest)(nil), "osmosis.tokenfactory.v1beta1.QueryDenomsFromCreatorRequest") proto.RegisterType((*QueryDenomsFromCreatorResponse)(nil), "osmosis.tokenfactory.v1beta1.QueryDenomsFromCreatorResponse") } func init() { proto.RegisterFile("osmosis/tokenfactory/v1beta1/query.proto", fileDescriptor_6f22013ad0f72e3f) } var fileDescriptor_6f22013ad0f72e3f = []byte{ // 575 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x54, 0x4d, 0x6f, 0x13, 0x31, 0x10, 0xcd, 0x42, 0x1b, 0x54, 0xf3, 0x21, 0x62, 0x2a, 0x04, 0x51, 0xd9, 0x80, 0xa9, 0xaa, 0x14, 0x55, 0x6b, 0x52, 0x72, 0xa2, 0x20, 0xc8, 0x06, 0xc1, 0x01, 0x8a, 0x60, 0x6f, 0x70, 0x89, 0x9c, 0xd4, 0xdd, 0x2e, 0x74, 0x77, 0xb6, 0xb6, 0x83, 0x88, 0xaa, 0x5e, 0x38, 0x70, 0x46, 0xe2, 0xc8, 0x7f, 0xe0, 0x77, 0xf4, 0x58, 0xa9, 0x17, 0x4e, 0x11, 0x4a, 0x2a, 0x7e, 0x40, 0x7e, 0x01, 0x8a, 0xed, 0x96, 0x96, 0x84, 0x55, 0x80, 0x53, 0x56, 0x9e, 0xf7, 0xde, 0xbc, 0x37, 0x33, 0x0a, 0x2a, 0x83, 0x8c, 0x41, 0x46, 0x92, 0x2a, 0x78, 0xcb, 0x93, 0x75, 0xd6, 0x52, 0x20, 0x3a, 0xf4, 0x5d, 0xa5, 0xc9, 0x15, 0xab, 0xd0, 0xad, 0x36, 0x17, 0x1d, 0x2f, 0x15, 0xa0, 0x00, 0xcf, 0x59, 0xa4, 0x77, 0x1c, 0xe9, 0x59, 0x64, 0x71, 0x36, 0x84, 0x10, 0x34, 0x90, 0x0e, 0xbf, 0x0c, 0xa7, 0x38, 0x17, 0x02, 0x84, 0x9b, 0x9c, 0xb2, 0x34, 0xa2, 0x2c, 0x49, 0x40, 0x31, 0x15, 0x41, 0x22, 0x6d, 0xf5, 0x56, 0x4b, 0x4b, 0xd2, 0x26, 0x93, 0xdc, 0xb4, 0x3a, 0x6a, 0x9c, 0xb2, 0x30, 0x4a, 0x34, 0xd8, 0x62, 0xab, 0x99, 0x3e, 0x59, 0x5b, 0x6d, 0x80, 0x88, 0x54, 0x67, 0x95, 0x2b, 0xb6, 0xc6, 0x14, 0xb3, 0xac, 0xc5, 0x4c, 0x56, 0xca, 0x04, 0x8b, 0xad, 0x19, 0x32, 0x8b, 0xf0, 0xcb, 0xa1, 0x85, 0x17, 0xfa, 0x31, 0xe0, 0x5b, 0x6d, 0x2e, 0x15, 0x79, 0x85, 0x2e, 0x9d, 0x78, 0x95, 0x29, 0x24, 0x92, 0x63, 0x1f, 0xe5, 0x0d, 0xf9, 0x8a, 0x73, 0xdd, 0x29, 0x9f, 0x5d, 0x9e, 0xf7, 0xb2, 0x86, 0xe3, 0x19, 0xb6, 0x3f, 0xb5, 0xdb, 0x2d, 0xe5, 0x02, 0xcb, 0x24, 0xcf, 0x10, 0xd1, 0xd2, 0x8f, 0x78, 0x02, 0x71, 0xed, 0xf7, 0x00, 0xd6, 0x00, 0x5e, 0x40, 0xd3, 0x6b, 0x43, 0x80, 0x6e, 0x34, 0xe3, 0x5f, 0x1c, 0x74, 0x4b, 0xe7, 0x3a, 0x2c, 0xde, 0xbc, 0x4b, 0xf4, 0x33, 0x09, 0x4c, 0x99, 0x7c, 0x75, 0xd0, 0xcd, 0x4c, 0x39, 0xeb, 0xfc, 0xa3, 0x83, 0xf0, 0xd1, 0xb4, 0x1a, 0xb1, 0x2d, 0xdb, 0x18, 0xd5, 0xec, 0x18, 0xe3, 0xa5, 0xfd, 0x1b, 0xc3, 0x58, 0x83, 0x6e, 0xe9, 0xaa, 0xf1, 0x35, 0xaa, 0x4e, 0x82, 0xc2, 0xc8, 0x82, 0xc8, 0x2a, 0xba, 0xf6, 0xcb, 0xaf, 0x7c, 0x2c, 0x20, 0xae, 0x0b, 0xce, 0x14, 0x88, 0xc3, 0xe4, 0x4b, 0xe8, 0x4c, 0xcb, 0xbc, 0xd8, 0xec, 0x78, 0xd0, 0x2d, 0x5d, 0x30, 0x3d, 0x6c, 0x81, 0x04, 0x87, 0x10, 0xf2, 0x14, 0xb9, 0x7f, 0x92, 0xb3, 0xc9, 0x17, 0x51, 0x5e, 0x8f, 0x6a, 0xb8, 0xb3, 0xd3, 0xe5, 0x19, 0xbf, 0x30, 0xe8, 0x96, 0xce, 0x1f, 0x1b, 0xa5, 0x24, 0x81, 0x05, 0x2c, 0x1f, 0x4c, 0xa1, 0x69, 0xad, 0x86, 0xbf, 0x38, 0x28, 0x6f, 0xb6, 0x87, 0x6f, 0x67, 0x0f, 0x67, 0xf4, 0x78, 0x8a, 0x95, 0xbf, 0x60, 0x18, 0x93, 0x64, 0xe9, 0xc3, 0xfe, 0xc1, 0xe7, 0x53, 0x0b, 0x78, 0x9e, 0x4e, 0x70, 0xb9, 0xf8, 0x87, 0x83, 0x2e, 0x8f, 0x5f, 0x0a, 0x7e, 0x38, 0x41, 0xef, 0xcc, 0xcb, 0x2b, 0xd6, 0xfe, 0x43, 0xc1, 0xa6, 0x79, 0xa2, 0xd3, 0xd4, 0xf0, 0x83, 0xec, 0x34, 0x66, 0xea, 0x74, 0x5b, 0xff, 0xee, 0xd0, 0xd1, 0x03, 0xc2, 0xfb, 0x0e, 0x2a, 0x8c, 0x6c, 0x16, 0xaf, 0x4c, 0xea, 0x70, 0xcc, 0x79, 0x15, 0xef, 0xfd, 0x1b, 0xd9, 0x26, 0xab, 0xeb, 0x64, 0xf7, 0xf1, 0xca, 0x24, 0xc9, 0x1a, 0xeb, 0x02, 0xe2, 0x86, 0xbd, 0x54, 0xba, 0x6d, 0x3f, 0x76, 0xfc, 0xe7, 0xbb, 0x3d, 0xd7, 0xd9, 0xeb, 0xb9, 0xce, 0xf7, 0x9e, 0xeb, 0x7c, 0xea, 0xbb, 0xb9, 0xbd, 0xbe, 0x9b, 0xfb, 0xd6, 0x77, 0x73, 0xaf, 0xab, 0x61, 0xa4, 0x36, 0xda, 0x4d, 0xaf, 0x05, 0x31, 0xad, 0xeb, 0x0e, 0x75, 0x48, 0x94, 0x60, 0x2d, 0x25, 0xe9, 0x9b, 0x76, 0x02, 0xf4, 0xfd, 0xc9, 0x7e, 0xaa, 0x93, 0x72, 0xd9, 0xcc, 0xeb, 0x7f, 0xb2, 0x3b, 0x3f, 0x03, 0x00, 0x00, 0xff, 0xff, 0xa7, 0x10, 0x27, 0x8d, 0xd4, 0x05, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. var _ context.Context var _ grpc.ClientConn // This is a compile-time assertion to ensure that this generated file // is compatible with the grpc package it is being compiled against. const _ = grpc.SupportPackageIsVersion4 // QueryClient is the client API for Query service. // // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. type QueryClient interface { // Params defines a gRPC query method that returns the tokenfactory module's // parameters. Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) // DenomAuthorityMetadata defines a gRPC query method for fetching // DenomAuthorityMetadata for a particular denom. DenomAuthorityMetadata(ctx context.Context, in *QueryDenomAuthorityMetadataRequest, opts ...grpc.CallOption) (*QueryDenomAuthorityMetadataResponse, error) // DenomsFromCreator defines a gRPC query method for fetching all // denominations created by a specific admin/creator. DenomsFromCreator(ctx context.Context, in *QueryDenomsFromCreatorRequest, opts ...grpc.CallOption) (*QueryDenomsFromCreatorResponse, error) } type queryClient struct { cc grpc1.ClientConn } func NewQueryClient(cc grpc1.ClientConn) QueryClient { return &queryClient{cc} } func (c *queryClient) Params(ctx context.Context, in *QueryParamsRequest, opts ...grpc.CallOption) (*QueryParamsResponse, error) { out := new(QueryParamsResponse) err := c.cc.Invoke(ctx, "/osmosis.tokenfactory.v1beta1.Query/Params", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) DenomAuthorityMetadata(ctx context.Context, in *QueryDenomAuthorityMetadataRequest, opts ...grpc.CallOption) (*QueryDenomAuthorityMetadataResponse, error) { out := new(QueryDenomAuthorityMetadataResponse) err := c.cc.Invoke(ctx, "/osmosis.tokenfactory.v1beta1.Query/DenomAuthorityMetadata", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *queryClient) DenomsFromCreator(ctx context.Context, in *QueryDenomsFromCreatorRequest, opts ...grpc.CallOption) (*QueryDenomsFromCreatorResponse, error) { out := new(QueryDenomsFromCreatorResponse) err := c.cc.Invoke(ctx, "/osmosis.tokenfactory.v1beta1.Query/DenomsFromCreator", in, out, opts...) if err != nil { return nil, err } return out, nil } // QueryServer is the server API for Query service. type QueryServer interface { // Params defines a gRPC query method that returns the tokenfactory module's // parameters. Params(context.Context, *QueryParamsRequest) (*QueryParamsResponse, error) // DenomAuthorityMetadata defines a gRPC query method for fetching // DenomAuthorityMetadata for a particular denom. DenomAuthorityMetadata(context.Context, *QueryDenomAuthorityMetadataRequest) (*QueryDenomAuthorityMetadataResponse, error) // DenomsFromCreator defines a gRPC query method for fetching all // denominations created by a specific admin/creator. DenomsFromCreator(context.Context, *QueryDenomsFromCreatorRequest) (*QueryDenomsFromCreatorResponse, error) } // UnimplementedQueryServer can be embedded to have forward compatible implementations. type UnimplementedQueryServer struct { } func (*UnimplementedQueryServer) Params(ctx context.Context, req *QueryParamsRequest) (*QueryParamsResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method Params not implemented") } func (*UnimplementedQueryServer) DenomAuthorityMetadata(ctx context.Context, req *QueryDenomAuthorityMetadataRequest) (*QueryDenomAuthorityMetadataResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method DenomAuthorityMetadata not implemented") } func (*UnimplementedQueryServer) DenomsFromCreator(ctx context.Context, req *QueryDenomsFromCreatorRequest) (*QueryDenomsFromCreatorResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method DenomsFromCreator not implemented") } func RegisterQueryServer(s grpc1.Server, srv QueryServer) { s.RegisterService(&_Query_serviceDesc, srv) } func _Query_Params_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryParamsRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).Params(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/osmosis.tokenfactory.v1beta1.Query/Params", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).Params(ctx, req.(*QueryParamsRequest)) } return interceptor(ctx, in, info, handler) } func _Query_DenomAuthorityMetadata_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryDenomAuthorityMetadataRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).DenomAuthorityMetadata(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/osmosis.tokenfactory.v1beta1.Query/DenomAuthorityMetadata", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).DenomAuthorityMetadata(ctx, req.(*QueryDenomAuthorityMetadataRequest)) } return interceptor(ctx, in, info, handler) } func _Query_DenomsFromCreator_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(QueryDenomsFromCreatorRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(QueryServer).DenomsFromCreator(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/osmosis.tokenfactory.v1beta1.Query/DenomsFromCreator", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(QueryServer).DenomsFromCreator(ctx, req.(*QueryDenomsFromCreatorRequest)) } return interceptor(ctx, in, info, handler) } var _Query_serviceDesc = grpc.ServiceDesc{ ServiceName: "osmosis.tokenfactory.v1beta1.Query", HandlerType: (*QueryServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "Params", Handler: _Query_Params_Handler, }, { MethodName: "DenomAuthorityMetadata", Handler: _Query_DenomAuthorityMetadata_Handler, }, { MethodName: "DenomsFromCreator", Handler: _Query_DenomsFromCreator_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "osmosis/tokenfactory/v1beta1/query.proto", } func (m *QueryParamsRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryParamsRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryParamsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *QueryParamsResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryParamsResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryParamsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.Params.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa return len(dAtA) - i, nil } func (m *QueryDenomAuthorityMetadataRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryDenomAuthorityMetadataRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryDenomAuthorityMetadataRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.Denom) > 0 { i -= len(m.Denom) copy(dAtA[i:], m.Denom) i = encodeVarintQuery(dAtA, i, uint64(len(m.Denom))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *QueryDenomAuthorityMetadataResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryDenomAuthorityMetadataResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryDenomAuthorityMetadataResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.AuthorityMetadata.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintQuery(dAtA, i, uint64(size)) } i-- dAtA[i] = 0xa return len(dAtA) - i, nil } func (m *QueryDenomsFromCreatorRequest) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryDenomsFromCreatorRequest) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryDenomsFromCreatorRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.Creator) > 0 { i -= len(m.Creator) copy(dAtA[i:], m.Creator) i = encodeVarintQuery(dAtA, i, uint64(len(m.Creator))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *QueryDenomsFromCreatorResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *QueryDenomsFromCreatorResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *QueryDenomsFromCreatorResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.Denoms) > 0 { for iNdEx := len(m.Denoms) - 1; iNdEx >= 0; iNdEx-- { i -= len(m.Denoms[iNdEx]) copy(dAtA[i:], m.Denoms[iNdEx]) i = encodeVarintQuery(dAtA, i, uint64(len(m.Denoms[iNdEx]))) i-- dAtA[i] = 0xa } } return len(dAtA) - i, nil } func encodeVarintQuery(dAtA []byte, offset int, v uint64) int { offset -= sovQuery(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *QueryParamsRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *QueryParamsResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l l = m.Params.Size() n += 1 + l + sovQuery(uint64(l)) return n } func (m *QueryDenomAuthorityMetadataRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Denom) if l > 0 { n += 1 + l + sovQuery(uint64(l)) } return n } func (m *QueryDenomAuthorityMetadataResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l l = m.AuthorityMetadata.Size() n += 1 + l + sovQuery(uint64(l)) return n } func (m *QueryDenomsFromCreatorRequest) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Creator) if l > 0 { n += 1 + l + sovQuery(uint64(l)) } return n } func (m *QueryDenomsFromCreatorResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l if len(m.Denoms) > 0 { for _, s := range m.Denoms { l = len(s) n += 1 + l + sovQuery(uint64(l)) } } return n } func sovQuery(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozQuery(x uint64) (n int) { return sovQuery(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *QueryParamsRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryParamsRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryParamsRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryParamsResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryParamsResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryParamsResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Params.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryDenomAuthorityMetadataRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryDenomAuthorityMetadataRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryDenomAuthorityMetadataRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Denom", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } m.Denom = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryDenomAuthorityMetadataResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryDenomAuthorityMetadataResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryDenomAuthorityMetadataResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field AuthorityMetadata", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.AuthorityMetadata.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryDenomsFromCreatorRequest) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryDenomsFromCreatorRequest: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryDenomsFromCreatorRequest: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } m.Creator = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *QueryDenomsFromCreatorResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: QueryDenomsFromCreatorResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: QueryDenomsFromCreatorResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Denoms", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowQuery } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthQuery } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthQuery } if postIndex > l { return io.ErrUnexpectedEOF } m.Denoms = append(m.Denoms, string(dAtA[iNdEx:postIndex])) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipQuery(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthQuery } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipQuery(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowQuery } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowQuery } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowQuery } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthQuery } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupQuery } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthQuery } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthQuery = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowQuery = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupQuery = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/tokenfactory/types/query.pb.gw.go ================================================ // Code generated by protoc-gen-grpc-gateway. DO NOT EDIT. // source: osmosis/tokenfactory/v1beta1/query.proto /* Package types is a reverse proxy. It translates gRPC into RESTful JSON APIs. */ package types import ( "context" "io" "net/http" "github.com/golang/protobuf/descriptor" "github.com/golang/protobuf/proto" "github.com/grpc-ecosystem/grpc-gateway/runtime" "github.com/grpc-ecosystem/grpc-gateway/utilities" "google.golang.org/grpc" "google.golang.org/grpc/codes" "google.golang.org/grpc/grpclog" "google.golang.org/grpc/metadata" "google.golang.org/grpc/status" ) // Suppress "imported and not used" errors var _ codes.Code var _ io.Reader var _ status.Status var _ = runtime.String var _ = utilities.NewDoubleArray var _ = descriptor.ForMessage var _ = metadata.Join func request_Query_Params_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryParamsRequest var metadata runtime.ServerMetadata msg, err := client.Params(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_Params_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryParamsRequest var metadata runtime.ServerMetadata msg, err := server.Params(ctx, &protoReq) return msg, metadata, err } func request_Query_DenomAuthorityMetadata_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryDenomAuthorityMetadataRequest var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["denom"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "denom") } protoReq.Denom, err = runtime.String(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "denom", err) } msg, err := client.DenomAuthorityMetadata(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_DenomAuthorityMetadata_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryDenomAuthorityMetadataRequest var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["denom"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "denom") } protoReq.Denom, err = runtime.String(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "denom", err) } msg, err := server.DenomAuthorityMetadata(ctx, &protoReq) return msg, metadata, err } func request_Query_DenomsFromCreator_0(ctx context.Context, marshaler runtime.Marshaler, client QueryClient, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryDenomsFromCreatorRequest var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["creator"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "creator") } protoReq.Creator, err = runtime.String(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "creator", err) } msg, err := client.DenomsFromCreator(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD)) return msg, metadata, err } func local_request_Query_DenomsFromCreator_0(ctx context.Context, marshaler runtime.Marshaler, server QueryServer, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) { var protoReq QueryDenomsFromCreatorRequest var metadata runtime.ServerMetadata var ( val string ok bool err error _ = err ) val, ok = pathParams["creator"] if !ok { return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "creator") } protoReq.Creator, err = runtime.String(val) if err != nil { return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "creator", err) } msg, err := server.DenomsFromCreator(ctx, &protoReq) return msg, metadata, err } // RegisterQueryHandlerServer registers the http handlers for service Query to "mux". // UnaryRPC :call QueryServer directly. // StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. // Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterQueryHandlerFromEndpoint instead. func RegisterQueryHandlerServer(ctx context.Context, mux *runtime.ServeMux, server QueryServer) error { mux.Handle("GET", pattern_Query_Params_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_Params_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Params_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_DenomAuthorityMetadata_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_DenomAuthorityMetadata_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_DenomAuthorityMetadata_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_DenomsFromCreator_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() var stream runtime.ServerTransportStream ctx = grpc.NewContextWithServerTransportStream(ctx, &stream) inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := local_request_Query_DenomsFromCreator_0(rctx, inboundMarshaler, server, req, pathParams) md.HeaderMD, md.TrailerMD = metadata.Join(md.HeaderMD, stream.Header()), metadata.Join(md.TrailerMD, stream.Trailer()) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_DenomsFromCreator_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) return nil } // RegisterQueryHandlerFromEndpoint is same as RegisterQueryHandler but // automatically dials to "endpoint" and closes the connection when "ctx" gets done. func RegisterQueryHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error) { conn, err := grpc.Dial(endpoint, opts...) if err != nil { return err } defer func() { if err != nil { if cerr := conn.Close(); cerr != nil { grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr) } return } go func() { <-ctx.Done() if cerr := conn.Close(); cerr != nil { grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr) } }() }() return RegisterQueryHandler(ctx, mux, conn) } // RegisterQueryHandler registers the http handlers for service Query to "mux". // The handlers forward requests to the grpc endpoint over "conn". func RegisterQueryHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error { return RegisterQueryHandlerClient(ctx, mux, NewQueryClient(conn)) } // RegisterQueryHandlerClient registers the http handlers for service Query // to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "QueryClient". // Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "QueryClient" // doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in // "QueryClient" to call the correct interceptors. func RegisterQueryHandlerClient(ctx context.Context, mux *runtime.ServeMux, client QueryClient) error { mux.Handle("GET", pattern_Query_Params_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_Params_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_Params_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_DenomAuthorityMetadata_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_DenomAuthorityMetadata_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_DenomAuthorityMetadata_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) mux.Handle("GET", pattern_Query_DenomsFromCreator_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) { ctx, cancel := context.WithCancel(req.Context()) defer cancel() inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req) rctx, err := runtime.AnnotateContext(ctx, mux, req) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } resp, md, err := request_Query_DenomsFromCreator_0(rctx, inboundMarshaler, client, req, pathParams) ctx = runtime.NewServerMetadataContext(ctx, md) if err != nil { runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err) return } forward_Query_DenomsFromCreator_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...) }) return nil } var ( pattern_Query_Params_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"osmosis", "tokenfactory", "v1beta1", "params"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_DenomAuthorityMetadata_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4, 2, 5}, []string{"osmosis", "tokenfactory", "v1beta1", "denoms", "denom", "authority_metadata"}, "", runtime.AssumeColonVerbOpt(false))) pattern_Query_DenomsFromCreator_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3, 1, 0, 4, 1, 5, 4}, []string{"osmosis", "tokenfactory", "v1beta1", "denoms_from_creator", "creator"}, "", runtime.AssumeColonVerbOpt(false))) ) var ( forward_Query_Params_0 = runtime.ForwardResponseMessage forward_Query_DenomAuthorityMetadata_0 = runtime.ForwardResponseMessage forward_Query_DenomsFromCreator_0 = runtime.ForwardResponseMessage ) ================================================ FILE: x/tokenfactory/types/tx.pb.go ================================================ // Code generated by protoc-gen-gogo. DO NOT EDIT. // source: osmosis/tokenfactory/v1beta1/tx.proto package types import ( context "context" fmt "fmt" _ "github.com/cosmos/cosmos-proto" types "github.com/cosmos/cosmos-sdk/types" _ "github.com/cosmos/cosmos-sdk/types/msgservice" types1 "github.com/cosmos/cosmos-sdk/x/bank/types" _ "github.com/cosmos/gogoproto/gogoproto" grpc1 "github.com/cosmos/gogoproto/grpc" proto "github.com/cosmos/gogoproto/proto" grpc "google.golang.org/grpc" codes "google.golang.org/grpc/codes" status "google.golang.org/grpc/status" io "io" math "math" math_bits "math/bits" ) // Reference imports to suppress errors if they are not otherwise used. var _ = proto.Marshal var _ = fmt.Errorf var _ = math.Inf // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package // MsgCreateDenom defines the message structure for the CreateDenom gRPC service // method. It allows an account to create a new denom. It requires a sender // address and a sub denomination. The (sender_address, sub_denomination) tuple // must be unique and cannot be re-used. // // The resulting denom created is defined as // . The resulting denom's admin is // originally set to be the creator, but this can be changed later. The token // denom does not indicate the current admin. type MsgCreateDenom struct { Sender string `protobuf:"bytes,1,opt,name=sender,proto3" json:"sender,omitempty" yaml:"sender"` // subdenom can be up to 44 "alphanumeric" characters long. Subdenom string `protobuf:"bytes,2,opt,name=subdenom,proto3" json:"subdenom,omitempty" yaml:"subdenom"` } func (m *MsgCreateDenom) Reset() { *m = MsgCreateDenom{} } func (m *MsgCreateDenom) String() string { return proto.CompactTextString(m) } func (*MsgCreateDenom) ProtoMessage() {} func (*MsgCreateDenom) Descriptor() ([]byte, []int) { return fileDescriptor_283b6c9a90a846b4, []int{0} } func (m *MsgCreateDenom) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgCreateDenom) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgCreateDenom.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgCreateDenom) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgCreateDenom.Merge(m, src) } func (m *MsgCreateDenom) XXX_Size() int { return m.Size() } func (m *MsgCreateDenom) XXX_DiscardUnknown() { xxx_messageInfo_MsgCreateDenom.DiscardUnknown(m) } var xxx_messageInfo_MsgCreateDenom proto.InternalMessageInfo func (m *MsgCreateDenom) GetSender() string { if m != nil { return m.Sender } return "" } func (m *MsgCreateDenom) GetSubdenom() string { if m != nil { return m.Subdenom } return "" } // MsgCreateDenomResponse is the return value of MsgCreateDenom // It returns the full string of the newly created denom type MsgCreateDenomResponse struct { NewTokenDenom string `protobuf:"bytes,1,opt,name=new_token_denom,json=newTokenDenom,proto3" json:"new_token_denom,omitempty" yaml:"new_token_denom"` } func (m *MsgCreateDenomResponse) Reset() { *m = MsgCreateDenomResponse{} } func (m *MsgCreateDenomResponse) String() string { return proto.CompactTextString(m) } func (*MsgCreateDenomResponse) ProtoMessage() {} func (*MsgCreateDenomResponse) Descriptor() ([]byte, []int) { return fileDescriptor_283b6c9a90a846b4, []int{1} } func (m *MsgCreateDenomResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgCreateDenomResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgCreateDenomResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgCreateDenomResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgCreateDenomResponse.Merge(m, src) } func (m *MsgCreateDenomResponse) XXX_Size() int { return m.Size() } func (m *MsgCreateDenomResponse) XXX_DiscardUnknown() { xxx_messageInfo_MsgCreateDenomResponse.DiscardUnknown(m) } var xxx_messageInfo_MsgCreateDenomResponse proto.InternalMessageInfo func (m *MsgCreateDenomResponse) GetNewTokenDenom() string { if m != nil { return m.NewTokenDenom } return "" } // MsgMint is the sdk.Msg type for allowing an admin account to mint // more of a token. For now, we only support minting to the sender account type MsgMint struct { Sender string `protobuf:"bytes,1,opt,name=sender,proto3" json:"sender,omitempty" yaml:"sender"` Amount types.Coin `protobuf:"bytes,2,opt,name=amount,proto3" json:"amount" yaml:"amount"` MintToAddress string `protobuf:"bytes,3,opt,name=mintToAddress,proto3" json:"mintToAddress,omitempty" yaml:"mint_to_address"` } func (m *MsgMint) Reset() { *m = MsgMint{} } func (m *MsgMint) String() string { return proto.CompactTextString(m) } func (*MsgMint) ProtoMessage() {} func (*MsgMint) Descriptor() ([]byte, []int) { return fileDescriptor_283b6c9a90a846b4, []int{2} } func (m *MsgMint) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgMint) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgMint.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgMint) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgMint.Merge(m, src) } func (m *MsgMint) XXX_Size() int { return m.Size() } func (m *MsgMint) XXX_DiscardUnknown() { xxx_messageInfo_MsgMint.DiscardUnknown(m) } var xxx_messageInfo_MsgMint proto.InternalMessageInfo func (m *MsgMint) GetSender() string { if m != nil { return m.Sender } return "" } func (m *MsgMint) GetAmount() types.Coin { if m != nil { return m.Amount } return types.Coin{} } func (m *MsgMint) GetMintToAddress() string { if m != nil { return m.MintToAddress } return "" } type MsgMintResponse struct { } func (m *MsgMintResponse) Reset() { *m = MsgMintResponse{} } func (m *MsgMintResponse) String() string { return proto.CompactTextString(m) } func (*MsgMintResponse) ProtoMessage() {} func (*MsgMintResponse) Descriptor() ([]byte, []int) { return fileDescriptor_283b6c9a90a846b4, []int{3} } func (m *MsgMintResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgMintResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgMintResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgMintResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgMintResponse.Merge(m, src) } func (m *MsgMintResponse) XXX_Size() int { return m.Size() } func (m *MsgMintResponse) XXX_DiscardUnknown() { xxx_messageInfo_MsgMintResponse.DiscardUnknown(m) } var xxx_messageInfo_MsgMintResponse proto.InternalMessageInfo // MsgBurn is the sdk.Msg type for allowing an admin account to burn // a token. For now, we only support burning from the sender account. type MsgBurn struct { Sender string `protobuf:"bytes,1,opt,name=sender,proto3" json:"sender,omitempty" yaml:"sender"` Amount types.Coin `protobuf:"bytes,2,opt,name=amount,proto3" json:"amount" yaml:"amount"` BurnFromAddress string `protobuf:"bytes,3,opt,name=burnFromAddress,proto3" json:"burnFromAddress,omitempty" yaml:"burn_from_address"` } func (m *MsgBurn) Reset() { *m = MsgBurn{} } func (m *MsgBurn) String() string { return proto.CompactTextString(m) } func (*MsgBurn) ProtoMessage() {} func (*MsgBurn) Descriptor() ([]byte, []int) { return fileDescriptor_283b6c9a90a846b4, []int{4} } func (m *MsgBurn) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgBurn) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgBurn.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgBurn) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgBurn.Merge(m, src) } func (m *MsgBurn) XXX_Size() int { return m.Size() } func (m *MsgBurn) XXX_DiscardUnknown() { xxx_messageInfo_MsgBurn.DiscardUnknown(m) } var xxx_messageInfo_MsgBurn proto.InternalMessageInfo func (m *MsgBurn) GetSender() string { if m != nil { return m.Sender } return "" } func (m *MsgBurn) GetAmount() types.Coin { if m != nil { return m.Amount } return types.Coin{} } func (m *MsgBurn) GetBurnFromAddress() string { if m != nil { return m.BurnFromAddress } return "" } type MsgBurnResponse struct { } func (m *MsgBurnResponse) Reset() { *m = MsgBurnResponse{} } func (m *MsgBurnResponse) String() string { return proto.CompactTextString(m) } func (*MsgBurnResponse) ProtoMessage() {} func (*MsgBurnResponse) Descriptor() ([]byte, []int) { return fileDescriptor_283b6c9a90a846b4, []int{5} } func (m *MsgBurnResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgBurnResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgBurnResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgBurnResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgBurnResponse.Merge(m, src) } func (m *MsgBurnResponse) XXX_Size() int { return m.Size() } func (m *MsgBurnResponse) XXX_DiscardUnknown() { xxx_messageInfo_MsgBurnResponse.DiscardUnknown(m) } var xxx_messageInfo_MsgBurnResponse proto.InternalMessageInfo // MsgChangeAdmin is the sdk.Msg type for allowing an admin account to reassign // adminship of a denom to a new account type MsgChangeAdmin struct { Sender string `protobuf:"bytes,1,opt,name=sender,proto3" json:"sender,omitempty" yaml:"sender"` Denom string `protobuf:"bytes,2,opt,name=denom,proto3" json:"denom,omitempty" yaml:"denom"` NewAdmin string `protobuf:"bytes,3,opt,name=new_admin,json=newAdmin,proto3" json:"new_admin,omitempty" yaml:"new_admin"` } func (m *MsgChangeAdmin) Reset() { *m = MsgChangeAdmin{} } func (m *MsgChangeAdmin) String() string { return proto.CompactTextString(m) } func (*MsgChangeAdmin) ProtoMessage() {} func (*MsgChangeAdmin) Descriptor() ([]byte, []int) { return fileDescriptor_283b6c9a90a846b4, []int{6} } func (m *MsgChangeAdmin) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgChangeAdmin) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgChangeAdmin.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgChangeAdmin) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgChangeAdmin.Merge(m, src) } func (m *MsgChangeAdmin) XXX_Size() int { return m.Size() } func (m *MsgChangeAdmin) XXX_DiscardUnknown() { xxx_messageInfo_MsgChangeAdmin.DiscardUnknown(m) } var xxx_messageInfo_MsgChangeAdmin proto.InternalMessageInfo func (m *MsgChangeAdmin) GetSender() string { if m != nil { return m.Sender } return "" } func (m *MsgChangeAdmin) GetDenom() string { if m != nil { return m.Denom } return "" } func (m *MsgChangeAdmin) GetNewAdmin() string { if m != nil { return m.NewAdmin } return "" } // MsgChangeAdminResponse defines the response structure for an executed // MsgChangeAdmin message. type MsgChangeAdminResponse struct { } func (m *MsgChangeAdminResponse) Reset() { *m = MsgChangeAdminResponse{} } func (m *MsgChangeAdminResponse) String() string { return proto.CompactTextString(m) } func (*MsgChangeAdminResponse) ProtoMessage() {} func (*MsgChangeAdminResponse) Descriptor() ([]byte, []int) { return fileDescriptor_283b6c9a90a846b4, []int{7} } func (m *MsgChangeAdminResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgChangeAdminResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgChangeAdminResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgChangeAdminResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgChangeAdminResponse.Merge(m, src) } func (m *MsgChangeAdminResponse) XXX_Size() int { return m.Size() } func (m *MsgChangeAdminResponse) XXX_DiscardUnknown() { xxx_messageInfo_MsgChangeAdminResponse.DiscardUnknown(m) } var xxx_messageInfo_MsgChangeAdminResponse proto.InternalMessageInfo // MsgSetDenomMetadata is the sdk.Msg type for allowing an admin account to set // the denom's bank metadata type MsgSetDenomMetadata struct { Sender string `protobuf:"bytes,1,opt,name=sender,proto3" json:"sender,omitempty" yaml:"sender"` Metadata types1.Metadata `protobuf:"bytes,2,opt,name=metadata,proto3" json:"metadata" yaml:"metadata"` } func (m *MsgSetDenomMetadata) Reset() { *m = MsgSetDenomMetadata{} } func (m *MsgSetDenomMetadata) String() string { return proto.CompactTextString(m) } func (*MsgSetDenomMetadata) ProtoMessage() {} func (*MsgSetDenomMetadata) Descriptor() ([]byte, []int) { return fileDescriptor_283b6c9a90a846b4, []int{8} } func (m *MsgSetDenomMetadata) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgSetDenomMetadata) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgSetDenomMetadata.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgSetDenomMetadata) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgSetDenomMetadata.Merge(m, src) } func (m *MsgSetDenomMetadata) XXX_Size() int { return m.Size() } func (m *MsgSetDenomMetadata) XXX_DiscardUnknown() { xxx_messageInfo_MsgSetDenomMetadata.DiscardUnknown(m) } var xxx_messageInfo_MsgSetDenomMetadata proto.InternalMessageInfo func (m *MsgSetDenomMetadata) GetSender() string { if m != nil { return m.Sender } return "" } func (m *MsgSetDenomMetadata) GetMetadata() types1.Metadata { if m != nil { return m.Metadata } return types1.Metadata{} } // MsgSetDenomMetadataResponse defines the response structure for an executed // MsgSetDenomMetadata message. type MsgSetDenomMetadataResponse struct { } func (m *MsgSetDenomMetadataResponse) Reset() { *m = MsgSetDenomMetadataResponse{} } func (m *MsgSetDenomMetadataResponse) String() string { return proto.CompactTextString(m) } func (*MsgSetDenomMetadataResponse) ProtoMessage() {} func (*MsgSetDenomMetadataResponse) Descriptor() ([]byte, []int) { return fileDescriptor_283b6c9a90a846b4, []int{9} } func (m *MsgSetDenomMetadataResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgSetDenomMetadataResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgSetDenomMetadataResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgSetDenomMetadataResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgSetDenomMetadataResponse.Merge(m, src) } func (m *MsgSetDenomMetadataResponse) XXX_Size() int { return m.Size() } func (m *MsgSetDenomMetadataResponse) XXX_DiscardUnknown() { xxx_messageInfo_MsgSetDenomMetadataResponse.DiscardUnknown(m) } var xxx_messageInfo_MsgSetDenomMetadataResponse proto.InternalMessageInfo type MsgForceTransfer struct { Sender string `protobuf:"bytes,1,opt,name=sender,proto3" json:"sender,omitempty" yaml:"sender"` Amount types.Coin `protobuf:"bytes,2,opt,name=amount,proto3" json:"amount" yaml:"amount"` TransferFromAddress string `protobuf:"bytes,3,opt,name=transferFromAddress,proto3" json:"transferFromAddress,omitempty" yaml:"transfer_from_address"` TransferToAddress string `protobuf:"bytes,4,opt,name=transferToAddress,proto3" json:"transferToAddress,omitempty" yaml:"transfer_to_address"` } func (m *MsgForceTransfer) Reset() { *m = MsgForceTransfer{} } func (m *MsgForceTransfer) String() string { return proto.CompactTextString(m) } func (*MsgForceTransfer) ProtoMessage() {} func (*MsgForceTransfer) Descriptor() ([]byte, []int) { return fileDescriptor_283b6c9a90a846b4, []int{10} } func (m *MsgForceTransfer) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgForceTransfer) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgForceTransfer.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgForceTransfer) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgForceTransfer.Merge(m, src) } func (m *MsgForceTransfer) XXX_Size() int { return m.Size() } func (m *MsgForceTransfer) XXX_DiscardUnknown() { xxx_messageInfo_MsgForceTransfer.DiscardUnknown(m) } var xxx_messageInfo_MsgForceTransfer proto.InternalMessageInfo func (m *MsgForceTransfer) GetSender() string { if m != nil { return m.Sender } return "" } func (m *MsgForceTransfer) GetAmount() types.Coin { if m != nil { return m.Amount } return types.Coin{} } func (m *MsgForceTransfer) GetTransferFromAddress() string { if m != nil { return m.TransferFromAddress } return "" } func (m *MsgForceTransfer) GetTransferToAddress() string { if m != nil { return m.TransferToAddress } return "" } type MsgForceTransferResponse struct { } func (m *MsgForceTransferResponse) Reset() { *m = MsgForceTransferResponse{} } func (m *MsgForceTransferResponse) String() string { return proto.CompactTextString(m) } func (*MsgForceTransferResponse) ProtoMessage() {} func (*MsgForceTransferResponse) Descriptor() ([]byte, []int) { return fileDescriptor_283b6c9a90a846b4, []int{11} } func (m *MsgForceTransferResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgForceTransferResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgForceTransferResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgForceTransferResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgForceTransferResponse.Merge(m, src) } func (m *MsgForceTransferResponse) XXX_Size() int { return m.Size() } func (m *MsgForceTransferResponse) XXX_DiscardUnknown() { xxx_messageInfo_MsgForceTransferResponse.DiscardUnknown(m) } var xxx_messageInfo_MsgForceTransferResponse proto.InternalMessageInfo // MsgUpdateParams is the Msg/UpdateParams request type. // // Since: cosmos-sdk 0.47 type MsgUpdateParams struct { // authority is the address of the governance account. Authority string `protobuf:"bytes,1,opt,name=authority,proto3" json:"authority,omitempty"` // params defines the x/mint parameters to update. // // NOTE: All parameters must be supplied. Params Params `protobuf:"bytes,2,opt,name=params,proto3" json:"params"` } func (m *MsgUpdateParams) Reset() { *m = MsgUpdateParams{} } func (m *MsgUpdateParams) String() string { return proto.CompactTextString(m) } func (*MsgUpdateParams) ProtoMessage() {} func (*MsgUpdateParams) Descriptor() ([]byte, []int) { return fileDescriptor_283b6c9a90a846b4, []int{12} } func (m *MsgUpdateParams) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgUpdateParams) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgUpdateParams.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgUpdateParams) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgUpdateParams.Merge(m, src) } func (m *MsgUpdateParams) XXX_Size() int { return m.Size() } func (m *MsgUpdateParams) XXX_DiscardUnknown() { xxx_messageInfo_MsgUpdateParams.DiscardUnknown(m) } var xxx_messageInfo_MsgUpdateParams proto.InternalMessageInfo func (m *MsgUpdateParams) GetAuthority() string { if m != nil { return m.Authority } return "" } func (m *MsgUpdateParams) GetParams() Params { if m != nil { return m.Params } return Params{} } // MsgUpdateParamsResponse defines the response structure for executing a // MsgUpdateParams message. // // Since: cosmos-sdk 0.47 type MsgUpdateParamsResponse struct { } func (m *MsgUpdateParamsResponse) Reset() { *m = MsgUpdateParamsResponse{} } func (m *MsgUpdateParamsResponse) String() string { return proto.CompactTextString(m) } func (*MsgUpdateParamsResponse) ProtoMessage() {} func (*MsgUpdateParamsResponse) Descriptor() ([]byte, []int) { return fileDescriptor_283b6c9a90a846b4, []int{13} } func (m *MsgUpdateParamsResponse) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) } func (m *MsgUpdateParamsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { if deterministic { return xxx_messageInfo_MsgUpdateParamsResponse.Marshal(b, m, deterministic) } else { b = b[:cap(b)] n, err := m.MarshalToSizedBuffer(b) if err != nil { return nil, err } return b[:n], nil } } func (m *MsgUpdateParamsResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_MsgUpdateParamsResponse.Merge(m, src) } func (m *MsgUpdateParamsResponse) XXX_Size() int { return m.Size() } func (m *MsgUpdateParamsResponse) XXX_DiscardUnknown() { xxx_messageInfo_MsgUpdateParamsResponse.DiscardUnknown(m) } var xxx_messageInfo_MsgUpdateParamsResponse proto.InternalMessageInfo func init() { proto.RegisterType((*MsgCreateDenom)(nil), "osmosis.tokenfactory.v1beta1.MsgCreateDenom") proto.RegisterType((*MsgCreateDenomResponse)(nil), "osmosis.tokenfactory.v1beta1.MsgCreateDenomResponse") proto.RegisterType((*MsgMint)(nil), "osmosis.tokenfactory.v1beta1.MsgMint") proto.RegisterType((*MsgMintResponse)(nil), "osmosis.tokenfactory.v1beta1.MsgMintResponse") proto.RegisterType((*MsgBurn)(nil), "osmosis.tokenfactory.v1beta1.MsgBurn") proto.RegisterType((*MsgBurnResponse)(nil), "osmosis.tokenfactory.v1beta1.MsgBurnResponse") proto.RegisterType((*MsgChangeAdmin)(nil), "osmosis.tokenfactory.v1beta1.MsgChangeAdmin") proto.RegisterType((*MsgChangeAdminResponse)(nil), "osmosis.tokenfactory.v1beta1.MsgChangeAdminResponse") proto.RegisterType((*MsgSetDenomMetadata)(nil), "osmosis.tokenfactory.v1beta1.MsgSetDenomMetadata") proto.RegisterType((*MsgSetDenomMetadataResponse)(nil), "osmosis.tokenfactory.v1beta1.MsgSetDenomMetadataResponse") proto.RegisterType((*MsgForceTransfer)(nil), "osmosis.tokenfactory.v1beta1.MsgForceTransfer") proto.RegisterType((*MsgForceTransferResponse)(nil), "osmosis.tokenfactory.v1beta1.MsgForceTransferResponse") proto.RegisterType((*MsgUpdateParams)(nil), "osmosis.tokenfactory.v1beta1.MsgUpdateParams") proto.RegisterType((*MsgUpdateParamsResponse)(nil), "osmosis.tokenfactory.v1beta1.MsgUpdateParamsResponse") } func init() { proto.RegisterFile("osmosis/tokenfactory/v1beta1/tx.proto", fileDescriptor_283b6c9a90a846b4) } var fileDescriptor_283b6c9a90a846b4 = []byte{ // 876 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xc4, 0x56, 0x4f, 0x6f, 0xdc, 0x44, 0x14, 0x8f, 0xdb, 0xb0, 0x24, 0xd3, 0xa6, 0x49, 0x9c, 0xd0, 0x6c, 0x4c, 0x6a, 0x57, 0x23, 0x8a, 0x28, 0xa2, 0xb6, 0xb6, 0x94, 0x4a, 0xf4, 0x44, 0x1d, 0x14, 0x71, 0x60, 0x11, 0x72, 0xc3, 0x05, 0x55, 0x5a, 0xcd, 0xee, 0x4e, 0x1c, 0x93, 0x7a, 0x66, 0x99, 0x99, 0x6d, 0xba, 0x37, 0xc4, 0x27, 0xe0, 0x80, 0x90, 0x38, 0xf0, 0x01, 0xb8, 0x71, 0xe0, 0x03, 0x70, 0x42, 0x3d, 0x56, 0x9c, 0x38, 0x59, 0x28, 0x39, 0x70, 0xf7, 0x27, 0xa8, 0x3c, 0x33, 0xfe, 0xbb, 0x55, 0x76, 0xf7, 0x94, 0x53, 0x62, 0xbf, 0xdf, 0xef, 0x37, 0xef, 0xf7, 0xde, 0x9b, 0xb7, 0x06, 0x77, 0x28, 0x8f, 0x29, 0x8f, 0xb8, 0x27, 0xe8, 0x09, 0x26, 0x47, 0x68, 0x20, 0x28, 0x9b, 0x78, 0xcf, 0x3b, 0x7d, 0x2c, 0x50, 0xc7, 0x13, 0x2f, 0xdc, 0x11, 0xa3, 0x82, 0x9a, 0x7b, 0x1a, 0xe6, 0x56, 0x61, 0xae, 0x86, 0x59, 0xdb, 0x21, 0x0d, 0xa9, 0x04, 0x7a, 0xd9, 0x7f, 0x8a, 0x63, 0xd9, 0x03, 0x49, 0xf2, 0xfa, 0x88, 0xe3, 0x42, 0x71, 0x40, 0x23, 0x32, 0x15, 0x27, 0x27, 0x45, 0x3c, 0x7b, 0xd0, 0xf1, 0xbb, 0x17, 0xa6, 0x36, 0x42, 0x0c, 0xc5, 0x5c, 0x43, 0x77, 0xb4, 0x54, 0xcc, 0x43, 0xef, 0x79, 0x27, 0xfb, 0xa3, 0x03, 0xbb, 0x2a, 0xd0, 0x53, 0xc9, 0xa9, 0x07, 0x15, 0x82, 0xcf, 0xc0, 0x8d, 0x2e, 0x0f, 0xf7, 0x19, 0x46, 0x02, 0x7f, 0x8e, 0x09, 0x8d, 0xcd, 0xbb, 0xa0, 0xc5, 0x31, 0x19, 0x62, 0xd6, 0x36, 0x6e, 0x1b, 0x1f, 0xac, 0xfa, 0x9b, 0x69, 0xe2, 0xac, 0x4d, 0x50, 0xfc, 0xec, 0x11, 0x54, 0xef, 0x61, 0xa0, 0x01, 0xa6, 0x07, 0x56, 0xf8, 0xb8, 0x3f, 0xcc, 0x68, 0xed, 0x2b, 0x12, 0xbc, 0x95, 0x26, 0xce, 0xba, 0x06, 0xeb, 0x08, 0x0c, 0x0a, 0x10, 0x7c, 0x0a, 0x6e, 0xd6, 0x4f, 0x0b, 0x30, 0x1f, 0x51, 0xc2, 0xb1, 0xe9, 0x83, 0x75, 0x82, 0x4f, 0x7b, 0xd2, 0x64, 0x4f, 0x29, 0xaa, 0xe3, 0xad, 0x34, 0x71, 0x6e, 0x2a, 0xc5, 0x06, 0x00, 0x06, 0x6b, 0x04, 0x9f, 0x1e, 0x66, 0x2f, 0xa4, 0x16, 0xfc, 0xcb, 0x00, 0x6f, 0x77, 0x79, 0xd8, 0x8d, 0x88, 0x58, 0xc4, 0xc5, 0x17, 0xa0, 0x85, 0x62, 0x3a, 0x26, 0x42, 0x7a, 0xb8, 0x76, 0x7f, 0xd7, 0xd5, 0x15, 0xca, 0x5a, 0x96, 0x77, 0xd7, 0xdd, 0xa7, 0x11, 0xf1, 0xdf, 0x79, 0x99, 0x38, 0x4b, 0xa5, 0x92, 0xa2, 0xc1, 0x40, 0xf3, 0xcd, 0xcf, 0xc0, 0x5a, 0x1c, 0x11, 0x71, 0x48, 0x1f, 0x0f, 0x87, 0x0c, 0x73, 0xde, 0xbe, 0xda, 0xb4, 0x90, 0x85, 0x7b, 0x82, 0xf6, 0x90, 0x02, 0xc0, 0xa0, 0x4e, 0x80, 0x9b, 0x60, 0x5d, 0x3b, 0xc8, 0x2b, 0x03, 0xff, 0x56, 0xae, 0xfc, 0x31, 0x23, 0x97, 0xe3, 0xea, 0x00, 0xac, 0xf7, 0xc7, 0x8c, 0x1c, 0x30, 0x1a, 0xd7, 0x7d, 0xed, 0xa5, 0x89, 0xd3, 0x56, 0x9c, 0x0c, 0xd0, 0x3b, 0x62, 0x34, 0x2e, 0x9d, 0x35, 0x49, 0xda, 0x5b, 0xe6, 0xa3, 0xf0, 0xf6, 0x8b, 0xa1, 0xc6, 0xef, 0x18, 0x91, 0x10, 0x3f, 0x1e, 0xc6, 0xd1, 0x42, 0x16, 0xdf, 0x07, 0x6f, 0x55, 0x67, 0x6f, 0x23, 0x4d, 0x9c, 0xeb, 0x0a, 0xa9, 0xe7, 0x43, 0x85, 0xcd, 0x0e, 0x58, 0xcd, 0x46, 0x07, 0x65, 0xfa, 0x3a, 0xf5, 0xed, 0x34, 0x71, 0x36, 0xca, 0xa9, 0x92, 0x21, 0x18, 0xac, 0x10, 0x7c, 0x2a, 0xb3, 0x80, 0x6d, 0x35, 0xa8, 0x65, 0x5e, 0x45, 0xca, 0x3f, 0x1b, 0x60, 0xab, 0xcb, 0xc3, 0x27, 0x58, 0xc8, 0xa1, 0xeb, 0x62, 0x81, 0x86, 0x48, 0xa0, 0x45, 0xf2, 0x0e, 0xc0, 0x4a, 0xac, 0x69, 0xba, 0x39, 0xb7, 0xca, 0xe6, 0x90, 0x93, 0xa2, 0x39, 0xb9, 0xb6, 0xbf, 0xa3, 0x1b, 0xa4, 0x6f, 0x56, 0x4e, 0x86, 0x41, 0xa1, 0x03, 0x6f, 0x81, 0x77, 0xdf, 0x90, 0x55, 0x91, 0xf5, 0xef, 0x57, 0xc0, 0x46, 0x97, 0x87, 0x07, 0x94, 0x0d, 0xf0, 0x21, 0x43, 0x84, 0x1f, 0x61, 0x76, 0x39, 0xd3, 0x14, 0x80, 0x2d, 0xa1, 0x13, 0x98, 0x9e, 0xa8, 0xdb, 0x69, 0xe2, 0xec, 0x29, 0x5e, 0x0e, 0x6a, 0x4c, 0xd5, 0x9b, 0xc8, 0xe6, 0x97, 0x60, 0x33, 0x7f, 0x5d, 0xde, 0xbd, 0x65, 0xa9, 0x68, 0xa7, 0x89, 0x63, 0x35, 0x14, 0xab, 0xf7, 0x6f, 0x9a, 0x08, 0x2d, 0xd0, 0x6e, 0x96, 0xaa, 0xa8, 0xe3, 0x6f, 0x86, 0x1c, 0xe2, 0x6f, 0x46, 0x43, 0x24, 0xf0, 0xd7, 0x72, 0xf9, 0x9a, 0x0f, 0xc1, 0x2a, 0x1a, 0x8b, 0x63, 0xca, 0x22, 0x31, 0xd1, 0x95, 0x6c, 0xff, 0xf3, 0xe7, 0xbd, 0x6d, 0x5d, 0x21, 0x2d, 0xfb, 0x44, 0xb0, 0x88, 0x84, 0x41, 0x09, 0x35, 0x7d, 0xd0, 0x52, 0xeb, 0x5b, 0xd7, 0xf4, 0x3d, 0xf7, 0xa2, 0x9f, 0x17, 0x57, 0x9d, 0xe6, 0x2f, 0x67, 0xe5, 0x0d, 0x34, 0xf3, 0xd1, 0x8d, 0x1f, 0xff, 0xff, 0xe3, 0xc3, 0x52, 0x13, 0xee, 0x82, 0x9d, 0x46, 0x7a, 0x79, 0xea, 0xf7, 0x7f, 0x6d, 0x81, 0xab, 0x5d, 0x1e, 0x9a, 0xdf, 0x83, 0x6b, 0xd5, 0x75, 0xff, 0xd1, 0xc5, 0xa7, 0xd6, 0xd7, 0xb5, 0xf5, 0x60, 0x11, 0x74, 0xb1, 0xdc, 0x9f, 0x82, 0x65, 0xb9, 0x94, 0xef, 0xcc, 0x64, 0x67, 0x30, 0xeb, 0xde, 0x5c, 0xb0, 0xaa, 0xba, 0x5c, 0x8e, 0xb3, 0xd5, 0x33, 0xd8, 0x1c, 0xea, 0xd5, 0x15, 0x25, 0xcb, 0x55, 0x59, 0x4f, 0x73, 0x94, 0xab, 0x44, 0xcf, 0x53, 0xae, 0xe9, 0x15, 0x63, 0xfe, 0x60, 0x80, 0x8d, 0xa9, 0xfd, 0xd2, 0x99, 0x29, 0xd5, 0xa4, 0x58, 0x9f, 0x2e, 0x4c, 0x29, 0x52, 0x38, 0x05, 0x6b, 0xf5, 0x5d, 0xe1, 0xce, 0xd4, 0xaa, 0xe1, 0xad, 0x87, 0x8b, 0xe1, 0x8b, 0x83, 0x05, 0xb8, 0x5e, 0xbb, 0x5c, 0xb3, 0xbb, 0x55, 0x85, 0x5b, 0x9f, 0x2c, 0x04, 0xcf, 0x4f, 0xf5, 0xbf, 0x7a, 0x79, 0x66, 0x1b, 0xaf, 0xce, 0x6c, 0xe3, 0xbf, 0x33, 0xdb, 0xf8, 0xe9, 0xdc, 0x5e, 0x7a, 0x75, 0x6e, 0x2f, 0xfd, 0x7b, 0x6e, 0x2f, 0x7d, 0xfb, 0x20, 0x8c, 0xc4, 0xf1, 0xb8, 0xef, 0x0e, 0x68, 0xec, 0xed, 0x4b, 0xed, 0x7d, 0x4a, 0x04, 0x43, 0x03, 0xc1, 0xbd, 0xef, 0xc6, 0x84, 0x7a, 0x2f, 0xea, 0x1f, 0x66, 0x62, 0x32, 0xc2, 0xbc, 0xdf, 0x92, 0x1f, 0x57, 0x1f, 0xbf, 0x0e, 0x00, 0x00, 0xff, 0xff, 0xc9, 0xb3, 0x74, 0xf3, 0x58, 0x0a, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. var _ context.Context var _ grpc.ClientConn // This is a compile-time assertion to ensure that this generated file // is compatible with the grpc package it is being compiled against. const _ = grpc.SupportPackageIsVersion4 // MsgClient is the client API for Msg service. // // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. type MsgClient interface { CreateDenom(ctx context.Context, in *MsgCreateDenom, opts ...grpc.CallOption) (*MsgCreateDenomResponse, error) Mint(ctx context.Context, in *MsgMint, opts ...grpc.CallOption) (*MsgMintResponse, error) Burn(ctx context.Context, in *MsgBurn, opts ...grpc.CallOption) (*MsgBurnResponse, error) ChangeAdmin(ctx context.Context, in *MsgChangeAdmin, opts ...grpc.CallOption) (*MsgChangeAdminResponse, error) SetDenomMetadata(ctx context.Context, in *MsgSetDenomMetadata, opts ...grpc.CallOption) (*MsgSetDenomMetadataResponse, error) ForceTransfer(ctx context.Context, in *MsgForceTransfer, opts ...grpc.CallOption) (*MsgForceTransferResponse, error) // UpdateParams defines a governance operation for updating the x/mint module // parameters. The authority is hard-coded to the x/gov module account. // // Since: cosmos-sdk 0.47 UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) } type msgClient struct { cc grpc1.ClientConn } func NewMsgClient(cc grpc1.ClientConn) MsgClient { return &msgClient{cc} } func (c *msgClient) CreateDenom(ctx context.Context, in *MsgCreateDenom, opts ...grpc.CallOption) (*MsgCreateDenomResponse, error) { out := new(MsgCreateDenomResponse) err := c.cc.Invoke(ctx, "/osmosis.tokenfactory.v1beta1.Msg/CreateDenom", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *msgClient) Mint(ctx context.Context, in *MsgMint, opts ...grpc.CallOption) (*MsgMintResponse, error) { out := new(MsgMintResponse) err := c.cc.Invoke(ctx, "/osmosis.tokenfactory.v1beta1.Msg/Mint", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *msgClient) Burn(ctx context.Context, in *MsgBurn, opts ...grpc.CallOption) (*MsgBurnResponse, error) { out := new(MsgBurnResponse) err := c.cc.Invoke(ctx, "/osmosis.tokenfactory.v1beta1.Msg/Burn", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *msgClient) ChangeAdmin(ctx context.Context, in *MsgChangeAdmin, opts ...grpc.CallOption) (*MsgChangeAdminResponse, error) { out := new(MsgChangeAdminResponse) err := c.cc.Invoke(ctx, "/osmosis.tokenfactory.v1beta1.Msg/ChangeAdmin", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *msgClient) SetDenomMetadata(ctx context.Context, in *MsgSetDenomMetadata, opts ...grpc.CallOption) (*MsgSetDenomMetadataResponse, error) { out := new(MsgSetDenomMetadataResponse) err := c.cc.Invoke(ctx, "/osmosis.tokenfactory.v1beta1.Msg/SetDenomMetadata", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *msgClient) ForceTransfer(ctx context.Context, in *MsgForceTransfer, opts ...grpc.CallOption) (*MsgForceTransferResponse, error) { out := new(MsgForceTransferResponse) err := c.cc.Invoke(ctx, "/osmosis.tokenfactory.v1beta1.Msg/ForceTransfer", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *msgClient) UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) { out := new(MsgUpdateParamsResponse) err := c.cc.Invoke(ctx, "/osmosis.tokenfactory.v1beta1.Msg/UpdateParams", in, out, opts...) if err != nil { return nil, err } return out, nil } // MsgServer is the server API for Msg service. type MsgServer interface { CreateDenom(context.Context, *MsgCreateDenom) (*MsgCreateDenomResponse, error) Mint(context.Context, *MsgMint) (*MsgMintResponse, error) Burn(context.Context, *MsgBurn) (*MsgBurnResponse, error) ChangeAdmin(context.Context, *MsgChangeAdmin) (*MsgChangeAdminResponse, error) SetDenomMetadata(context.Context, *MsgSetDenomMetadata) (*MsgSetDenomMetadataResponse, error) ForceTransfer(context.Context, *MsgForceTransfer) (*MsgForceTransferResponse, error) // UpdateParams defines a governance operation for updating the x/mint module // parameters. The authority is hard-coded to the x/gov module account. // // Since: cosmos-sdk 0.47 UpdateParams(context.Context, *MsgUpdateParams) (*MsgUpdateParamsResponse, error) } // UnimplementedMsgServer can be embedded to have forward compatible implementations. type UnimplementedMsgServer struct { } func (*UnimplementedMsgServer) CreateDenom(ctx context.Context, req *MsgCreateDenom) (*MsgCreateDenomResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method CreateDenom not implemented") } func (*UnimplementedMsgServer) Mint(ctx context.Context, req *MsgMint) (*MsgMintResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method Mint not implemented") } func (*UnimplementedMsgServer) Burn(ctx context.Context, req *MsgBurn) (*MsgBurnResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method Burn not implemented") } func (*UnimplementedMsgServer) ChangeAdmin(ctx context.Context, req *MsgChangeAdmin) (*MsgChangeAdminResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method ChangeAdmin not implemented") } func (*UnimplementedMsgServer) SetDenomMetadata(ctx context.Context, req *MsgSetDenomMetadata) (*MsgSetDenomMetadataResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method SetDenomMetadata not implemented") } func (*UnimplementedMsgServer) ForceTransfer(ctx context.Context, req *MsgForceTransfer) (*MsgForceTransferResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method ForceTransfer not implemented") } func (*UnimplementedMsgServer) UpdateParams(ctx context.Context, req *MsgUpdateParams) (*MsgUpdateParamsResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method UpdateParams not implemented") } func RegisterMsgServer(s grpc1.Server, srv MsgServer) { s.RegisterService(&_Msg_serviceDesc, srv) } func _Msg_CreateDenom_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgCreateDenom) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(MsgServer).CreateDenom(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/osmosis.tokenfactory.v1beta1.Msg/CreateDenom", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).CreateDenom(ctx, req.(*MsgCreateDenom)) } return interceptor(ctx, in, info, handler) } func _Msg_Mint_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgMint) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(MsgServer).Mint(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/osmosis.tokenfactory.v1beta1.Msg/Mint", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).Mint(ctx, req.(*MsgMint)) } return interceptor(ctx, in, info, handler) } func _Msg_Burn_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgBurn) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(MsgServer).Burn(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/osmosis.tokenfactory.v1beta1.Msg/Burn", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).Burn(ctx, req.(*MsgBurn)) } return interceptor(ctx, in, info, handler) } func _Msg_ChangeAdmin_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgChangeAdmin) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(MsgServer).ChangeAdmin(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/osmosis.tokenfactory.v1beta1.Msg/ChangeAdmin", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).ChangeAdmin(ctx, req.(*MsgChangeAdmin)) } return interceptor(ctx, in, info, handler) } func _Msg_SetDenomMetadata_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgSetDenomMetadata) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(MsgServer).SetDenomMetadata(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/osmosis.tokenfactory.v1beta1.Msg/SetDenomMetadata", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).SetDenomMetadata(ctx, req.(*MsgSetDenomMetadata)) } return interceptor(ctx, in, info, handler) } func _Msg_ForceTransfer_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgForceTransfer) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(MsgServer).ForceTransfer(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/osmosis.tokenfactory.v1beta1.Msg/ForceTransfer", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).ForceTransfer(ctx, req.(*MsgForceTransfer)) } return interceptor(ctx, in, info, handler) } func _Msg_UpdateParams_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(MsgUpdateParams) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(MsgServer).UpdateParams(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/osmosis.tokenfactory.v1beta1.Msg/UpdateParams", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(MsgServer).UpdateParams(ctx, req.(*MsgUpdateParams)) } return interceptor(ctx, in, info, handler) } var _Msg_serviceDesc = grpc.ServiceDesc{ ServiceName: "osmosis.tokenfactory.v1beta1.Msg", HandlerType: (*MsgServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "CreateDenom", Handler: _Msg_CreateDenom_Handler, }, { MethodName: "Mint", Handler: _Msg_Mint_Handler, }, { MethodName: "Burn", Handler: _Msg_Burn_Handler, }, { MethodName: "ChangeAdmin", Handler: _Msg_ChangeAdmin_Handler, }, { MethodName: "SetDenomMetadata", Handler: _Msg_SetDenomMetadata_Handler, }, { MethodName: "ForceTransfer", Handler: _Msg_ForceTransfer_Handler, }, { MethodName: "UpdateParams", Handler: _Msg_UpdateParams_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "osmosis/tokenfactory/v1beta1/tx.proto", } func (m *MsgCreateDenom) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgCreateDenom) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgCreateDenom) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.Subdenom) > 0 { i -= len(m.Subdenom) copy(dAtA[i:], m.Subdenom) i = encodeVarintTx(dAtA, i, uint64(len(m.Subdenom))) i-- dAtA[i] = 0x12 } if len(m.Sender) > 0 { i -= len(m.Sender) copy(dAtA[i:], m.Sender) i = encodeVarintTx(dAtA, i, uint64(len(m.Sender))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *MsgCreateDenomResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgCreateDenomResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgCreateDenomResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.NewTokenDenom) > 0 { i -= len(m.NewTokenDenom) copy(dAtA[i:], m.NewTokenDenom) i = encodeVarintTx(dAtA, i, uint64(len(m.NewTokenDenom))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *MsgMint) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgMint) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgMint) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.MintToAddress) > 0 { i -= len(m.MintToAddress) copy(dAtA[i:], m.MintToAddress) i = encodeVarintTx(dAtA, i, uint64(len(m.MintToAddress))) i-- dAtA[i] = 0x1a } { size, err := m.Amount.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintTx(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 if len(m.Sender) > 0 { i -= len(m.Sender) copy(dAtA[i:], m.Sender) i = encodeVarintTx(dAtA, i, uint64(len(m.Sender))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *MsgMintResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgMintResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgMintResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *MsgBurn) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgBurn) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgBurn) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.BurnFromAddress) > 0 { i -= len(m.BurnFromAddress) copy(dAtA[i:], m.BurnFromAddress) i = encodeVarintTx(dAtA, i, uint64(len(m.BurnFromAddress))) i-- dAtA[i] = 0x1a } { size, err := m.Amount.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintTx(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 if len(m.Sender) > 0 { i -= len(m.Sender) copy(dAtA[i:], m.Sender) i = encodeVarintTx(dAtA, i, uint64(len(m.Sender))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *MsgBurnResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgBurnResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgBurnResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *MsgChangeAdmin) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgChangeAdmin) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgChangeAdmin) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.NewAdmin) > 0 { i -= len(m.NewAdmin) copy(dAtA[i:], m.NewAdmin) i = encodeVarintTx(dAtA, i, uint64(len(m.NewAdmin))) i-- dAtA[i] = 0x1a } if len(m.Denom) > 0 { i -= len(m.Denom) copy(dAtA[i:], m.Denom) i = encodeVarintTx(dAtA, i, uint64(len(m.Denom))) i-- dAtA[i] = 0x12 } if len(m.Sender) > 0 { i -= len(m.Sender) copy(dAtA[i:], m.Sender) i = encodeVarintTx(dAtA, i, uint64(len(m.Sender))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *MsgChangeAdminResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgChangeAdminResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgChangeAdminResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *MsgSetDenomMetadata) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgSetDenomMetadata) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgSetDenomMetadata) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.Metadata.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintTx(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 if len(m.Sender) > 0 { i -= len(m.Sender) copy(dAtA[i:], m.Sender) i = encodeVarintTx(dAtA, i, uint64(len(m.Sender))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *MsgSetDenomMetadataResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgSetDenomMetadataResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgSetDenomMetadataResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *MsgForceTransfer) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgForceTransfer) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgForceTransfer) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l if len(m.TransferToAddress) > 0 { i -= len(m.TransferToAddress) copy(dAtA[i:], m.TransferToAddress) i = encodeVarintTx(dAtA, i, uint64(len(m.TransferToAddress))) i-- dAtA[i] = 0x22 } if len(m.TransferFromAddress) > 0 { i -= len(m.TransferFromAddress) copy(dAtA[i:], m.TransferFromAddress) i = encodeVarintTx(dAtA, i, uint64(len(m.TransferFromAddress))) i-- dAtA[i] = 0x1a } { size, err := m.Amount.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintTx(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 if len(m.Sender) > 0 { i -= len(m.Sender) copy(dAtA[i:], m.Sender) i = encodeVarintTx(dAtA, i, uint64(len(m.Sender))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *MsgForceTransferResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgForceTransferResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgForceTransferResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func (m *MsgUpdateParams) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgUpdateParams) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgUpdateParams) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l { size, err := m.Params.MarshalToSizedBuffer(dAtA[:i]) if err != nil { return 0, err } i -= size i = encodeVarintTx(dAtA, i, uint64(size)) } i-- dAtA[i] = 0x12 if len(m.Authority) > 0 { i -= len(m.Authority) copy(dAtA[i:], m.Authority) i = encodeVarintTx(dAtA, i, uint64(len(m.Authority))) i-- dAtA[i] = 0xa } return len(dAtA) - i, nil } func (m *MsgUpdateParamsResponse) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) n, err := m.MarshalToSizedBuffer(dAtA[:size]) if err != nil { return nil, err } return dAtA[:n], nil } func (m *MsgUpdateParamsResponse) MarshalTo(dAtA []byte) (int, error) { size := m.Size() return m.MarshalToSizedBuffer(dAtA[:size]) } func (m *MsgUpdateParamsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { i := len(dAtA) _ = i var l int _ = l return len(dAtA) - i, nil } func encodeVarintTx(dAtA []byte, offset int, v uint64) int { offset -= sovTx(v) base := offset for v >= 1<<7 { dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } dAtA[offset] = uint8(v) return base } func (m *MsgCreateDenom) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Sender) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = len(m.Subdenom) if l > 0 { n += 1 + l + sovTx(uint64(l)) } return n } func (m *MsgCreateDenomResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.NewTokenDenom) if l > 0 { n += 1 + l + sovTx(uint64(l)) } return n } func (m *MsgMint) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Sender) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = m.Amount.Size() n += 1 + l + sovTx(uint64(l)) l = len(m.MintToAddress) if l > 0 { n += 1 + l + sovTx(uint64(l)) } return n } func (m *MsgMintResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *MsgBurn) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Sender) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = m.Amount.Size() n += 1 + l + sovTx(uint64(l)) l = len(m.BurnFromAddress) if l > 0 { n += 1 + l + sovTx(uint64(l)) } return n } func (m *MsgBurnResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *MsgChangeAdmin) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Sender) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = len(m.Denom) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = len(m.NewAdmin) if l > 0 { n += 1 + l + sovTx(uint64(l)) } return n } func (m *MsgChangeAdminResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *MsgSetDenomMetadata) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Sender) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = m.Metadata.Size() n += 1 + l + sovTx(uint64(l)) return n } func (m *MsgSetDenomMetadataResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *MsgForceTransfer) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Sender) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = m.Amount.Size() n += 1 + l + sovTx(uint64(l)) l = len(m.TransferFromAddress) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = len(m.TransferToAddress) if l > 0 { n += 1 + l + sovTx(uint64(l)) } return n } func (m *MsgForceTransferResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func (m *MsgUpdateParams) Size() (n int) { if m == nil { return 0 } var l int _ = l l = len(m.Authority) if l > 0 { n += 1 + l + sovTx(uint64(l)) } l = m.Params.Size() n += 1 + l + sovTx(uint64(l)) return n } func (m *MsgUpdateParamsResponse) Size() (n int) { if m == nil { return 0 } var l int _ = l return n } func sovTx(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 } func sozTx(x uint64) (n int) { return sovTx(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } func (m *MsgCreateDenom) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgCreateDenom: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgCreateDenom: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Sender", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Sender = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Subdenom", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Subdenom = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgCreateDenomResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgCreateDenomResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgCreateDenomResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field NewTokenDenom", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.NewTokenDenom = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgMint) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgMint: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgMint: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Sender", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Sender = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Amount", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Amount.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 3: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field MintToAddress", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.MintToAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgMintResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgMintResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgMintResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgBurn) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgBurn: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgBurn: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Sender", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Sender = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Amount", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Amount.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 3: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field BurnFromAddress", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.BurnFromAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgBurnResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgBurnResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgBurnResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgChangeAdmin) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgChangeAdmin: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgChangeAdmin: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Sender", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Sender = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Denom", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Denom = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field NewAdmin", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.NewAdmin = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgChangeAdminResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgChangeAdminResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgChangeAdminResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgSetDenomMetadata) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgSetDenomMetadata: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgSetDenomMetadata: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Sender", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Sender = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Metadata", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Metadata.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgSetDenomMetadataResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgSetDenomMetadataResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgSetDenomMetadataResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgForceTransfer) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgForceTransfer: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgForceTransfer: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Sender", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Sender = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Amount", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Amount.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 3: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field TransferFromAddress", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.TransferFromAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 4: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field TransferToAddress", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.TransferToAddress = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgForceTransferResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgForceTransferResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgForceTransferResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgUpdateParams) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgUpdateParams: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgUpdateParams: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Authority", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ stringLen |= uint64(b&0x7F) << shift if b < 0x80 { break } } intStringLen := int(stringLen) if intStringLen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + intStringLen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } m.Authority = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field Params", wireType) } var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ msglen |= int(b&0x7F) << shift if b < 0x80 { break } } if msglen < 0 { return ErrInvalidLengthTx } postIndex := iNdEx + msglen if postIndex < 0 { return ErrInvalidLengthTx } if postIndex > l { return io.ErrUnexpectedEOF } if err := m.Params.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func (m *MsgUpdateParamsResponse) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowTx } if iNdEx >= l { return io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= uint64(b&0x7F) << shift if b < 0x80 { break } } fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { return fmt.Errorf("proto: MsgUpdateParamsResponse: wiretype end group for non-group") } if fieldNum <= 0 { return fmt.Errorf("proto: MsgUpdateParamsResponse: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { default: iNdEx = preIndex skippy, err := skipTx(dAtA[iNdEx:]) if err != nil { return err } if (skippy < 0) || (iNdEx+skippy) < 0 { return ErrInvalidLengthTx } if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } iNdEx += skippy } } if iNdEx > l { return io.ErrUnexpectedEOF } return nil } func skipTx(dAtA []byte) (n int, err error) { l := len(dAtA) iNdEx := 0 depth := 0 for iNdEx < l { var wire uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTx } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } wireType := int(wire & 0x7) switch wireType { case 0: for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTx } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } iNdEx++ if dAtA[iNdEx-1] < 0x80 { break } } case 1: iNdEx += 8 case 2: var length int for shift := uint(0); ; shift += 7 { if shift >= 64 { return 0, ErrIntOverflowTx } if iNdEx >= l { return 0, io.ErrUnexpectedEOF } b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { break } } if length < 0 { return 0, ErrInvalidLengthTx } iNdEx += length case 3: depth++ case 4: if depth == 0 { return 0, ErrUnexpectedEndOfGroupTx } depth-- case 5: iNdEx += 4 default: return 0, fmt.Errorf("proto: illegal wireType %d", wireType) } if iNdEx < 0 { return 0, ErrInvalidLengthTx } if depth == 0 { return iNdEx, nil } } return 0, io.ErrUnexpectedEOF } var ( ErrInvalidLengthTx = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowTx = fmt.Errorf("proto: integer overflow") ErrUnexpectedEndOfGroupTx = fmt.Errorf("proto: unexpected end of group") ) ================================================ FILE: x/tokenfactory/wasm/custom_msg_test.go ================================================ package wasm_test import ( "encoding/json" "fmt" "testing" "github.com/CosmWasm/wasmd/x/wasm/keeper" wasmvmtypes "github.com/CosmWasm/wasmvm/types" "github.com/stretchr/testify/require" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/app" "github.com/cybercongress/go-cyber/v7/x/tokenfactory/types" bindings "github.com/cybercongress/go-cyber/v7/x/tokenfactory/wasm/types" ) func TestCreateDenomMsg(t *testing.T) { creator := RandomAccountAddress() junoapp, ctx := SetupCustomApp(t, creator) lucky := RandomAccountAddress() reflect := instantiateReflectContract(t, ctx, junoapp, lucky) require.NotEmpty(t, reflect) // Fund reflect contract with 100 base denom creation fees reflectAmount := sdk.NewCoins(sdk.NewCoin(types.DefaultParams().DenomCreationFee[0].Denom, types.DefaultParams().DenomCreationFee[0].Amount.MulRaw(100))) fundAccount(t, ctx, junoapp, reflect, reflectAmount) msg := bindings.TokenFactoryMsg{CreateDenom: &bindings.CreateDenom{ Subdenom: "SUN", }} err := executeCustom(t, ctx, junoapp, reflect, lucky, msg, sdk.Coin{}) require.NoError(t, err) // query the denom and see if it matches query := bindings.TokenFactoryQuery{ FullDenom: &bindings.FullDenom{ CreatorAddr: reflect.String(), Subdenom: "SUN", }, } resp := bindings.FullDenomResponse{} queryCustom(t, ctx, junoapp, reflect, query, &resp) require.Equal(t, resp.Denom, fmt.Sprintf("factory/%s/SUN", reflect.String())) } func TestMintMsg(t *testing.T) { creator := RandomAccountAddress() junoapp, ctx := SetupCustomApp(t, creator) lucky := RandomAccountAddress() reflect := instantiateReflectContract(t, ctx, junoapp, lucky) require.NotEmpty(t, reflect) // Fund reflect contract with 100 base denom creation fees reflectAmount := sdk.NewCoins(sdk.NewCoin(types.DefaultParams().DenomCreationFee[0].Denom, types.DefaultParams().DenomCreationFee[0].Amount.MulRaw(100))) fundAccount(t, ctx, junoapp, reflect, reflectAmount) // lucky was broke balances := junoapp.AppKeepers.BankKeeper.GetAllBalances(ctx, lucky) require.Empty(t, balances) // Create denom for minting msg := bindings.TokenFactoryMsg{CreateDenom: &bindings.CreateDenom{ Subdenom: "SUN", }} err := executeCustom(t, ctx, junoapp, reflect, lucky, msg, sdk.Coin{}) require.NoError(t, err) sunDenom := fmt.Sprintf("factory/%s/%s", reflect.String(), msg.CreateDenom.Subdenom) amount, ok := sdk.NewIntFromString("808010808") require.True(t, ok) msg = bindings.TokenFactoryMsg{MintTokens: &bindings.MintTokens{ Denom: sunDenom, Amount: amount, MintToAddress: lucky.String(), }} err = executeCustom(t, ctx, junoapp, reflect, lucky, msg, sdk.Coin{}) require.NoError(t, err) balances = junoapp.AppKeepers.BankKeeper.GetAllBalances(ctx, lucky) require.Len(t, balances, 1) coin := balances[0] require.Equal(t, amount, coin.Amount) require.Contains(t, coin.Denom, "factory/") // query the denom and see if it matches query := bindings.TokenFactoryQuery{ FullDenom: &bindings.FullDenom{ CreatorAddr: reflect.String(), Subdenom: "SUN", }, } resp := bindings.FullDenomResponse{} queryCustom(t, ctx, junoapp, reflect, query, &resp) require.Equal(t, resp.Denom, coin.Denom) // mint the same denom again err = executeCustom(t, ctx, junoapp, reflect, lucky, msg, sdk.Coin{}) require.NoError(t, err) balances = junoapp.AppKeepers.BankKeeper.GetAllBalances(ctx, lucky) require.Len(t, balances, 1) coin = balances[0] require.Equal(t, amount.MulRaw(2), coin.Amount) require.Contains(t, coin.Denom, "factory/") // query the denom and see if it matches query = bindings.TokenFactoryQuery{ FullDenom: &bindings.FullDenom{ CreatorAddr: reflect.String(), Subdenom: "SUN", }, } resp = bindings.FullDenomResponse{} queryCustom(t, ctx, junoapp, reflect, query, &resp) require.Equal(t, resp.Denom, coin.Denom) // now mint another amount / denom // create it first msg = bindings.TokenFactoryMsg{CreateDenom: &bindings.CreateDenom{ Subdenom: "MOON", }} err = executeCustom(t, ctx, junoapp, reflect, lucky, msg, sdk.Coin{}) require.NoError(t, err) moonDenom := fmt.Sprintf("factory/%s/%s", reflect.String(), msg.CreateDenom.Subdenom) amount = amount.SubRaw(1) msg = bindings.TokenFactoryMsg{MintTokens: &bindings.MintTokens{ Denom: moonDenom, Amount: amount, MintToAddress: lucky.String(), }} err = executeCustom(t, ctx, junoapp, reflect, lucky, msg, sdk.Coin{}) require.NoError(t, err) balances = junoapp.AppKeepers.BankKeeper.GetAllBalances(ctx, lucky) require.Len(t, balances, 2) coin = balances[0] require.Equal(t, amount, coin.Amount) require.Contains(t, coin.Denom, "factory/") // query the denom and see if it matches query = bindings.TokenFactoryQuery{ FullDenom: &bindings.FullDenom{ CreatorAddr: reflect.String(), Subdenom: "MOON", }, } resp = bindings.FullDenomResponse{} queryCustom(t, ctx, junoapp, reflect, query, &resp) require.Equal(t, resp.Denom, coin.Denom) // and check the first denom is unchanged coin = balances[1] require.Equal(t, amount.AddRaw(1).MulRaw(2), coin.Amount) require.Contains(t, coin.Denom, "factory/") // query the denom and see if it matches query = bindings.TokenFactoryQuery{ FullDenom: &bindings.FullDenom{ CreatorAddr: reflect.String(), Subdenom: "SUN", }, } resp = bindings.FullDenomResponse{} queryCustom(t, ctx, junoapp, reflect, query, &resp) require.Equal(t, resp.Denom, coin.Denom) } func TestForceTransfer(t *testing.T) { creator := RandomAccountAddress() junoapp, ctx := SetupCustomApp(t, creator) lucky := RandomAccountAddress() rcpt := RandomAccountAddress() reflect := instantiateReflectContract(t, ctx, junoapp, lucky) require.NotEmpty(t, reflect) // Fund reflect contract with 100 base denom creation fees reflectAmount := sdk.NewCoins(sdk.NewCoin(types.DefaultParams().DenomCreationFee[0].Denom, types.DefaultParams().DenomCreationFee[0].Amount.MulRaw(100))) fundAccount(t, ctx, junoapp, reflect, reflectAmount) // lucky was broke balances := junoapp.AppKeepers.BankKeeper.GetAllBalances(ctx, lucky) require.Empty(t, balances) // Create denom for minting msg := bindings.TokenFactoryMsg{CreateDenom: &bindings.CreateDenom{ Subdenom: "SUN", }} err := executeCustom(t, ctx, junoapp, reflect, lucky, msg, sdk.Coin{}) require.NoError(t, err) sunDenom := fmt.Sprintf("factory/%s/%s", reflect.String(), msg.CreateDenom.Subdenom) amount, ok := sdk.NewIntFromString("808010808") require.True(t, ok) // Mint new tokens to lucky msg = bindings.TokenFactoryMsg{MintTokens: &bindings.MintTokens{ Denom: sunDenom, Amount: amount, MintToAddress: lucky.String(), }} err = executeCustom(t, ctx, junoapp, reflect, lucky, msg, sdk.Coin{}) require.NoError(t, err) // Force move 100 tokens from lucky to rcpt msg = bindings.TokenFactoryMsg{ForceTransfer: &bindings.ForceTransfer{ Denom: sunDenom, Amount: sdk.NewInt(100), FromAddress: lucky.String(), ToAddress: rcpt.String(), }} err = executeCustom(t, ctx, junoapp, reflect, lucky, msg, sdk.Coin{}) require.NoError(t, err) // check the balance of rcpt balances = junoapp.AppKeepers.BankKeeper.GetAllBalances(ctx, rcpt) require.Len(t, balances, 1) coin := balances[0] require.Equal(t, sdk.NewInt(100), coin.Amount) } func TestBurnMsg(t *testing.T) { creator := RandomAccountAddress() junoapp, ctx := SetupCustomApp(t, creator) lucky := RandomAccountAddress() reflect := instantiateReflectContract(t, ctx, junoapp, lucky) require.NotEmpty(t, reflect) // Fund reflect contract with 100 base denom creation fees reflectAmount := sdk.NewCoins(sdk.NewCoin(types.DefaultParams().DenomCreationFee[0].Denom, types.DefaultParams().DenomCreationFee[0].Amount.MulRaw(100))) fundAccount(t, ctx, junoapp, reflect, reflectAmount) // lucky was broke balances := junoapp.AppKeepers.BankKeeper.GetAllBalances(ctx, lucky) require.Empty(t, balances) // Create denom for minting msg := bindings.TokenFactoryMsg{CreateDenom: &bindings.CreateDenom{ Subdenom: "SUN", }} err := executeCustom(t, ctx, junoapp, reflect, lucky, msg, sdk.Coin{}) require.NoError(t, err) sunDenom := fmt.Sprintf("factory/%s/%s", reflect.String(), msg.CreateDenom.Subdenom) amount, ok := sdk.NewIntFromString("808010809") require.True(t, ok) msg = bindings.TokenFactoryMsg{MintTokens: &bindings.MintTokens{ Denom: sunDenom, Amount: amount, MintToAddress: lucky.String(), }} err = executeCustom(t, ctx, junoapp, reflect, lucky, msg, sdk.Coin{}) require.NoError(t, err) // can burn from different address with burnFrom amt, ok := sdk.NewIntFromString("1") require.True(t, ok) msg = bindings.TokenFactoryMsg{BurnTokens: &bindings.BurnTokens{ Denom: sunDenom, Amount: amt, BurnFromAddress: lucky.String(), }} err = executeCustom(t, ctx, junoapp, reflect, lucky, msg, sdk.Coin{}) require.NoError(t, err) // lucky needs to send balance to reflect contract to burn it luckyBalance := junoapp.AppKeepers.BankKeeper.GetAllBalances(ctx, lucky) err = junoapp.AppKeepers.BankKeeper.SendCoins(ctx, lucky, reflect, luckyBalance) require.NoError(t, err) msg = bindings.TokenFactoryMsg{BurnTokens: &bindings.BurnTokens{ Denom: sunDenom, Amount: amount.Abs().Sub(sdk.NewInt(1)), BurnFromAddress: reflect.String(), }} err = executeCustom(t, ctx, junoapp, reflect, lucky, msg, sdk.Coin{}) require.NoError(t, err) } type ReflectExec struct { ReflectMsg *ReflectMsgs `json:"reflect_msg,omitempty"` ReflectSubMsg *ReflectSubMsgs `json:"reflect_sub_msg,omitempty"` } type ReflectMsgs struct { Msgs []wasmvmtypes.CosmosMsg `json:"msgs"` } type ReflectSubMsgs struct { Msgs []wasmvmtypes.SubMsg `json:"msgs"` } func executeCustom(t *testing.T, ctx sdk.Context, junoapp *app.App, contract sdk.AccAddress, sender sdk.AccAddress, msg bindings.TokenFactoryMsg, funds sdk.Coin) error { //nolint:unparam // funds is always nil but could change in the future. customBz, err := json.Marshal(msg) require.NoError(t, err) reflectMsg := ReflectExec{ ReflectMsg: &ReflectMsgs{ Msgs: []wasmvmtypes.CosmosMsg{{ Custom: customBz, }}, }, } reflectBz, err := json.Marshal(reflectMsg) require.NoError(t, err) // no funds sent if amount is 0 var coins sdk.Coins if !funds.Amount.IsNil() { coins = sdk.Coins{funds} } contractKeeper := keeper.NewDefaultPermissionKeeper(junoapp.AppKeepers.WasmKeeper) _, err = contractKeeper.Execute(ctx, contract, sender, reflectBz, coins) return err } ================================================ FILE: x/tokenfactory/wasm/custom_query_test.go ================================================ package wasm_test import ( "encoding/json" "fmt" "testing" wasmvmtypes "github.com/CosmWasm/wasmvm/types" "github.com/stretchr/testify/require" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/app" bindings "github.com/cybercongress/go-cyber/v7/x/tokenfactory/wasm/types" ) func TestQueryFullDenom(t *testing.T) { actor := RandomAccountAddress() junoapp, ctx := SetupCustomApp(t, actor) reflect := instantiateReflectContract(t, ctx, junoapp, actor) require.NotEmpty(t, reflect) // query full denom query := bindings.TokenFactoryQuery{ FullDenom: &bindings.FullDenom{ CreatorAddr: reflect.String(), Subdenom: "ustart", }, } resp := bindings.FullDenomResponse{} queryCustom(t, ctx, junoapp, reflect, query, &resp) expected := fmt.Sprintf("factory/%s/ustart", reflect.String()) require.EqualValues(t, expected, resp.Denom) } type ReflectQuery struct { Chain *ChainRequest `json:"chain,omitempty"` } type ChainRequest struct { Request wasmvmtypes.QueryRequest `json:"request"` } type ChainResponse struct { Data []byte `json:"data"` } func queryCustom(t *testing.T, ctx sdk.Context, junoapp *app.App, contract sdk.AccAddress, request bindings.TokenFactoryQuery, response interface{}) { msgBz, err := json.Marshal(request) require.NoError(t, err) fmt.Println("queryCustom1", string(msgBz)) query := ReflectQuery{ Chain: &ChainRequest{ Request: wasmvmtypes.QueryRequest{Custom: msgBz}, }, } queryBz, err := json.Marshal(query) require.NoError(t, err) fmt.Println("queryCustom2", string(queryBz)) resBz, err := junoapp.AppKeepers.WasmKeeper.QuerySmart(ctx, contract, queryBz) require.NoError(t, err) var resp ChainResponse err = json.Unmarshal(resBz, &resp) require.NoError(t, err) err = json.Unmarshal(resp.Data, response) require.NoError(t, err) } ================================================ FILE: x/tokenfactory/wasm/helpers_test.go ================================================ package wasm_test import ( "os" "testing" "time" "github.com/CosmWasm/wasmd/x/wasm/keeper" "github.com/stretchr/testify/require" "github.com/cometbft/cometbft/crypto" "github.com/cometbft/cometbft/crypto/ed25519" tmproto "github.com/cometbft/cometbft/proto/tendermint/types" sdk "github.com/cosmos/cosmos-sdk/types" banktestutil "github.com/cosmos/cosmos-sdk/x/bank/testutil" "github.com/cybercongress/go-cyber/v7/app" ) func CreateTestInput(t *testing.T) (*app.App, sdk.Context) { osmosis := app.Setup(t) ctx := osmosis.BaseApp.NewContext(false, tmproto.Header{Height: 1, ChainID: "testing", Time: time.Now().UTC()}) return osmosis, ctx } func FundAccount(t *testing.T, ctx sdk.Context, junoapp *app.App, acct sdk.AccAddress) { err := banktestutil.FundAccount(junoapp.AppKeepers.BankKeeper, ctx, acct, sdk.NewCoins( sdk.NewCoin("uosmo", sdk.NewInt(10000000000)), )) require.NoError(t, err) } // we need to make this deterministic (same every test run), as content might affect gas costs func keyPubAddr() (crypto.PrivKey, crypto.PubKey, sdk.AccAddress) { key := ed25519.GenPrivKey() pub := key.PubKey() addr := sdk.AccAddress(pub.Address()) return key, pub, addr } func RandomAccountAddress() sdk.AccAddress { _, _, addr := keyPubAddr() return addr } func RandomBech32AccountAddress() string { return RandomAccountAddress().String() } func storeReflectCode(t *testing.T, ctx sdk.Context, junoapp *app.App, addr sdk.AccAddress) uint64 { wasmCode, err := os.ReadFile("./testdata/token_reflect.wasm") require.NoError(t, err) contractKeeper := keeper.NewDefaultPermissionKeeper(junoapp.AppKeepers.WasmKeeper) codeID, _, err := contractKeeper.Create(ctx, addr, wasmCode, nil) require.NoError(t, err) return codeID } func instantiateReflectContract(t *testing.T, ctx sdk.Context, junoapp *app.App, funder sdk.AccAddress) sdk.AccAddress { initMsgBz := []byte("{}") contractKeeper := keeper.NewDefaultPermissionKeeper(junoapp.AppKeepers.WasmKeeper) codeID := uint64(1) addr, _, err := contractKeeper.Instantiate(ctx, codeID, funder, funder, initMsgBz, "demo contract", nil) require.NoError(t, err) return addr } func fundAccount(t *testing.T, ctx sdk.Context, junoapp *app.App, addr sdk.AccAddress, coins sdk.Coins) { err := banktestutil.FundAccount( junoapp.AppKeepers.BankKeeper, ctx, addr, coins, ) require.NoError(t, err) } func SetupCustomApp(t *testing.T, addr sdk.AccAddress) (*app.App, sdk.Context) { junoApp, ctx := CreateTestInput(t) wasmKeeper := junoApp.AppKeepers.WasmKeeper storeReflectCode(t, ctx, junoApp, addr) cInfo := wasmKeeper.GetCodeInfo(ctx, 1) require.NotNil(t, cInfo) return junoApp, ctx } ================================================ FILE: x/tokenfactory/wasm/message_plugin.go ================================================ package wasm import ( wasmvmtypes "github.com/CosmWasm/wasmvm/types" pluginstypes "github.com/cybercongress/go-cyber/v7/plugins/types" errorsmod "cosmossdk.io/errors" sdk "github.com/cosmos/cosmos-sdk/types" bankkeeper "github.com/cosmos/cosmos-sdk/x/bank/keeper" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" tokenfactorykeeper "github.com/cybercongress/go-cyber/v7/x/tokenfactory/keeper" tokenfactorytypes "github.com/cybercongress/go-cyber/v7/x/tokenfactory/types" bindingstypes "github.com/cybercongress/go-cyber/v7/x/tokenfactory/wasm/types" ) type Messenger struct { bank bankkeeper.Keeper tokenFactory *tokenfactorykeeper.Keeper } func NewMessenger( bank bankkeeper.Keeper, tokenFactory *tokenfactorykeeper.Keeper, ) *Messenger { return &Messenger{ bank: bank, tokenFactory: tokenFactory, } } // DispatchMsg executes on the contractMsg. func (m *Messenger) HandleMsg(ctx sdk.Context, contractAddr sdk.AccAddress, contractIBCPortID string, msg pluginstypes.CyberMsg) ([]sdk.Event, [][]byte, error) { var contractMsg = msg.TokenFactory switch { case contractMsg.CreateDenom != nil: return m.createDenom(ctx, contractAddr, contractMsg.CreateDenom) case contractMsg.MintTokens != nil: return m.mintTokens(ctx, contractAddr, contractMsg.MintTokens) case contractMsg.ChangeAdmin != nil: return m.changeAdmin(ctx, contractAddr, contractMsg.ChangeAdmin) case contractMsg.BurnTokens != nil: return m.burnTokens(ctx, contractAddr, contractMsg.BurnTokens) case contractMsg.SetMetadata != nil: return m.setMetadata(ctx, contractAddr, contractMsg.SetMetadata) case contractMsg.ForceTransfer != nil: return m.forceTransfer(ctx, contractAddr, contractMsg.ForceTransfer) default: return nil, nil, pluginstypes.ErrHandleMsg } } // createDenom creates a new token denom func (m *Messenger) createDenom(ctx sdk.Context, contractAddr sdk.AccAddress, createDenom *bindingstypes.CreateDenom) ([]sdk.Event, [][]byte, error) { bz, err := PerformCreateDenom(m.tokenFactory, m.bank, ctx, contractAddr, createDenom) if err != nil { return nil, nil, errorsmod.Wrap(err, "perform create denom") } // TODO: double check how this is all encoded to the contract return nil, [][]byte{bz}, nil } // PerformCreateDenom is used with createDenom to create a token denom; validates the msgCreateDenom. func PerformCreateDenom(f *tokenfactorykeeper.Keeper, b bankkeeper.Keeper, ctx sdk.Context, contractAddr sdk.AccAddress, createDenom *bindingstypes.CreateDenom) ([]byte, error) { if createDenom == nil { return nil, wasmvmtypes.InvalidRequest{Err: "create denom null create denom"} } msgServer := tokenfactorykeeper.NewMsgServerImpl(*f) msgCreateDenom := tokenfactorytypes.NewMsgCreateDenom(contractAddr.String(), createDenom.Subdenom) if err := msgCreateDenom.ValidateBasic(); err != nil { return nil, errorsmod.Wrap(err, "failed validating MsgCreateDenom") } // Create denom resp, err := msgServer.CreateDenom( sdk.WrapSDKContext(ctx), msgCreateDenom, ) if err != nil { return nil, errorsmod.Wrap(err, "creating denom") } if createDenom.Metadata != nil { newDenom := resp.NewTokenDenom err := PerformSetMetadata(f, b, ctx, contractAddr, newDenom, *createDenom.Metadata) if err != nil { return nil, errorsmod.Wrap(err, "setting metadata") } } return resp.Marshal() } // mintTokens mints tokens of a specified denom to an address. func (m *Messenger) mintTokens(ctx sdk.Context, contractAddr sdk.AccAddress, mint *bindingstypes.MintTokens) ([]sdk.Event, [][]byte, error) { err := PerformMint(m.tokenFactory, m.bank, ctx, contractAddr, mint) if err != nil { return nil, nil, errorsmod.Wrap(err, "perform mint") } return nil, nil, nil } // PerformMint used with mintTokens to validate the mint message and mint through token factory. func PerformMint(f *tokenfactorykeeper.Keeper, b bankkeeper.Keeper, ctx sdk.Context, contractAddr sdk.AccAddress, mint *bindingstypes.MintTokens) error { if mint == nil { return wasmvmtypes.InvalidRequest{Err: "mint token null mint"} } rcpt, err := parseAddress(mint.MintToAddress) if err != nil { return err } coin := sdk.Coin{Denom: mint.Denom, Amount: mint.Amount} sdkMsg := tokenfactorytypes.NewMsgMint(contractAddr.String(), coin) if err = sdkMsg.ValidateBasic(); err != nil { return err } // Mint through token factory / message server msgServer := tokenfactorykeeper.NewMsgServerImpl(*f) _, err = msgServer.Mint(sdk.WrapSDKContext(ctx), sdkMsg) if err != nil { return errorsmod.Wrap(err, "minting coins from message") } if b.BlockedAddr(rcpt) { return errorsmod.Wrapf(err, "minting coins to blocked address %s", rcpt.String()) } err = b.SendCoins(ctx, contractAddr, rcpt, sdk.NewCoins(coin)) if err != nil { return errorsmod.Wrap(err, "sending newly minted coins from message") } return nil } // changeAdmin changes the admin. func (m *Messenger) changeAdmin(ctx sdk.Context, contractAddr sdk.AccAddress, changeAdmin *bindingstypes.ChangeAdmin) ([]sdk.Event, [][]byte, error) { err := ChangeAdmin(m.tokenFactory, ctx, contractAddr, changeAdmin) if err != nil { return nil, nil, errorsmod.Wrap(err, "failed to change admin") } return nil, nil, nil } // ChangeAdmin is used with changeAdmin to validate changeAdmin messages and to dispatch. func ChangeAdmin(f *tokenfactorykeeper.Keeper, ctx sdk.Context, contractAddr sdk.AccAddress, changeAdmin *bindingstypes.ChangeAdmin) error { if changeAdmin == nil { return wasmvmtypes.InvalidRequest{Err: "changeAdmin is nil"} } newAdminAddr, err := parseAddress(changeAdmin.NewAdminAddress) if err != nil { return err } changeAdminMsg := tokenfactorytypes.NewMsgChangeAdmin(contractAddr.String(), changeAdmin.Denom, newAdminAddr.String()) if err := changeAdminMsg.ValidateBasic(); err != nil { return err } msgServer := tokenfactorykeeper.NewMsgServerImpl(*f) _, err = msgServer.ChangeAdmin(sdk.WrapSDKContext(ctx), changeAdminMsg) if err != nil { return errorsmod.Wrap(err, "failed changing admin from message") } return nil } // burnTokens burns tokens. func (m *Messenger) burnTokens(ctx sdk.Context, contractAddr sdk.AccAddress, burn *bindingstypes.BurnTokens) ([]sdk.Event, [][]byte, error) { err := PerformBurn(m.tokenFactory, ctx, contractAddr, burn) if err != nil { return nil, nil, errorsmod.Wrap(err, "perform burn") } return nil, nil, nil } // PerformBurn performs token burning after validating tokenBurn message. func PerformBurn(f *tokenfactorykeeper.Keeper, ctx sdk.Context, contractAddr sdk.AccAddress, burn *bindingstypes.BurnTokens) error { if burn == nil { return wasmvmtypes.InvalidRequest{Err: "burn token null mint"} } coin := sdk.Coin{Denom: burn.Denom, Amount: burn.Amount} sdkMsg := tokenfactorytypes.NewMsgBurn(contractAddr.String(), coin) if burn.BurnFromAddress != "" { sdkMsg = tokenfactorytypes.NewMsgBurnFrom(contractAddr.String(), coin, burn.BurnFromAddress) } if err := sdkMsg.ValidateBasic(); err != nil { return err } // Burn through token factory / message server msgServer := tokenfactorykeeper.NewMsgServerImpl(*f) _, err := msgServer.Burn(sdk.WrapSDKContext(ctx), sdkMsg) if err != nil { return errorsmod.Wrap(err, "burning coins from message") } return nil } // forceTransfer moves tokens. func (m *Messenger) forceTransfer(ctx sdk.Context, contractAddr sdk.AccAddress, forcetransfer *bindingstypes.ForceTransfer) ([]sdk.Event, [][]byte, error) { err := PerformForceTransfer(m.tokenFactory, ctx, contractAddr, forcetransfer) if err != nil { return nil, nil, errorsmod.Wrap(err, "perform force transfer") } return nil, nil, nil } // PerformForceTransfer performs token moving after validating tokenForceTransfer message. func PerformForceTransfer(f *tokenfactorykeeper.Keeper, ctx sdk.Context, contractAddr sdk.AccAddress, forcetransfer *bindingstypes.ForceTransfer) error { if forcetransfer == nil { return wasmvmtypes.InvalidRequest{Err: "force transfer null"} } _, err := parseAddress(forcetransfer.FromAddress) if err != nil { return err } _, err = parseAddress(forcetransfer.ToAddress) if err != nil { return err } coin := sdk.Coin{Denom: forcetransfer.Denom, Amount: forcetransfer.Amount} sdkMsg := tokenfactorytypes.NewMsgForceTransfer(contractAddr.String(), coin, forcetransfer.FromAddress, forcetransfer.ToAddress) if err := sdkMsg.ValidateBasic(); err != nil { return err } // Transfer through token factory / message server msgServer := tokenfactorykeeper.NewMsgServerImpl(*f) _, err = msgServer.ForceTransfer(sdk.WrapSDKContext(ctx), sdkMsg) if err != nil { return errorsmod.Wrap(err, "force transferring from message") } return nil } // createDenom creates a new token denom func (m *Messenger) setMetadata(ctx sdk.Context, contractAddr sdk.AccAddress, setMetadata *bindingstypes.SetMetadata) ([]sdk.Event, [][]byte, error) { err := PerformSetMetadata(m.tokenFactory, m.bank, ctx, contractAddr, setMetadata.Denom, setMetadata.Metadata) if err != nil { return nil, nil, errorsmod.Wrap(err, "perform create denom") } return nil, nil, nil } // PerformSetMetadata is used with setMetadata to add new metadata // It also is called inside CreateDenom if optional metadata field is set func PerformSetMetadata(f *tokenfactorykeeper.Keeper, b bankkeeper.Keeper, ctx sdk.Context, contractAddr sdk.AccAddress, denom string, metadata bindingstypes.Metadata) error { // ensure contract address is admin of denom auth, err := f.GetAuthorityMetadata(ctx, denom) if err != nil { return err } if auth.Admin != contractAddr.String() { return wasmvmtypes.InvalidRequest{Err: "only admin can set metadata"} } // ensure we are setting proper denom metadata (bank uses Base field, fill it if missing) if metadata.Base == "" { metadata.Base = denom } else if metadata.Base != denom { // this is the key that we set return wasmvmtypes.InvalidRequest{Err: "Base must be the same as denom"} } // Create and validate the metadata bankMetadata := WasmMetadataToSdk(metadata) if err := bankMetadata.Validate(); err != nil { return err } b.SetDenomMetaData(ctx, bankMetadata) return nil } // GetFullDenom is a function, not method, so the message_plugin can use it func GetFullDenom(contract string, subDenom string) (string, error) { // Address validation if _, err := parseAddress(contract); err != nil { return "", err } fullDenom, err := tokenfactorytypes.GetTokenDenom(contract, subDenom) if err != nil { return "", errorsmod.Wrap(err, "validate sub-denom") } return fullDenom, nil } // parseAddress parses address from bech32 string and verifies its format. func parseAddress(addr string) (sdk.AccAddress, error) { parsed, err := sdk.AccAddressFromBech32(addr) if err != nil { return nil, errorsmod.Wrap(err, "address from bech32") } err = sdk.VerifyAddressFormat(parsed) if err != nil { return nil, errorsmod.Wrap(err, "verify address format") } return parsed, nil } func WasmMetadataToSdk(metadata bindingstypes.Metadata) banktypes.Metadata { denoms := []*banktypes.DenomUnit{} for _, unit := range metadata.DenomUnits { denoms = append(denoms, &banktypes.DenomUnit{ Denom: unit.Denom, Exponent: unit.Exponent, Aliases: unit.Aliases, }) } return banktypes.Metadata{ Description: metadata.Description, Display: metadata.Display, Base: metadata.Base, Name: metadata.Name, Symbol: metadata.Symbol, DenomUnits: denoms, } } func SdkMetadataToWasm(metadata banktypes.Metadata) *bindingstypes.Metadata { denoms := []bindingstypes.DenomUnit{} for _, unit := range metadata.DenomUnits { denoms = append(denoms, bindingstypes.DenomUnit{ Denom: unit.Denom, Exponent: unit.Exponent, Aliases: unit.Aliases, }) } return &bindingstypes.Metadata{ Description: metadata.Description, Display: metadata.Display, Base: metadata.Base, Name: metadata.Name, Symbol: metadata.Symbol, DenomUnits: denoms, } } ================================================ FILE: x/tokenfactory/wasm/queries.go ================================================ package wasm import ( "fmt" sdk "github.com/cosmos/cosmos-sdk/types" bankkeeper "github.com/cosmos/cosmos-sdk/x/bank/keeper" tokenfactorykeeper "github.com/cybercongress/go-cyber/v7/x/tokenfactory/keeper" bindingstypes "github.com/cybercongress/go-cyber/v7/x/tokenfactory/wasm/types" ) type Querier struct { bankKeeper bankkeeper.Keeper tokenFactoryKeeper *tokenfactorykeeper.Keeper } func NewWasmQuerier(b bankkeeper.Keeper, tfk *tokenfactorykeeper.Keeper) *Querier { return &Querier{ bankKeeper: b, tokenFactoryKeeper: tfk, } } // GetDenomAdmin is a query to get denom admin. func (querier *Querier) GetDenomAdmin(ctx sdk.Context, denom string) (*bindingstypes.AdminResponse, error) { metadata, err := querier.tokenFactoryKeeper.GetAuthorityMetadata(ctx, denom) if err != nil { return nil, fmt.Errorf("failed to get admin for denom: %s", denom) } return &bindingstypes.AdminResponse{Admin: metadata.Admin}, nil } func (querier *Querier) GetDenomsByCreator(ctx sdk.Context, creator string) (*bindingstypes.DenomsByCreatorResponse, error) { // TODO: validate creator address denoms := querier.tokenFactoryKeeper.GetDenomsFromCreator(ctx, creator) return &bindingstypes.DenomsByCreatorResponse{Denoms: denoms}, nil } func (querier *Querier) GetMetadata(ctx sdk.Context, denom string) (*bindingstypes.MetadataResponse, error) { metadata, found := querier.bankKeeper.GetDenomMetaData(ctx, denom) var parsed *bindingstypes.Metadata if found { parsed = SdkMetadataToWasm(metadata) } return &bindingstypes.MetadataResponse{Metadata: parsed}, nil } func (querier *Querier) GetParams(ctx sdk.Context) (*bindingstypes.ParamsResponse, error) { params := querier.tokenFactoryKeeper.GetParams(ctx) return &bindingstypes.ParamsResponse{ Params: bindingstypes.Params{ DenomCreationFee: ConvertSdkCoinsToWasmCoins(params.DenomCreationFee), }, }, nil } ================================================ FILE: x/tokenfactory/wasm/query_plugin.go ================================================ package wasm import ( "encoding/json" "fmt" pluginstypes "github.com/cybercongress/go-cyber/v7/plugins/types" wasmvmtypes "github.com/CosmWasm/wasmvm/types" errorsmod "cosmossdk.io/errors" sdk "github.com/cosmos/cosmos-sdk/types" bindingstypes "github.com/cybercongress/go-cyber/v7/x/tokenfactory/wasm/types" ) // CustomQuerier dispatches custom CosmWasm wasm queries. func (querier *Querier) HandleQuery(ctx sdk.Context, query pluginstypes.CyberQuery) ([]byte, error) { //var contractQuery = query.TokenFactory switch { case query.FullDenom != nil: creator := query.FullDenom.CreatorAddr subdenom := query.FullDenom.Subdenom fullDenom, err := GetFullDenom(creator, subdenom) if err != nil { return nil, errorsmod.Wrap(err, "osmo full denom query") } res := bindingstypes.FullDenomResponse{ Denom: fullDenom, } bz, err := json.Marshal(res) if err != nil { return nil, errorsmod.Wrap(err, "failed to marshal FullDenomResponse") } return bz, nil case query.Admin != nil: res, err := querier.GetDenomAdmin(ctx, query.Admin.Denom) if err != nil { return nil, err } bz, err := json.Marshal(res) if err != nil { return nil, fmt.Errorf("failed to JSON marshal AdminResponse: %w", err) } return bz, nil case query.Metadata != nil: res, err := querier.GetMetadata(ctx, query.Metadata.Denom) if err != nil { return nil, err } bz, err := json.Marshal(res) if err != nil { return nil, fmt.Errorf("failed to JSON marshal MetadataResponse: %w", err) } return bz, nil case query.DenomsByCreator != nil: res, err := querier.GetDenomsByCreator(ctx, query.DenomsByCreator.Creator) if err != nil { return nil, err } bz, err := json.Marshal(res) if err != nil { return nil, fmt.Errorf("failed to JSON marshal DenomsByCreatorResponse: %w", err) } return bz, nil case query.Params != nil: res, err := querier.GetParams(ctx) if err != nil { return nil, err } bz, err := json.Marshal(res) if err != nil { return nil, fmt.Errorf("failed to JSON marshal ParamsResponse: %w", err) } return bz, nil default: return nil, pluginstypes.ErrHandleQuery } //} } // ConvertSdkCoinsToWasmCoins converts sdk type coins to wasm vm type coins func ConvertSdkCoinsToWasmCoins(coins []sdk.Coin) wasmvmtypes.Coins { var toSend wasmvmtypes.Coins for _, coin := range coins { c := ConvertSdkCoinToWasmCoin(coin) toSend = append(toSend, c) } return toSend } // ConvertSdkCoinToWasmCoin converts a sdk type coin to a wasm vm type coin func ConvertSdkCoinToWasmCoin(coin sdk.Coin) wasmvmtypes.Coin { return wasmvmtypes.Coin{ Denom: coin.Denom, // Note: tokenfactory tokens have 18 decimal places, so 10^22 is common, no longer in u64 range Amount: coin.Amount.String(), } } ================================================ FILE: x/tokenfactory/wasm/types/msg.go ================================================ package types import "cosmossdk.io/math" type TokenFactoryMsg struct { /// Contracts can create denoms, namespaced under the contract's address. /// A contract may create any number of independent sub-denoms. CreateDenom *CreateDenom `json:"create_denom,omitempty"` /// Contracts can change the admin of a denom that they are the admin of. ChangeAdmin *ChangeAdmin `json:"change_admin,omitempty"` /// Contracts can mint native tokens for an existing factory denom /// that they are the admin of. MintTokens *MintTokens `json:"mint_tokens,omitempty"` /// Contracts can burn native tokens for an existing factory denom /// that they are the admin of. /// Currently, the burn from address must be the admin contract. BurnTokens *BurnTokens `json:"burn_tokens,omitempty"` /// Sets the metadata on a denom which the contract controls SetMetadata *SetMetadata `json:"set_metadata,omitempty"` /// Forces a transfer of tokens from one address to another. ForceTransfer *ForceTransfer `json:"force_transfer,omitempty"` } // CreateDenom creates a new factory denom, of denomination: // factory/{creating contract address}/{Subdenom} // Subdenom can be of length at most 44 characters, in [0-9a-zA-Z./] // The (creating contract address, subdenom) pair must be unique. // The created denom's admin is the creating contract address, // but this admin can be changed using the ChangeAdmin binding. type CreateDenom struct { Subdenom string `json:"subdenom"` Metadata *Metadata `json:"metadata,omitempty"` } // ChangeAdmin changes the admin for a factory denom. // If the NewAdminAddress is empty, the denom has no admin. type ChangeAdmin struct { Denom string `json:"denom"` NewAdminAddress string `json:"new_admin_address"` } type MintTokens struct { Denom string `json:"denom"` Amount math.Int `json:"amount"` MintToAddress string `json:"mint_to_address"` } type BurnTokens struct { Denom string `json:"denom"` Amount math.Int `json:"amount"` BurnFromAddress string `json:"burn_from_address"` } type SetMetadata struct { Denom string `json:"denom"` Metadata Metadata `json:"metadata"` } type ForceTransfer struct { Denom string `json:"denom"` Amount math.Int `json:"amount"` FromAddress string `json:"from_address"` ToAddress string `json:"to_address"` } ================================================ FILE: x/tokenfactory/wasm/types/query.go ================================================ package types // See https://github.com/CosmWasm/token-bindings/blob/main/packages/bindings/src/query.rs type TokenFactoryQuery struct { /// Given a subdenom minted by a contract via `OsmosisMsg::MintTokens`, /// returns the full denom as used by `BankMsg::Send`. FullDenom *FullDenom `json:"full_denom,omitempty"` Admin *DenomAdmin `json:"admin,omitempty"` Metadata *GetMetadata `json:"metadata,omitempty"` DenomsByCreator *DenomsByCreator `json:"denoms_by_creator,omitempty"` Params *GetParams `json:"params,omitempty"` } // query types type FullDenom struct { CreatorAddr string `json:"creator_addr"` Subdenom string `json:"subdenom"` } type GetMetadata struct { Denom string `json:"denom"` } type DenomAdmin struct { Denom string `json:"denom"` } type DenomsByCreator struct { Creator string `json:"creator"` } type GetParams struct{} // responses type FullDenomResponse struct { Denom string `json:"denom"` } type AdminResponse struct { Admin string `json:"admin"` } type MetadataResponse struct { Metadata *Metadata `json:"metadata,omitempty"` } type DenomsByCreatorResponse struct { Denoms []string `json:"denoms"` } type ParamsResponse struct { Params Params `json:"params"` } ================================================ FILE: x/tokenfactory/wasm/types/types.go ================================================ package types import ( wasmvmtypes "github.com/CosmWasm/wasmvm/types" ) type Metadata struct { Description string `json:"description"` // DenomUnits represents the list of DenomUnit's for a given coin DenomUnits []DenomUnit `json:"denom_units"` // Base represents the base denom (should be the DenomUnit with exponent = 0). Base string `json:"base"` // Display indicates the suggested denom that should be displayed in clients. Display string `json:"display"` // Name defines the name of the token (eg: Cosmos Atom) Name string `json:"name"` // Symbol is the token symbol usually shown on exchanges (eg: ATOM). // This can be the same as the display. Symbol string `json:"symbol"` } type DenomUnit struct { // Denom represents the string name of the given denom unit (e.g uatom). Denom string `json:"denom"` // Exponent represents power of 10 exponent that one must // raise the base_denom to in order to equal the given DenomUnit's denom // 1 denom = 1^exponent base_denom // (e.g. with a base_denom of uatom, one can create a DenomUnit of 'atom' with // exponent = 6, thus: 1 atom = 10^6 uatom). Exponent uint32 `json:"exponent"` // Aliases is a list of string aliases for the given denom Aliases []string `json:"aliases"` } type Params struct { DenomCreationFee []wasmvmtypes.Coin `json:"denom_creation_fee"` } ================================================ FILE: x/tokenfactory/wasm/validate_msg_test.go ================================================ package wasm_test import ( "fmt" bindings "github.com/cybercongress/go-cyber/v7/x/tokenfactory/wasm/types" "testing" "github.com/stretchr/testify/require" sdk "github.com/cosmos/cosmos-sdk/types" "github.com/cybercongress/go-cyber/v7/x/tokenfactory/types" wasmbinding "github.com/cybercongress/go-cyber/v7/x/tokenfactory/wasm" ) func TestCreateDenom(t *testing.T) { actor := RandomAccountAddress() junoapp, ctx := SetupCustomApp(t, actor) // Fund actor with 100 base denom creation fees actorAmount := sdk.NewCoins(sdk.NewCoin(types.DefaultParams().DenomCreationFee[0].Denom, types.DefaultParams().DenomCreationFee[0].Amount.MulRaw(100))) fundAccount(t, ctx, junoapp, actor, actorAmount) specs := map[string]struct { createDenom *bindings.CreateDenom expErr bool }{ "valid sub-denom": { createDenom: &bindings.CreateDenom{ Subdenom: "MOON", }, }, "empty sub-denom": { createDenom: &bindings.CreateDenom{ Subdenom: "", }, expErr: false, }, "invalid sub-denom": { createDenom: &bindings.CreateDenom{ Subdenom: "sub-denom_2", }, expErr: false, }, "null create denom": { createDenom: nil, expErr: true, }, } for name, spec := range specs { t.Run(name, func(t *testing.T) { // when _, gotErr := wasmbinding.PerformCreateDenom(&junoapp.AppKeepers.TokenFactoryKeeper, junoapp.AppKeepers.BankKeeper, ctx, actor, spec.createDenom) // then if spec.expErr { t.Logf("validate_msg_test got error: %v", gotErr) require.Error(t, gotErr) return } require.NoError(t, gotErr) }) } } func TestChangeAdmin(t *testing.T) { const validDenom = "validdenom" tokenCreator := RandomAccountAddress() specs := map[string]struct { actor sdk.AccAddress changeAdmin *bindings.ChangeAdmin expErrMsg string }{ "valid": { changeAdmin: &bindings.ChangeAdmin{ Denom: fmt.Sprintf("factory/%s/%s", tokenCreator.String(), validDenom), NewAdminAddress: RandomBech32AccountAddress(), }, actor: tokenCreator, }, "typo in factory in denom name": { changeAdmin: &bindings.ChangeAdmin{ Denom: fmt.Sprintf("facory/%s/%s", tokenCreator.String(), validDenom), NewAdminAddress: RandomBech32AccountAddress(), }, actor: tokenCreator, expErrMsg: "denom prefix is incorrect. Is: facory. Should be: factory: invalid denom", }, "invalid address in denom": { changeAdmin: &bindings.ChangeAdmin{ Denom: fmt.Sprintf("factory/%s/%s", RandomBech32AccountAddress(), validDenom), NewAdminAddress: RandomBech32AccountAddress(), }, actor: tokenCreator, expErrMsg: "failed changing admin from message: unauthorized account", }, "other denom name in 3 part name": { changeAdmin: &bindings.ChangeAdmin{ Denom: fmt.Sprintf("factory/%s/%s", tokenCreator.String(), "invalid denom"), NewAdminAddress: RandomBech32AccountAddress(), }, actor: tokenCreator, expErrMsg: fmt.Sprintf("invalid denom: factory/%s/invalid denom", tokenCreator.String()), }, "empty denom": { changeAdmin: &bindings.ChangeAdmin{ Denom: "", NewAdminAddress: RandomBech32AccountAddress(), }, actor: tokenCreator, expErrMsg: "invalid denom: ", }, "empty address": { changeAdmin: &bindings.ChangeAdmin{ Denom: fmt.Sprintf("factory/%s/%s", tokenCreator.String(), validDenom), NewAdminAddress: "", }, actor: tokenCreator, expErrMsg: "address from bech32: empty address string is not allowed", }, "creator is a different address": { changeAdmin: &bindings.ChangeAdmin{ Denom: fmt.Sprintf("factory/%s/%s", tokenCreator.String(), validDenom), NewAdminAddress: RandomBech32AccountAddress(), }, actor: RandomAccountAddress(), expErrMsg: "failed changing admin from message: unauthorized account", }, "change to the same address": { changeAdmin: &bindings.ChangeAdmin{ Denom: fmt.Sprintf("factory/%s/%s", tokenCreator.String(), validDenom), NewAdminAddress: tokenCreator.String(), }, actor: tokenCreator, }, "nil binding": { actor: tokenCreator, expErrMsg: "invalid request: changeAdmin is nil - original request: ", }, } for name, spec := range specs { t.Run(name, func(t *testing.T) { // Setup junoapp, ctx := SetupCustomApp(t, tokenCreator) // Fund actor with 100 base denom creation fees actorAmount := sdk.NewCoins(sdk.NewCoin(types.DefaultParams().DenomCreationFee[0].Denom, types.DefaultParams().DenomCreationFee[0].Amount.MulRaw(100))) fundAccount(t, ctx, junoapp, tokenCreator, actorAmount) _, err := wasmbinding.PerformCreateDenom(&junoapp.AppKeepers.TokenFactoryKeeper, junoapp.AppKeepers.BankKeeper, ctx, tokenCreator, &bindings.CreateDenom{ Subdenom: validDenom, }) require.NoError(t, err) err = wasmbinding.ChangeAdmin(&junoapp.AppKeepers.TokenFactoryKeeper, ctx, spec.actor, spec.changeAdmin) if len(spec.expErrMsg) > 0 { require.Error(t, err) actualErrMsg := err.Error() require.Equal(t, spec.expErrMsg, actualErrMsg) return } require.NoError(t, err) }) } } func TestMint(t *testing.T) { creator := RandomAccountAddress() junoapp, ctx := SetupCustomApp(t, creator) // Fund actor with 100 base denom creation fees tokenCreationFeeAmt := sdk.NewCoins(sdk.NewCoin(types.DefaultParams().DenomCreationFee[0].Denom, types.DefaultParams().DenomCreationFee[0].Amount.MulRaw(100))) fundAccount(t, ctx, junoapp, creator, tokenCreationFeeAmt) // Create denoms for valid mint tests validDenom := bindings.CreateDenom{ Subdenom: "MOON", } _, err := wasmbinding.PerformCreateDenom(&junoapp.AppKeepers.TokenFactoryKeeper, junoapp.AppKeepers.BankKeeper, ctx, creator, &validDenom) require.NoError(t, err) emptyDenom := bindings.CreateDenom{ Subdenom: "", } _, err = wasmbinding.PerformCreateDenom(&junoapp.AppKeepers.TokenFactoryKeeper, junoapp.AppKeepers.BankKeeper, ctx, creator, &emptyDenom) require.NoError(t, err) validDenomStr := fmt.Sprintf("factory/%s/%s", creator.String(), validDenom.Subdenom) emptyDenomStr := fmt.Sprintf("factory/%s/%s", creator.String(), emptyDenom.Subdenom) lucky := RandomAccountAddress() // lucky was broke balances := junoapp.AppKeepers.BankKeeper.GetAllBalances(ctx, lucky) require.Empty(t, balances) amount, ok := sdk.NewIntFromString("8080") require.True(t, ok) specs := map[string]struct { mint *bindings.MintTokens expErr bool }{ "valid mint": { mint: &bindings.MintTokens{ Denom: validDenomStr, Amount: amount, MintToAddress: lucky.String(), }, }, "empty sub-denom": { mint: &bindings.MintTokens{ Denom: emptyDenomStr, Amount: amount, MintToAddress: lucky.String(), }, expErr: false, }, "nonexistent sub-denom": { mint: &bindings.MintTokens{ Denom: fmt.Sprintf("factory/%s/%s", creator.String(), "SUN"), Amount: amount, MintToAddress: lucky.String(), }, expErr: true, }, "invalid sub-denom": { mint: &bindings.MintTokens{ Denom: "sub-denom_2", Amount: amount, MintToAddress: lucky.String(), }, expErr: true, }, "zero amount": { mint: &bindings.MintTokens{ Denom: validDenomStr, Amount: sdk.ZeroInt(), MintToAddress: lucky.String(), }, expErr: true, }, "negative amount": { mint: &bindings.MintTokens{ Denom: validDenomStr, Amount: amount.Neg(), MintToAddress: lucky.String(), }, expErr: true, }, "empty recipient": { mint: &bindings.MintTokens{ Denom: validDenomStr, Amount: amount, MintToAddress: "", }, expErr: true, }, "invalid recipient": { mint: &bindings.MintTokens{ Denom: validDenomStr, Amount: amount, MintToAddress: "invalid", }, expErr: true, }, "null mint": { mint: nil, expErr: true, }, } for name, spec := range specs { t.Run(name, func(t *testing.T) { // when gotErr := wasmbinding.PerformMint(&junoapp.AppKeepers.TokenFactoryKeeper, junoapp.AppKeepers.BankKeeper, ctx, creator, spec.mint) // then if spec.expErr { require.Error(t, gotErr) return } require.NoError(t, gotErr) }) } } func TestBurn(t *testing.T) { creator := RandomAccountAddress() junoapp, ctx := SetupCustomApp(t, creator) // Fund actor with 100 base denom creation fees tokenCreationFeeAmt := sdk.NewCoins(sdk.NewCoin(types.DefaultParams().DenomCreationFee[0].Denom, types.DefaultParams().DenomCreationFee[0].Amount.MulRaw(100))) fundAccount(t, ctx, junoapp, creator, tokenCreationFeeAmt) // Create denoms for valid burn tests validDenom := bindings.CreateDenom{ Subdenom: "MOON", } _, err := wasmbinding.PerformCreateDenom(&junoapp.AppKeepers.TokenFactoryKeeper, junoapp.AppKeepers.BankKeeper, ctx, creator, &validDenom) require.NoError(t, err) emptyDenom := bindings.CreateDenom{ Subdenom: "", } _, err = wasmbinding.PerformCreateDenom(&junoapp.AppKeepers.TokenFactoryKeeper, junoapp.AppKeepers.BankKeeper, ctx, creator, &emptyDenom) require.NoError(t, err) lucky := RandomAccountAddress() // lucky was broke balances := junoapp.AppKeepers.BankKeeper.GetAllBalances(ctx, lucky) require.Empty(t, balances) validDenomStr := fmt.Sprintf("factory/%s/%s", creator.String(), validDenom.Subdenom) emptyDenomStr := fmt.Sprintf("factory/%s/%s", creator.String(), emptyDenom.Subdenom) mintAmount, ok := sdk.NewIntFromString("8080") require.True(t, ok) specs := map[string]struct { burn *bindings.BurnTokens expErr bool }{ "valid burn": { burn: &bindings.BurnTokens{ Denom: validDenomStr, Amount: mintAmount, BurnFromAddress: creator.String(), }, expErr: false, }, "non admin address": { burn: &bindings.BurnTokens{ Denom: validDenomStr, Amount: mintAmount, BurnFromAddress: lucky.String(), }, expErr: true, }, "empty sub-denom": { burn: &bindings.BurnTokens{ Denom: emptyDenomStr, Amount: mintAmount, BurnFromAddress: creator.String(), }, expErr: false, }, "invalid sub-denom": { burn: &bindings.BurnTokens{ Denom: "sub-denom_2", Amount: mintAmount, BurnFromAddress: creator.String(), }, expErr: true, }, "non-minted denom": { burn: &bindings.BurnTokens{ Denom: fmt.Sprintf("factory/%s/%s", creator.String(), "SUN"), Amount: mintAmount, BurnFromAddress: creator.String(), }, expErr: true, }, "zero amount": { burn: &bindings.BurnTokens{ Denom: validDenomStr, Amount: sdk.ZeroInt(), BurnFromAddress: creator.String(), }, expErr: true, }, "negative amount": { burn: nil, expErr: true, }, "null burn": { burn: &bindings.BurnTokens{ Denom: validDenomStr, Amount: mintAmount.Neg(), BurnFromAddress: creator.String(), }, expErr: true, }, } for name, spec := range specs { t.Run(name, func(t *testing.T) { // Mint valid denom str and empty denom string for burn test mintBinding := &bindings.MintTokens{ Denom: validDenomStr, Amount: mintAmount, MintToAddress: creator.String(), } err := wasmbinding.PerformMint(&junoapp.AppKeepers.TokenFactoryKeeper, junoapp.AppKeepers.BankKeeper, ctx, creator, mintBinding) require.NoError(t, err) emptyDenomMintBinding := &bindings.MintTokens{ Denom: emptyDenomStr, Amount: mintAmount, MintToAddress: creator.String(), } err = wasmbinding.PerformMint(&junoapp.AppKeepers.TokenFactoryKeeper, junoapp.AppKeepers.BankKeeper, ctx, creator, emptyDenomMintBinding) require.NoError(t, err) // when gotErr := wasmbinding.PerformBurn(&junoapp.AppKeepers.TokenFactoryKeeper, ctx, creator, spec.burn) // then if spec.expErr { require.Error(t, gotErr) return } require.NoError(t, gotErr) }) } } ================================================ FILE: x/tokenfactory/wasm/validate_queries_test.go ================================================ package wasm_test import ( "fmt" sdk "github.com/cosmos/cosmos-sdk/types" wasmbinding "github.com/cybercongress/go-cyber/v7/x/tokenfactory/wasm" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" "testing" ) func TestFullDenom(t *testing.T) { actor := RandomAccountAddress() specs := map[string]struct { addr string subdenom string expFullDenom string expErr bool }{ "valid address": { addr: actor.String(), subdenom: "subDenom1", expFullDenom: fmt.Sprintf("factory/%s/subDenom1", actor.String()), }, "empty address": { addr: "", subdenom: "subDenom1", expErr: true, }, "invalid address": { addr: "invalid", subdenom: "subDenom1", expErr: true, }, "empty sub-denom": { addr: actor.String(), subdenom: "", expFullDenom: fmt.Sprintf("factory/%s/", actor.String()), }, "valid sub-denom (contains underscore)": { addr: actor.String(), subdenom: "sub_denom", expFullDenom: fmt.Sprintf("factory/%s/sub_denom", actor.String()), }, } for name, spec := range specs { t.Run(name, func(t *testing.T) { // when gotFullDenom, gotErr := wasmbinding.GetFullDenom(spec.addr, spec.subdenom) // then if spec.expErr { require.Error(t, gotErr) return } require.NoError(t, gotErr) assert.Equal(t, spec.expFullDenom, gotFullDenom, "exp %s but got %s", spec.expFullDenom, gotFullDenom) }) } } func TestDenomAdmin(t *testing.T) { addr := RandomAccountAddress() app, ctx := SetupCustomApp(t, addr) // set token creation fee to zero to make testing easier tfParams := app.AppKeepers.TokenFactoryKeeper.GetParams(ctx) tfParams.DenomCreationFee = sdk.NewCoins() if err := app.AppKeepers.TokenFactoryKeeper.SetParams(ctx, tfParams); err != nil { t.Fatal(err) } // create a subdenom via the token factory admin := sdk.AccAddress([]byte("addr1_______________")) tfDenom, err := app.AppKeepers.TokenFactoryKeeper.CreateDenom(ctx, admin.String(), "subdenom") require.NoError(t, err) require.NotEmpty(t, tfDenom) queryPlugin := wasmbinding.NewQueryPlugin(app.AppKeepers.BankKeeper, &app.AppKeepers.TokenFactoryKeeper) testCases := []struct { name string denom string expectErr bool expectAdmin string }{ { name: "valid token factory denom", denom: tfDenom, expectAdmin: admin.String(), }, { name: "invalid token factory denom", denom: "uosmo", expectErr: false, expectAdmin: "", }, } for _, tc := range testCases { tc := tc t.Run(tc.name, func(t *testing.T) { resp, err := queryPlugin.GetDenomAdmin(ctx, tc.denom) if tc.expectErr { require.Error(t, err) } else { require.NoError(t, err) require.NotNil(t, resp) require.Equal(t, tc.expectAdmin, resp.Admin) } }) } }