From b6fca6487e4ebbc9894492724d9c76ede54ff963 Mon Sep 17 00:00:00 2001 From: ctrl-felix <62290842+ctrl-Felix@users.noreply.github.com> Date: Mon, 1 Aug 2022 13:14:41 +0200 Subject: [PATCH] refactor files & add automated protobuf aggregation --- .gitignore | 4 +- README.md | 24 +- aggregate.py | 79 ++++ configs/cosmos.json | 32 ++ configs/osmosis.json | 37 ++ pyproject.toml | 4 +- .../akash/audit/v1beta1/audit.proto | 99 ----- .../akash/audit/v1beta2/audit.proto | 99 ----- .../akash/audit/v1beta2/genesis.proto | 13 - .../akash/audit/v1beta2/query.proto | 79 ---- .../akash/base/v1beta1/attribute.proto | 41 -- .../akash/base/v1beta1/endpoint.proto | 19 - .../akash/base/v1beta1/resource.proto | 68 --- .../akash/base/v1beta1/resourcevalue.proto | 12 - .../akash/base/v1beta2/attribute.proto | 41 -- .../akash/base/v1beta2/endpoint.proto | 23 - .../akash/base/v1beta2/resource.proto | 56 --- .../akash/base/v1beta2/resourceunits.proto | 37 -- .../akash/base/v1beta2/resourcevalue.proto | 15 - .../akash/cert/v1beta2/cert.proto | 118 ------ .../akash/cert/v1beta2/genesis.proto | 31 -- .../akash/cert/v1beta2/query.proto | 50 --- .../akash/deployment/v1beta1/authz.proto | 21 - .../akash/deployment/v1beta1/deployment.proto | 152 ------- .../akash/deployment/v1beta1/genesis.proto | 33 -- .../akash/deployment/v1beta1/group.proto | 128 ------ .../akash/deployment/v1beta1/params.proto | 16 - .../akash/deployment/v1beta1/query.proto | 71 ---- .../akash/deployment/v1beta2/authz.proto | 21 - .../akash/deployment/v1beta2/deployment.proto | 75 ---- .../deployment/v1beta2/deploymentmsg.proto | 106 ----- .../akash/deployment/v1beta2/genesis.proto | 39 -- .../akash/deployment/v1beta2/group.proto | 48 --- .../akash/deployment/v1beta2/groupid.proto | 27 -- .../akash/deployment/v1beta2/groupmsg.proto | 52 --- .../akash/deployment/v1beta2/groupspec.proto | 31 -- .../akash/deployment/v1beta2/params.proto | 18 - .../akash/deployment/v1beta2/query.proto | 72 ---- .../akash/deployment/v1beta2/resource.proto | 28 -- .../akash/deployment/v1beta2/service.proto | 31 -- .../akash/escrow/v1beta1/genesis.proto | 22 - .../akash/escrow/v1beta1/query.proto | 58 --- .../akash/escrow/v1beta1/types.proto | 139 ------ .../akash/escrow/v1beta2/genesis.proto | 22 - .../akash/escrow/v1beta2/query.proto | 58 --- .../akash/escrow/v1beta2/types.proto | 155 ------- .../akash/inflation/v1beta2/genesis.proto | 16 - .../akash/inflation/v1beta2/params.proto | 37 -- .../akash/market/v1beta2/bid.proto | 109 ----- .../akash/market/v1beta2/genesis.proto | 24 -- .../akash/market/v1beta2/lease.proto | 117 ------ .../akash/market/v1beta2/order.proto | 74 ---- .../akash/market/v1beta2/params.proto | 21 - .../akash/market/v1beta2/query.proto | 123 ------ .../akash/market/v1beta2/service.proto | 24 -- .../akash/provider/v1beta1/provider.proto | 120 ------ .../akash/provider/v1beta2/genesis.proto | 16 - .../akash/provider/v1beta2/provider.proto | 120 ------ .../akash/provider/v1beta2/query.proto | 44 -- .../bitsong/fantoken/v1beta1/events.proto | 40 -- .../bitsong/fantoken/v1beta1/fantoken.proto | 46 -- .../bitsong/fantoken/v1beta1/genesis.proto | 17 - .../bitsong/fantoken/v1beta1/gov.proto | 42 -- .../bitsong/fantoken/v1beta1/params.proto | 29 -- .../bitsong/fantoken/v1beta1/query.proto | 57 --- .../bitsong/fantoken/v1beta1/tx.proto | 135 ------ .../bitsong/merkledrop/v1beta1/events.proto | 30 -- .../bitsong/merkledrop/v1beta1/genesis.proto | 25 -- .../bitsong/merkledrop/v1beta1/gov.proto | 30 -- .../merkledrop/v1beta1/merkledrop.proto | 44 -- .../bitsong/merkledrop/v1beta1/params.proto | 20 - .../bitsong/merkledrop/v1beta1/query.proto | 51 --- .../bitsong/merkledrop/v1beta1/tx.proto | 60 --- .../cosmos/app/module/v1alpha1/module.proto | 13 - .../cosmos/app/v1alpha1/config.proto | 36 -- .../cosmos/app/v1alpha1/module.proto | 93 ----- .../cosmos/app/v1alpha1/query.proto | 22 - .../cosmos/auth/v1beta1/auth.proto | 47 --- .../cosmos/auth/v1beta1/genesis.proto | 17 - .../cosmos/auth/v1beta1/query.proto | 130 ------ .../cosmos/authz/v1beta1/authz.proto | 46 -- .../cosmos/authz/v1beta1/event.proto | 27 -- .../cosmos/authz/v1beta1/genesis.proto | 13 - .../cosmos/authz/v1beta1/query.proto | 82 ---- .../cosmos/authz/v1beta1/tx.proto | 75 ---- .../cosmos/bank/v1beta1/authz.proto | 19 - .../cosmos/bank/v1beta1/bank.proto | 108 ----- .../cosmos/bank/v1beta1/genesis.proto | 40 -- .../cosmos/bank/v1beta1/query.proto | 231 ---------- .../cosmos/bank/v1beta1/tx.proto | 48 --- .../cosmos/base/abci/v1beta1/abci.proto | 158 ------- .../cosmos/base/kv/v1beta1/kv.proto | 17 - .../base/query/v1beta1/pagination.proto | 56 --- .../base/reflection/v1beta1/reflection.proto | 44 -- .../base/reflection/v2alpha1/reflection.proto | 218 ---------- .../base/snapshots/v1beta1/snapshot.proto | 70 ---- .../base/store/v1beta1/commit_info.proto | 29 -- .../cosmos/base/store/v1beta1/listening.proto | 16 - .../base/tendermint/v1beta1/query.proto | 196 --------- .../cosmos/base/v1beta1/coin.proto | 43 -- .../capability/v1beta1/capability.proto | 30 -- .../cosmos/capability/v1beta1/genesis.proto | 26 -- .../cosmos/crisis/v1beta1/genesis.proto | 14 - .../cosmos/crisis/v1beta1/tx.proto | 29 -- .../cosmos/crypto/ed25519/keys.proto | 23 - .../cosmos/crypto/hd/v1/hd.proto | 23 - .../cosmos/crypto/keyring/v1/record.proto | 47 --- .../cosmos/crypto/multisig/keys.proto | 17 - .../crypto/multisig/v1beta1/multisig.proto | 25 -- .../cosmos/crypto/secp256k1/keys.proto | 22 - .../cosmos/crypto/secp256r1/keys.proto | 23 - .../distribution/v1beta1/distribution.proto | 152 ------- .../cosmos/distribution/v1beta1/genesis.proto | 144 ------- .../cosmos/distribution/v1beta1/query.proto | 219 ---------- .../cosmos/distribution/v1beta1/tx.proto | 97 ----- .../cosmos/evidence/v1beta1/evidence.proto | 22 - .../cosmos/evidence/v1beta1/genesis.proto | 12 - .../cosmos/evidence/v1beta1/query.proto | 51 --- .../cosmos/evidence/v1beta1/tx.proto | 35 -- .../cosmos/feegrant/v1beta1/feegrant.proto | 78 ---- .../cosmos/feegrant/v1beta1/genesis.proto | 13 - .../cosmos/feegrant/v1beta1/query.proto | 79 ---- .../cosmos/feegrant/v1beta1/tx.proto | 53 --- .../cosmos/genutil/v1beta1/genesis.proto | 12 - .../cosmos/gov/v1/genesis.proto | 26 -- src/cosmospy_protobuf/cosmos/gov/v1/gov.proto | 132 ------ .../cosmos/gov/v1/query.proto | 183 -------- src/cosmospy_protobuf/cosmos/gov/v1/tx.proto | 100 ----- .../cosmos/gov/v1beta1/genesis.proto | 26 -- .../cosmos/gov/v1beta1/gov.proto | 201 --------- .../cosmos/gov/v1beta1/query.proto | 191 --------- .../cosmos/gov/v1beta1/tx.proto | 106 ----- .../cosmos/group/v1/events.proto | 81 ---- .../cosmos/group/v1/genesis.proto | 39 -- .../cosmos/group/v1/query.proto | 313 -------------- .../cosmos/group/v1/tx.proto | 373 ----------------- .../cosmos/group/v1/types.proto | 318 -------------- .../cosmos/mint/v1beta1/genesis.proto | 16 - .../cosmos/mint/v1beta1/mint.proto | 57 --- .../cosmos/mint/v1beta1/query.proto | 57 --- src/cosmospy_protobuf/cosmos/msg/v1/msg.proto | 22 - .../cosmos/nft/v1beta1/event.proto | 26 -- .../cosmos/nft/v1beta1/genesis.proto | 22 - .../cosmos/nft/v1beta1/nft.proto | 48 --- .../cosmos/nft/v1beta1/query.proto | 125 ------ .../cosmos/nft/v1beta1/tx.proto | 30 -- .../cosmos/orm/module/v1alpha1/module.proto | 14 - src/cosmospy_protobuf/cosmos/orm/v1/orm.proto | 104 ----- .../cosmos/orm/v1alpha1/schema.proto | 76 ---- .../cosmos/params/v1beta1/params.proto | 27 -- .../cosmos/params/v1beta1/query.proto | 54 --- .../cosmos/slashing/v1beta1/genesis.proto | 47 --- .../cosmos/slashing/v1beta1/query.proto | 64 --- .../cosmos/slashing/v1beta1/slashing.proto | 45 -- .../cosmos/slashing/v1beta1/tx.proto | 30 -- .../cosmos/staking/v1beta1/authz.proto | 47 --- .../cosmos/staking/v1beta1/genesis.proto | 49 --- .../cosmos/staking/v1beta1/query.proto | 349 ---------------- .../cosmos/staking/v1beta1/staking.proto | 358 ---------------- .../cosmos/staking/v1beta1/tx.proto | 159 ------- .../cosmos/tx/signing/v1beta1/signing.proto | 106 ----- .../cosmos/tx/v1beta1/service.proto | 163 -------- .../cosmos/tx/v1beta1/tx.proto | 249 ----------- .../cosmos/upgrade/v1beta1/query.proto | 120 ------ .../cosmos/upgrade/v1beta1/tx.proto | 55 --- .../cosmos/upgrade/v1beta1/upgrade.proto | 83 ---- .../cosmos/vesting/v1beta1/tx.proto | 74 ---- .../cosmos/vesting/v1beta1/vesting.proto | 76 ---- src/cosmospy_protobuf/gogoproto/gogo.proto | 2 - .../google/api/annotations.proto | 4 +- src/cosmospy_protobuf/google/api/http.proto | 297 ++++++------- .../google/protobuf/any.proto | 9 +- .../ibc/applications/fee/v1/ack.proto | 17 - .../ibc/applications/fee/v1/fee.proto | 56 --- .../ibc/applications/fee/v1/genesis.proto | 52 --- .../ibc/applications/fee/v1/metadata.proto | 16 - .../ibc/applications/fee/v1/query.proto | 203 --------- .../ibc/applications/fee/v1/tx.proto | 85 ---- .../ibc/core/channel/v1/channel.proto | 14 - .../ibc/core/channel/v1/tx.proto | 11 +- .../ibc/core/commitment/v1/commitment.proto | 2 +- src/cosmospy_protobuf/ibc/proofs.proto | 234 ----------- .../osmosis/epochs/genesis.proto | 37 -- .../osmosis/epochs/query.proto | 30 -- .../pool-models/balancer/balancerPool.proto | 148 ------- .../gamm/pool-models/balancer/tx.proto | 29 -- .../stableswap/stableswap_pool.proto | 66 --- .../gamm/pool-models/stableswap/tx.proto | 31 -- .../osmosis/gamm/v1beta1/genesis.proto | 26 -- .../osmosis/gamm/v1beta1/query.proto | 193 --------- .../osmosis/gamm/v1beta1/tx.proto | 219 ---------- .../osmosis/incentives/gauge.proto | 51 --- .../osmosis/incentives/genesis.proto | 22 - .../osmosis/incentives/params.proto | 13 - .../osmosis/incentives/query.proto | 164 -------- .../osmosis/incentives/tx.proto | 50 --- .../osmosis/lockup/genesis.proto | 14 - .../osmosis/lockup/lock.proto | 93 ----- .../osmosis/lockup/query.proto | 289 ------------- src/cosmospy_protobuf/osmosis/lockup/tx.proto | 51 --- .../osmosis/mint/v1beta1/genesis.proto | 20 - .../osmosis/mint/v1beta1/mint.proto | 97 ----- .../osmosis/mint/v1beta1/query.proto | 45 -- .../pool-incentives/v1beta1/genesis.proto | 23 - .../osmosis/pool-incentives/v1beta1/gov.proto | 49 --- .../pool-incentives/v1beta1/incentives.proto | 44 -- .../pool-incentives/v1beta1/query.proto | 102 ----- .../osmosis/store/v1beta1/tree.proto | 19 - .../osmosis/superfluid/genesis.proto | 21 - .../osmosis/superfluid/gov.proto | 31 -- .../osmosis/superfluid/params.proto | 18 - .../osmosis/superfluid/query.proto | 255 ------------ .../osmosis/superfluid/superfluid.proto | 69 --- .../osmosis/superfluid/tx.proto | 70 ---- .../v1beta1/authorityMetadata.proto | 17 - .../tokenfactory/v1beta1/genesis.proto | 27 -- .../osmosis/tokenfactory/v1beta1/query.proto | 41 -- .../osmosis/tokenfactory/v1beta1/tx.proto | 88 ---- .../osmosis/txfees/v1beta1/feetoken.proto | 17 - .../osmosis/txfees/v1beta1/genesis.proto | 13 - .../osmosis/txfees/v1beta1/gov.proto | 25 -- .../osmosis/txfees/v1beta1/query.proto | 71 ---- .../tendermint/abci/types.proto | 394 ------------------ .../tendermint/crypto/keys.proto | 17 - .../tendermint/crypto/proof.proto | 41 -- .../tendermint/libs/bits/types.proto | 9 - .../tendermint/p2p/types.proto | 42 -- .../tendermint/types/block.proto | 15 - .../tendermint/types/evidence.proto | 38 -- .../tendermint/types/params.proto | 79 ---- .../tendermint/types/types.proto | 153 ------- .../tendermint/types/validator.proto | 25 -- .../tendermint/version/types.proto | 24 -- .../umee/leverage/v1beta1/genesis.proto | 54 --- .../umee/leverage/v1beta1/gov.proto | 20 - .../umee/leverage/v1beta1/leverage.proto | 120 ------ .../umee/leverage/v1beta1/query.proto | 390 ----------------- .../umee/leverage/v1beta1/tx.proto | 100 ----- .../umee/oracle/v1beta1/genesis.proto | 34 -- .../umee/oracle/v1beta1/oracle.proto | 98 ----- .../umee/oracle/v1beta1/query.proto | 195 --------- .../umee/oracle/v1beta1/tx.proto | 65 --- 242 files changed, 293 insertions(+), 17166 deletions(-) create mode 100644 aggregate.py create mode 100644 configs/cosmos.json create mode 100644 configs/osmosis.json delete mode 100644 src/cosmospy_protobuf/akash/audit/v1beta1/audit.proto delete mode 100644 src/cosmospy_protobuf/akash/audit/v1beta2/audit.proto delete mode 100644 src/cosmospy_protobuf/akash/audit/v1beta2/genesis.proto delete mode 100644 src/cosmospy_protobuf/akash/audit/v1beta2/query.proto delete mode 100644 src/cosmospy_protobuf/akash/base/v1beta1/attribute.proto delete mode 100644 src/cosmospy_protobuf/akash/base/v1beta1/endpoint.proto delete mode 100644 src/cosmospy_protobuf/akash/base/v1beta1/resource.proto delete mode 100644 src/cosmospy_protobuf/akash/base/v1beta1/resourcevalue.proto delete mode 100644 src/cosmospy_protobuf/akash/base/v1beta2/attribute.proto delete mode 100644 src/cosmospy_protobuf/akash/base/v1beta2/endpoint.proto delete mode 100644 src/cosmospy_protobuf/akash/base/v1beta2/resource.proto delete mode 100644 src/cosmospy_protobuf/akash/base/v1beta2/resourceunits.proto delete mode 100644 src/cosmospy_protobuf/akash/base/v1beta2/resourcevalue.proto delete mode 100644 src/cosmospy_protobuf/akash/cert/v1beta2/cert.proto delete mode 100644 src/cosmospy_protobuf/akash/cert/v1beta2/genesis.proto delete mode 100644 src/cosmospy_protobuf/akash/cert/v1beta2/query.proto delete mode 100644 src/cosmospy_protobuf/akash/deployment/v1beta1/authz.proto delete mode 100644 src/cosmospy_protobuf/akash/deployment/v1beta1/deployment.proto delete mode 100644 src/cosmospy_protobuf/akash/deployment/v1beta1/genesis.proto delete mode 100644 src/cosmospy_protobuf/akash/deployment/v1beta1/group.proto delete mode 100644 src/cosmospy_protobuf/akash/deployment/v1beta1/params.proto delete mode 100644 src/cosmospy_protobuf/akash/deployment/v1beta1/query.proto delete mode 100644 src/cosmospy_protobuf/akash/deployment/v1beta2/authz.proto delete mode 100644 src/cosmospy_protobuf/akash/deployment/v1beta2/deployment.proto delete mode 100644 src/cosmospy_protobuf/akash/deployment/v1beta2/deploymentmsg.proto delete mode 100644 src/cosmospy_protobuf/akash/deployment/v1beta2/genesis.proto delete mode 100644 src/cosmospy_protobuf/akash/deployment/v1beta2/group.proto delete mode 100644 src/cosmospy_protobuf/akash/deployment/v1beta2/groupid.proto delete mode 100644 src/cosmospy_protobuf/akash/deployment/v1beta2/groupmsg.proto delete mode 100644 src/cosmospy_protobuf/akash/deployment/v1beta2/groupspec.proto delete mode 100644 src/cosmospy_protobuf/akash/deployment/v1beta2/params.proto delete mode 100644 src/cosmospy_protobuf/akash/deployment/v1beta2/query.proto delete mode 100644 src/cosmospy_protobuf/akash/deployment/v1beta2/resource.proto delete mode 100644 src/cosmospy_protobuf/akash/deployment/v1beta2/service.proto delete mode 100644 src/cosmospy_protobuf/akash/escrow/v1beta1/genesis.proto delete mode 100644 src/cosmospy_protobuf/akash/escrow/v1beta1/query.proto delete mode 100644 src/cosmospy_protobuf/akash/escrow/v1beta1/types.proto delete mode 100644 src/cosmospy_protobuf/akash/escrow/v1beta2/genesis.proto delete mode 100644 src/cosmospy_protobuf/akash/escrow/v1beta2/query.proto delete mode 100644 src/cosmospy_protobuf/akash/escrow/v1beta2/types.proto delete mode 100644 src/cosmospy_protobuf/akash/inflation/v1beta2/genesis.proto delete mode 100644 src/cosmospy_protobuf/akash/inflation/v1beta2/params.proto delete mode 100644 src/cosmospy_protobuf/akash/market/v1beta2/bid.proto delete mode 100644 src/cosmospy_protobuf/akash/market/v1beta2/genesis.proto delete mode 100644 src/cosmospy_protobuf/akash/market/v1beta2/lease.proto delete mode 100644 src/cosmospy_protobuf/akash/market/v1beta2/order.proto delete mode 100644 src/cosmospy_protobuf/akash/market/v1beta2/params.proto delete mode 100644 src/cosmospy_protobuf/akash/market/v1beta2/query.proto delete mode 100644 src/cosmospy_protobuf/akash/market/v1beta2/service.proto delete mode 100644 src/cosmospy_protobuf/akash/provider/v1beta1/provider.proto delete mode 100644 src/cosmospy_protobuf/akash/provider/v1beta2/genesis.proto delete mode 100644 src/cosmospy_protobuf/akash/provider/v1beta2/provider.proto delete mode 100644 src/cosmospy_protobuf/akash/provider/v1beta2/query.proto delete mode 100644 src/cosmospy_protobuf/bitsong/fantoken/v1beta1/events.proto delete mode 100644 src/cosmospy_protobuf/bitsong/fantoken/v1beta1/fantoken.proto delete mode 100644 src/cosmospy_protobuf/bitsong/fantoken/v1beta1/genesis.proto delete mode 100644 src/cosmospy_protobuf/bitsong/fantoken/v1beta1/gov.proto delete mode 100644 src/cosmospy_protobuf/bitsong/fantoken/v1beta1/params.proto delete mode 100644 src/cosmospy_protobuf/bitsong/fantoken/v1beta1/query.proto delete mode 100644 src/cosmospy_protobuf/bitsong/fantoken/v1beta1/tx.proto delete mode 100644 src/cosmospy_protobuf/bitsong/merkledrop/v1beta1/events.proto delete mode 100644 src/cosmospy_protobuf/bitsong/merkledrop/v1beta1/genesis.proto delete mode 100644 src/cosmospy_protobuf/bitsong/merkledrop/v1beta1/gov.proto delete mode 100644 src/cosmospy_protobuf/bitsong/merkledrop/v1beta1/merkledrop.proto delete mode 100644 src/cosmospy_protobuf/bitsong/merkledrop/v1beta1/params.proto delete mode 100644 src/cosmospy_protobuf/bitsong/merkledrop/v1beta1/query.proto delete mode 100644 src/cosmospy_protobuf/bitsong/merkledrop/v1beta1/tx.proto delete mode 100644 src/cosmospy_protobuf/cosmos/app/module/v1alpha1/module.proto delete mode 100644 src/cosmospy_protobuf/cosmos/app/v1alpha1/config.proto delete mode 100644 src/cosmospy_protobuf/cosmos/app/v1alpha1/module.proto delete mode 100644 src/cosmospy_protobuf/cosmos/app/v1alpha1/query.proto delete mode 100644 src/cosmospy_protobuf/cosmos/auth/v1beta1/auth.proto delete mode 100644 src/cosmospy_protobuf/cosmos/auth/v1beta1/genesis.proto delete mode 100644 src/cosmospy_protobuf/cosmos/auth/v1beta1/query.proto delete mode 100644 src/cosmospy_protobuf/cosmos/authz/v1beta1/authz.proto delete mode 100644 src/cosmospy_protobuf/cosmos/authz/v1beta1/event.proto delete mode 100644 src/cosmospy_protobuf/cosmos/authz/v1beta1/genesis.proto delete mode 100644 src/cosmospy_protobuf/cosmos/authz/v1beta1/query.proto delete mode 100644 src/cosmospy_protobuf/cosmos/authz/v1beta1/tx.proto delete mode 100644 src/cosmospy_protobuf/cosmos/bank/v1beta1/authz.proto delete mode 100644 src/cosmospy_protobuf/cosmos/bank/v1beta1/bank.proto delete mode 100644 src/cosmospy_protobuf/cosmos/bank/v1beta1/genesis.proto delete mode 100644 src/cosmospy_protobuf/cosmos/bank/v1beta1/query.proto delete mode 100644 src/cosmospy_protobuf/cosmos/bank/v1beta1/tx.proto delete mode 100644 src/cosmospy_protobuf/cosmos/base/abci/v1beta1/abci.proto delete mode 100644 src/cosmospy_protobuf/cosmos/base/kv/v1beta1/kv.proto delete mode 100644 src/cosmospy_protobuf/cosmos/base/query/v1beta1/pagination.proto delete mode 100644 src/cosmospy_protobuf/cosmos/base/reflection/v1beta1/reflection.proto delete mode 100644 src/cosmospy_protobuf/cosmos/base/reflection/v2alpha1/reflection.proto delete mode 100644 src/cosmospy_protobuf/cosmos/base/snapshots/v1beta1/snapshot.proto delete mode 100644 src/cosmospy_protobuf/cosmos/base/store/v1beta1/commit_info.proto delete mode 100644 src/cosmospy_protobuf/cosmos/base/store/v1beta1/listening.proto delete mode 100644 src/cosmospy_protobuf/cosmos/base/tendermint/v1beta1/query.proto delete mode 100644 src/cosmospy_protobuf/cosmos/base/v1beta1/coin.proto delete mode 100644 src/cosmospy_protobuf/cosmos/capability/v1beta1/capability.proto delete mode 100644 src/cosmospy_protobuf/cosmos/capability/v1beta1/genesis.proto delete mode 100644 src/cosmospy_protobuf/cosmos/crisis/v1beta1/genesis.proto delete mode 100644 src/cosmospy_protobuf/cosmos/crisis/v1beta1/tx.proto delete mode 100644 src/cosmospy_protobuf/cosmos/crypto/ed25519/keys.proto delete mode 100644 src/cosmospy_protobuf/cosmos/crypto/hd/v1/hd.proto delete mode 100644 src/cosmospy_protobuf/cosmos/crypto/keyring/v1/record.proto delete mode 100644 src/cosmospy_protobuf/cosmos/crypto/multisig/keys.proto delete mode 100644 src/cosmospy_protobuf/cosmos/crypto/multisig/v1beta1/multisig.proto delete mode 100644 src/cosmospy_protobuf/cosmos/crypto/secp256k1/keys.proto delete mode 100644 src/cosmospy_protobuf/cosmos/crypto/secp256r1/keys.proto delete mode 100644 src/cosmospy_protobuf/cosmos/distribution/v1beta1/distribution.proto delete mode 100644 src/cosmospy_protobuf/cosmos/distribution/v1beta1/genesis.proto delete mode 100644 src/cosmospy_protobuf/cosmos/distribution/v1beta1/query.proto delete mode 100644 src/cosmospy_protobuf/cosmos/distribution/v1beta1/tx.proto delete mode 100644 src/cosmospy_protobuf/cosmos/evidence/v1beta1/evidence.proto delete mode 100644 src/cosmospy_protobuf/cosmos/evidence/v1beta1/genesis.proto delete mode 100644 src/cosmospy_protobuf/cosmos/evidence/v1beta1/query.proto delete mode 100644 src/cosmospy_protobuf/cosmos/evidence/v1beta1/tx.proto delete mode 100644 src/cosmospy_protobuf/cosmos/feegrant/v1beta1/feegrant.proto delete mode 100644 src/cosmospy_protobuf/cosmos/feegrant/v1beta1/genesis.proto delete mode 100644 src/cosmospy_protobuf/cosmos/feegrant/v1beta1/query.proto delete mode 100644 src/cosmospy_protobuf/cosmos/feegrant/v1beta1/tx.proto delete mode 100644 src/cosmospy_protobuf/cosmos/genutil/v1beta1/genesis.proto delete mode 100644 src/cosmospy_protobuf/cosmos/gov/v1/genesis.proto delete mode 100644 src/cosmospy_protobuf/cosmos/gov/v1/gov.proto delete mode 100644 src/cosmospy_protobuf/cosmos/gov/v1/query.proto delete mode 100644 src/cosmospy_protobuf/cosmos/gov/v1/tx.proto delete mode 100644 src/cosmospy_protobuf/cosmos/gov/v1beta1/genesis.proto delete mode 100644 src/cosmospy_protobuf/cosmos/gov/v1beta1/gov.proto delete mode 100644 src/cosmospy_protobuf/cosmos/gov/v1beta1/query.proto delete mode 100644 src/cosmospy_protobuf/cosmos/gov/v1beta1/tx.proto delete mode 100644 src/cosmospy_protobuf/cosmos/group/v1/events.proto delete mode 100644 src/cosmospy_protobuf/cosmos/group/v1/genesis.proto delete mode 100644 src/cosmospy_protobuf/cosmos/group/v1/query.proto delete mode 100644 src/cosmospy_protobuf/cosmos/group/v1/tx.proto delete mode 100644 src/cosmospy_protobuf/cosmos/group/v1/types.proto delete mode 100644 src/cosmospy_protobuf/cosmos/mint/v1beta1/genesis.proto delete mode 100644 src/cosmospy_protobuf/cosmos/mint/v1beta1/mint.proto delete mode 100644 src/cosmospy_protobuf/cosmos/mint/v1beta1/query.proto delete mode 100644 src/cosmospy_protobuf/cosmos/msg/v1/msg.proto delete mode 100644 src/cosmospy_protobuf/cosmos/nft/v1beta1/event.proto delete mode 100644 src/cosmospy_protobuf/cosmos/nft/v1beta1/genesis.proto delete mode 100644 src/cosmospy_protobuf/cosmos/nft/v1beta1/nft.proto delete mode 100644 src/cosmospy_protobuf/cosmos/nft/v1beta1/query.proto delete mode 100644 src/cosmospy_protobuf/cosmos/nft/v1beta1/tx.proto delete mode 100644 src/cosmospy_protobuf/cosmos/orm/module/v1alpha1/module.proto delete mode 100644 src/cosmospy_protobuf/cosmos/orm/v1/orm.proto delete mode 100644 src/cosmospy_protobuf/cosmos/orm/v1alpha1/schema.proto delete mode 100644 src/cosmospy_protobuf/cosmos/params/v1beta1/params.proto delete mode 100644 src/cosmospy_protobuf/cosmos/params/v1beta1/query.proto delete mode 100644 src/cosmospy_protobuf/cosmos/slashing/v1beta1/genesis.proto delete mode 100644 src/cosmospy_protobuf/cosmos/slashing/v1beta1/query.proto delete mode 100644 src/cosmospy_protobuf/cosmos/slashing/v1beta1/slashing.proto delete mode 100644 src/cosmospy_protobuf/cosmos/slashing/v1beta1/tx.proto delete mode 100644 src/cosmospy_protobuf/cosmos/staking/v1beta1/authz.proto delete mode 100644 src/cosmospy_protobuf/cosmos/staking/v1beta1/genesis.proto delete mode 100644 src/cosmospy_protobuf/cosmos/staking/v1beta1/query.proto delete mode 100644 src/cosmospy_protobuf/cosmos/staking/v1beta1/staking.proto delete mode 100644 src/cosmospy_protobuf/cosmos/staking/v1beta1/tx.proto delete mode 100644 src/cosmospy_protobuf/cosmos/tx/signing/v1beta1/signing.proto delete mode 100644 src/cosmospy_protobuf/cosmos/tx/v1beta1/service.proto delete mode 100644 src/cosmospy_protobuf/cosmos/tx/v1beta1/tx.proto delete mode 100644 src/cosmospy_protobuf/cosmos/upgrade/v1beta1/query.proto delete mode 100644 src/cosmospy_protobuf/cosmos/upgrade/v1beta1/tx.proto delete mode 100644 src/cosmospy_protobuf/cosmos/upgrade/v1beta1/upgrade.proto delete mode 100644 src/cosmospy_protobuf/cosmos/vesting/v1beta1/tx.proto delete mode 100644 src/cosmospy_protobuf/cosmos/vesting/v1beta1/vesting.proto delete mode 100644 src/cosmospy_protobuf/ibc/applications/fee/v1/ack.proto delete mode 100644 src/cosmospy_protobuf/ibc/applications/fee/v1/fee.proto delete mode 100644 src/cosmospy_protobuf/ibc/applications/fee/v1/genesis.proto delete mode 100644 src/cosmospy_protobuf/ibc/applications/fee/v1/metadata.proto delete mode 100644 src/cosmospy_protobuf/ibc/applications/fee/v1/query.proto delete mode 100644 src/cosmospy_protobuf/ibc/applications/fee/v1/tx.proto delete mode 100644 src/cosmospy_protobuf/ibc/proofs.proto delete mode 100644 src/cosmospy_protobuf/osmosis/epochs/genesis.proto delete mode 100644 src/cosmospy_protobuf/osmosis/epochs/query.proto delete mode 100644 src/cosmospy_protobuf/osmosis/gamm/pool-models/balancer/balancerPool.proto delete mode 100644 src/cosmospy_protobuf/osmosis/gamm/pool-models/balancer/tx.proto delete mode 100644 src/cosmospy_protobuf/osmosis/gamm/pool-models/stableswap/stableswap_pool.proto delete mode 100644 src/cosmospy_protobuf/osmosis/gamm/pool-models/stableswap/tx.proto delete mode 100644 src/cosmospy_protobuf/osmosis/gamm/v1beta1/genesis.proto delete mode 100644 src/cosmospy_protobuf/osmosis/gamm/v1beta1/query.proto delete mode 100644 src/cosmospy_protobuf/osmosis/gamm/v1beta1/tx.proto delete mode 100644 src/cosmospy_protobuf/osmosis/incentives/gauge.proto delete mode 100644 src/cosmospy_protobuf/osmosis/incentives/genesis.proto delete mode 100644 src/cosmospy_protobuf/osmosis/incentives/params.proto delete mode 100644 src/cosmospy_protobuf/osmosis/incentives/query.proto delete mode 100644 src/cosmospy_protobuf/osmosis/incentives/tx.proto delete mode 100644 src/cosmospy_protobuf/osmosis/lockup/genesis.proto delete mode 100644 src/cosmospy_protobuf/osmosis/lockup/lock.proto delete mode 100644 src/cosmospy_protobuf/osmosis/lockup/query.proto delete mode 100644 src/cosmospy_protobuf/osmosis/lockup/tx.proto delete mode 100644 src/cosmospy_protobuf/osmosis/mint/v1beta1/genesis.proto delete mode 100644 src/cosmospy_protobuf/osmosis/mint/v1beta1/mint.proto delete mode 100644 src/cosmospy_protobuf/osmosis/mint/v1beta1/query.proto delete mode 100644 src/cosmospy_protobuf/osmosis/pool-incentives/v1beta1/genesis.proto delete mode 100644 src/cosmospy_protobuf/osmosis/pool-incentives/v1beta1/gov.proto delete mode 100644 src/cosmospy_protobuf/osmosis/pool-incentives/v1beta1/incentives.proto delete mode 100644 src/cosmospy_protobuf/osmosis/pool-incentives/v1beta1/query.proto delete mode 100644 src/cosmospy_protobuf/osmosis/store/v1beta1/tree.proto delete mode 100644 src/cosmospy_protobuf/osmosis/superfluid/genesis.proto delete mode 100644 src/cosmospy_protobuf/osmosis/superfluid/gov.proto delete mode 100644 src/cosmospy_protobuf/osmosis/superfluid/params.proto delete mode 100644 src/cosmospy_protobuf/osmosis/superfluid/query.proto delete mode 100644 src/cosmospy_protobuf/osmosis/superfluid/superfluid.proto delete mode 100644 src/cosmospy_protobuf/osmosis/superfluid/tx.proto delete mode 100644 src/cosmospy_protobuf/osmosis/tokenfactory/v1beta1/authorityMetadata.proto delete mode 100644 src/cosmospy_protobuf/osmosis/tokenfactory/v1beta1/genesis.proto delete mode 100644 src/cosmospy_protobuf/osmosis/tokenfactory/v1beta1/query.proto delete mode 100644 src/cosmospy_protobuf/osmosis/tokenfactory/v1beta1/tx.proto delete mode 100644 src/cosmospy_protobuf/osmosis/txfees/v1beta1/feetoken.proto delete mode 100644 src/cosmospy_protobuf/osmosis/txfees/v1beta1/genesis.proto delete mode 100644 src/cosmospy_protobuf/osmosis/txfees/v1beta1/gov.proto delete mode 100644 src/cosmospy_protobuf/osmosis/txfees/v1beta1/query.proto delete mode 100644 src/cosmospy_protobuf/tendermint/abci/types.proto delete mode 100644 src/cosmospy_protobuf/tendermint/crypto/keys.proto delete mode 100644 src/cosmospy_protobuf/tendermint/crypto/proof.proto delete mode 100644 src/cosmospy_protobuf/tendermint/libs/bits/types.proto delete mode 100644 src/cosmospy_protobuf/tendermint/p2p/types.proto delete mode 100644 src/cosmospy_protobuf/tendermint/types/block.proto delete mode 100644 src/cosmospy_protobuf/tendermint/types/evidence.proto delete mode 100644 src/cosmospy_protobuf/tendermint/types/params.proto delete mode 100644 src/cosmospy_protobuf/tendermint/types/types.proto delete mode 100644 src/cosmospy_protobuf/tendermint/types/validator.proto delete mode 100644 src/cosmospy_protobuf/tendermint/version/types.proto delete mode 100644 src/cosmospy_protobuf/umee/leverage/v1beta1/genesis.proto delete mode 100644 src/cosmospy_protobuf/umee/leverage/v1beta1/gov.proto delete mode 100644 src/cosmospy_protobuf/umee/leverage/v1beta1/leverage.proto delete mode 100644 src/cosmospy_protobuf/umee/leverage/v1beta1/query.proto delete mode 100644 src/cosmospy_protobuf/umee/leverage/v1beta1/tx.proto delete mode 100644 src/cosmospy_protobuf/umee/oracle/v1beta1/genesis.proto delete mode 100644 src/cosmospy_protobuf/umee/oracle/v1beta1/oracle.proto delete mode 100644 src/cosmospy_protobuf/umee/oracle/v1beta1/query.proto delete mode 100644 src/cosmospy_protobuf/umee/oracle/v1beta1/tx.proto diff --git a/.gitignore b/.gitignore index 09fde9c5..2b7fb280 100644 --- a/.gitignore +++ b/.gitignore @@ -1,7 +1,7 @@ .idea *.pyc -*.py *.pyi test/ dist/ -cosmospy_protobuf.egg-info \ No newline at end of file +cosmospy_protobuf.egg-info +tmp/ \ No newline at end of file diff --git a/README.md b/README.md index 81a6df3a..4d714b37 100644 --- a/README.md +++ b/README.md @@ -28,10 +28,17 @@ print(r.balances) ``` -## Compile the Protobuf files - -The files are compield using the ``grpc_tools.protoc`` command from the [grpcio-tools](https://pypi.org/project/grpcio-tools/) library. -To compile a .proto file use following command: +## Build yourself +There are two scripts helping you to fork this repository to work with any cosmos based coin. +1. Create a config in ``configs`` and take a existing one as example +2. Run the ``aggregate.py`` file with your filename without ``.json`` (Example ``python aggregate.py cosmos``) +3. Run the ``compile.py`` to compile all your files to protobuf +4. Build your package. You're done! +5. +## Protobuf compilation + +The files are compiled using the ``grpc_tools.protoc`` command from the [grpcio-tools](https://pypi.org/project/grpcio-tools/) library. +To compile a .proto file manually use following command: ``` python -m grpc_tools.protoc -I --python_out=. --grpc_python_out=. ``` @@ -43,9 +50,6 @@ Note: * To compile the whole project it is favorable to match all proto files by using `*.proto` instead of each individual file. You can also match the whole folders to compile multiple folders at the same time. Not that the folders might contain sub-folders. ## Other Cosmos based coins -Currently following coins are supported by this library: -* Akash -* Bitsong -* Cosmos -* Osmosis -* Umee +Currently following coins are maintained by me: +* Cosmos (this branch) +* Osmosis (branch: osmosis, package name: `osmosis-protobuf`) diff --git a/aggregate.py b/aggregate.py new file mode 100644 index 00000000..1e6e6d89 --- /dev/null +++ b/aggregate.py @@ -0,0 +1,79 @@ +import errno +import json +import os +import shutil +import time +from os.path import dirname, abspath, isfile +import argparse + +from git import Repo + +parser = argparse.ArgumentParser(description='Aggregate all protobuf files') +parser.add_argument('coin', type=str, help="Coin to parse from the .json file in the config folder") +args = parser.parse_args() + +# Get current directory +d = dirname(abspath(__file__)) + +# Check if requested coin has a config +coin = args.coin +try: + config_path = os.path.join(d, f'configs/{coin.lower()}.json') + f = open(config_path, "r") + coin_config = json.load(f) + f.close() +except Exception: + print("Coin couldn't be found") + exit() + + +tmp_dir = os.path.join(d, "tmp") +if not os.path.isdir(tmp_dir): + os.mkdir(tmp_dir) + +project_dir = os.path.join(tmp_dir, str(time.time())) +os.mkdir(project_dir) + +# Delete all existing protobuf files +root_dir = 'src/cosmospy_protobuf' +root_abs_path = os.path.join(d, root_dir) +for filename in os.listdir(root_abs_path): + file_path = os.path.join(root_abs_path, filename) + try: + if os.path.isfile(file_path) or os.path.islink(file_path): + os.unlink(file_path) + elif os.path.isdir(file_path): + shutil.rmtree(file_path) + except Exception as e: + print('Failed to delete %s. Reason: %s' % (file_path, e)) + +# Load config +i = 1 +for repo_url, repo_config in coin_config.items(): + print(f"Cloning {repo_url} | {repo_config['branch']}") + repo_dir = project_dir + "/" + str(i) + Repo.clone_from( + repo_url, + project_dir + "/" + str(i), + branch=repo_config['branch'] + ) + + # Copy proto files to root_dir + for proto_folder in repo_config['paths']: + proto_dir = os.path.join(repo_dir, proto_folder) + category_name = proto_folder.split('/')[-1] + try: + shutil.copytree(proto_dir, root_abs_path + "/" + category_name, dirs_exist_ok=True, ignore=shutil.ignore_patterns("*.go")) + print(f"Copied {category_name}") + except OSError as exc: # python >2.5 + try: + shutil.copy(proto_dir, root_abs_path) + print(f"File {proto_dir} copied successfully") + except: + raise + + i += 1 + + + + diff --git a/configs/cosmos.json b/configs/cosmos.json new file mode 100644 index 00000000..d23dcfb9 --- /dev/null +++ b/configs/cosmos.json @@ -0,0 +1,32 @@ +{ + "https://github.com/cosmos/cosmos-sdk.git": { + "include": true, + "branch": "v0.45.3", + "paths": ["proto/cosmos"] + }, + "https://github.com/tendermint/tendermint.git": { + "include": true, + "branch": "v0.34.14", + "paths": ["proto/tendermint"] + }, + "https://github.com/cosmos/ibc-go": { + "include": true, + "branch": "v3.0.0", + "paths": ["proto/ibc", "third_party/proto/google"] + }, + "https://github.com/cosmos/cosmos-proto.git": { + "include": true, + "branch": "main", + "paths": ["proto/cosmos_proto"] + }, + "https://github.com/cosmos/gogoproto.git": { + "include": true, + "branch": "master", + "paths": ["gogoproto"] + }, + "https://github.com/confio/ics23.git": { + "include": true, + "branch": "master", + "paths": ["proofs.proto"] + } +} \ No newline at end of file diff --git a/configs/osmosis.json b/configs/osmosis.json new file mode 100644 index 00000000..e167be34 --- /dev/null +++ b/configs/osmosis.json @@ -0,0 +1,37 @@ +{ + "https://github.com/osmosis-labs/osmosis.git": { + "include": true, + "branch": "v10.0.0", + "paths": ["proto/osmosis"] + }, + "https://github.com/cosmos/cosmos-sdk.git": { + "include": true, + "branch": "v0.45.4", + "paths": ["proto/cosmos"] + }, + "https://github.com/tendermint/tendermint.git": { + "include": true, + "branch": "v0.34.19", + "paths": ["proto/tendermint"] + }, + "https://github.com/cosmos/ibc-go": { + "include": true, + "branch": "v3.0.0", + "paths": ["proto/ibc", "third_party/proto/google"] + }, + "https://github.com/cosmos/cosmos-proto.git": { + "include": true, + "branch": "main", + "paths": ["proto/cosmos_proto"] + }, + "https://github.com/cosmos/gogoproto.git": { + "include": true, + "branch": "master", + "paths": ["gogoproto"] + }, + "https://github.com/confio/ics23.git": { + "include": true, + "branch": "master", + "paths": ["proofs.proto"] + } +} \ No newline at end of file diff --git a/pyproject.toml b/pyproject.toml index 7cba8751..d8beac93 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -4,13 +4,13 @@ build-backend = "hatchling.build" [project] name = "cosmospy_protobuf" -version = "0.0.1" +version = "0.0.2" description = "This package contains a compiled python version of all cosmos protobuf files with their dependencies" authors = [ { name = "ctrl-felix", email = "dev@ctrl-felix.de" }, ] readme = "README.md" -keywords = ["cosmospy", "proto", "cosmospy-protobuf"] +keywords = ["cosmospy", "proto", "cosmospy-protobuf", "cosmos", "cosmos-protobuf", "protobuf"] license = {text = "BSD 3-Clause License"} classifiers = [ "Programming Language :: Python :: 3", diff --git a/src/cosmospy_protobuf/akash/audit/v1beta1/audit.proto b/src/cosmospy_protobuf/akash/audit/v1beta1/audit.proto deleted file mode 100644 index b27aabc2..00000000 --- a/src/cosmospy_protobuf/akash/audit/v1beta1/audit.proto +++ /dev/null @@ -1,99 +0,0 @@ -syntax = "proto3"; -package akash.audit.v1beta1; - -import "gogoproto/gogo.proto"; -import "akash/base/v1beta1/attribute.proto"; - -option go_package = "github.com/ovrclk/akash/x/audit/types/v1beta1"; - -// Msg defines the provider Msg service -service Msg { - // SignProviderAttributes defines a method that signs provider attributes - rpc SignProviderAttributes(MsgSignProviderAttributes) returns (MsgSignProviderAttributesResponse); - - // DeleteProviderAttributes defines a method that deletes provider attributes - rpc DeleteProviderAttributes(MsgDeleteProviderAttributes) returns (MsgDeleteProviderAttributesResponse); -} - -// Provider stores owner auditor and attributes details -message Provider { - string owner = 1 [(gogoproto.jsontag) = "owner", (gogoproto.moretags) = "yaml:\"owner\""]; - - string auditor = 2 [(gogoproto.jsontag) = "auditor", (gogoproto.moretags) = "yaml:\"auditor\""]; - - repeated akash.base.v1beta1.Attribute attributes = 4 [ - (gogoproto.castrepeated) = "github.com/ovrclk/akash/types/v1beta1.Attributes", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "attributes", - (gogoproto.moretags) = "yaml:\"attributes\"" - ]; -} - -// Attributes -message AuditedAttributes { - option (gogoproto.equal) = false; - option (gogoproto.goproto_stringer) = true; - - string owner = 1 [(gogoproto.jsontag) = "owner", (gogoproto.moretags) = "yaml:\"owner\""]; - - string auditor = 2 [(gogoproto.jsontag) = "auditor", (gogoproto.moretags) = "yaml:\"auditor\""]; - - repeated akash.base.v1beta1.Attribute attributes = 3 [ - (gogoproto.castrepeated) = "github.com/ovrclk/akash/types/v1beta1.Attributes", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "attributes", - (gogoproto.moretags) = "yaml:\"attributes\"" - ]; -} - -// AttributesResponse represents details of deployment along with group details -message AttributesResponse { - option (gogoproto.equal) = false; - option (gogoproto.goproto_stringer) = true; - - repeated AuditedAttributes attributes = 1 - [(gogoproto.nullable) = false, (gogoproto.jsontag) = "attributes", (gogoproto.moretags) = "yaml:\"attributes\""]; -} - -// AttributesFilters defines filters used to filter deployments -message AttributesFilters { - option (gogoproto.equal) = false; - option (gogoproto.goproto_stringer) = true; - - repeated string auditors = 1 [(gogoproto.jsontag) = "auditors", (gogoproto.moretags) = "yaml:\"auditors\""]; - - repeated string owners = 2 [(gogoproto.jsontag) = "owners", (gogoproto.moretags) = "yaml:\"owners\""]; -} - -// MsgSignProviderAttributes defines an SDK message for signing a provider attributes -message MsgSignProviderAttributes { - option (gogoproto.equal) = false; - - string owner = 1 [(gogoproto.jsontag) = "owner", (gogoproto.moretags) = "yaml:\"owner\""]; - - string auditor = 2 [(gogoproto.jsontag) = "auditor", (gogoproto.moretags) = "yaml:\"auditor\""]; - - repeated akash.base.v1beta1.Attribute attributes = 3 [ - (gogoproto.castrepeated) = "github.com/ovrclk/akash/types/v1beta1.Attributes", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "attributes", - (gogoproto.moretags) = "yaml:\"attributes\"" - ]; -} - -// MsgSignProviderAttributesResponse defines the Msg/CreateProvider response type. -message MsgSignProviderAttributesResponse {} - -// MsgDeleteProviderAttributes defined the Msg/DeleteProviderAttributes -message MsgDeleteProviderAttributes { - option (gogoproto.equal) = false; - - string owner = 1 [(gogoproto.jsontag) = "owner", (gogoproto.moretags) = "yaml:\"owner\""]; - - string auditor = 2 [(gogoproto.jsontag) = "auditor", (gogoproto.moretags) = "yaml:\"auditor\""]; - - repeated string keys = 3 [(gogoproto.jsontag) = "keys", (gogoproto.moretags) = "yaml:\"keys\""]; -} - -// MsgDeleteProviderAttributesResponse defines the Msg/ProviderAttributes response type. -message MsgDeleteProviderAttributesResponse {} diff --git a/src/cosmospy_protobuf/akash/audit/v1beta2/audit.proto b/src/cosmospy_protobuf/akash/audit/v1beta2/audit.proto deleted file mode 100644 index b91ac553..00000000 --- a/src/cosmospy_protobuf/akash/audit/v1beta2/audit.proto +++ /dev/null @@ -1,99 +0,0 @@ -syntax = "proto3"; -package akash.audit.v1beta2; - -import "gogoproto/gogo.proto"; -import "akash/base/v1beta2/attribute.proto"; - -option go_package = "github.com/ovrclk/akash/x/audit/types/v1beta2"; - -// Msg defines the provider Msg service -service Msg { - // SignProviderAttributes defines a method that signs provider attributes - rpc SignProviderAttributes(MsgSignProviderAttributes) returns (MsgSignProviderAttributesResponse); - - // DeleteProviderAttributes defines a method that deletes provider attributes - rpc DeleteProviderAttributes(MsgDeleteProviderAttributes) returns (MsgDeleteProviderAttributesResponse); -} - -// Provider stores owner auditor and attributes details -message Provider { - string owner = 1 [(gogoproto.jsontag) = "owner", (gogoproto.moretags) = "yaml:\"owner\""]; - - string auditor = 2 [(gogoproto.jsontag) = "auditor", (gogoproto.moretags) = "yaml:\"auditor\""]; - - repeated akash.base.v1beta2.Attribute attributes = 4 [ - (gogoproto.castrepeated) = "github.com/ovrclk/akash/types/v1beta2.Attributes", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "attributes", - (gogoproto.moretags) = "yaml:\"attributes\"" - ]; -} - -// Attributes -message AuditedAttributes { - option (gogoproto.equal) = false; - option (gogoproto.goproto_stringer) = true; - - string owner = 1 [(gogoproto.jsontag) = "owner", (gogoproto.moretags) = "yaml:\"owner\""]; - - string auditor = 2 [(gogoproto.jsontag) = "auditor", (gogoproto.moretags) = "yaml:\"auditor\""]; - - repeated akash.base.v1beta2.Attribute attributes = 3 [ - (gogoproto.castrepeated) = "github.com/ovrclk/akash/types/v1beta2.Attributes", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "attributes", - (gogoproto.moretags) = "yaml:\"attributes\"" - ]; -} - -// AttributesResponse represents details of deployment along with group details -message AttributesResponse { - option (gogoproto.equal) = false; - option (gogoproto.goproto_stringer) = true; - - repeated AuditedAttributes attributes = 1 - [(gogoproto.nullable) = false, (gogoproto.jsontag) = "attributes", (gogoproto.moretags) = "yaml:\"attributes\""]; -} - -// AttributesFilters defines filters used to filter deployments -message AttributesFilters { - option (gogoproto.equal) = false; - option (gogoproto.goproto_stringer) = true; - - repeated string auditors = 1 [(gogoproto.jsontag) = "auditors", (gogoproto.moretags) = "yaml:\"auditors\""]; - - repeated string owners = 2 [(gogoproto.jsontag) = "owners", (gogoproto.moretags) = "yaml:\"owners\""]; -} - -// MsgSignProviderAttributes defines an SDK message for signing a provider attributes -message MsgSignProviderAttributes { - option (gogoproto.equal) = false; - - string owner = 1 [(gogoproto.jsontag) = "owner", (gogoproto.moretags) = "yaml:\"owner\""]; - - string auditor = 2 [(gogoproto.jsontag) = "auditor", (gogoproto.moretags) = "yaml:\"auditor\""]; - - repeated akash.base.v1beta2.Attribute attributes = 3 [ - (gogoproto.castrepeated) = "github.com/ovrclk/akash/types/v1beta2.Attributes", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "attributes", - (gogoproto.moretags) = "yaml:\"attributes\"" - ]; -} - -// MsgSignProviderAttributesResponse defines the Msg/CreateProvider response type. -message MsgSignProviderAttributesResponse {} - -// MsgDeleteProviderAttributes defined the Msg/DeleteProviderAttributes -message MsgDeleteProviderAttributes { - option (gogoproto.equal) = false; - - string owner = 1 [(gogoproto.jsontag) = "owner", (gogoproto.moretags) = "yaml:\"owner\""]; - - string auditor = 2 [(gogoproto.jsontag) = "auditor", (gogoproto.moretags) = "yaml:\"auditor\""]; - - repeated string keys = 3 [(gogoproto.jsontag) = "keys", (gogoproto.moretags) = "yaml:\"keys\""]; -} - -// MsgDeleteProviderAttributesResponse defines the Msg/ProviderAttributes response type. -message MsgDeleteProviderAttributesResponse {} diff --git a/src/cosmospy_protobuf/akash/audit/v1beta2/genesis.proto b/src/cosmospy_protobuf/akash/audit/v1beta2/genesis.proto deleted file mode 100644 index 0ee2345d..00000000 --- a/src/cosmospy_protobuf/akash/audit/v1beta2/genesis.proto +++ /dev/null @@ -1,13 +0,0 @@ -syntax = "proto3"; -package akash.audit.v1beta2; - -import "gogoproto/gogo.proto"; -import "akash/audit/v1beta2/audit.proto"; - -option go_package = "github.com/ovrclk/akash/x/audit/types/v1beta2"; - -// GenesisState defines the basic genesis state used by audit module -message GenesisState { - repeated AuditedAttributes attributes = 1 - [(gogoproto.nullable) = false, (gogoproto.jsontag) = "attributes", (gogoproto.moretags) = "yaml:\"attributes\""]; -} diff --git a/src/cosmospy_protobuf/akash/audit/v1beta2/query.proto b/src/cosmospy_protobuf/akash/audit/v1beta2/query.proto deleted file mode 100644 index 7b2ba77c..00000000 --- a/src/cosmospy_protobuf/akash/audit/v1beta2/query.proto +++ /dev/null @@ -1,79 +0,0 @@ -syntax = "proto3"; - -// buf:lint:ignore RPC_RESPONSE_STANDARD_NAME - -package akash.audit.v1beta2; - -import "gogoproto/gogo.proto"; -import "google/api/annotations.proto"; -import "cosmos/base/query/v1beta1/pagination.proto"; -import "akash/audit/v1beta2/audit.proto"; - -option go_package = "github.com/ovrclk/akash/x/audit/types/v1beta2"; - -// Query defines the gRPC querier service -service Query { - // AllProvidersAttributes queries all providers - // buf:lint:ignore RPC_REQUEST_RESPONSE_UNIQUE - // buf:lint:ignore RPC_RESPONSE_STANDARD_NAME - rpc AllProvidersAttributes(QueryAllProvidersAttributesRequest) returns (QueryProvidersResponse) { - option (google.api.http).get = "/akash/audit/v1beta2/audit/attributes/list"; - } - - // ProviderAttributes queries all provider signed attributes - // buf:lint:ignore RPC_REQUEST_RESPONSE_UNIQUE - // buf:lint:ignore RPC_RESPONSE_STANDARD_NAME - rpc ProviderAttributes(QueryProviderAttributesRequest) returns (QueryProvidersResponse) { - option (google.api.http).get = "/akash/audit/v1beta2/audit/attributes/{owner}/list"; - } - - // ProviderAuditorAttributes queries provider signed attributes by specific auditor - // buf:lint:ignore RPC_REQUEST_RESPONSE_UNIQUE - // buf:lint:ignore RPC_RESPONSE_STANDARD_NAME - rpc ProviderAuditorAttributes(QueryProviderAuditorRequest) returns (QueryProvidersResponse) { - option (google.api.http).get = "/akash/audit/v1beta2/audit/attributes/{auditor}/{owner}"; - } - - // AuditorAttributes queries all providers signed by this auditor - // buf:lint:ignore RPC_REQUEST_RESPONSE_UNIQUE - // buf:lint:ignore RPC_RESPONSE_STANDARD_NAME - rpc AuditorAttributes(QueryAuditorAttributesRequest) returns (QueryProvidersResponse) { - option (google.api.http).get = "/akash/provider/v1beta2/auditor/{auditor}/list"; - } -} - -// QueryProvidersResponse is response type for the Query/Providers RPC method -message QueryProvidersResponse { - repeated Provider providers = 1 [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "Providers"]; - - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryProviderRequest is request type for the Query/Provider RPC method -message QueryProviderRequest { - string auditor = 1; - string owner = 2; -} - -// QueryAllProvidersAttributesRequest is request type for the Query/All Providers RPC method -message QueryAllProvidersAttributesRequest { - cosmos.base.query.v1beta1.PageRequest pagination = 1; -} - -// QueryProviderAttributesRequest is request type for the Query/Provider RPC method -message QueryProviderAttributesRequest { - string owner = 1; - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} - -// QueryProviderAuditorRequest is request type for the Query/Providers RPC method -message QueryProviderAuditorRequest { - string auditor = 1; - string owner = 2; -} - -// QueryAuditorAttributesRequest is request type for the Query/Providers RPC method -message QueryAuditorAttributesRequest { - string auditor = 1; - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} diff --git a/src/cosmospy_protobuf/akash/base/v1beta1/attribute.proto b/src/cosmospy_protobuf/akash/base/v1beta1/attribute.proto deleted file mode 100644 index 94cffe4c..00000000 --- a/src/cosmospy_protobuf/akash/base/v1beta1/attribute.proto +++ /dev/null @@ -1,41 +0,0 @@ -syntax = "proto3"; - -package akash.base.v1beta1; - -import "gogoproto/gogo.proto"; - -option (gogoproto.goproto_stringer_all) = false; -option (gogoproto.stringer_all) = false; -option go_package = "github.com/ovrclk/akash/types/v1beta1"; - -// Attribute represents key value pair -message Attribute { - option (gogoproto.goproto_getters) = false; - string key = 1 [(gogoproto.moretags) = "yaml:\"key\""]; - string value = 2 [(gogoproto.moretags) = "yaml:\"value\""]; -} - -// SignedBy represents validation accounts that tenant expects signatures for provider attributes -// AllOf has precedence i.e. if there is at least one entry AnyOf is ignored regardless to how many -// entries there -// this behaviour to be discussed -message SignedBy { - option (gogoproto.goproto_getters) = false; - // all_of all keys in this list must have signed attributes - repeated string all_of = 1 [(gogoproto.jsontag) = "all_of", (gogoproto.moretags) = "yaml:\"allOf\""]; - // any_of at least of of the keys from the list must have signed attributes - repeated string any_of = 2 [(gogoproto.jsontag) = "any_of", (gogoproto.moretags) = "yaml:\"anyOf\""]; -} - -// PlacementRequirements -message PlacementRequirements { - option (gogoproto.goproto_getters) = false; - - // SignedBy list of keys that tenants expect to have signatures from - SignedBy signed_by = 1 - [(gogoproto.nullable) = false, (gogoproto.jsontag) = "signed_by", (gogoproto.moretags) = "yaml:\"signed_by\""]; - - // Attribute list of attributes tenant expects from the provider - repeated Attribute attributes = 2 - [(gogoproto.nullable) = false, (gogoproto.jsontag) = "attributes", (gogoproto.moretags) = "yaml:\"attributes\""]; -} diff --git a/src/cosmospy_protobuf/akash/base/v1beta1/endpoint.proto b/src/cosmospy_protobuf/akash/base/v1beta1/endpoint.proto deleted file mode 100644 index 809fba87..00000000 --- a/src/cosmospy_protobuf/akash/base/v1beta1/endpoint.proto +++ /dev/null @@ -1,19 +0,0 @@ -syntax = "proto3"; -package akash.base.v1beta1; - -import "gogoproto/gogo.proto"; - -option go_package = "github.com/ovrclk/akash/types/v1beta1"; - -// Endpoint describes a publicly accessible IP service -message Endpoint { - option (gogoproto.equal) = true; - // This describes how the endpoint is implemented when the lease is deployed - enum Kind { - // Describes an endpoint that becomes a Kubernetes Ingress - SHARED_HTTP = 0; - // Describes an endpoint that becomes a Kubernetes NodePort - RANDOM_PORT = 1; - } - Kind kind = 1; -} diff --git a/src/cosmospy_protobuf/akash/base/v1beta1/resource.proto b/src/cosmospy_protobuf/akash/base/v1beta1/resource.proto deleted file mode 100644 index ff0ed877..00000000 --- a/src/cosmospy_protobuf/akash/base/v1beta1/resource.proto +++ /dev/null @@ -1,68 +0,0 @@ -syntax = "proto3"; -package akash.base.v1beta1; - -import "gogoproto/gogo.proto"; -import "akash/base/v1beta1/attribute.proto"; -import "akash/base/v1beta1/resourcevalue.proto"; -import "akash/base/v1beta1/endpoint.proto"; - -option go_package = "github.com/ovrclk/akash/types/v1beta1"; - -// CPU stores resource units and cpu config attributes -message CPU { - option (gogoproto.equal) = true; - ResourceValue units = 1 [(gogoproto.nullable) = false]; - repeated Attribute attributes = 2 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "attributes,omitempty", - (gogoproto.moretags) = "yaml:\"cpu,omitempty\"" - ]; -} - -// Memory stores resource quantity and memory attributes -message Memory { - option (gogoproto.equal) = true; - ResourceValue quantity = 1 - [(gogoproto.nullable) = false, (gogoproto.jsontag) = "size", (gogoproto.moretags) = "yaml:\"size\""]; - repeated Attribute attributes = 2 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "attributes,omitempty", - (gogoproto.moretags) = "yaml:\"cpu,omitempty\"" - ]; -} - -// Storage stores resource quantity and storage attributes -message Storage { - option (gogoproto.equal) = true; - ResourceValue quantity = 1 - [(gogoproto.nullable) = false, (gogoproto.jsontag) = "size", (gogoproto.moretags) = "yaml:\"size\""]; - repeated Attribute attributes = 2 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "attributes,omitempty", - (gogoproto.moretags) = "yaml:\"cpu,omitempty\"" - ]; -} - -// ResourceUnits describes all available resources types for deployment/node etc -// if field is nil resource is not present in the given data-structure -message ResourceUnits { - option (gogoproto.equal) = true; - CPU cpu = 1 [ - (gogoproto.nullable) = true, - (gogoproto.customname) = "CPU", - (gogoproto.jsontag) = "cpu,omitempty", - (gogoproto.moretags) = "yaml:\"cpu,omitempty\"" - ]; - Memory memory = 2 [ - (gogoproto.nullable) = true, - (gogoproto.jsontag) = "memory,omitempty", - (gogoproto.moretags) = "yaml:\"memory,omitempty\"" - ]; - Storage storage = 3 [ - (gogoproto.nullable) = true, - (gogoproto.jsontag) = "storage,omitempty", - (gogoproto.moretags) = "yaml:\"storage,omitempty\"" - ]; - repeated akash.base.v1beta1.Endpoint endpoints = 4 - [(gogoproto.nullable) = false, (gogoproto.jsontag) = "endpoints", (gogoproto.moretags) = "yaml:\"endpoints\""]; -} diff --git a/src/cosmospy_protobuf/akash/base/v1beta1/resourcevalue.proto b/src/cosmospy_protobuf/akash/base/v1beta1/resourcevalue.proto deleted file mode 100644 index 86109943..00000000 --- a/src/cosmospy_protobuf/akash/base/v1beta1/resourcevalue.proto +++ /dev/null @@ -1,12 +0,0 @@ -syntax = "proto3"; -package akash.base.v1beta1; - -import "gogoproto/gogo.proto"; - -option go_package = "github.com/ovrclk/akash/types/v1beta1"; - -// Unit stores cpu, memory and storage metrics -message ResourceValue { - option (gogoproto.equal) = true; - bytes val = 1 [(gogoproto.nullable) = false, (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int"]; -} diff --git a/src/cosmospy_protobuf/akash/base/v1beta2/attribute.proto b/src/cosmospy_protobuf/akash/base/v1beta2/attribute.proto deleted file mode 100644 index f2d25fd9..00000000 --- a/src/cosmospy_protobuf/akash/base/v1beta2/attribute.proto +++ /dev/null @@ -1,41 +0,0 @@ -syntax = "proto3"; - -package akash.base.v1beta2; - -import "gogoproto/gogo.proto"; - -option (gogoproto.goproto_stringer_all) = false; -option (gogoproto.stringer_all) = false; -option go_package = "github.com/ovrclk/akash/types/v1beta2"; - -// Attribute represents key value pair -message Attribute { - option (gogoproto.goproto_getters) = false; - string key = 1 [(gogoproto.moretags) = "yaml:\"key\""]; - string value = 2 [(gogoproto.moretags) = "yaml:\"value\""]; -} - -// SignedBy represents validation accounts that tenant expects signatures for provider attributes -// AllOf has precedence i.e. if there is at least one entry AnyOf is ignored regardless to how many -// entries there -// this behaviour to be discussed -message SignedBy { - option (gogoproto.goproto_getters) = false; - // all_of all keys in this list must have signed attributes - repeated string all_of = 1 [(gogoproto.jsontag) = "all_of", (gogoproto.moretags) = "yaml:\"allOf\""]; - // any_of at least of of the keys from the list must have signed attributes - repeated string any_of = 2 [(gogoproto.jsontag) = "any_of", (gogoproto.moretags) = "yaml:\"anyOf\""]; -} - -// PlacementRequirements -message PlacementRequirements { - option (gogoproto.goproto_getters) = false; - - // SignedBy list of keys that tenants expect to have signatures from - SignedBy signed_by = 1 - [(gogoproto.nullable) = false, (gogoproto.jsontag) = "signed_by", (gogoproto.moretags) = "yaml:\"signed_by\""]; - - // Attribute list of attributes tenant expects from the provider - repeated Attribute attributes = 2 - [(gogoproto.nullable) = false, (gogoproto.jsontag) = "attributes", (gogoproto.moretags) = "yaml:\"attributes\""]; -} diff --git a/src/cosmospy_protobuf/akash/base/v1beta2/endpoint.proto b/src/cosmospy_protobuf/akash/base/v1beta2/endpoint.proto deleted file mode 100644 index 4bc67171..00000000 --- a/src/cosmospy_protobuf/akash/base/v1beta2/endpoint.proto +++ /dev/null @@ -1,23 +0,0 @@ -syntax = "proto3"; -package akash.base.v1beta2; - -import "gogoproto/gogo.proto"; - -option go_package = "github.com/ovrclk/akash/types/v1beta2"; - -// Endpoint describes a publicly accessible IP service -message Endpoint { - option (gogoproto.equal) = true; - // This describes how the endpoint is implemented when the lease is deployed - enum Kind { - // Describes an endpoint that becomes a Kubernetes Ingress - SHARED_HTTP = 0; - // Describes an endpoint that becomes a Kubernetes NodePort - RANDOM_PORT = 1; - // Describes an endpoint that becomes a leased IP - LEASED_IP = 2; - } - Kind kind = 1; - uint32 sequence_number = 2 - [(gogoproto.customname) = "SequenceNumber", (gogoproto.jsontag) = "sequence_number", (gogoproto.moretags) = "yaml:\"sequence_number\""]; -} diff --git a/src/cosmospy_protobuf/akash/base/v1beta2/resource.proto b/src/cosmospy_protobuf/akash/base/v1beta2/resource.proto deleted file mode 100644 index 9768964d..00000000 --- a/src/cosmospy_protobuf/akash/base/v1beta2/resource.proto +++ /dev/null @@ -1,56 +0,0 @@ -syntax = "proto3"; -package akash.base.v1beta2; - -import "gogoproto/gogo.proto"; -import "akash/base/v1beta2/attribute.proto"; -import "akash/base/v1beta2/resourcevalue.proto"; - -option go_package = "github.com/ovrclk/akash/types/v1beta2"; - -// CPU stores resource units and cpu config attributes -message CPU { - option (gogoproto.equal) = true; - ResourceValue units = 1 [(gogoproto.nullable) = false]; - repeated Attribute attributes = 2 [ - (gogoproto.nullable) = false, - (gogoproto.castrepeated) = "Attributes", - (gogoproto.jsontag) = "attributes,omitempty", - (gogoproto.moretags) = "yaml:\"attributes,omitempty\"" - ]; -} - -// Memory stores resource quantity and memory attributes -message Memory { - option (gogoproto.equal) = true; - ResourceValue quantity = 1 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "size", - (gogoproto.moretags) = "yaml:\"size\"" - ]; - repeated Attribute attributes = 2 [ - (gogoproto.nullable) = false, - (gogoproto.castrepeated) = "Attributes", - (gogoproto.jsontag) = "attributes,omitempty", - (gogoproto.moretags) = "yaml:\"attributes,omitempty\"" - ]; -} - -// Storage stores resource quantity and storage attributes -message Storage { - option (gogoproto.equal) = true; - string name = 1 [ - (gogoproto.jsontag) = "name", - (gogoproto.moretags) = "yaml:\"name\"" - ]; - ResourceValue quantity = 2 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "size", - (gogoproto.moretags) = "yaml:\"size\"" - ]; - repeated Attribute attributes = 3 [ - (gogoproto.nullable) = false, - (gogoproto.castrepeated) = "Attributes", - (gogoproto.jsontag) = "attributes,omitempty", - (gogoproto.moretags) = "yaml:\"attributes,omitempty\"" - ]; -} diff --git a/src/cosmospy_protobuf/akash/base/v1beta2/resourceunits.proto b/src/cosmospy_protobuf/akash/base/v1beta2/resourceunits.proto deleted file mode 100644 index 97d866f1..00000000 --- a/src/cosmospy_protobuf/akash/base/v1beta2/resourceunits.proto +++ /dev/null @@ -1,37 +0,0 @@ -syntax = "proto3"; -package akash.base.v1beta2; - -import "gogoproto/gogo.proto"; -import "akash/base/v1beta2/resource.proto"; -import "akash/base/v1beta2/endpoint.proto"; - -option go_package = "github.com/ovrclk/akash/types/v1beta2"; - -// ResourceUnits describes all available resources types for deployment/node etc -// if field is nil resource is not present in the given data-structure -message ResourceUnits { - option (gogoproto.equal) = true; - CPU cpu = 1 [ - (gogoproto.nullable) = true, - (gogoproto.customname) = "CPU", - (gogoproto.jsontag) = "cpu,omitempty", - (gogoproto.moretags) = "yaml:\"cpu,omitempty\"" - ]; - Memory memory = 2 [ - (gogoproto.nullable) = true, - (gogoproto.jsontag) = "memory,omitempty", - (gogoproto.moretags) = "yaml:\"memory,omitempty\"" - ]; - repeated Storage storage = 3 [ - (gogoproto.nullable) = false, - (gogoproto.castrepeated) = "Volumes", - (gogoproto.jsontag) = "storage,omitempty", - (gogoproto.moretags) = "yaml:\"storage,omitempty\"" - ]; - repeated akash.base.v1beta2.Endpoint endpoints = 4 [ - (gogoproto.nullable) = false, - (gogoproto.castrepeated) = "Endpoints", - (gogoproto.jsontag) = "endpoints", - (gogoproto.moretags) = "yaml:\"endpoints\"" - ]; -} diff --git a/src/cosmospy_protobuf/akash/base/v1beta2/resourcevalue.proto b/src/cosmospy_protobuf/akash/base/v1beta2/resourcevalue.proto deleted file mode 100644 index f7a2c3ba..00000000 --- a/src/cosmospy_protobuf/akash/base/v1beta2/resourcevalue.proto +++ /dev/null @@ -1,15 +0,0 @@ -syntax = "proto3"; -package akash.base.v1beta2; - -import "gogoproto/gogo.proto"; - -option go_package = "github.com/ovrclk/akash/types/v1beta2"; - -// Unit stores cpu, memory and storage metrics -message ResourceValue { - option (gogoproto.equal) = true; - bytes val = 1 [ - (gogoproto.nullable) = false, - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int" - ]; -} diff --git a/src/cosmospy_protobuf/akash/cert/v1beta2/cert.proto b/src/cosmospy_protobuf/akash/cert/v1beta2/cert.proto deleted file mode 100644 index 6c866562..00000000 --- a/src/cosmospy_protobuf/akash/cert/v1beta2/cert.proto +++ /dev/null @@ -1,118 +0,0 @@ -syntax = "proto3"; -package akash.cert.v1beta2; - -import "gogoproto/gogo.proto"; - -option go_package = "github.com/ovrclk/akash/x/cert/types/v1beta2"; - -// Msg defines the provider Msg service -service Msg { - // CreateCertificate defines a method to create new certificate given proper inputs. - rpc CreateCertificate(MsgCreateCertificate) returns(MsgCreateCertificateResponse); - // RevokeCertificate defines a method to revoke the certificate - rpc RevokeCertificate(MsgRevokeCertificate) returns(MsgRevokeCertificateResponse); -} - -// CertificateID stores owner and sequence number -message CertificateID { - option (gogoproto.equal) = false; - option (gogoproto.goproto_stringer) = false; - - string owner = 1 [ - (gogoproto.jsontag) = "owner", - (gogoproto.moretags) = "yaml:\"owner\"" - ]; - - string serial = 2 [ - (gogoproto.jsontag) = "serial", - (gogoproto.moretags) = "yaml:\"serial\"" - ]; -} - -// Certificate stores state, certificate and it's public key -message Certificate { - // State is an enum which refers to state of deployment - enum State { - option (gogoproto.goproto_enum_prefix) = false; - - // Prefix should start with 0 in enum. So declaring dummy state - invalid = 0 [(gogoproto.enumvalue_customname) = "CertificateStateInvalid"]; - // CertificateValid denotes state for deployment active - valid = 1 [(gogoproto.enumvalue_customname) = "CertificateValid"]; - // CertificateRevoked denotes state for deployment closed - revoked = 2 [(gogoproto.enumvalue_customname) = "CertificateRevoked"]; - } - - State state = 2 [ - (gogoproto.jsontag) = "state", - (gogoproto.moretags) = "yaml:\"state\"" - ]; - - bytes cert = 3 [ - (gogoproto.jsontag) = "cert", - (gogoproto.moretags) = "yaml:\"cert\"" - ]; - - bytes pubkey = 4 [ - (gogoproto.jsontag) = "pubkey", - (gogoproto.moretags) = "yaml:\"pubkey\"" - ]; -} - -// CertificateFilter defines filters used to filter certificates -message CertificateFilter { - option (gogoproto.equal) = false; - - string owner = 1 [ - (gogoproto.jsontag) = "owner", - (gogoproto.moretags) = "yaml:\"owner\"" - ]; - - string serial = 2 [ - (gogoproto.jsontag) = "serial", - (gogoproto.moretags) = "yaml:\"serial\"" - ]; - - string state = 3 [ - (gogoproto.jsontag) = "state", - (gogoproto.moretags) = "yaml:\"state\"" - ]; -} - -// MsgCreateCertificate defines an SDK message for creating certificate -message MsgCreateCertificate { - option (gogoproto.equal) = false; - - string owner = 1 [ - (gogoproto.jsontag) = "owner", - (gogoproto.moretags) = "yaml:\"owner\"" - ]; - - bytes cert = 2 [ - (gogoproto.jsontag) = "cert", - (gogoproto.moretags) = "yaml:\"cert\"" - ]; - - bytes pubkey = 3 [ - (gogoproto.jsontag) = "pubkey", - (gogoproto.moretags) = "yaml:\"pubkey\"" - ]; -} - -// MsgCreateCertificateResponse defines the Msg/CreateCertificate response type. -message MsgCreateCertificateResponse {} - -// MsgRevokeCertificate defines an SDK message for revoking certificate -message MsgRevokeCertificate { - option (gogoproto.equal) = false; - - CertificateID id = 1 [ - (gogoproto.nullable) = false, - (gogoproto.customname) = "ID", - (gogoproto.jsontag) = "id", - (gogoproto.moretags) = "yaml:\"id\"" - ]; -} - -// MsgRevokeCertificateResponse defines the Msg/RevokeCertificate response type. -message MsgRevokeCertificateResponse {} diff --git a/src/cosmospy_protobuf/akash/cert/v1beta2/genesis.proto b/src/cosmospy_protobuf/akash/cert/v1beta2/genesis.proto deleted file mode 100644 index fd44d7ec..00000000 --- a/src/cosmospy_protobuf/akash/cert/v1beta2/genesis.proto +++ /dev/null @@ -1,31 +0,0 @@ -syntax = "proto3"; -package akash.cert.v1beta2; - -import "akash/cert/v1beta2/cert.proto"; -import "gogoproto/gogo.proto"; - -option go_package = "github.com/ovrclk/akash/x/cert/types/v1beta2"; - -// GenesisCertificate defines certificate entry at genesis -message GenesisCertificate { - string owner = 1 [ - (gogoproto.jsontag) = "owner", - (gogoproto.moretags) = "yaml:\"owner\"" - ]; - - Certificate certificate = 2 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "certificate", - (gogoproto.moretags) = "yaml:\"certificate\"" - ]; -} - -// GenesisState defines the basic genesis state used by cert module -message GenesisState { - repeated GenesisCertificate certificates = 1 [ - (gogoproto.castrepeated) = "GenesisCertificates", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "certificates", - (gogoproto.moretags) = "yaml:\"certificates\"" - ]; -} diff --git a/src/cosmospy_protobuf/akash/cert/v1beta2/query.proto b/src/cosmospy_protobuf/akash/cert/v1beta2/query.proto deleted file mode 100644 index 7fce9908..00000000 --- a/src/cosmospy_protobuf/akash/cert/v1beta2/query.proto +++ /dev/null @@ -1,50 +0,0 @@ -syntax = "proto3"; -package akash.cert.v1beta2; - -import "gogoproto/gogo.proto"; -import "google/api/annotations.proto"; -import "cosmos/base/query/v1beta1/pagination.proto"; -import "akash/cert/v1beta2/cert.proto"; - -option go_package = "github.com/ovrclk/akash/x/cert/types/v1beta2"; - -// Query defines the gRPC querier service -service Query { - // Certificates queries certificates - rpc Certificates(QueryCertificatesRequest) returns (QueryCertificatesResponse) { - option (google.api.http).get = "/akash/cert/v1beta2/certificates/list"; - } -} - -// CertificateResponse contains a single X509 certificate and its serial number -message CertificateResponse { - Certificate certificate = 1 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "certificate", - (gogoproto.moretags) = "yaml:\"certificate\"" - ]; - - string serial = 2 [ - (gogoproto.jsontag) = "serial", - (gogoproto.moretags) = "yaml:\"serial\"" - ]; -} - -// QueryDeploymentsRequest is request type for the Query/Deployments RPC method -message QueryCertificatesRequest { - CertificateFilter filter = 1 [ - (gogoproto.nullable) = false - ]; - - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} - -// QueryCertificatesResponse is response type for the Query/Certificates RPC method -message QueryCertificatesResponse { - repeated CertificateResponse certificates = 1 [ - (gogoproto.nullable) = false, - (gogoproto.castrepeated) = "CertificatesResponse" - ]; - - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} diff --git a/src/cosmospy_protobuf/akash/deployment/v1beta1/authz.proto b/src/cosmospy_protobuf/akash/deployment/v1beta1/authz.proto deleted file mode 100644 index e1003e2a..00000000 --- a/src/cosmospy_protobuf/akash/deployment/v1beta1/authz.proto +++ /dev/null @@ -1,21 +0,0 @@ -syntax = "proto3"; -package akash.deployment.v1beta1; - -import "gogoproto/gogo.proto"; -import "cosmos_proto/cosmos.proto"; -import "cosmos/base/v1beta1/coin.proto"; - -option go_package = "github.com/ovrclk/akash/x/deployment/types/v1beta1"; - -// DepositDeploymentAuthorization allows the grantee to deposit up to spend_limit coins from -// the granter's account for a deployment. -message DepositDeploymentAuthorization { - option (cosmos_proto.implements_interface) = "Authorization"; - - // SpendLimit is the amount the grantee is authorized to spend from the granter's account for - // the purpose of deployment. - cosmos.base.v1beta1.Coin spend_limit = 1 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "spend_limit" - ]; -} diff --git a/src/cosmospy_protobuf/akash/deployment/v1beta1/deployment.proto b/src/cosmospy_protobuf/akash/deployment/v1beta1/deployment.proto deleted file mode 100644 index 2698cc98..00000000 --- a/src/cosmospy_protobuf/akash/deployment/v1beta1/deployment.proto +++ /dev/null @@ -1,152 +0,0 @@ -syntax = "proto3"; -package akash.deployment.v1beta1; - -import "gogoproto/gogo.proto"; -import "akash/deployment/v1beta1/group.proto"; -import "cosmos/base/v1beta1/coin.proto"; - -option go_package = "github.com/ovrclk/akash/x/deployment/types/v1beta1"; - -// Msg defines the deployment Msg service. -service Msg { - // CreateDeployment defines a method to create new deployment given proper inputs. - rpc CreateDeployment(MsgCreateDeployment) returns (MsgCreateDeploymentResponse); - - // DepositDeployment deposits more funds into the deployment account - rpc DepositDeployment(MsgDepositDeployment) returns (MsgDepositDeploymentResponse); - - // UpdateDeployment defines a method to update a deployment given proper inputs. - rpc UpdateDeployment(MsgUpdateDeployment) returns (MsgUpdateDeploymentResponse); - - // CloseDeployment defines a method to close a deployment given proper inputs. - rpc CloseDeployment(MsgCloseDeployment) returns (MsgCloseDeploymentResponse); - - // CloseGroup defines a method to close a group of a deployment given proper inputs. - rpc CloseGroup(MsgCloseGroup) returns (MsgCloseGroupResponse); - - // PauseGroup defines a method to close a group of a deployment given proper inputs. - rpc PauseGroup(MsgPauseGroup) returns (MsgPauseGroupResponse); - - // StartGroup defines a method to close a group of a deployment given proper inputs. - rpc StartGroup(MsgStartGroup) returns (MsgStartGroupResponse); -} - -// MsgCreateDeployment defines an SDK message for creating deployment -message MsgCreateDeployment { - option (gogoproto.equal) = false; - - DeploymentID id = 1 [ - (gogoproto.nullable) = false, - (gogoproto.customname) = "ID", - (gogoproto.jsontag) = "id", - (gogoproto.moretags) = "yaml:\"id\"" - ]; - repeated GroupSpec groups = 2 - [(gogoproto.nullable) = false, (gogoproto.jsontag) = "groups", (gogoproto.moretags) = "yaml:\"groups\""]; - bytes version = 3 [(gogoproto.jsontag) = "version", (gogoproto.moretags) = "yaml:\"version\""]; - - cosmos.base.v1beta1.Coin deposit = 4 - [(gogoproto.nullable) = false, (gogoproto.jsontag) = "deposit", (gogoproto.moretags) = "yaml:\"deposit\""]; -} - -// MsgCreateDeploymentResponse defines the Msg/CreateDeployment response type. -message MsgCreateDeploymentResponse {} - -// MsgDepositDeployment deposits more funds into the deposit account -message MsgDepositDeployment { - option (gogoproto.equal) = false; - - DeploymentID id = 1 [ - (gogoproto.nullable) = false, - (gogoproto.customname) = "ID", - (gogoproto.jsontag) = "id", - (gogoproto.moretags) = "yaml:\"id\"" - ]; - - cosmos.base.v1beta1.Coin amount = 2 - [(gogoproto.nullable) = false, (gogoproto.jsontag) = "amount", (gogoproto.moretags) = "yaml:\"amount\""]; -} - -// MsgCreateDeploymentResponse defines the Msg/CreateDeployment response type. -message MsgDepositDeploymentResponse {} - -// MsgUpdateDeployment defines an SDK message for updating deployment -message MsgUpdateDeployment { - option (gogoproto.equal) = false; - - DeploymentID id = 1 [ - (gogoproto.nullable) = false, - (gogoproto.customname) = "ID", - (gogoproto.jsontag) = "id", - (gogoproto.moretags) = "yaml:\"id\"" - ]; - repeated GroupSpec groups = 2 - [(gogoproto.nullable) = false, (gogoproto.jsontag) = "groups", (gogoproto.moretags) = "yaml:\"groups\""]; - bytes version = 3 [(gogoproto.jsontag) = "version", (gogoproto.moretags) = "yaml:\"version\""]; -} - -// MsgUpdateDeploymentResponse defines the Msg/UpdateDeployment response type. -message MsgUpdateDeploymentResponse {} - -// MsgCloseDeployment defines an SDK message for closing deployment -message MsgCloseDeployment { - option (gogoproto.equal) = false; - - DeploymentID id = 1 [ - (gogoproto.nullable) = false, - (gogoproto.customname) = "ID", - (gogoproto.jsontag) = "id", - (gogoproto.moretags) = "yaml:\"id\"" - ]; -} - -// MsgCloseDeploymentResponse defines the Msg/CloseDeployment response type. -message MsgCloseDeploymentResponse {} - -// DeploymentID stores owner and sequence number -message DeploymentID { - option (gogoproto.equal) = false; - option (gogoproto.goproto_stringer) = false; - - string owner = 1 [(gogoproto.jsontag) = "owner", (gogoproto.moretags) = "yaml:\"owner\""]; - uint64 dseq = 2 - [(gogoproto.customname) = "DSeq", (gogoproto.jsontag) = "dseq", (gogoproto.moretags) = "yaml:\"dseq\""]; -} - -// Deployment stores deploymentID, state and version details -message Deployment { - option (gogoproto.equal) = false; - - DeploymentID deployment_id = 1 [ - (gogoproto.nullable) = false, - (gogoproto.customname) = "DeploymentID", - (gogoproto.jsontag) = "id", - (gogoproto.moretags) = "yaml:\"id\"" - ]; - - // State is an enum which refers to state of deployment - enum State { - option (gogoproto.goproto_enum_prefix) = false; - - // Prefix should start with 0 in enum. So declaring dummy state - invalid = 0 [(gogoproto.enumvalue_customname) = "DeploymentStateInvalid"]; - // DeploymentActive denotes state for deployment active - active = 1 [(gogoproto.enumvalue_customname) = "DeploymentActive"]; - // DeploymentClosed denotes state for deployment closed - closed = 2 [(gogoproto.enumvalue_customname) = "DeploymentClosed"]; - } - - State state = 2 [(gogoproto.jsontag) = "state", (gogoproto.moretags) = "yaml:\"state\""]; - bytes version = 3 [(gogoproto.jsontag) = "version", (gogoproto.moretags) = "yaml:\"version\""]; - int64 created_at = 4; -} - -// DeploymentFilters defines filters used to filter deployments -message DeploymentFilters { - option (gogoproto.equal) = false; - - string owner = 1 [(gogoproto.jsontag) = "owner", (gogoproto.moretags) = "yaml:\"owner\""]; - uint64 dseq = 2 - [(gogoproto.customname) = "DSeq", (gogoproto.jsontag) = "dseq", (gogoproto.moretags) = "yaml:\"dseq\""]; - string state = 3 [(gogoproto.jsontag) = "state", (gogoproto.moretags) = "yaml:\"state\""]; -} diff --git a/src/cosmospy_protobuf/akash/deployment/v1beta1/genesis.proto b/src/cosmospy_protobuf/akash/deployment/v1beta1/genesis.proto deleted file mode 100644 index 3c92c96f..00000000 --- a/src/cosmospy_protobuf/akash/deployment/v1beta1/genesis.proto +++ /dev/null @@ -1,33 +0,0 @@ -syntax = "proto3"; -package akash.deployment.v1beta1; - -import "gogoproto/gogo.proto"; -import "akash/deployment/v1beta1/deployment.proto"; -import "akash/deployment/v1beta1/group.proto"; -import "akash/deployment/v1beta1/params.proto"; - -option go_package = "github.com/ovrclk/akash/x/deployment/types/v1beta1"; - -// GenesisDeployment defines the basic genesis state used by deployment module -message GenesisDeployment { - Deployment deployment = 1 - [(gogoproto.nullable) = false, (gogoproto.jsontag) = "deployment", (gogoproto.moretags) = "yaml:\"deployment\""]; - - repeated Group groups = 2 - [(gogoproto.nullable) = false, (gogoproto.jsontag) = "groups", (gogoproto.moretags) = "yaml:\"groups\""]; -} - -// GenesisState stores slice of genesis deployment instance -message GenesisState { - repeated GenesisDeployment deployments = 1 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "deployments", - (gogoproto.moretags) = "yaml:\"deployments\"" - ]; - - Params params = 2 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "params", - (gogoproto.moretags) = "yaml:\"params\"" - ]; -} diff --git a/src/cosmospy_protobuf/akash/deployment/v1beta1/group.proto b/src/cosmospy_protobuf/akash/deployment/v1beta1/group.proto deleted file mode 100644 index 5bd313bc..00000000 --- a/src/cosmospy_protobuf/akash/deployment/v1beta1/group.proto +++ /dev/null @@ -1,128 +0,0 @@ -syntax = "proto3"; -package akash.deployment.v1beta1; - -import "gogoproto/gogo.proto"; -import "akash/base/v1beta1/resource.proto"; -import "akash/base/v1beta1/attribute.proto"; -import "cosmos/base/v1beta1/coin.proto"; - -option go_package = "github.com/ovrclk/akash/x/deployment/types/v1beta1"; - -// MsgCloseGroup defines SDK message to close a single Group within a Deployment. -message MsgCloseGroup { - option (gogoproto.equal) = false; - - GroupID id = 1 [ - (gogoproto.customname) = "ID", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "id", - (gogoproto.moretags) = "yaml:\"id\"" - ]; -} - -// MsgCloseGroupResponse defines the Msg/CloseGroup response type. -message MsgCloseGroupResponse {} - -// MsgPauseGroup defines SDK message to close a single Group within a Deployment. -message MsgPauseGroup { - option (gogoproto.equal) = false; - - GroupID id = 1 [ - (gogoproto.customname) = "ID", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "id", - (gogoproto.moretags) = "yaml:\"id\"" - ]; -} - -// MsgPauseGroupResponse defines the Msg/PauseGroup response type. -message MsgPauseGroupResponse {} - -// MsgStartGroup defines SDK message to close a single Group within a Deployment. -message MsgStartGroup { - option (gogoproto.equal) = false; - - GroupID id = 1 [ - (gogoproto.customname) = "ID", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "id", - (gogoproto.moretags) = "yaml:\"id\"" - ]; -} - -// MsgStartGroupResponse defines the Msg/StartGroup response type. -message MsgStartGroupResponse {} - -// GroupID stores owner, deployment sequence number and group sequence number -message GroupID { - option (gogoproto.equal) = false; - option (gogoproto.goproto_stringer) = false; - - string owner = 1 [(gogoproto.jsontag) = "owner", (gogoproto.moretags) = "yaml:\"owner\""]; - uint64 dseq = 2 - [(gogoproto.customname) = "DSeq", (gogoproto.jsontag) = "dseq", (gogoproto.moretags) = "yaml:\"dseq\""]; - uint32 gseq = 3 - [(gogoproto.customname) = "GSeq", (gogoproto.jsontag) = "gseq", (gogoproto.moretags) = "yaml:\"gseq\""]; -} - -// GroupSpec stores group specifications -message GroupSpec { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - string name = 1 [(gogoproto.jsontag) = "name", (gogoproto.moretags) = "yaml:\"name\""]; - - akash.base.v1beta1.PlacementRequirements requirements = 2 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "requirements", - (gogoproto.moretags) = "yaml:\"requirements\"" - ]; - - repeated Resource resources = 3 - [(gogoproto.nullable) = false, (gogoproto.jsontag) = "resources", (gogoproto.moretags) = "yaml:\"resources\""]; -} - -// Group stores group id, state and specifications of group -message Group { - option (gogoproto.equal) = false; - - GroupID group_id = 1 [ - (gogoproto.customname) = "GroupID", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "id", - (gogoproto.moretags) = "yaml:\"id\"" - ]; - - // State is an enum which refers to state of group - enum State { - option (gogoproto.goproto_enum_prefix) = false; - - // Prefix should start with 0 in enum. So declaring dummy state - invalid = 0 [(gogoproto.enumvalue_customname) = "GroupStateInvalid"]; - // GroupOpen denotes state for group open - open = 1 [(gogoproto.enumvalue_customname) = "GroupOpen"]; - // GroupOrdered denotes state for group ordered - paused = 2 [(gogoproto.enumvalue_customname) = "GroupPaused"]; - // GroupInsufficientFunds denotes state for group insufficient_funds - insufficient_funds = 3 [(gogoproto.enumvalue_customname) = "GroupInsufficientFunds"]; - // GroupClosed denotes state for group closed - closed = 4 [(gogoproto.enumvalue_customname) = "GroupClosed"]; - } - - State state = 2 [(gogoproto.jsontag) = "state", (gogoproto.moretags) = "yaml:\"state\""]; - GroupSpec group_spec = 3 - [(gogoproto.nullable) = false, (gogoproto.jsontag) = "spec", (gogoproto.moretags) = "yaml:\"spec\""]; - - int64 created_at = 4; -} - -// Resource stores unit, total count and price of resource -message Resource { - option (gogoproto.equal) = false; - - akash.base.v1beta1.ResourceUnits resources = 1 - [(gogoproto.nullable) = false, (gogoproto.jsontag) = "unit", (gogoproto.moretags) = "yaml:\"unit\""]; - uint32 count = 2 [(gogoproto.jsontag) = "count", (gogoproto.moretags) = "yaml:\"count\""]; - cosmos.base.v1beta1.Coin price = 3 - [(gogoproto.nullable) = false, (gogoproto.jsontag) = "price", (gogoproto.moretags) = "yaml:\"price\""]; -} diff --git a/src/cosmospy_protobuf/akash/deployment/v1beta1/params.proto b/src/cosmospy_protobuf/akash/deployment/v1beta1/params.proto deleted file mode 100644 index faa0adea..00000000 --- a/src/cosmospy_protobuf/akash/deployment/v1beta1/params.proto +++ /dev/null @@ -1,16 +0,0 @@ -syntax = "proto3"; -package akash.deployment.v1beta1; -import "gogoproto/gogo.proto"; -import "cosmos/base/v1beta1/coin.proto"; - -option go_package = "github.com/ovrclk/akash/x/deployment/types/v1beta1"; - -// Params defines the parameters for the x/deployment package -message Params { - cosmos.base.v1beta1.Coin deployment_min_deposit = 1 [ - (gogoproto.customname) = "DeploymentMinDeposit", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "deployment_min_deposit", - (gogoproto.moretags) = "yaml:\"deployment_min_deposit\"" - ]; -} diff --git a/src/cosmospy_protobuf/akash/deployment/v1beta1/query.proto b/src/cosmospy_protobuf/akash/deployment/v1beta1/query.proto deleted file mode 100644 index 60e810a7..00000000 --- a/src/cosmospy_protobuf/akash/deployment/v1beta1/query.proto +++ /dev/null @@ -1,71 +0,0 @@ -syntax = "proto3"; -package akash.deployment.v1beta1; - -import "gogoproto/gogo.proto"; -import "google/api/annotations.proto"; -import "cosmos/base/query/v1beta1/pagination.proto"; -import "akash/deployment/v1beta1/deployment.proto"; -import "akash/deployment/v1beta1/group.proto"; -import "akash/escrow/v1beta1/types.proto"; - -option go_package = "github.com/ovrclk/akash/x/deployment/types/v1beta1"; - -// Query defines the gRPC querier service -service Query { - // Deployments queries deployments - rpc Deployments(QueryDeploymentsRequest) returns (QueryDeploymentsResponse) { - option (google.api.http).get = "/akash/deployment/v1beta1/deployments/list"; - } - - // Deployment queries deployment details - rpc Deployment(QueryDeploymentRequest) returns (QueryDeploymentResponse) { - option (google.api.http).get = "/akash/deployment/v1beta1/deployments/info"; - } - - // Group queries group details - rpc Group(QueryGroupRequest) returns (QueryGroupResponse) { - option (google.api.http).get = "/akash/deployment/v1beta1/groups/info"; - } -} - -// QueryDeploymentsRequest is request type for the Query/Deployments RPC method -message QueryDeploymentsRequest { - DeploymentFilters filters = 1 [(gogoproto.nullable) = false]; - - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} - -// QueryDeploymentsResponse is response type for the Query/Deployments RPC method -message QueryDeploymentsResponse { - repeated QueryDeploymentResponse deployments = 1 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "DeploymentResponses"]; - - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryDeploymentRequest is request type for the Query/Deployment RPC method -message QueryDeploymentRequest { - DeploymentID id = 1 [(gogoproto.nullable) = false, (gogoproto.customname) = "ID"]; -} - -// QueryDeploymentResponse is response type for the Query/Deployment RPC method -message QueryDeploymentResponse { - option (gogoproto.equal) = false; - Deployment deployment = 1 - [(gogoproto.nullable) = false, (gogoproto.jsontag) = "deployment", (gogoproto.moretags) = "yaml:\"deployment\""]; - repeated Group groups = 2 - [(gogoproto.nullable) = false, (gogoproto.jsontag) = "groups", (gogoproto.moretags) = "yaml:\"groups\""]; - akash.escrow.v1beta1.Account escrow_account = 3 [ - (gogoproto.nullable) = false - ]; -} - -// QueryGroupRequest is request type for the Query/Group RPC method -message QueryGroupRequest { - GroupID id = 1 [(gogoproto.nullable) = false, (gogoproto.customname) = "ID"]; -} - -// QueryGroupResponse is response type for the Query/Group RPC method -message QueryGroupResponse { - Group group = 1 [(gogoproto.nullable) = false]; -} diff --git a/src/cosmospy_protobuf/akash/deployment/v1beta2/authz.proto b/src/cosmospy_protobuf/akash/deployment/v1beta2/authz.proto deleted file mode 100644 index 992ad7f8..00000000 --- a/src/cosmospy_protobuf/akash/deployment/v1beta2/authz.proto +++ /dev/null @@ -1,21 +0,0 @@ -syntax = "proto3"; -package akash.deployment.v1beta2; - -import "gogoproto/gogo.proto"; -import "cosmos_proto/cosmos.proto"; -import "cosmos/base/v1beta1/coin.proto"; - -option go_package = "github.com/ovrclk/akash/x/deployment/types/v1beta2"; - -// DepositDeploymentAuthorization allows the grantee to deposit up to spend_limit coins from -// the granter's account for a deployment. -message DepositDeploymentAuthorization { - option (cosmos_proto.implements_interface) = "Authorization"; - - // SpendLimit is the amount the grantee is authorized to spend from the granter's account for - // the purpose of deployment. - cosmos.base.v1beta1.Coin spend_limit = 1 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "spend_limit" - ]; -} diff --git a/src/cosmospy_protobuf/akash/deployment/v1beta2/deployment.proto b/src/cosmospy_protobuf/akash/deployment/v1beta2/deployment.proto deleted file mode 100644 index d9409ab9..00000000 --- a/src/cosmospy_protobuf/akash/deployment/v1beta2/deployment.proto +++ /dev/null @@ -1,75 +0,0 @@ -syntax = "proto3"; -package akash.deployment.v1beta2; - -import "gogoproto/gogo.proto"; - -option go_package = "github.com/ovrclk/akash/x/deployment/types/v1beta2"; - -// DeploymentID stores owner and sequence number -message DeploymentID { - option (gogoproto.equal) = false; - option (gogoproto.goproto_stringer) = false; - - string owner = 1 [ - (gogoproto.jsontag) = "owner", - (gogoproto.moretags) = "yaml:\"owner\"" - ]; - uint64 dseq = 2 [ - (gogoproto.customname) = "DSeq", - (gogoproto.jsontag) = "dseq", - (gogoproto.moretags) = "yaml:\"dseq\"" - ]; -} - -// Deployment stores deploymentID, state and version details -message Deployment { - option (gogoproto.equal) = false; - - DeploymentID deployment_id = 1 [ - (gogoproto.nullable) = false, - (gogoproto.customname) = "DeploymentID", - (gogoproto.jsontag) = "id", - (gogoproto.moretags) = "yaml:\"id\"" - ]; - - // State is an enum which refers to state of deployment - enum State { - option (gogoproto.goproto_enum_prefix) = false; - - // Prefix should start with 0 in enum. So declaring dummy state - invalid = 0 [(gogoproto.enumvalue_customname) = "DeploymentStateInvalid"]; - // DeploymentActive denotes state for deployment active - active = 1 [(gogoproto.enumvalue_customname) = "DeploymentActive"]; - // DeploymentClosed denotes state for deployment closed - closed = 2 [(gogoproto.enumvalue_customname) = "DeploymentClosed"]; - } - - State state = 2 [ - (gogoproto.jsontag) = "state", - (gogoproto.moretags) = "yaml:\"state\"" - ]; - bytes version = 3 [ - (gogoproto.jsontag) = "version", - (gogoproto.moretags) = "yaml:\"version\"" - ]; - int64 created_at = 4; -} - -// DeploymentFilters defines filters used to filter deployments -message DeploymentFilters { - option (gogoproto.equal) = false; - - string owner = 1 [ - (gogoproto.jsontag) = "owner", - (gogoproto.moretags) = "yaml:\"owner\"" - ]; - uint64 dseq = 2 [ - (gogoproto.customname) = "DSeq", - (gogoproto.jsontag) = "dseq", - (gogoproto.moretags) = "yaml:\"dseq\"" - ]; - string state = 3 [ - (gogoproto.jsontag) = "state", - (gogoproto.moretags) = "yaml:\"state\"" - ]; -} diff --git a/src/cosmospy_protobuf/akash/deployment/v1beta2/deploymentmsg.proto b/src/cosmospy_protobuf/akash/deployment/v1beta2/deploymentmsg.proto deleted file mode 100644 index 2f877995..00000000 --- a/src/cosmospy_protobuf/akash/deployment/v1beta2/deploymentmsg.proto +++ /dev/null @@ -1,106 +0,0 @@ -syntax = "proto3"; -package akash.deployment.v1beta2; - -import "gogoproto/gogo.proto"; - -import "akash/deployment/v1beta2/deployment.proto"; -import "akash/deployment/v1beta2/groupspec.proto"; - -import "cosmos/base/v1beta1/coin.proto"; - -option go_package = "github.com/ovrclk/akash/x/deployment/types/v1beta2"; - -// MsgCreateDeployment defines an SDK message for creating deployment -message MsgCreateDeployment { - option (gogoproto.equal) = false; - - DeploymentID id = 1 [ - (gogoproto.nullable) = false, - (gogoproto.customname) = "ID", - (gogoproto.jsontag) = "id", - (gogoproto.moretags) = "yaml:\"id\"" - ]; - repeated GroupSpec groups = 2 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "groups", - (gogoproto.moretags) = "yaml:\"groups\"" - ]; - bytes version = 3 [ - (gogoproto.jsontag) = "version", - (gogoproto.moretags) = "yaml:\"version\"" - ]; - cosmos.base.v1beta1.Coin deposit = 4 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "deposit", - (gogoproto.moretags) = "yaml:\"deposit\"" - ]; - // Depositor pays for the deposit - string depositor = 5 [ - (gogoproto.jsontag) = "depositor", - (gogoproto.moretags) = "yaml:\"depositor\"" - ]; -} - -// MsgCreateDeploymentResponse defines the Msg/CreateDeployment response type. -message MsgCreateDeploymentResponse {} - -// MsgDepositDeployment deposits more funds into the deposit account -message MsgDepositDeployment { - option (gogoproto.equal) = false; - - DeploymentID id = 1 [ - (gogoproto.nullable) = false, - (gogoproto.customname) = "ID", - (gogoproto.jsontag) = "id", - (gogoproto.moretags) = "yaml:\"id\"" - ]; - - cosmos.base.v1beta1.Coin amount = 2 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "amount", - (gogoproto.moretags) = "yaml:\"amount\"" - ]; - - // Depositor pays for the deposit - string depositor = 3 [ - (gogoproto.jsontag) = "depositor", - (gogoproto.moretags) = "yaml:\"depositor\"" - ]; -} - -// MsgCreateDeploymentResponse defines the Msg/CreateDeployment response type. -message MsgDepositDeploymentResponse {} - -// MsgUpdateDeployment defines an SDK message for updating deployment -message MsgUpdateDeployment { - option (gogoproto.equal) = false; - - DeploymentID id = 1 [ - (gogoproto.nullable) = false, - (gogoproto.customname) = "ID", - (gogoproto.jsontag) = "id", - (gogoproto.moretags) = "yaml:\"id\"" - ]; - bytes version = 3 [ - (gogoproto.jsontag) = "version", - (gogoproto.moretags) = "yaml:\"version\"" - ]; -} - -// MsgUpdateDeploymentResponse defines the Msg/UpdateDeployment response type. -message MsgUpdateDeploymentResponse {} - -// MsgCloseDeployment defines an SDK message for closing deployment -message MsgCloseDeployment { - option (gogoproto.equal) = false; - - DeploymentID id = 1 [ - (gogoproto.nullable) = false, - (gogoproto.customname) = "ID", - (gogoproto.jsontag) = "id", - (gogoproto.moretags) = "yaml:\"id\"" - ]; -} - -// MsgCloseDeploymentResponse defines the Msg/CloseDeployment response type. -message MsgCloseDeploymentResponse {} diff --git a/src/cosmospy_protobuf/akash/deployment/v1beta2/genesis.proto b/src/cosmospy_protobuf/akash/deployment/v1beta2/genesis.proto deleted file mode 100644 index f53751ad..00000000 --- a/src/cosmospy_protobuf/akash/deployment/v1beta2/genesis.proto +++ /dev/null @@ -1,39 +0,0 @@ -syntax = "proto3"; -package akash.deployment.v1beta2; - -import "gogoproto/gogo.proto"; -import "akash/deployment/v1beta2/deployment.proto"; -import "akash/deployment/v1beta2/group.proto"; -import "akash/deployment/v1beta2/params.proto"; - -option go_package = "github.com/ovrclk/akash/x/deployment/types/v1beta2"; - -// GenesisDeployment defines the basic genesis state used by deployment module -message GenesisDeployment { - Deployment deployment = 1 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "deployment", - (gogoproto.moretags) = "yaml:\"deployment\"" - ]; - - repeated Group groups = 2 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "groups", - (gogoproto.moretags) = "yaml:\"groups\"" - ]; -} - -// GenesisState stores slice of genesis deployment instance -message GenesisState { - repeated GenesisDeployment deployments = 1 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "deployments", - (gogoproto.moretags) = "yaml:\"deployments\"" - ]; - - Params params = 2 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "params", - (gogoproto.moretags) = "yaml:\"params\"" - ]; -} diff --git a/src/cosmospy_protobuf/akash/deployment/v1beta2/group.proto b/src/cosmospy_protobuf/akash/deployment/v1beta2/group.proto deleted file mode 100644 index 20ce83ec..00000000 --- a/src/cosmospy_protobuf/akash/deployment/v1beta2/group.proto +++ /dev/null @@ -1,48 +0,0 @@ -syntax = "proto3"; -package akash.deployment.v1beta2; - -import "gogoproto/gogo.proto"; -import "akash/deployment/v1beta2/groupid.proto"; -import "akash/deployment/v1beta2/groupspec.proto"; - -option go_package = "github.com/ovrclk/akash/x/deployment/types/v1beta2"; - -// Group stores group id, state and specifications of group -message Group { - option (gogoproto.equal) = false; - - GroupID group_id = 1 [ - (gogoproto.customname) = "GroupID", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "id", - (gogoproto.moretags) = "yaml:\"id\"" - ]; - - // State is an enum which refers to state of group - enum State { - option (gogoproto.goproto_enum_prefix) = false; - - // Prefix should start with 0 in enum. So declaring dummy state - invalid = 0 [(gogoproto.enumvalue_customname) = "GroupStateInvalid"]; - // GroupOpen denotes state for group open - open = 1 [(gogoproto.enumvalue_customname) = "GroupOpen"]; - // GroupOrdered denotes state for group ordered - paused = 2 [(gogoproto.enumvalue_customname) = "GroupPaused"]; - // GroupInsufficientFunds denotes state for group insufficient_funds - insufficient_funds = 3 [(gogoproto.enumvalue_customname) = "GroupInsufficientFunds"]; - // GroupClosed denotes state for group closed - closed = 4 [(gogoproto.enumvalue_customname) = "GroupClosed"]; - } - - State state = 2 [ - (gogoproto.jsontag) = "state", - (gogoproto.moretags) = "yaml:\"state\"" - ]; - GroupSpec group_spec = 3 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "spec", - (gogoproto.moretags) = "yaml:\"spec\"" - ]; - - int64 created_at = 4; -} diff --git a/src/cosmospy_protobuf/akash/deployment/v1beta2/groupid.proto b/src/cosmospy_protobuf/akash/deployment/v1beta2/groupid.proto deleted file mode 100644 index b95a83b4..00000000 --- a/src/cosmospy_protobuf/akash/deployment/v1beta2/groupid.proto +++ /dev/null @@ -1,27 +0,0 @@ -syntax = "proto3"; -package akash.deployment.v1beta2; - -import "gogoproto/gogo.proto"; - -option go_package = "github.com/ovrclk/akash/x/deployment/types/v1beta2"; - -// GroupID stores owner, deployment sequence number and group sequence number -message GroupID { - option (gogoproto.equal) = false; - option (gogoproto.goproto_stringer) = false; - - string owner = 1 [ - (gogoproto.jsontag) = "owner", - (gogoproto.moretags) = "yaml:\"owner\"" - ]; - uint64 dseq = 2 [ - (gogoproto.customname) = "DSeq", - (gogoproto.jsontag) = "dseq", - (gogoproto.moretags) = "yaml:\"dseq\"" - ]; - uint32 gseq = 3 [ - (gogoproto.customname) = "GSeq", - (gogoproto.jsontag) = "gseq", - (gogoproto.moretags) = "yaml:\"gseq\"" - ]; -} diff --git a/src/cosmospy_protobuf/akash/deployment/v1beta2/groupmsg.proto b/src/cosmospy_protobuf/akash/deployment/v1beta2/groupmsg.proto deleted file mode 100644 index c3883c17..00000000 --- a/src/cosmospy_protobuf/akash/deployment/v1beta2/groupmsg.proto +++ /dev/null @@ -1,52 +0,0 @@ -syntax = "proto3"; -package akash.deployment.v1beta2; - -import "gogoproto/gogo.proto"; -import "akash/deployment/v1beta2/groupid.proto"; - -option go_package = "github.com/ovrclk/akash/x/deployment/types/v1beta2"; - -// MsgCloseGroup defines SDK message to close a single Group within a Deployment. -message MsgCloseGroup { - option (gogoproto.equal) = false; - - GroupID id = 1 [ - (gogoproto.customname) = "ID", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "id", - (gogoproto.moretags) = "yaml:\"id\"" - ]; -} - -// MsgCloseGroupResponse defines the Msg/CloseGroup response type. -message MsgCloseGroupResponse {} - -// MsgPauseGroup defines SDK message to close a single Group within a Deployment. -message MsgPauseGroup { - option (gogoproto.equal) = false; - - GroupID id = 1 [ - (gogoproto.customname) = "ID", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "id", - (gogoproto.moretags) = "yaml:\"id\"" - ]; -} - -// MsgPauseGroupResponse defines the Msg/PauseGroup response type. -message MsgPauseGroupResponse {} - -// MsgStartGroup defines SDK message to close a single Group within a Deployment. -message MsgStartGroup { - option (gogoproto.equal) = false; - - GroupID id = 1 [ - (gogoproto.customname) = "ID", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "id", - (gogoproto.moretags) = "yaml:\"id\"" - ]; -} - -// MsgStartGroupResponse defines the Msg/StartGroup response type. -message MsgStartGroupResponse {} diff --git a/src/cosmospy_protobuf/akash/deployment/v1beta2/groupspec.proto b/src/cosmospy_protobuf/akash/deployment/v1beta2/groupspec.proto deleted file mode 100644 index 3db687ad..00000000 --- a/src/cosmospy_protobuf/akash/deployment/v1beta2/groupspec.proto +++ /dev/null @@ -1,31 +0,0 @@ -syntax = "proto3"; -package akash.deployment.v1beta2; - -import "gogoproto/gogo.proto"; -import "akash/base/v1beta2/attribute.proto"; -import "akash/deployment/v1beta2/resource.proto"; - -option go_package = "github.com/ovrclk/akash/x/deployment/types/v1beta2"; - -// GroupSpec stores group specifications -message GroupSpec { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - string name = 1 [ - (gogoproto.jsontag) = "name", - (gogoproto.moretags) = "yaml:\"name\"" - ]; - - akash.base.v1beta2.PlacementRequirements requirements = 2 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "requirements", - (gogoproto.moretags) = "yaml:\"requirements\"" - ]; - - repeated Resource resources = 3 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "resources", - (gogoproto.moretags) = "yaml:\"resources\"" - ]; -} diff --git a/src/cosmospy_protobuf/akash/deployment/v1beta2/params.proto b/src/cosmospy_protobuf/akash/deployment/v1beta2/params.proto deleted file mode 100644 index 6c2b695a..00000000 --- a/src/cosmospy_protobuf/akash/deployment/v1beta2/params.proto +++ /dev/null @@ -1,18 +0,0 @@ -syntax = "proto3"; - -package akash.deployment.v1beta2; - -import "gogoproto/gogo.proto"; -import "cosmos/base/v1beta1/coin.proto"; - -option go_package = "github.com/ovrclk/akash/x/deployment/types/v1beta2"; - -// Params defines the parameters for the x/deployment package -message Params { - cosmos.base.v1beta1.Coin deployment_min_deposit = 1 [ - (gogoproto.customname) = "DeploymentMinDeposit", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "deployment_min_deposit", - (gogoproto.moretags) = "yaml:\"deployment_min_deposit\"" - ]; -} diff --git a/src/cosmospy_protobuf/akash/deployment/v1beta2/query.proto b/src/cosmospy_protobuf/akash/deployment/v1beta2/query.proto deleted file mode 100644 index 3f55d8bd..00000000 --- a/src/cosmospy_protobuf/akash/deployment/v1beta2/query.proto +++ /dev/null @@ -1,72 +0,0 @@ -syntax = "proto3"; -package akash.deployment.v1beta2; - -import "gogoproto/gogo.proto"; -import "google/api/annotations.proto"; -import "cosmos/base/query/v1beta1/pagination.proto"; -import "akash/deployment/v1beta2/deployment.proto"; -import "akash/deployment/v1beta2/group.proto"; -import "akash/deployment/v1beta2/groupid.proto"; -import "akash/escrow/v1beta2/types.proto"; - -option go_package = "github.com/ovrclk/akash/x/deployment/types/v1beta2"; - -// Query defines the gRPC querier service -service Query { - // Deployments queries deployments - rpc Deployments(QueryDeploymentsRequest) returns (QueryDeploymentsResponse) { - option (google.api.http).get = "/akash/deployment/v1beta2/deployments/list"; - } - - // Deployment queries deployment details - rpc Deployment(QueryDeploymentRequest) returns (QueryDeploymentResponse) { - option (google.api.http).get = "/akash/deployment/v1beta2/deployments/info"; - } - - // Group queries group details - rpc Group(QueryGroupRequest) returns (QueryGroupResponse) { - option (google.api.http).get = "/akash/deployment/v1beta2/groups/info"; - } -} - -// QueryDeploymentsRequest is request type for the Query/Deployments RPC method -message QueryDeploymentsRequest { - DeploymentFilters filters = 1 [(gogoproto.nullable) = false]; - - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} - -// QueryDeploymentsResponse is response type for the Query/Deployments RPC method -message QueryDeploymentsResponse { - repeated QueryDeploymentResponse deployments = 1 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "DeploymentResponses"]; - - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryDeploymentRequest is request type for the Query/Deployment RPC method -message QueryDeploymentRequest { - DeploymentID id = 1 [(gogoproto.nullable) = false, (gogoproto.customname) = "ID"]; -} - -// QueryDeploymentResponse is response type for the Query/Deployment RPC method -message QueryDeploymentResponse { - option (gogoproto.equal) = false; - Deployment deployment = 1 - [(gogoproto.nullable) = false, (gogoproto.jsontag) = "deployment", (gogoproto.moretags) = "yaml:\"deployment\""]; - repeated Group groups = 2 - [(gogoproto.nullable) = false, (gogoproto.jsontag) = "groups", (gogoproto.moretags) = "yaml:\"groups\""]; - akash.escrow.v1beta2.Account escrow_account = 3 [ - (gogoproto.nullable) = false - ]; -} - -// QueryGroupRequest is request type for the Query/Group RPC method -message QueryGroupRequest { - GroupID id = 1 [(gogoproto.nullable) = false, (gogoproto.customname) = "ID"]; -} - -// QueryGroupResponse is response type for the Query/Group RPC method -message QueryGroupResponse { - Group group = 1 [(gogoproto.nullable) = false]; -} diff --git a/src/cosmospy_protobuf/akash/deployment/v1beta2/resource.proto b/src/cosmospy_protobuf/akash/deployment/v1beta2/resource.proto deleted file mode 100644 index 512bcd14..00000000 --- a/src/cosmospy_protobuf/akash/deployment/v1beta2/resource.proto +++ /dev/null @@ -1,28 +0,0 @@ -syntax = "proto3"; -package akash.deployment.v1beta2; - -import "gogoproto/gogo.proto"; -import "akash/base/v1beta2/resourceunits.proto"; -import "cosmos/base/v1beta1/coin.proto"; - -option go_package = "github.com/ovrclk/akash/x/deployment/types/v1beta2"; - -// Resource stores unit, total count and price of resource -message Resource { - option (gogoproto.equal) = false; - - akash.base.v1beta2.ResourceUnits resources = 1 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "unit", - (gogoproto.moretags) = "yaml:\"unit\"" - ]; - uint32 count = 2 [ - (gogoproto.jsontag) = "count", - (gogoproto.moretags) = "yaml:\"count\"" - ]; - cosmos.base.v1beta1.DecCoin price = 3 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "price", - (gogoproto.moretags) = "yaml:\"price\"" - ]; -} diff --git a/src/cosmospy_protobuf/akash/deployment/v1beta2/service.proto b/src/cosmospy_protobuf/akash/deployment/v1beta2/service.proto deleted file mode 100644 index a254f07b..00000000 --- a/src/cosmospy_protobuf/akash/deployment/v1beta2/service.proto +++ /dev/null @@ -1,31 +0,0 @@ -syntax = "proto3"; -package akash.deployment.v1beta2; - -import "akash/deployment/v1beta2/deploymentmsg.proto"; -import "akash/deployment/v1beta2/groupmsg.proto"; - -option go_package = "github.com/ovrclk/akash/x/deployment/types/v1beta2"; - -// Msg defines the deployment Msg service. -service Msg { - // CreateDeployment defines a method to create new deployment given proper inputs. - rpc CreateDeployment(MsgCreateDeployment) returns (MsgCreateDeploymentResponse); - - // DepositDeployment deposits more funds into the deployment account - rpc DepositDeployment(MsgDepositDeployment) returns (MsgDepositDeploymentResponse); - - // UpdateDeployment defines a method to update a deployment given proper inputs. - rpc UpdateDeployment(MsgUpdateDeployment) returns (MsgUpdateDeploymentResponse); - - // CloseDeployment defines a method to close a deployment given proper inputs. - rpc CloseDeployment(MsgCloseDeployment) returns (MsgCloseDeploymentResponse); - - // CloseGroup defines a method to close a group of a deployment given proper inputs. - rpc CloseGroup(MsgCloseGroup) returns (MsgCloseGroupResponse); - - // PauseGroup defines a method to close a group of a deployment given proper inputs. - rpc PauseGroup(MsgPauseGroup) returns (MsgPauseGroupResponse); - - // StartGroup defines a method to close a group of a deployment given proper inputs. - rpc StartGroup(MsgStartGroup) returns (MsgStartGroupResponse); -} diff --git a/src/cosmospy_protobuf/akash/escrow/v1beta1/genesis.proto b/src/cosmospy_protobuf/akash/escrow/v1beta1/genesis.proto deleted file mode 100644 index ea828200..00000000 --- a/src/cosmospy_protobuf/akash/escrow/v1beta1/genesis.proto +++ /dev/null @@ -1,22 +0,0 @@ -syntax = "proto3"; -package akash.escrow.v1beta1; - -import "gogoproto/gogo.proto"; -import "akash/escrow/v1beta1/types.proto"; - -option go_package = "github.com/ovrclk/akash/x/escrow/types/v1beta1"; - -// GenesisState defines the basic genesis state used by escrow module -message GenesisState { - repeated Account accounts = 1 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "accounts", - (gogoproto.moretags) = "yaml:\"accounts\"" - ]; - - repeated Payment payments = 2 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "payments", - (gogoproto.moretags) = "yaml:\"payments\"" - ]; -} diff --git a/src/cosmospy_protobuf/akash/escrow/v1beta1/query.proto b/src/cosmospy_protobuf/akash/escrow/v1beta1/query.proto deleted file mode 100644 index 41228f09..00000000 --- a/src/cosmospy_protobuf/akash/escrow/v1beta1/query.proto +++ /dev/null @@ -1,58 +0,0 @@ -syntax = "proto3"; - -package akash.escrow.v1beta1; - -import "gogoproto/gogo.proto"; -import "google/api/annotations.proto"; -import "cosmos/base/query/v1beta1/pagination.proto"; -import "akash/escrow/v1beta1/types.proto"; - -option go_package = "github.com/ovrclk/akash/x/escrow/types/v1beta1"; - -// Query defines the gRPC querier service -service Query { - // buf:lint:ignore RPC_REQUEST_RESPONSE_UNIQUE - // buf:lint:ignore RPC_RESPONSE_STANDARD_NAME - // Accounts queries all accounts - rpc Accounts(QueryAccountsRequest) returns (QueryAccountsResponse) { - option (google.api.http).get = "/akash/escrow/v1beta1/types/accounts/list"; - } - - // buf:lint:ignore RPC_REQUEST_RESPONSE_UNIQUE - // buf:lint:ignore RPC_RESPONSE_STANDARD_NAME - // Payments queries all payments - rpc Payments(QueryPaymentsRequest) returns (QueryPaymentsResponse) { - option (google.api.http).get = "/akash/escrow/v1beta1/types/payments/list"; - } -} - -// QueryAccountRequest is request type for the Query/Account RPC method -message QueryAccountsRequest { - string scope = 1; - string xid = 2; - string owner = 3; - string state = 4; - cosmos.base.query.v1beta1.PageRequest pagination = 5; -} - -// QueryProvidersResponse is response type for the Query/Providers RPC method -message QueryAccountsResponse { - repeated Account accounts = 1 [(gogoproto.nullable) = false]; - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryPaymentRequest is request type for the Query/Payment RPC method -message QueryPaymentsRequest { - string scope = 1; - string xid = 2; - string id = 3; - string owner = 4; - string state = 5; - cosmos.base.query.v1beta1.PageRequest pagination = 6; -} - -// QueryProvidersResponse is response type for the Query/Providers RPC method -message QueryPaymentsResponse { - repeated Payment payments = 1 [(gogoproto.nullable) = false]; - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} diff --git a/src/cosmospy_protobuf/akash/escrow/v1beta1/types.proto b/src/cosmospy_protobuf/akash/escrow/v1beta1/types.proto deleted file mode 100644 index 0df98ab5..00000000 --- a/src/cosmospy_protobuf/akash/escrow/v1beta1/types.proto +++ /dev/null @@ -1,139 +0,0 @@ -syntax = "proto3"; -package akash.escrow.v1beta1; - -import "gogoproto/gogo.proto"; -import "cosmos/base/v1beta1/coin.proto"; - -option go_package = "github.com/ovrclk/akash/x/escrow/types/v1beta1"; - -// AccountID is the account identifier -message AccountID { - string scope = 1 [ - (gogoproto.jsontag) = "scope", - (gogoproto.moretags) = "yaml:\"scope\"" - ]; - string xid = 2 [ - (gogoproto.jsontag) = "xid", - (gogoproto.moretags) = "yaml:\"xid\"", - (gogoproto.customname) = "XID" - ]; -} - -// Account stores state for an escrow account -message Account { - - // State stores state for an escrow account - enum State { - option (gogoproto.goproto_enum_prefix) = false; - - // AccountStateInvalid is an invalid state - invalid = 0 [(gogoproto.enumvalue_customname) = "AccountStateInvalid"]; - // AccountOpen is the state when an account is open - open = 1 [(gogoproto.enumvalue_customname) = "AccountOpen"]; - // AccountClosed is the state when an account is closed - closed = 2 [(gogoproto.enumvalue_customname) = "AccountClosed"]; - // AccountOverdrawn is the state when an account is overdrawn - overdrawn = 3 [(gogoproto.enumvalue_customname) = "AccountOverdrawn"]; - } - - // unique identifier for this escrow account - AccountID id = 1 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "id", - (gogoproto.moretags) = "yaml:\"id\"", - (gogoproto.customname) = "ID" - ]; - - // bech32 encoded account address of the owner of this escrow account - string owner = 2 [ - (gogoproto.jsontag) = "owner", - (gogoproto.moretags) = "yaml:\"owner\"" - ]; - - // current state of this escrow account - State state = 3 [ - (gogoproto.jsontag) = "state", - (gogoproto.moretags) = "yaml:\"state\"" - ]; - - // unspent coins received from the owner's wallet - cosmos.base.v1beta1.Coin balance = 4 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "balance", - (gogoproto.moretags) = "yaml:\"balance\"" - ]; - - // total coins spent by this account - cosmos.base.v1beta1.Coin transferred = 5 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "transferred", - (gogoproto.moretags) = "yaml:\"transferred\"" - ]; - - // block height at which this account was last settled - int64 settled_at = 6 [ - (gogoproto.jsontag) = "settledAt", - (gogoproto.moretags) = "yaml:\"settledAt\"", - (gogoproto.customname) = "SettledAt" - ]; -} - -// Payment stores state for a payment -message Payment { - option (gogoproto.goproto_stringer) = true; - - // Payment State - enum State { - option (gogoproto.goproto_enum_prefix) = false; - - // PaymentStateInvalid is the state when the payment is invalid - invalid = 0 [(gogoproto.enumvalue_customname) = "PaymentStateInvalid"]; - // PaymentStateOpen is the state when the payment is open - open = 1 [(gogoproto.enumvalue_customname) = "PaymentOpen"]; - // PaymentStateClosed is the state when the payment is closed - closed = 2 [(gogoproto.enumvalue_customname) = "PaymentClosed"]; - // PaymentStateOverdrawn is the state when the payment is overdrawn - overdrawn = 3 [(gogoproto.enumvalue_customname) = "PaymentOverdrawn"]; - } - - AccountID account_id = 1 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "accountID", - (gogoproto.moretags) = "yaml:\"accountID\"", - (gogoproto.customname) = "AccountID" - ]; - - string payment_id = 2 [ - (gogoproto.jsontag) = "paymentID", - (gogoproto.moretags) = "yaml:\"paymentID\"", - (gogoproto.customname) = "PaymentID" - ]; - - string owner = 3 [ - (gogoproto.jsontag) = "owner", - (gogoproto.moretags) = "yaml:\"owner\"" - ]; - - State state = 4 [ - (gogoproto.jsontag) = "state", - (gogoproto.moretags) = "yaml:\"state\"" - ]; - - cosmos.base.v1beta1.Coin rate = 5 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "rate", - (gogoproto.moretags) = "yaml:\"rate\"" - ]; - - cosmos.base.v1beta1.Coin balance = 6 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "balance", - (gogoproto.moretags) = "yaml:\"balance\"" - ]; - - cosmos.base.v1beta1.Coin withdrawn = 7 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "withdrawn", - (gogoproto.moretags) = "yaml:\"withdrawn\"" - ]; -} diff --git a/src/cosmospy_protobuf/akash/escrow/v1beta2/genesis.proto b/src/cosmospy_protobuf/akash/escrow/v1beta2/genesis.proto deleted file mode 100644 index b8e482e4..00000000 --- a/src/cosmospy_protobuf/akash/escrow/v1beta2/genesis.proto +++ /dev/null @@ -1,22 +0,0 @@ -syntax = "proto3"; -package akash.escrow.v1beta2; - -import "gogoproto/gogo.proto"; -import "akash/escrow/v1beta2/types.proto"; - -option go_package = "github.com/ovrclk/akash/x/escrow/types/v1beta2"; - -// GenesisState defines the basic genesis state used by escrow module -message GenesisState { - repeated Account accounts = 1 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "accounts", - (gogoproto.moretags) = "yaml:\"accounts\"" - ]; - - repeated FractionalPayment payments = 2 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "payments", - (gogoproto.moretags) = "yaml:\"payments\"" - ]; -} diff --git a/src/cosmospy_protobuf/akash/escrow/v1beta2/query.proto b/src/cosmospy_protobuf/akash/escrow/v1beta2/query.proto deleted file mode 100644 index 40f9608c..00000000 --- a/src/cosmospy_protobuf/akash/escrow/v1beta2/query.proto +++ /dev/null @@ -1,58 +0,0 @@ -syntax = "proto3"; - -package akash.escrow.v1beta2; - -import "gogoproto/gogo.proto"; -import "google/api/annotations.proto"; -import "cosmos/base/query/v1beta1/pagination.proto"; -import "akash/escrow/v1beta2/types.proto"; - -option go_package = "github.com/ovrclk/akash/x/escrow/types/v1beta2"; - -// Query defines the gRPC querier service -service Query { - // buf:lint:ignore RPC_REQUEST_RESPONSE_UNIQUE - // buf:lint:ignore RPC_RESPONSE_STANDARD_NAME - // Accounts queries all accounts - rpc Accounts(QueryAccountsRequest) returns (QueryAccountsResponse) { - option (google.api.http).get = "/akash/escrow/v1beta2/types/accounts/list"; - } - - // buf:lint:ignore RPC_REQUEST_RESPONSE_UNIQUE - // buf:lint:ignore RPC_RESPONSE_STANDARD_NAME - // Payments queries all payments - rpc Payments(QueryPaymentsRequest) returns (QueryPaymentsResponse) { - option (google.api.http).get = "/akash/escrow/v1beta2/types/payments/list"; - } -} - -// QueryAccountRequest is request type for the Query/Account RPC method -message QueryAccountsRequest { - string scope = 1; - string xid = 2; - string owner = 3; - string state = 4; - cosmos.base.query.v1beta1.PageRequest pagination = 5; -} - -// QueryProvidersResponse is response type for the Query/Providers RPC method -message QueryAccountsResponse { - repeated Account accounts = 1 [(gogoproto.nullable) = false]; - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryPaymentRequest is request type for the Query/Payment RPC method -message QueryPaymentsRequest { - string scope = 1; - string xid = 2; - string id = 3; - string owner = 4; - string state = 5; - cosmos.base.query.v1beta1.PageRequest pagination = 6; -} - -// QueryProvidersResponse is response type for the Query/Providers RPC method -message QueryPaymentsResponse { - repeated FractionalPayment payments = 1 [(gogoproto.nullable) = false]; - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} diff --git a/src/cosmospy_protobuf/akash/escrow/v1beta2/types.proto b/src/cosmospy_protobuf/akash/escrow/v1beta2/types.proto deleted file mode 100644 index 2713fff3..00000000 --- a/src/cosmospy_protobuf/akash/escrow/v1beta2/types.proto +++ /dev/null @@ -1,155 +0,0 @@ -syntax = "proto3"; -package akash.escrow.v1beta2; - -import "gogoproto/gogo.proto"; -import "cosmos/base/v1beta1/coin.proto"; - -option go_package = "github.com/ovrclk/akash/x/escrow/types/v1beta2"; - -// AccountID is the account identifier -message AccountID { - string scope = 1 [ - (gogoproto.jsontag) = "scope", - (gogoproto.moretags) = "yaml:\"scope\"" - ]; - string xid = 2 [ - (gogoproto.jsontag) = "xid", - (gogoproto.moretags) = "yaml:\"xid\"", - (gogoproto.customname) = "XID" - ]; -} - -// Account stores state for an escrow account -message Account { - - // State stores state for an escrow account - enum State { - option (gogoproto.goproto_enum_prefix) = false; - - // AccountStateInvalid is an invalid state - invalid = 0 [(gogoproto.enumvalue_customname) = "AccountStateInvalid"]; - // AccountOpen is the state when an account is open - open = 1 [(gogoproto.enumvalue_customname) = "AccountOpen"]; - // AccountClosed is the state when an account is closed - closed = 2 [(gogoproto.enumvalue_customname) = "AccountClosed"]; - // AccountOverdrawn is the state when an account is overdrawn - overdrawn = 3 [(gogoproto.enumvalue_customname) = "AccountOverdrawn"]; - } - - // unique identifier for this escrow account - AccountID id = 1 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "id", - (gogoproto.moretags) = "yaml:\"id\"", - (gogoproto.customname) = "ID" - ]; - - // bech32 encoded account address of the owner of this escrow account - string owner = 2 [ - (gogoproto.jsontag) = "owner", - (gogoproto.moretags) = "yaml:\"owner\"" - ]; - - // current state of this escrow account - State state = 3 [ - (gogoproto.jsontag) = "state", - (gogoproto.moretags) = "yaml:\"state\"" - ]; - - // unspent coins received from the owner's wallet - cosmos.base.v1beta1.DecCoin balance = 4 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "balance", - (gogoproto.moretags) = "yaml:\"balance\"" - ]; - - // total coins spent by this account - cosmos.base.v1beta1.DecCoin transferred = 5 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "transferred", - (gogoproto.moretags) = "yaml:\"transferred\"" - ]; - - // block height at which this account was last settled - int64 settled_at = 6 [ - (gogoproto.jsontag) = "settledAt", - (gogoproto.moretags) = "yaml:\"settledAt\"", - (gogoproto.customname) = "SettledAt" - ]; - - // bech32 encoded account address of the depositor. - // If depositor is same as the owner, then any incoming coins are added to the Balance. - // If depositor isn't same as the owner, then any incoming coins are added to the Funds. - string depositor = 7 [ - (gogoproto.jsontag) = "depositor", - (gogoproto.moretags) = "yaml:\"depositor\"" - ]; - - // Funds are unspent coins received from the (non-Owner) Depositor's wallet. - // If there are any funds, they should be spent before spending the Balance. - cosmos.base.v1beta1.DecCoin funds = 8 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "funds", - (gogoproto.moretags) = "yaml:\"funds\"" - ]; -} - -// Payment stores state for a payment -message FractionalPayment { - option (gogoproto.goproto_stringer) = true; - - // Payment State - enum State { - option (gogoproto.goproto_enum_prefix) = false; - - // PaymentStateInvalid is the state when the payment is invalid - invalid = 0 [(gogoproto.enumvalue_customname) = "PaymentStateInvalid"]; - // PaymentStateOpen is the state when the payment is open - open = 1 [(gogoproto.enumvalue_customname) = "PaymentOpen"]; - // PaymentStateClosed is the state when the payment is closed - closed = 2 [(gogoproto.enumvalue_customname) = "PaymentClosed"]; - // PaymentStateOverdrawn is the state when the payment is overdrawn - overdrawn = 3 [(gogoproto.enumvalue_customname) = "PaymentOverdrawn"]; - } - - AccountID account_id = 1 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "accountID", - (gogoproto.moretags) = "yaml:\"accountID\"", - (gogoproto.customname) = "AccountID" - ]; - - string payment_id = 2 [ - (gogoproto.jsontag) = "paymentID", - (gogoproto.moretags) = "yaml:\"paymentID\"", - (gogoproto.customname) = "PaymentID" - ]; - - string owner = 3 [ - (gogoproto.jsontag) = "owner", - (gogoproto.moretags) = "yaml:\"owner\"" - ]; - - State state = 4 [ - (gogoproto.jsontag) = "state", - (gogoproto.moretags) = "yaml:\"state\"" - ]; - - cosmos.base.v1beta1.DecCoin rate = 5 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "rate", - (gogoproto.moretags) = "yaml:\"rate\"" - ]; - - cosmos.base.v1beta1.DecCoin balance = 6 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "balance", - (gogoproto.moretags) = "yaml:\"balance\"" - ]; - - cosmos.base.v1beta1.Coin withdrawn = 7 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "withdrawn", - (gogoproto.moretags) = "yaml:\"withdrawn\"" - ]; -} diff --git a/src/cosmospy_protobuf/akash/inflation/v1beta2/genesis.proto b/src/cosmospy_protobuf/akash/inflation/v1beta2/genesis.proto deleted file mode 100644 index 53def743..00000000 --- a/src/cosmospy_protobuf/akash/inflation/v1beta2/genesis.proto +++ /dev/null @@ -1,16 +0,0 @@ -syntax = "proto3"; -package akash.inflation.v1beta2; - -import "gogoproto/gogo.proto"; -import "akash/inflation/v1beta2/params.proto"; - -option go_package = "github.com/ovrclk/akash/x/inflation/types/v1beta2"; - -// GenesisState stores slice of genesis deployment instance -message GenesisState { - Params params = 1 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "params", - (gogoproto.moretags) = "yaml:\"params\"" - ]; -} diff --git a/src/cosmospy_protobuf/akash/inflation/v1beta2/params.proto b/src/cosmospy_protobuf/akash/inflation/v1beta2/params.proto deleted file mode 100644 index 329296d8..00000000 --- a/src/cosmospy_protobuf/akash/inflation/v1beta2/params.proto +++ /dev/null @@ -1,37 +0,0 @@ -syntax = "proto3"; -package akash.inflation.v1beta2; -import "gogoproto/gogo.proto"; - -option go_package = "github.com/ovrclk/akash/x/inflation/types/v1beta2"; - -// Params defines the parameters for the x/deployment package -message Params { - // InflationDecayFactor is the number of years it takes inflation to halve. - string inflation_decay_factor = 1 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false, - (gogoproto.customname) = "InflationDecayFactor", - (gogoproto.jsontag) = "inflation_decay_factor", - (gogoproto.moretags) = "yaml:\"inflation_decay_factor\"" - ]; - - // InitialInflation is the rate at which inflation starts at genesis. - // It is a decimal value in the range [0.0, 100.0]. - string initial_inflation = 2 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false, - (gogoproto.customname) = "InitialInflation", - (gogoproto.jsontag) = "initial_inflation", - (gogoproto.moretags) = "yaml:\"initial_inflation\"" - ]; - - // Variance defines the fraction by which inflation can vary from ideal inflation in a block. - // It is a decimal value in the range [0.0, 1.0]. - string variance = 3 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false, - (gogoproto.customname) = "Variance", - (gogoproto.jsontag) = "variance", - (gogoproto.moretags) = "yaml:\"variance\"" - ]; -} diff --git a/src/cosmospy_protobuf/akash/market/v1beta2/bid.proto b/src/cosmospy_protobuf/akash/market/v1beta2/bid.proto deleted file mode 100644 index 02d2d272..00000000 --- a/src/cosmospy_protobuf/akash/market/v1beta2/bid.proto +++ /dev/null @@ -1,109 +0,0 @@ -syntax = "proto3"; -package akash.market.v1beta2; - -import "gogoproto/gogo.proto"; -import "akash/market/v1beta2/order.proto"; -import "cosmos/base/v1beta1/coin.proto"; - -option go_package = "github.com/ovrclk/akash/x/market/types/v1beta2"; - -// MsgCreateBid defines an SDK message for creating Bid -message MsgCreateBid { - option (gogoproto.equal) = false; - - OrderID order = 1 [ - (gogoproto.customname) = "Order", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "order", - (gogoproto.moretags) = "yaml:\"order\"" - ]; - string provider = 2 [(gogoproto.jsontag) = "provider", (gogoproto.moretags) = "yaml:\"provider\""]; - cosmos.base.v1beta1.DecCoin price = 3 - [(gogoproto.nullable) = false, (gogoproto.jsontag) = "price", (gogoproto.moretags) = "yaml:\"price\""]; - - cosmos.base.v1beta1.Coin deposit = 4 - [(gogoproto.nullable) = false, (gogoproto.jsontag) = "deposit", (gogoproto.moretags) = "yaml:\"deposit\""]; -} - -// MsgCreateBidResponse defines the Msg/CreateBid response type. -message MsgCreateBidResponse {} - -// MsgCloseBid defines an SDK message for closing bid -message MsgCloseBid { - option (gogoproto.equal) = false; - - BidID bid_id = 1 [ - (gogoproto.customname) = "BidID", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "id", - (gogoproto.moretags) = "yaml:\"id\"" - ]; -} - -// MsgCloseBidResponse defines the Msg/CloseBid response type. -message MsgCloseBidResponse {} - -// BidID stores owner and all other seq numbers -// A successful bid becomes a Lease(ID). -message BidID { - option (gogoproto.equal) = false; - option (gogoproto.goproto_stringer) = false; - - string owner = 1 [(gogoproto.jsontag) = "owner", (gogoproto.moretags) = "yaml:\"owner\""]; - uint64 dseq = 2 - [(gogoproto.customname) = "DSeq", (gogoproto.jsontag) = "dseq", (gogoproto.moretags) = "yaml:\"dseq\""]; - uint32 gseq = 3 - [(gogoproto.customname) = "GSeq", (gogoproto.jsontag) = "gseq", (gogoproto.moretags) = "yaml:\"gseq\""]; - uint32 oseq = 4 - [(gogoproto.customname) = "OSeq", (gogoproto.jsontag) = "oseq", (gogoproto.moretags) = "yaml:\"oseq\""]; - string provider = 5 [(gogoproto.jsontag) = "provider", (gogoproto.moretags) = "yaml:\"provider\""]; -} - -// Bid stores BidID, state of bid and price -message Bid { - option (gogoproto.equal) = false; - option (gogoproto.goproto_stringer) = false; - - BidID bid_id = 1 [ - (gogoproto.customname) = "BidID", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "id", - (gogoproto.moretags) = "yaml:\"id\"" - ]; - - // State is an enum which refers to state of bid - enum State { - option (gogoproto.goproto_enum_prefix) = false; - - // Prefix should start with 0 in enum. So declaring dummy state - invalid = 0 [(gogoproto.enumvalue_customname) = "BidStateInvalid"]; - // BidOpen denotes state for bid open - open = 1 [(gogoproto.enumvalue_customname) = "BidOpen"]; - // BidMatched denotes state for bid open - active = 2 [(gogoproto.enumvalue_customname) = "BidActive"]; - // BidLost denotes state for bid lost - lost = 3 [(gogoproto.enumvalue_customname) = "BidLost"]; - // BidClosed denotes state for bid closed - closed = 4 [(gogoproto.enumvalue_customname) = "BidClosed"]; - } - - State state = 2 [(gogoproto.jsontag) = "state", (gogoproto.moretags) = "yaml:\"state\""]; - cosmos.base.v1beta1.DecCoin price = 3 - [(gogoproto.nullable) = false, (gogoproto.jsontag) = "price", (gogoproto.moretags) = "yaml:\"price\""]; - int64 created_at = 4; -} - -// BidFilters defines flags for bid list filter -message BidFilters { - option (gogoproto.equal) = false; - - string owner = 1 [(gogoproto.jsontag) = "owner", (gogoproto.moretags) = "yaml:\"owner\""]; - uint64 dseq = 2 - [(gogoproto.customname) = "DSeq", (gogoproto.jsontag) = "dseq", (gogoproto.moretags) = "yaml:\"dseq\""]; - uint32 gseq = 3 - [(gogoproto.customname) = "GSeq", (gogoproto.jsontag) = "gseq", (gogoproto.moretags) = "yaml:\"gseq\""]; - uint32 oseq = 4 - [(gogoproto.customname) = "OSeq", (gogoproto.jsontag) = "oseq", (gogoproto.moretags) = "yaml:\"oseq\""]; - string provider = 5 [(gogoproto.jsontag) = "provider", (gogoproto.moretags) = "yaml:\"provider\""]; - string state = 6 [(gogoproto.jsontag) = "state", (gogoproto.moretags) = "yaml:\"state\""]; -} diff --git a/src/cosmospy_protobuf/akash/market/v1beta2/genesis.proto b/src/cosmospy_protobuf/akash/market/v1beta2/genesis.proto deleted file mode 100644 index 038aa0cb..00000000 --- a/src/cosmospy_protobuf/akash/market/v1beta2/genesis.proto +++ /dev/null @@ -1,24 +0,0 @@ -syntax = "proto3"; -package akash.market.v1beta2; - -import "gogoproto/gogo.proto"; -import "akash/market/v1beta2/order.proto"; -import "akash/market/v1beta2/lease.proto"; -import "akash/market/v1beta2/params.proto"; - -option go_package = "github.com/ovrclk/akash/x/market/types/v1beta2"; - -// GenesisState defines the basic genesis state used by market module -message GenesisState { - repeated Order orders = 1 - [(gogoproto.nullable) = false, (gogoproto.jsontag) = "orders", (gogoproto.moretags) = "yaml:\"orders\""]; - - repeated Lease leases = 2 - [(gogoproto.nullable) = false, (gogoproto.jsontag) = "leases", (gogoproto.moretags) = "yaml:\"leases\""]; - - Params params = 3 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "params", - (gogoproto.moretags) = "yaml:\"params\"" - ]; -} diff --git a/src/cosmospy_protobuf/akash/market/v1beta2/lease.proto b/src/cosmospy_protobuf/akash/market/v1beta2/lease.proto deleted file mode 100644 index 05ce0e69..00000000 --- a/src/cosmospy_protobuf/akash/market/v1beta2/lease.proto +++ /dev/null @@ -1,117 +0,0 @@ -syntax = "proto3"; -package akash.market.v1beta2; - -import "gogoproto/gogo.proto"; -import "cosmos/base/v1beta1/coin.proto"; -import "akash/market/v1beta2/bid.proto"; - -option go_package = "github.com/ovrclk/akash/x/market/types/v1beta2"; - -// LeaseID stores bid details of lease -message LeaseID { - option (gogoproto.equal) = false; - option (gogoproto.goproto_stringer) = false; - - string owner = 1 [(gogoproto.jsontag) = "owner", (gogoproto.moretags) = "yaml:\"owner\""]; - uint64 dseq = 2 - [(gogoproto.customname) = "DSeq", (gogoproto.jsontag) = "dseq", (gogoproto.moretags) = "yaml:\"dseq\""]; - uint32 gseq = 3 - [(gogoproto.customname) = "GSeq", (gogoproto.jsontag) = "gseq", (gogoproto.moretags) = "yaml:\"gseq\""]; - uint32 oseq = 4 - [(gogoproto.customname) = "OSeq", (gogoproto.jsontag) = "oseq", (gogoproto.moretags) = "yaml:\"oseq\""]; - string provider = 5 [(gogoproto.jsontag) = "provider", (gogoproto.moretags) = "yaml:\"provider\""]; -} - -// Lease stores LeaseID, state of lease and price -message Lease { - option (gogoproto.equal) = false; - option (gogoproto.goproto_stringer) = false; - - LeaseID lease_id = 1 [ - (gogoproto.customname) = "LeaseID", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "id", - (gogoproto.moretags) = "yaml:\"id\"" - ]; - - // State is an enum which refers to state of lease - enum State { - option (gogoproto.goproto_enum_prefix) = false; - - // Prefix should start with 0 in enum. So declaring dummy state - invalid = 0 [(gogoproto.enumvalue_customname) = "LeaseStateInvalid"]; - // LeaseActive denotes state for lease active - active = 1 [(gogoproto.enumvalue_customname) = "LeaseActive"]; - // LeaseInsufficientFunds denotes state for lease insufficient_funds - insufficient_funds = 2 [(gogoproto.enumvalue_customname) = "LeaseInsufficientFunds"]; - // LeaseClosed denotes state for lease closed - closed = 3 [(gogoproto.enumvalue_customname) = "LeaseClosed"]; - } - - State state = 2 [(gogoproto.jsontag) = "state", (gogoproto.moretags) = "yaml:\"state\""]; - cosmos.base.v1beta1.DecCoin price = 3 - [(gogoproto.nullable) = false, (gogoproto.jsontag) = "price", (gogoproto.moretags) = "yaml:\"price\""]; - int64 created_at = 4; - int64 closed_on = 5; -} - -// LeaseFilters defines flags for lease list filter -message LeaseFilters { - option (gogoproto.equal) = false; - - string owner = 1 [(gogoproto.jsontag) = "owner", (gogoproto.moretags) = "yaml:\"owner\""]; - uint64 dseq = 2 - [(gogoproto.customname) = "DSeq", (gogoproto.jsontag) = "dseq", (gogoproto.moretags) = "yaml:\"dseq\""]; - uint32 gseq = 3 - [(gogoproto.customname) = "GSeq", (gogoproto.jsontag) = "gseq", (gogoproto.moretags) = "yaml:\"gseq\""]; - uint32 oseq = 4 - [(gogoproto.customname) = "OSeq", (gogoproto.jsontag) = "oseq", (gogoproto.moretags) = "yaml:\"oseq\""]; - string provider = 5 [(gogoproto.jsontag) = "provider", (gogoproto.moretags) = "yaml:\"provider\""]; - string state = 6 [(gogoproto.jsontag) = "state", (gogoproto.moretags) = "yaml:\"state\""]; -} - -// MsgCreateLease is sent to create a lease -message MsgCreateLease { - option (gogoproto.equal) = false; - - BidID bid_id = 1 [ - (gogoproto.customname) = "BidID", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "id", - (gogoproto.moretags) = "yaml:\"id\"" - ]; -} - -// MsgCreateLeaseResponse is the response from creating a lease -message MsgCreateLeaseResponse {} - -// MsgWithdrawLease defines an SDK message for closing bid -message MsgWithdrawLease { - option (gogoproto.equal) = false; - - LeaseID bid_id = 1 [ - (gogoproto.customname) = "LeaseID", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "id", - (gogoproto.moretags) = "yaml:\"id\"" - ]; -} - -// MsgWithdrawLeaseResponse defines the Msg/WithdrawLease response type. -message MsgWithdrawLeaseResponse {} - - -// MsgCloseLease defines an SDK message for closing order -message MsgCloseLease { - option (gogoproto.equal) = false; - - LeaseID lease_id = 1 [ - (gogoproto.customname) = "LeaseID", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "id", - (gogoproto.moretags) = "yaml:\"id\"" - ]; -} - -// MsgCloseLeaseResponse defines the Msg/CloseLease response type. -message MsgCloseLeaseResponse {} diff --git a/src/cosmospy_protobuf/akash/market/v1beta2/order.proto b/src/cosmospy_protobuf/akash/market/v1beta2/order.proto deleted file mode 100644 index 2bd9589c..00000000 --- a/src/cosmospy_protobuf/akash/market/v1beta2/order.proto +++ /dev/null @@ -1,74 +0,0 @@ -syntax = "proto3"; -package akash.market.v1beta2; - -import "gogoproto/gogo.proto"; -import "akash/deployment/v1beta2/groupspec.proto"; - -option go_package = "github.com/ovrclk/akash/x/market/types/v1beta2"; - -// OrderID stores owner and all other seq numbers -message OrderID { - option (gogoproto.equal) = false; - option (gogoproto.goproto_stringer) = false; - - string owner = 1 [(gogoproto.jsontag) = "owner", (gogoproto.moretags) = "yaml:\"owner\""]; - uint64 dseq = 2 - [(gogoproto.customname) = "DSeq", (gogoproto.jsontag) = "dseq", (gogoproto.moretags) = "yaml:\"dseq\""]; - uint32 gseq = 3 - [(gogoproto.customname) = "GSeq", (gogoproto.jsontag) = "gseq", (gogoproto.moretags) = "yaml:\"gseq\""]; - uint32 oseq = 4 - [(gogoproto.customname) = "OSeq", (gogoproto.jsontag) = "oseq", (gogoproto.moretags) = "yaml:\"oseq\""]; -} - -// Order stores orderID, state of order and other details -message Order { - option (gogoproto.equal) = false; - option (gogoproto.goproto_stringer) = false; - - OrderID order_id = 1 [ - (gogoproto.customname) = "OrderID", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "id", - (gogoproto.moretags) = "yaml:\"id\"" - ]; - - // State is an enum which refers to state of order - enum State { - option (gogoproto.goproto_enum_prefix) = false; - - // Prefix should start with 0 in enum. So declaring dummy state - invalid = 0 [(gogoproto.enumvalue_customname) = "OrderStateInvalid"]; - // OrderOpen denotes state for order open - open = 1 [(gogoproto.enumvalue_customname) = "OrderOpen"]; - // OrderMatched denotes state for order matched - active = 2 [(gogoproto.enumvalue_customname) = "OrderActive"]; - // OrderClosed denotes state for order lost - closed = 3 [(gogoproto.enumvalue_customname) = "OrderClosed"]; - } - - State state = 2 [ - (gogoproto.jsontag) = "state", - (gogoproto.moretags) = "yaml:\"state\"" - ]; - akash.deployment.v1beta2.GroupSpec spec = 3 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "spec", - (gogoproto.moretags) = "yaml:\"spec\"" - ]; - - int64 created_at = 4; -} - -// OrderFilters defines flags for order list filter -message OrderFilters { - option (gogoproto.equal) = false; - - string owner = 1 [(gogoproto.jsontag) = "owner", (gogoproto.moretags) = "yaml:\"owner\""]; - uint64 dseq = 2 - [(gogoproto.customname) = "DSeq", (gogoproto.jsontag) = "dseq", (gogoproto.moretags) = "yaml:\"dseq\""]; - uint32 gseq = 3 - [(gogoproto.customname) = "GSeq", (gogoproto.jsontag) = "gseq", (gogoproto.moretags) = "yaml:\"gseq\""]; - uint32 oseq = 4 - [(gogoproto.customname) = "OSeq", (gogoproto.jsontag) = "oseq", (gogoproto.moretags) = "yaml:\"oseq\""]; - string state = 5 [(gogoproto.jsontag) = "state", (gogoproto.moretags) = "yaml:\"state\""]; -} diff --git a/src/cosmospy_protobuf/akash/market/v1beta2/params.proto b/src/cosmospy_protobuf/akash/market/v1beta2/params.proto deleted file mode 100644 index 8eb45f53..00000000 --- a/src/cosmospy_protobuf/akash/market/v1beta2/params.proto +++ /dev/null @@ -1,21 +0,0 @@ -syntax = "proto3"; -package akash.market.v1beta2; -import "gogoproto/gogo.proto"; -import "cosmos/base/v1beta1/coin.proto"; - -option go_package = "github.com/ovrclk/akash/x/market/types/v1beta2"; - -// Params is the params for the x/market module -message Params { - cosmos.base.v1beta1.Coin bid_min_deposit = 1 [ - (gogoproto.customname) = "BidMinDeposit", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "bid_min_deposit", - (gogoproto.moretags) = "yaml:\"bid_min_deposit\"" - ]; - uint32 order_max_bids = 2 [ - (gogoproto.customname) = "OrderMaxBids", - (gogoproto.jsontag) = "order_max_bids", - (gogoproto.moretags) = "yaml:\"order_max_bids\"" - ]; -} diff --git a/src/cosmospy_protobuf/akash/market/v1beta2/query.proto b/src/cosmospy_protobuf/akash/market/v1beta2/query.proto deleted file mode 100644 index 230f091d..00000000 --- a/src/cosmospy_protobuf/akash/market/v1beta2/query.proto +++ /dev/null @@ -1,123 +0,0 @@ -syntax = "proto3"; -package akash.market.v1beta2; - -import "gogoproto/gogo.proto"; -import "google/api/annotations.proto"; -import "cosmos/base/query/v1beta1/pagination.proto"; -import "akash/market/v1beta2/order.proto"; -import "akash/market/v1beta2/bid.proto"; -import "akash/market/v1beta2/lease.proto"; -import "akash/escrow/v1beta2/types.proto"; - -option go_package = "github.com/ovrclk/akash/x/market/types/v1beta2"; - -// Query defines the gRPC querier service -service Query { - // Orders queries orders with filters - rpc Orders(QueryOrdersRequest) returns (QueryOrdersResponse) { - option (google.api.http).get = "/akash/market/v1beta2/orders/list"; - } - - // Order queries order details - rpc Order(QueryOrderRequest) returns (QueryOrderResponse) { - option (google.api.http).get = "/akash/market/v1beta2/orders/info"; - } - - // Bids queries bids with filters - rpc Bids(QueryBidsRequest) returns (QueryBidsResponse) { - option (google.api.http).get = "/akash/market/v1beta2/bids/list"; - } - - // Bid queries bid details - rpc Bid(QueryBidRequest) returns (QueryBidResponse) { - option (google.api.http).get = "/akash/market/v1beta2/bids/info"; - } - - // Leases queries leases with filters - rpc Leases(QueryLeasesRequest) returns (QueryLeasesResponse) { - option (google.api.http).get = "/akash/market/v1beta2/leases/list"; - } - - // Lease queries lease details - rpc Lease(QueryLeaseRequest) returns (QueryLeaseResponse) { - option (google.api.http).get = "/akash/market/v1beta2/leases/info"; - } -} - -// QueryOrdersRequest is request type for the Query/Orders RPC method -message QueryOrdersRequest { - OrderFilters filters = 1 [(gogoproto.nullable) = false]; - - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} - -// QueryOrdersResponse is response type for the Query/Orders RPC method -message QueryOrdersResponse { - repeated Order orders = 1 [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "Orders"]; - - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryOrderRequest is request type for the Query/Order RPC method -message QueryOrderRequest { - OrderID id = 1 [(gogoproto.nullable) = false, (gogoproto.customname) = "ID"]; -} - -// QueryOrderResponse is response type for the Query/Order RPC method -message QueryOrderResponse { - Order order = 1 [(gogoproto.nullable) = false]; -} - -// QueryBidsRequest is request type for the Query/Bids RPC method -message QueryBidsRequest { - BidFilters filters = 1 [(gogoproto.nullable) = false]; - - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} - -// QueryBidsResponse is response type for the Query/Bids RPC method -message QueryBidsResponse { - repeated QueryBidResponse bids = 1 [(gogoproto.nullable) = false]; - - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryBidRequest is request type for the Query/Bid RPC method -message QueryBidRequest { - BidID id = 1 [(gogoproto.nullable) = false, (gogoproto.customname) = "ID"]; -} - -// QueryBidResponse is response type for the Query/Bid RPC method -message QueryBidResponse { - Bid bid = 1 [(gogoproto.nullable) = false]; - akash.escrow.v1beta2.Account escrow_account = 2 [ - (gogoproto.nullable) = false - ]; -} - -// QueryLeasesRequest is request type for the Query/Leases RPC method -message QueryLeasesRequest { - LeaseFilters filters = 1 [(gogoproto.nullable) = false]; - - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} - -// QueryLeasesResponse is response type for the Query/Leases RPC method -message QueryLeasesResponse { - repeated QueryLeaseResponse leases = 1 [(gogoproto.nullable) = false]; - - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryLeaseRequest is request type for the Query/Lease RPC method -message QueryLeaseRequest { - LeaseID id = 1 [(gogoproto.nullable) = false, (gogoproto.customname) = "ID"]; -} - -// QueryLeaseResponse is response type for the Query/Lease RPC method -message QueryLeaseResponse { - Lease lease = 1 [(gogoproto.nullable) = false]; - akash.escrow.v1beta2.FractionalPayment escrow_payment = 2 [ - (gogoproto.nullable) = false - ]; -} diff --git a/src/cosmospy_protobuf/akash/market/v1beta2/service.proto b/src/cosmospy_protobuf/akash/market/v1beta2/service.proto deleted file mode 100644 index 1a9a123d..00000000 --- a/src/cosmospy_protobuf/akash/market/v1beta2/service.proto +++ /dev/null @@ -1,24 +0,0 @@ -syntax = "proto3"; -package akash.market.v1beta2; - -import "akash/market/v1beta2/bid.proto"; -import "akash/market/v1beta2/lease.proto"; -option go_package = "github.com/ovrclk/akash/x/market/types/v1beta2"; - -// Msg defines the market Msg service -service Msg { - // CreateBid defines a method to create a bid given proper inputs. - rpc CreateBid(MsgCreateBid) returns (MsgCreateBidResponse); - - // CloseBid defines a method to close a bid given proper inputs. - rpc CloseBid(MsgCloseBid) returns (MsgCloseBidResponse); - - // WithdrawLease withdraws accrued funds from the lease payment - rpc WithdrawLease(MsgWithdrawLease) returns (MsgWithdrawLeaseResponse); - - // CreateLease creates a new lease - rpc CreateLease(MsgCreateLease) returns (MsgCreateLeaseResponse); - - // CloseLease defines a method to close an order given proper inputs. - rpc CloseLease(MsgCloseLease) returns (MsgCloseLeaseResponse); -} diff --git a/src/cosmospy_protobuf/akash/provider/v1beta1/provider.proto b/src/cosmospy_protobuf/akash/provider/v1beta1/provider.proto deleted file mode 100644 index da0e90aa..00000000 --- a/src/cosmospy_protobuf/akash/provider/v1beta1/provider.proto +++ /dev/null @@ -1,120 +0,0 @@ -syntax = "proto3"; -package akash.provider.v1beta1; - -import "gogoproto/gogo.proto"; -import "akash/base/v1beta1/attribute.proto"; - -option go_package = "github.com/ovrclk/akash/x/provider/types/v1beta1"; - -// Msg defines the provider Msg service -service Msg { - // CreateProvider defines a method that creates a provider given the proper inputs - rpc CreateProvider(MsgCreateProvider) returns (MsgCreateProviderResponse); - - // UpdateProvider defines a method that updates a provider given the proper inputs - rpc UpdateProvider(MsgUpdateProvider) returns (MsgUpdateProviderResponse); - - // DeleteProvider defines a method that deletes a provider given the proper inputs - rpc DeleteProvider(MsgDeleteProvider) returns (MsgDeleteProviderResponse); -} - -// ProviderInfo -message ProviderInfo { - string email = 1 [ - (gogoproto.customname) = "EMail", - (gogoproto.jsontag) = "email", - (gogoproto.moretags) = "yaml:\"email\"" - ]; - string website = 2 [ - (gogoproto.jsontag) = "website", - (gogoproto.moretags) = "yaml:\"website\"" - ]; -} - -// MsgCreateProvider defines an SDK message for creating a provider -message MsgCreateProvider { - option (gogoproto.equal) = false; - - string owner = 1 [(gogoproto.jsontag) = "owner", (gogoproto.moretags) = "yaml:\"owner\""]; - string host_uri = 2 [ - (gogoproto.customname) = "HostURI", - (gogoproto.jsontag) = "host_uri", - (gogoproto.moretags) = "yaml:\"host_uri\"" - ]; - repeated akash.base.v1beta1.Attribute attributes = 3 [ - (gogoproto.castrepeated) = "github.com/ovrclk/akash/types/v1beta1.Attributes", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "attributes", - (gogoproto.moretags) = "yaml:\"attributes\"" - ]; - - ProviderInfo info = 4 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "info", - (gogoproto.moretags) = "yaml:\"info\"" - ]; -} - -// MsgCreateProviderResponse defines the Msg/CreateProvider response type. -message MsgCreateProviderResponse {} - -// MsgUpdateProvider defines an SDK message for updating a provider -message MsgUpdateProvider { - option (gogoproto.equal) = false; - - string owner = 1 [(gogoproto.jsontag) = "owner", (gogoproto.moretags) = "yaml:\"owner\""]; - string host_uri = 2 [ - (gogoproto.customname) = "HostURI", - (gogoproto.jsontag) = "host_uri", - (gogoproto.moretags) = "yaml:\"host_uri\"" - ]; - repeated akash.base.v1beta1.Attribute attributes = 3 [ - (gogoproto.castrepeated) = "github.com/ovrclk/akash/types/v1beta1.Attributes", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "attributes", - (gogoproto.moretags) = "yaml:\"attributes\"" - ]; - ProviderInfo info = 4 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "info", - (gogoproto.moretags) = "yaml:\"info\"" - ]; -} - -// MsgUpdateProviderResponse defines the Msg/UpdateProvider response type. -message MsgUpdateProviderResponse {} - -// MsgDeleteProvider defines an SDK message for deleting a provider -message MsgDeleteProvider { - option (gogoproto.equal) = false; - - string owner = 1 [(gogoproto.jsontag) = "owner", (gogoproto.moretags) = "yaml:\"owner\""]; -} - -// MsgDeleteProviderResponse defines the Msg/DeleteProvider response type. -message MsgDeleteProviderResponse {} - -// Provider stores owner and host details -message Provider { - option (gogoproto.equal) = false; - option (gogoproto.goproto_stringer) = false; - - string owner = 1 [(gogoproto.jsontag) = "owner", (gogoproto.moretags) = "yaml:\"owner\""]; - string host_uri = 2 [ - (gogoproto.customname) = "HostURI", - (gogoproto.jsontag) = "host_uri", - (gogoproto.moretags) = "yaml:\"host_uri\"" - ]; - repeated akash.base.v1beta1.Attribute attributes = 3 [ - (gogoproto.castrepeated) = "github.com/ovrclk/akash/types/v1beta1.Attributes", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "attributes", - (gogoproto.moretags) = "yaml:\"attributes\"" - ]; - - ProviderInfo info = 4 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "info", - (gogoproto.moretags) = "yaml:\"info\"" - ]; -} diff --git a/src/cosmospy_protobuf/akash/provider/v1beta2/genesis.proto b/src/cosmospy_protobuf/akash/provider/v1beta2/genesis.proto deleted file mode 100644 index 1ce9788f..00000000 --- a/src/cosmospy_protobuf/akash/provider/v1beta2/genesis.proto +++ /dev/null @@ -1,16 +0,0 @@ -syntax = "proto3"; -package akash.provider.v1beta2; - -import "gogoproto/gogo.proto"; -import "akash/provider/v1beta2/provider.proto"; - -option go_package = "github.com/ovrclk/akash/x/provider/types/v1beta2"; - -// GenesisState defines the basic genesis state used by provider module -message GenesisState { - repeated Provider providers = 1 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "providers", - (gogoproto.moretags) = "yaml:\"providers\"" - ]; -} diff --git a/src/cosmospy_protobuf/akash/provider/v1beta2/provider.proto b/src/cosmospy_protobuf/akash/provider/v1beta2/provider.proto deleted file mode 100644 index 16ac1146..00000000 --- a/src/cosmospy_protobuf/akash/provider/v1beta2/provider.proto +++ /dev/null @@ -1,120 +0,0 @@ -syntax = "proto3"; -package akash.provider.v1beta2; - -import "gogoproto/gogo.proto"; -import "akash/base/v1beta2/attribute.proto"; - -option go_package = "github.com/ovrclk/akash/x/provider/types/v1beta2"; - -// Msg defines the provider Msg service -service Msg { - // CreateProvider defines a method that creates a provider given the proper inputs - rpc CreateProvider(MsgCreateProvider) returns (MsgCreateProviderResponse); - - // UpdateProvider defines a method that updates a provider given the proper inputs - rpc UpdateProvider(MsgUpdateProvider) returns (MsgUpdateProviderResponse); - - // DeleteProvider defines a method that deletes a provider given the proper inputs - rpc DeleteProvider(MsgDeleteProvider) returns (MsgDeleteProviderResponse); -} - -// ProviderInfo -message ProviderInfo { - string email = 1 [ - (gogoproto.customname) = "EMail", - (gogoproto.jsontag) = "email", - (gogoproto.moretags) = "yaml:\"email\"" - ]; - string website = 2 [ - (gogoproto.jsontag) = "website", - (gogoproto.moretags) = "yaml:\"website\"" - ]; -} - -// MsgCreateProvider defines an SDK message for creating a provider -message MsgCreateProvider { - option (gogoproto.equal) = false; - - string owner = 1 [(gogoproto.jsontag) = "owner", (gogoproto.moretags) = "yaml:\"owner\""]; - string host_uri = 2 [ - (gogoproto.customname) = "HostURI", - (gogoproto.jsontag) = "host_uri", - (gogoproto.moretags) = "yaml:\"host_uri\"" - ]; - repeated akash.base.v1beta2.Attribute attributes = 3 [ - (gogoproto.castrepeated) = "github.com/ovrclk/akash/types/v1beta2.Attributes", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "attributes", - (gogoproto.moretags) = "yaml:\"attributes\"" - ]; - - ProviderInfo info = 4 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "info", - (gogoproto.moretags) = "yaml:\"info\"" - ]; -} - -// MsgCreateProviderResponse defines the Msg/CreateProvider response type. -message MsgCreateProviderResponse {} - -// MsgUpdateProvider defines an SDK message for updating a provider -message MsgUpdateProvider { - option (gogoproto.equal) = false; - - string owner = 1 [(gogoproto.jsontag) = "owner", (gogoproto.moretags) = "yaml:\"owner\""]; - string host_uri = 2 [ - (gogoproto.customname) = "HostURI", - (gogoproto.jsontag) = "host_uri", - (gogoproto.moretags) = "yaml:\"host_uri\"" - ]; - repeated akash.base.v1beta2.Attribute attributes = 3 [ - (gogoproto.castrepeated) = "github.com/ovrclk/akash/types/v1beta2.Attributes", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "attributes", - (gogoproto.moretags) = "yaml:\"attributes\"" - ]; - ProviderInfo info = 4 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "info", - (gogoproto.moretags) = "yaml:\"info\"" - ]; -} - -// MsgUpdateProviderResponse defines the Msg/UpdateProvider response type. -message MsgUpdateProviderResponse {} - -// MsgDeleteProvider defines an SDK message for deleting a provider -message MsgDeleteProvider { - option (gogoproto.equal) = false; - - string owner = 1 [(gogoproto.jsontag) = "owner", (gogoproto.moretags) = "yaml:\"owner\""]; -} - -// MsgDeleteProviderResponse defines the Msg/DeleteProvider response type. -message MsgDeleteProviderResponse {} - -// Provider stores owner and host details -message Provider { - option (gogoproto.equal) = false; - option (gogoproto.goproto_stringer) = false; - - string owner = 1 [(gogoproto.jsontag) = "owner", (gogoproto.moretags) = "yaml:\"owner\""]; - string host_uri = 2 [ - (gogoproto.customname) = "HostURI", - (gogoproto.jsontag) = "host_uri", - (gogoproto.moretags) = "yaml:\"host_uri\"" - ]; - repeated akash.base.v1beta2.Attribute attributes = 3 [ - (gogoproto.castrepeated) = "github.com/ovrclk/akash/types/v1beta2.Attributes", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "attributes", - (gogoproto.moretags) = "yaml:\"attributes\"" - ]; - - ProviderInfo info = 4 [ - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "info", - (gogoproto.moretags) = "yaml:\"info\"" - ]; -} diff --git a/src/cosmospy_protobuf/akash/provider/v1beta2/query.proto b/src/cosmospy_protobuf/akash/provider/v1beta2/query.proto deleted file mode 100644 index 2c777522..00000000 --- a/src/cosmospy_protobuf/akash/provider/v1beta2/query.proto +++ /dev/null @@ -1,44 +0,0 @@ -syntax = "proto3"; -package akash.provider.v1beta2; - -import "gogoproto/gogo.proto"; -import "google/api/annotations.proto"; -import "cosmos/base/query/v1beta1/pagination.proto"; -import "akash/provider/v1beta2/provider.proto"; - -option go_package = "github.com/ovrclk/akash/x/provider/types/v1beta2"; - -// Query defines the gRPC querier service -service Query { - // Providers queries providers - rpc Providers(QueryProvidersRequest) returns (QueryProvidersResponse) { - option (google.api.http).get = "/akash/provider/v1beta2/providers"; - } - - // Provider queries provider details - rpc Provider(QueryProviderRequest) returns (QueryProviderResponse) { - option (google.api.http).get = "/akash/provider/v1beta2/providers/{owner}"; - } -} - -// QueryProvidersRequest is request type for the Query/Providers RPC method -message QueryProvidersRequest { - cosmos.base.query.v1beta1.PageRequest pagination = 1; -} - -// QueryProvidersResponse is response type for the Query/Providers RPC method -message QueryProvidersResponse { - repeated Provider providers = 1 [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "Providers"]; - - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryProviderRequest is request type for the Query/Provider RPC method -message QueryProviderRequest { - string owner = 1; -} - -// QueryProviderResponse is response type for the Query/Provider RPC method -message QueryProviderResponse { - Provider provider = 1 [(gogoproto.nullable) = false]; -} diff --git a/src/cosmospy_protobuf/bitsong/fantoken/v1beta1/events.proto b/src/cosmospy_protobuf/bitsong/fantoken/v1beta1/events.proto deleted file mode 100644 index 53029571..00000000 --- a/src/cosmospy_protobuf/bitsong/fantoken/v1beta1/events.proto +++ /dev/null @@ -1,40 +0,0 @@ -syntax = "proto3"; -package bitsong.fantoken.v1beta1; - -import "gogoproto/gogo.proto"; - -option go_package = "github.com/bitsongofficial/go-bitsong/x/fantoken/types"; - -message EventIssue { - string denom = 1; -} - -message EventDisableMint { - string denom = 1; -} - -message EventMint { - string recipient = 1; - string coin = 2; -} - -message EventBurn { - string sender = 1; - string coin = 2; -} - -message EventSetAuthority { - string denom = 1; - string old_authority = 2 [ (gogoproto.moretags) = "yaml:\"old_authority\"" ]; - string new_authority = 3 [ (gogoproto.moretags) = "yaml:\"new_authority\"" ]; -} - -message EventSetMinter { - string denom = 1; - string old_minter = 2 [ (gogoproto.moretags) = "yaml:\"old_minter\"" ]; - string new_minter = 3 [ (gogoproto.moretags) = "yaml:\"new_minter\"" ]; -} - -message EventSetUri { - string denom = 1; -} \ No newline at end of file diff --git a/src/cosmospy_protobuf/bitsong/fantoken/v1beta1/fantoken.proto b/src/cosmospy_protobuf/bitsong/fantoken/v1beta1/fantoken.proto deleted file mode 100644 index 9904b7df..00000000 --- a/src/cosmospy_protobuf/bitsong/fantoken/v1beta1/fantoken.proto +++ /dev/null @@ -1,46 +0,0 @@ -syntax = "proto3"; -package bitsong.fantoken.v1beta1; - -import "cosmos/base/v1beta1/coin.proto"; -import "gogoproto/gogo.proto"; - -option go_package = "github.com/bitsongofficial/go-bitsong/x/fantoken/types"; -option (gogoproto.goproto_getters_all) = false; - -message Metadata { - // name defines the name of the fantoken (eg: Kitty Punk) - string name = 1; - - // symbol is the token symbol usually shown on exchanges (eg: KITTY) - string symbol = 2; - - // URI to a document (on or off-chain) that contains additional - // information.Optional. - string uri = 3 [ (gogoproto.customname) = "URI" ]; - - // sdk.AccAddress allowed to set a new uri - string authority = 4; -} - -// FanToken defines a standard for the fungible token -message FanToken { - option (gogoproto.goproto_getters) = false; - option (gogoproto.goproto_stringer) = false; - - // denom represents the string name of the given denom unit (e.g ft). - string denom = 1; - - string max_supply = 2 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.moretags) = "yaml:\"max_supply\"", - (gogoproto.nullable) = false - ]; - - // sdk.AccAddress allowed to mint new fantoken - string minter = 3; - - Metadata meta_data = 4 [ - (gogoproto.moretags) = "yaml:\"meta_data\"", - (gogoproto.nullable) = false - ]; -} \ No newline at end of file diff --git a/src/cosmospy_protobuf/bitsong/fantoken/v1beta1/genesis.proto b/src/cosmospy_protobuf/bitsong/fantoken/v1beta1/genesis.proto deleted file mode 100644 index 130cc3a0..00000000 --- a/src/cosmospy_protobuf/bitsong/fantoken/v1beta1/genesis.proto +++ /dev/null @@ -1,17 +0,0 @@ -syntax = "proto3"; -package bitsong.fantoken.v1beta1; - -import "gogoproto/gogo.proto"; -import "bitsong/fantoken/v1beta1/fantoken.proto"; -import "bitsong/fantoken/v1beta1/params.proto"; -import "cosmos/base/v1beta1/coin.proto"; - -option go_package = "github.com/bitsongofficial/go-bitsong/x/fantoken/types"; - -// GenesisState defines the fantoken module's genesis state -message GenesisState { - bitsong.fantoken.v1beta1.Params params = 1 [ (gogoproto.nullable) = false ]; - - repeated bitsong.fantoken.v1beta1.FanToken fan_tokens = 2 - [ (gogoproto.nullable) = false ]; -} \ No newline at end of file diff --git a/src/cosmospy_protobuf/bitsong/fantoken/v1beta1/gov.proto b/src/cosmospy_protobuf/bitsong/fantoken/v1beta1/gov.proto deleted file mode 100644 index 4936a5f9..00000000 --- a/src/cosmospy_protobuf/bitsong/fantoken/v1beta1/gov.proto +++ /dev/null @@ -1,42 +0,0 @@ -syntax = "proto3"; -package bitsong.fantoken.v1beta1; - -import "cosmos/base/v1beta1/coin.proto"; -import "gogoproto/gogo.proto"; - -option go_package = "github.com/bitsongofficial/go-bitsong/x/fantoken/types"; -option (gogoproto.goproto_getters_all) = false; - -message UpdateFeesProposal { - option (gogoproto.equal) = true; - option (gogoproto.goproto_stringer) = false; - - string title = 1; - string description = 2; - - cosmos.base.v1beta1.Coin issue_fee = 3 [ - (gogoproto.moretags) = "yaml:\"issue_fee\"", - (gogoproto.nullable) = false - ]; - - cosmos.base.v1beta1.Coin mint_fee = 4 [ - (gogoproto.moretags) = "yaml:\"mint_fee\"", - (gogoproto.nullable) = false - ]; - - cosmos.base.v1beta1.Coin burn_fee = 5 [ - (gogoproto.moretags) = "yaml:\"burn_fee\"", - (gogoproto.nullable) = false - ]; -} - -message UpdateFeesProposalWithDeposit { - option (gogoproto.goproto_stringer) = true; - - string title = 1; - string description = 2; - string issue_fee = 3; - string mint_fee = 4; - string burn_fee = 5; - string deposit = 7; -} \ No newline at end of file diff --git a/src/cosmospy_protobuf/bitsong/fantoken/v1beta1/params.proto b/src/cosmospy_protobuf/bitsong/fantoken/v1beta1/params.proto deleted file mode 100644 index 3a086a20..00000000 --- a/src/cosmospy_protobuf/bitsong/fantoken/v1beta1/params.proto +++ /dev/null @@ -1,29 +0,0 @@ -syntax = "proto3"; -package bitsong.fantoken.v1beta1; - -import "cosmos/base/v1beta1/coin.proto"; -import "gogoproto/gogo.proto"; - -option go_package = "github.com/bitsongofficial/go-bitsong/x/fantoken/types"; -option (gogoproto.goproto_getters_all) = false; - -// Params defines fantoken module's parameters -message Params { - option (gogoproto.equal) = true; - option (gogoproto.goproto_stringer) = false; - - cosmos.base.v1beta1.Coin issue_fee = 1 [ - (gogoproto.moretags) = "yaml:\"issue_fee\"", - (gogoproto.nullable) = false - ]; - - cosmos.base.v1beta1.Coin mint_fee = 2 [ - (gogoproto.moretags) = "yaml:\"mint_fee\"", - (gogoproto.nullable) = false - ]; - - cosmos.base.v1beta1.Coin burn_fee = 3 [ - (gogoproto.moretags) = "yaml:\"burn_fee\"", - (gogoproto.nullable) = false - ]; -} \ No newline at end of file diff --git a/src/cosmospy_protobuf/bitsong/fantoken/v1beta1/query.proto b/src/cosmospy_protobuf/bitsong/fantoken/v1beta1/query.proto deleted file mode 100644 index 4b18881b..00000000 --- a/src/cosmospy_protobuf/bitsong/fantoken/v1beta1/query.proto +++ /dev/null @@ -1,57 +0,0 @@ -syntax = "proto3"; -package bitsong.fantoken.v1beta1; - -import "cosmos/base/v1beta1/coin.proto"; -import "cosmos/base/query/v1beta1/pagination.proto"; -import "gogoproto/gogo.proto"; -import "google/api/annotations.proto"; -import "bitsong/fantoken/v1beta1/fantoken.proto"; -import "bitsong/fantoken/v1beta1/params.proto"; - -option go_package = "github.com/bitsongofficial/go-bitsong/x/fantoken/types"; - -// Query creates service with fantoken as RPC -service Query { - - // FanToken returns fantoken with fantoken name - rpc FanToken(QueryFanTokenRequest) returns (QueryFanTokenResponse) { - option (google.api.http).get = "/bitsong/fantoken/v1beta1/denom/{denom}"; - } - - // FanTokens returns the fantoken list - rpc FanTokens(QueryFanTokensRequest) returns (QueryFanTokensResponse) { - option (google.api.http).get = "/bitsong/fantoken/v1beta1/fantokens"; - } - - // Params queries the fantoken parameters - rpc Params(QueryParamsRequest) returns (QueryParamsResponse) { - option (google.api.http).get = "/bitsong/fantoken/v1beta1/params"; - } -} - -// QueryFanTokenRequest is request type for the Query/FanToken RPC method -message QueryFanTokenRequest { string denom = 1; } - -// QueryFanTokenResponse is response type for the Query/FanToken RPC method -message QueryFanTokenResponse { bitsong.fantoken.v1beta1.FanToken fantoken = 1; } - -// QueryFanTokensRequest is request type for the Query/FanTokens RPC method -message QueryFanTokensRequest { - string authority = 1; - // pagination defines an optional pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} - -// QueryFanTokensResponse is response type for the Query/FanTokens RPC method -message QueryFanTokensResponse { - repeated bitsong.fantoken.v1beta1.FanToken fantokens = 1; - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryParametersRequest is request type for the Query/Parameters RPC method -message QueryParamsRequest {} - -// QueryParametersResponse is response type for the Query/Parameters RPC method -message QueryParamsResponse { - bitsong.fantoken.v1beta1.Params params = 1 [ (gogoproto.nullable) = false ]; -} \ No newline at end of file diff --git a/src/cosmospy_protobuf/bitsong/fantoken/v1beta1/tx.proto b/src/cosmospy_protobuf/bitsong/fantoken/v1beta1/tx.proto deleted file mode 100644 index 79c315c2..00000000 --- a/src/cosmospy_protobuf/bitsong/fantoken/v1beta1/tx.proto +++ /dev/null @@ -1,135 +0,0 @@ -syntax = "proto3"; -package bitsong.fantoken; - -import "cosmos/base/v1beta1/coin.proto"; -import "gogoproto/gogo.proto"; - -option go_package = "github.com/bitsongofficial/go-bitsong/x/fantoken/types"; -option (gogoproto.goproto_getters_all) = false; - -// Msg defines the oracle Msg service -service Msg { - // Issue defines a method for issuing a new fan token - rpc Issue(MsgIssue) returns (MsgIssueResponse); - - // Mint defines a method for minting some fan tokens - rpc Mint(MsgMint) returns (MsgMintResponse); - - // Burn defines a method for burning some fan tokens - rpc Burn(MsgBurn) returns (MsgBurnResponse); - - // DisableMint defines a method for disable the mint function - rpc DisableMint(MsgDisableMint) returns (MsgDisableMintResponse); - - rpc SetMinter(MsgSetMinter) returns (MsgSetMinterResponse); - rpc SetAuthority(MsgSetAuthority) returns (MsgSetAuthorityResponse); - rpc SetUri(MsgSetUri) returns (MsgSetUriResponse); -} - -// MsgIssue defines a message for issuing a new fan token -message MsgIssue { - - // symbol which corresponds to the symbol of the fan token. It is a string and cannot change for the whole life of the fan token - string symbol = 1; - - // name which corresponds to the name of the fan token. It is a string and cannot change for the whole life of the fan token - string name = 2; - - // max_supply that represents the maximum number of possible mintable tokens. It is an integer number, expressed in micro unit 10^6 - string max_supply = 3 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.moretags) = "yaml:\"max_supply\"", - (gogoproto.nullable) = false - ]; - - // authority which is who can set a new uri metadata - string authority = 4; - - // minter who is who can mint new fantoken and disable the minter process, the minter key also pay the gas fee - string minter = 5; - - // URI which is the current uri of the fan token. It is a string can change during the fan token lifecycle thanks to the MsgEdit - string uri = 6 [ (gogoproto.customname) = "URI" ]; -} - -// MsgIssueResponse defines the MsgIssue response type -message MsgIssueResponse {} - -// MsgDisableMint defines a message for disable the mint function -message MsgDisableMint { - string denom = 1; - string minter = 2; -} - -// MsgDisableMintResponse defines the MsgDisableMint response type -message MsgDisableMintResponse {} - -// MsgMint defines a message for minting a new fan token -message MsgMint { - string recipient = 1; - - // coin mean the amount + denom, eg: 10000ftFADJID34MCDM - cosmos.base.v1beta1.Coin coin = 2 [ - (gogoproto.moretags) = "yaml:\"coin\"", - (gogoproto.nullable) = false - ]; - - string minter = 3; -} - -// MsgMintResponse defines the MsgMint response type -message MsgMintResponse {} - -// MsgBurn defines a message for burning some fan tokens -message MsgBurn { - // coin mean the amount + denom, eg: 10000ftFADJID34MCDM - cosmos.base.v1beta1.Coin coin = 1 [ - (gogoproto.moretags) = "yaml:\"coin\"", - (gogoproto.nullable) = false - ]; - - string sender = 2; -} - -// MsgBurnResponse defines the MsgBurn response type -message MsgBurnResponse {} - -// MsgSetMinter defines a message for changing the fan token minter address -message MsgSetMinter { - - // denom the fan token denom - string denom = 1; - - // old_minter, the actual minter - string old_minter = 2 [ (gogoproto.moretags) = "yaml:\"old_minter\"" ]; - - // new_minter, the new fan token minter - string new_minter = 3 [ (gogoproto.moretags) = "yaml:\"new_minter\"" ]; -} - -// MsgSetMinterResponse defines the MsgTransferAuthority response type -message MsgSetMinterResponse {} - -// MsgSetAuthority defines a message for changing the fan token minter address -message MsgSetAuthority { - - // denom the fan token denom - string denom = 1; - - // old_authority, the actual metadata authority - string old_authority = 2 [ (gogoproto.moretags) = "yaml:\"old_authority\"" ]; - - // new_authority, the new fan token metadata authority - string new_authority = 3 [ (gogoproto.moretags) = "yaml:\"new_authority\"" ]; -} - -// MsgSetAuthorityResponse defines the MsgTransferAuthority response type -message MsgSetAuthorityResponse {} - -message MsgSetUri { - string authority = 1; - string denom = 2; - string uri = 3 [ (gogoproto.customname) = "URI" ]; -} - -message MsgSetUriResponse{} \ No newline at end of file diff --git a/src/cosmospy_protobuf/bitsong/merkledrop/v1beta1/events.proto b/src/cosmospy_protobuf/bitsong/merkledrop/v1beta1/events.proto deleted file mode 100644 index 5ac281a7..00000000 --- a/src/cosmospy_protobuf/bitsong/merkledrop/v1beta1/events.proto +++ /dev/null @@ -1,30 +0,0 @@ -syntax = "proto3"; -package bitsong.merkledrop.v1beta1; - -import "gogoproto/gogo.proto"; -import "cosmos/base/v1beta1/coin.proto"; - -option go_package = "github.com/bitsongofficial/go-bitsong/x/merkledrop/types"; -option (gogoproto.goproto_getters_all) = false; - -message EventCreate { - string owner = 1; - uint64 merkledrop_id = 2; -} - -message EventClaim { - uint64 merkledrop_id = 1; - uint64 index = 2; - cosmos.base.v1beta1.Coin coin = 3 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Coin", - (gogoproto.nullable) = false - ]; -} - -message EventWithdraw { - uint64 merkledrop_id = 1; - cosmos.base.v1beta1.Coin coin = 2 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Coin", - (gogoproto.nullable) = false - ]; -} \ No newline at end of file diff --git a/src/cosmospy_protobuf/bitsong/merkledrop/v1beta1/genesis.proto b/src/cosmospy_protobuf/bitsong/merkledrop/v1beta1/genesis.proto deleted file mode 100644 index e6e462bf..00000000 --- a/src/cosmospy_protobuf/bitsong/merkledrop/v1beta1/genesis.proto +++ /dev/null @@ -1,25 +0,0 @@ -syntax = "proto3"; -package bitsong.merkledrop.v1beta1; - -import "gogoproto/gogo.proto"; -import "cosmos/base/v1beta1/coin.proto"; -import "bitsong/merkledrop/v1beta1/merkledrop.proto"; -import "bitsong/merkledrop/v1beta1/params.proto"; - -option go_package = "github.com/bitsongofficial/go-bitsong/x/merkledrop/types"; -option (gogoproto.goproto_getters_all) = false; - -message Indexes { - uint64 merkledrop_id = 1 [ (gogoproto.moretags) = "yaml:\"mdi\"" ]; - repeated uint64 index = 2 [ (gogoproto.moretags) = "yaml:\"i\"" ]; -} - -message GenesisState { - uint64 last_merkledrop_id = 1; - - repeated bitsong.merkledrop.v1beta1.Merkledrop merkledrops = 2 [ (gogoproto.nullable) = false ]; - - repeated Indexes indexes = 3; - - Params params = 4 [ (gogoproto.nullable) = false ]; -} \ No newline at end of file diff --git a/src/cosmospy_protobuf/bitsong/merkledrop/v1beta1/gov.proto b/src/cosmospy_protobuf/bitsong/merkledrop/v1beta1/gov.proto deleted file mode 100644 index f955fc02..00000000 --- a/src/cosmospy_protobuf/bitsong/merkledrop/v1beta1/gov.proto +++ /dev/null @@ -1,30 +0,0 @@ -syntax = "proto3"; -package bitsong.merkledrop.v1beta1; - -import "cosmos/base/v1beta1/coin.proto"; -import "gogoproto/gogo.proto"; - -option go_package = "github.com/bitsongofficial/go-bitsong/x/merkledrop/types"; -option (gogoproto.goproto_getters_all) = false; - -message UpdateFeesProposal { - option (gogoproto.equal) = true; - option (gogoproto.goproto_stringer) = false; - - string title = 1; - string description = 2; - - cosmos.base.v1beta1.Coin creation_fee = 3 [ - (gogoproto.moretags) = "yaml:\"creation_fee\"", - (gogoproto.nullable) = false - ]; -} - -message UpdateFeesProposalWithDeposit { - option (gogoproto.goproto_stringer) = true; - - string title = 1; - string description = 2; - string creation_fee = 3; - string deposit = 7; -} \ No newline at end of file diff --git a/src/cosmospy_protobuf/bitsong/merkledrop/v1beta1/merkledrop.proto b/src/cosmospy_protobuf/bitsong/merkledrop/v1beta1/merkledrop.proto deleted file mode 100644 index 60c1c13c..00000000 --- a/src/cosmospy_protobuf/bitsong/merkledrop/v1beta1/merkledrop.proto +++ /dev/null @@ -1,44 +0,0 @@ -syntax = "proto3"; -package bitsong.merkledrop.v1beta1; - -import "gogoproto/gogo.proto"; -import "google/protobuf/timestamp.proto"; -import "cosmos/base/v1beta1/coin.proto"; - -option go_package = "github.com/bitsongofficial/go-bitsong/x/merkledrop/types"; -option (gogoproto.goproto_getters_all) = false; - -message Merkledrop { - option (gogoproto.goproto_stringer) = false; - option (gogoproto.goproto_getters) = false; - - // merkledrop id - uint64 id = 1; - - // merkle_root of the merkledrop - string merkle_root = 2 [ (gogoproto.moretags) = "yaml:\"merkle_root\"" ]; - - // merkledrop start height - int64 start_height = 3; - - // merkledrop end height - int64 end_height = 4; - - // denom to distribuite - string denom = 5; - - // amount to distribuite - string amount = 6 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.nullable) = false - ]; - - // claimed amount - string claimed = 7 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.nullable) = false - ]; - - // merkledrop's owner - string owner = 8; -} \ No newline at end of file diff --git a/src/cosmospy_protobuf/bitsong/merkledrop/v1beta1/params.proto b/src/cosmospy_protobuf/bitsong/merkledrop/v1beta1/params.proto deleted file mode 100644 index d58e8c36..00000000 --- a/src/cosmospy_protobuf/bitsong/merkledrop/v1beta1/params.proto +++ /dev/null @@ -1,20 +0,0 @@ -syntax = "proto3"; -package bitsong.merkledrop.v1beta1; - -import "gogoproto/gogo.proto"; -import "cosmos/base/v1beta1/coin.proto"; - -option go_package = "github.com/bitsongofficial/go-bitsong/x/merkledrop/types"; -option (gogoproto.goproto_getters_all) = false; - -// Params defines merkledrop module's parameters -message Params { - option (gogoproto.equal) = true; - option (gogoproto.goproto_stringer) = false; - - cosmos.base.v1beta1.Coin creation_fee = 1 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Coin", - (gogoproto.moretags) = "yaml:\"creation_fee\"", - (gogoproto.nullable) = false - ]; -} \ No newline at end of file diff --git a/src/cosmospy_protobuf/bitsong/merkledrop/v1beta1/query.proto b/src/cosmospy_protobuf/bitsong/merkledrop/v1beta1/query.proto deleted file mode 100644 index 189c22ca..00000000 --- a/src/cosmospy_protobuf/bitsong/merkledrop/v1beta1/query.proto +++ /dev/null @@ -1,51 +0,0 @@ -syntax = "proto3"; -package bitsong.merkledrop.v1beta1; - -import "gogoproto/gogo.proto"; -import "google/api/annotations.proto"; -import "cosmos/base/v1beta1/coin.proto"; -import "bitsong/merkledrop/v1beta1/merkledrop.proto"; -import "bitsong/merkledrop/v1beta1/params.proto"; - -option go_package = "github.com/bitsongofficial/go-bitsong/x/merkledrop/types"; -option (gogoproto.goproto_getters_all) = false; - -service Query { - rpc Merkledrop(QueryMerkledropRequest) returns (QueryMerkledropResponse) { - option (google.api.http).get = "/bitsong/merkledrop/v1beta1/markledrops/{id}"; - } - - rpc IndexClaimed(QueryIndexClaimedRequest) returns (QueryIndexClaimedResponse) { - option (google.api.http).get = "/bitsong/merkledrop/v1beta1/markledrops/{id}/index_claimed/{index}"; - } - - // Params queries the fantoken parameters - rpc Params(QueryParamsRequest) returns (QueryParamsResponse) { - option (google.api.http).get = "/bitsong/merkledrop/v1beta1/params"; - } -} - -message QueryMerkledropRequest { uint64 id = 1; } - -message QueryMerkledropResponse { - bitsong.merkledrop.v1beta1.Merkledrop merkledrop = 1 [ (gogoproto.nullable) = false ]; -} - -message QueryIndexClaimedRequest { - uint64 id = 1; - uint64 index = 2; -} - -message QueryIndexClaimedResponse { - bool is_claimed = 1 [ - (gogoproto.moretags) = "yaml:\"is_claimed\"" - ]; -} - -// QueryParametersRequest is request type for the Query/Parameters RPC method -message QueryParamsRequest {} - -// QueryParametersResponse is response type for the Query/Parameters RPC method -message QueryParamsResponse { - bitsong.merkledrop.v1beta1.Params params = 1 [ (gogoproto.nullable) = false ]; -} \ No newline at end of file diff --git a/src/cosmospy_protobuf/bitsong/merkledrop/v1beta1/tx.proto b/src/cosmospy_protobuf/bitsong/merkledrop/v1beta1/tx.proto deleted file mode 100644 index e4b052b2..00000000 --- a/src/cosmospy_protobuf/bitsong/merkledrop/v1beta1/tx.proto +++ /dev/null @@ -1,60 +0,0 @@ -syntax = "proto3"; -package bitsong.merkledrop.v1beta1; - -import "gogoproto/gogo.proto"; -import "google/protobuf/timestamp.proto"; -import "cosmos/base/v1beta1/coin.proto"; - -option go_package = "github.com/bitsongofficial/go-bitsong/x/merkledrop/types"; -option (gogoproto.goproto_getters_all) = false; - -service Msg { - rpc Create(MsgCreate) returns (MsgCreateResponse); - - rpc Claim(MsgClaim) returns (MsgClaimResponse); -} - -message MsgCreate { - // owner of the merkledrop - string owner = 1; - - // merkle_root used to compute proofs - string merkle_root = 2 [ (gogoproto.moretags) = "yaml:\"merkle_root\"" ]; - - // merkledrop start height - int64 start_height = 3; - - // merkledrop end height - int64 end_height = 4; - - // coins to distribute - cosmos.base.v1beta1.Coin coin = 5 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Coin", - (gogoproto.nullable) = false - ]; -} - -message MsgCreateResponse { - string owner = 1; - uint64 id = 2; -} - -message MsgClaim { - string sender = 1; - uint64 merkledrop_id = 2; - uint64 index = 3; - string amount = 4 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.nullable) = false - ]; - repeated string proofs = 5; -} - -message MsgClaimResponse { - uint64 id = 1; - uint64 index = 2; - string amount = 3 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.nullable) = false - ]; -} \ No newline at end of file diff --git a/src/cosmospy_protobuf/cosmos/app/module/v1alpha1/module.proto b/src/cosmospy_protobuf/cosmos/app/module/v1alpha1/module.proto deleted file mode 100644 index 487e195c..00000000 --- a/src/cosmospy_protobuf/cosmos/app/module/v1alpha1/module.proto +++ /dev/null @@ -1,13 +0,0 @@ -syntax = "proto3"; - -package cosmos.app.module.v1alpha1; - -import "cosmos/app/v1alpha1/module.proto"; - -// Module is the module config object for the cosmos.app v1 app module. -message Module { - option (cosmos.app.v1alpha1.module) = { - go_import: "github.com/cosmos/cosmos-sdk/app" - use_package: {name: "cosmos.app.v1alpha1"} - }; -} diff --git a/src/cosmospy_protobuf/cosmos/app/v1alpha1/config.proto b/src/cosmospy_protobuf/cosmos/app/v1alpha1/config.proto deleted file mode 100644 index ed775006..00000000 --- a/src/cosmospy_protobuf/cosmos/app/v1alpha1/config.proto +++ /dev/null @@ -1,36 +0,0 @@ -syntax = "proto3"; - -package cosmos.app.v1alpha1; - -import "google/protobuf/any.proto"; - -// 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. -message Config { - // modules are the module configurations for the app. - repeated ModuleConfig modules = 1; -} - -// ModuleConfig is a module configuration for an app. -message ModuleConfig { - // 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. - string name = 1; - - // config is the config object for the module. Module config messages should - // define a ModuleDescriptor using the cosmos.app.v1alpha1.is_module extension. - google.protobuf.Any config = 2; -} diff --git a/src/cosmospy_protobuf/cosmos/app/v1alpha1/module.proto b/src/cosmospy_protobuf/cosmos/app/v1alpha1/module.proto deleted file mode 100644 index 46c31e4d..00000000 --- a/src/cosmospy_protobuf/cosmos/app/v1alpha1/module.proto +++ /dev/null @@ -1,93 +0,0 @@ -syntax = "proto3"; - -package cosmos.app.v1alpha1; - -import "google/protobuf/descriptor.proto"; - -extend google.protobuf.MessageOptions { - // module indicates that this proto type is a config object for an app module - // and optionally provides other descriptive information about the module. - // It is recommended that a new module config object and go module is versioned - // for every state machine breaking version of a module. The recommended - // pattern for doing this is to put module config objects in a separate proto - // package from the API they expose. Ex: the cosmos.group.v1 API would be - // exposed by module configs cosmos.group.module.v1, cosmos.group.module.v2, etc. - ModuleDescriptor module = 57193479; -} - -// ModuleDescriptor describes an app module. -message ModuleDescriptor { - // go_import names the package that should be imported by an app to load the - // module in the runtime module registry. Either go_import must be defined here - // or the go_package option must be defined at the file level to indicate - // to users where to location the module implementation. go_import takes - // precedence over go_package when both are defined. - string go_import = 1; - - // use_package refers to a protobuf package that this module - // uses and exposes to the world. In an app, only one module should "use" - // or own a single protobuf package. It is assumed that the module uses - // all of the .proto files in a single package. - repeated PackageReference use_package = 2; - - // can_migrate_from defines which module versions this module can migrate - // state from. The framework will check that one module version is able to - // migrate from a previous module version before attempting to update its - // config. It is assumed that modules can transitively migrate from earlier - // versions. For instance if v3 declares it can migrate from v2, and v2 - // declares it can migrate from v1, the framework knows how to migrate - // from v1 to v3, assuming all 3 module versions are registered at runtime. - repeated MigrateFromInfo can_migrate_from = 3; -} - -// PackageReference is a reference to a protobuf package used by a module. -message PackageReference { - // name is the fully-qualified name of the package. - string name = 1; - - // revision is the optional revision of the package that is being used. - // Protobuf packages used in Cosmos should generally have a major version - // as the last part of the package name, ex. foo.bar.baz.v1. - // The revision of a package can be thought of as the minor version of a - // package which has additional backwards compatible definitions that weren't - // present in a previous version. - // - // A package should indicate its revision with a source code comment - // above the package declaration in one of its files containing the - // text "Revision N" where N is an integer revision. All packages start - // at revision 0 the first time they are released in a module. - // - // When a new version of a module is released and items are added to existing - // .proto files, these definitions should contain comments of the form - // "Since Revision N" where N is an integer revision. - // - // When the module runtime starts up, it will check the pinned proto - // image and panic if there are runtime protobuf definitions that are not - // in the pinned descriptor which do not have - // a "Since Revision N" comment or have a "Since Revision N" comment where - // N is <= to the revision specified here. This indicates that the protobuf - // files have been updated, but the pinned file descriptor hasn't. - // - // If there are items in the pinned file descriptor with a revision - // greater than the value indicated here, this will also cause a panic - // as it may mean that the pinned descriptor for a legacy module has been - // improperly updated or that there is some other versioning discrepancy. - // Runtime protobuf definitions will also be checked for compatibility - // with pinned file descriptors to make sure there are no incompatible changes. - // - // This behavior ensures that: - // * pinned proto images are up-to-date - // * protobuf files are carefully annotated with revision comments which - // are important good client UX - // * protobuf files are changed in backwards and forwards compatible ways - uint32 revision = 2; -} - -// MigrateFromInfo is information on a module version that a newer module -// can migrate from. -message MigrateFromInfo { - - // module is the fully-qualified protobuf name of the module config object - // for the previous module version, ex: "cosmos.group.module.v1.Module". - string module = 1; -} diff --git a/src/cosmospy_protobuf/cosmos/app/v1alpha1/query.proto b/src/cosmospy_protobuf/cosmos/app/v1alpha1/query.proto deleted file mode 100644 index efec9c81..00000000 --- a/src/cosmospy_protobuf/cosmos/app/v1alpha1/query.proto +++ /dev/null @@ -1,22 +0,0 @@ -syntax = "proto3"; - -package cosmos.app.v1alpha1; - -import "cosmos/app/v1alpha1/config.proto"; - -// Query is the app module query service. -service Query { - - // Config returns the current app config. - rpc Config(QueryConfigRequest) returns (QueryConfigResponse) {} -} - -// QueryConfigRequest is the Query/Config request type. -message QueryConfigRequest {} - -// QueryConfigRequest is the Query/Config response type. -message QueryConfigResponse { - - // config is the current app config. - Config config = 1; -} diff --git a/src/cosmospy_protobuf/cosmos/auth/v1beta1/auth.proto b/src/cosmospy_protobuf/cosmos/auth/v1beta1/auth.proto deleted file mode 100644 index 963c6f15..00000000 --- a/src/cosmospy_protobuf/cosmos/auth/v1beta1/auth.proto +++ /dev/null @@ -1,47 +0,0 @@ -syntax = "proto3"; -package cosmos.auth.v1beta1; - -import "cosmos_proto/cosmos.proto"; -import "gogoproto/gogo.proto"; -import "google/protobuf/any.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/auth/types"; - -// 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). -message BaseAccount { - option (gogoproto.goproto_getters) = false; - option (gogoproto.goproto_stringer) = false; - option (gogoproto.equal) = false; - - option (cosmos_proto.implements_interface) = "AccountI"; - - string address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - google.protobuf.Any pub_key = 2 [(gogoproto.jsontag) = "public_key,omitempty"]; - uint64 account_number = 3; - uint64 sequence = 4; -} - -// ModuleAccount defines an account for modules that holds coins on a pool. -message ModuleAccount { - option (gogoproto.goproto_getters) = false; - option (gogoproto.goproto_stringer) = false; - option (cosmos_proto.implements_interface) = "ModuleAccountI"; - - BaseAccount base_account = 1 [(gogoproto.embed) = true]; - string name = 2; - repeated string permissions = 3; -} - -// Params defines the parameters for the auth module. -message Params { - option (gogoproto.equal) = true; - option (gogoproto.goproto_stringer) = false; - - uint64 max_memo_characters = 1; - uint64 tx_sig_limit = 2; - uint64 tx_size_cost_per_byte = 3; - uint64 sig_verify_cost_ed25519 = 4 [(gogoproto.customname) = "SigVerifyCostED25519"]; - uint64 sig_verify_cost_secp256k1 = 5 [(gogoproto.customname) = "SigVerifyCostSecp256k1"]; -} diff --git a/src/cosmospy_protobuf/cosmos/auth/v1beta1/genesis.proto b/src/cosmospy_protobuf/cosmos/auth/v1beta1/genesis.proto deleted file mode 100644 index c88b94ee..00000000 --- a/src/cosmospy_protobuf/cosmos/auth/v1beta1/genesis.proto +++ /dev/null @@ -1,17 +0,0 @@ -syntax = "proto3"; -package cosmos.auth.v1beta1; - -import "google/protobuf/any.proto"; -import "gogoproto/gogo.proto"; -import "cosmos/auth/v1beta1/auth.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/auth/types"; - -// GenesisState defines the auth module's genesis state. -message GenesisState { - // params defines all the paramaters of the module. - Params params = 1 [(gogoproto.nullable) = false]; - - // accounts are the accounts present at genesis. - repeated google.protobuf.Any accounts = 2; -} diff --git a/src/cosmospy_protobuf/cosmos/auth/v1beta1/query.proto b/src/cosmospy_protobuf/cosmos/auth/v1beta1/query.proto deleted file mode 100644 index 7798da00..00000000 --- a/src/cosmospy_protobuf/cosmos/auth/v1beta1/query.proto +++ /dev/null @@ -1,130 +0,0 @@ -syntax = "proto3"; -package cosmos.auth.v1beta1; - -import "cosmos/base/query/v1beta1/pagination.proto"; -import "gogoproto/gogo.proto"; -import "google/protobuf/any.proto"; -import "google/api/annotations.proto"; -import "cosmos/auth/v1beta1/auth.proto"; -import "cosmos_proto/cosmos.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/auth/types"; - -// Query defines the gRPC querier service. -service Query { - // Accounts returns all the existing accounts - // - // Since: cosmos-sdk 0.43 - rpc Accounts(QueryAccountsRequest) returns (QueryAccountsResponse) { - option (google.api.http).get = "/cosmos/auth/v1beta1/accounts"; - } - - // Account returns account details based on address. - rpc Account(QueryAccountRequest) returns (QueryAccountResponse) { - option (google.api.http).get = "/cosmos/auth/v1beta1/accounts/{address}"; - } - - // Params queries all parameters. - rpc Params(QueryParamsRequest) returns (QueryParamsResponse) { - option (google.api.http).get = "/cosmos/auth/v1beta1/params"; - } - - // ModuleAccounts returns all the existing module accounts. - rpc ModuleAccounts(QueryModuleAccountsRequest) returns (QueryModuleAccountsResponse) { - option (google.api.http).get = "/cosmos/auth/v1beta1/module_accounts"; - } - - // Bech32 queries bech32Prefix - rpc Bech32Prefix(Bech32PrefixRequest) returns (Bech32PrefixResponse) { - option (google.api.http).get = "/cosmos/auth/v1beta1/bech32"; - } - - // AddressBytesToString converts Account Address bytes to string - rpc AddressBytesToString(AddressBytesToStringRequest) returns (AddressBytesToStringResponse) { - option (google.api.http).get = "/cosmos/auth/v1beta1/bech32/{address_bytes}"; - } - - // AddressStringToBytes converts Address string to bytes - rpc AddressStringToBytes(AddressStringToBytesRequest) returns (AddressStringToBytesResponse) { - option (google.api.http).get = "/cosmos/auth/v1beta1/bech32/{address_string}"; - } -} - -// QueryAccountsRequest is the request type for the Query/Accounts RPC method. -// -// Since: cosmos-sdk 0.43 -message QueryAccountsRequest { - // pagination defines an optional pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 1; -} - -// QueryAccountsResponse is the response type for the Query/Accounts RPC method. -// -// Since: cosmos-sdk 0.43 -message QueryAccountsResponse { - // accounts are the existing accounts - repeated google.protobuf.Any accounts = 1 [(cosmos_proto.accepts_interface) = "AccountI"]; - - // pagination defines the pagination in the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryAccountRequest is the request type for the Query/Account RPC method. -message QueryAccountRequest { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // address defines the address to query for. - string address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// QueryModuleAccountsRequest is the request type for the Query/ModuleAccounts RPC method. -message QueryModuleAccountsRequest {} - -// 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]; -} - -// QueryAccountResponse is the response type for the Query/Account RPC method. -message QueryAccountResponse { - // account defines the account of the corresponding address. - google.protobuf.Any account = 1 [(cosmos_proto.accepts_interface) = "AccountI"]; -} - -// QueryParamsRequest is the request type for the Query/Params RPC method. -message QueryParamsRequest {} - -// QueryModuleAccountsResponse is the response type for the Query/ModuleAccounts RPC method. -message QueryModuleAccountsResponse { - repeated google.protobuf.Any accounts = 1 [(cosmos_proto.accepts_interface) = "ModuleAccountI"]; -} - -// Bech32PrefixRequest is the request type for Bech32Prefix rpc method -message Bech32PrefixRequest {} - -// Bech32PrefixResponse is the response type for Bech32Prefix rpc method -message Bech32PrefixResponse { - string bech32_prefix = 1; -} - -// AddressBytesToStringRequest is the request type for AddressString rpc method -message AddressBytesToStringRequest { - bytes address_bytes = 1; -} - -// AddressBytesToStringResponse is the response type for AddressString rpc method -message AddressBytesToStringResponse { - string address_string = 1; -} - -// AddressStringToBytesRequest is the request type for AccountBytes rpc method -message AddressStringToBytesRequest { - string address_string = 1; -} - -// AddressStringToBytesResponse is the response type for AddressBytes rpc method -message AddressStringToBytesResponse { - bytes address_bytes = 1; -} diff --git a/src/cosmospy_protobuf/cosmos/authz/v1beta1/authz.proto b/src/cosmospy_protobuf/cosmos/authz/v1beta1/authz.proto deleted file mode 100644 index 06ce288a..00000000 --- a/src/cosmospy_protobuf/cosmos/authz/v1beta1/authz.proto +++ /dev/null @@ -1,46 +0,0 @@ -// Since: cosmos-sdk 0.43 -syntax = "proto3"; -package cosmos.authz.v1beta1; - -import "cosmos_proto/cosmos.proto"; -import "google/protobuf/timestamp.proto"; -import "gogoproto/gogo.proto"; -import "google/protobuf/any.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/authz"; -option (gogoproto.goproto_getters_all) = false; - -// GenericAuthorization gives the grantee unrestricted permissions to execute -// the provided method on behalf of the granter's account. -message GenericAuthorization { - option (cosmos_proto.implements_interface) = "Authorization"; - - // Msg, identified by it's type URL, to grant unrestricted permissions to execute - string msg = 1; -} - -// Grant gives permissions to execute -// the provide method with expiration time. -message Grant { - google.protobuf.Any authorization = 1 [(cosmos_proto.accepts_interface) = "Authorization"]; - // 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) - google.protobuf.Timestamp expiration = 2 [(gogoproto.stdtime) = true, (gogoproto.nullable) = true]; -} - -// GrantAuthorization extends a grant with both the addresses of the grantee and granter. -// It is used in genesis.proto and query.proto -message GrantAuthorization { - string granter = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - string grantee = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - google.protobuf.Any authorization = 3 [(cosmos_proto.accepts_interface) = "Authorization"]; - google.protobuf.Timestamp expiration = 4 [(gogoproto.stdtime) = true]; -} - -// GrantQueueItem contains the list of TypeURL of a sdk.Msg. -message GrantQueueItem { - // msg_type_urls contains the list of TypeURL of a sdk.Msg. - repeated string msg_type_urls = 1; -} diff --git a/src/cosmospy_protobuf/cosmos/authz/v1beta1/event.proto b/src/cosmospy_protobuf/cosmos/authz/v1beta1/event.proto deleted file mode 100644 index 0476649a..00000000 --- a/src/cosmospy_protobuf/cosmos/authz/v1beta1/event.proto +++ /dev/null @@ -1,27 +0,0 @@ -// Since: cosmos-sdk 0.43 -syntax = "proto3"; -package cosmos.authz.v1beta1; - -import "cosmos_proto/cosmos.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/authz"; - -// EventGrant is emitted on Msg/Grant -message EventGrant { - // Msg type URL for which an autorization is granted - string msg_type_url = 2; - // Granter account address - string granter = 3 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - // Grantee account address - string grantee = 4 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// EventRevoke is emitted on Msg/Revoke -message EventRevoke { - // Msg type URL for which an autorization is revoked - string msg_type_url = 2; - // Granter account address - string granter = 3 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - // Grantee account address - string grantee = 4 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} diff --git a/src/cosmospy_protobuf/cosmos/authz/v1beta1/genesis.proto b/src/cosmospy_protobuf/cosmos/authz/v1beta1/genesis.proto deleted file mode 100644 index 310f6265..00000000 --- a/src/cosmospy_protobuf/cosmos/authz/v1beta1/genesis.proto +++ /dev/null @@ -1,13 +0,0 @@ -// Since: cosmos-sdk 0.43 -syntax = "proto3"; -package cosmos.authz.v1beta1; - -import "gogoproto/gogo.proto"; -import "cosmos/authz/v1beta1/authz.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/authz"; - -// GenesisState defines the authz module's genesis state. -message GenesisState { - repeated GrantAuthorization authorization = 1 [(gogoproto.nullable) = false]; -} diff --git a/src/cosmospy_protobuf/cosmos/authz/v1beta1/query.proto b/src/cosmospy_protobuf/cosmos/authz/v1beta1/query.proto deleted file mode 100644 index 62154ac1..00000000 --- a/src/cosmospy_protobuf/cosmos/authz/v1beta1/query.proto +++ /dev/null @@ -1,82 +0,0 @@ -// Since: cosmos-sdk 0.43 -syntax = "proto3"; -package cosmos.authz.v1beta1; - -import "google/api/annotations.proto"; -import "cosmos/base/query/v1beta1/pagination.proto"; -import "cosmos/authz/v1beta1/authz.proto"; -import "cosmos_proto/cosmos.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/authz"; - -// Query defines the gRPC querier service. -service Query { - // Returns list of `Authorization`, granted to the grantee by the granter. - rpc Grants(QueryGrantsRequest) returns (QueryGrantsResponse) { - option (google.api.http).get = "/cosmos/authz/v1beta1/grants"; - } - - // GranterGrants returns list of `GrantAuthorization`, granted by granter. - // - // Since: cosmos-sdk 0.46 - rpc GranterGrants(QueryGranterGrantsRequest) returns (QueryGranterGrantsResponse) { - option (google.api.http).get = "/cosmos/authz/v1beta1/grants/granter/{granter}"; - } - - // GranteeGrants returns a list of `GrantAuthorization` by grantee. - // - // Since: cosmos-sdk 0.46 - rpc GranteeGrants(QueryGranteeGrantsRequest) returns (QueryGranteeGrantsResponse) { - option (google.api.http).get = "/cosmos/authz/v1beta1/grants/grantee/{grantee}"; - } -} - -// QueryGrantsRequest is the request type for the Query/Grants RPC method. -message QueryGrantsRequest { - string granter = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - string grantee = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - // Optional, msg_type_url, when set, will query only grants matching given msg type. - string msg_type_url = 3; - // pagination defines an pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 4; -} - -// QueryGrantsResponse is the response type for the Query/Authorizations RPC method. -message QueryGrantsResponse { - // authorizations is a list of grants granted for grantee by granter. - repeated Grant grants = 1; - // pagination defines an pagination for the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryGranterGrantsRequest is the request type for the Query/GranterGrants RPC method. -message QueryGranterGrantsRequest { - string granter = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // pagination defines an pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} - -// QueryGranterGrantsResponse is the response type for the Query/GranterGrants RPC method. -message QueryGranterGrantsResponse { - // grants is a list of grants granted by the granter. - repeated GrantAuthorization grants = 1; - // pagination defines an pagination for the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryGranteeGrantsRequest is the request type for the Query/IssuedGrants RPC method. -message QueryGranteeGrantsRequest { - string grantee = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // pagination defines an pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} - -// QueryGranteeGrantsResponse is the response type for the Query/GranteeGrants RPC method. -message QueryGranteeGrantsResponse { - // grants is a list of grants granted to the grantee. - repeated GrantAuthorization grants = 1; - // pagination defines an pagination for the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} diff --git a/src/cosmospy_protobuf/cosmos/authz/v1beta1/tx.proto b/src/cosmospy_protobuf/cosmos/authz/v1beta1/tx.proto deleted file mode 100644 index 068218ff..00000000 --- a/src/cosmospy_protobuf/cosmos/authz/v1beta1/tx.proto +++ /dev/null @@ -1,75 +0,0 @@ -// Since: cosmos-sdk 0.43 -syntax = "proto3"; -package cosmos.authz.v1beta1; - -import "cosmos_proto/cosmos.proto"; -import "gogoproto/gogo.proto"; -import "google/protobuf/any.proto"; -import "cosmos/authz/v1beta1/authz.proto"; -import "cosmos/msg/v1/msg.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/authz"; -option (gogoproto.goproto_getters_all) = false; - -// Msg defines the authz Msg service. -service Msg { - // Grant grants the provided authorization to the grantee on the granter's - // account with the provided expiration time. If there is already a grant - // for the given (granter, grantee, Authorization) triple, then the grant - // will be overwritten. - rpc Grant(MsgGrant) returns (MsgGrantResponse); - - // Exec attempts to execute the provided messages using - // authorizations granted to the grantee. Each message should have only - // one signer corresponding to the granter of the authorization. - rpc Exec(MsgExec) returns (MsgExecResponse); - - // Revoke revokes any authorization corresponding to the provided method name on the - // granter's account that has been granted to the grantee. - rpc Revoke(MsgRevoke) returns (MsgRevokeResponse); -} - -// MsgGrant is a request type for Grant method. It declares authorization to the grantee -// on behalf of the granter with the provided expiration time. -message MsgGrant { - option (cosmos.msg.v1.signer) = "granter"; - - string granter = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - string grantee = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - cosmos.authz.v1beta1.Grant grant = 3 [(gogoproto.nullable) = false]; -} - -// MsgExecResponse defines the Msg/MsgExecResponse response type. -message MsgExecResponse { - repeated bytes results = 1; -} - -// MsgExec attempts to execute the provided messages using -// authorizations granted to the grantee. Each message should have only -// one signer corresponding to the granter of the authorization. -message MsgExec { - option (cosmos.msg.v1.signer) = "grantee"; - - string grantee = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - // Authorization Msg requests to execute. Each msg must implement Authorization interface - // The x/authz will try to find a grant matching (msg.signers[0], grantee, MsgTypeURL(msg)) - // triple and validate it. - repeated google.protobuf.Any msgs = 2 [(cosmos_proto.accepts_interface) = "sdk.Msg, authz.Authorization"]; -} - -// MsgGrantResponse defines the Msg/MsgGrant response type. -message MsgGrantResponse {} - -// MsgRevoke revokes any authorization with the provided sdk.Msg type on the -// granter's account with that has been granted to the grantee. -message MsgRevoke { - option (cosmos.msg.v1.signer) = "granter"; - - string granter = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - string grantee = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - string msg_type_url = 3; -} - -// MsgRevokeResponse defines the Msg/MsgRevokeResponse response type. -message MsgRevokeResponse {} diff --git a/src/cosmospy_protobuf/cosmos/bank/v1beta1/authz.proto b/src/cosmospy_protobuf/cosmos/bank/v1beta1/authz.proto deleted file mode 100644 index 4f58b15e..00000000 --- a/src/cosmospy_protobuf/cosmos/bank/v1beta1/authz.proto +++ /dev/null @@ -1,19 +0,0 @@ -syntax = "proto3"; -package cosmos.bank.v1beta1; - -import "gogoproto/gogo.proto"; -import "cosmos_proto/cosmos.proto"; -import "cosmos/base/v1beta1/coin.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/bank/types"; - -// SendAuthorization allows the grantee to spend up to spend_limit coins from -// the granter's account. -// -// Since: cosmos-sdk 0.43 -message SendAuthorization { - option (cosmos_proto.implements_interface) = "Authorization"; - - repeated cosmos.base.v1beta1.Coin spend_limit = 1 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; -} diff --git a/src/cosmospy_protobuf/cosmos/bank/v1beta1/bank.proto b/src/cosmospy_protobuf/cosmos/bank/v1beta1/bank.proto deleted file mode 100644 index 7bc9819d..00000000 --- a/src/cosmospy_protobuf/cosmos/bank/v1beta1/bank.proto +++ /dev/null @@ -1,108 +0,0 @@ -syntax = "proto3"; -package cosmos.bank.v1beta1; - -import "gogoproto/gogo.proto"; -import "cosmos_proto/cosmos.proto"; -import "cosmos/base/v1beta1/coin.proto"; -import "cosmos/msg/v1/msg.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/bank/types"; - -// Params defines the parameters for the bank module. -message Params { - option (gogoproto.goproto_stringer) = false; - repeated SendEnabled send_enabled = 1; - bool default_send_enabled = 2; -} - -// SendEnabled maps coin denom to a send_enabled status (whether a denom is -// sendable). -message SendEnabled { - option (gogoproto.equal) = true; - option (gogoproto.goproto_stringer) = false; - string denom = 1; - bool enabled = 2; -} - -// Input models transaction input. -message Input { - option (cosmos.msg.v1.signer) = "address"; - - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - string address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - repeated cosmos.base.v1beta1.Coin coins = 2 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; -} - -// Output models transaction outputs. -message Output { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - string address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - repeated cosmos.base.v1beta1.Coin coins = 2 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; -} - -// Supply represents a struct that passively keeps track of the total supply -// amounts in the network. -// This message is deprecated now that supply is indexed by denom. -message Supply { - option deprecated = true; - - option (gogoproto.equal) = true; - option (gogoproto.goproto_getters) = false; - - option (cosmos_proto.implements_interface) = "*github.com/cosmos/cosmos-sdk/x/bank/migrations/v040.SupplyI"; - - repeated cosmos.base.v1beta1.Coin total = 1 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; -} - -// DenomUnit represents a struct that describes a given -// denomination unit of the basic token. -message DenomUnit { - // denom represents the string name of the given denom unit (e.g uatom). - string denom = 1; - // 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). - uint32 exponent = 2; - // aliases is a list of string aliases for the given denom - repeated string aliases = 3; -} - -// Metadata represents a struct that describes -// a basic token. -message Metadata { - string description = 1; - // denom_units represents the list of DenomUnit's for a given coin - repeated DenomUnit denom_units = 2; - // base represents the base denom (should be the DenomUnit with exponent = 0). - string base = 3; - // display indicates the suggested denom that should be - // displayed in clients. - string display = 4; - // name defines the name of the token (eg: Cosmos Atom) - // - // Since: cosmos-sdk 0.43 - string name = 5; - // symbol is the token symbol usually shown on exchanges (eg: ATOM). This can - // be the same as the display. - // - // Since: cosmos-sdk 0.43 - string symbol = 6; - // URI to a document (on or off-chain) that contains additional information. Optional. - // - // Since: cosmos-sdk 0.46 - string uri = 7 [(gogoproto.customname) = "URI"]; - // 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 - string uri_hash = 8 [(gogoproto.customname) = "URIHash"]; -} diff --git a/src/cosmospy_protobuf/cosmos/bank/v1beta1/genesis.proto b/src/cosmospy_protobuf/cosmos/bank/v1beta1/genesis.proto deleted file mode 100644 index aa35790b..00000000 --- a/src/cosmospy_protobuf/cosmos/bank/v1beta1/genesis.proto +++ /dev/null @@ -1,40 +0,0 @@ -syntax = "proto3"; -package cosmos.bank.v1beta1; - -import "gogoproto/gogo.proto"; -import "cosmos/base/v1beta1/coin.proto"; -import "cosmos/bank/v1beta1/bank.proto"; -import "cosmos_proto/cosmos.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/bank/types"; - -// GenesisState defines the bank module's genesis state. -message GenesisState { - // params defines all the paramaters of the module. - Params params = 1 [(gogoproto.nullable) = false]; - - // balances is an array containing the balances of all the accounts. - repeated Balance balances = 2 [(gogoproto.nullable) = false]; - - // supply represents the total supply. If it is left empty, then supply will be calculated based on the provided - // balances. Otherwise, it will be used to validate that the sum of the balances equals this amount. - repeated cosmos.base.v1beta1.Coin supply = 3 - [(gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins", (gogoproto.nullable) = false]; - - // denom_metadata defines the metadata of the differents coins. - repeated Metadata denom_metadata = 4 [(gogoproto.nullable) = false]; -} - -// Balance defines an account address and balance pair used in the bank module's -// genesis state. -message Balance { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // address is the address of the balance holder. - string address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // coins defines the different coins this balance holds. - repeated cosmos.base.v1beta1.Coin coins = 2 - [(gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins", (gogoproto.nullable) = false]; -} diff --git a/src/cosmospy_protobuf/cosmos/bank/v1beta1/query.proto b/src/cosmospy_protobuf/cosmos/bank/v1beta1/query.proto deleted file mode 100644 index cbe7f38a..00000000 --- a/src/cosmospy_protobuf/cosmos/bank/v1beta1/query.proto +++ /dev/null @@ -1,231 +0,0 @@ -syntax = "proto3"; -package cosmos.bank.v1beta1; - -import "cosmos/base/query/v1beta1/pagination.proto"; -import "gogoproto/gogo.proto"; -import "google/api/annotations.proto"; -import "cosmos/base/v1beta1/coin.proto"; -import "cosmos/bank/v1beta1/bank.proto"; -import "cosmos_proto/cosmos.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/bank/types"; - -// Query defines the gRPC querier service. -service Query { - // Balance queries the balance of a single coin for a single account. - rpc Balance(QueryBalanceRequest) returns (QueryBalanceResponse) { - option (google.api.http).get = "/cosmos/bank/v1beta1/balances/{address}/by_denom"; - } - - // AllBalances queries the balance of all coins for a single account. - rpc AllBalances(QueryAllBalancesRequest) returns (QueryAllBalancesResponse) { - option (google.api.http).get = "/cosmos/bank/v1beta1/balances/{address}"; - } - - // SpendableBalances queries the spenable balance of all coins for a single - // account. - rpc SpendableBalances(QuerySpendableBalancesRequest) returns (QuerySpendableBalancesResponse) { - option (google.api.http).get = "/cosmos/bank/v1beta1/spendable_balances/{address}"; - } - - // TotalSupply queries the total supply of all coins. - rpc TotalSupply(QueryTotalSupplyRequest) returns (QueryTotalSupplyResponse) { - option (google.api.http).get = "/cosmos/bank/v1beta1/supply"; - } - - // SupplyOf queries the supply of a single coin. - rpc SupplyOf(QuerySupplyOfRequest) returns (QuerySupplyOfResponse) { - option (google.api.http).get = "/cosmos/bank/v1beta1/supply/by_denom"; - } - - // Params queries the parameters of x/bank module. - rpc Params(QueryParamsRequest) returns (QueryParamsResponse) { - option (google.api.http).get = "/cosmos/bank/v1beta1/params"; - } - - // DenomsMetadata queries the client metadata of a given coin denomination. - rpc DenomMetadata(QueryDenomMetadataRequest) returns (QueryDenomMetadataResponse) { - option (google.api.http).get = "/cosmos/bank/v1beta1/denoms_metadata/{denom}"; - } - - // DenomsMetadata queries the client metadata for all registered coin - // denominations. - rpc DenomsMetadata(QueryDenomsMetadataRequest) returns (QueryDenomsMetadataResponse) { - option (google.api.http).get = "/cosmos/bank/v1beta1/denoms_metadata"; - } - - // DenomOwners queries for all account addresses that own a particular token - // denomination. - rpc DenomOwners(QueryDenomOwnersRequest) returns (QueryDenomOwnersResponse) { - option (google.api.http).get = "/cosmos/bank/v1beta1/denom_owners/{denom}"; - } -} - -// QueryBalanceRequest is the request type for the Query/Balance RPC method. -message QueryBalanceRequest { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // address is the address to query balances for. - string address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // denom is the coin denom to query balances for. - string denom = 2; -} - -// QueryBalanceResponse is the response type for the Query/Balance RPC method. -message QueryBalanceResponse { - // balance is the balance of the coin. - cosmos.base.v1beta1.Coin balance = 1; -} - -// QueryBalanceRequest is the request type for the Query/AllBalances RPC method. -message QueryAllBalancesRequest { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // address is the address to query balances for. - string address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // pagination defines an optional pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} - -// QueryAllBalancesResponse is the response type for the Query/AllBalances RPC -// method. -message QueryAllBalancesResponse { - // balances is the balances of all the coins. - repeated cosmos.base.v1beta1.Coin balances = 1 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; - - // pagination defines the pagination in the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QuerySpendableBalancesRequest defines the gRPC request structure for querying -// an account's spendable balances. -message QuerySpendableBalancesRequest { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // address is the address to query spendable balances for. - string address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // pagination defines an optional pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} - -// QuerySpendableBalancesResponse defines the gRPC response structure for querying -// an account's spendable balances. -message QuerySpendableBalancesResponse { - // balances is the spendable balances of all the coins. - repeated cosmos.base.v1beta1.Coin balances = 1 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; - - // pagination defines the pagination in the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryTotalSupplyRequest is the request type for the Query/TotalSupply RPC -// method. -message QueryTotalSupplyRequest { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // pagination defines an optional pagination for the request. - // - // Since: cosmos-sdk 0.43 - cosmos.base.query.v1beta1.PageRequest pagination = 1; -} - -// QueryTotalSupplyResponse is the response type for the Query/TotalSupply RPC -// method -message QueryTotalSupplyResponse { - // supply is the supply of the coins - repeated cosmos.base.v1beta1.Coin supply = 1 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; - - // pagination defines the pagination in the response. - // - // Since: cosmos-sdk 0.43 - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QuerySupplyOfRequest is the request type for the Query/SupplyOf RPC method. -message QuerySupplyOfRequest { - // denom is the coin denom to query balances for. - string denom = 1; -} - -// QuerySupplyOfResponse is the response type for the Query/SupplyOf RPC method. -message QuerySupplyOfResponse { - // amount is the supply of the coin. - cosmos.base.v1beta1.Coin amount = 1 [(gogoproto.nullable) = false]; -} - -// QueryParamsRequest defines the request type for querying x/bank parameters. -message QueryParamsRequest {} - -// QueryParamsResponse defines the response type for querying x/bank parameters. -message QueryParamsResponse { - Params params = 1 [(gogoproto.nullable) = false]; -} - -// QueryDenomsMetadataRequest is the request type for the Query/DenomsMetadata RPC method. -message QueryDenomsMetadataRequest { - // pagination defines an optional pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 1; -} - -// QueryDenomsMetadataResponse is the response type for the Query/DenomsMetadata RPC -// method. -message QueryDenomsMetadataResponse { - // metadata provides the client information for all the registered tokens. - repeated Metadata metadatas = 1 [(gogoproto.nullable) = false]; - - // pagination defines the pagination in the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryDenomMetadataRequest is the request type for the Query/DenomMetadata RPC method. -message QueryDenomMetadataRequest { - // denom is the coin denom to query the metadata for. - string denom = 1; -} - -// QueryDenomMetadataResponse is the response type for the Query/DenomMetadata RPC -// method. -message QueryDenomMetadataResponse { - // metadata describes and provides all the client information for the requested token. - Metadata metadata = 1 [(gogoproto.nullable) = false]; -} - -// QueryDenomOwnersRequest defines the request type for the DenomOwners RPC query, -// which queries for a paginated set of all account holders of a particular -// denomination. -message QueryDenomOwnersRequest { - // denom defines the coin denomination to query all account holders for. - string denom = 1; - - // pagination defines an optional pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} - -// 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. -message DenomOwner { - // address defines the address that owns a particular denomination. - string address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // balance is the balance of the denominated coin for an account. - cosmos.base.v1beta1.Coin balance = 2 [(gogoproto.nullable) = false]; -} - -// QueryDenomOwnersResponse defines the RPC response of a DenomOwners RPC query. -message QueryDenomOwnersResponse { - repeated DenomOwner denom_owners = 1; - - // pagination defines the pagination in the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} diff --git a/src/cosmospy_protobuf/cosmos/bank/v1beta1/tx.proto b/src/cosmospy_protobuf/cosmos/bank/v1beta1/tx.proto deleted file mode 100644 index 22e62cbf..00000000 --- a/src/cosmospy_protobuf/cosmos/bank/v1beta1/tx.proto +++ /dev/null @@ -1,48 +0,0 @@ -syntax = "proto3"; -package cosmos.bank.v1beta1; - -import "gogoproto/gogo.proto"; -import "cosmos/base/v1beta1/coin.proto"; -import "cosmos/bank/v1beta1/bank.proto"; -import "cosmos_proto/cosmos.proto"; -import "cosmos/msg/v1/msg.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/bank/types"; - -// Msg defines the bank Msg service. -service Msg { - // Send defines a method for sending coins from one account to another account. - rpc Send(MsgSend) returns (MsgSendResponse); - - // MultiSend defines a method for sending coins from some accounts to other accounts. - rpc MultiSend(MsgMultiSend) returns (MsgMultiSendResponse); -} - -// MsgSend represents a message to send coins from one account to another. -message MsgSend { - option (cosmos.msg.v1.signer) = "from_address"; - - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - string from_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - string to_address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - repeated cosmos.base.v1beta1.Coin amount = 3 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; -} - -// MsgSendResponse defines the Msg/Send response type. -message MsgSendResponse {} - -// MsgMultiSend represents an arbitrary multi-in, multi-out send message. -message MsgMultiSend { - option (cosmos.msg.v1.signer) = "inputs"; - - option (gogoproto.equal) = false; - - repeated Input inputs = 1 [(gogoproto.nullable) = false]; - repeated Output outputs = 2 [(gogoproto.nullable) = false]; -} - -// MsgMultiSendResponse defines the Msg/MultiSend response type. -message MsgMultiSendResponse {} diff --git a/src/cosmospy_protobuf/cosmos/base/abci/v1beta1/abci.proto b/src/cosmospy_protobuf/cosmos/base/abci/v1beta1/abci.proto deleted file mode 100644 index 09a2fcc4..00000000 --- a/src/cosmospy_protobuf/cosmos/base/abci/v1beta1/abci.proto +++ /dev/null @@ -1,158 +0,0 @@ -syntax = "proto3"; -package cosmos.base.abci.v1beta1; - -import "gogoproto/gogo.proto"; -import "tendermint/abci/types.proto"; -import "google/protobuf/any.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/types"; -option (gogoproto.goproto_stringer_all) = false; - -// TxResponse defines a structure containing relevant tx data and metadata. The -// tags are stringified and the log is JSON decoded. -message TxResponse { - option (gogoproto.goproto_getters) = false; - // The block height - int64 height = 1; - // The transaction hash. - string txhash = 2 [(gogoproto.customname) = "TxHash"]; - // Namespace for the Code - string codespace = 3; - // Response code. - uint32 code = 4; - // Result bytes, if any. - string data = 5; - // The output of the application's logger (raw string). May be - // non-deterministic. - string raw_log = 6; - // The output of the application's logger (typed). May be non-deterministic. - repeated ABCIMessageLog logs = 7 [(gogoproto.castrepeated) = "ABCIMessageLogs", (gogoproto.nullable) = false]; - // Additional information. May be non-deterministic. - string info = 8; - // Amount of gas requested for transaction. - int64 gas_wanted = 9; - // Amount of gas consumed by transaction. - int64 gas_used = 10; - // The request transaction bytes. - google.protobuf.Any tx = 11; - // 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. - string timestamp = 12; - // 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 handler. 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 - repeated tendermint.abci.Event events = 13 [(gogoproto.nullable) = false]; -} - -// ABCIMessageLog defines a structure containing an indexed tx ABCI message log. -message ABCIMessageLog { - option (gogoproto.stringer) = true; - - uint32 msg_index = 1 [(gogoproto.jsontag) = "msg_index"]; - string log = 2; - - // Events contains a slice of Event objects that were emitted during some - // execution. - repeated StringEvent events = 3 [(gogoproto.castrepeated) = "StringEvents", (gogoproto.nullable) = false]; -} - -// StringEvent defines en Event object wrapper where all the attributes -// contain key/value pairs that are strings instead of raw bytes. -message StringEvent { - option (gogoproto.stringer) = true; - - string type = 1; - repeated Attribute attributes = 2 [(gogoproto.nullable) = false]; -} - -// Attribute defines an attribute wrapper where the key and value are -// strings instead of raw bytes. -message Attribute { - string key = 1; - string value = 2; -} - -// GasInfo defines tx execution gas context. -message GasInfo { - // GasWanted is the maximum units of work we allow this tx to perform. - uint64 gas_wanted = 1; - - // GasUsed is the amount of gas actually consumed. - uint64 gas_used = 2; -} - -// Result is the union of ResponseFormat and ResponseCheckTx. -message Result { - option (gogoproto.goproto_getters) = false; - - // 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. - bytes data = 1 [deprecated = true]; - - // Log contains the log information from message or handler execution. - string log = 2; - - // Events contains a slice of Event objects that were emitted during message - // or handler execution. - repeated tendermint.abci.Event events = 3 [(gogoproto.nullable) = false]; - - // msg_responses contains the Msg handler responses type packed in Anys. - // - // Since: cosmos-sdk 0.46 - repeated google.protobuf.Any msg_responses = 4; -} - -// SimulationResponse defines the response generated when a transaction is -// successfully simulated. -message SimulationResponse { - GasInfo gas_info = 1 [(gogoproto.embed) = true, (gogoproto.nullable) = false]; - Result result = 2; -} - -// MsgData defines the data returned in a Result object during message -// execution. -message MsgData { - option deprecated = true; - option (gogoproto.stringer) = true; - - string msg_type = 1; - bytes data = 2; -} - -// TxMsgData defines a list of MsgData. A transaction will have a MsgData object -// for each message. -message TxMsgData { - option (gogoproto.stringer) = true; - - // data field is deprecated and not populated. - repeated MsgData data = 1 [deprecated = true]; - - // msg_responses contains the Msg handler responses packed into Anys. - // - // Since: cosmos-sdk 0.46 - repeated google.protobuf.Any msg_responses = 2; -} - -// SearchTxsResult defines a structure for querying txs pageable -message SearchTxsResult { - option (gogoproto.stringer) = true; - - // Count of all txs - uint64 total_count = 1; - // Count of txs in current page - uint64 count = 2; - // Index of current page, start from 1 - uint64 page_number = 3; - // Count of total pages - uint64 page_total = 4; - // Max count txs per page - uint64 limit = 5; - // List of txs in current page - repeated TxResponse txs = 6; -} diff --git a/src/cosmospy_protobuf/cosmos/base/kv/v1beta1/kv.proto b/src/cosmospy_protobuf/cosmos/base/kv/v1beta1/kv.proto deleted file mode 100644 index 4e9b8d28..00000000 --- a/src/cosmospy_protobuf/cosmos/base/kv/v1beta1/kv.proto +++ /dev/null @@ -1,17 +0,0 @@ -syntax = "proto3"; -package cosmos.base.kv.v1beta1; - -import "gogoproto/gogo.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/types/kv"; - -// Pairs defines a repeated slice of Pair objects. -message Pairs { - repeated Pair pairs = 1 [(gogoproto.nullable) = false]; -} - -// Pair defines a key/value bytes tuple. -message Pair { - bytes key = 1; - bytes value = 2; -} diff --git a/src/cosmospy_protobuf/cosmos/base/query/v1beta1/pagination.proto b/src/cosmospy_protobuf/cosmos/base/query/v1beta1/pagination.proto deleted file mode 100644 index 0a368144..00000000 --- a/src/cosmospy_protobuf/cosmos/base/query/v1beta1/pagination.proto +++ /dev/null @@ -1,56 +0,0 @@ -syntax = "proto3"; -package cosmos.base.query.v1beta1; - -option go_package = "github.com/cosmos/cosmos-sdk/types/query"; - -// PageRequest is to be embedded in gRPC request messages for efficient -// pagination. Ex: -// -// message SomeRequest { -// Foo some_parameter = 1; -// PageRequest pagination = 2; -// } -message PageRequest { - // 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. - bytes key = 1; - - // 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. - uint64 offset = 2; - - // 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. - uint64 limit = 3; - - // 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. - bool count_total = 4; - - // reverse is set to true if results are to be returned in the descending order. - // - // Since: cosmos-sdk 0.43 - bool reverse = 5; -} - -// 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; -// } -message PageResponse { - // 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. - bytes next_key = 1; - - // total is total number of results available if PageRequest.count_total - // was set, its value is undefined otherwise - uint64 total = 2; -} diff --git a/src/cosmospy_protobuf/cosmos/base/reflection/v1beta1/reflection.proto b/src/cosmospy_protobuf/cosmos/base/reflection/v1beta1/reflection.proto deleted file mode 100644 index 22670e72..00000000 --- a/src/cosmospy_protobuf/cosmos/base/reflection/v1beta1/reflection.proto +++ /dev/null @@ -1,44 +0,0 @@ -syntax = "proto3"; -package cosmos.base.reflection.v1beta1; - -import "google/api/annotations.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/client/grpc/reflection"; - -// ReflectionService defines a service for interface reflection. -service ReflectionService { - // ListAllInterfaces lists all the interfaces registered in the interface - // registry. - rpc ListAllInterfaces(ListAllInterfacesRequest) returns (ListAllInterfacesResponse) { - option (google.api.http).get = "/cosmos/base/reflection/v1beta1/interfaces"; - }; - - // ListImplementations list all the concrete types that implement a given - // interface. - rpc ListImplementations(ListImplementationsRequest) returns (ListImplementationsResponse) { - option (google.api.http).get = "/cosmos/base/reflection/v1beta1/interfaces/" - "{interface_name}/implementations"; - }; -} - -// ListAllInterfacesRequest is the request type of the ListAllInterfaces RPC. -message ListAllInterfacesRequest {} - -// ListAllInterfacesResponse is the response type of the ListAllInterfaces RPC. -message ListAllInterfacesResponse { - // interface_names is an array of all the registered interfaces. - repeated string interface_names = 1; -} - -// ListImplementationsRequest is the request type of the ListImplementations -// RPC. -message ListImplementationsRequest { - // interface_name defines the interface to query the implementations for. - string interface_name = 1; -} - -// ListImplementationsResponse is the response type of the ListImplementations -// RPC. -message ListImplementationsResponse { - repeated string implementation_message_names = 1; -} diff --git a/src/cosmospy_protobuf/cosmos/base/reflection/v2alpha1/reflection.proto b/src/cosmospy_protobuf/cosmos/base/reflection/v2alpha1/reflection.proto deleted file mode 100644 index d5b04855..00000000 --- a/src/cosmospy_protobuf/cosmos/base/reflection/v2alpha1/reflection.proto +++ /dev/null @@ -1,218 +0,0 @@ -// Since: cosmos-sdk 0.43 -syntax = "proto3"; -package cosmos.base.reflection.v2alpha1; - -import "google/api/annotations.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/server/grpc/reflection/v2alpha1"; - -// AppDescriptor describes a cosmos-sdk based application -message AppDescriptor { - // AuthnDescriptor provides information on how to authenticate transactions on the application - // NOTE: experimental and subject to change in future releases. - AuthnDescriptor authn = 1; - // chain provides the chain descriptor - ChainDescriptor chain = 2; - // codec provides metadata information regarding codec related types - CodecDescriptor codec = 3; - // configuration provides metadata information regarding the sdk.Config type - ConfigurationDescriptor configuration = 4; - // query_services provides metadata information regarding the available queriable endpoints - QueryServicesDescriptor query_services = 5; - // tx provides metadata information regarding how to send transactions to the given application - TxDescriptor tx = 6; -} - -// TxDescriptor describes the accepted transaction type -message TxDescriptor { - // fullname is the protobuf fullname of the raw transaction type (for instance the tx.Tx type) - // it is not meant to support polymorphism of transaction types, it is supposed to be used by - // reflection clients to understand if they can handle a specific transaction type in an application. - string fullname = 1; - // msgs lists the accepted application messages (sdk.Msg) - repeated MsgDescriptor msgs = 2; -} - -// AuthnDescriptor provides information on how to sign transactions without relying -// on the online RPCs GetTxMetadata and CombineUnsignedTxAndSignatures -message AuthnDescriptor { - // sign_modes defines the supported signature algorithm - repeated SigningModeDescriptor sign_modes = 1; -} - -// SigningModeDescriptor provides information on a signing flow of the application -// NOTE(fdymylja): here we could go as far as providing an entire flow on how -// to sign a message given a SigningModeDescriptor, but it's better to think about -// this another time -message SigningModeDescriptor { - // name defines the unique name of the signing mode - string name = 1; - // number is the unique int32 identifier for the sign_mode enum - int32 number = 2; - // authn_info_provider_method_fullname defines the fullname of the method to call to get - // the metadata required to authenticate using the provided sign_modes - string authn_info_provider_method_fullname = 3; -} - -// ChainDescriptor describes chain information of the application -message ChainDescriptor { - // id is the chain id - string id = 1; -} - -// CodecDescriptor describes the registered interfaces and provides metadata information on the types -message CodecDescriptor { - // interfaces is a list of the registerted interfaces descriptors - repeated InterfaceDescriptor interfaces = 1; -} - -// InterfaceDescriptor describes the implementation of an interface -message InterfaceDescriptor { - // fullname is the name of the interface - string fullname = 1; - // interface_accepting_messages contains information regarding the proto messages which contain the interface as - // google.protobuf.Any field - repeated InterfaceAcceptingMessageDescriptor interface_accepting_messages = 2; - // interface_implementers is a list of the descriptors of the interface implementers - repeated InterfaceImplementerDescriptor interface_implementers = 3; -} - -// InterfaceImplementerDescriptor describes an interface implementer -message InterfaceImplementerDescriptor { - // fullname is the protobuf queryable name of the interface implementer - string fullname = 1; - // type_url defines the type URL used when marshalling the type as any - // this is required so we can provide type safe google.protobuf.Any marshalling and - // unmarshalling, making sure that we don't accept just 'any' type - // in our interface fields - string type_url = 2; -} - -// InterfaceAcceptingMessageDescriptor describes a protobuf message which contains -// an interface represented as a google.protobuf.Any -message InterfaceAcceptingMessageDescriptor { - // fullname is the protobuf fullname of the type containing the interface - string fullname = 1; - // field_descriptor_names is a list of the protobuf name (not fullname) of the field - // which contains the interface as google.protobuf.Any (the interface is the same, but - // it can be in multiple fields of the same proto message) - repeated string field_descriptor_names = 2; -} - -// ConfigurationDescriptor contains metadata information on the sdk.Config -message ConfigurationDescriptor { - // bech32_account_address_prefix is the account address prefix - string bech32_account_address_prefix = 1; -} - -// MsgDescriptor describes a cosmos-sdk message that can be delivered with a transaction -message MsgDescriptor { - // msg_type_url contains the TypeURL of a sdk.Msg. - string msg_type_url = 1; -} - -// ReflectionService defines a service for application reflection. -service ReflectionService { - // GetAuthnDescriptor returns information on how to authenticate transactions in the application - // NOTE: this RPC is still experimental and might be subject to breaking changes or removal in - // future releases of the cosmos-sdk. - rpc GetAuthnDescriptor(GetAuthnDescriptorRequest) returns (GetAuthnDescriptorResponse) { - option (google.api.http).get = "/cosmos/base/reflection/v1beta1/app_descriptor/authn"; - } - // GetChainDescriptor returns the description of the chain - rpc GetChainDescriptor(GetChainDescriptorRequest) returns (GetChainDescriptorResponse) { - option (google.api.http).get = "/cosmos/base/reflection/v1beta1/app_descriptor/chain"; - }; - // GetCodecDescriptor returns the descriptor of the codec of the application - rpc GetCodecDescriptor(GetCodecDescriptorRequest) returns (GetCodecDescriptorResponse) { - option (google.api.http).get = "/cosmos/base/reflection/v1beta1/app_descriptor/codec"; - } - // GetConfigurationDescriptor returns the descriptor for the sdk.Config of the application - rpc GetConfigurationDescriptor(GetConfigurationDescriptorRequest) returns (GetConfigurationDescriptorResponse) { - option (google.api.http).get = "/cosmos/base/reflection/v1beta1/app_descriptor/configuration"; - } - // GetQueryServicesDescriptor returns the available gRPC queryable services of the application - rpc GetQueryServicesDescriptor(GetQueryServicesDescriptorRequest) returns (GetQueryServicesDescriptorResponse) { - option (google.api.http).get = "/cosmos/base/reflection/v1beta1/app_descriptor/query_services"; - } - // GetTxDescriptor returns information on the used transaction object and available msgs that can be used - rpc GetTxDescriptor(GetTxDescriptorRequest) returns (GetTxDescriptorResponse) { - option (google.api.http).get = "/cosmos/base/reflection/v1beta1/app_descriptor/tx_descriptor"; - } -} - -// GetAuthnDescriptorRequest is the request used for the GetAuthnDescriptor RPC -message GetAuthnDescriptorRequest {} -// GetAuthnDescriptorResponse is the response returned by the GetAuthnDescriptor RPC -message GetAuthnDescriptorResponse { - // authn describes how to authenticate to the application when sending transactions - AuthnDescriptor authn = 1; -} - -// GetChainDescriptorRequest is the request used for the GetChainDescriptor RPC -message GetChainDescriptorRequest {} -// GetChainDescriptorResponse is the response returned by the GetChainDescriptor RPC -message GetChainDescriptorResponse { - // chain describes application chain information - ChainDescriptor chain = 1; -} - -// GetCodecDescriptorRequest is the request used for the GetCodecDescriptor RPC -message GetCodecDescriptorRequest {} -// GetCodecDescriptorResponse is the response returned by the GetCodecDescriptor RPC -message GetCodecDescriptorResponse { - // codec describes the application codec such as registered interfaces and implementations - CodecDescriptor codec = 1; -} - -// GetConfigurationDescriptorRequest is the request used for the GetConfigurationDescriptor RPC -message GetConfigurationDescriptorRequest {} -// GetConfigurationDescriptorResponse is the response returned by the GetConfigurationDescriptor RPC -message GetConfigurationDescriptorResponse { - // config describes the application's sdk.Config - ConfigurationDescriptor config = 1; -} - -// GetQueryServicesDescriptorRequest is the request used for the GetQueryServicesDescriptor RPC -message GetQueryServicesDescriptorRequest {} -// GetQueryServicesDescriptorResponse is the response returned by the GetQueryServicesDescriptor RPC -message GetQueryServicesDescriptorResponse { - // queries provides information on the available queryable services - QueryServicesDescriptor queries = 1; -} - -// GetTxDescriptorRequest is the request used for the GetTxDescriptor RPC -message GetTxDescriptorRequest {} -// GetTxDescriptorResponse is the response returned by the GetTxDescriptor RPC -message GetTxDescriptorResponse { - // tx provides information on msgs that can be forwarded to the application - // alongside the accepted transaction protobuf type - TxDescriptor tx = 1; -} - -// QueryServicesDescriptor contains the list of cosmos-sdk queriable services -message QueryServicesDescriptor { - // query_services is a list of cosmos-sdk QueryServiceDescriptor - repeated QueryServiceDescriptor query_services = 1; -} - -// QueryServiceDescriptor describes a cosmos-sdk queryable service -message QueryServiceDescriptor { - // fullname is the protobuf fullname of the service descriptor - string fullname = 1; - // is_module describes if this service is actually exposed by an application's module - bool is_module = 2; - // methods provides a list of query service methods - repeated QueryMethodDescriptor methods = 3; -} - -// QueryMethodDescriptor describes a queryable method of a query service -// no other info is provided beside method name and tendermint queryable path -// because it would be redundant with the grpc reflection service -message QueryMethodDescriptor { - // name is the protobuf name (not fullname) of the method - string name = 1; - // full_query_path is the path that can be used to query - // this method via tendermint abci.Query - string full_query_path = 2; -} diff --git a/src/cosmospy_protobuf/cosmos/base/snapshots/v1beta1/snapshot.proto b/src/cosmospy_protobuf/cosmos/base/snapshots/v1beta1/snapshot.proto deleted file mode 100644 index a89e0b4c..00000000 --- a/src/cosmospy_protobuf/cosmos/base/snapshots/v1beta1/snapshot.proto +++ /dev/null @@ -1,70 +0,0 @@ -syntax = "proto3"; -package cosmos.base.snapshots.v1beta1; - -import "gogoproto/gogo.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/snapshots/types"; - -// Snapshot contains Tendermint state sync snapshot info. -message Snapshot { - uint64 height = 1; - uint32 format = 2; - uint32 chunks = 3; - bytes hash = 4; - Metadata metadata = 5 [(gogoproto.nullable) = false]; -} - -// Metadata contains SDK-specific snapshot metadata. -message Metadata { - repeated bytes chunk_hashes = 1; // SHA-256 chunk hashes -} - -// SnapshotItem is an item contained in a rootmulti.Store snapshot. -message SnapshotItem { - // item is the specific type of snapshot item. - oneof item { - SnapshotStoreItem store = 1; - SnapshotIAVLItem iavl = 2 [(gogoproto.customname) = "IAVL"]; - SnapshotExtensionMeta extension = 3; - SnapshotExtensionPayload extension_payload = 4; - SnapshotKVItem kv = 5 [(gogoproto.customname) = "KV"]; - SnapshotSchema schema = 6; - } -} - -// SnapshotStoreItem contains metadata about a snapshotted store. -message SnapshotStoreItem { - string name = 1; -} - -// SnapshotIAVLItem is an exported IAVL node. -message SnapshotIAVLItem { - bytes key = 1; - bytes value = 2; - // version is block height - int64 version = 3; - // height is depth of the tree. - int32 height = 4; -} - -// SnapshotExtensionMeta contains metadata about an external snapshotter. -message SnapshotExtensionMeta { - string name = 1; - uint32 format = 2; -} - -// SnapshotExtensionPayload contains payloads of an external snapshotter. -message SnapshotExtensionPayload { - bytes payload = 1; -} - -// SnapshotKVItem is an exported Key/Value Pair -message SnapshotKVItem { - bytes key = 1; - bytes value = 2; -} - -// SnapshotSchema is an exported schema of smt store -message SnapshotSchema{ - repeated bytes keys = 1; -} diff --git a/src/cosmospy_protobuf/cosmos/base/store/v1beta1/commit_info.proto b/src/cosmospy_protobuf/cosmos/base/store/v1beta1/commit_info.proto deleted file mode 100644 index 98a33d30..00000000 --- a/src/cosmospy_protobuf/cosmos/base/store/v1beta1/commit_info.proto +++ /dev/null @@ -1,29 +0,0 @@ -syntax = "proto3"; -package cosmos.base.store.v1beta1; - -import "gogoproto/gogo.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/store/types"; - -// CommitInfo defines commit information used by the multi-store when committing -// a version/height. -message CommitInfo { - int64 version = 1; - repeated StoreInfo store_infos = 2 [(gogoproto.nullable) = false]; -} - -// StoreInfo defines store-specific commit information. It contains a reference -// between a store name and the commit ID. -message StoreInfo { - string name = 1; - CommitID commit_id = 2 [(gogoproto.nullable) = false]; -} - -// CommitID defines the committment information when a specific store is -// committed. -message CommitID { - option (gogoproto.goproto_stringer) = false; - - int64 version = 1; - bytes hash = 2; -} diff --git a/src/cosmospy_protobuf/cosmos/base/store/v1beta1/listening.proto b/src/cosmospy_protobuf/cosmos/base/store/v1beta1/listening.proto deleted file mode 100644 index 35999710..00000000 --- a/src/cosmospy_protobuf/cosmos/base/store/v1beta1/listening.proto +++ /dev/null @@ -1,16 +0,0 @@ -syntax = "proto3"; -package cosmos.base.store.v1beta1; - -option go_package = "github.com/cosmos/cosmos-sdk/store/types"; - -// StoreKVPair is a KVStore KVPair used for listening to state changes (Sets and Deletes) -// It optionally includes the StoreKey for the originating KVStore and a Boolean flag to distinguish between Sets and -// Deletes -// -// Since: cosmos-sdk 0.43 -message StoreKVPair { - string store_key = 1; // the store key for the KVStore this pair originates from - bool delete = 2; // true indicates a delete operation, false indicates a set operation - bytes key = 3; - bytes value = 4; -} diff --git a/src/cosmospy_protobuf/cosmos/base/tendermint/v1beta1/query.proto b/src/cosmospy_protobuf/cosmos/base/tendermint/v1beta1/query.proto deleted file mode 100644 index b6ddb1a5..00000000 --- a/src/cosmospy_protobuf/cosmos/base/tendermint/v1beta1/query.proto +++ /dev/null @@ -1,196 +0,0 @@ -syntax = "proto3"; -package cosmos.base.tendermint.v1beta1; - -import "gogoproto/gogo.proto"; -import "google/protobuf/any.proto"; -import "google/api/annotations.proto"; -import "tendermint/p2p/types.proto"; -import "tendermint/types/block.proto"; -import "tendermint/types/types.proto"; -import "cosmos/base/query/v1beta1/pagination.proto"; -import "cosmos_proto/cosmos.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/client/grpc/tmservice"; - -// Service defines the gRPC querier service for tendermint queries. -service Service { - // GetNodeInfo queries the current node info. - rpc GetNodeInfo(GetNodeInfoRequest) returns (GetNodeInfoResponse) { - option (google.api.http).get = "/cosmos/base/tendermint/v1beta1/node_info"; - } - - // GetSyncing queries node syncing. - rpc GetSyncing(GetSyncingRequest) returns (GetSyncingResponse) { - option (google.api.http).get = "/cosmos/base/tendermint/v1beta1/syncing"; - } - - // GetLatestBlock returns the latest block. - rpc GetLatestBlock(GetLatestBlockRequest) returns (GetLatestBlockResponse) { - option (google.api.http).get = "/cosmos/base/tendermint/v1beta1/blocks/latest"; - } - - // GetBlockByHeight queries block for given height. - rpc GetBlockByHeight(GetBlockByHeightRequest) returns (GetBlockByHeightResponse) { - option (google.api.http).get = "/cosmos/base/tendermint/v1beta1/blocks/{height}"; - } - - // GetLatestValidatorSet queries latest validator-set. - rpc GetLatestValidatorSet(GetLatestValidatorSetRequest) returns (GetLatestValidatorSetResponse) { - option (google.api.http).get = "/cosmos/base/tendermint/v1beta1/validatorsets/latest"; - } - - // GetValidatorSetByHeight queries validator-set at a given height. - rpc GetValidatorSetByHeight(GetValidatorSetByHeightRequest) returns (GetValidatorSetByHeightResponse) { - option (google.api.http).get = "/cosmos/base/tendermint/v1beta1/validatorsets/{height}"; - } - - // 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. - // - // Since: cosmos-sdk 0.46 - rpc ABCIQuery(ABCIQueryRequest) returns (ABCIQueryResponse) { - option (google.api.http).get = "/cosmos/base/tendermint/v1beta1/abci_query"; - } -} - -// GetValidatorSetByHeightRequest is the request type for the Query/GetValidatorSetByHeight RPC method. -message GetValidatorSetByHeightRequest { - int64 height = 1; - // pagination defines an pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} - -// GetValidatorSetByHeightResponse is the response type for the Query/GetValidatorSetByHeight RPC method. -message GetValidatorSetByHeightResponse { - int64 block_height = 1; - repeated Validator validators = 2; - // pagination defines an pagination for the response. - cosmos.base.query.v1beta1.PageResponse pagination = 3; -} - -// GetLatestValidatorSetRequest is the request type for the Query/GetValidatorSetByHeight RPC method. -message GetLatestValidatorSetRequest { - // pagination defines an pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 1; -} - -// GetLatestValidatorSetResponse is the response type for the Query/GetValidatorSetByHeight RPC method. -message GetLatestValidatorSetResponse { - int64 block_height = 1; - repeated Validator validators = 2; - // pagination defines an pagination for the response. - cosmos.base.query.v1beta1.PageResponse pagination = 3; -} - -// Validator is the type for the validator-set. -message Validator { - string address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - google.protobuf.Any pub_key = 2; - int64 voting_power = 3; - int64 proposer_priority = 4; -} - -// GetBlockByHeightRequest is the request type for the Query/GetBlockByHeight RPC method. -message GetBlockByHeightRequest { - int64 height = 1; -} - -// GetBlockByHeightResponse is the response type for the Query/GetBlockByHeight RPC method. -message GetBlockByHeightResponse { - .tendermint.types.BlockID block_id = 1; - .tendermint.types.Block block = 2; -} - -// GetLatestBlockRequest is the request type for the Query/GetLatestBlock RPC method. -message GetLatestBlockRequest {} - -// GetLatestBlockResponse is the response type for the Query/GetLatestBlock RPC method. -message GetLatestBlockResponse { - .tendermint.types.BlockID block_id = 1; - .tendermint.types.Block block = 2; -} - -// GetSyncingRequest is the request type for the Query/GetSyncing RPC method. -message GetSyncingRequest {} - -// GetSyncingResponse is the response type for the Query/GetSyncing RPC method. -message GetSyncingResponse { - bool syncing = 1; -} - -// GetNodeInfoRequest is the request type for the Query/GetNodeInfo RPC method. -message GetNodeInfoRequest {} - -// GetNodeInfoResponse is the response type for the Query/GetNodeInfo RPC method. -message GetNodeInfoResponse { - .tendermint.p2p.NodeInfo node_info = 1; - VersionInfo application_version = 2; -} - -// VersionInfo is the type for the GetNodeInfoResponse message. -message VersionInfo { - string name = 1; - string app_name = 2; - string version = 3; - string git_commit = 4; - string build_tags = 5; - string go_version = 6; - repeated Module build_deps = 7; - // Since: cosmos-sdk 0.43 - string cosmos_sdk_version = 8; -} - -// Module is the type for VersionInfo -message Module { - // module path - string path = 1; - // module version - string version = 2; - // checksum - string sum = 3; -} - -// ABCIQueryRequest defines the request structure for the ABCIQuery gRPC query. -message ABCIQueryRequest { - bytes data = 1; - string path = 2; - int64 height = 3; - bool prove = 4; -} - -// ABCIQueryResponse defines the response structure for the ABCIQuery gRPC query. -// -// Note: This type is a duplicate of the ResponseQuery proto type defined in -// Tendermint. -message ABCIQueryResponse { - uint32 code = 1; - // DEPRECATED: use "value" instead - reserved 2; - string log = 3; // nondeterministic - string info = 4; // nondeterministic - int64 index = 5; - bytes key = 6; - bytes value = 7; - ProofOps proof_ops = 8; - int64 height = 9; - string codespace = 10; -} - -// ProofOp defines an operation used for calculating Merkle root. The data could -// be arbitrary format, providing nessecary data for example neighbouring node -// hash. -// -// Note: This type is a duplicate of the ProofOp proto type defined in Tendermint. -message ProofOp { - string type = 1; - bytes key = 2; - bytes data = 3; -} - -// ProofOps is Merkle proof defined by the list of ProofOps. -// -// Note: This type is a duplicate of the ProofOps proto type defined in Tendermint. -message ProofOps { - repeated ProofOp ops = 1 [(gogoproto.nullable) = false]; -} diff --git a/src/cosmospy_protobuf/cosmos/base/v1beta1/coin.proto b/src/cosmospy_protobuf/cosmos/base/v1beta1/coin.proto deleted file mode 100644 index 69e67e09..00000000 --- a/src/cosmospy_protobuf/cosmos/base/v1beta1/coin.proto +++ /dev/null @@ -1,43 +0,0 @@ -syntax = "proto3"; -package cosmos.base.v1beta1; - -import "gogoproto/gogo.proto"; -import "cosmos_proto/cosmos.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/types"; -option (gogoproto.goproto_stringer_all) = false; -option (gogoproto.stringer_all) = false; - -// Coin defines a token with a denomination and an amount. -// -// NOTE: The amount field is an Int which implements the custom method -// signatures required by gogoproto. -message Coin { - option (gogoproto.equal) = true; - - string denom = 1; - string amount = 2 - [(cosmos_proto.scalar) = "cosmos.Int", (gogoproto.customtype) = "Int", (gogoproto.nullable) = false]; -} - -// 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. -message DecCoin { - option (gogoproto.equal) = true; - - string denom = 1; - string amount = 2 - [(cosmos_proto.scalar) = "cosmos.Dec", (gogoproto.customtype) = "Dec", (gogoproto.nullable) = false]; -} - -// IntProto defines a Protobuf wrapper around an Int object. -message IntProto { - string int = 1 [(cosmos_proto.scalar) = "cosmos.Int", (gogoproto.customtype) = "Int", (gogoproto.nullable) = false]; -} - -// DecProto defines a Protobuf wrapper around a Dec object. -message DecProto { - string dec = 1 [(cosmos_proto.scalar) = "cosmos.Dec", (gogoproto.customtype) = "Dec", (gogoproto.nullable) = false]; -} diff --git a/src/cosmospy_protobuf/cosmos/capability/v1beta1/capability.proto b/src/cosmospy_protobuf/cosmos/capability/v1beta1/capability.proto deleted file mode 100644 index c433566d..00000000 --- a/src/cosmospy_protobuf/cosmos/capability/v1beta1/capability.proto +++ /dev/null @@ -1,30 +0,0 @@ -syntax = "proto3"; -package cosmos.capability.v1beta1; - -option go_package = "github.com/cosmos/cosmos-sdk/x/capability/types"; - -import "gogoproto/gogo.proto"; - -// Capability defines an implementation of an object capability. The index -// provided to a Capability must be globally unique. -message Capability { - option (gogoproto.goproto_stringer) = false; - - uint64 index = 1; -} - -// Owner defines a single capability owner. An owner is defined by the name of -// capability and the module name. -message Owner { - option (gogoproto.goproto_stringer) = false; - option (gogoproto.goproto_getters) = false; - - string module = 1; - string name = 2; -} - -// CapabilityOwners defines a set of owners of a single Capability. The set of -// owners must be unique. -message CapabilityOwners { - repeated Owner owners = 1 [(gogoproto.nullable) = false]; -} diff --git a/src/cosmospy_protobuf/cosmos/capability/v1beta1/genesis.proto b/src/cosmospy_protobuf/cosmos/capability/v1beta1/genesis.proto deleted file mode 100644 index b5482439..00000000 --- a/src/cosmospy_protobuf/cosmos/capability/v1beta1/genesis.proto +++ /dev/null @@ -1,26 +0,0 @@ -syntax = "proto3"; -package cosmos.capability.v1beta1; - -import "gogoproto/gogo.proto"; -import "cosmos/capability/v1beta1/capability.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/capability/types"; - -// GenesisOwners defines the capability owners with their corresponding index. -message GenesisOwners { - // index is the index of the capability owner. - uint64 index = 1; - - // index_owners are the owners at the given index. - CapabilityOwners index_owners = 2 [(gogoproto.nullable) = false]; -} - -// GenesisState defines the capability module's genesis state. -message GenesisState { - // index is the capability global index. - uint64 index = 1; - - // owners represents a map from index to owners of the capability index - // index key is string to allow amino marshalling. - repeated GenesisOwners owners = 2 [(gogoproto.nullable) = false]; -} diff --git a/src/cosmospy_protobuf/cosmos/crisis/v1beta1/genesis.proto b/src/cosmospy_protobuf/cosmos/crisis/v1beta1/genesis.proto deleted file mode 100644 index 5c291604..00000000 --- a/src/cosmospy_protobuf/cosmos/crisis/v1beta1/genesis.proto +++ /dev/null @@ -1,14 +0,0 @@ -syntax = "proto3"; -package cosmos.crisis.v1beta1; - -option go_package = "github.com/cosmos/cosmos-sdk/x/crisis/types"; - -import "gogoproto/gogo.proto"; -import "cosmos/base/v1beta1/coin.proto"; - -// GenesisState defines the crisis module's genesis state. -message GenesisState { - // constant_fee is the fee used to verify the invariant in the crisis - // module. - cosmos.base.v1beta1.Coin constant_fee = 3 [(gogoproto.nullable) = false]; -} diff --git a/src/cosmospy_protobuf/cosmos/crisis/v1beta1/tx.proto b/src/cosmospy_protobuf/cosmos/crisis/v1beta1/tx.proto deleted file mode 100644 index fea9059f..00000000 --- a/src/cosmospy_protobuf/cosmos/crisis/v1beta1/tx.proto +++ /dev/null @@ -1,29 +0,0 @@ -syntax = "proto3"; -package cosmos.crisis.v1beta1; - -option go_package = "github.com/cosmos/cosmos-sdk/x/crisis/types"; - -import "gogoproto/gogo.proto"; -import "cosmos_proto/cosmos.proto"; -import "cosmos/msg/v1/msg.proto"; - -// Msg defines the bank Msg service. -service Msg { - // VerifyInvariant defines a method to verify a particular invariance. - rpc VerifyInvariant(MsgVerifyInvariant) returns (MsgVerifyInvariantResponse); -} - -// MsgVerifyInvariant represents a message to verify a particular invariance. -message MsgVerifyInvariant { - option (cosmos.msg.v1.signer) = "sender"; - - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - string sender = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - string invariant_module_name = 2; - string invariant_route = 3; -} - -// MsgVerifyInvariantResponse defines the Msg/VerifyInvariant response type. -message MsgVerifyInvariantResponse {} diff --git a/src/cosmospy_protobuf/cosmos/crypto/ed25519/keys.proto b/src/cosmospy_protobuf/cosmos/crypto/ed25519/keys.proto deleted file mode 100644 index 6ffec344..00000000 --- a/src/cosmospy_protobuf/cosmos/crypto/ed25519/keys.proto +++ /dev/null @@ -1,23 +0,0 @@ -syntax = "proto3"; -package cosmos.crypto.ed25519; - -import "gogoproto/gogo.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/crypto/keys/ed25519"; - -// PubKey is an ed25519 public key for handling Tendermint keys in SDK. -// It's needed for Any serialization and SDK compatibility. -// It must not be used in a non Tendermint key context because it doesn't implement -// ADR-28. Nevertheless, you will like to use ed25519 in app user level -// then you must create a new proto message and follow ADR-28 for Address construction. -message PubKey { - option (gogoproto.goproto_stringer) = false; - - bytes key = 1 [(gogoproto.casttype) = "crypto/ed25519.PublicKey"]; -} - -// Deprecated: PrivKey defines a ed25519 private key. -// NOTE: ed25519 keys must not be used in SDK apps except in a tendermint validator context. -message PrivKey { - bytes key = 1 [(gogoproto.casttype) = "crypto/ed25519.PrivateKey"]; -} diff --git a/src/cosmospy_protobuf/cosmos/crypto/hd/v1/hd.proto b/src/cosmospy_protobuf/cosmos/crypto/hd/v1/hd.proto deleted file mode 100644 index e4a95afc..00000000 --- a/src/cosmospy_protobuf/cosmos/crypto/hd/v1/hd.proto +++ /dev/null @@ -1,23 +0,0 @@ -syntax = "proto3"; -package cosmos.crypto.hd.v1; - -import "gogoproto/gogo.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/crypto/hd"; -option (gogoproto.goproto_getters_all) = false; - -// BIP44Params is used as path field in ledger item in Record. -message BIP44Params { - option (gogoproto.goproto_stringer) = false; - // purpose is a constant set to 44' (or 0x8000002C) following the BIP43 recommendation - uint32 purpose = 1; - // coin_type is a constant that improves privacy - uint32 coin_type = 2; - // account splits the key space into independent user identities - uint32 account = 3; - // change is a constant used for public derivation. Constant 0 is used for external chain and constant 1 for internal - // chain. - bool change = 4; - // address_index is used as child index in BIP32 derivation - uint32 address_index = 5; -} diff --git a/src/cosmospy_protobuf/cosmos/crypto/keyring/v1/record.proto b/src/cosmospy_protobuf/cosmos/crypto/keyring/v1/record.proto deleted file mode 100644 index 9b2d3c96..00000000 --- a/src/cosmospy_protobuf/cosmos/crypto/keyring/v1/record.proto +++ /dev/null @@ -1,47 +0,0 @@ -syntax = "proto3"; -package cosmos.crypto.keyring.v1; - -import "gogoproto/gogo.proto"; -import "google/protobuf/any.proto"; -import "cosmos/crypto/hd/v1/hd.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/crypto/keyring"; -option (gogoproto.goproto_getters_all) = false; - -// Record is used for representing a key in the keyring. -message Record { - // name represents a name of Record - string name = 1; - // pub_key represents a public key in any format - google.protobuf.Any pub_key = 2; - - // Record contains one of the following items - oneof item { - // local stores the public information about a locally stored key - Local local = 3; - // ledger stores the public information about a Ledger key - Ledger ledger = 4; - // Multi does not store any information. - Multi multi = 5; - // Offline does not store any information. - Offline offline = 6; - } - - // Item is a keyring item stored in a keyring backend. - // Local item - message Local { - google.protobuf.Any priv_key = 1; - string priv_key_type = 2; - } - - // Ledger item - message Ledger { - hd.v1.BIP44Params path = 1; - } - - // Multi item - message Multi {} - - // Offline item - message Offline {} -} diff --git a/src/cosmospy_protobuf/cosmos/crypto/multisig/keys.proto b/src/cosmospy_protobuf/cosmos/crypto/multisig/keys.proto deleted file mode 100644 index 7a11fe33..00000000 --- a/src/cosmospy_protobuf/cosmos/crypto/multisig/keys.proto +++ /dev/null @@ -1,17 +0,0 @@ -syntax = "proto3"; -package cosmos.crypto.multisig; - -import "gogoproto/gogo.proto"; -import "google/protobuf/any.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/crypto/keys/multisig"; - -// LegacyAminoPubKey specifies a public key type -// which nests multiple public keys and a threshold, -// it uses legacy amino address rules. -message LegacyAminoPubKey { - option (gogoproto.goproto_getters) = false; - - uint32 threshold = 1; - repeated google.protobuf.Any public_keys = 2 [(gogoproto.customname) = "PubKeys"]; -} diff --git a/src/cosmospy_protobuf/cosmos/crypto/multisig/v1beta1/multisig.proto b/src/cosmospy_protobuf/cosmos/crypto/multisig/v1beta1/multisig.proto deleted file mode 100644 index bf671f17..00000000 --- a/src/cosmospy_protobuf/cosmos/crypto/multisig/v1beta1/multisig.proto +++ /dev/null @@ -1,25 +0,0 @@ -syntax = "proto3"; -package cosmos.crypto.multisig.v1beta1; - -import "gogoproto/gogo.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/crypto/types"; - -// MultiSignature wraps the signatures from a multisig.LegacyAminoPubKey. -// See cosmos.tx.v1betata1.ModeInfo.Multi for how to specify which signers -// signed and with which modes. -message MultiSignature { - option (gogoproto.goproto_unrecognized) = true; - repeated bytes signatures = 1; -} - -// 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. -message CompactBitArray { - option (gogoproto.goproto_stringer) = false; - - uint32 extra_bits_stored = 1; - bytes elems = 2; -} diff --git a/src/cosmospy_protobuf/cosmos/crypto/secp256k1/keys.proto b/src/cosmospy_protobuf/cosmos/crypto/secp256k1/keys.proto deleted file mode 100644 index a2272571..00000000 --- a/src/cosmospy_protobuf/cosmos/crypto/secp256k1/keys.proto +++ /dev/null @@ -1,22 +0,0 @@ -syntax = "proto3"; -package cosmos.crypto.secp256k1; - -import "gogoproto/gogo.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1"; - -// PubKey defines a secp256k1 public key -// Key is the compressed form of the pubkey. The first byte depends is a 0x02 byte -// if the y-coordinate is the lexicographically largest of the two associated with -// the x-coordinate. Otherwise the first byte is a 0x03. -// This prefix is followed with the x-coordinate. -message PubKey { - option (gogoproto.goproto_stringer) = false; - - bytes key = 1; -} - -// PrivKey defines a secp256k1 private key. -message PrivKey { - bytes key = 1; -} diff --git a/src/cosmospy_protobuf/cosmos/crypto/secp256r1/keys.proto b/src/cosmospy_protobuf/cosmos/crypto/secp256r1/keys.proto deleted file mode 100644 index 2e96c6e3..00000000 --- a/src/cosmospy_protobuf/cosmos/crypto/secp256r1/keys.proto +++ /dev/null @@ -1,23 +0,0 @@ -// Since: cosmos-sdk 0.43 -syntax = "proto3"; -package cosmos.crypto.secp256r1; - -import "gogoproto/gogo.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/crypto/keys/secp256r1"; -option (gogoproto.messagename_all) = true; -option (gogoproto.goproto_stringer_all) = false; -option (gogoproto.goproto_getters_all) = false; - -// PubKey defines a secp256r1 ECDSA public key. -message PubKey { - // Point on secp256r1 curve in a compressed representation as specified in section - // 4.3.6 of ANSI X9.62: https://webstore.ansi.org/standards/ascx9/ansix9621998 - bytes key = 1 [(gogoproto.customtype) = "ecdsaPK"]; -} - -// PrivKey defines a secp256r1 ECDSA private key. -message PrivKey { - // secret number serialized using big-endian encoding - bytes secret = 1 [(gogoproto.customtype) = "ecdsaSK"]; -} diff --git a/src/cosmospy_protobuf/cosmos/distribution/v1beta1/distribution.proto b/src/cosmospy_protobuf/cosmos/distribution/v1beta1/distribution.proto deleted file mode 100644 index ad12bd60..00000000 --- a/src/cosmospy_protobuf/cosmos/distribution/v1beta1/distribution.proto +++ /dev/null @@ -1,152 +0,0 @@ -syntax = "proto3"; -package cosmos.distribution.v1beta1; - -option go_package = "github.com/cosmos/cosmos-sdk/x/distribution/types"; -option (gogoproto.equal_all) = true; - -import "gogoproto/gogo.proto"; -import "cosmos/base/v1beta1/coin.proto"; -import "cosmos_proto/cosmos.proto"; - -// Params defines the set of params for the distribution module. -message Params { - option (gogoproto.goproto_stringer) = false; - string community_tax = 1 [ - (cosmos_proto.scalar) = "cosmos.Dec", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false - ]; - string base_proposer_reward = 2 [ - (cosmos_proto.scalar) = "cosmos.Dec", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false - ]; - string bonus_proposer_reward = 3 [ - (cosmos_proto.scalar) = "cosmos.Dec", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false - ]; - bool withdraw_addr_enabled = 4; -} - -// ValidatorHistoricalRewards represents historical rewards for a validator. -// Height is implicit within the store key. -// Cumulative reward ratio is the sum from the zeroeth period -// until this period of rewards / tokens, per the spec. -// The reference count indicates the number of objects -// which might need to reference this historical entry at any point. -// ReferenceCount = -// number of outstanding delegations which ended the associated period (and -// might need to read that record) -// + number of slashes which ended the associated period (and might need to -// read that record) -// + one per validator for the zeroeth period, set on initialization -message ValidatorHistoricalRewards { - repeated cosmos.base.v1beta1.DecCoin cumulative_reward_ratio = 1 - [(gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.DecCoins", (gogoproto.nullable) = false]; - uint32 reference_count = 2; -} - -// ValidatorCurrentRewards represents current rewards and current -// period for a validator kept as a running counter and incremented -// each block as long as the validator's tokens remain constant. -message ValidatorCurrentRewards { - repeated cosmos.base.v1beta1.DecCoin rewards = 1 - [(gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.DecCoins", (gogoproto.nullable) = false]; - uint64 period = 2; -} - -// ValidatorAccumulatedCommission represents accumulated commission -// for a validator kept as a running counter, can be withdrawn at any time. -message ValidatorAccumulatedCommission { - repeated cosmos.base.v1beta1.DecCoin commission = 1 - [(gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.DecCoins", (gogoproto.nullable) = false]; -} - -// ValidatorOutstandingRewards represents outstanding (un-withdrawn) rewards -// for a validator inexpensive to track, allows simple sanity checks. -message ValidatorOutstandingRewards { - repeated cosmos.base.v1beta1.DecCoin rewards = 1 - [(gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.DecCoins", (gogoproto.nullable) = false]; -} - -// 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. -message ValidatorSlashEvent { - uint64 validator_period = 1; - string fraction = 2 [ - (cosmos_proto.scalar) = "cosmos.Dec", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false - ]; -} - -// ValidatorSlashEvents is a collection of ValidatorSlashEvent messages. -message ValidatorSlashEvents { - option (gogoproto.goproto_stringer) = false; - repeated ValidatorSlashEvent validator_slash_events = 1 [(gogoproto.nullable) = false]; -} - -// FeePool is the global fee pool for distribution. -message FeePool { - repeated cosmos.base.v1beta1.DecCoin community_pool = 1 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.DecCoins"]; -} - -// CommunityPoolSpendProposal details a proposal for use of community funds, -// together with how many coins are proposed to be spent, and to which -// recipient account. -message CommunityPoolSpendProposal { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - option (gogoproto.goproto_stringer) = false; - - string title = 1; - string description = 2; - string recipient = 3; - repeated cosmos.base.v1beta1.Coin amount = 4 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; -} - -// DelegatorStartingInfo represents the starting info for a delegator reward -// period. It tracks the previous validator period, the delegation's amount of -// staking token, and the creation height (to check later on if any slashes have -// occurred). NOTE: Even though validators are slashed to whole staking tokens, -// the delegators within the validator may be left with less than a full token, -// thus sdk.Dec is used. -message DelegatorStartingInfo { - uint64 previous_period = 1; - string stake = 2 [ - (cosmos_proto.scalar) = "cosmos.Dec", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false - ]; - uint64 height = 3 [(gogoproto.jsontag) = "creation_height"]; -} - -// DelegationDelegatorReward represents the properties -// of a delegator's delegation reward. -message DelegationDelegatorReward { - option (gogoproto.goproto_getters) = false; - option (gogoproto.goproto_stringer) = true; - - string validator_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - repeated cosmos.base.v1beta1.DecCoin reward = 2 - [(gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.DecCoins", (gogoproto.nullable) = false]; -} - -// CommunityPoolSpendProposalWithDeposit defines a CommunityPoolSpendProposal -// with a deposit -message CommunityPoolSpendProposalWithDeposit { - option (gogoproto.goproto_getters) = false; - option (gogoproto.goproto_stringer) = true; - - string title = 1; - string description = 2; - string recipient = 3; - string amount = 4; - string deposit = 5; -} diff --git a/src/cosmospy_protobuf/cosmos/distribution/v1beta1/genesis.proto b/src/cosmospy_protobuf/cosmos/distribution/v1beta1/genesis.proto deleted file mode 100644 index 4662e8df..00000000 --- a/src/cosmospy_protobuf/cosmos/distribution/v1beta1/genesis.proto +++ /dev/null @@ -1,144 +0,0 @@ -syntax = "proto3"; -package cosmos.distribution.v1beta1; - -option go_package = "github.com/cosmos/cosmos-sdk/x/distribution/types"; -option (gogoproto.equal_all) = true; - -import "gogoproto/gogo.proto"; -import "cosmos/base/v1beta1/coin.proto"; -import "cosmos/distribution/v1beta1/distribution.proto"; -import "cosmos_proto/cosmos.proto"; - -// DelegatorWithdrawInfo is the address for where distributions rewards are -// withdrawn to by default this struct is only used at genesis to feed in -// default withdraw addresses. -message DelegatorWithdrawInfo { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // delegator_address is the address of the delegator. - string delegator_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // withdraw_address is the address to withdraw the delegation rewards to. - string withdraw_address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// ValidatorOutstandingRewardsRecord is used for import/export via genesis json. -message ValidatorOutstandingRewardsRecord { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // validator_address is the address of the validator. - string validator_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // outstanding_rewards represents the oustanding rewards of a validator. - repeated cosmos.base.v1beta1.DecCoin outstanding_rewards = 2 - [(gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.DecCoins", (gogoproto.nullable) = false]; -} - -// ValidatorAccumulatedCommissionRecord is used for import / export via genesis -// json. -message ValidatorAccumulatedCommissionRecord { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // validator_address is the address of the validator. - string validator_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // accumulated is the accumulated commission of a validator. - ValidatorAccumulatedCommission accumulated = 2 [(gogoproto.nullable) = false]; -} - -// ValidatorHistoricalRewardsRecord is used for import / export via genesis -// json. -message ValidatorHistoricalRewardsRecord { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // validator_address is the address of the validator. - string validator_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // period defines the period the historical rewards apply to. - uint64 period = 2; - - // rewards defines the historical rewards of a validator. - ValidatorHistoricalRewards rewards = 3 [(gogoproto.nullable) = false]; -} - -// ValidatorCurrentRewardsRecord is used for import / export via genesis json. -message ValidatorCurrentRewardsRecord { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // validator_address is the address of the validator. - string validator_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // rewards defines the current rewards of a validator. - ValidatorCurrentRewards rewards = 2 [(gogoproto.nullable) = false]; -} - -// DelegatorStartingInfoRecord used for import / export via genesis json. -message DelegatorStartingInfoRecord { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // delegator_address is the address of the delegator. - string delegator_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // validator_address is the address of the validator. - string validator_address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // starting_info defines the starting info of a delegator. - DelegatorStartingInfo starting_info = 3 [(gogoproto.nullable) = false]; -} - -// ValidatorSlashEventRecord is used for import / export via genesis json. -message ValidatorSlashEventRecord { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // validator_address is the address of the validator. - string validator_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - // height defines the block height at which the slash event occured. - uint64 height = 2; - // period is the period of the slash event. - uint64 period = 3; - // validator_slash_event describes the slash event. - ValidatorSlashEvent validator_slash_event = 4 [(gogoproto.nullable) = false]; -} - -// GenesisState defines the distribution module's genesis state. -message GenesisState { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // params defines all the paramaters of the module. - Params params = 1 [(gogoproto.nullable) = false]; - - // fee_pool defines the fee pool at genesis. - FeePool fee_pool = 2 [(gogoproto.nullable) = false]; - - // fee_pool defines the delegator withdraw infos at genesis. - repeated DelegatorWithdrawInfo delegator_withdraw_infos = 3 [(gogoproto.nullable) = false]; - - // fee_pool defines the previous proposer at genesis. - string previous_proposer = 4 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // fee_pool defines the outstanding rewards of all validators at genesis. - repeated ValidatorOutstandingRewardsRecord outstanding_rewards = 5 [(gogoproto.nullable) = false]; - - // fee_pool defines the accumulated commisions of all validators at genesis. - repeated ValidatorAccumulatedCommissionRecord validator_accumulated_commissions = 6 [(gogoproto.nullable) = false]; - - // fee_pool defines the historical rewards of all validators at genesis. - repeated ValidatorHistoricalRewardsRecord validator_historical_rewards = 7 [(gogoproto.nullable) = false]; - - // fee_pool defines the current rewards of all validators at genesis. - repeated ValidatorCurrentRewardsRecord validator_current_rewards = 8 [(gogoproto.nullable) = false]; - - // fee_pool defines the delegator starting infos at genesis. - repeated DelegatorStartingInfoRecord delegator_starting_infos = 9 [(gogoproto.nullable) = false]; - - // fee_pool defines the validator slash events at genesis. - repeated ValidatorSlashEventRecord validator_slash_events = 10 [(gogoproto.nullable) = false]; -} diff --git a/src/cosmospy_protobuf/cosmos/distribution/v1beta1/query.proto b/src/cosmospy_protobuf/cosmos/distribution/v1beta1/query.proto deleted file mode 100644 index a09413fc..00000000 --- a/src/cosmospy_protobuf/cosmos/distribution/v1beta1/query.proto +++ /dev/null @@ -1,219 +0,0 @@ -syntax = "proto3"; -package cosmos.distribution.v1beta1; - -import "cosmos/base/query/v1beta1/pagination.proto"; -import "gogoproto/gogo.proto"; -import "google/api/annotations.proto"; -import "cosmos/base/v1beta1/coin.proto"; -import "cosmos/distribution/v1beta1/distribution.proto"; -import "cosmos_proto/cosmos.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/distribution/types"; - -// Query defines the gRPC querier service for distribution module. -service Query { - // Params queries params of the distribution module. - rpc Params(QueryParamsRequest) returns (QueryParamsResponse) { - option (google.api.http).get = "/cosmos/distribution/v1beta1/params"; - } - - // ValidatorOutstandingRewards queries rewards of a validator address. - rpc ValidatorOutstandingRewards(QueryValidatorOutstandingRewardsRequest) - returns (QueryValidatorOutstandingRewardsResponse) { - option (google.api.http).get = "/cosmos/distribution/v1beta1/validators/" - "{validator_address}/outstanding_rewards"; - } - - // ValidatorCommission queries accumulated commission for a validator. - rpc ValidatorCommission(QueryValidatorCommissionRequest) returns (QueryValidatorCommissionResponse) { - option (google.api.http).get = "/cosmos/distribution/v1beta1/validators/" - "{validator_address}/commission"; - } - - // ValidatorSlashes queries slash events of a validator. - rpc ValidatorSlashes(QueryValidatorSlashesRequest) returns (QueryValidatorSlashesResponse) { - option (google.api.http).get = "/cosmos/distribution/v1beta1/validators/{validator_address}/slashes"; - } - - // DelegationRewards queries the total rewards accrued by a delegation. - rpc DelegationRewards(QueryDelegationRewardsRequest) returns (QueryDelegationRewardsResponse) { - option (google.api.http).get = "/cosmos/distribution/v1beta1/delegators/{delegator_address}/rewards/" - "{validator_address}"; - } - - // DelegationTotalRewards queries the total rewards accrued by a each - // validator. - rpc DelegationTotalRewards(QueryDelegationTotalRewardsRequest) returns (QueryDelegationTotalRewardsResponse) { - option (google.api.http).get = "/cosmos/distribution/v1beta1/delegators/{delegator_address}/rewards"; - } - - // DelegatorValidators queries the validators of a delegator. - rpc DelegatorValidators(QueryDelegatorValidatorsRequest) returns (QueryDelegatorValidatorsResponse) { - option (google.api.http).get = "/cosmos/distribution/v1beta1/delegators/" - "{delegator_address}/validators"; - } - - // DelegatorWithdrawAddress queries withdraw address of a delegator. - rpc DelegatorWithdrawAddress(QueryDelegatorWithdrawAddressRequest) returns (QueryDelegatorWithdrawAddressResponse) { - option (google.api.http).get = "/cosmos/distribution/v1beta1/delegators/" - "{delegator_address}/withdraw_address"; - } - - // CommunityPool queries the community pool coins. - rpc CommunityPool(QueryCommunityPoolRequest) returns (QueryCommunityPoolResponse) { - option (google.api.http).get = "/cosmos/distribution/v1beta1/community_pool"; - } -} - -// 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]; -} - -// QueryValidatorOutstandingRewardsRequest is the request type for the -// Query/ValidatorOutstandingRewards RPC method. -message QueryValidatorOutstandingRewardsRequest { - // validator_address defines the validator address to query for. - string validator_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// QueryValidatorOutstandingRewardsResponse is the response type for the -// Query/ValidatorOutstandingRewards RPC method. -message QueryValidatorOutstandingRewardsResponse { - ValidatorOutstandingRewards rewards = 1 [(gogoproto.nullable) = false]; -} - -// QueryValidatorCommissionRequest is the request type for the -// Query/ValidatorCommission RPC method -message QueryValidatorCommissionRequest { - // validator_address defines the validator address to query for. - string validator_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// QueryValidatorCommissionResponse is the response type for the -// Query/ValidatorCommission RPC method -message QueryValidatorCommissionResponse { - // commission defines the commision the validator received. - ValidatorAccumulatedCommission commission = 1 [(gogoproto.nullable) = false]; -} - -// QueryValidatorSlashesRequest is the request type for the -// Query/ValidatorSlashes RPC method -message QueryValidatorSlashesRequest { - option (gogoproto.goproto_getters) = false; - option (gogoproto.goproto_stringer) = true; - - // validator_address defines the validator address to query for. - string validator_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - // starting_height defines the optional starting height to query the slashes. - uint64 starting_height = 2; - // starting_height defines the optional ending height to query the slashes. - uint64 ending_height = 3; - // pagination defines an optional pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 4; -} - -// QueryValidatorSlashesResponse is the response type for the -// Query/ValidatorSlashes RPC method. -message QueryValidatorSlashesResponse { - // slashes defines the slashes the validator received. - repeated ValidatorSlashEvent slashes = 1 [(gogoproto.nullable) = false]; - - // pagination defines the pagination in the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryDelegationRewardsRequest is the request type for the -// Query/DelegationRewards RPC method. -message QueryDelegationRewardsRequest { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // delegator_address defines the delegator address to query for. - string delegator_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - // validator_address defines the validator address to query for. - string validator_address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// QueryDelegationRewardsResponse is the response type for the -// Query/DelegationRewards RPC method. -message QueryDelegationRewardsResponse { - // rewards defines the rewards accrued by a delegation. - repeated cosmos.base.v1beta1.DecCoin rewards = 1 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.DecCoins"]; -} - -// QueryDelegationTotalRewardsRequest is the request type for the -// Query/DelegationTotalRewards RPC method. -message QueryDelegationTotalRewardsRequest { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - // delegator_address defines the delegator address to query for. - string delegator_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// QueryDelegationTotalRewardsResponse is the response type for the -// Query/DelegationTotalRewards RPC method. -message QueryDelegationTotalRewardsResponse { - // rewards defines all the rewards accrued by a delegator. - repeated DelegationDelegatorReward rewards = 1 [(gogoproto.nullable) = false]; - // total defines the sum of all the rewards. - repeated cosmos.base.v1beta1.DecCoin total = 2 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.DecCoins"]; -} - -// QueryDelegatorValidatorsRequest is the request type for the -// Query/DelegatorValidators RPC method. -message QueryDelegatorValidatorsRequest { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // delegator_address defines the delegator address to query for. - string delegator_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// QueryDelegatorValidatorsResponse is the response type for the -// Query/DelegatorValidators RPC method. -message QueryDelegatorValidatorsResponse { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // validators defines the validators a delegator is delegating for. - repeated string validators = 1; -} - -// QueryDelegatorWithdrawAddressRequest is the request type for the -// Query/DelegatorWithdrawAddress RPC method. -message QueryDelegatorWithdrawAddressRequest { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // delegator_address defines the delegator address to query for. - string delegator_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// QueryDelegatorWithdrawAddressResponse is the response type for the -// Query/DelegatorWithdrawAddress RPC method. -message QueryDelegatorWithdrawAddressResponse { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // withdraw_address defines the delegator address to query for. - string withdraw_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// QueryCommunityPoolRequest is the request type for the Query/CommunityPool RPC -// method. -message QueryCommunityPoolRequest {} - -// QueryCommunityPoolResponse is the response type for the Query/CommunityPool -// RPC method. -message QueryCommunityPoolResponse { - // pool defines community pool's coins. - repeated cosmos.base.v1beta1.DecCoin pool = 1 - [(gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.DecCoins", (gogoproto.nullable) = false]; -} diff --git a/src/cosmospy_protobuf/cosmos/distribution/v1beta1/tx.proto b/src/cosmospy_protobuf/cosmos/distribution/v1beta1/tx.proto deleted file mode 100644 index 68fea0c2..00000000 --- a/src/cosmospy_protobuf/cosmos/distribution/v1beta1/tx.proto +++ /dev/null @@ -1,97 +0,0 @@ -syntax = "proto3"; -package cosmos.distribution.v1beta1; - -option go_package = "github.com/cosmos/cosmos-sdk/x/distribution/types"; -option (gogoproto.equal_all) = true; - -import "gogoproto/gogo.proto"; -import "cosmos/base/v1beta1/coin.proto"; -import "cosmos_proto/cosmos.proto"; -import "cosmos/msg/v1/msg.proto"; - -// Msg defines the distribution Msg service. -service Msg { - // SetWithdrawAddress defines a method to change the withdraw address - // for a delegator (or validator self-delegation). - rpc SetWithdrawAddress(MsgSetWithdrawAddress) returns (MsgSetWithdrawAddressResponse); - - // WithdrawDelegatorReward defines a method to withdraw rewards of delegator - // from a single validator. - rpc WithdrawDelegatorReward(MsgWithdrawDelegatorReward) returns (MsgWithdrawDelegatorRewardResponse); - - // WithdrawValidatorCommission defines a method to withdraw the - // full commission to the validator address. - rpc WithdrawValidatorCommission(MsgWithdrawValidatorCommission) returns (MsgWithdrawValidatorCommissionResponse); - - // FundCommunityPool defines a method to allow an account to directly - // fund the community pool. - rpc FundCommunityPool(MsgFundCommunityPool) returns (MsgFundCommunityPoolResponse); -} - -// MsgSetWithdrawAddress sets the withdraw address for -// a delegator (or validator self-delegation). -message MsgSetWithdrawAddress { - option (cosmos.msg.v1.signer) = "delegator_address"; - - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - string delegator_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - string withdraw_address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// MsgSetWithdrawAddressResponse defines the Msg/SetWithdrawAddress response type. -message MsgSetWithdrawAddressResponse {} - -// MsgWithdrawDelegatorReward represents delegation withdrawal to a delegator -// from a single validator. -message MsgWithdrawDelegatorReward { - option (cosmos.msg.v1.signer) = "delegator_address"; - - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - string delegator_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - string validator_address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// MsgWithdrawDelegatorRewardResponse defines the Msg/WithdrawDelegatorReward response type. -message MsgWithdrawDelegatorRewardResponse { - // Since: cosmos-sdk 0.46 - repeated cosmos.base.v1beta1.Coin amount = 1 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; -} - -// MsgWithdrawValidatorCommission withdraws the full commission to the validator -// address. -message MsgWithdrawValidatorCommission { - option (cosmos.msg.v1.signer) = "validator_address"; - - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - string validator_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// MsgWithdrawValidatorCommissionResponse defines the Msg/WithdrawValidatorCommission response type. -message MsgWithdrawValidatorCommissionResponse { - // Since: cosmos-sdk 0.46 - repeated cosmos.base.v1beta1.Coin amount = 1 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; -} - -// MsgFundCommunityPool allows an account to directly -// fund the community pool. -message MsgFundCommunityPool { - option (cosmos.msg.v1.signer) = "depositor"; - - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - repeated cosmos.base.v1beta1.Coin amount = 1 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; - string depositor = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// MsgFundCommunityPoolResponse defines the Msg/FundCommunityPool response type. -message MsgFundCommunityPoolResponse {} diff --git a/src/cosmospy_protobuf/cosmos/evidence/v1beta1/evidence.proto b/src/cosmospy_protobuf/cosmos/evidence/v1beta1/evidence.proto deleted file mode 100644 index 83f9ec3d..00000000 --- a/src/cosmospy_protobuf/cosmos/evidence/v1beta1/evidence.proto +++ /dev/null @@ -1,22 +0,0 @@ -syntax = "proto3"; -package cosmos.evidence.v1beta1; - -option go_package = "github.com/cosmos/cosmos-sdk/x/evidence/types"; -option (gogoproto.equal_all) = true; - -import "gogoproto/gogo.proto"; -import "google/protobuf/timestamp.proto"; -import "cosmos_proto/cosmos.proto"; - -// Equivocation implements the Evidence interface and defines evidence of double -// signing misbehavior. -message Equivocation { - option (gogoproto.goproto_stringer) = false; - option (gogoproto.goproto_getters) = false; - option (gogoproto.equal) = false; - - int64 height = 1; - google.protobuf.Timestamp time = 2 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; - int64 power = 3; - string consensus_address = 4 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} \ No newline at end of file diff --git a/src/cosmospy_protobuf/cosmos/evidence/v1beta1/genesis.proto b/src/cosmospy_protobuf/cosmos/evidence/v1beta1/genesis.proto deleted file mode 100644 index 199f446f..00000000 --- a/src/cosmospy_protobuf/cosmos/evidence/v1beta1/genesis.proto +++ /dev/null @@ -1,12 +0,0 @@ -syntax = "proto3"; -package cosmos.evidence.v1beta1; - -option go_package = "github.com/cosmos/cosmos-sdk/x/evidence/types"; - -import "google/protobuf/any.proto"; - -// GenesisState defines the evidence module's genesis state. -message GenesisState { - // evidence defines all the evidence at genesis. - repeated google.protobuf.Any evidence = 1; -} diff --git a/src/cosmospy_protobuf/cosmos/evidence/v1beta1/query.proto b/src/cosmospy_protobuf/cosmos/evidence/v1beta1/query.proto deleted file mode 100644 index eda00544..00000000 --- a/src/cosmospy_protobuf/cosmos/evidence/v1beta1/query.proto +++ /dev/null @@ -1,51 +0,0 @@ -syntax = "proto3"; -package cosmos.evidence.v1beta1; - -import "cosmos/base/query/v1beta1/pagination.proto"; -import "gogoproto/gogo.proto"; -import "google/protobuf/any.proto"; -import "google/api/annotations.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/evidence/types"; - -// Query defines the gRPC querier service. -service Query { - // Evidence queries evidence based on evidence hash. - rpc Evidence(QueryEvidenceRequest) returns (QueryEvidenceResponse) { - option (google.api.http).get = "/cosmos/evidence/v1beta1/evidence/{evidence_hash}"; - } - - // AllEvidence queries all evidence. - rpc AllEvidence(QueryAllEvidenceRequest) returns (QueryAllEvidenceResponse) { - option (google.api.http).get = "/cosmos/evidence/v1beta1/evidence"; - } -} - -// QueryEvidenceRequest is the request type for the Query/Evidence RPC method. -message QueryEvidenceRequest { - // evidence_hash defines the hash of the requested evidence. - bytes evidence_hash = 1 [(gogoproto.casttype) = "github.com/tendermint/tendermint/libs/bytes.HexBytes"]; -} - -// QueryEvidenceResponse is the response type for the Query/Evidence RPC method. -message QueryEvidenceResponse { - // evidence returns the requested evidence. - google.protobuf.Any evidence = 1; -} - -// QueryEvidenceRequest is the request type for the Query/AllEvidence RPC -// method. -message QueryAllEvidenceRequest { - // pagination defines an optional pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 1; -} - -// QueryAllEvidenceResponse is the response type for the Query/AllEvidence RPC -// method. -message QueryAllEvidenceResponse { - // evidence returns all evidences. - repeated google.protobuf.Any evidence = 1; - - // pagination defines the pagination in the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} diff --git a/src/cosmospy_protobuf/cosmos/evidence/v1beta1/tx.proto b/src/cosmospy_protobuf/cosmos/evidence/v1beta1/tx.proto deleted file mode 100644 index 223f7e11..00000000 --- a/src/cosmospy_protobuf/cosmos/evidence/v1beta1/tx.proto +++ /dev/null @@ -1,35 +0,0 @@ -syntax = "proto3"; -package cosmos.evidence.v1beta1; - -option go_package = "github.com/cosmos/cosmos-sdk/x/evidence/types"; -option (gogoproto.equal_all) = true; - -import "gogoproto/gogo.proto"; -import "google/protobuf/any.proto"; -import "cosmos_proto/cosmos.proto"; -import "cosmos/msg/v1/msg.proto"; - -// Msg defines the evidence Msg service. -service Msg { - // SubmitEvidence submits an arbitrary Evidence of misbehavior such as equivocation or - // counterfactual signing. - rpc SubmitEvidence(MsgSubmitEvidence) returns (MsgSubmitEvidenceResponse); -} - -// MsgSubmitEvidence represents a message that supports submitting arbitrary -// Evidence of misbehavior such as equivocation or counterfactual signing. -message MsgSubmitEvidence { - option (cosmos.msg.v1.signer) = "submitter"; - - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - string submitter = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - google.protobuf.Any evidence = 2 [(cosmos_proto.accepts_interface) = "Evidence"]; -} - -// MsgSubmitEvidenceResponse defines the Msg/SubmitEvidence response type. -message MsgSubmitEvidenceResponse { - // hash defines the hash of the evidence. - bytes hash = 4; -} diff --git a/src/cosmospy_protobuf/cosmos/feegrant/v1beta1/feegrant.proto b/src/cosmospy_protobuf/cosmos/feegrant/v1beta1/feegrant.proto deleted file mode 100644 index eca71e2b..00000000 --- a/src/cosmospy_protobuf/cosmos/feegrant/v1beta1/feegrant.proto +++ /dev/null @@ -1,78 +0,0 @@ -// Since: cosmos-sdk 0.43 -syntax = "proto3"; -package cosmos.feegrant.v1beta1; - -import "gogoproto/gogo.proto"; -import "google/protobuf/any.proto"; -import "cosmos_proto/cosmos.proto"; -import "cosmos/base/v1beta1/coin.proto"; -import "google/protobuf/timestamp.proto"; -import "google/protobuf/duration.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/feegrant"; - -// BasicAllowance implements Allowance with a one-time grant of tokens -// that optionally expires. The grantee can use up to SpendLimit to cover fees. -message BasicAllowance { - option (cosmos_proto.implements_interface) = "FeeAllowanceI"; - - // spend_limit specifies the maximum amount of tokens that can be spent - // by this allowance and will be updated as tokens are spent. If it is - // empty, there is no spend limit and any amount of coins can be spent. - repeated cosmos.base.v1beta1.Coin spend_limit = 1 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; - - // expiration specifies an optional time when this allowance expires - google.protobuf.Timestamp expiration = 2 [(gogoproto.stdtime) = true]; -} - -// PeriodicAllowance extends Allowance to allow for both a maximum cap, -// as well as a limit per time period. -message PeriodicAllowance { - option (cosmos_proto.implements_interface) = "FeeAllowanceI"; - - // basic specifies a struct of `BasicAllowance` - BasicAllowance basic = 1 [(gogoproto.nullable) = false]; - - // period specifies the time duration in which period_spend_limit coins can - // be spent before that allowance is reset - google.protobuf.Duration period = 2 [(gogoproto.stdduration) = true, (gogoproto.nullable) = false]; - - // period_spend_limit specifies the maximum number of coins that can be spent - // in the period - repeated cosmos.base.v1beta1.Coin period_spend_limit = 3 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; - - // period_can_spend is the number of coins left to be spent before the period_reset time - repeated cosmos.base.v1beta1.Coin period_can_spend = 4 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; - - // period_reset is the time at which this period resets and a new one begins, - // it is calculated from the start time of the first transaction after the - // last period ended - google.protobuf.Timestamp period_reset = 5 [(gogoproto.stdtime) = true, (gogoproto.nullable) = false]; -} - -// AllowedMsgAllowance creates allowance only for specified message types. -message AllowedMsgAllowance { - option (gogoproto.goproto_getters) = false; - option (cosmos_proto.implements_interface) = "FeeAllowanceI"; - - // allowance can be any of basic and periodic fee allowance. - google.protobuf.Any allowance = 1 [(cosmos_proto.accepts_interface) = "FeeAllowanceI"]; - - // allowed_messages are the messages for which the grantee has the access. - repeated string allowed_messages = 2; -} - -// Grant is stored in the KVStore to record a grant with full context -message Grant { - // granter is the address of the user granting an allowance of their funds. - string granter = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // grantee is the address of the user being granted an allowance of another user's funds. - string grantee = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // allowance can be any of basic, periodic, allowed fee allowance. - google.protobuf.Any allowance = 3 [(cosmos_proto.accepts_interface) = "FeeAllowanceI"]; -} diff --git a/src/cosmospy_protobuf/cosmos/feegrant/v1beta1/genesis.proto b/src/cosmospy_protobuf/cosmos/feegrant/v1beta1/genesis.proto deleted file mode 100644 index 5b1ac4ca..00000000 --- a/src/cosmospy_protobuf/cosmos/feegrant/v1beta1/genesis.proto +++ /dev/null @@ -1,13 +0,0 @@ -// Since: cosmos-sdk 0.43 -syntax = "proto3"; -package cosmos.feegrant.v1beta1; - -import "gogoproto/gogo.proto"; -import "cosmos/feegrant/v1beta1/feegrant.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/feegrant"; - -// GenesisState contains a set of fee allowances, persisted from the store -message GenesisState { - repeated Grant allowances = 1 [(gogoproto.nullable) = false]; -} diff --git a/src/cosmospy_protobuf/cosmos/feegrant/v1beta1/query.proto b/src/cosmospy_protobuf/cosmos/feegrant/v1beta1/query.proto deleted file mode 100644 index 59c992c9..00000000 --- a/src/cosmospy_protobuf/cosmos/feegrant/v1beta1/query.proto +++ /dev/null @@ -1,79 +0,0 @@ -// Since: cosmos-sdk 0.43 -syntax = "proto3"; -package cosmos.feegrant.v1beta1; - -import "cosmos/feegrant/v1beta1/feegrant.proto"; -import "cosmos/base/query/v1beta1/pagination.proto"; -import "google/api/annotations.proto"; -import "cosmos_proto/cosmos.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/feegrant"; - -// Query defines the gRPC querier service. -service Query { - - // Allowance returns fee granted to the grantee by the granter. - rpc Allowance(QueryAllowanceRequest) returns (QueryAllowanceResponse) { - option (google.api.http).get = "/cosmos/feegrant/v1beta1/allowance/{granter}/{grantee}"; - } - - // Allowances returns all the grants for address. - rpc Allowances(QueryAllowancesRequest) returns (QueryAllowancesResponse) { - option (google.api.http).get = "/cosmos/feegrant/v1beta1/allowances/{grantee}"; - } - - // AllowancesByGranter returns all the grants given by an address - // Since v0.46 - rpc AllowancesByGranter(QueryAllowancesByGranterRequest) returns (QueryAllowancesByGranterResponse) { - option (google.api.http).get = "/cosmos/feegrant/v1beta1/issued/{granter}"; - } -} - -// QueryAllowanceRequest is the request type for the Query/Allowance RPC method. -message QueryAllowanceRequest { - // granter is the address of the user granting an allowance of their funds. - string granter = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // grantee is the address of the user being granted an allowance of another user's funds. - string grantee = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// QueryAllowanceResponse is the response type for the Query/Allowance RPC method. -message QueryAllowanceResponse { - // allowance is a allowance granted for grantee by granter. - cosmos.feegrant.v1beta1.Grant allowance = 1; -} - -// QueryAllowancesRequest is the request type for the Query/Allowances RPC method. -message QueryAllowancesRequest { - string grantee = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // pagination defines an pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} - -// QueryAllowancesResponse is the response type for the Query/Allowances RPC method. -message QueryAllowancesResponse { - // allowances are allowance's granted for grantee by granter. - repeated cosmos.feegrant.v1beta1.Grant allowances = 1; - - // pagination defines an pagination for the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryAllowancesByGranterRequest is the request type for the Query/AllowancesByGranter RPC method. -message QueryAllowancesByGranterRequest { - string granter = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // pagination defines an pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} - -// QueryAllowancesByGranterResponse is the response type for the Query/AllowancesByGranter RPC method. -message QueryAllowancesByGranterResponse { - // allowances that have been issued by the granter. - repeated cosmos.feegrant.v1beta1.Grant allowances = 1; - - // pagination defines an pagination for the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} diff --git a/src/cosmospy_protobuf/cosmos/feegrant/v1beta1/tx.proto b/src/cosmospy_protobuf/cosmos/feegrant/v1beta1/tx.proto deleted file mode 100644 index a12d9aaa..00000000 --- a/src/cosmospy_protobuf/cosmos/feegrant/v1beta1/tx.proto +++ /dev/null @@ -1,53 +0,0 @@ -// Since: cosmos-sdk 0.43 -syntax = "proto3"; -package cosmos.feegrant.v1beta1; - -import "google/protobuf/any.proto"; -import "cosmos_proto/cosmos.proto"; -import "cosmos/msg/v1/msg.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/feegrant"; - -// Msg defines the feegrant msg service. -service Msg { - - // GrantAllowance grants fee allowance to the grantee on the granter's - // account with the provided expiration time. - rpc GrantAllowance(MsgGrantAllowance) returns (MsgGrantAllowanceResponse); - - // RevokeAllowance revokes any fee allowance of granter's account that - // has been granted to the grantee. - rpc RevokeAllowance(MsgRevokeAllowance) returns (MsgRevokeAllowanceResponse); -} - -// MsgGrantAllowance adds permission for Grantee to spend up to Allowance -// of fees from the account of Granter. -message MsgGrantAllowance { - option (cosmos.msg.v1.signer) = "granter"; - - // granter is the address of the user granting an allowance of their funds. - string granter = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // grantee is the address of the user being granted an allowance of another user's funds. - string grantee = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // allowance can be any of basic, periodic, allowed fee allowance. - google.protobuf.Any allowance = 3 [(cosmos_proto.accepts_interface) = "FeeAllowanceI"]; -} - -// MsgGrantAllowanceResponse defines the Msg/GrantAllowanceResponse response type. -message MsgGrantAllowanceResponse {} - -// MsgRevokeAllowance removes any existing Allowance from Granter to Grantee. -message MsgRevokeAllowance { - option (cosmos.msg.v1.signer) = "granter"; - - // granter is the address of the user granting an allowance of their funds. - string granter = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // grantee is the address of the user being granted an allowance of another user's funds. - string grantee = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// MsgRevokeAllowanceResponse defines the Msg/RevokeAllowanceResponse response type. -message MsgRevokeAllowanceResponse {} diff --git a/src/cosmospy_protobuf/cosmos/genutil/v1beta1/genesis.proto b/src/cosmospy_protobuf/cosmos/genutil/v1beta1/genesis.proto deleted file mode 100644 index 958d15fe..00000000 --- a/src/cosmospy_protobuf/cosmos/genutil/v1beta1/genesis.proto +++ /dev/null @@ -1,12 +0,0 @@ -syntax = "proto3"; -package cosmos.genutil.v1beta1; - -import "gogoproto/gogo.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/genutil/types"; - -// GenesisState defines the raw genesis transaction in JSON. -message GenesisState { - // gen_txs defines the genesis transactions. - repeated bytes gen_txs = 1 [(gogoproto.casttype) = "encoding/json.RawMessage", (gogoproto.jsontag) = "gentxs"]; -} diff --git a/src/cosmospy_protobuf/cosmos/gov/v1/genesis.proto b/src/cosmospy_protobuf/cosmos/gov/v1/genesis.proto deleted file mode 100644 index cb44a7f3..00000000 --- a/src/cosmospy_protobuf/cosmos/gov/v1/genesis.proto +++ /dev/null @@ -1,26 +0,0 @@ -// Since: cosmos-sdk 0.46 -syntax = "proto3"; - -package cosmos.gov.v1; - -import "cosmos/gov/v1/gov.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/gov/types/v1"; - -// GenesisState defines the gov module's genesis state. -message GenesisState { - // starting_proposal_id is the ID of the starting proposal. - uint64 starting_proposal_id = 1; - // deposits defines all the deposits present at genesis. - repeated Deposit deposits = 2; - // votes defines all the votes present at genesis. - repeated Vote votes = 3; - // proposals defines all the proposals present at genesis. - repeated Proposal proposals = 4; - // params defines all the paramaters of related to deposit. - DepositParams deposit_params = 5; - // params defines all the paramaters of related to voting. - VotingParams voting_params = 6; - // params defines all the paramaters of related to tally. - TallyParams tally_params = 7; -} diff --git a/src/cosmospy_protobuf/cosmos/gov/v1/gov.proto b/src/cosmospy_protobuf/cosmos/gov/v1/gov.proto deleted file mode 100644 index 8a857233..00000000 --- a/src/cosmospy_protobuf/cosmos/gov/v1/gov.proto +++ /dev/null @@ -1,132 +0,0 @@ -// Since: cosmos-sdk 0.46 -syntax = "proto3"; -package cosmos.gov.v1; - -import "cosmos/base/v1beta1/coin.proto"; -import "gogoproto/gogo.proto"; -import "google/protobuf/timestamp.proto"; -import "google/protobuf/any.proto"; -import "google/protobuf/duration.proto"; -import "cosmos_proto/cosmos.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/gov/types/v1"; - -// VoteOption enumerates the valid vote options for a given governance proposal. -enum VoteOption { - // VOTE_OPTION_UNSPECIFIED defines a no-op vote option. - VOTE_OPTION_UNSPECIFIED = 0; - // VOTE_OPTION_YES defines a yes vote option. - VOTE_OPTION_YES = 1; - // VOTE_OPTION_ABSTAIN defines an abstain vote option. - VOTE_OPTION_ABSTAIN = 2; - // VOTE_OPTION_NO defines a no vote option. - VOTE_OPTION_NO = 3; - // VOTE_OPTION_NO_WITH_VETO defines a no with veto vote option. - VOTE_OPTION_NO_WITH_VETO = 4; -} - -// WeightedVoteOption defines a unit of vote for vote split. -message WeightedVoteOption { - VoteOption option = 1; - string weight = 2 [(cosmos_proto.scalar) = "cosmos.Dec"]; -} - -// Deposit defines an amount deposited by an account address to an active -// proposal. -message Deposit { - uint64 proposal_id = 1; - string depositor = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - repeated cosmos.base.v1beta1.Coin amount = 3 [(gogoproto.nullable) = false]; -} - -// Proposal defines the core field members of a governance proposal. -message Proposal { - uint64 id = 1; - repeated google.protobuf.Any messages = 2; - ProposalStatus status = 3; - // 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. - TallyResult final_tally_result = 4; - google.protobuf.Timestamp submit_time = 5 [(gogoproto.stdtime) = true]; - google.protobuf.Timestamp deposit_end_time = 6 [(gogoproto.stdtime) = true]; - repeated cosmos.base.v1beta1.Coin total_deposit = 7 [(gogoproto.nullable) = false]; - google.protobuf.Timestamp voting_start_time = 8 [(gogoproto.stdtime) = true]; - google.protobuf.Timestamp voting_end_time = 9 [(gogoproto.stdtime) = true]; - - // metadata is any arbitrary metadata attached to the proposal. - string metadata = 10; -} - -// ProposalStatus enumerates the valid statuses of a proposal. -enum ProposalStatus { - // PROPOSAL_STATUS_UNSPECIFIED defines the default proposal status. - PROPOSAL_STATUS_UNSPECIFIED = 0; - // PROPOSAL_STATUS_DEPOSIT_PERIOD defines a proposal status during the deposit - // period. - PROPOSAL_STATUS_DEPOSIT_PERIOD = 1; - // PROPOSAL_STATUS_VOTING_PERIOD defines a proposal status during the voting - // period. - PROPOSAL_STATUS_VOTING_PERIOD = 2; - // PROPOSAL_STATUS_PASSED defines a proposal status of a proposal that has - // passed. - PROPOSAL_STATUS_PASSED = 3; - // PROPOSAL_STATUS_REJECTED defines a proposal status of a proposal that has - // been rejected. - PROPOSAL_STATUS_REJECTED = 4; - // PROPOSAL_STATUS_FAILED defines a proposal status of a proposal that has - // failed. - PROPOSAL_STATUS_FAILED = 5; -} - -// TallyResult defines a standard tally for a governance proposal. -message TallyResult { - string yes_count = 1 [(cosmos_proto.scalar) = "cosmos.Int"]; - string abstain_count = 2 [(cosmos_proto.scalar) = "cosmos.Int"]; - string no_count = 3 [(cosmos_proto.scalar) = "cosmos.Int"]; - string no_with_veto_count = 4 [(cosmos_proto.scalar) = "cosmos.Int"]; -} - -// Vote defines a vote on a governance proposal. -// A Vote consists of a proposal ID, the voter, and the vote option. -message Vote { - uint64 proposal_id = 1; - string voter = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - reserved 3; - repeated WeightedVoteOption options = 4; - - // metadata is any arbitrary metadata to attached to the vote. - string metadata = 5; -} - -// DepositParams defines the params for deposits on governance proposals. -message DepositParams { - // Minimum deposit for a proposal to enter voting period. - repeated cosmos.base.v1beta1.Coin min_deposit = 1 - [(gogoproto.nullable) = false, (gogoproto.jsontag) = "min_deposit,omitempty"]; - - // Maximum period for Atom holders to deposit on a proposal. Initial value: 2 - // months. - google.protobuf.Duration max_deposit_period = 2 - [(gogoproto.stdduration) = true, (gogoproto.jsontag) = "max_deposit_period,omitempty"]; -} - -// VotingParams defines the params for voting on governance proposals. -message VotingParams { - // Length of the voting period. - google.protobuf.Duration voting_period = 1 [(gogoproto.stdduration) = true]; -} - -// TallyParams defines the params for tallying votes on governance proposals. -message TallyParams { - // Minimum percentage of total stake needed to vote for a result to be - // considered valid. - string quorum = 1 [(cosmos_proto.scalar) = "cosmos.Dec", (gogoproto.jsontag) = "quorum,omitempty"]; - - // Minimum proportion of Yes votes for proposal to pass. Default value: 0.5. - string threshold = 2 [(cosmos_proto.scalar) = "cosmos.Dec", (gogoproto.jsontag) = "threshold,omitempty"]; - - // Minimum value of Veto votes to Total votes ratio for proposal to be - // vetoed. Default value: 1/3. - string veto_threshold = 3 [(cosmos_proto.scalar) = "cosmos.Dec", (gogoproto.jsontag) = "veto_threshold,omitempty"]; -} diff --git a/src/cosmospy_protobuf/cosmos/gov/v1/query.proto b/src/cosmospy_protobuf/cosmos/gov/v1/query.proto deleted file mode 100644 index b9d59145..00000000 --- a/src/cosmospy_protobuf/cosmos/gov/v1/query.proto +++ /dev/null @@ -1,183 +0,0 @@ - -// Since: cosmos-sdk 0.46 -syntax = "proto3"; -package cosmos.gov.v1; - -import "cosmos/base/query/v1beta1/pagination.proto"; -import "google/api/annotations.proto"; -import "cosmos/gov/v1/gov.proto"; -import "cosmos_proto/cosmos.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/gov/types/v1"; - -// Query defines the gRPC querier service for gov module -service Query { - // Proposal queries proposal details based on ProposalID. - rpc Proposal(QueryProposalRequest) returns (QueryProposalResponse) { - option (google.api.http).get = "/cosmos/gov/v1/proposals/{proposal_id}"; - } - - // Proposals queries all proposals based on given status. - rpc Proposals(QueryProposalsRequest) returns (QueryProposalsResponse) { - option (google.api.http).get = "/cosmos/gov/v1/proposals"; - } - - // Vote queries voted information based on proposalID, voterAddr. - rpc Vote(QueryVoteRequest) returns (QueryVoteResponse) { - option (google.api.http).get = "/cosmos/gov/v1/proposals/{proposal_id}/votes/{voter}"; - } - - // Votes queries votes of a given proposal. - rpc Votes(QueryVotesRequest) returns (QueryVotesResponse) { - option (google.api.http).get = "/cosmos/gov/v1/proposals/{proposal_id}/votes"; - } - - // Params queries all parameters of the gov module. - rpc Params(QueryParamsRequest) returns (QueryParamsResponse) { - option (google.api.http).get = "/cosmos/gov/v1/params/{params_type}"; - } - - // Deposit queries single deposit information based proposalID, depositAddr. - rpc Deposit(QueryDepositRequest) returns (QueryDepositResponse) { - option (google.api.http).get = "/cosmos/gov/v1/proposals/{proposal_id}/deposits/{depositor}"; - } - - // Deposits queries all deposits of a single proposal. - rpc Deposits(QueryDepositsRequest) returns (QueryDepositsResponse) { - option (google.api.http).get = "/cosmos/gov/v1/proposals/{proposal_id}/deposits"; - } - - // TallyResult queries the tally of a proposal vote. - rpc TallyResult(QueryTallyResultRequest) returns (QueryTallyResultResponse) { - option (google.api.http).get = "/cosmos/gov/v1/proposals/{proposal_id}/tally"; - } -} - -// QueryProposalRequest is the request type for the Query/Proposal RPC method. -message QueryProposalRequest { - // proposal_id defines the unique id of the proposal. - uint64 proposal_id = 1; -} - -// QueryProposalResponse is the response type for the Query/Proposal RPC method. -message QueryProposalResponse { - Proposal proposal = 1; -} - -// QueryProposalsRequest is the request type for the Query/Proposals RPC method. -message QueryProposalsRequest { - // proposal_status defines the status of the proposals. - ProposalStatus proposal_status = 1; - - // voter defines the voter address for the proposals. - string voter = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // depositor defines the deposit addresses from the proposals. - string depositor = 3 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // pagination defines an optional pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 4; -} - -// QueryProposalsResponse is the response type for the Query/Proposals RPC -// method. -message QueryProposalsResponse { - repeated Proposal proposals = 1; - - // pagination defines the pagination in the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryVoteRequest is the request type for the Query/Vote RPC method. -message QueryVoteRequest { - // proposal_id defines the unique id of the proposal. - uint64 proposal_id = 1; - - // voter defines the voter address for the proposals. - string voter = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// QueryVoteResponse is the response type for the Query/Vote RPC method. -message QueryVoteResponse { - // vote defined the queried vote. - Vote vote = 1; -} - -// QueryVotesRequest is the request type for the Query/Votes RPC method. -message QueryVotesRequest { - // proposal_id defines the unique id of the proposal. - uint64 proposal_id = 1; - - // pagination defines an optional pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} - -// QueryVotesResponse is the response type for the Query/Votes RPC method. -message QueryVotesResponse { - // votes defined the queried votes. - repeated Vote votes = 1; - - // pagination defines the pagination in the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryParamsRequest is the request type for the Query/Params RPC method. -message QueryParamsRequest { - // params_type defines which parameters to query for, can be one of "voting", - // "tallying" or "deposit". - string params_type = 1; -} - -// QueryParamsResponse is the response type for the Query/Params RPC method. -message QueryParamsResponse { - // voting_params defines the parameters related to voting. - VotingParams voting_params = 1; - // deposit_params defines the parameters related to deposit. - DepositParams deposit_params = 2; - // tally_params defines the parameters related to tally. - TallyParams tally_params = 3; -} - -// QueryDepositRequest is the request type for the Query/Deposit RPC method. -message QueryDepositRequest { - // proposal_id defines the unique id of the proposal. - uint64 proposal_id = 1; - - // depositor defines the deposit addresses from the proposals. - string depositor = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// QueryDepositResponse is the response type for the Query/Deposit RPC method. -message QueryDepositResponse { - // deposit defines the requested deposit. - Deposit deposit = 1; -} - -// QueryDepositsRequest is the request type for the Query/Deposits RPC method. -message QueryDepositsRequest { - // proposal_id defines the unique id of the proposal. - uint64 proposal_id = 1; - - // pagination defines an optional pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} - -// QueryDepositsResponse is the response type for the Query/Deposits RPC method. -message QueryDepositsResponse { - repeated Deposit deposits = 1; - - // pagination defines the pagination in the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryTallyResultRequest is the request type for the Query/Tally RPC method. -message QueryTallyResultRequest { - // proposal_id defines the unique id of the proposal. - uint64 proposal_id = 1; -} - -// QueryTallyResultResponse is the response type for the Query/Tally RPC method. -message QueryTallyResultResponse { - // tally defines the requested tally. - TallyResult tally = 1; -} diff --git a/src/cosmospy_protobuf/cosmos/gov/v1/tx.proto b/src/cosmospy_protobuf/cosmos/gov/v1/tx.proto deleted file mode 100644 index 9306c51e..00000000 --- a/src/cosmospy_protobuf/cosmos/gov/v1/tx.proto +++ /dev/null @@ -1,100 +0,0 @@ -// Since: cosmos-sdk 0.46 -syntax = "proto3"; -package cosmos.gov.v1; - -import "cosmos/base/v1beta1/coin.proto"; -import "cosmos/gov/v1/gov.proto"; -import "gogoproto/gogo.proto"; -import "cosmos_proto/cosmos.proto"; -import "google/protobuf/any.proto"; -import "cosmos/msg/v1/msg.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/gov/types/v1"; - -// Msg defines the gov Msg service. -service Msg { - // SubmitProposal defines a method to create new proposal given a content. - rpc SubmitProposal(MsgSubmitProposal) returns (MsgSubmitProposalResponse); - - // ExecLegacyContent defines a Msg to be in included in a MsgSubmitProposal - // to execute a legacy content-based proposal. - rpc ExecLegacyContent(MsgExecLegacyContent) returns (MsgExecLegacyContentResponse); - - // Vote defines a method to add a vote on a specific proposal. - rpc Vote(MsgVote) returns (MsgVoteResponse); - - // VoteWeighted defines a method to add a weighted vote on a specific proposal. - rpc VoteWeighted(MsgVoteWeighted) returns (MsgVoteWeightedResponse); - - // Deposit defines a method to add deposit on a specific proposal. - rpc Deposit(MsgDeposit) returns (MsgDepositResponse); -} - -// MsgSubmitProposal defines an sdk.Msg type that supports submitting arbitrary -// proposal Content. -message MsgSubmitProposal { - option (cosmos.msg.v1.signer) = "proposer"; - - repeated google.protobuf.Any messages = 1; - repeated cosmos.base.v1beta1.Coin initial_deposit = 2 [(gogoproto.nullable) = false]; - string proposer = 3 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - // metadata is any arbitrary metadata attached to the proposal. - string metadata = 4; -} - -// MsgSubmitProposalResponse defines the Msg/SubmitProposal response type. -message MsgSubmitProposalResponse { - uint64 proposal_id = 1; -} - -// MsgExecLegacyContent is used to wrap the legacy content field into a message. -// This ensures backwards compatibility with v1beta1.MsgSubmitProposal. -message MsgExecLegacyContent { - option (cosmos.msg.v1.signer) = "authority"; - - // content is the proposal's content. - google.protobuf.Any content = 1 [(cosmos_proto.accepts_interface) = "Content"]; - // authority must be the gov module address. - string authority = 2; -} - -// MsgExecLegacyContentResponse defines the Msg/ExecLegacyContent response type. -message MsgExecLegacyContentResponse {} - -// MsgVote defines a message to cast a vote. -message MsgVote { - option (cosmos.msg.v1.signer) = "voter"; - - uint64 proposal_id = 1 [(gogoproto.jsontag) = "proposal_id"]; - string voter = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - VoteOption option = 3; - string metadata = 4; -} - -// MsgVoteResponse defines the Msg/Vote response type. -message MsgVoteResponse {} - -// MsgVoteWeighted defines a message to cast a vote. -message MsgVoteWeighted { - option (cosmos.msg.v1.signer) = "voter"; - - uint64 proposal_id = 1 [(gogoproto.jsontag) = "proposal_id"]; - string voter = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - repeated WeightedVoteOption options = 3; - string metadata = 4; -} - -// MsgVoteWeightedResponse defines the Msg/VoteWeighted response type. -message MsgVoteWeightedResponse {} - -// MsgDeposit defines a message to submit a deposit to an existing proposal. -message MsgDeposit { - option (cosmos.msg.v1.signer) = "depositor"; - - uint64 proposal_id = 1 [(gogoproto.jsontag) = "proposal_id"]; - string depositor = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - repeated cosmos.base.v1beta1.Coin amount = 3 [(gogoproto.nullable) = false]; -} - -// MsgDepositResponse defines the Msg/Deposit response type. -message MsgDepositResponse {} diff --git a/src/cosmospy_protobuf/cosmos/gov/v1beta1/genesis.proto b/src/cosmospy_protobuf/cosmos/gov/v1beta1/genesis.proto deleted file mode 100644 index be9b07e4..00000000 --- a/src/cosmospy_protobuf/cosmos/gov/v1beta1/genesis.proto +++ /dev/null @@ -1,26 +0,0 @@ -syntax = "proto3"; - -package cosmos.gov.v1beta1; - -import "gogoproto/gogo.proto"; -import "cosmos/gov/v1beta1/gov.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1"; - -// GenesisState defines the gov module's genesis state. -message GenesisState { - // starting_proposal_id is the ID of the starting proposal. - uint64 starting_proposal_id = 1; - // deposits defines all the deposits present at genesis. - repeated Deposit deposits = 2 [(gogoproto.castrepeated) = "Deposits", (gogoproto.nullable) = false]; - // votes defines all the votes present at genesis. - repeated Vote votes = 3 [(gogoproto.castrepeated) = "Votes", (gogoproto.nullable) = false]; - // proposals defines all the proposals present at genesis. - repeated Proposal proposals = 4 [(gogoproto.castrepeated) = "Proposals", (gogoproto.nullable) = false]; - // params defines all the paramaters of related to deposit. - DepositParams deposit_params = 5 [(gogoproto.nullable) = false]; - // params defines all the paramaters of related to voting. - VotingParams voting_params = 6 [(gogoproto.nullable) = false]; - // params defines all the paramaters of related to tally. - TallyParams tally_params = 7 [(gogoproto.nullable) = false]; -} diff --git a/src/cosmospy_protobuf/cosmos/gov/v1beta1/gov.proto b/src/cosmospy_protobuf/cosmos/gov/v1beta1/gov.proto deleted file mode 100644 index 0e65d65b..00000000 --- a/src/cosmospy_protobuf/cosmos/gov/v1beta1/gov.proto +++ /dev/null @@ -1,201 +0,0 @@ -syntax = "proto3"; -package cosmos.gov.v1beta1; - -import "cosmos/base/v1beta1/coin.proto"; -import "gogoproto/gogo.proto"; -import "google/protobuf/timestamp.proto"; -import "google/protobuf/any.proto"; -import "google/protobuf/duration.proto"; -import "cosmos_proto/cosmos.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1"; - -option (gogoproto.goproto_stringer_all) = false; -option (gogoproto.stringer_all) = false; -option (gogoproto.goproto_getters_all) = false; - -// VoteOption enumerates the valid vote options for a given governance proposal. -enum VoteOption { - option (gogoproto.goproto_enum_prefix) = false; - - // VOTE_OPTION_UNSPECIFIED defines a no-op vote option. - VOTE_OPTION_UNSPECIFIED = 0 [(gogoproto.enumvalue_customname) = "OptionEmpty"]; - // VOTE_OPTION_YES defines a yes vote option. - VOTE_OPTION_YES = 1 [(gogoproto.enumvalue_customname) = "OptionYes"]; - // VOTE_OPTION_ABSTAIN defines an abstain vote option. - VOTE_OPTION_ABSTAIN = 2 [(gogoproto.enumvalue_customname) = "OptionAbstain"]; - // VOTE_OPTION_NO defines a no vote option. - VOTE_OPTION_NO = 3 [(gogoproto.enumvalue_customname) = "OptionNo"]; - // VOTE_OPTION_NO_WITH_VETO defines a no with veto vote option. - VOTE_OPTION_NO_WITH_VETO = 4 [(gogoproto.enumvalue_customname) = "OptionNoWithVeto"]; -} - -// WeightedVoteOption defines a unit of vote for vote split. -// -// Since: cosmos-sdk 0.43 -message WeightedVoteOption { - VoteOption option = 1; - string weight = 2 [ - (cosmos_proto.scalar) = "cosmos.Dec", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false - ]; -} - -// TextProposal defines a standard text proposal whose changes need to be -// manually updated in case of approval. -message TextProposal { - option (cosmos_proto.implements_interface) = "Content"; - - option (gogoproto.equal) = true; - - string title = 1; - string description = 2; -} - -// Deposit defines an amount deposited by an account address to an active -// proposal. -message Deposit { - option (gogoproto.goproto_getters) = false; - option (gogoproto.equal) = false; - - uint64 proposal_id = 1; - string depositor = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - repeated cosmos.base.v1beta1.Coin amount = 3 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; -} - -// Proposal defines the core field members of a governance proposal. -message Proposal { - option (gogoproto.equal) = true; - - uint64 proposal_id = 1; - google.protobuf.Any content = 2 [(cosmos_proto.accepts_interface) = "Content"]; - ProposalStatus status = 3; - // 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. - TallyResult final_tally_result = 4 [(gogoproto.nullable) = false]; - google.protobuf.Timestamp submit_time = 5 [(gogoproto.stdtime) = true, (gogoproto.nullable) = false]; - google.protobuf.Timestamp deposit_end_time = 6 [(gogoproto.stdtime) = true, (gogoproto.nullable) = false]; - repeated cosmos.base.v1beta1.Coin total_deposit = 7 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; - google.protobuf.Timestamp voting_start_time = 8 [(gogoproto.stdtime) = true, (gogoproto.nullable) = false]; - google.protobuf.Timestamp voting_end_time = 9 [(gogoproto.stdtime) = true, (gogoproto.nullable) = false]; -} - -// ProposalStatus enumerates the valid statuses of a proposal. -enum ProposalStatus { - option (gogoproto.goproto_enum_prefix) = false; - - // PROPOSAL_STATUS_UNSPECIFIED defines the default proposal status. - PROPOSAL_STATUS_UNSPECIFIED = 0 [(gogoproto.enumvalue_customname) = "StatusNil"]; - // PROPOSAL_STATUS_DEPOSIT_PERIOD defines a proposal status during the deposit - // period. - PROPOSAL_STATUS_DEPOSIT_PERIOD = 1 [(gogoproto.enumvalue_customname) = "StatusDepositPeriod"]; - // PROPOSAL_STATUS_VOTING_PERIOD defines a proposal status during the voting - // period. - PROPOSAL_STATUS_VOTING_PERIOD = 2 [(gogoproto.enumvalue_customname) = "StatusVotingPeriod"]; - // PROPOSAL_STATUS_PASSED defines a proposal status of a proposal that has - // passed. - PROPOSAL_STATUS_PASSED = 3 [(gogoproto.enumvalue_customname) = "StatusPassed"]; - // PROPOSAL_STATUS_REJECTED defines a proposal status of a proposal that has - // been rejected. - PROPOSAL_STATUS_REJECTED = 4 [(gogoproto.enumvalue_customname) = "StatusRejected"]; - // PROPOSAL_STATUS_FAILED defines a proposal status of a proposal that has - // failed. - PROPOSAL_STATUS_FAILED = 5 [(gogoproto.enumvalue_customname) = "StatusFailed"]; -} - -// TallyResult defines a standard tally for a governance proposal. -message TallyResult { - option (gogoproto.equal) = true; - - string yes = 1 [ - (cosmos_proto.scalar) = "cosmos.Int", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.nullable) = false - ]; - string abstain = 2 [ - (cosmos_proto.scalar) = "cosmos.Int", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.nullable) = false - ]; - string no = 3 [ - (cosmos_proto.scalar) = "cosmos.Int", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.nullable) = false - ]; - string no_with_veto = 4 [ - (cosmos_proto.scalar) = "cosmos.Int", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.nullable) = false - ]; -} - -// Vote defines a vote on a governance proposal. -// A Vote consists of a proposal ID, the voter, and the vote option. -message Vote { - option (gogoproto.goproto_stringer) = false; - option (gogoproto.equal) = false; - - uint64 proposal_id = 1 [(gogoproto.jsontag) = "id"]; - string voter = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - // 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. - VoteOption option = 3 [deprecated = true]; - // Since: cosmos-sdk 0.43 - repeated WeightedVoteOption options = 4 [(gogoproto.nullable) = false]; -} - -// DepositParams defines the params for deposits on governance proposals. -message DepositParams { - // Minimum deposit for a proposal to enter voting period. - repeated cosmos.base.v1beta1.Coin min_deposit = 1 [ - (gogoproto.nullable) = false, - (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins", - (gogoproto.jsontag) = "min_deposit,omitempty" - ]; - - // Maximum period for Atom holders to deposit on a proposal. Initial value: 2 - // months. - google.protobuf.Duration max_deposit_period = 2 [ - (gogoproto.nullable) = false, - (gogoproto.stdduration) = true, - (gogoproto.jsontag) = "max_deposit_period,omitempty" - ]; -} - -// VotingParams defines the params for voting on governance proposals. -message VotingParams { - // Length of the voting period. - google.protobuf.Duration voting_period = 1 - [(gogoproto.nullable) = false, (gogoproto.stdduration) = true, (gogoproto.jsontag) = "voting_period,omitempty"]; -} - -// TallyParams defines the params for tallying votes on governance proposals. -message TallyParams { - // Minimum percentage of total stake needed to vote for a result to be - // considered valid. - bytes quorum = 1 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "quorum,omitempty" - ]; - - // Minimum proportion of Yes votes for proposal to pass. Default value: 0.5. - bytes threshold = 2 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "threshold,omitempty" - ]; - - // Minimum value of Veto votes to Total votes ratio for proposal to be - // vetoed. Default value: 1/3. - bytes veto_threshold = 3 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "veto_threshold,omitempty" - ]; -} diff --git a/src/cosmospy_protobuf/cosmos/gov/v1beta1/query.proto b/src/cosmospy_protobuf/cosmos/gov/v1beta1/query.proto deleted file mode 100644 index 168e1f5e..00000000 --- a/src/cosmospy_protobuf/cosmos/gov/v1beta1/query.proto +++ /dev/null @@ -1,191 +0,0 @@ -syntax = "proto3"; -package cosmos.gov.v1beta1; - -import "cosmos/base/query/v1beta1/pagination.proto"; -import "gogoproto/gogo.proto"; -import "google/api/annotations.proto"; -import "cosmos/gov/v1beta1/gov.proto"; -import "cosmos_proto/cosmos.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1"; - -// Query defines the gRPC querier service for gov module -service Query { - // Proposal queries proposal details based on ProposalID. - rpc Proposal(QueryProposalRequest) returns (QueryProposalResponse) { - option (google.api.http).get = "/cosmos/gov/v1beta1/proposals/{proposal_id}"; - } - - // Proposals queries all proposals based on given status. - rpc Proposals(QueryProposalsRequest) returns (QueryProposalsResponse) { - option (google.api.http).get = "/cosmos/gov/v1beta1/proposals"; - } - - // Vote queries voted information based on proposalID, voterAddr. - rpc Vote(QueryVoteRequest) returns (QueryVoteResponse) { - option (google.api.http).get = "/cosmos/gov/v1beta1/proposals/{proposal_id}/votes/{voter}"; - } - - // Votes queries votes of a given proposal. - rpc Votes(QueryVotesRequest) returns (QueryVotesResponse) { - option (google.api.http).get = "/cosmos/gov/v1beta1/proposals/{proposal_id}/votes"; - } - - // Params queries all parameters of the gov module. - rpc Params(QueryParamsRequest) returns (QueryParamsResponse) { - option (google.api.http).get = "/cosmos/gov/v1beta1/params/{params_type}"; - } - - // Deposit queries single deposit information based proposalID, depositAddr. - rpc Deposit(QueryDepositRequest) returns (QueryDepositResponse) { - option (google.api.http).get = "/cosmos/gov/v1beta1/proposals/{proposal_id}/deposits/{depositor}"; - } - - // Deposits queries all deposits of a single proposal. - rpc Deposits(QueryDepositsRequest) returns (QueryDepositsResponse) { - option (google.api.http).get = "/cosmos/gov/v1beta1/proposals/{proposal_id}/deposits"; - } - - // TallyResult queries the tally of a proposal vote. - rpc TallyResult(QueryTallyResultRequest) returns (QueryTallyResultResponse) { - option (google.api.http).get = "/cosmos/gov/v1beta1/proposals/{proposal_id}/tally"; - } -} - -// QueryProposalRequest is the request type for the Query/Proposal RPC method. -message QueryProposalRequest { - // proposal_id defines the unique id of the proposal. - uint64 proposal_id = 1; -} - -// QueryProposalResponse is the response type for the Query/Proposal RPC method. -message QueryProposalResponse { - Proposal proposal = 1 [(gogoproto.nullable) = false]; -} - -// QueryProposalsRequest is the request type for the Query/Proposals RPC method. -message QueryProposalsRequest { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // proposal_status defines the status of the proposals. - ProposalStatus proposal_status = 1; - - // voter defines the voter address for the proposals. - string voter = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // depositor defines the deposit addresses from the proposals. - string depositor = 3 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // pagination defines an optional pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 4; -} - -// QueryProposalsResponse is the response type for the Query/Proposals RPC -// method. -message QueryProposalsResponse { - repeated Proposal proposals = 1 [(gogoproto.nullable) = false]; - - // pagination defines the pagination in the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryVoteRequest is the request type for the Query/Vote RPC method. -message QueryVoteRequest { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // proposal_id defines the unique id of the proposal. - uint64 proposal_id = 1; - - // voter defines the voter address for the proposals. - string voter = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// QueryVoteResponse is the response type for the Query/Vote RPC method. -message QueryVoteResponse { - // vote defined the queried vote. - Vote vote = 1 [(gogoproto.nullable) = false]; -} - -// QueryVotesRequest is the request type for the Query/Votes RPC method. -message QueryVotesRequest { - // proposal_id defines the unique id of the proposal. - uint64 proposal_id = 1; - - // pagination defines an optional pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} - -// QueryVotesResponse is the response type for the Query/Votes RPC method. -message QueryVotesResponse { - // votes defined the queried votes. - repeated Vote votes = 1 [(gogoproto.nullable) = false]; - - // pagination defines the pagination in the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryParamsRequest is the request type for the Query/Params RPC method. -message QueryParamsRequest { - // params_type defines which parameters to query for, can be one of "voting", - // "tallying" or "deposit". - string params_type = 1; -} - -// QueryParamsResponse is the response type for the Query/Params RPC method. -message QueryParamsResponse { - // voting_params defines the parameters related to voting. - VotingParams voting_params = 1 [(gogoproto.nullable) = false]; - // deposit_params defines the parameters related to deposit. - DepositParams deposit_params = 2 [(gogoproto.nullable) = false]; - // tally_params defines the parameters related to tally. - TallyParams tally_params = 3 [(gogoproto.nullable) = false]; -} - -// QueryDepositRequest is the request type for the Query/Deposit RPC method. -message QueryDepositRequest { - option (gogoproto.goproto_getters) = false; - option (gogoproto.equal) = false; - - // proposal_id defines the unique id of the proposal. - uint64 proposal_id = 1; - - // depositor defines the deposit addresses from the proposals. - string depositor = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// QueryDepositResponse is the response type for the Query/Deposit RPC method. -message QueryDepositResponse { - // deposit defines the requested deposit. - Deposit deposit = 1 [(gogoproto.nullable) = false]; -} - -// QueryDepositsRequest is the request type for the Query/Deposits RPC method. -message QueryDepositsRequest { - // proposal_id defines the unique id of the proposal. - uint64 proposal_id = 1; - - // pagination defines an optional pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} - -// QueryDepositsResponse is the response type for the Query/Deposits RPC method. -message QueryDepositsResponse { - repeated Deposit deposits = 1 [(gogoproto.nullable) = false]; - - // pagination defines the pagination in the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryTallyResultRequest is the request type for the Query/Tally RPC method. -message QueryTallyResultRequest { - // proposal_id defines the unique id of the proposal. - uint64 proposal_id = 1; -} - -// QueryTallyResultResponse is the response type for the Query/Tally RPC method. -message QueryTallyResultResponse { - // tally defines the requested tally. - TallyResult tally = 1 [(gogoproto.nullable) = false]; -} diff --git a/src/cosmospy_protobuf/cosmos/gov/v1beta1/tx.proto b/src/cosmospy_protobuf/cosmos/gov/v1beta1/tx.proto deleted file mode 100644 index 00ce2253..00000000 --- a/src/cosmospy_protobuf/cosmos/gov/v1beta1/tx.proto +++ /dev/null @@ -1,106 +0,0 @@ -syntax = "proto3"; -package cosmos.gov.v1beta1; - -import "cosmos/base/v1beta1/coin.proto"; -import "cosmos/gov/v1beta1/gov.proto"; -import "cosmos_proto/cosmos.proto"; -import "gogoproto/gogo.proto"; -import "google/protobuf/any.proto"; - -import "cosmos/msg/v1/msg.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/gov/types/v1beta1"; - -// Msg defines the bank Msg service. -service Msg { - // SubmitProposal defines a method to create new proposal given a content. - rpc SubmitProposal(MsgSubmitProposal) returns (MsgSubmitProposalResponse); - - // Vote defines a method to add a vote on a specific proposal. - rpc Vote(MsgVote) returns (MsgVoteResponse); - - // VoteWeighted defines a method to add a weighted vote on a specific proposal. - // - // Since: cosmos-sdk 0.43 - rpc VoteWeighted(MsgVoteWeighted) returns (MsgVoteWeightedResponse); - - // Deposit defines a method to add deposit on a specific proposal. - rpc Deposit(MsgDeposit) returns (MsgDepositResponse); -} - -// MsgSubmitProposal defines an sdk.Msg type that supports submitting arbitrary -// proposal Content. -message MsgSubmitProposal { - option (cosmos.msg.v1.signer) = "proposer"; - - option (gogoproto.equal) = false; - option (gogoproto.goproto_stringer) = false; - option (gogoproto.stringer) = false; - option (gogoproto.goproto_getters) = false; - - google.protobuf.Any content = 1 [(cosmos_proto.accepts_interface) = "Content"]; - repeated cosmos.base.v1beta1.Coin initial_deposit = 2 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; - string proposer = 3 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// MsgSubmitProposalResponse defines the Msg/SubmitProposal response type. -message MsgSubmitProposalResponse { - uint64 proposal_id = 1 [(gogoproto.jsontag) = "proposal_id"]; -} - -// MsgVote defines a message to cast a vote. -message MsgVote { - option (cosmos.msg.v1.signer) = "voter"; - - option (gogoproto.equal) = false; - option (gogoproto.goproto_stringer) = false; - option (gogoproto.stringer) = false; - option (gogoproto.goproto_getters) = false; - - uint64 proposal_id = 1; - string voter = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - VoteOption option = 3; -} - -// MsgVoteResponse defines the Msg/Vote response type. -message MsgVoteResponse {} - -// MsgVoteWeighted defines a message to cast a vote. -// -// Since: cosmos-sdk 0.43 -message MsgVoteWeighted { - option (cosmos.msg.v1.signer) = "voter"; - - option (gogoproto.equal) = false; - option (gogoproto.goproto_stringer) = false; - option (gogoproto.stringer) = false; - option (gogoproto.goproto_getters) = false; - - uint64 proposal_id = 1 [(gogoproto.jsontag) = "proposal_id"]; - string voter = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - repeated WeightedVoteOption options = 3 [(gogoproto.nullable) = false]; -} - -// MsgVoteWeightedResponse defines the Msg/VoteWeighted response type. -// -// Since: cosmos-sdk 0.43 -message MsgVoteWeightedResponse {} - -// MsgDeposit defines a message to submit a deposit to an existing proposal. -message MsgDeposit { - option (cosmos.msg.v1.signer) = "depositor"; - - option (gogoproto.equal) = false; - option (gogoproto.goproto_stringer) = false; - option (gogoproto.stringer) = false; - option (gogoproto.goproto_getters) = false; - - uint64 proposal_id = 1 [(gogoproto.jsontag) = "proposal_id"]; - string depositor = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - repeated cosmos.base.v1beta1.Coin amount = 3 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; -} - -// MsgDepositResponse defines the Msg/Deposit response type. -message MsgDepositResponse {} diff --git a/src/cosmospy_protobuf/cosmos/group/v1/events.proto b/src/cosmospy_protobuf/cosmos/group/v1/events.proto deleted file mode 100644 index c2cfe872..00000000 --- a/src/cosmospy_protobuf/cosmos/group/v1/events.proto +++ /dev/null @@ -1,81 +0,0 @@ -// Since: cosmos-sdk 0.46 -syntax = "proto3"; - -package cosmos.group.v1; - -import "cosmos_proto/cosmos.proto"; -import "cosmos/group/v1/types.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/group"; - -// EventCreateGroup is an event emitted when a group is created. -message EventCreateGroup { - - // group_id is the unique ID of the group. - uint64 group_id = 1; -} - -// EventUpdateGroup is an event emitted when a group is updated. -message EventUpdateGroup { - - // group_id is the unique ID of the group. - uint64 group_id = 1; -} - -// EventCreateGroupPolicy is an event emitted when a group policy is created. -message EventCreateGroupPolicy { - - // address is the account address of the group policy. - string address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// EventUpdateGroupPolicy is an event emitted when a group policy is updated. -message EventUpdateGroupPolicy { - - // address is the account address of the group policy. - string address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// EventSubmitProposal is an event emitted when a proposal is created. -message EventSubmitProposal { - - // proposal_id is the unique ID of the proposal. - uint64 proposal_id = 1; -} - -// EventWithdrawProposal is an event emitted when a proposal is withdrawn. -message EventWithdrawProposal { - - // proposal_id is the unique ID of the proposal. - uint64 proposal_id = 1; -} - -// EventVote is an event emitted when a voter votes on a proposal. -message EventVote { - - // proposal_id is the unique ID of the proposal. - uint64 proposal_id = 1; -} - -// EventExec is an event emitted when a proposal is executed. -message EventExec { - - // proposal_id is the unique ID of the proposal. - uint64 proposal_id = 1; - - // result is the proposal execution result. - ProposalExecutorResult result = 2; - - // logs contains error logs in case the execution result is FAILURE. - string logs = 3; -} - -// EventLeaveGroup is an event emitted when group member leaves the group. -message EventLeaveGroup { - - // group_id is the unique ID of the group. - uint64 group_id = 1; - - // address is the account address of the group member. - string address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} diff --git a/src/cosmospy_protobuf/cosmos/group/v1/genesis.proto b/src/cosmospy_protobuf/cosmos/group/v1/genesis.proto deleted file mode 100644 index e4c895e9..00000000 --- a/src/cosmospy_protobuf/cosmos/group/v1/genesis.proto +++ /dev/null @@ -1,39 +0,0 @@ -// Since: cosmos-sdk 0.46 -syntax = "proto3"; - -package cosmos.group.v1; - -option go_package = "github.com/cosmos/cosmos-sdk/x/group"; - -import "cosmos/group/v1/types.proto"; - -// GenesisState defines the group module's genesis state. -message GenesisState { - - // group_seq is the group table orm.Sequence, - // it is used to get the next group ID. - uint64 group_seq = 1; - - // groups is the list of groups info. - repeated GroupInfo groups = 2; - - // group_members is the list of groups members. - repeated GroupMember group_members = 3; - - // group_policy_seq is the group policy table orm.Sequence, - // it is used to generate the next group policy account address. - uint64 group_policy_seq = 4; - - // group_policies is the list of group policies info. - repeated GroupPolicyInfo group_policies = 5; - - // proposal_seq is the proposal table orm.Sequence, - // it is used to get the next proposal ID. - uint64 proposal_seq = 6; - - // proposals is the list of proposals. - repeated Proposal proposals = 7; - - // votes is the list of votes. - repeated Vote votes = 8; -} \ No newline at end of file diff --git a/src/cosmospy_protobuf/cosmos/group/v1/query.proto b/src/cosmospy_protobuf/cosmos/group/v1/query.proto deleted file mode 100644 index 51a011a9..00000000 --- a/src/cosmospy_protobuf/cosmos/group/v1/query.proto +++ /dev/null @@ -1,313 +0,0 @@ -// Since: cosmos-sdk 0.46 -syntax = "proto3"; - -package cosmos.group.v1; - -import "gogoproto/gogo.proto"; -import "google/api/annotations.proto"; -import "cosmos/group/v1/types.proto"; -import "cosmos/base/query/v1beta1/pagination.proto"; -import "cosmos_proto/cosmos.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/group"; - -// Query is the cosmos.group.v1 Query service. -service Query { - - // GroupInfo queries group info based on group id. - rpc GroupInfo(QueryGroupInfoRequest) returns (QueryGroupInfoResponse) { - option (google.api.http).get = "/cosmos/group/v1/group_info/{group_id}"; - }; - - // GroupPolicyInfo queries group policy info based on account address of group policy. - rpc GroupPolicyInfo(QueryGroupPolicyInfoRequest) returns (QueryGroupPolicyInfoResponse) { - option (google.api.http).get = "/cosmos/group/v1/group_policy_info/{address}"; - }; - - // GroupMembers queries members of a group - rpc GroupMembers(QueryGroupMembersRequest) returns (QueryGroupMembersResponse) { - option (google.api.http).get = "/cosmos/group/v1/group_members/{group_id}"; - }; - - // GroupsByAdmin queries groups by admin address. - rpc GroupsByAdmin(QueryGroupsByAdminRequest) returns (QueryGroupsByAdminResponse) { - option (google.api.http).get = "/cosmos/group/v1/groups_by_admin/{admin}"; - }; - - // GroupPoliciesByGroup queries group policies by group id. - rpc GroupPoliciesByGroup(QueryGroupPoliciesByGroupRequest) returns (QueryGroupPoliciesByGroupResponse) { - option (google.api.http).get = "/cosmos/group/v1/group_policies_by_group/{group_id}"; - }; - - // GroupsByAdmin queries group policies by admin address. - rpc GroupPoliciesByAdmin(QueryGroupPoliciesByAdminRequest) returns (QueryGroupPoliciesByAdminResponse) { - option (google.api.http).get = "/cosmos/group/v1/group_policies_by_admin/{admin}"; - }; - - // Proposal queries a proposal based on proposal id. - rpc Proposal(QueryProposalRequest) returns (QueryProposalResponse) { - option (google.api.http).get = "/cosmos/group/v1/proposal/{proposal_id}"; - }; - - // ProposalsByGroupPolicy queries proposals based on account address of group policy. - rpc ProposalsByGroupPolicy(QueryProposalsByGroupPolicyRequest) returns (QueryProposalsByGroupPolicyResponse) { - option (google.api.http).get = "/cosmos/group/v1/proposals_by_group_policy/{address}"; - }; - - // VoteByProposalVoter queries a vote by proposal id and voter. - rpc VoteByProposalVoter(QueryVoteByProposalVoterRequest) returns (QueryVoteByProposalVoterResponse) { - option (google.api.http).get = "/cosmos/group/v1/vote_by_proposal_voter/{proposal_id}/{voter}"; - }; - - // VotesByProposal queries a vote by proposal. - rpc VotesByProposal(QueryVotesByProposalRequest) returns (QueryVotesByProposalResponse) { - option (google.api.http).get = "/cosmos/group/v1/votes_by_proposal/{proposal_id}"; - }; - - // VotesByVoter queries a vote by voter. - rpc VotesByVoter(QueryVotesByVoterRequest) returns (QueryVotesByVoterResponse) { - option (google.api.http).get = "/cosmos/group/v1/votes_by_voter/{voter}"; - }; - - // GroupsByMember queries groups by member address. - rpc GroupsByMember(QueryGroupsByMemberRequest) returns (QueryGroupsByMemberResponse) { - option (google.api.http).get = "/cosmos/group/v1/groups_by_member/{address}"; - }; - - // TallyResult returns the tally result of a proposal. If the proposal is - // still in voting period, then this query computes the current tally state, - // which might not be final. On the other hand, if the proposal is final, - // then it simply returns the `final_tally_result` state stored in the - // proposal itself. - rpc TallyResult(QueryTallyResultRequest) returns (QueryTallyResultResponse) { - option (google.api.http).get = "/cosmos/group/v1/proposals/{proposal_id}/tally"; - }; -} - -// QueryGroupInfoRequest is the Query/GroupInfo request type. -message QueryGroupInfoRequest { - - // group_id is the unique ID of the group. - uint64 group_id = 1; -} - -// QueryGroupInfoResponse is the Query/GroupInfo response type. -message QueryGroupInfoResponse { - - // info is the GroupInfo for the group. - GroupInfo info = 1; -} - -// QueryGroupPolicyInfoRequest is the Query/GroupPolicyInfo request type. -message QueryGroupPolicyInfoRequest { - - // address is the account address of the group policy. - string address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// QueryGroupPolicyInfoResponse is the Query/GroupPolicyInfo response type. -message QueryGroupPolicyInfoResponse { - - // info is the GroupPolicyInfo for the group policy. - GroupPolicyInfo info = 1; -} - -// QueryGroupMembersRequest is the Query/GroupMembers request type. -message QueryGroupMembersRequest { - - // group_id is the unique ID of the group. - uint64 group_id = 1; - - // pagination defines an optional pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} - -// QueryGroupMembersResponse is the Query/GroupMembersResponse response type. -message QueryGroupMembersResponse { - - // members are the members of the group with given group_id. - repeated GroupMember members = 1; - - // pagination defines the pagination in the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryGroupsByAdminRequest is the Query/GroupsByAdmin request type. -message QueryGroupsByAdminRequest { - - // admin is the account address of a group's admin. - string admin = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // pagination defines an optional pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} - -// QueryGroupsByAdminResponse is the Query/GroupsByAdminResponse response type. -message QueryGroupsByAdminResponse { - - // groups are the groups info with the provided admin. - repeated GroupInfo groups = 1; - - // pagination defines the pagination in the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryGroupPoliciesByGroupRequest is the Query/GroupPoliciesByGroup request type. -message QueryGroupPoliciesByGroupRequest { - - // group_id is the unique ID of the group policy's group. - uint64 group_id = 1; - - // pagination defines an optional pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} - -// QueryGroupPoliciesByGroupResponse is the Query/GroupPoliciesByGroup response type. -message QueryGroupPoliciesByGroupResponse { - - // group_policies are the group policies info associated with the provided group. - repeated GroupPolicyInfo group_policies = 1; - - // pagination defines the pagination in the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryGroupPoliciesByAdminRequest is the Query/GroupPoliciesByAdmin request type. -message QueryGroupPoliciesByAdminRequest { - - // admin is the admin address of the group policy. - string admin = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // pagination defines an optional pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} - -// QueryGroupPoliciesByAdminResponse is the Query/GroupPoliciesByAdmin response type. -message QueryGroupPoliciesByAdminResponse { - - // group_policies are the group policies info with provided admin. - repeated GroupPolicyInfo group_policies = 1; - - // pagination defines the pagination in the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryProposalRequest is the Query/Proposal request type. -message QueryProposalRequest { - - // proposal_id is the unique ID of a proposal. - uint64 proposal_id = 1; -} - -// QueryProposalResponse is the Query/Proposal response type. -message QueryProposalResponse { - - // proposal is the proposal info. - Proposal proposal = 1; -} - -// QueryProposalsByGroupPolicyRequest is the Query/ProposalByGroupPolicy request type. -message QueryProposalsByGroupPolicyRequest { - - // address is the account address of the group policy related to proposals. - string address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // pagination defines an optional pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} - -// QueryProposalsByGroupPolicyResponse is the Query/ProposalByGroupPolicy response type. -message QueryProposalsByGroupPolicyResponse { - - // proposals are the proposals with given group policy. - repeated Proposal proposals = 1; - - // pagination defines the pagination in the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryVoteByProposalVoterRequest is the Query/VoteByProposalVoter request type. -message QueryVoteByProposalVoterRequest { - - // proposal_id is the unique ID of a proposal. - uint64 proposal_id = 1; - - // voter is a proposal voter account address. - string voter = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// QueryVoteByProposalVoterResponse is the Query/VoteByProposalVoter response type. -message QueryVoteByProposalVoterResponse { - - // vote is the vote with given proposal_id and voter. - Vote vote = 1; -} - -// QueryVotesByProposalRequest is the Query/VotesByProposal request type. -message QueryVotesByProposalRequest { - - // proposal_id is the unique ID of a proposal. - uint64 proposal_id = 1; - - // pagination defines an optional pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} - -// QueryVotesByProposalResponse is the Query/VotesByProposal response type. -message QueryVotesByProposalResponse { - - // votes are the list of votes for given proposal_id. - repeated Vote votes = 1; - - // pagination defines the pagination in the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryVotesByVoterRequest is the Query/VotesByVoter request type. -message QueryVotesByVoterRequest { - // voter is a proposal voter account address. - string voter = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // pagination defines an optional pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} - -// QueryVotesByVoterResponse is the Query/VotesByVoter response type. -message QueryVotesByVoterResponse { - - // votes are the list of votes by given voter. - repeated Vote votes = 1; - - // pagination defines the pagination in the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryGroupsByMemberRequest is the Query/GroupsByMember request type. -message QueryGroupsByMemberRequest { - // address is the group member address. - string address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // pagination defines an optional pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} - -// QueryGroupsByMemberResponse is the Query/GroupsByMember response type. -message QueryGroupsByMemberResponse { - // groups are the groups info with the provided group member. - repeated GroupInfo groups = 1; - - // pagination defines the pagination in the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryTallyResultRequest is the Query/TallyResult request type. -message QueryTallyResultRequest { - // proposal_id is the unique id of a proposal. - uint64 proposal_id = 1; -} - -// QueryTallyResultResponse is the Query/TallyResult response type. -message QueryTallyResultResponse { - // tally defines the requested tally. - TallyResult tally = 1 [(gogoproto.nullable) = false]; -} diff --git a/src/cosmospy_protobuf/cosmos/group/v1/tx.proto b/src/cosmospy_protobuf/cosmos/group/v1/tx.proto deleted file mode 100644 index 1983d31b..00000000 --- a/src/cosmospy_protobuf/cosmos/group/v1/tx.proto +++ /dev/null @@ -1,373 +0,0 @@ -// Since: cosmos-sdk 0.46 -syntax = "proto3"; - -package cosmos.group.v1; - -option go_package = "github.com/cosmos/cosmos-sdk/x/group"; - -import "gogoproto/gogo.proto"; -import "cosmos_proto/cosmos.proto"; -import "google/protobuf/any.proto"; -import "cosmos/group/v1/types.proto"; - -import "cosmos/msg/v1/msg.proto"; - -// Msg is the cosmos.group.v1 Msg service. -service Msg { - - // CreateGroup creates a new group with an admin account address, a list of members and some optional metadata. - rpc CreateGroup(MsgCreateGroup) returns (MsgCreateGroupResponse); - - // UpdateGroupMembers updates the group members with given group id and admin address. - rpc UpdateGroupMembers(MsgUpdateGroupMembers) returns (MsgUpdateGroupMembersResponse); - - // UpdateGroupAdmin updates the group admin with given group id and previous admin address. - rpc UpdateGroupAdmin(MsgUpdateGroupAdmin) returns (MsgUpdateGroupAdminResponse); - - // UpdateGroupMetadata updates the group metadata with given group id and admin address. - rpc UpdateGroupMetadata(MsgUpdateGroupMetadata) returns (MsgUpdateGroupMetadataResponse); - - // CreateGroupPolicy creates a new group policy using given DecisionPolicy. - rpc CreateGroupPolicy(MsgCreateGroupPolicy) returns (MsgCreateGroupPolicyResponse); - - // CreateGroupWithPolicy creates a new group with policy. - rpc CreateGroupWithPolicy(MsgCreateGroupWithPolicy) returns (MsgCreateGroupWithPolicyResponse); - - // UpdateGroupPolicyAdmin updates a group policy admin. - rpc UpdateGroupPolicyAdmin(MsgUpdateGroupPolicyAdmin) returns (MsgUpdateGroupPolicyAdminResponse); - - // UpdateGroupPolicyDecisionPolicy allows a group policy's decision policy to be updated. - rpc UpdateGroupPolicyDecisionPolicy(MsgUpdateGroupPolicyDecisionPolicy) - returns (MsgUpdateGroupPolicyDecisionPolicyResponse); - - // UpdateGroupPolicyMetadata updates a group policy metadata. - rpc UpdateGroupPolicyMetadata(MsgUpdateGroupPolicyMetadata) returns (MsgUpdateGroupPolicyMetadataResponse); - - // SubmitProposal submits a new proposal. - rpc SubmitProposal(MsgSubmitProposal) returns (MsgSubmitProposalResponse); - - // WithdrawProposal withdraws a proposal. - rpc WithdrawProposal(MsgWithdrawProposal) returns (MsgWithdrawProposalResponse); - - // Vote allows a voter to vote on a proposal. - rpc Vote(MsgVote) returns (MsgVoteResponse); - - // Exec executes a proposal. - rpc Exec(MsgExec) returns (MsgExecResponse); - - // LeaveGroup allows a group member to leave the group. - rpc LeaveGroup(MsgLeaveGroup) returns (MsgLeaveGroupResponse); -} - -// -// Groups -// - -// MsgCreateGroup is the Msg/CreateGroup request type. -message MsgCreateGroup { - option (cosmos.msg.v1.signer) = "admin"; - - // admin is the account address of the group admin. - string admin = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // members defines the group members. - repeated MemberRequest members = 2 [(gogoproto.nullable) = false]; - - // metadata is any arbitrary metadata to attached to the group. - string metadata = 3; -} - -// MsgCreateGroupResponse is the Msg/CreateGroup response type. -message MsgCreateGroupResponse { - - // group_id is the unique ID of the newly created group. - uint64 group_id = 1; -} - -// MsgUpdateGroupMembers is the Msg/UpdateGroupMembers request type. -message MsgUpdateGroupMembers { - option (cosmos.msg.v1.signer) = "admin"; - - // admin is the account address of the group admin. - string admin = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // group_id is the unique ID of the group. - uint64 group_id = 2; - - // member_updates is the list of members to update, - // set weight to 0 to remove a member. - repeated MemberRequest member_updates = 3 [(gogoproto.nullable) = false]; -} - -// MsgUpdateGroupMembersResponse is the Msg/UpdateGroupMembers response type. -message MsgUpdateGroupMembersResponse {} - -// MsgUpdateGroupAdmin is the Msg/UpdateGroupAdmin request type. -message MsgUpdateGroupAdmin { - option (cosmos.msg.v1.signer) = "admin"; - - // admin is the current account address of the group admin. - string admin = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // group_id is the unique ID of the group. - uint64 group_id = 2; - - // new_admin is the group new admin account address. - string new_admin = 3 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// MsgUpdateGroupAdminResponse is the Msg/UpdateGroupAdmin response type. -message MsgUpdateGroupAdminResponse {} - -// MsgUpdateGroupMetadata is the Msg/UpdateGroupMetadata request type. -message MsgUpdateGroupMetadata { - option (cosmos.msg.v1.signer) = "admin"; - - // admin is the account address of the group admin. - string admin = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // group_id is the unique ID of the group. - uint64 group_id = 2; - - // metadata is the updated group's metadata. - string metadata = 3; -} - -// MsgUpdateGroupMetadataResponse is the Msg/UpdateGroupMetadata response type. -message MsgUpdateGroupMetadataResponse {} - -// -// Group Policies -// - -// MsgCreateGroupPolicy is the Msg/CreateGroupPolicy request type. -message MsgCreateGroupPolicy { - option (cosmos.msg.v1.signer) = "admin"; - - option (gogoproto.goproto_getters) = false; - - // admin is the account address of the group admin. - string admin = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // group_id is the unique ID of the group. - uint64 group_id = 2; - - // metadata is any arbitrary metadata attached to the group policy. - string metadata = 3; - - // decision_policy specifies the group policy's decision policy. - google.protobuf.Any decision_policy = 4 [(cosmos_proto.accepts_interface) = "cosmos.group.v1.DecisionPolicy"]; -} - -// MsgCreateGroupPolicyResponse is the Msg/CreateGroupPolicy response type. -message MsgCreateGroupPolicyResponse { - - // address is the account address of the newly created group policy. - string address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// MsgUpdateGroupPolicyAdmin is the Msg/UpdateGroupPolicyAdmin request type. -message MsgUpdateGroupPolicyAdmin { - option (cosmos.msg.v1.signer) = "admin"; - - // admin is the account address of the group admin. - string admin = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // group_policy_address is the account address of the group policy. - string group_policy_address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // new_admin is the new group policy admin. - string new_admin = 3 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// MsgCreateGroupWithPolicy is the Msg/CreateGroupWithPolicy request type. -message MsgCreateGroupWithPolicy { - option (cosmos.msg.v1.signer) = "admin"; - option (gogoproto.goproto_getters) = false; - - // admin is the account address of the group and group policy admin. - string admin = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // members defines the group members. - repeated MemberRequest members = 2 [(gogoproto.nullable) = false]; - - // group_metadata is any arbitrary metadata attached to the group. - string group_metadata = 3; - - // group_policy_metadata is any arbitrary metadata attached to the group policy. - string group_policy_metadata = 4; - - // group_policy_as_admin is a boolean field, if set to true, the group policy account address will be used as group - // and group policy admin. - bool group_policy_as_admin = 5; - - // decision_policy specifies the group policy's decision policy. - google.protobuf.Any decision_policy = 6 [(cosmos_proto.accepts_interface) = "cosmos.group.v1.DecisionPolicy"]; -} - -// MsgCreateGroupWithPolicyResponse is the Msg/CreateGroupWithPolicy response type. -message MsgCreateGroupWithPolicyResponse { - - // group_id is the unique ID of the newly created group with policy. - uint64 group_id = 1; - - // group_policy_address is the account address of the newly created group policy. - string group_policy_address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// MsgUpdateGroupPolicyAdminResponse is the Msg/UpdateGroupPolicyAdmin response type. -message MsgUpdateGroupPolicyAdminResponse {} - -// MsgUpdateGroupPolicyDecisionPolicy is the Msg/UpdateGroupPolicyDecisionPolicy request type. -message MsgUpdateGroupPolicyDecisionPolicy { - option (cosmos.msg.v1.signer) = "admin"; - - option (gogoproto.goproto_getters) = false; - - // admin is the account address of the group admin. - string admin = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // group_policy_address is the account address of group policy. - string group_policy_address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // decision_policy is the updated group policy's decision policy. - google.protobuf.Any decision_policy = 3 [(cosmos_proto.accepts_interface) = "cosmos.group.v1.DecisionPolicy"]; -} - -// MsgUpdateGroupPolicyDecisionPolicyResponse is the Msg/UpdateGroupPolicyDecisionPolicy response type. -message MsgUpdateGroupPolicyDecisionPolicyResponse {} - -// MsgUpdateGroupPolicyMetadata is the Msg/UpdateGroupPolicyMetadata request type. -message MsgUpdateGroupPolicyMetadata { - option (cosmos.msg.v1.signer) = "admin"; - - // admin is the account address of the group admin. - string admin = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // group_policy_address is the account address of group policy. - string group_policy_address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // metadata is the updated group policy metadata. - string metadata = 3; -} - -// MsgUpdateGroupPolicyMetadataResponse is the Msg/UpdateGroupPolicyMetadata response type. -message MsgUpdateGroupPolicyMetadataResponse {} - -// -// Proposals and Voting -// - -// Exec defines modes of execution of a proposal on creation or on new vote. -enum Exec { - - // An empty value means that there should be a separate - // MsgExec request for the proposal to execute. - EXEC_UNSPECIFIED = 0; - - // Try to execute the proposal immediately. - // If the proposal is not allowed per the DecisionPolicy, - // the proposal will still be open and could - // be executed at a later point. - EXEC_TRY = 1; -} - -// MsgSubmitProposal is the Msg/SubmitProposal request type. -message MsgSubmitProposal { - option (cosmos.msg.v1.signer) = "proposers"; - - option (gogoproto.goproto_getters) = false; - - // group_policy_address is the account address of group policy. - string group_policy_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // proposers are the account addresses of the proposers. - // Proposers signatures will be counted as yes votes. - repeated string proposers = 2; - - // metadata is any arbitrary metadata to attached to the proposal. - string metadata = 3; - - // messages is a list of `sdk.Msg`s that will be executed if the proposal passes. - repeated google.protobuf.Any messages = 4; - - // exec defines the mode of execution of the proposal, - // whether it should be executed immediately on creation or not. - // If so, proposers signatures are considered as Yes votes. - Exec exec = 5; -} - -// MsgSubmitProposalResponse is the Msg/SubmitProposal response type. -message MsgSubmitProposalResponse { - - // proposal is the unique ID of the proposal. - uint64 proposal_id = 1; -} - -// MsgWithdrawProposal is the Msg/WithdrawProposal request type. -message MsgWithdrawProposal { - option (cosmos.msg.v1.signer) = "address"; - - // proposal is the unique ID of the proposal. - uint64 proposal_id = 1; - - // address is the admin of the group policy or one of the proposer of the proposal. - string address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// MsgWithdrawProposalResponse is the Msg/WithdrawProposal response type. -message MsgWithdrawProposalResponse {} - -// MsgVote is the Msg/Vote request type. -message MsgVote { - option (cosmos.msg.v1.signer) = "voter"; - - // proposal is the unique ID of the proposal. - uint64 proposal_id = 1; - // voter is the voter account address. - string voter = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // option is the voter's choice on the proposal. - VoteOption option = 3; - - // metadata is any arbitrary metadata to attached to the vote. - string metadata = 4; - - // exec defines whether the proposal should be executed - // immediately after voting or not. - Exec exec = 5; -} - -// MsgVoteResponse is the Msg/Vote response type. -message MsgVoteResponse {} - -// MsgExec is the Msg/Exec request type. -message MsgExec { - option (cosmos.msg.v1.signer) = "signer"; - - // proposal is the unique ID of the proposal. - uint64 proposal_id = 1; - - // executor is the account address used to execute the proposal. - string executor = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// MsgExecResponse is the Msg/Exec request type. -message MsgExecResponse { - // result is the final result of the proposal execution. - ProposalExecutorResult result = 2; -} - -// MsgLeaveGroup is the Msg/LeaveGroup request type. -message MsgLeaveGroup { - option (cosmos.msg.v1.signer) = "address"; - - // address is the account address of the group member. - string address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // group_id is the unique ID of the group. - uint64 group_id = 2; -} - -// MsgLeaveGroupResponse is the Msg/LeaveGroup response type. -message MsgLeaveGroupResponse {} diff --git a/src/cosmospy_protobuf/cosmos/group/v1/types.proto b/src/cosmospy_protobuf/cosmos/group/v1/types.proto deleted file mode 100644 index 63e20c8f..00000000 --- a/src/cosmospy_protobuf/cosmos/group/v1/types.proto +++ /dev/null @@ -1,318 +0,0 @@ -// Since: cosmos-sdk 0.46 -syntax = "proto3"; - -package cosmos.group.v1; - -option go_package = "github.com/cosmos/cosmos-sdk/x/group"; - -import "gogoproto/gogo.proto"; -import "google/protobuf/duration.proto"; -import "google/protobuf/timestamp.proto"; -import "cosmos_proto/cosmos.proto"; -import "google/protobuf/any.proto"; - -// Member represents a group member with an account address, -// non-zero weight, metadata and added_at timestamp. -message Member { - - // address is the member's account address. - string address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // weight is the member's voting weight that should be greater than 0. - string weight = 2; - - // metadata is any arbitrary metadata attached to the member. - string metadata = 3; - - // added_at is a timestamp specifying when a member was added. - google.protobuf.Timestamp added_at = 4 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; -} - - -// MemberRequest represents a group member to be used in Msg server requests. -// Contrary to `Member`, it doesn't have any `added_at` field -// since this field cannot be set as part of requests. -message MemberRequest { - - // address is the member's account address. - string address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // weight is the member's voting weight that should be greater than 0. - string weight = 2; - - // metadata is any arbitrary metadata attached to the member. - string metadata = 3; -} - -// ThresholdDecisionPolicy is a decision policy where a proposal passes when it -// satisfies the two following conditions: -// 1. The sum of all `YES` voters' weights is greater or equal than the defined -// `threshold`. -// 2. The voting and execution periods of the proposal respect the parameters -// given by `windows`. -message ThresholdDecisionPolicy { - option (cosmos_proto.implements_interface) = "DecisionPolicy"; - - // threshold is the minimum weighted sum of `YES` votes that must be met or - // exceeded for a proposal to succeed. - string threshold = 1; - - // windows defines the different windows for voting and execution. - DecisionPolicyWindows windows = 2; -} - -// PercentageDecisionPolicy is a decision policy where a proposal passes when -// it satisfies the two following conditions: -// 1. The percentage of all `YES` voters' weights out of the total group weight -// is greater or equal than the given `percentage`. -// 2. The voting and execution periods of the proposal respect the parameters -// given by `windows`. -message PercentageDecisionPolicy { - option (cosmos_proto.implements_interface) = "DecisionPolicy"; - - // percentage is the minimum percentage the weighted sum of `YES` votes must - // meet for a proposal to succeed. - string percentage = 1; - - // windows defines the different windows for voting and execution. - DecisionPolicyWindows windows = 2; -} - -// DecisionPolicyWindows defines the different windows for voting and execution. -message DecisionPolicyWindows { - // voting_period is the duration from submission of a proposal to the end of voting period - // Within this times votes can be submitted with MsgVote. - google.protobuf.Duration voting_period = 1 [(gogoproto.stdduration) = true, (gogoproto.nullable) = false]; - - // min_execution_period is the minimum duration after the proposal submission - // where members can start sending MsgExec. This means that the window for - // sending a MsgExec transaction is: - // `[ submission + min_execution_period ; submission + voting_period + max_execution_period]` - // where max_execution_period is a app-specific config, defined in the keeper. - // If not set, min_execution_period will default to 0. - // - // Please make sure to set a `min_execution_period` that is smaller than - // `voting_period + max_execution_period`, or else the above execution window - // is empty, meaning that all proposals created with this decision policy - // won't be able to be executed. - google.protobuf.Duration min_execution_period = 2 [(gogoproto.stdduration) = true, (gogoproto.nullable) = false]; -} - -// VoteOption enumerates the valid vote options for a given proposal. -enum VoteOption { - option (gogoproto.goproto_enum_prefix) = false; - - // VOTE_OPTION_UNSPECIFIED defines an unspecified vote option which will - // return an error. - VOTE_OPTION_UNSPECIFIED = 0; - // VOTE_OPTION_YES defines a yes vote option. - VOTE_OPTION_YES = 1; - // VOTE_OPTION_ABSTAIN defines an abstain vote option. - VOTE_OPTION_ABSTAIN = 2; - // VOTE_OPTION_NO defines a no vote option. - VOTE_OPTION_NO = 3; - // VOTE_OPTION_NO_WITH_VETO defines a no with veto vote option. - VOTE_OPTION_NO_WITH_VETO = 4; -} - -// -// State -// - -// GroupInfo represents the high-level on-chain information for a group. -message GroupInfo { - - // id is the unique ID of the group. - uint64 id = 1; - - // admin is the account address of the group's admin. - string admin = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // metadata is any arbitrary metadata to attached to the group. - string metadata = 3; - - // version is used to track changes to a group's membership structure that - // would break existing proposals. Whenever any members weight is changed, - // or any member is added or removed this version is incremented and will - // cause proposals based on older versions of this group to fail - uint64 version = 4; - - // total_weight is the sum of the group members' weights. - string total_weight = 5; - - // created_at is a timestamp specifying when a group was created. - google.protobuf.Timestamp created_at = 6 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; -} - -// GroupMember represents the relationship between a group and a member. -message GroupMember { - - // group_id is the unique ID of the group. - uint64 group_id = 1; - - // member is the member data. - Member member = 2; -} - -// GroupPolicyInfo represents the high-level on-chain information for a group policy. -message GroupPolicyInfo { - option (gogoproto.equal) = true; - option (gogoproto.goproto_getters) = false; - - // address is the account address of group policy. - string address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // group_id is the unique ID of the group. - uint64 group_id = 2; - - // admin is the account address of the group admin. - string admin = 3 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // metadata is any arbitrary metadata to attached to the group policy. - string metadata = 4; - - // version is used to track changes to a group's GroupPolicyInfo structure that - // would create a different result on a running proposal. - uint64 version = 5; - - // decision_policy specifies the group policy's decision policy. - google.protobuf.Any decision_policy = 6 [(cosmos_proto.accepts_interface) = "cosmos.group.v1.DecisionPolicy"]; - - // created_at is a timestamp specifying when a group policy was created. - google.protobuf.Timestamp created_at = 7 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; -} - -// Proposal defines a group proposal. Any member of a group can submit a proposal -// for a group policy to decide upon. -// A proposal consists of a set of `sdk.Msg`s that will be executed if the proposal -// passes as well as some optional metadata associated with the proposal. -message Proposal { - option (gogoproto.goproto_getters) = false; - - // id is the unique id of the proposal. - uint64 id = 1; - - // group_policy_address is the account address of group policy. - string group_policy_address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // metadata is any arbitrary metadata to attached to the proposal. - string metadata = 3; - - // proposers are the account addresses of the proposers. - repeated string proposers = 4 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // submit_time is a timestamp specifying when a proposal was submitted. - google.protobuf.Timestamp submit_time = 5 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; - - // group_version tracks the version of the group at proposal submission. - // This field is here for informational purposes only. - uint64 group_version = 6; - - // group_policy_version tracks the version of the group policy at proposal submission. - // When a decision policy is changed, existing proposals from previous policy - // versions will become invalid with the `ABORTED` status. - // This field is here for informational purposes only. - uint64 group_policy_version = 7; - - // status represents the high level position in the life cycle of the proposal. Initial value is Submitted. - ProposalStatus status = 8; - - // final_tally_result contains the sums of all weighted votes for this - // proposal for each vote option. It is empty at submission, and only - // populated after tallying, at voting period end or at proposal execution, - // whichever happens first. - TallyResult final_tally_result = 9 [(gogoproto.nullable) = false]; - - // voting_period_end is the timestamp before which voting must be done. - // Unless a successfull MsgExec is called before (to execute a proposal whose - // tally is successful before the voting period ends), tallying will be done - // at this point, and the `final_tally_result`and `status` fields will be - // accordingly updated. - google.protobuf.Timestamp voting_period_end = 10 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; - - // executor_result is the final result of the proposal execution. Initial value is NotRun. - ProposalExecutorResult executor_result = 11; - - // messages is a list of `sdk.Msg`s that will be executed if the proposal passes. - repeated google.protobuf.Any messages = 12; -} - -// ProposalStatus defines proposal statuses. -enum ProposalStatus { - option (gogoproto.goproto_enum_prefix) = false; - - // An empty value is invalid and not allowed. - PROPOSAL_STATUS_UNSPECIFIED = 0; - - // Initial status of a proposal when submitted. - PROPOSAL_STATUS_SUBMITTED = 1; - - // Final status of a proposal when the final tally is done and the outcome - // passes the group policy's decision policy. - PROPOSAL_STATUS_ACCEPTED = 2; - - // Final status of a proposal when the final tally is done and the outcome - // is rejected by the group policy's decision policy. - PROPOSAL_STATUS_REJECTED = 3; - - // Final status of a proposal when the group policy is modified before the - // final tally. - PROPOSAL_STATUS_ABORTED = 4; - - // A proposal can be withdrawn before the voting start time by the owner. - // When this happens the final status is Withdrawn. - PROPOSAL_STATUS_WITHDRAWN = 5; -} - -// ProposalExecutorResult defines types of proposal executor results. -enum ProposalExecutorResult { - option (gogoproto.goproto_enum_prefix) = false; - - // An empty value is not allowed. - PROPOSAL_EXECUTOR_RESULT_UNSPECIFIED = 0; - - // We have not yet run the executor. - PROPOSAL_EXECUTOR_RESULT_NOT_RUN = 1; - - // The executor was successful and proposed action updated state. - PROPOSAL_EXECUTOR_RESULT_SUCCESS = 2; - - // The executor returned an error and proposed action didn't update state. - PROPOSAL_EXECUTOR_RESULT_FAILURE = 3; -} - -// TallyResult represents the sum of weighted votes for each vote option. -message TallyResult { - option (gogoproto.goproto_getters) = false; - - // yes_count is the weighted sum of yes votes. - string yes_count = 1; - - // abstain_count is the weighted sum of abstainers. - string abstain_count = 2; - - // no_count is the weighted sum of no votes. - string no_count = 3; - - // no_with_veto_count is the weighted sum of veto. - string no_with_veto_count = 4; -} - -// Vote represents a vote for a proposal. -message Vote { - - // proposal is the unique ID of the proposal. - uint64 proposal_id = 1; - - // voter is the account address of the voter. - string voter = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // option is the voter's choice on the proposal. - VoteOption option = 3; - - // metadata is any arbitrary metadata to attached to the vote. - string metadata = 4; - - // submit_time is the timestamp when the vote was submitted. - google.protobuf.Timestamp submit_time = 5 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; -} diff --git a/src/cosmospy_protobuf/cosmos/mint/v1beta1/genesis.proto b/src/cosmospy_protobuf/cosmos/mint/v1beta1/genesis.proto deleted file mode 100644 index 4e783fb5..00000000 --- a/src/cosmospy_protobuf/cosmos/mint/v1beta1/genesis.proto +++ /dev/null @@ -1,16 +0,0 @@ -syntax = "proto3"; -package cosmos.mint.v1beta1; - -import "gogoproto/gogo.proto"; -import "cosmos/mint/v1beta1/mint.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/mint/types"; - -// GenesisState defines the mint module's genesis state. -message GenesisState { - // minter is a space for holding current inflation information. - Minter minter = 1 [(gogoproto.nullable) = false]; - - // params defines all the paramaters of the module. - Params params = 2 [(gogoproto.nullable) = false]; -} diff --git a/src/cosmospy_protobuf/cosmos/mint/v1beta1/mint.proto b/src/cosmospy_protobuf/cosmos/mint/v1beta1/mint.proto deleted file mode 100644 index 9cfe2b76..00000000 --- a/src/cosmospy_protobuf/cosmos/mint/v1beta1/mint.proto +++ /dev/null @@ -1,57 +0,0 @@ -syntax = "proto3"; -package cosmos.mint.v1beta1; - -option go_package = "github.com/cosmos/cosmos-sdk/x/mint/types"; - -import "gogoproto/gogo.proto"; -import "cosmos_proto/cosmos.proto"; - -// Minter represents the minting state. -message Minter { - // current annual inflation rate - string inflation = 1 [ - (cosmos_proto.scalar) = "cosmos.Dec", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false - ]; - // current annual expected provisions - string annual_provisions = 2 [ - (cosmos_proto.scalar) = "cosmos.Dec", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false - ]; -} - -// Params holds parameters for the mint module. -message Params { - option (gogoproto.goproto_stringer) = false; - - // type of coin to mint - string mint_denom = 1; - // maximum annual change in inflation rate - string inflation_rate_change = 2 [ - (cosmos_proto.scalar) = "cosmos.Dec", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false - ]; - // maximum inflation rate - string inflation_max = 3 [ - (cosmos_proto.scalar) = "cosmos.Dec", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false - ]; - // minimum inflation rate - string inflation_min = 4 [ - (cosmos_proto.scalar) = "cosmos.Dec", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false - ]; - // goal of percent bonded atoms - string goal_bonded = 5 [ - (cosmos_proto.scalar) = "cosmos.Dec", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false - ]; - // expected blocks per year - uint64 blocks_per_year = 6; -} diff --git a/src/cosmospy_protobuf/cosmos/mint/v1beta1/query.proto b/src/cosmospy_protobuf/cosmos/mint/v1beta1/query.proto deleted file mode 100644 index acd341d7..00000000 --- a/src/cosmospy_protobuf/cosmos/mint/v1beta1/query.proto +++ /dev/null @@ -1,57 +0,0 @@ -syntax = "proto3"; -package cosmos.mint.v1beta1; - -import "gogoproto/gogo.proto"; -import "google/api/annotations.proto"; -import "cosmos/mint/v1beta1/mint.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/mint/types"; - -// Query provides defines the gRPC querier service. -service Query { - // Params returns the total set of minting parameters. - rpc Params(QueryParamsRequest) returns (QueryParamsResponse) { - option (google.api.http).get = "/cosmos/mint/v1beta1/params"; - } - - // Inflation returns the current minting inflation value. - rpc Inflation(QueryInflationRequest) returns (QueryInflationResponse) { - option (google.api.http).get = "/cosmos/mint/v1beta1/inflation"; - } - - // AnnualProvisions current minting annual provisions value. - rpc AnnualProvisions(QueryAnnualProvisionsRequest) returns (QueryAnnualProvisionsResponse) { - option (google.api.http).get = "/cosmos/mint/v1beta1/annual_provisions"; - } -} - -// 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]; -} - -// QueryInflationRequest is the request type for the Query/Inflation RPC method. -message QueryInflationRequest {} - -// QueryInflationResponse is the response type for the Query/Inflation RPC -// method. -message QueryInflationResponse { - // inflation is the current minting inflation value. - bytes inflation = 1 [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", (gogoproto.nullable) = false]; -} - -// QueryAnnualProvisionsRequest is the request type for the -// Query/AnnualProvisions RPC method. -message QueryAnnualProvisionsRequest {} - -// QueryAnnualProvisionsResponse is the response type for the -// Query/AnnualProvisions RPC method. -message QueryAnnualProvisionsResponse { - // annual_provisions is the current minting annual provisions value. - bytes annual_provisions = 1 - [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", (gogoproto.nullable) = false]; -} diff --git a/src/cosmospy_protobuf/cosmos/msg/v1/msg.proto b/src/cosmospy_protobuf/cosmos/msg/v1/msg.proto deleted file mode 100644 index 89bdf312..00000000 --- a/src/cosmospy_protobuf/cosmos/msg/v1/msg.proto +++ /dev/null @@ -1,22 +0,0 @@ -syntax = "proto3"; - -package cosmos.msg.v1; - -import "google/protobuf/descriptor.proto"; - -// TODO(fdymylja): once we fully migrate to protov2 the go_package needs to be updated. -// We need this right now because gogoproto codegen needs to import the extension. -option go_package = "github.com/cosmos/cosmos-sdk/types/msgservice"; - -extend google.protobuf.MessageOptions { - // signer must be used in cosmos messages in order - // to signal to external clients which fields in a - // given cosmos message must be filled with signer - // information (address). - // The field must be the protobuf name of the message - // field extended with this MessageOption. - // The field must either be of string kind, or of message - // kind in case the signer information is contained within - // a message inside the cosmos message. - repeated string signer = 11110000; -} \ No newline at end of file diff --git a/src/cosmospy_protobuf/cosmos/nft/v1beta1/event.proto b/src/cosmospy_protobuf/cosmos/nft/v1beta1/event.proto deleted file mode 100644 index 96964f08..00000000 --- a/src/cosmospy_protobuf/cosmos/nft/v1beta1/event.proto +++ /dev/null @@ -1,26 +0,0 @@ -syntax = "proto3"; -package cosmos.nft.v1beta1; - -option go_package = "github.com/cosmos/cosmos-sdk/x/nft"; - -// EventSend is emitted on Msg/Send -message EventSend { - string class_id = 1; - string id = 2; - string sender = 3; - string receiver = 4; -} - -// EventMint is emitted on Mint -message EventMint { - string class_id = 1; - string id = 2; - string owner = 3; -} - -// EventBurn is emitted on Burn -message EventBurn { - string class_id = 1; - string id = 2; - string owner = 3; -} diff --git a/src/cosmospy_protobuf/cosmos/nft/v1beta1/genesis.proto b/src/cosmospy_protobuf/cosmos/nft/v1beta1/genesis.proto deleted file mode 100644 index 6f36ed34..00000000 --- a/src/cosmospy_protobuf/cosmos/nft/v1beta1/genesis.proto +++ /dev/null @@ -1,22 +0,0 @@ -syntax = "proto3"; -package cosmos.nft.v1beta1; - -import "cosmos/nft/v1beta1/nft.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/nft"; - -// GenesisState defines the nft module's genesis state. -message GenesisState { - // class defines the class of the nft type. - repeated cosmos.nft.v1beta1.Class classes = 1; - repeated Entry entries = 2; -} - -// Entry Defines all nft owned by a person -message Entry { - // owner is the owner address of the following nft - string owner = 1; - - // nfts is a group of nfts of the same owner - repeated cosmos.nft.v1beta1.NFT nfts = 2; -} diff --git a/src/cosmospy_protobuf/cosmos/nft/v1beta1/nft.proto b/src/cosmospy_protobuf/cosmos/nft/v1beta1/nft.proto deleted file mode 100644 index b1241260..00000000 --- a/src/cosmospy_protobuf/cosmos/nft/v1beta1/nft.proto +++ /dev/null @@ -1,48 +0,0 @@ -syntax = "proto3"; -package cosmos.nft.v1beta1; - -import "google/protobuf/any.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/nft"; - -// Class defines the class of the nft type. -message Class { - // id defines the unique identifier of the NFT classification, similar to the contract address of ERC721 - string id = 1; - - // name defines the human-readable name of the NFT classification. Optional - string name = 2; - - // symbol is an abbreviated name for nft classification. Optional - string symbol = 3; - - // description is a brief description of nft classification. Optional - string description = 4; - - // uri for the class metadata stored off chain. It can define schema for Class and NFT `Data` attributes. Optional - string uri = 5; - - // uri_hash is a hash of the document pointed by uri. Optional - string uri_hash = 6; - - // data is the app specific metadata of the NFT class. Optional - google.protobuf.Any data = 7; -} - -// NFT defines the NFT. -message NFT { - // class_id associated with the NFT, similar to the contract address of ERC721 - string class_id = 1; - - // id is a unique identifier of the NFT - string id = 2; - - // uri for the NFT metadata stored off chain - string uri = 3; - - // uri_hash is a hash of the document pointed by uri - string uri_hash = 4; - - // data is an app specific data of the NFT. Optional - google.protobuf.Any data = 10; -} diff --git a/src/cosmospy_protobuf/cosmos/nft/v1beta1/query.proto b/src/cosmospy_protobuf/cosmos/nft/v1beta1/query.proto deleted file mode 100644 index c1d8070f..00000000 --- a/src/cosmospy_protobuf/cosmos/nft/v1beta1/query.proto +++ /dev/null @@ -1,125 +0,0 @@ -syntax = "proto3"; -package cosmos.nft.v1beta1; - -import "cosmos/base/query/v1beta1/pagination.proto"; -import "google/api/annotations.proto"; -import "cosmos/nft/v1beta1/nft.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/nft"; - -// Query defines the gRPC querier service. -service Query { - // Balance queries the number of NFTs of a given class owned by the owner, same as balanceOf in ERC721 - rpc Balance(QueryBalanceRequest) returns (QueryBalanceResponse) { - option (google.api.http).get = "/cosmos/nft/v1beta1/balance/{owner}/{class_id}"; - } - - // Owner queries the owner of the NFT based on its class and id, same as ownerOf in ERC721 - rpc Owner(QueryOwnerRequest) returns (QueryOwnerResponse) { - option (google.api.http).get = "/cosmos/nft/v1beta1/owner/{class_id}/{id}"; - } - - // Supply queries the number of NFTs from the given class, same as totalSupply of ERC721. - rpc Supply(QuerySupplyRequest) returns (QuerySupplyResponse) { - option (google.api.http).get = "/cosmos/nft/v1beta1/supply/{class_id}"; - } - - // NFTs queries all NFTs of a given class or owner,choose at least one of the two, similar to tokenByIndex in - // ERC721Enumerable - rpc NFTs(QueryNFTsRequest) returns (QueryNFTsResponse) { - option (google.api.http).get = "/cosmos/nft/v1beta1/nfts"; - } - - // NFT queries an NFT based on its class and id. - rpc NFT(QueryNFTRequest) returns (QueryNFTResponse) { - option (google.api.http).get = "/cosmos/nft/v1beta1/nfts/{class_id}/{id}"; - } - - // Class queries an NFT class based on its id - rpc Class(QueryClassRequest) returns (QueryClassResponse) { - option (google.api.http).get = "/cosmos/nft/v1beta1/classes/{class_id}"; - } - - // Classes queries all NFT classes - rpc Classes(QueryClassesRequest) returns (QueryClassesResponse) { - option (google.api.http).get = "/cosmos/nft/v1beta1/classes"; - } -} - -// QueryBalanceRequest is the request type for the Query/Balance RPC method -message QueryBalanceRequest { - string class_id = 1; - string owner = 2; -} - -// QueryBalanceResponse is the response type for the Query/Balance RPC method -message QueryBalanceResponse { - uint64 amount = 1; -} - -// QueryOwnerRequest is the request type for the Query/Owner RPC method -message QueryOwnerRequest { - string class_id = 1; - string id = 2; -} - -// QueryOwnerResponse is the response type for the Query/Owner RPC method -message QueryOwnerResponse { - string owner = 1; -} - -// QuerySupplyRequest is the request type for the Query/Supply RPC method -message QuerySupplyRequest { - string class_id = 1; -} - -// QuerySupplyResponse is the response type for the Query/Supply RPC method -message QuerySupplyResponse { - uint64 amount = 1; -} - -// QueryNFTstRequest is the request type for the Query/NFTs RPC method -message QueryNFTsRequest { - string class_id = 1; - string owner = 2; - cosmos.base.query.v1beta1.PageRequest pagination = 3; -} - -// QueryNFTsResponse is the response type for the Query/NFTs RPC methods -message QueryNFTsResponse { - repeated cosmos.nft.v1beta1.NFT nfts = 1; - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryNFTRequest is the request type for the Query/NFT RPC method -message QueryNFTRequest { - string class_id = 1; - string id = 2; -} - -// QueryNFTResponse is the response type for the Query/NFT RPC method -message QueryNFTResponse { - cosmos.nft.v1beta1.NFT nft = 1; -} - -// QueryClassRequest is the request type for the Query/Class RPC method -message QueryClassRequest { - string class_id = 1; -} - -// QueryClassResponse is the response type for the Query/Class RPC method -message QueryClassResponse { - cosmos.nft.v1beta1.Class class = 1; -} - -// QueryClassesRequest is the request type for the Query/Classes RPC method -message QueryClassesRequest { - // pagination defines an optional pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 1; -} - -// QueryClassesResponse is the response type for the Query/Classes RPC method -message QueryClassesResponse { - repeated cosmos.nft.v1beta1.Class classes = 1; - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} diff --git a/src/cosmospy_protobuf/cosmos/nft/v1beta1/tx.proto b/src/cosmospy_protobuf/cosmos/nft/v1beta1/tx.proto deleted file mode 100644 index 95b402ce..00000000 --- a/src/cosmospy_protobuf/cosmos/nft/v1beta1/tx.proto +++ /dev/null @@ -1,30 +0,0 @@ -syntax = "proto3"; -package cosmos.nft.v1beta1; - -option go_package = "github.com/cosmos/cosmos-sdk/x/nft"; - -import "cosmos/msg/v1/msg.proto"; - -// Msg defines the nft Msg service. -service Msg { - // Send defines a method to send a nft from one account to another account. - rpc Send(MsgSend) returns (MsgSendResponse); -} -// MsgSend represents a message to send a nft from one account to another account. -message MsgSend { - option (cosmos.msg.v1.signer) = "sender"; - - // class_id defines the unique identifier of the nft classification, similar to the contract address of ERC721 - string class_id = 1; - - // id defines the unique identification of nft - string id = 2; - - // sender is the address of the owner of nft - string sender = 3; - - // receiver is the receiver address of nft - string receiver = 4; -} -// MsgSendResponse defines the Msg/Send response type. -message MsgSendResponse {} \ No newline at end of file diff --git a/src/cosmospy_protobuf/cosmos/orm/module/v1alpha1/module.proto b/src/cosmospy_protobuf/cosmos/orm/module/v1alpha1/module.proto deleted file mode 100644 index cb7bbbee..00000000 --- a/src/cosmospy_protobuf/cosmos/orm/module/v1alpha1/module.proto +++ /dev/null @@ -1,14 +0,0 @@ -syntax = "proto3"; - -package cosmos.orm.module.v1alpha1; - -import "cosmos/app/v1alpha1/module.proto"; - -// Module defines the ORM module which adds providers to the app container for -// module-scoped DB's. In the future it may provide gRPC services for interacting -// with ORM data. -message Module { - option (cosmos.app.v1alpha1.module) = { - go_import: "github.com/cosmos/cosmos-sdk/orm" - }; -} diff --git a/src/cosmospy_protobuf/cosmos/orm/v1/orm.proto b/src/cosmospy_protobuf/cosmos/orm/v1/orm.proto deleted file mode 100644 index abfbbd4f..00000000 --- a/src/cosmospy_protobuf/cosmos/orm/v1/orm.proto +++ /dev/null @@ -1,104 +0,0 @@ -syntax = "proto3"; - -package cosmos.orm.v1; - -import "google/protobuf/descriptor.proto"; - -extend google.protobuf.MessageOptions { - - // table specifies that this message will be used as an ORM table. It cannot - // be used together with the singleton option. - TableDescriptor table = 104503790; - - // singleton specifies that this message will be used as an ORM singleton. It cannot - // be used together with the table option. - SingletonDescriptor singleton = 104503791; -} - -// TableDescriptor describes an ORM table. -message TableDescriptor { - - // primary_key defines the primary key for the table. - PrimaryKeyDescriptor primary_key = 1; - - // index defines one or more secondary indexes. - repeated SecondaryIndexDescriptor index = 2; - - // id is a non-zero integer ID that must be unique within the - // tables and singletons in this file. It may be deprecated in the future when this - // can be auto-generated. - uint32 id = 3; -} - -// PrimaryKeyDescriptor describes a table primary key. -message PrimaryKeyDescriptor { - - // fields is a comma-separated list of fields in the primary key. Spaces are - // not allowed. Supported field types, their encodings, and any applicable constraints - // are described below. - // - uint32 are encoded as 2,3,4 or 5 bytes using a compact encoding that - // is suitable for sorted iteration (not varint encoding). This type is - // well-suited for small integers. - // - uint64 are encoded as 2,4,6 or 9 bytes using a compact encoding that - // is suitable for sorted iteration (not varint encoding). This type is - // well-suited for small integers such as auto-incrementing sequences. - // - fixed32, fixed64 are encoded as big-endian fixed width bytes and support - // sorted iteration. These types are well-suited for encoding fixed with - // decimals as integers. - // - string's are encoded as raw bytes in terminal key segments and null-terminated - // in non-terminal segments. Null characters are thus forbidden in strings. - // string fields support sorted iteration. - // - bytes are encoded as raw bytes in terminal segments and length-prefixed - // with a 32-bit unsigned varint in non-terminal segments. - // - int32, sint32, int64, sint64, sfixed32, sfixed64 are encoded as fixed width bytes with - // an encoding that enables sorted iteration. - // - google.protobuf.Timestamp and google.protobuf.Duration are encoded - // as 12 bytes using an encoding that enables sorted iteration. - // - enum fields are encoded using varint encoding and do not support sorted - // iteration. - // - bool fields are encoded as a single byte 0 or 1. - // - // All other fields types are unsupported in keys including repeated and - // oneof fields. - // - // Primary keys are prefixed by the varint encoded table id and the byte 0x0 - // plus any additional prefix specified by the schema. - string fields = 1; - - // auto_increment specifies that the primary key is generated by an - // auto-incrementing integer. If this is set to true fields must only - // contain one field of that is of type uint64. - bool auto_increment = 2; -} - -// PrimaryKeyDescriptor describes a table secondary index. -message SecondaryIndexDescriptor { - - // fields is a comma-separated list of fields in the index. The supported - // field types are the same as those for PrimaryKeyDescriptor.fields. - // Index keys are prefixed by the varint encoded table id and the varint - // encoded index id plus any additional prefix specified by the schema. - // - // In addition the the field segments, non-unique index keys are suffixed with - // any additional primary key fields not present in the index fields so that the - // primary key can be reconstructed. Unique indexes instead of being suffixed - // store the remaining primary key fields in the value.. - string fields = 1; - - // id is a non-zero integer ID that must be unique within the indexes for this - // table and less than 32768. It may be deprecated in the future when this can - // be auto-generated. - uint32 id = 2; - - // unique specifies that this an unique index. - bool unique = 3; -} - -// TableDescriptor describes an ORM singleton table which has at most one instance. -message SingletonDescriptor { - - // id is a non-zero integer ID that must be unique within the - // tables and singletons in this file. It may be deprecated in the future when this - // can be auto-generated. - uint32 id = 1; -} \ No newline at end of file diff --git a/src/cosmospy_protobuf/cosmos/orm/v1alpha1/schema.proto b/src/cosmospy_protobuf/cosmos/orm/v1alpha1/schema.proto deleted file mode 100644 index ab713340..00000000 --- a/src/cosmospy_protobuf/cosmos/orm/v1alpha1/schema.proto +++ /dev/null @@ -1,76 +0,0 @@ -syntax = "proto3"; - -package cosmos.orm.v1alpha1; - -import "google/protobuf/descriptor.proto"; - -extend google.protobuf.MessageOptions { - // module_schema is used to define the ORM schema for an app module. - // All module config messages that use module_schema must also declare - // themselves as app module config messages using the cosmos.app.v1.is_module - // option. - ModuleSchemaDescriptor module_schema = 104503792; -} - -// ModuleSchemaDescriptor describe's a module's ORM schema. -message ModuleSchemaDescriptor { - repeated FileEntry schema_file = 1; - - // FileEntry describes an ORM file used in a module. - message FileEntry { - // id is a prefix that will be varint encoded and prepended to all the - // table keys specified in the file's tables. - uint32 id = 1; - - // proto_file_name is the name of a file .proto in that contains - // table definitions. The .proto file must be in a package that the - // module has referenced using cosmos.app.v1.ModuleDescriptor.use_package. - string proto_file_name = 2; - - // storage_type optionally indicates the type of storage this file's - // tables should used. If it is left unspecified, the default KV-storage - // of the app will be used. - StorageType storage_type = 3; - } - - // prefix is an optional prefix that precedes all keys in this module's - // store. - bytes prefix = 2; -} - -// StorageType -enum StorageType { - // STORAGE_TYPE_DEFAULT_UNSPECIFIED indicates the persistent - // KV-storage where primary key entries are stored in merkle-tree - // backed commitment storage and indexes and seqs are stored in - // fast index storage. Note that the Cosmos SDK before store/v2alpha1 - // does not support this. - STORAGE_TYPE_DEFAULT_UNSPECIFIED = 0; - - // STORAGE_TYPE_MEMORY indicates in-memory storage that will be - // reloaded every time an app restarts. Tables with this type of storage - // will by default be ignored when importing and exporting a module's - // state from JSON. - STORAGE_TYPE_MEMORY = 1; - - // STORAGE_TYPE_TRANSIENT indicates transient storage that is reset - // at the end of every block. Tables with this type of storage - // will by default be ignored when importing and exporting a module's - // state from JSON. - STORAGE_TYPE_TRANSIENT = 2; - - // STORAGE_TYPE_INDEX indicates persistent storage which is not backed - // by a merkle-tree and won't affect the app hash. Note that the Cosmos SDK - // before store/v2alpha1 does not support this. - STORAGE_TYPE_INDEX = 3; - - // STORAGE_TYPE_INDEX indicates persistent storage which is backed by - // a merkle-tree. With this type of storage, both primary and index keys - // will affect the app hash and this is generally less efficient - // than using STORAGE_TYPE_DEFAULT_UNSPECIFIED which separates index - // keys into index storage. Note that modules built with the - // Cosmos SDK before store/v2alpha1 must specify STORAGE_TYPE_COMMITMENT - // instead of STORAGE_TYPE_DEFAULT_UNSPECIFIED or STORAGE_TYPE_INDEX - // because this is the only type of persistent storage available. - STORAGE_TYPE_COMMITMENT = 4; -} diff --git a/src/cosmospy_protobuf/cosmos/params/v1beta1/params.proto b/src/cosmospy_protobuf/cosmos/params/v1beta1/params.proto deleted file mode 100644 index 5382fd79..00000000 --- a/src/cosmospy_protobuf/cosmos/params/v1beta1/params.proto +++ /dev/null @@ -1,27 +0,0 @@ -syntax = "proto3"; -package cosmos.params.v1beta1; - -option go_package = "github.com/cosmos/cosmos-sdk/x/params/types/proposal"; -option (gogoproto.equal_all) = true; - -import "gogoproto/gogo.proto"; - -// ParameterChangeProposal defines a proposal to change one or more parameters. -message ParameterChangeProposal { - option (gogoproto.goproto_getters) = false; - option (gogoproto.goproto_stringer) = false; - - string title = 1; - string description = 2; - repeated ParamChange changes = 3 [(gogoproto.nullable) = false]; -} - -// ParamChange defines an individual parameter change, for use in -// ParameterChangeProposal. -message ParamChange { - option (gogoproto.goproto_stringer) = false; - - string subspace = 1; - string key = 2; - string value = 3; -} diff --git a/src/cosmospy_protobuf/cosmos/params/v1beta1/query.proto b/src/cosmospy_protobuf/cosmos/params/v1beta1/query.proto deleted file mode 100644 index 3b1c9a76..00000000 --- a/src/cosmospy_protobuf/cosmos/params/v1beta1/query.proto +++ /dev/null @@ -1,54 +0,0 @@ -syntax = "proto3"; -package cosmos.params.v1beta1; - -import "gogoproto/gogo.proto"; -import "google/api/annotations.proto"; -import "cosmos/params/v1beta1/params.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/params/types/proposal"; - -// Query defines the gRPC querier service. -service Query { - // Params queries a specific parameter of a module, given its subspace and - // key. - rpc Params(QueryParamsRequest) returns (QueryParamsResponse) { - option (google.api.http).get = "/cosmos/params/v1beta1/params"; - } - - // Subspaces queries for all registered subspaces and all keys for a subspace. - rpc Subspaces(QuerySubspacesRequest) returns (QuerySubspacesResponse) { - option (google.api.http).get = "/cosmos/params/v1beta1/subspaces"; - } -} - -// QueryParamsRequest is request type for the Query/Params RPC method. -message QueryParamsRequest { - // subspace defines the module to query the parameter for. - string subspace = 1; - - // key defines the key of the parameter in the subspace. - string key = 2; -} - -// QueryParamsResponse is response type for the Query/Params RPC method. -message QueryParamsResponse { - // param defines the queried parameter. - ParamChange param = 1 [(gogoproto.nullable) = false]; -} - -// QuerySubspacesRequest defines a request type for querying for all registered -// subspaces and all keys for a subspace. -message QuerySubspacesRequest {} - -// QuerySubspacesResponse defines the response types for querying for all -// registered subspaces and all keys for a subspace. -message QuerySubspacesResponse { - repeated Subspace subspaces = 1; -} - -// Subspace defines a parameter subspace name and all the keys that exist for -// the subspace. -message Subspace { - string subspace = 1; - repeated string keys = 2; -} diff --git a/src/cosmospy_protobuf/cosmos/slashing/v1beta1/genesis.proto b/src/cosmospy_protobuf/cosmos/slashing/v1beta1/genesis.proto deleted file mode 100644 index 312d56aa..00000000 --- a/src/cosmospy_protobuf/cosmos/slashing/v1beta1/genesis.proto +++ /dev/null @@ -1,47 +0,0 @@ -syntax = "proto3"; -package cosmos.slashing.v1beta1; - -option go_package = "github.com/cosmos/cosmos-sdk/x/slashing/types"; - -import "gogoproto/gogo.proto"; -import "cosmos/slashing/v1beta1/slashing.proto"; -import "cosmos_proto/cosmos.proto"; - -// GenesisState defines the slashing module's genesis state. -message GenesisState { - // params defines all the paramaters of related to deposit. - Params params = 1 [(gogoproto.nullable) = false]; - - // signing_infos represents a map between validator addresses and their - // signing infos. - repeated SigningInfo signing_infos = 2 [(gogoproto.nullable) = false]; - - // missed_blocks represents a map between validator addresses and their - // missed blocks. - repeated ValidatorMissedBlocks missed_blocks = 3 [(gogoproto.nullable) = false]; -} - -// SigningInfo stores validator signing info of corresponding address. -message SigningInfo { - // address is the validator address. - string address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - // validator_signing_info represents the signing info of this validator. - ValidatorSigningInfo validator_signing_info = 2 [(gogoproto.nullable) = false]; -} - -// ValidatorMissedBlocks contains array of missed blocks of corresponding -// address. -message ValidatorMissedBlocks { - // address is the validator address. - string address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - // missed_blocks is an array of missed blocks by the validator. - repeated MissedBlock missed_blocks = 2 [(gogoproto.nullable) = false]; -} - -// MissedBlock contains height and missed status as boolean. -message MissedBlock { - // index is the height at which the block was missed. - int64 index = 1; - // missed is the missed status. - bool missed = 2; -} diff --git a/src/cosmospy_protobuf/cosmos/slashing/v1beta1/query.proto b/src/cosmospy_protobuf/cosmos/slashing/v1beta1/query.proto deleted file mode 100644 index f742c1f8..00000000 --- a/src/cosmospy_protobuf/cosmos/slashing/v1beta1/query.proto +++ /dev/null @@ -1,64 +0,0 @@ -syntax = "proto3"; -package cosmos.slashing.v1beta1; - -import "cosmos/base/query/v1beta1/pagination.proto"; -import "gogoproto/gogo.proto"; -import "google/api/annotations.proto"; -import "cosmos/slashing/v1beta1/slashing.proto"; -import "cosmos_proto/cosmos.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/slashing/types"; - -// Query provides defines the gRPC querier service -service Query { - // Params queries the parameters of slashing module - rpc Params(QueryParamsRequest) returns (QueryParamsResponse) { - option (google.api.http).get = "/cosmos/slashing/v1beta1/params"; - } - - // SigningInfo queries the signing info of given cons address - rpc SigningInfo(QuerySigningInfoRequest) returns (QuerySigningInfoResponse) { - option (google.api.http).get = "/cosmos/slashing/v1beta1/signing_infos/{cons_address}"; - } - - // SigningInfos queries signing info of all validators - rpc SigningInfos(QuerySigningInfosRequest) returns (QuerySigningInfosResponse) { - option (google.api.http).get = "/cosmos/slashing/v1beta1/signing_infos"; - } -} - -// 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 params = 1 [(gogoproto.nullable) = false]; -} - -// QuerySigningInfoRequest is the request type for the Query/SigningInfo RPC -// method -message QuerySigningInfoRequest { - // cons_address is the address to query signing info of - string cons_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// QuerySigningInfoResponse is the response type for the Query/SigningInfo RPC -// method -message QuerySigningInfoResponse { - // val_signing_info is the signing info of requested val cons address - ValidatorSigningInfo val_signing_info = 1 [(gogoproto.nullable) = false]; -} - -// QuerySigningInfosRequest is the request type for the Query/SigningInfos RPC -// method -message QuerySigningInfosRequest { - cosmos.base.query.v1beta1.PageRequest pagination = 1; -} - -// QuerySigningInfosResponse is the response type for the Query/SigningInfos RPC -// method -message QuerySigningInfosResponse { - // info is the signing info of all validators - repeated cosmos.slashing.v1beta1.ValidatorSigningInfo info = 1 [(gogoproto.nullable) = false]; - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} diff --git a/src/cosmospy_protobuf/cosmos/slashing/v1beta1/slashing.proto b/src/cosmospy_protobuf/cosmos/slashing/v1beta1/slashing.proto deleted file mode 100644 index 0aa9f61f..00000000 --- a/src/cosmospy_protobuf/cosmos/slashing/v1beta1/slashing.proto +++ /dev/null @@ -1,45 +0,0 @@ -syntax = "proto3"; -package cosmos.slashing.v1beta1; - -option go_package = "github.com/cosmos/cosmos-sdk/x/slashing/types"; -option (gogoproto.equal_all) = true; - -import "gogoproto/gogo.proto"; -import "google/protobuf/duration.proto"; -import "google/protobuf/timestamp.proto"; -import "cosmos_proto/cosmos.proto"; - -// ValidatorSigningInfo defines a validator's signing info for monitoring their -// liveness activity. -message ValidatorSigningInfo { - option (gogoproto.equal) = true; - option (gogoproto.goproto_stringer) = false; - - string address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - // Height at which validator was first a candidate OR was unjailed - int64 start_height = 2; - // 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`. - int64 index_offset = 3; - // Timestamp until which the validator is jailed due to liveness downtime. - google.protobuf.Timestamp jailed_until = 4 [(gogoproto.stdtime) = true, (gogoproto.nullable) = false]; - // 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. - bool tombstoned = 5; - // A counter kept to avoid unnecessary array reads. - // Note that `Sum(MissedBlocksBitArray)` always equals `MissedBlocksCounter`. - int64 missed_blocks_counter = 6; -} - -// Params represents the parameters used for by the slashing module. -message Params { - int64 signed_blocks_window = 1; - bytes min_signed_per_window = 2 - [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", (gogoproto.nullable) = false]; - google.protobuf.Duration downtime_jail_duration = 3 [(gogoproto.nullable) = false, (gogoproto.stdduration) = true]; - bytes slash_fraction_double_sign = 4 - [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", (gogoproto.nullable) = false]; - bytes slash_fraction_downtime = 5 - [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", (gogoproto.nullable) = false]; -} diff --git a/src/cosmospy_protobuf/cosmos/slashing/v1beta1/tx.proto b/src/cosmospy_protobuf/cosmos/slashing/v1beta1/tx.proto deleted file mode 100644 index 7c90304b..00000000 --- a/src/cosmospy_protobuf/cosmos/slashing/v1beta1/tx.proto +++ /dev/null @@ -1,30 +0,0 @@ -syntax = "proto3"; -package cosmos.slashing.v1beta1; - -option go_package = "github.com/cosmos/cosmos-sdk/x/slashing/types"; -option (gogoproto.equal_all) = true; - -import "gogoproto/gogo.proto"; -import "cosmos_proto/cosmos.proto"; -import "cosmos/msg/v1/msg.proto"; - -// Msg defines the slashing Msg service. -service Msg { - // Unjail defines a method for unjailing a jailed validator, thus returning - // them into the bonded validator set, so they can begin receiving provisions - // and rewards again. - rpc Unjail(MsgUnjail) returns (MsgUnjailResponse); -} - -// MsgUnjail defines the Msg/Unjail request type -message MsgUnjail { - option (cosmos.msg.v1.signer) = "validator_addr"; - - option (gogoproto.goproto_getters) = false; - option (gogoproto.goproto_stringer) = true; - - string validator_addr = 1 [(cosmos_proto.scalar) = "cosmos.AddressString", (gogoproto.jsontag) = "address"]; -} - -// MsgUnjailResponse defines the Msg/Unjail response type -message MsgUnjailResponse {} diff --git a/src/cosmospy_protobuf/cosmos/staking/v1beta1/authz.proto b/src/cosmospy_protobuf/cosmos/staking/v1beta1/authz.proto deleted file mode 100644 index 677edaad..00000000 --- a/src/cosmospy_protobuf/cosmos/staking/v1beta1/authz.proto +++ /dev/null @@ -1,47 +0,0 @@ -syntax = "proto3"; -package cosmos.staking.v1beta1; - -import "gogoproto/gogo.proto"; -import "cosmos_proto/cosmos.proto"; -import "cosmos/base/v1beta1/coin.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/staking/types"; - -// StakeAuthorization defines authorization for delegate/undelegate/redelegate. -// -// Since: cosmos-sdk 0.43 -message StakeAuthorization { - option (cosmos_proto.implements_interface) = "Authorization"; - - // max_tokens specifies the maximum amount of tokens can be delegate to a validator. If it is - // empty, there is no spend limit and any amount of coins can be delegated. - cosmos.base.v1beta1.Coin max_tokens = 1 [(gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coin"]; - // validators is the oneof that represents either allow_list or deny_list - oneof validators { - // allow_list specifies list of validator addresses to whom grantee can delegate tokens on behalf of granter's - // account. - Validators allow_list = 2; - // deny_list specifies list of validator addresses to whom grantee can not delegate tokens. - Validators deny_list = 3; - } - // Validators defines list of validator addresses. - message Validators { - repeated string address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - } - // authorization_type defines one of AuthorizationType. - AuthorizationType authorization_type = 4; -} - -// AuthorizationType defines the type of staking module authorization type -// -// Since: cosmos-sdk 0.43 -enum AuthorizationType { - // AUTHORIZATION_TYPE_UNSPECIFIED specifies an unknown authorization type - AUTHORIZATION_TYPE_UNSPECIFIED = 0; - // AUTHORIZATION_TYPE_DELEGATE defines an authorization type for Msg/Delegate - AUTHORIZATION_TYPE_DELEGATE = 1; - // AUTHORIZATION_TYPE_UNDELEGATE defines an authorization type for Msg/Undelegate - AUTHORIZATION_TYPE_UNDELEGATE = 2; - // AUTHORIZATION_TYPE_REDELEGATE defines an authorization type for Msg/BeginRedelegate - AUTHORIZATION_TYPE_REDELEGATE = 3; -} diff --git a/src/cosmospy_protobuf/cosmos/staking/v1beta1/genesis.proto b/src/cosmospy_protobuf/cosmos/staking/v1beta1/genesis.proto deleted file mode 100644 index bf3c298e..00000000 --- a/src/cosmospy_protobuf/cosmos/staking/v1beta1/genesis.proto +++ /dev/null @@ -1,49 +0,0 @@ -syntax = "proto3"; -package cosmos.staking.v1beta1; - -option go_package = "github.com/cosmos/cosmos-sdk/x/staking/types"; - -import "gogoproto/gogo.proto"; -import "cosmos/staking/v1beta1/staking.proto"; -import "cosmos_proto/cosmos.proto"; - -// GenesisState defines the staking module's genesis state. -message GenesisState { - // params defines all the paramaters of related to deposit. - Params params = 1 [(gogoproto.nullable) = false]; - - // last_total_power tracks the total amounts of bonded tokens recorded during - // the previous end block. - bytes last_total_power = 2 - [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", (gogoproto.nullable) = false]; - - // last_validator_powers is a special index that provides a historical list - // of the last-block's bonded validators. - repeated LastValidatorPower last_validator_powers = 3 [(gogoproto.nullable) = false]; - - // delegations defines the validator set at genesis. - repeated Validator validators = 4 [(gogoproto.nullable) = false]; - - // delegations defines the delegations active at genesis. - repeated Delegation delegations = 5 [(gogoproto.nullable) = false]; - - // unbonding_delegations defines the unbonding delegations active at genesis. - repeated UnbondingDelegation unbonding_delegations = 6 [(gogoproto.nullable) = false]; - - // redelegations defines the redelegations active at genesis. - repeated Redelegation redelegations = 7 [(gogoproto.nullable) = false]; - - bool exported = 8; -} - -// LastValidatorPower required for validator set update logic. -message LastValidatorPower { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // address is the address of the validator. - string address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // power defines the power of the validator. - int64 power = 2; -} diff --git a/src/cosmospy_protobuf/cosmos/staking/v1beta1/query.proto b/src/cosmospy_protobuf/cosmos/staking/v1beta1/query.proto deleted file mode 100644 index 02469232..00000000 --- a/src/cosmospy_protobuf/cosmos/staking/v1beta1/query.proto +++ /dev/null @@ -1,349 +0,0 @@ -syntax = "proto3"; -package cosmos.staking.v1beta1; - -import "cosmos/base/query/v1beta1/pagination.proto"; -import "gogoproto/gogo.proto"; -import "google/api/annotations.proto"; -import "cosmos/staking/v1beta1/staking.proto"; -import "cosmos_proto/cosmos.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/staking/types"; - -// Query defines the gRPC querier service. -service Query { - // Validators queries all validators that match the given status. - rpc Validators(QueryValidatorsRequest) returns (QueryValidatorsResponse) { - option (google.api.http).get = "/cosmos/staking/v1beta1/validators"; - } - - // Validator queries validator info for given validator address. - rpc Validator(QueryValidatorRequest) returns (QueryValidatorResponse) { - option (google.api.http).get = "/cosmos/staking/v1beta1/validators/{validator_addr}"; - } - - // ValidatorDelegations queries delegate info for given validator. - rpc ValidatorDelegations(QueryValidatorDelegationsRequest) returns (QueryValidatorDelegationsResponse) { - option (google.api.http).get = "/cosmos/staking/v1beta1/validators/{validator_addr}/delegations"; - } - - // ValidatorUnbondingDelegations queries unbonding delegations of a validator. - rpc ValidatorUnbondingDelegations(QueryValidatorUnbondingDelegationsRequest) - returns (QueryValidatorUnbondingDelegationsResponse) { - option (google.api.http).get = "/cosmos/staking/v1beta1/validators/" - "{validator_addr}/unbonding_delegations"; - } - - // Delegation queries delegate info for given validator delegator pair. - rpc Delegation(QueryDelegationRequest) returns (QueryDelegationResponse) { - option (google.api.http).get = "/cosmos/staking/v1beta1/validators/{validator_addr}/delegations/" - "{delegator_addr}"; - } - - // UnbondingDelegation queries unbonding info for given validator delegator - // pair. - rpc UnbondingDelegation(QueryUnbondingDelegationRequest) returns (QueryUnbondingDelegationResponse) { - option (google.api.http).get = "/cosmos/staking/v1beta1/validators/{validator_addr}/delegations/" - "{delegator_addr}/unbonding_delegation"; - } - - // DelegatorDelegations queries all delegations of a given delegator address. - rpc DelegatorDelegations(QueryDelegatorDelegationsRequest) returns (QueryDelegatorDelegationsResponse) { - option (google.api.http).get = "/cosmos/staking/v1beta1/delegations/{delegator_addr}"; - } - - // DelegatorUnbondingDelegations queries all unbonding delegations of a given - // delegator address. - rpc DelegatorUnbondingDelegations(QueryDelegatorUnbondingDelegationsRequest) - returns (QueryDelegatorUnbondingDelegationsResponse) { - option (google.api.http).get = "/cosmos/staking/v1beta1/delegators/" - "{delegator_addr}/unbonding_delegations"; - } - - // Redelegations queries redelegations of given address. - rpc Redelegations(QueryRedelegationsRequest) returns (QueryRedelegationsResponse) { - option (google.api.http).get = "/cosmos/staking/v1beta1/delegators/{delegator_addr}/redelegations"; - } - - // DelegatorValidators queries all validators info for given delegator - // address. - rpc DelegatorValidators(QueryDelegatorValidatorsRequest) returns (QueryDelegatorValidatorsResponse) { - option (google.api.http).get = "/cosmos/staking/v1beta1/delegators/{delegator_addr}/validators"; - } - - // DelegatorValidator queries validator info for given delegator validator - // pair. - rpc DelegatorValidator(QueryDelegatorValidatorRequest) returns (QueryDelegatorValidatorResponse) { - option (google.api.http).get = "/cosmos/staking/v1beta1/delegators/{delegator_addr}/validators/" - "{validator_addr}"; - } - - // HistoricalInfo queries the historical info for given height. - rpc HistoricalInfo(QueryHistoricalInfoRequest) returns (QueryHistoricalInfoResponse) { - option (google.api.http).get = "/cosmos/staking/v1beta1/historical_info/{height}"; - } - - // Pool queries the pool info. - rpc Pool(QueryPoolRequest) returns (QueryPoolResponse) { - option (google.api.http).get = "/cosmos/staking/v1beta1/pool"; - } - - // Parameters queries the staking parameters. - rpc Params(QueryParamsRequest) returns (QueryParamsResponse) { - option (google.api.http).get = "/cosmos/staking/v1beta1/params"; - } -} - -// QueryValidatorsRequest is request type for Query/Validators RPC method. -message QueryValidatorsRequest { - // status enables to query for validators matching a given status. - string status = 1; - - // pagination defines an optional pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} - -// QueryValidatorsResponse is response type for the Query/Validators RPC method -message QueryValidatorsResponse { - // validators contains all the queried validators. - repeated Validator validators = 1 [(gogoproto.nullable) = false]; - - // pagination defines the pagination in the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryValidatorRequest is response type for the Query/Validator RPC method -message QueryValidatorRequest { - // validator_addr defines the validator address to query for. - string validator_addr = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// QueryValidatorResponse is response type for the Query/Validator RPC method -message QueryValidatorResponse { - // validator defines the the validator info. - Validator validator = 1 [(gogoproto.nullable) = false]; -} - -// QueryValidatorDelegationsRequest is request type for the -// Query/ValidatorDelegations RPC method -message QueryValidatorDelegationsRequest { - // validator_addr defines the validator address to query for. - string validator_addr = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // pagination defines an optional pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} - -// QueryValidatorDelegationsResponse is response type for the -// Query/ValidatorDelegations RPC method -message QueryValidatorDelegationsResponse { - repeated DelegationResponse delegation_responses = 1 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "DelegationResponses"]; - - // pagination defines the pagination in the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryValidatorUnbondingDelegationsRequest is required type for the -// Query/ValidatorUnbondingDelegations RPC method -message QueryValidatorUnbondingDelegationsRequest { - // validator_addr defines the validator address to query for. - string validator_addr = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // pagination defines an optional pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} - -// QueryValidatorUnbondingDelegationsResponse is response type for the -// Query/ValidatorUnbondingDelegations RPC method. -message QueryValidatorUnbondingDelegationsResponse { - repeated UnbondingDelegation unbonding_responses = 1 [(gogoproto.nullable) = false]; - - // pagination defines the pagination in the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryDelegationRequest is request type for the Query/Delegation RPC method. -message QueryDelegationRequest { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // delegator_addr defines the delegator address to query for. - string delegator_addr = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // validator_addr defines the validator address to query for. - string validator_addr = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// QueryDelegationResponse is response type for the Query/Delegation RPC method. -message QueryDelegationResponse { - // delegation_responses defines the delegation info of a delegation. - DelegationResponse delegation_response = 1; -} - -// QueryUnbondingDelegationRequest is request type for the -// Query/UnbondingDelegation RPC method. -message QueryUnbondingDelegationRequest { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // delegator_addr defines the delegator address to query for. - string delegator_addr = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // validator_addr defines the validator address to query for. - string validator_addr = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// QueryDelegationResponse is response type for the Query/UnbondingDelegation -// RPC method. -message QueryUnbondingDelegationResponse { - // unbond defines the unbonding information of a delegation. - UnbondingDelegation unbond = 1 [(gogoproto.nullable) = false]; -} - -// QueryDelegatorDelegationsRequest is request type for the -// Query/DelegatorDelegations RPC method. -message QueryDelegatorDelegationsRequest { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // delegator_addr defines the delegator address to query for. - string delegator_addr = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // pagination defines an optional pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} - -// QueryDelegatorDelegationsResponse is response type for the -// Query/DelegatorDelegations RPC method. -message QueryDelegatorDelegationsResponse { - // delegation_responses defines all the delegations' info of a delegator. - repeated DelegationResponse delegation_responses = 1 [(gogoproto.nullable) = false]; - - // pagination defines the pagination in the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryDelegatorUnbondingDelegationsRequest is request type for the -// Query/DelegatorUnbondingDelegations RPC method. -message QueryDelegatorUnbondingDelegationsRequest { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // delegator_addr defines the delegator address to query for. - string delegator_addr = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // pagination defines an optional pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} - -// QueryUnbondingDelegatorDelegationsResponse is response type for the -// Query/UnbondingDelegatorDelegations RPC method. -message QueryDelegatorUnbondingDelegationsResponse { - repeated UnbondingDelegation unbonding_responses = 1 [(gogoproto.nullable) = false]; - - // pagination defines the pagination in the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryRedelegationsRequest is request type for the Query/Redelegations RPC -// method. -message QueryRedelegationsRequest { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // delegator_addr defines the delegator address to query for. - string delegator_addr = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // src_validator_addr defines the validator address to redelegate from. - string src_validator_addr = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // dst_validator_addr defines the validator address to redelegate to. - string dst_validator_addr = 3 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // pagination defines an optional pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 4; -} - -// QueryRedelegationsResponse is response type for the Query/Redelegations RPC -// method. -message QueryRedelegationsResponse { - repeated RedelegationResponse redelegation_responses = 1 [(gogoproto.nullable) = false]; - - // pagination defines the pagination in the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryDelegatorValidatorsRequest is request type for the -// Query/DelegatorValidators RPC method. -message QueryDelegatorValidatorsRequest { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // delegator_addr defines the delegator address to query for. - string delegator_addr = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // pagination defines an optional pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} - -// QueryDelegatorValidatorsResponse is response type for the -// Query/DelegatorValidators RPC method. -message QueryDelegatorValidatorsResponse { - // validators defines the the validators' info of a delegator. - repeated Validator validators = 1 [(gogoproto.nullable) = false]; - - // pagination defines the pagination in the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -// QueryDelegatorValidatorRequest is request type for the -// Query/DelegatorValidator RPC method. -message QueryDelegatorValidatorRequest { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // delegator_addr defines the delegator address to query for. - string delegator_addr = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // validator_addr defines the validator address to query for. - string validator_addr = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// QueryDelegatorValidatorResponse response type for the -// Query/DelegatorValidator RPC method. -message QueryDelegatorValidatorResponse { - // validator defines the the validator info. - Validator validator = 1 [(gogoproto.nullable) = false]; -} - -// QueryHistoricalInfoRequest is request type for the Query/HistoricalInfo RPC -// method. -message QueryHistoricalInfoRequest { - // height defines at which height to query the historical info. - int64 height = 1; -} - -// QueryHistoricalInfoResponse is response type for the Query/HistoricalInfo RPC -// method. -message QueryHistoricalInfoResponse { - // hist defines the historical info at the given height. - HistoricalInfo hist = 1; -} - -// QueryPoolRequest is request type for the Query/Pool RPC method. -message QueryPoolRequest {} - -// QueryPoolResponse is response type for the Query/Pool RPC method. -message QueryPoolResponse { - // pool defines the pool info. - Pool pool = 1 [(gogoproto.nullable) = false]; -} - -// QueryParamsRequest is request type for the Query/Params RPC method. -message QueryParamsRequest {} - -// QueryParamsResponse is response type for the Query/Params RPC method. -message QueryParamsResponse { - // params holds all the parameters of this module. - Params params = 1 [(gogoproto.nullable) = false]; -} diff --git a/src/cosmospy_protobuf/cosmos/staking/v1beta1/staking.proto b/src/cosmospy_protobuf/cosmos/staking/v1beta1/staking.proto deleted file mode 100644 index dcf2645f..00000000 --- a/src/cosmospy_protobuf/cosmos/staking/v1beta1/staking.proto +++ /dev/null @@ -1,358 +0,0 @@ -syntax = "proto3"; -package cosmos.staking.v1beta1; - -import "gogoproto/gogo.proto"; -import "google/protobuf/any.proto"; -import "google/protobuf/duration.proto"; -import "google/protobuf/timestamp.proto"; - -import "cosmos_proto/cosmos.proto"; -import "cosmos/base/v1beta1/coin.proto"; -import "tendermint/types/types.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/staking/types"; - -// 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). -message HistoricalInfo { - tendermint.types.Header header = 1 [(gogoproto.nullable) = false]; - repeated Validator valset = 2 [(gogoproto.nullable) = false]; -} - -// CommissionRates defines the initial commission rates to be used for creating -// a validator. -message CommissionRates { - option (gogoproto.equal) = true; - option (gogoproto.goproto_stringer) = false; - - // rate is the commission rate charged to delegators, as a fraction. - string rate = 1 [ - (cosmos_proto.scalar) = "cosmos.Dec", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false - ]; - // max_rate defines the maximum commission rate which validator can ever charge, as a fraction. - string max_rate = 2 [ - (cosmos_proto.scalar) = "cosmos.Dec", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false - ]; - // max_change_rate defines the maximum daily increase of the validator commission, as a fraction. - string max_change_rate = 3 [ - (cosmos_proto.scalar) = "cosmos.Dec", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false - ]; -} - -// Commission defines commission parameters for a given validator. -message Commission { - option (gogoproto.equal) = true; - option (gogoproto.goproto_stringer) = false; - - // commission_rates defines the initial commission rates to be used for creating a validator. - CommissionRates commission_rates = 1 [(gogoproto.embed) = true, (gogoproto.nullable) = false]; - // update_time is the last time the commission rate was changed. - google.protobuf.Timestamp update_time = 2 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; -} - -// Description defines a validator description. -message Description { - option (gogoproto.equal) = true; - option (gogoproto.goproto_stringer) = false; - - // moniker defines a human-readable name for the validator. - string moniker = 1; - // identity defines an optional identity signature (ex. UPort or Keybase). - string identity = 2; - // website defines an optional website link. - string website = 3; - // security_contact defines an optional email for security contact. - string security_contact = 4; - // details define other optional details. - string details = 5; -} - -// 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. -message Validator { - option (gogoproto.equal) = false; - option (gogoproto.goproto_stringer) = false; - option (gogoproto.goproto_getters) = false; - - // operator_address defines the address of the validator's operator; bech encoded in JSON. - string operator_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - // consensus_pubkey is the consensus public key of the validator, as a Protobuf Any. - google.protobuf.Any consensus_pubkey = 2 [(cosmos_proto.accepts_interface) = "cosmos.crypto.PubKey"]; - // jailed defined whether the validator has been jailed from bonded status or not. - bool jailed = 3; - // status is the validator status (bonded/unbonding/unbonded). - BondStatus status = 4; - // tokens define the delegated tokens (incl. self-delegation). - string tokens = 5 [ - (cosmos_proto.scalar) = "cosmos.Int", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.nullable) = false - ]; - // delegator_shares defines total shares issued to a validator's delegators. - string delegator_shares = 6 [ - (cosmos_proto.scalar) = "cosmos.Dec", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false - ]; - // description defines the description terms for the validator. - Description description = 7 [(gogoproto.nullable) = false]; - // unbonding_height defines, if unbonding, the height at which this validator has begun unbonding. - int64 unbonding_height = 8; - // unbonding_time defines, if unbonding, the min time for the validator to complete unbonding. - google.protobuf.Timestamp unbonding_time = 9 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; - // commission defines the commission parameters. - Commission commission = 10 [(gogoproto.nullable) = false]; - // min_self_delegation is the validator's self declared minimum self delegation. - string min_self_delegation = 11 [ - (cosmos_proto.scalar) = "cosmos.Int", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.nullable) = false - ]; -} - -// BondStatus is the status of a validator. -enum BondStatus { - option (gogoproto.goproto_enum_prefix) = false; - - // UNSPECIFIED defines an invalid validator status. - BOND_STATUS_UNSPECIFIED = 0 [(gogoproto.enumvalue_customname) = "Unspecified"]; - // UNBONDED defines a validator that is not bonded. - BOND_STATUS_UNBONDED = 1 [(gogoproto.enumvalue_customname) = "Unbonded"]; - // UNBONDING defines a validator that is unbonding. - BOND_STATUS_UNBONDING = 2 [(gogoproto.enumvalue_customname) = "Unbonding"]; - // BONDED defines a validator that is bonded. - BOND_STATUS_BONDED = 3 [(gogoproto.enumvalue_customname) = "Bonded"]; -} - -// ValAddresses defines a repeated set of validator addresses. -message ValAddresses { - option (gogoproto.goproto_stringer) = false; - option (gogoproto.stringer) = true; - - repeated string addresses = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// DVPair is struct that just has a delegator-validator pair with no other data. -// It is intended to be used as a marshalable pointer. For example, a DVPair can -// be used to construct the key to getting an UnbondingDelegation from state. -message DVPair { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - option (gogoproto.goproto_stringer) = false; - - string delegator_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - string validator_address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// DVPairs defines an array of DVPair objects. -message DVPairs { - repeated DVPair pairs = 1 [(gogoproto.nullable) = false]; -} - -// DVVTriplet is struct that just has a delegator-validator-validator triplet -// with no other data. It is intended to be used as a marshalable pointer. For -// example, a DVVTriplet can be used to construct the key to getting a -// Redelegation from state. -message DVVTriplet { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - option (gogoproto.goproto_stringer) = false; - - string delegator_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - string validator_src_address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - string validator_dst_address = 3 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// DVVTriplets defines an array of DVVTriplet objects. -message DVVTriplets { - repeated DVVTriplet triplets = 1 [(gogoproto.nullable) = false]; -} - -// 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. -message Delegation { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - option (gogoproto.goproto_stringer) = false; - - // delegator_address is the bech32-encoded address of the delegator. - string delegator_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - // validator_address is the bech32-encoded address of the validator. - string validator_address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - // shares define the delegation shares received. - string shares = 3 [ - (cosmos_proto.scalar) = "cosmos.Dec", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false - ]; -} - -// UnbondingDelegation stores all of a single delegator's unbonding bonds -// for a single validator in an time-ordered list. -message UnbondingDelegation { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - option (gogoproto.goproto_stringer) = false; - - // delegator_address is the bech32-encoded address of the delegator. - string delegator_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - // validator_address is the bech32-encoded address of the validator. - string validator_address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - // entries are the unbonding delegation entries. - repeated UnbondingDelegationEntry entries = 3 [(gogoproto.nullable) = false]; // unbonding delegation entries -} - -// UnbondingDelegationEntry defines an unbonding object with relevant metadata. -message UnbondingDelegationEntry { - option (gogoproto.equal) = true; - option (gogoproto.goproto_stringer) = false; - - // creation_height is the height which the unbonding took place. - int64 creation_height = 1; - // completion_time is the unix time for unbonding completion. - google.protobuf.Timestamp completion_time = 2 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; - // initial_balance defines the tokens initially scheduled to receive at completion. - string initial_balance = 3 [ - (cosmos_proto.scalar) = "cosmos.Int", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.nullable) = false - ]; - // balance defines the tokens to receive at completion. - string balance = 4 [ - (cosmos_proto.scalar) = "cosmos.Int", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.nullable) = false - ]; -} - -// RedelegationEntry defines a redelegation object with relevant metadata. -message RedelegationEntry { - option (gogoproto.equal) = true; - option (gogoproto.goproto_stringer) = false; - - // creation_height defines the height which the redelegation took place. - int64 creation_height = 1; - // completion_time defines the unix time for redelegation completion. - google.protobuf.Timestamp completion_time = 2 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; - // initial_balance defines the initial balance when redelegation started. - string initial_balance = 3 [ - (cosmos_proto.scalar) = "cosmos.Int", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.nullable) = false - ]; - // shares_dst is the amount of destination-validator shares created by redelegation. - string shares_dst = 4 [ - (cosmos_proto.scalar) = "cosmos.Dec", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false - ]; -} - -// Redelegation contains the list of a particular delegator's redelegating bonds -// from a particular source validator to a particular destination validator. -message Redelegation { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - option (gogoproto.goproto_stringer) = false; - - // delegator_address is the bech32-encoded address of the delegator. - string delegator_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - // validator_src_address is the validator redelegation source operator address. - string validator_src_address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - // validator_dst_address is the validator redelegation destination operator address. - string validator_dst_address = 3 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - // entries are the redelegation entries. - repeated RedelegationEntry entries = 4 [(gogoproto.nullable) = false]; // redelegation entries -} - -// Params defines the parameters for the staking module. -message Params { - option (gogoproto.equal) = true; - option (gogoproto.goproto_stringer) = false; - - // unbonding_time is the time duration of unbonding. - google.protobuf.Duration unbonding_time = 1 [(gogoproto.nullable) = false, (gogoproto.stdduration) = true]; - // max_validators is the maximum number of validators. - uint32 max_validators = 2; - // max_entries is the max entries for either unbonding delegation or redelegation (per pair/trio). - uint32 max_entries = 3; - // historical_entries is the number of historical entries to persist. - uint32 historical_entries = 4; - // bond_denom defines the bondable coin denomination. - string bond_denom = 5; - // min_commission_rate is the chain-wide minimum commission rate that a validator can charge their delegators - string min_commission_rate = 6 [ - (gogoproto.moretags) = "yaml:\"min_commission_rate\"", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false - ]; -} - -// DelegationResponse is equivalent to Delegation except that it contains a -// balance in addition to shares which is more suitable for client responses. -message DelegationResponse { - option (gogoproto.equal) = false; - option (gogoproto.goproto_stringer) = false; - - Delegation delegation = 1 [(gogoproto.nullable) = false]; - - cosmos.base.v1beta1.Coin balance = 2 [(gogoproto.nullable) = false]; -} - -// RedelegationEntryResponse is equivalent to a RedelegationEntry except that it -// contains a balance in addition to shares which is more suitable for client -// responses. -message RedelegationEntryResponse { - option (gogoproto.equal) = true; - - RedelegationEntry redelegation_entry = 1 [(gogoproto.nullable) = false]; - string balance = 4 [ - (cosmos_proto.scalar) = "cosmos.Int", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.nullable) = false - ]; -} - -// RedelegationResponse is equivalent to a Redelegation except that its entries -// contain a balance in addition to shares which is more suitable for client -// responses. -message RedelegationResponse { - option (gogoproto.equal) = false; - - Redelegation redelegation = 1 [(gogoproto.nullable) = false]; - repeated RedelegationEntryResponse entries = 2 [(gogoproto.nullable) = false]; -} - -// Pool is used for tracking bonded and not-bonded token supply of the bond -// denomination. -message Pool { - option (gogoproto.description) = true; - option (gogoproto.equal) = true; - string not_bonded_tokens = 1 [ - (cosmos_proto.scalar) = "cosmos.Int", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "not_bonded_tokens" - ]; - string bonded_tokens = 2 [ - (cosmos_proto.scalar) = "cosmos.Int", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.nullable) = false, - (gogoproto.jsontag) = "bonded_tokens" - ]; -} diff --git a/src/cosmospy_protobuf/cosmos/staking/v1beta1/tx.proto b/src/cosmospy_protobuf/cosmos/staking/v1beta1/tx.proto deleted file mode 100644 index b7dac398..00000000 --- a/src/cosmospy_protobuf/cosmos/staking/v1beta1/tx.proto +++ /dev/null @@ -1,159 +0,0 @@ -syntax = "proto3"; -package cosmos.staking.v1beta1; - -import "google/protobuf/any.proto"; -import "google/protobuf/timestamp.proto"; -import "gogoproto/gogo.proto"; - -import "cosmos_proto/cosmos.proto"; -import "cosmos/base/v1beta1/coin.proto"; -import "cosmos/staking/v1beta1/staking.proto"; - -import "cosmos/msg/v1/msg.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/staking/types"; - -// Msg defines the staking Msg service. -service Msg { - // CreateValidator defines a method for creating a new validator. - rpc CreateValidator(MsgCreateValidator) returns (MsgCreateValidatorResponse); - - // EditValidator defines a method for editing an existing validator. - rpc EditValidator(MsgEditValidator) returns (MsgEditValidatorResponse); - - // Delegate defines a method for performing a delegation of coins - // from a delegator to a validator. - rpc Delegate(MsgDelegate) returns (MsgDelegateResponse); - - // BeginRedelegate defines a method for performing a redelegation - // of coins from a delegator and source validator to a destination validator. - rpc BeginRedelegate(MsgBeginRedelegate) returns (MsgBeginRedelegateResponse); - - // Undelegate defines a method for performing an undelegation from a - // delegate and a validator. - rpc Undelegate(MsgUndelegate) returns (MsgUndelegateResponse); - - // CancelUnbondingDelegation defines a method for performing canceling the unbonding delegation - // and delegate back to previous validator. - rpc CancelUnbondingDelegation(MsgCancelUnbondingDelegation) returns (MsgCancelUnbondingDelegationResponse); -} - -// MsgCreateValidator defines a SDK message for creating a new validator. -message MsgCreateValidator { - // NOTE(fdymylja): this is a particular case in which - // if validator_address == delegator_address then only one - // is expected to sign, otherwise both are. - option (cosmos.msg.v1.signer) = "delegator_address"; - option (cosmos.msg.v1.signer) = "validator_address"; - - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - Description description = 1 [(gogoproto.nullable) = false]; - CommissionRates commission = 2 [(gogoproto.nullable) = false]; - string min_self_delegation = 3 [ - (cosmos_proto.scalar) = "cosmos.Int", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.nullable) = false - ]; - string delegator_address = 4 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - string validator_address = 5 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - google.protobuf.Any pubkey = 6 [(cosmos_proto.accepts_interface) = "cosmos.crypto.PubKey"]; - cosmos.base.v1beta1.Coin value = 7 [(gogoproto.nullable) = false]; -} - -// MsgCreateValidatorResponse defines the Msg/CreateValidator response type. -message MsgCreateValidatorResponse {} - -// MsgEditValidator defines a SDK message for editing an existing validator. -message MsgEditValidator { - option (cosmos.msg.v1.signer) = "validator_address"; - - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - Description description = 1 [(gogoproto.nullable) = false]; - string validator_address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // We pass a reference to the new commission rate and min self delegation as - // it's not mandatory to update. If not updated, the deserialized rate will be - // zero with no way to distinguish if an update was intended. - // REF: #2373 - string commission_rate = 3 - [(cosmos_proto.scalar) = "cosmos.Dec", (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec"]; - string min_self_delegation = 4 - [(cosmos_proto.scalar) = "cosmos.Int", (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int"]; -} - -// MsgEditValidatorResponse defines the Msg/EditValidator response type. -message MsgEditValidatorResponse {} - -// MsgDelegate defines a SDK message for performing a delegation of coins -// from a delegator to a validator. -message MsgDelegate { - option (cosmos.msg.v1.signer) = "delegator_address"; - - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - string delegator_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - string validator_address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - cosmos.base.v1beta1.Coin amount = 3 [(gogoproto.nullable) = false]; -} - -// MsgDelegateResponse defines the Msg/Delegate response type. -message MsgDelegateResponse {} - -// MsgBeginRedelegate defines a SDK message for performing a redelegation -// of coins from a delegator and source validator to a destination validator. -message MsgBeginRedelegate { - option (cosmos.msg.v1.signer) = "delegator_address"; - - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - string delegator_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - string validator_src_address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - string validator_dst_address = 3 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - cosmos.base.v1beta1.Coin amount = 4 [(gogoproto.nullable) = false]; -} - -// MsgBeginRedelegateResponse defines the Msg/BeginRedelegate response type. -message MsgBeginRedelegateResponse { - google.protobuf.Timestamp completion_time = 1 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; -} - -// MsgUndelegate defines a SDK message for performing an undelegation from a -// delegate and a validator. -message MsgUndelegate { - option (cosmos.msg.v1.signer) = "delegator_address"; - - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - string delegator_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - string validator_address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - cosmos.base.v1beta1.Coin amount = 3 [(gogoproto.nullable) = false]; -} - -// MsgUndelegateResponse defines the Msg/Undelegate response type. -message MsgUndelegateResponse { - google.protobuf.Timestamp completion_time = 1 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; -} - -// MsgCancelUnbondingDelegation defines the SDK message for performing a cancel unbonding delegation for delegator -message MsgCancelUnbondingDelegation{ - option (cosmos.msg.v1.signer) = "delegator_address"; - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - string delegator_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - string validator_address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - // amount is always less than or equal to unbonding delegation entry balance - cosmos.base.v1beta1.Coin amount = 3 [(gogoproto.nullable) = false]; - // creation_height is the height which the unbonding took place. - int64 creation_height = 4; -} - -// MsgCancelUnbondingDelegationResponse -message MsgCancelUnbondingDelegationResponse{} diff --git a/src/cosmospy_protobuf/cosmos/tx/signing/v1beta1/signing.proto b/src/cosmospy_protobuf/cosmos/tx/signing/v1beta1/signing.proto deleted file mode 100644 index 13fa0393..00000000 --- a/src/cosmospy_protobuf/cosmos/tx/signing/v1beta1/signing.proto +++ /dev/null @@ -1,106 +0,0 @@ -syntax = "proto3"; -package cosmos.tx.signing.v1beta1; - -import "cosmos/crypto/multisig/v1beta1/multisig.proto"; -import "google/protobuf/any.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/types/tx/signing"; - -// 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. -enum SignMode { - // SIGN_MODE_UNSPECIFIED specifies an unknown signing mode and will be - // rejected. - SIGN_MODE_UNSPECIFIED = 0; - - // SIGN_MODE_DIRECT specifies a signing mode which uses SignDoc and is - // verified with raw bytes from Tx. - SIGN_MODE_DIRECT = 1; - - // 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_TEXTUAL = 2; - - // 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_DIRECT_AUX = 3; - - // SIGN_MODE_LEGACY_AMINO_JSON is a backwards compatibility mode which uses - // Amino JSON and will be removed in the future. - SIGN_MODE_LEGACY_AMINO_JSON = 127; - - // 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 - SIGN_MODE_EIP_191 = 191; -} - -// SignatureDescriptors wraps multiple SignatureDescriptor's. -message SignatureDescriptors { - // signatures are the signature descriptors - repeated SignatureDescriptor signatures = 1; -} - -// SignatureDescriptor is a convenience type which represents the full data for -// a signature including the public key of the signer, signing modes and the -// signature itself. It is primarily used for coordinating signatures between -// clients. -message SignatureDescriptor { - // public_key is the public key of the signer - google.protobuf.Any public_key = 1; - - Data data = 2; - - // 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. - uint64 sequence = 3; - - // Data represents signature data - message Data { - // sum is the oneof that specifies whether this represents single or multi-signature data - oneof sum { - // single represents a single signer - Single single = 1; - - // multi represents a multisig signer - Multi multi = 2; - } - - // Single is the signature data for a single signer - message Single { - // mode is the signing mode of the single signer - SignMode mode = 1; - - // signature is the raw signature bytes - bytes signature = 2; - } - - // Multi is the signature data for a multisig public key - message Multi { - // bitarray specifies which keys within the multisig are signing - cosmos.crypto.multisig.v1beta1.CompactBitArray bitarray = 1; - - // signatures is the signatures of the multi-signature - repeated Data signatures = 2; - } - } -} diff --git a/src/cosmospy_protobuf/cosmos/tx/v1beta1/service.proto b/src/cosmospy_protobuf/cosmos/tx/v1beta1/service.proto deleted file mode 100644 index e7af1526..00000000 --- a/src/cosmospy_protobuf/cosmos/tx/v1beta1/service.proto +++ /dev/null @@ -1,163 +0,0 @@ -syntax = "proto3"; -package cosmos.tx.v1beta1; - -import "google/api/annotations.proto"; -import "cosmos/base/abci/v1beta1/abci.proto"; -import "cosmos/tx/v1beta1/tx.proto"; -import "cosmos/base/query/v1beta1/pagination.proto"; -import "tendermint/types/block.proto"; -import "tendermint/types/types.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/types/tx"; - -// Service defines a gRPC service for interacting with transactions. -service Service { - // Simulate simulates executing a transaction for estimating gas usage. - rpc Simulate(SimulateRequest) returns (SimulateResponse) { - option (google.api.http) = { - post: "/cosmos/tx/v1beta1/simulate" - body: "*" - }; - } - // GetTx fetches a tx by hash. - rpc GetTx(GetTxRequest) returns (GetTxResponse) { - option (google.api.http).get = "/cosmos/tx/v1beta1/txs/{hash}"; - } - // BroadcastTx broadcast transaction. - rpc BroadcastTx(BroadcastTxRequest) returns (BroadcastTxResponse) { - option (google.api.http) = { - post: "/cosmos/tx/v1beta1/txs" - body: "*" - }; - } - // GetTxsEvent fetches txs by event. - rpc GetTxsEvent(GetTxsEventRequest) returns (GetTxsEventResponse) { - option (google.api.http).get = "/cosmos/tx/v1beta1/txs"; - } - // GetBlockWithTxs fetches a block with decoded txs. - // - // Since: cosmos-sdk 0.45.2 - rpc GetBlockWithTxs(GetBlockWithTxsRequest) returns (GetBlockWithTxsResponse) { - option (google.api.http).get = "/cosmos/tx/v1beta1/txs/block/{height}"; - } -} - -// GetTxsEventRequest is the request type for the Service.TxsByEvents -// RPC method. -message GetTxsEventRequest { - // events is the list of transaction event type. - repeated string events = 1; - // pagination defines a pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 2; - OrderBy order_by = 3; -} - -// OrderBy defines the sorting order -enum OrderBy { - // ORDER_BY_UNSPECIFIED specifies an unknown sorting order. OrderBy defaults to ASC in this case. - ORDER_BY_UNSPECIFIED = 0; - // ORDER_BY_ASC defines ascending order - ORDER_BY_ASC = 1; - // ORDER_BY_DESC defines descending order - ORDER_BY_DESC = 2; -} - -// GetTxsEventResponse is the response type for the Service.TxsByEvents -// RPC method. -message GetTxsEventResponse { - // txs is the list of queried transactions. - repeated cosmos.tx.v1beta1.Tx txs = 1; - // tx_responses is the list of queried TxResponses. - repeated cosmos.base.abci.v1beta1.TxResponse tx_responses = 2; - // pagination defines a pagination for the response. - cosmos.base.query.v1beta1.PageResponse pagination = 3; -} - -// BroadcastTxRequest is the request type for the Service.BroadcastTxRequest -// RPC method. -message BroadcastTxRequest { - // tx_bytes is the raw transaction. - bytes tx_bytes = 1; - BroadcastMode mode = 2; -} - -// BroadcastMode specifies the broadcast mode for the TxService.Broadcast RPC method. -enum BroadcastMode { - // zero-value for mode ordering - BROADCAST_MODE_UNSPECIFIED = 0; - // BROADCAST_MODE_BLOCK defines a tx broadcasting mode where the client waits for - // the tx to be committed in a block. - BROADCAST_MODE_BLOCK = 1; - // BROADCAST_MODE_SYNC defines a tx broadcasting mode where the client waits for - // a CheckTx execution response only. - BROADCAST_MODE_SYNC = 2; - // BROADCAST_MODE_ASYNC defines a tx broadcasting mode where the client returns - // immediately. - BROADCAST_MODE_ASYNC = 3; -} - -// BroadcastTxResponse is the response type for the -// Service.BroadcastTx method. -message BroadcastTxResponse { - // tx_response is the queried TxResponses. - cosmos.base.abci.v1beta1.TxResponse tx_response = 1; -} - -// SimulateRequest is the request type for the Service.Simulate -// RPC method. -message SimulateRequest { - // tx is the transaction to simulate. - // Deprecated. Send raw tx bytes instead. - cosmos.tx.v1beta1.Tx tx = 1 [deprecated = true]; - // tx_bytes is the raw transaction. - // - // Since: cosmos-sdk 0.43 - bytes tx_bytes = 2; -} - -// SimulateResponse is the response type for the -// Service.SimulateRPC method. -message SimulateResponse { - // gas_info is the information about gas used in the simulation. - cosmos.base.abci.v1beta1.GasInfo gas_info = 1; - // result is the result of the simulation. - cosmos.base.abci.v1beta1.Result result = 2; -} - -// GetTxRequest is the request type for the Service.GetTx -// RPC method. -message GetTxRequest { - // hash is the tx hash to query, encoded as a hex string. - string hash = 1; -} - -// GetTxResponse is the response type for the Service.GetTx method. -message GetTxResponse { - // tx is the queried transaction. - cosmos.tx.v1beta1.Tx tx = 1; - // tx_response is the queried TxResponses. - cosmos.base.abci.v1beta1.TxResponse tx_response = 2; -} - -// GetBlockWithTxsRequest is the request type for the Service.GetBlockWithTxs -// RPC method. -// -// Since: cosmos-sdk 0.45.2 -message GetBlockWithTxsRequest { - // height is the height of the block to query. - int64 height = 1; - // pagination defines a pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} - -// GetBlockWithTxsResponse is the response type for the Service.GetBlockWithTxs method. -// -// Since: cosmos-sdk 0.45.2 -message GetBlockWithTxsResponse { - // txs are the transactions in the block. - repeated cosmos.tx.v1beta1.Tx txs = 1; - .tendermint.types.BlockID block_id = 2; - .tendermint.types.Block block = 3; - // pagination defines a pagination for the response. - cosmos.base.query.v1beta1.PageResponse pagination = 4; -} \ No newline at end of file diff --git a/src/cosmospy_protobuf/cosmos/tx/v1beta1/tx.proto b/src/cosmospy_protobuf/cosmos/tx/v1beta1/tx.proto deleted file mode 100644 index b015604e..00000000 --- a/src/cosmospy_protobuf/cosmos/tx/v1beta1/tx.proto +++ /dev/null @@ -1,249 +0,0 @@ -syntax = "proto3"; -package cosmos.tx.v1beta1; - -import "gogoproto/gogo.proto"; -import "cosmos/crypto/multisig/v1beta1/multisig.proto"; -import "cosmos/base/v1beta1/coin.proto"; -import "cosmos/tx/signing/v1beta1/signing.proto"; -import "google/protobuf/any.proto"; -import "cosmos_proto/cosmos.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/types/tx"; - -// Tx is the standard type used for broadcasting transactions. -message Tx { - // body is the processable content of the transaction - TxBody body = 1; - - // auth_info is the authorization related content of the transaction, - // specifically signers, signer modes and fee - AuthInfo auth_info = 2; - - // 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. - repeated bytes signatures = 3; -} - -// TxRaw is a variant of Tx that pins the signer's exact binary representation -// of body and auth_info. This is used for signing, broadcasting and -// verification. The binary `serialize(tx: TxRaw)` is stored in Tendermint and -// the hash `sha256(serialize(tx: TxRaw))` becomes the "txhash", commonly used -// as the transaction ID. -message TxRaw { - // body_bytes is a protobuf serialization of a TxBody that matches the - // representation in SignDoc. - bytes body_bytes = 1; - - // auth_info_bytes is a protobuf serialization of an AuthInfo that matches the - // representation in SignDoc. - bytes auth_info_bytes = 2; - - // 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. - repeated bytes signatures = 3; -} - -// SignDoc is the type used for generating sign bytes for SIGN_MODE_DIRECT. -message SignDoc { - // body_bytes is protobuf serialization of a TxBody that matches the - // representation in TxRaw. - bytes body_bytes = 1; - - // auth_info_bytes is a protobuf serialization of an AuthInfo that matches the - // representation in TxRaw. - bytes auth_info_bytes = 2; - - // chain_id is the unique identifier of the chain this transaction targets. - // It prevents signed transactions from being used on another chain by an - // attacker - string chain_id = 3; - - // account_number is the account number of the account in state - uint64 account_number = 4; -} - -// SignDocDirectAux is the type used for generating sign bytes for -// SIGN_MODE_DIRECT_AUX. -// -// Since: cosmos-sdk 0.46 -message SignDocDirectAux { - // body_bytes is protobuf serialization of a TxBody that matches the - // representation in TxRaw. - bytes body_bytes = 1; - - // public_key is the public key of the signing account. - google.protobuf.Any public_key = 2; - - // chain_id is the identifier of the chain this transaction targets. - // It prevents signed transactions from being used on another chain by an - // attacker. - string chain_id = 3; - - // account_number is the account number of the account in state. - uint64 account_number = 4; - - // sequence is the sequence number of the signing account. - uint64 sequence = 5; - - // Tip is the optional tip used for meta-transactions. It should be left - // empty if the signer is not the tipper for this transaction. - Tip tip = 6; -} - -// TxBody is the body of a transaction that all signers sign over. -message TxBody { - // 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. - repeated google.protobuf.Any messages = 1; - - // 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). - string memo = 2; - - // timeout is the block height after which this transaction will not - // be processed by the chain - uint64 timeout_height = 3; - - // 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 - repeated google.protobuf.Any extension_options = 1023; - - // 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 - repeated google.protobuf.Any non_critical_extension_options = 2047; -} - -// AuthInfo describes the fee and signer modes that are used to sign a -// transaction. -message AuthInfo { - // 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. - repeated SignerInfo signer_infos = 1; - - // 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. - Fee fee = 2; - - // Tip is the optional tip used for meta-transactions. - // - // Since: cosmos-sdk 0.46 - Tip tip = 3; -} - -// SignerInfo describes the public key and signing mode of a single top-level -// signer. -message SignerInfo { - // 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. - google.protobuf.Any public_key = 1; - - // mode_info describes the signing mode of the signer and is a nested - // structure to support nested multisig pubkey's - ModeInfo mode_info = 2; - - // 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. - uint64 sequence = 3; -} - -// ModeInfo describes the signing mode of a single or nested multisig signer. -message ModeInfo { - // sum is the oneof that specifies whether this represents a single or nested - // multisig signer - oneof sum { - // single represents a single signer - Single single = 1; - - // multi represents a nested multisig signer - Multi multi = 2; - } - - // 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 - message Single { - // mode is the signing mode of the single signer - cosmos.tx.signing.v1beta1.SignMode mode = 1; - } - - // Multi is the mode info for a multisig public key - message Multi { - // bitarray specifies which keys within the multisig are signing - cosmos.crypto.multisig.v1beta1.CompactBitArray bitarray = 1; - - // mode_infos is the corresponding modes of the signers of the multisig - // which could include nested multisig public keys - repeated ModeInfo mode_infos = 2; - } -} - -// 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. -message Fee { - // amount is the amount of coins to be paid as a fee - repeated cosmos.base.v1beta1.Coin amount = 1 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; - - // gas_limit is the maximum gas that can be used in transaction processing - // before an out of gas error occurs - uint64 gas_limit = 2; - - // 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. - string payer = 3 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // 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 - string granter = 4 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// Tip is the tip used for meta-transactions. -// -// Since: cosmos-sdk 0.46 -message Tip { - // amount is the amount of the tip - repeated cosmos.base.v1beta1.Coin amount = 1 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; - // tipper is the address of the account paying for the tip - string tipper = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// AuxSignerData is the intermediary format that an auxiliary signer (e.g. a -// tipper) builds and sends to the fee payer (who will build and broadcast the -// actual tx). AuxSignerData is not a valid tx in itself, and will be rejected -// by the node if sent directly as-is. -// -// Since: cosmos-sdk 0.46 -message AuxSignerData { - // address is the bech32-encoded address of the auxiliary signer. If using - // AuxSignerData across different chains, the bech32 prefix of the target - // chain (where the final transaction is broadcasted) should be used. - string address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - // sign_doc is the SIGN_MODE_DIRECT_AUX sign doc that the auxiliary signer - // signs. Note: we use the same sign doc even if we're signing with - // LEGACY_AMINO_JSON. - SignDocDirectAux sign_doc = 2; - // mode is the signing mode of the single signer. - cosmos.tx.signing.v1beta1.SignMode mode = 3; - // sig is the signature of the sign doc. - bytes sig = 4; -} diff --git a/src/cosmospy_protobuf/cosmos/upgrade/v1beta1/query.proto b/src/cosmospy_protobuf/cosmos/upgrade/v1beta1/query.proto deleted file mode 100644 index e8c4baa0..00000000 --- a/src/cosmospy_protobuf/cosmos/upgrade/v1beta1/query.proto +++ /dev/null @@ -1,120 +0,0 @@ -syntax = "proto3"; -package cosmos.upgrade.v1beta1; - -import "google/api/annotations.proto"; -import "cosmos/upgrade/v1beta1/upgrade.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/upgrade/types"; - -// Query defines the gRPC upgrade querier service. -service Query { - // CurrentPlan queries the current upgrade plan. - rpc CurrentPlan(QueryCurrentPlanRequest) returns (QueryCurrentPlanResponse) { - option (google.api.http).get = "/cosmos/upgrade/v1beta1/current_plan"; - } - - // AppliedPlan queries a previously applied upgrade plan by its name. - rpc AppliedPlan(QueryAppliedPlanRequest) returns (QueryAppliedPlanResponse) { - option (google.api.http).get = "/cosmos/upgrade/v1beta1/applied_plan/{name}"; - } - - // 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) - rpc UpgradedConsensusState(QueryUpgradedConsensusStateRequest) returns (QueryUpgradedConsensusStateResponse) { - option deprecated = true; - option (google.api.http).get = "/cosmos/upgrade/v1beta1/upgraded_consensus_state/{last_height}"; - } - - // ModuleVersions queries the list of module versions from state. - // - // Since: cosmos-sdk 0.43 - rpc ModuleVersions(QueryModuleVersionsRequest) returns (QueryModuleVersionsResponse) { - option (google.api.http).get = "/cosmos/upgrade/v1beta1/module_versions"; - } - - // Returns the account with authority to conduct upgrades - rpc Authority(QueryAuthorityRequest) returns (QueryAuthorityResponse) { - option (google.api.http).get = "/cosmos/upgrade/v1beta1/authority"; - } -} - -// QueryCurrentPlanRequest is the request type for the Query/CurrentPlan RPC -// method. -message QueryCurrentPlanRequest {} - -// QueryCurrentPlanResponse is the response type for the Query/CurrentPlan RPC -// method. -message QueryCurrentPlanResponse { - // plan is the current upgrade plan. - Plan plan = 1; -} - -// QueryCurrentPlanRequest is the request type for the Query/AppliedPlan RPC -// method. -message QueryAppliedPlanRequest { - // name is the name of the applied plan to query for. - string name = 1; -} - -// QueryAppliedPlanResponse is the response type for the Query/AppliedPlan RPC -// method. -message QueryAppliedPlanResponse { - // height is the block height at which the plan was applied. - int64 height = 1; -} - -// QueryUpgradedConsensusStateRequest is the request type for the Query/UpgradedConsensusState -// RPC method. -message QueryUpgradedConsensusStateRequest { - option deprecated = true; - - // last height of the current chain must be sent in request - // as this is the height under which next consensus state is stored - int64 last_height = 1; -} - -// QueryUpgradedConsensusStateResponse is the response type for the Query/UpgradedConsensusState -// RPC method. -message QueryUpgradedConsensusStateResponse { - option deprecated = true; - reserved 1; - - // Since: cosmos-sdk 0.43 - bytes upgraded_consensus_state = 2; -} - -// QueryModuleVersionsRequest is the request type for the Query/ModuleVersions -// RPC method. -// -// Since: cosmos-sdk 0.43 -message QueryModuleVersionsRequest { - // 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 - string module_name = 1; -} - -// QueryModuleVersionsResponse is the response type for the Query/ModuleVersions -// RPC method. -// -// Since: cosmos-sdk 0.43 -message QueryModuleVersionsResponse { - // module_versions is a list of module names with their consensus versions. - repeated ModuleVersion module_versions = 1; -} - -// QueryAuthorityRequest is the request type for Query/Authority -// -// Since: cosmos-sdk 0.46 -message QueryAuthorityRequest {} - -// QueryAuthorityResponse is the response type for Query/Authority -// -// Since: cosmos-sdk 0.46 -message QueryAuthorityResponse { - string address = 1; -} \ No newline at end of file diff --git a/src/cosmospy_protobuf/cosmos/upgrade/v1beta1/tx.proto b/src/cosmospy_protobuf/cosmos/upgrade/v1beta1/tx.proto deleted file mode 100644 index 9b04bf44..00000000 --- a/src/cosmospy_protobuf/cosmos/upgrade/v1beta1/tx.proto +++ /dev/null @@ -1,55 +0,0 @@ -syntax = "proto3"; -package cosmos.upgrade.v1beta1; - -import "gogoproto/gogo.proto"; -import "cosmos_proto/cosmos.proto"; -import "cosmos/upgrade/v1beta1/upgrade.proto"; -import "cosmos/msg/v1/msg.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/upgrade/types"; - -// Msg defines the upgrade Msg service. -service Msg { - // SoftwareUpgrade is a governance operation for initiating a software upgrade. - // - // Since: cosmos-sdk 0.46 - rpc SoftwareUpgrade(MsgSoftwareUpgrade) returns (MsgSoftwareUpgradeResponse); - // CancelUpgrade is a governance operation for cancelling a previously - // approvid software upgrade. - // - // Since: cosmos-sdk 0.46 - rpc CancelUpgrade(MsgCancelUpgrade) returns (MsgCancelUpgradeResponse); -} - -// MsgSoftwareUpgrade is the Msg/SoftwareUpgrade request type. -// -// Since: cosmos-sdk 0.46 -message MsgSoftwareUpgrade { - option (cosmos.msg.v1.signer) = "authority"; - - // authority is the address of the governance account. - string authority = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - - // plan is the upgrade plan. - Plan plan = 2 [(gogoproto.nullable) = false]; -} - -// MsgSoftwareUpgradeResponse is the Msg/SoftwareUpgrade response type. -// -// Since: cosmos-sdk 0.46 -message MsgSoftwareUpgradeResponse {} - -// MsgCancelUpgrade is the Msg/CancelUpgrade request type. -// -// Since: cosmos-sdk 0.46 -message MsgCancelUpgrade { - option (cosmos.msg.v1.signer) = "authority"; - - // authority is the address of the governance account. - string authority = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; -} - -// MsgCancelUpgradeResponse is the Msg/CancelUpgrade response type. -// -// Since: cosmos-sdk 0.46 -message MsgCancelUpgradeResponse {} \ No newline at end of file diff --git a/src/cosmospy_protobuf/cosmos/upgrade/v1beta1/upgrade.proto b/src/cosmospy_protobuf/cosmos/upgrade/v1beta1/upgrade.proto deleted file mode 100644 index 4de7d01f..00000000 --- a/src/cosmospy_protobuf/cosmos/upgrade/v1beta1/upgrade.proto +++ /dev/null @@ -1,83 +0,0 @@ -syntax = "proto3"; -package cosmos.upgrade.v1beta1; - -import "google/protobuf/any.proto"; -import "gogoproto/gogo.proto"; -import "google/protobuf/timestamp.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/upgrade/types"; -option (gogoproto.goproto_getters_all) = false; - -// Plan specifies information about a planned upgrade and when it should occur. -message Plan { - option (gogoproto.equal) = true; - option (gogoproto.goproto_stringer) = false; - - // 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. - string name = 1; - - // 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. - google.protobuf.Timestamp time = 2 [deprecated = true, (gogoproto.stdtime) = true, (gogoproto.nullable) = false]; - - // The height at which the upgrade must be performed. - // Only used if Time is not set. - int64 height = 3; - - // Any application specific upgrade info to be included on-chain - // such as a git commit that validators could automatically upgrade to - string info = 4; - - // 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. - google.protobuf.Any upgraded_client_state = 5 [deprecated = true]; -} - -// SoftwareUpgradeProposal is a gov Content type for initiating a software -// upgrade. -// Deprecated: This legacy proposal is deprecated in favor of Msg-based gov -// proposals, see MsgSoftwareUpgrade. -message SoftwareUpgradeProposal { - option deprecated = true; - option (gogoproto.equal) = true; - option (gogoproto.goproto_stringer) = false; - - string title = 1; - string description = 2; - Plan plan = 3 [(gogoproto.nullable) = false]; -} - -// CancelSoftwareUpgradeProposal is a gov Content type for cancelling a software -// upgrade. -// Deprecated: This legacy proposal is deprecated in favor of Msg-based gov -// proposals, see MsgCancelUpgrade. -message CancelSoftwareUpgradeProposal { - option deprecated = true; - option (gogoproto.equal) = true; - option (gogoproto.goproto_stringer) = false; - - string title = 1; - string description = 2; -} - -// ModuleVersion specifies a module and its consensus version. -// -// Since: cosmos-sdk 0.43 -message ModuleVersion { - option (gogoproto.equal) = true; - option (gogoproto.goproto_stringer) = true; - - // name of the app module - string name = 1; - - // consensus version of the app module - uint64 version = 2; -} diff --git a/src/cosmospy_protobuf/cosmos/vesting/v1beta1/tx.proto b/src/cosmospy_protobuf/cosmos/vesting/v1beta1/tx.proto deleted file mode 100644 index 211bad09..00000000 --- a/src/cosmospy_protobuf/cosmos/vesting/v1beta1/tx.proto +++ /dev/null @@ -1,74 +0,0 @@ -syntax = "proto3"; -package cosmos.vesting.v1beta1; - -import "gogoproto/gogo.proto"; -import "cosmos/base/v1beta1/coin.proto"; -import "cosmos_proto/cosmos.proto"; -import "cosmos/vesting/v1beta1/vesting.proto"; - -import "cosmos/msg/v1/msg.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/auth/vesting/types"; - -// Msg defines the bank Msg service. -service Msg { - // CreateVestingAccount defines a method that enables creating a vesting - // account. - rpc CreateVestingAccount(MsgCreateVestingAccount) returns (MsgCreateVestingAccountResponse); - // CreatePermanentLockedAccount defines a method that enables creating a permanent - // locked account. - rpc CreatePermanentLockedAccount(MsgCreatePermanentLockedAccount) returns (MsgCreatePermanentLockedAccountResponse); - // CreatePeriodicVestingAccount defines a method that enables creating a - // periodic vesting account. - rpc CreatePeriodicVestingAccount(MsgCreatePeriodicVestingAccount) returns (MsgCreatePeriodicVestingAccountResponse); -} - -// MsgCreateVestingAccount defines a message that enables creating a vesting -// account. -message MsgCreateVestingAccount { - option (cosmos.msg.v1.signer) = "from_address"; - - option (gogoproto.equal) = true; - - string from_address = 1 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - string to_address = 2 [(cosmos_proto.scalar) = "cosmos.AddressString"]; - repeated cosmos.base.v1beta1.Coin amount = 3 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; - - int64 end_time = 4; - bool delayed = 5; -} - -// MsgCreateVestingAccountResponse defines the Msg/CreateVestingAccount response type. -message MsgCreateVestingAccountResponse {} - -// MsgCreatePermanentLockedAccount defines a message that enables creating a permanent -// locked account. -message MsgCreatePermanentLockedAccount { - option (gogoproto.equal) = true; - - string from_address = 1 [(gogoproto.moretags) = "yaml:\"from_address\""]; - string to_address = 2 [(gogoproto.moretags) = "yaml:\"to_address\""]; - repeated cosmos.base.v1beta1.Coin amount = 3 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; -} - -// MsgCreatePermanentLockedAccountResponse defines the Msg/CreatePermanentLockedAccount response type. -message MsgCreatePermanentLockedAccountResponse {} - -// MsgCreateVestingAccount defines a message that enables creating a vesting -// account. -message MsgCreatePeriodicVestingAccount { - option (cosmos.msg.v1.signer) = "from_address"; - - option (gogoproto.equal) = false; - - string from_address = 1; - string to_address = 2; - int64 start_time = 3; - repeated Period vesting_periods = 4 [(gogoproto.nullable) = false]; -} - -// MsgCreateVestingAccountResponse defines the Msg/CreatePeriodicVestingAccount -// response type. -message MsgCreatePeriodicVestingAccountResponse {} diff --git a/src/cosmospy_protobuf/cosmos/vesting/v1beta1/vesting.proto b/src/cosmospy_protobuf/cosmos/vesting/v1beta1/vesting.proto deleted file mode 100644 index 824cc30d..00000000 --- a/src/cosmospy_protobuf/cosmos/vesting/v1beta1/vesting.proto +++ /dev/null @@ -1,76 +0,0 @@ -syntax = "proto3"; -package cosmos.vesting.v1beta1; - -import "gogoproto/gogo.proto"; -import "cosmos/base/v1beta1/coin.proto"; -import "cosmos/auth/v1beta1/auth.proto"; - -option go_package = "github.com/cosmos/cosmos-sdk/x/auth/vesting/types"; - -// BaseVestingAccount implements the VestingAccount interface. It contains all -// the necessary fields needed for any vesting account implementation. -message BaseVestingAccount { - option (gogoproto.goproto_getters) = false; - option (gogoproto.goproto_stringer) = false; - - cosmos.auth.v1beta1.BaseAccount base_account = 1 [(gogoproto.embed) = true]; - repeated cosmos.base.v1beta1.Coin original_vesting = 2 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; - repeated cosmos.base.v1beta1.Coin delegated_free = 3 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; - repeated cosmos.base.v1beta1.Coin delegated_vesting = 4 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; - int64 end_time = 5; -} - -// ContinuousVestingAccount implements the VestingAccount interface. It -// continuously vests by unlocking coins linearly with respect to time. -message ContinuousVestingAccount { - option (gogoproto.goproto_getters) = false; - option (gogoproto.goproto_stringer) = false; - - BaseVestingAccount base_vesting_account = 1 [(gogoproto.embed) = true]; - int64 start_time = 2; -} - -// DelayedVestingAccount implements the VestingAccount interface. It vests all -// coins after a specific time, but non prior. In other words, it keeps them -// locked until a specified time. -message DelayedVestingAccount { - option (gogoproto.goproto_getters) = false; - option (gogoproto.goproto_stringer) = false; - - BaseVestingAccount base_vesting_account = 1 [(gogoproto.embed) = true]; -} - -// Period defines a length of time and amount of coins that will vest. -message Period { - option (gogoproto.goproto_stringer) = false; - - int64 length = 1; - repeated cosmos.base.v1beta1.Coin amount = 2 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; -} - -// PeriodicVestingAccount implements the VestingAccount interface. It -// periodically vests by unlocking coins during each specified period. -message PeriodicVestingAccount { - option (gogoproto.goproto_getters) = false; - option (gogoproto.goproto_stringer) = false; - - BaseVestingAccount base_vesting_account = 1 [(gogoproto.embed) = true]; - int64 start_time = 2; - repeated Period vesting_periods = 3 [(gogoproto.nullable) = false]; -} - -// PermanentLockedAccount implements the VestingAccount interface. It does -// not ever release coins, locking them indefinitely. Coins in this account can -// still be used for delegating and for governance votes even while locked. -// -// Since: cosmos-sdk 0.43 -message PermanentLockedAccount { - option (gogoproto.goproto_getters) = false; - option (gogoproto.goproto_stringer) = false; - - BaseVestingAccount base_vesting_account = 1 [(gogoproto.embed) = true]; -} diff --git a/src/cosmospy_protobuf/gogoproto/gogo.proto b/src/cosmospy_protobuf/gogoproto/gogo.proto index 56819f9b..974b36a7 100644 --- a/src/cosmospy_protobuf/gogoproto/gogo.proto +++ b/src/cosmospy_protobuf/gogoproto/gogo.proto @@ -1,5 +1,3 @@ -// https://github.com/cosmos/gogoproto/blob/master/gogoproto/gogo.proto - // Protocol Buffers for Go with Gadgets // // Copyright (c) 2013, The GoGo Authors. All rights reserved. diff --git a/src/cosmospy_protobuf/google/api/annotations.proto b/src/cosmospy_protobuf/google/api/annotations.proto index b10a1dcf..85c361b4 100644 --- a/src/cosmospy_protobuf/google/api/annotations.proto +++ b/src/cosmospy_protobuf/google/api/annotations.proto @@ -1,6 +1,4 @@ -// https://github.com/googleapis/googleapis/blob/master/google/api/annotations.proto - -// Copyright 2015 Google LLC +// Copyright (c) 2015, Google Inc. // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. diff --git a/src/cosmospy_protobuf/google/api/http.proto b/src/cosmospy_protobuf/google/api/http.proto index 6a3c97f9..2bd3a19b 100644 --- a/src/cosmospy_protobuf/google/api/http.proto +++ b/src/cosmospy_protobuf/google/api/http.proto @@ -1,6 +1,4 @@ -// https://github.com/googleapis/googleapis/blob/master/google/api/http.proto - -// Copyright 2015 Google LLC +// Copyright 2018 Google LLC // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -25,6 +23,7 @@ option java_outer_classname = "HttpProto"; option java_package = "com.google.api"; option objc_class_prefix = "GAPI"; + // Defines the HTTP configuration for an API service. It contains a list of // [HttpRule][google.api.HttpRule], each specifying the mapping of an RPC method // to one or more HTTP REST API methods. @@ -34,7 +33,7 @@ message Http { // **NOTE:** All service configuration rules follow "last one wins" order. repeated HttpRule rules = 1; - // When set to true, URL path parameters will be fully URI-decoded except in + // When set to true, URL path parmeters will be fully URI-decoded except in // cases of single segment matches in reserved expansion, where "%2F" will be // left encoded. // @@ -43,94 +42,94 @@ message Http { bool fully_decode_reserved_expansion = 2; } -// # gRPC Transcoding -// -// gRPC Transcoding is a feature for mapping between a gRPC method and one or -// more HTTP REST endpoints. It allows developers to build a single API service -// that supports both gRPC APIs and REST APIs. Many systems, including [Google -// APIs](https://github.com/googleapis/googleapis), -// [Cloud Endpoints](https://cloud.google.com/endpoints), [gRPC -// Gateway](https://github.com/grpc-ecosystem/grpc-gateway), -// and [Envoy](https://github.com/envoyproxy/envoy) proxy support this feature -// and use it for large scale production services. -// -// `HttpRule` defines the schema of the gRPC/REST mapping. The mapping specifies -// how different portions of the gRPC request message are mapped to the URL -// path, URL query parameters, and HTTP request body. It also controls how the -// gRPC response message is mapped to the HTTP response body. `HttpRule` is -// typically specified as an `google.api.http` annotation on the gRPC method. -// -// Each mapping specifies a URL path template and an HTTP method. The path -// template may refer to one or more fields in the gRPC request message, as long -// as each field is a non-repeated field with a primitive (non-message) type. -// The path template controls how fields of the request message are mapped to -// the URL path. -// -// Example: +// `HttpRule` defines the mapping of an RPC method to one or more HTTP +// REST API methods. The mapping specifies how different portions of the RPC +// request message are mapped to URL path, URL query parameters, and +// HTTP request body. The mapping is typically specified as an +// `google.api.http` annotation on the RPC method, +// see "google/api/annotations.proto" for details. +// +// The mapping consists of a field specifying the path template and +// method kind. The path template can refer to fields in the request +// message, as in the example below which describes a REST GET +// operation on a resource collection of messages: +// // // service Messaging { // rpc GetMessage(GetMessageRequest) returns (Message) { -// option (google.api.http) = { -// get: "/v1/{name=messages/*}" -// }; +// option (google.api.http).get = "/v1/messages/{message_id}/{sub.subfield}"; // } // } // message GetMessageRequest { -// string name = 1; // Mapped to URL path. +// message SubMessage { +// string subfield = 1; +// } +// string message_id = 1; // mapped to the URL +// SubMessage sub = 2; // `sub.subfield` is url-mapped // } // message Message { -// string text = 1; // The resource content. +// string text = 1; // content of the resource // } // -// This enables an HTTP REST to gRPC mapping as below: +// The same http annotation can alternatively be expressed inside the +// `GRPC API Configuration` YAML file. +// +// http: +// rules: +// - selector: .Messaging.GetMessage +// get: /v1/messages/{message_id}/{sub.subfield} // -// HTTP | gRPC +// This definition enables an automatic, bidrectional mapping of HTTP +// JSON to RPC. Example: +// +// HTTP | RPC // -----|----- -// `GET /v1/messages/123456` | `GetMessage(name: "messages/123456")` +// `GET /v1/messages/123456/foo` | `GetMessage(message_id: "123456" sub: SubMessage(subfield: "foo"))` +// +// In general, not only fields but also field paths can be referenced +// from a path pattern. Fields mapped to the path pattern cannot be +// repeated and must have a primitive (non-message) type. +// +// Any fields in the request message which are not bound by the path +// pattern automatically become (optional) HTTP query +// parameters. Assume the following definition of the request message: // -// Any fields in the request message which are not bound by the path template -// automatically become HTTP query parameters if there is no HTTP request body. -// For example: // // service Messaging { // rpc GetMessage(GetMessageRequest) returns (Message) { -// option (google.api.http) = { -// get:"/v1/messages/{message_id}" -// }; +// option (google.api.http).get = "/v1/messages/{message_id}"; // } // } // message GetMessageRequest { // message SubMessage { // string subfield = 1; // } -// string message_id = 1; // Mapped to URL path. -// int64 revision = 2; // Mapped to URL query parameter `revision`. -// SubMessage sub = 3; // Mapped to URL query parameter `sub.subfield`. +// string message_id = 1; // mapped to the URL +// int64 revision = 2; // becomes a parameter +// SubMessage sub = 3; // `sub.subfield` becomes a parameter // } // +// // This enables a HTTP JSON to RPC mapping as below: // -// HTTP | gRPC +// HTTP | RPC // -----|----- -// `GET /v1/messages/123456?revision=2&sub.subfield=foo` | -// `GetMessage(message_id: "123456" revision: 2 sub: SubMessage(subfield: -// "foo"))` -// -// Note that fields which are mapped to URL query parameters must have a -// primitive type or a repeated primitive type or a non-repeated message type. -// In the case of a repeated type, the parameter can be repeated in the URL -// as `...?param=A¶m=B`. In the case of a message type, each field of the -// message is mapped to a separate parameter, such as -// `...?foo.a=A&foo.b=B&foo.c=C`. -// -// For HTTP methods that allow a request body, the `body` field +// `GET /v1/messages/123456?revision=2&sub.subfield=foo` | `GetMessage(message_id: "123456" revision: 2 sub: SubMessage(subfield: "foo"))` +// +// Note that fields which are mapped to HTTP parameters must have a +// primitive type or a repeated primitive type. Message types are not +// allowed. In the case of a repeated type, the parameter can be +// repeated in the URL, as in `...?param=A¶m=B`. +// +// For HTTP method kinds which allow a request body, the `body` field // specifies the mapping. Consider a REST update method on the // message resource collection: // +// // service Messaging { // rpc UpdateMessage(UpdateMessageRequest) returns (Message) { // option (google.api.http) = { -// patch: "/v1/messages/{message_id}" +// put: "/v1/messages/{message_id}" // body: "message" // }; // } @@ -140,14 +139,14 @@ message Http { // Message message = 2; // mapped to the body // } // +// // The following HTTP JSON to RPC mapping is enabled, where the // representation of the JSON in the request body is determined by // protos JSON encoding: // -// HTTP | gRPC +// HTTP | RPC // -----|----- -// `PATCH /v1/messages/123456 { "text": "Hi!" }` | `UpdateMessage(message_id: -// "123456" message { text: "Hi!" })` +// `PUT /v1/messages/123456 { "text": "Hi!" }` | `UpdateMessage(message_id: "123456" message { text: "Hi!" })` // // The special name `*` can be used in the body mapping to define that // every field not bound by the path template should be mapped to the @@ -157,7 +156,7 @@ message Http { // service Messaging { // rpc UpdateMessage(Message) returns (Message) { // option (google.api.http) = { -// patch: "/v1/messages/{message_id}" +// put: "/v1/messages/{message_id}" // body: "*" // }; // } @@ -170,14 +169,13 @@ message Http { // // The following HTTP JSON to RPC mapping is enabled: // -// HTTP | gRPC +// HTTP | RPC // -----|----- -// `PATCH /v1/messages/123456 { "text": "Hi!" }` | `UpdateMessage(message_id: -// "123456" text: "Hi!")` +// `PUT /v1/messages/123456 { "text": "Hi!" }` | `UpdateMessage(message_id: "123456" text: "Hi!")` // // Note that when using `*` in the body mapping, it is not possible to // have HTTP parameters, as all fields not bound by the path end in -// the body. This makes this option more rarely used in practice when +// the body. This makes this option more rarely used in practice of // defining REST APIs. The common usage of `*` is in custom methods // which don't use the URL at all for transferring data. // @@ -199,31 +197,32 @@ message Http { // string user_id = 2; // } // -// This enables the following two alternative HTTP JSON to RPC mappings: // -// HTTP | gRPC +// This enables the following two alternative HTTP JSON to RPC +// mappings: +// +// HTTP | RPC // -----|----- // `GET /v1/messages/123456` | `GetMessage(message_id: "123456")` -// `GET /v1/users/me/messages/123456` | `GetMessage(user_id: "me" message_id: -// "123456")` -// -// ## Rules for HTTP mapping -// -// 1. Leaf request fields (recursive expansion nested messages in the request -// message) are classified into three categories: -// - Fields referred by the path template. They are passed via the URL path. -// - Fields referred by the [HttpRule.body][google.api.HttpRule.body]. They are passed via the HTTP -// request body. -// - All other fields are passed via the URL query parameters, and the -// parameter name is the field path in the request message. A repeated -// field can be represented as multiple query parameters under the same -// name. -// 2. If [HttpRule.body][google.api.HttpRule.body] is "*", there is no URL query parameter, all fields -// are passed via URL path and HTTP request body. -// 3. If [HttpRule.body][google.api.HttpRule.body] is omitted, there is no HTTP request body, all -// fields are passed via URL path and URL query parameters. -// -// ### Path template syntax +// `GET /v1/users/me/messages/123456` | `GetMessage(user_id: "me" message_id: "123456")` +// +// # Rules for HTTP mapping +// +// The rules for mapping HTTP path, query parameters, and body fields +// to the request message are as follows: +// +// 1. The `body` field specifies either `*` or a field path, or is +// omitted. If omitted, it indicates there is no HTTP request body. +// 2. Leaf fields (recursive expansion of nested messages in the +// request) can be classified into three types: +// (a) Matched in the URL template. +// (b) Covered by body (if body is `*`, everything except (a) fields; +// else everything under the body field) +// (c) All other fields. +// 3. URL query parameters found in the HTTP request are mapped to (c) fields. +// 4. Any body sent with an HTTP request can contain only (b) fields. +// +// The syntax of the path template is as follows: // // Template = "/" Segments [ Verb ] ; // Segments = Segment { "/" Segment } ; @@ -232,88 +231,36 @@ message Http { // FieldPath = IDENT { "." IDENT } ; // Verb = ":" LITERAL ; // -// The syntax `*` matches a single URL path segment. The syntax `**` matches -// zero or more URL path segments, which must be the last part of the URL path -// except the `Verb`. +// The syntax `*` matches a single path segment. The syntax `**` matches zero +// or more path segments, which must be the last part of the path except the +// `Verb`. The syntax `LITERAL` matches literal text in the path. // // The syntax `Variable` matches part of the URL path as specified by its // template. A variable template must not contain other variables. If a variable // matches a single path segment, its template may be omitted, e.g. `{var}` // is equivalent to `{var=*}`. // -// The syntax `LITERAL` matches literal text in the URL path. If the `LITERAL` -// contains any reserved character, such characters should be percent-encoded -// before the matching. -// // If a variable contains exactly one path segment, such as `"{var}"` or -// `"{var=*}"`, when such a variable is expanded into a URL path on the client -// side, all characters except `[-_.~0-9a-zA-Z]` are percent-encoded. The -// server side does the reverse decoding. Such variables show up in the -// [Discovery -// Document](https://developers.google.com/discovery/v1/reference/apis) as -// `{var}`. -// -// If a variable contains multiple path segments, such as `"{var=foo/*}"` -// or `"{var=**}"`, when such a variable is expanded into a URL path on the -// client side, all characters except `[-_.~/0-9a-zA-Z]` are percent-encoded. -// The server side does the reverse decoding, except "%2F" and "%2f" are left -// unchanged. Such variables show up in the -// [Discovery -// Document](https://developers.google.com/discovery/v1/reference/apis) as -// `{+var}`. -// -// ## Using gRPC API Service Configuration -// -// gRPC API Service Configuration (service config) is a configuration language -// for configuring a gRPC service to become a user-facing product. The -// service config is simply the YAML representation of the `google.api.Service` -// proto message. -// -// As an alternative to annotating your proto file, you can configure gRPC -// transcoding in your service config YAML files. You do this by specifying a -// `HttpRule` that maps the gRPC method to a REST endpoint, achieving the same -// effect as the proto annotation. This can be particularly useful if you -// have a proto that is reused in multiple services. Note that any transcoding -// specified in the service config will override any matching transcoding -// configuration in the proto. -// -// Example: -// -// http: -// rules: -// # Selects a gRPC method and applies HttpRule to it. -// - selector: example.v1.Messaging.GetMessage -// get: /v1/messages/{message_id}/{sub.subfield} -// -// ## Special notes -// -// When gRPC Transcoding is used to map a gRPC to JSON REST endpoints, the -// proto to JSON conversion must follow the [proto3 -// specification](https://developers.google.com/protocol-buffers/docs/proto3#json). -// -// While the single segment variable follows the semantics of -// [RFC 6570](https://tools.ietf.org/html/rfc6570) Section 3.2.2 Simple String -// Expansion, the multi segment variable **does not** follow RFC 6570 Section -// 3.2.3 Reserved Expansion. The reason is that the Reserved Expansion +// `"{var=*}"`, when such a variable is expanded into a URL path, all characters +// except `[-_.~0-9a-zA-Z]` are percent-encoded. Such variables show up in the +// Discovery Document as `{var}`. +// +// If a variable contains one or more path segments, such as `"{var=foo/*}"` +// or `"{var=**}"`, when such a variable is expanded into a URL path, all +// characters except `[-_.~/0-9a-zA-Z]` are percent-encoded. Such variables +// show up in the Discovery Document as `{+var}`. +// +// NOTE: While the single segment variable matches the semantics of +// [RFC 6570](https://tools.ietf.org/html/rfc6570) Section 3.2.2 +// Simple String Expansion, the multi segment variable **does not** match +// RFC 6570 Reserved Expansion. The reason is that the Reserved Expansion // does not expand special characters like `?` and `#`, which would lead -// to invalid URLs. As the result, gRPC Transcoding uses a custom encoding -// for multi segment variables. +// to invalid URLs. // -// The path variables **must not** refer to any repeated or mapped field, -// because client libraries are not capable of handling such variable expansion. -// -// The path variables **must not** capture the leading "/" character. The reason -// is that the most common use case "{var}" does not capture the leading "/" -// character. For consistency, all path variables must share the same behavior. -// -// Repeated message fields must not be mapped to URL query parameters, because -// no client library can support such complicated mapping. -// -// If an API needs to use a JSON array for request or response body, it can map -// the request or response body to a repeated field. However, some gRPC -// Transcoding implementations may not support this feature. +// NOTE: the field paths in variables and in the `body` must not refer to +// repeated fields or map fields. message HttpRule { - // Selects a method to which this rule applies. + // Selects methods to which this rule applies. // // Refer to [selector][google.api.DocumentationRule.selector] for syntax details. string selector = 1; @@ -322,20 +269,19 @@ message HttpRule { // used with any of the {get|put|post|delete|patch} methods. A custom method // can be defined using the 'custom' field. oneof pattern { - // Maps to HTTP GET. Used for listing and getting information about - // resources. + // Used for listing and getting information about resources. string get = 2; - // Maps to HTTP PUT. Used for replacing a resource. + // Used for updating a resource. string put = 3; - // Maps to HTTP POST. Used for creating a resource or performing an action. + // Used for creating a resource. string post = 4; - // Maps to HTTP DELETE. Used for deleting a resource. + // Used for deleting a resource. string delete = 5; - // Maps to HTTP PATCH. Used for updating a resource. + // Used for updating a resource. string patch = 6; // The custom pattern is used for specifying an HTTP method that is not @@ -345,20 +291,15 @@ message HttpRule { CustomHttpPattern custom = 8; } - // The name of the request field whose value is mapped to the HTTP request - // body, or `*` for mapping all request fields not captured by the path - // pattern to the HTTP body, or omitted for not having any HTTP request body. - // - // NOTE: the referred field must be present at the top-level of the request - // message type. + // The name of the request field whose value is mapped to the HTTP body, or + // `*` for mapping all fields not captured by the path pattern to the HTTP + // body. NOTE: the referred field must not be a repeated field and must be + // present at the top-level of request message type. string body = 7; // Optional. The name of the response field whose value is mapped to the HTTP - // response body. When omitted, the entire response message will be used - // as the HTTP response body. - // - // NOTE: The referred field must be present at the top-level of the response - // message type. + // body of response. Other response fields are ignored. When + // not set, the response message will be used as HTTP body of response. string response_body = 12; // Additional HTTP bindings for the selector. Nested bindings must diff --git a/src/cosmospy_protobuf/google/protobuf/any.proto b/src/cosmospy_protobuf/google/protobuf/any.proto index 6452f404..1431810e 100644 --- a/src/cosmospy_protobuf/google/protobuf/any.proto +++ b/src/cosmospy_protobuf/google/protobuf/any.proto @@ -1,5 +1,3 @@ -// https://github.com/cosmos/cosmos-sdk/blob/main/third_party/proto/google/protobuf/any.proto - // Protocol Buffers - Google's data interchange format // Copyright 2008 Google Inc. All rights reserved. // https://developers.google.com/protocol-buffers/ @@ -39,7 +37,7 @@ import "gogoproto/gogo.proto"; option csharp_namespace = "Google.Protobuf.WellKnownTypes"; option go_package = "types"; option java_package = "com.google.protobuf"; -option java_outer_classname = "CosmosAnyProto"; +option java_outer_classname = "AnyProto"; option java_multiple_files = true; option objc_class_prefix = "GPB"; @@ -158,9 +156,6 @@ message Any { bytes value = 2; option (gogoproto.typedecl) = false; - option (gogoproto.goproto_stringer) = false; - option (gogoproto.gostring) = false; - option (gogoproto.stringer) = false; } -option (gogoproto.goproto_registration) = false; \ No newline at end of file +option (gogoproto.goproto_registration) = false; diff --git a/src/cosmospy_protobuf/ibc/applications/fee/v1/ack.proto b/src/cosmospy_protobuf/ibc/applications/fee/v1/ack.proto deleted file mode 100644 index 728c7536..00000000 --- a/src/cosmospy_protobuf/ibc/applications/fee/v1/ack.proto +++ /dev/null @@ -1,17 +0,0 @@ -syntax = "proto3"; - -package ibc.applications.fee.v1; - -option go_package = "github.com/cosmos/ibc-go/v3/modules/apps/29-fee/types"; - -import "gogoproto/gogo.proto"; - -// IncentivizedAcknowledgement is the acknowledgement format to be used by applications wrapped in the fee middleware -message IncentivizedAcknowledgement { - // the underlying app acknowledgement result bytes - bytes result = 1; - // the relayer address which submits the recv packet message - string forward_relayer_address = 2 [(gogoproto.moretags) = "yaml:\"forward_relayer_address\""]; - // success flag of the base application callback - bool underlying_app_success = 3 [(gogoproto.moretags) = "yaml:\"underlying_app_successl\""]; -} diff --git a/src/cosmospy_protobuf/ibc/applications/fee/v1/fee.proto b/src/cosmospy_protobuf/ibc/applications/fee/v1/fee.proto deleted file mode 100644 index e7a1fa43..00000000 --- a/src/cosmospy_protobuf/ibc/applications/fee/v1/fee.proto +++ /dev/null @@ -1,56 +0,0 @@ -syntax = "proto3"; - -package ibc.applications.fee.v1; - -option go_package = "github.com/cosmos/ibc-go/v3/modules/apps/29-fee/types"; - -import "cosmos/base/v1beta1/coin.proto"; -import "gogoproto/gogo.proto"; -import "ibc/core/channel/v1/channel.proto"; - -// Fee defines the ICS29 receive, acknowledgement and timeout fees -message Fee { - // the packet receive fee - repeated cosmos.base.v1beta1.Coin recv_fee = 1 [ - (gogoproto.moretags) = "yaml:\"recv_fee\"", - (gogoproto.nullable) = false, - (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" - ]; - // the packet acknowledgement fee - repeated cosmos.base.v1beta1.Coin ack_fee = 2 [ - (gogoproto.moretags) = "yaml:\"ack_fee\"", - (gogoproto.nullable) = false, - (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" - ]; - // the packet timeout fee - repeated cosmos.base.v1beta1.Coin timeout_fee = 3 [ - (gogoproto.moretags) = "yaml:\"timeout_fee\"", - (gogoproto.nullable) = false, - (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" - ]; -} - -// PacketFee contains ICS29 relayer fees, refund address and optional list of permitted relayers -message PacketFee { - // fee encapsulates the recv, ack and timeout fees associated with an IBC packet - Fee fee = 1 [(gogoproto.nullable) = false]; - // the refund address for unspent fees - string refund_address = 2 [(gogoproto.moretags) = "yaml:\"refund_address\""]; - // optional list of relayers permitted to receive fees - repeated string relayers = 3; -} - -// PacketFees contains a list of type PacketFee -message PacketFees { - // list of packet fees - repeated PacketFee packet_fees = 1 [(gogoproto.moretags) = "yaml:\"packet_fees\"", (gogoproto.nullable) = false]; -} - -// IdentifiedPacketFees contains a list of type PacketFee and associated PacketId -message IdentifiedPacketFees { - // unique packet identifier comprised of the channel ID, port ID and sequence - ibc.core.channel.v1.PacketId packet_id = 1 - [(gogoproto.nullable) = false, (gogoproto.moretags) = "yaml:\"packet_id\""]; - // list of packet fees - repeated PacketFee packet_fees = 2 [(gogoproto.moretags) = "yaml:\"packet_fees\"", (gogoproto.nullable) = false]; -} diff --git a/src/cosmospy_protobuf/ibc/applications/fee/v1/genesis.proto b/src/cosmospy_protobuf/ibc/applications/fee/v1/genesis.proto deleted file mode 100644 index cae13223..00000000 --- a/src/cosmospy_protobuf/ibc/applications/fee/v1/genesis.proto +++ /dev/null @@ -1,52 +0,0 @@ -syntax = "proto3"; - -package ibc.applications.fee.v1; - -option go_package = "github.com/cosmos/ibc-go/v3/modules/apps/29-fee/types"; - -import "gogoproto/gogo.proto"; -import "ibc/applications/fee/v1/fee.proto"; -import "ibc/core/channel/v1/channel.proto"; - -// GenesisState defines the ICS29 fee middleware genesis state -message GenesisState { - // list of identified packet fees - repeated IdentifiedPacketFees identified_fees = 1 - [(gogoproto.moretags) = "yaml:\"identified_fees\"", (gogoproto.nullable) = false]; - // list of fee enabled channels - repeated FeeEnabledChannel fee_enabled_channels = 2 - [(gogoproto.moretags) = "yaml:\"fee_enabled_channels\"", (gogoproto.nullable) = false]; - // list of registered relayer addresses - repeated RegisteredRelayerAddress registered_relayers = 3 - [(gogoproto.moretags) = "yaml:\"registered_relayers\"", (gogoproto.nullable) = false]; - // list of forward relayer addresses - repeated ForwardRelayerAddress forward_relayers = 4 - [(gogoproto.moretags) = "yaml:\"forward_relayers\"", (gogoproto.nullable) = false]; -} - -// FeeEnabledChannel contains the PortID & ChannelID for a fee enabled channel -message FeeEnabledChannel { - // unique port identifier - string port_id = 1 [(gogoproto.moretags) = "yaml:\"port_id\""]; - // unique channel identifier - string channel_id = 2 [(gogoproto.moretags) = "yaml:\"channel_id\""]; -} - -// RegisteredRelayerAddress contains the address and counterparty address for a specific relayer (for distributing fees) -message RegisteredRelayerAddress { - // the relayer address - string address = 1; - // the counterparty relayer address - string counterparty_address = 2 [(gogoproto.moretags) = "yaml:\"counterparty_address\""]; - // unique channel identifier - string channel_id = 3 [(gogoproto.moretags) = "yaml:\"channel_id\""]; -} - -// ForwardRelayerAddress contains the forward relayer address and PacketId used for async acknowledgements -message ForwardRelayerAddress { - // the forward relayer address - string address = 1; - // unique packet identifer comprised of the channel ID, port ID and sequence - ibc.core.channel.v1.PacketId packet_id = 2 - [(gogoproto.nullable) = false, (gogoproto.moretags) = "yaml:\"packet_id\""]; -} diff --git a/src/cosmospy_protobuf/ibc/applications/fee/v1/metadata.proto b/src/cosmospy_protobuf/ibc/applications/fee/v1/metadata.proto deleted file mode 100644 index 0afb3e09..00000000 --- a/src/cosmospy_protobuf/ibc/applications/fee/v1/metadata.proto +++ /dev/null @@ -1,16 +0,0 @@ -syntax = "proto3"; - -package ibc.applications.fee.v1; - -option go_package = "github.com/cosmos/ibc-go/v3/modules/apps/29-fee/types"; - -import "gogoproto/gogo.proto"; - -// Metadata defines the ICS29 channel specific metadata encoded into the channel version bytestring -// See ICS004: https://github.com/cosmos/ibc/tree/master/spec/core/ics-004-channel-and-packet-semantics#Versioning -message Metadata { - // fee_version defines the ICS29 fee version - string fee_version = 1 [(gogoproto.moretags) = "yaml:\"fee_version\""]; - // app_version defines the underlying application version, which may or may not be a JSON encoded bytestring - string app_version = 2 [(gogoproto.moretags) = "yaml:\"app_version\""]; -} diff --git a/src/cosmospy_protobuf/ibc/applications/fee/v1/query.proto b/src/cosmospy_protobuf/ibc/applications/fee/v1/query.proto deleted file mode 100644 index acab12f5..00000000 --- a/src/cosmospy_protobuf/ibc/applications/fee/v1/query.proto +++ /dev/null @@ -1,203 +0,0 @@ -syntax = "proto3"; - -package ibc.applications.fee.v1; - -option go_package = "github.com/cosmos/ibc-go/v3/modules/apps/29-fee/types"; - -import "gogoproto/gogo.proto"; -import "google/api/annotations.proto"; -import "cosmos/base/v1beta1/coin.proto"; -import "cosmos/base/query/v1beta1/pagination.proto"; -import "ibc/applications/fee/v1/fee.proto"; -import "ibc/applications/fee/v1/genesis.proto"; -import "ibc/core/channel/v1/channel.proto"; - -// Query defines the ICS29 gRPC querier service. -service Query { - // IncentivizedPackets returns all incentivized packets and their associated fees - rpc IncentivizedPackets(QueryIncentivizedPacketsRequest) returns (QueryIncentivizedPacketsResponse) { - option (google.api.http).get = "/ibc/apps/fee/v1/incentivized_packets"; - } - - // IncentivizedPacket returns all packet fees for a packet given its identifier - rpc IncentivizedPacket(QueryIncentivizedPacketRequest) returns (QueryIncentivizedPacketResponse) { - option (google.api.http).get = - "/ibc/apps/fee/v1/incentivized_packet/port/{packet_id.port_id}/channel/{packet_id.channel_id}/sequence/" - "{packet_id.sequence}"; - } - - // Gets all incentivized packets for a specific channel - rpc IncentivizedPacketsForChannel(QueryIncentivizedPacketsForChannelRequest) - returns (QueryIncentivizedPacketsForChannelResponse) { - option (google.api.http).get = "/ibc/apps/fee/v1/incentivized_packets/port/{port_id}/channel/{channel_id}"; - } - - // TotalRecvFees returns the total receive fees for a packet given its identifier - rpc TotalRecvFees(QueryTotalRecvFeesRequest) returns (QueryTotalRecvFeesResponse) { - option (google.api.http).get = "/ibc/apps/fee/v1/total_recv_fees/port/{packet_id.port_id}/channel/" - "{packet_id.channel_id}/sequence/{packet_id.sequence}"; - } - - // TotalAckFees returns the total acknowledgement fees for a packet given its identifier - rpc TotalAckFees(QueryTotalAckFeesRequest) returns (QueryTotalAckFeesResponse) { - option (google.api.http).get = "/ibc/apps/fee/v1/total_ack_fees/port/{packet_id.port_id}/channel/" - "{packet_id.channel_id}/sequence/{packet_id.sequence}"; - } - - // TotalTimeoutFees returns the total timeout fees for a packet given its identifier - rpc TotalTimeoutFees(QueryTotalTimeoutFeesRequest) returns (QueryTotalTimeoutFeesResponse) { - option (google.api.http).get = "/ibc/apps/fee/v1/total_timeout_fees/port/{packet_id.port_id}/channel/" - "{packet_id.channel_id}/sequence/{packet_id.sequence}"; - } - - // CounterpartyAddress returns the registered counterparty address for forward relaying - rpc CounterpartyAddress(QueryCounterpartyAddressRequest) returns (QueryCounterpartyAddressResponse) { - option (google.api.http).get = "/ibc/apps/fee/v1/counterparty_address/{relayer_address}/channel/{channel_id}"; - } - - // FeeEnabledChannels returns a list of all fee enabled channels - rpc FeeEnabledChannels(QueryFeeEnabledChannelsRequest) returns (QueryFeeEnabledChannelsResponse) { - option (google.api.http).get = "/ibc/apps/fee/v1/fee_enabled"; - } - - // FeeEnabledChannel returns true if the provided port and channel identifiers belong to a fee enabled channel - rpc FeeEnabledChannel(QueryFeeEnabledChannelRequest) returns (QueryFeeEnabledChannelResponse) { - option (google.api.http).get = "/ibc/apps/fee/v1/fee_enabled/port/{port_id}/channel/{channel_id}"; - } -} - -// QueryIncentivizedPacketsRequest defines the request type for the IncentivizedPackets rpc -message QueryIncentivizedPacketsRequest { - // pagination defines an optional pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 1; - // block height at which to query - uint64 query_height = 2; -} - -// QueryIncentivizedPacketsResponse defines the response type for the IncentivizedPackets rpc -message QueryIncentivizedPacketsResponse { - // list of identified fees for incentivized packets - repeated ibc.applications.fee.v1.IdentifiedPacketFees incentivized_packets = 1 [(gogoproto.nullable) = false]; -} - -// QueryIncentivizedPacketRequest defines the request type for the IncentivizedPacket rpc -message QueryIncentivizedPacketRequest { - // unique packet identifier comprised of channel ID, port ID and sequence - ibc.core.channel.v1.PacketId packet_id = 1 [(gogoproto.nullable) = false]; - // block height at which to query - uint64 query_height = 2; -} - -// QueryIncentivizedPacketsResponse defines the response type for the IncentivizedPacket rpc -message QueryIncentivizedPacketResponse { - // the identified fees for the incentivized packet - ibc.applications.fee.v1.IdentifiedPacketFees incentivized_packet = 1 [(gogoproto.nullable) = false]; -} - -// QueryIncentivizedPacketsForChannelRequest defines the request type for querying for all incentivized packets -// for a specific channel -message QueryIncentivizedPacketsForChannelRequest { - // pagination defines an optional pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 1; - string port_id = 2; - string channel_id = 3; - // Height to query at - uint64 query_height = 4; -} - -// QueryIncentivizedPacketsResponse defines the response type for the incentivized packets RPC -message QueryIncentivizedPacketsForChannelResponse { - // Map of all incentivized_packets - repeated ibc.applications.fee.v1.IdentifiedPacketFees incentivized_packets = 1; -} - -// QueryTotalRecvFeesRequest defines the request type for the TotalRecvFees rpc -message QueryTotalRecvFeesRequest { - // the packet identifier for the associated fees - ibc.core.channel.v1.PacketId packet_id = 1 [(gogoproto.nullable) = false]; -} - -// QueryTotalRecvFeesResponse defines the response type for the TotalRecvFees rpc -message QueryTotalRecvFeesResponse { - // the total packet receive fees - repeated cosmos.base.v1beta1.Coin recv_fees = 1 [ - (gogoproto.moretags) = "yaml:\"recv_fees\"", - (gogoproto.nullable) = false, - (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" - ]; -} - -// QueryTotalAckFeesRequest defines the request type for the TotalAckFees rpc -message QueryTotalAckFeesRequest { - // the packet identifier for the associated fees - ibc.core.channel.v1.PacketId packet_id = 1 [(gogoproto.nullable) = false]; -} - -// QueryTotalAckFeesResponse defines the response type for the TotalAckFees rpc -message QueryTotalAckFeesResponse { - // the total packet acknowledgement fees - repeated cosmos.base.v1beta1.Coin ack_fees = 1 [ - (gogoproto.moretags) = "yaml:\"ack_fees\"", - (gogoproto.nullable) = false, - (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" - ]; -} - -// QueryTotalTimeoutFeesRequest defines the request type for the TotalTimeoutFees rpc -message QueryTotalTimeoutFeesRequest { - // the packet identifier for the associated fees - ibc.core.channel.v1.PacketId packet_id = 1 [(gogoproto.nullable) = false]; -} - -// QueryTotalTimeoutFeesResponse defines the response type for the TotalTimeoutFees rpc -message QueryTotalTimeoutFeesResponse { - // the total packet timeout fees - repeated cosmos.base.v1beta1.Coin timeout_fees = 1 [ - (gogoproto.moretags) = "yaml:\"timeout_fees\"", - (gogoproto.nullable) = false, - (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" - ]; -} - -// QueryCounterpartyAddressRequest defines the request type for the CounterpartyAddress rpc -message QueryCounterpartyAddressRequest { - // unique channel identifier - string channel_id = 1 [(gogoproto.moretags) = "yaml:\"channel_id\""]; - // the relayer address to which the counterparty is registered - string relayer_address = 2 [(gogoproto.moretags) = "yaml:\"relayer_address\""]; -} - -// QueryCounterpartyAddressResponse defines the response type for the CounterpartyAddress rpc -message QueryCounterpartyAddressResponse { - // the counterparty address used to compensate forward relaying - string counterparty_address = 1 [(gogoproto.moretags) = "yaml:\"counterparty_address\""]; -} - -// QueryFeeEnabledChannelsRequest defines the request type for the FeeEnabledChannels rpc -message QueryFeeEnabledChannelsRequest { - // pagination defines an optional pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 1; - // block height at which to query - uint64 query_height = 2; -} - -// QueryFeeEnabledChannelsResponse defines the response type for the FeeEnabledChannels rpc -message QueryFeeEnabledChannelsResponse { - // list of fee enabled channels - repeated ibc.applications.fee.v1.FeeEnabledChannel fee_enabled_channels = 1 - [(gogoproto.moretags) = "yaml:\"fee_enabled_channels\"", (gogoproto.nullable) = false]; -} - -// QueryFeeEnabledChannelRequest defines the request type for the FeeEnabledChannel rpc -message QueryFeeEnabledChannelRequest { - // unique port identifier - string port_id = 1 [(gogoproto.moretags) = "yaml:\"port_id\""]; - // unique channel identifier - string channel_id = 2 [(gogoproto.moretags) = "yaml:\"channel_id\""]; -} - -// QueryFeeEnabledChannelResponse defines the response type for the FeeEnabledChannel rpc -message QueryFeeEnabledChannelResponse { - // boolean flag representing the fee enabled channel status - bool fee_enabled = 1 [(gogoproto.moretags) = "yaml:\"fee_enabled\""]; -} diff --git a/src/cosmospy_protobuf/ibc/applications/fee/v1/tx.proto b/src/cosmospy_protobuf/ibc/applications/fee/v1/tx.proto deleted file mode 100644 index 7a0044cd..00000000 --- a/src/cosmospy_protobuf/ibc/applications/fee/v1/tx.proto +++ /dev/null @@ -1,85 +0,0 @@ -syntax = "proto3"; - -package ibc.applications.fee.v1; - -option go_package = "github.com/cosmos/ibc-go/v3/modules/apps/29-fee/types"; - -import "gogoproto/gogo.proto"; -import "ibc/applications/fee/v1/fee.proto"; -import "ibc/core/channel/v1/channel.proto"; - -// Msg defines the ICS29 Msg service. -service Msg { - // RegisterCounterpartyAddress defines a rpc handler method for MsgRegisterCounterpartyAddress - // RegisterCounterpartyAddress is called by the relayer on each channelEnd and allows them to specify their - // counterparty address before relaying. This ensures they will be properly compensated for forward relaying since - // destination chain must send back relayer's source address (counterparty address) in acknowledgement. This function - // may be called more than once by a relayer, in which case, latest counterparty address is always used. - rpc RegisterCounterpartyAddress(MsgRegisterCounterpartyAddress) returns (MsgRegisterCounterpartyAddressResponse); - - // PayPacketFee defines a rpc handler method for MsgPayPacketFee - // PayPacketFee is an open callback that may be called by any module/user that wishes to escrow funds in order to - // incentivize the relaying of the packet at the next sequence - // NOTE: This method is intended to be used within a multi msg transaction, where the subsequent msg that follows - // initiates the lifecycle of the incentivized packet - rpc PayPacketFee(MsgPayPacketFee) returns (MsgPayPacketFeeResponse); - - // PayPacketFeeAsync defines a rpc handler method for MsgPayPacketFeeAsync - // PayPacketFeeAsync is an open callback that may be called by any module/user that wishes to escrow funds in order to - // incentivize the relaying of a known packet (i.e. at a particular sequence) - rpc PayPacketFeeAsync(MsgPayPacketFeeAsync) returns (MsgPayPacketFeeAsyncResponse); -} - -// MsgRegisterCounterpartyAddress defines the request type for the RegisterCounterpartyAddress rpc -message MsgRegisterCounterpartyAddress { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // the relayer address - string address = 1; - // the counterparty relayer address - string counterparty_address = 2 [(gogoproto.moretags) = "yaml:\"counterparty_address\""]; - // unique channel identifier - string channel_id = 3 [(gogoproto.moretags) = "yaml:\"channel_id\""]; -} - -// MsgRegisterCounterpartyAddressResponse defines the response type for the RegisterCounterpartyAddress rpc -message MsgRegisterCounterpartyAddressResponse {} - -// MsgPayPacketFee defines the request type for the PayPacketFee rpc -// This Msg can be used to pay for a packet at the next sequence send & should be combined with the Msg that will be -// paid for -message MsgPayPacketFee { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // fee encapsulates the recv, ack and timeout fees associated with an IBC packet - ibc.applications.fee.v1.Fee fee = 1 [(gogoproto.nullable) = false]; - // the source port unique identifier - string source_port_id = 2 [(gogoproto.moretags) = "yaml:\"source_port_id\""]; - // the source channel unique identifer - string source_channel_id = 3 [(gogoproto.moretags) = "yaml:\"source_channel_id\""]; - // account address to refund fee if necessary - string signer = 4; - // optional list of relayers permitted to the receive packet fees - repeated string relayers = 5; -} - -// MsgPayPacketFeeResponse defines the response type for the PayPacketFee rpc -message MsgPayPacketFeeResponse {} - -// MsgPayPacketFeeAsync defines the request type for the PayPacketFeeAsync rpc -// This Msg can be used to pay for a packet at a specified sequence (instead of the next sequence send) -message MsgPayPacketFeeAsync { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // unique packet identifier comprised of the channel ID, port ID and sequence - ibc.core.channel.v1.PacketId packet_id = 1 - [(gogoproto.moretags) = "yaml:\"packet_id\"", (gogoproto.nullable) = false]; - // the packet fee associated with a particular IBC packet - PacketFee packet_fee = 2 [(gogoproto.moretags) = "yaml:\"packet_fee\"", (gogoproto.nullable) = false]; -} - -// MsgPayPacketFeeAsyncResponse defines the response type for the PayPacketFeeAsync rpc -message MsgPayPacketFeeAsyncResponse {} diff --git a/src/cosmospy_protobuf/ibc/core/channel/v1/channel.proto b/src/cosmospy_protobuf/ibc/core/channel/v1/channel.proto index 177f2c85..68c6ec17 100644 --- a/src/cosmospy_protobuf/ibc/core/channel/v1/channel.proto +++ b/src/cosmospy_protobuf/ibc/core/channel/v1/channel.proto @@ -132,20 +132,6 @@ message PacketState { bytes data = 4; } -// 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 -message PacketId { - option (gogoproto.goproto_getters) = false; - - // channel port identifier - string port_id = 1 [(gogoproto.moretags) = "yaml:\"port_id\""]; - // channel unique identifier - string channel_id = 2 [(gogoproto.moretags) = "yaml:\"channel_id\""]; - // packet sequence - uint64 sequence = 3; -} - // Acknowledgement is the recommended acknowledgement format to be used by // app-specific protocols. // NOTE: The field numbers 21 and 22 were explicitly chosen to avoid accidental diff --git a/src/cosmospy_protobuf/ibc/core/channel/v1/tx.proto b/src/cosmospy_protobuf/ibc/core/channel/v1/tx.proto index d34b00e9..d4d6df1d 100644 --- a/src/cosmospy_protobuf/ibc/core/channel/v1/tx.proto +++ b/src/cosmospy_protobuf/ibc/core/channel/v1/tx.proto @@ -47,11 +47,11 @@ enum ResponseResultType { option (gogoproto.goproto_enum_prefix) = false; // Default zero value enumeration - RESPONSE_RESULT_TYPE_UNSPECIFIED = 0 [(gogoproto.enumvalue_customname) = "UNSPECIFIED"]; + RESPONSE_RESULT_UNSPECIFIED = 0 [(gogoproto.enumvalue_customname) = "UNSPECIFIED"]; // The message did not call the IBC application callbacks (because, for example, the packet had already been relayed) - RESPONSE_RESULT_TYPE_NOOP = 1 [(gogoproto.enumvalue_customname) = "NOOP"]; + RESPONSE_RESULT_NOOP = 1 [(gogoproto.enumvalue_customname) = "NOOP"]; // The message was executed successfully - RESPONSE_RESULT_TYPE_SUCCESS = 2 [(gogoproto.enumvalue_customname) = "SUCCESS"]; + RESPONSE_RESULT_SUCCESS = 2 [(gogoproto.enumvalue_customname) = "SUCCESS"]; } // MsgChannelOpenInit defines an sdk.Msg to initialize a channel handshake. It @@ -68,7 +68,6 @@ message MsgChannelOpenInit { // MsgChannelOpenInitResponse defines the Msg/ChannelOpenInit response type. message MsgChannelOpenInitResponse { string channel_id = 1 [(gogoproto.moretags) = "yaml:\"channel_id\""]; - string version = 2; } // MsgChannelOpenInit defines a msg sent by a Relayer to try to open a channel @@ -92,9 +91,7 @@ message MsgChannelOpenTry { } // MsgChannelOpenTryResponse defines the Msg/ChannelOpenTry response type. -message MsgChannelOpenTryResponse { - string version = 1; -} +message MsgChannelOpenTryResponse {} // MsgChannelOpenAck defines a msg sent by a Relayer to Chain A to acknowledge // the change of channel state to TRYOPEN on Chain B. diff --git a/src/cosmospy_protobuf/ibc/core/commitment/v1/commitment.proto b/src/cosmospy_protobuf/ibc/core/commitment/v1/commitment.proto index 5a9c8e78..b0afed22 100644 --- a/src/cosmospy_protobuf/ibc/core/commitment/v1/commitment.proto +++ b/src/cosmospy_protobuf/ibc/core/commitment/v1/commitment.proto @@ -5,7 +5,7 @@ package ibc.core.commitment.v1; option go_package = "github.com/cosmos/ibc-go/v3/modules/core/23-commitment/types"; import "gogoproto/gogo.proto"; -import "ibc/proofs.proto"; +import "proofs.proto"; // MerkleRoot defines a merkle root hash. // In the Cosmos SDK, the AppHash of a block header becomes the root. diff --git a/src/cosmospy_protobuf/ibc/proofs.proto b/src/cosmospy_protobuf/ibc/proofs.proto deleted file mode 100644 index 33a4431f..00000000 --- a/src/cosmospy_protobuf/ibc/proofs.proto +++ /dev/null @@ -1,234 +0,0 @@ -syntax = "proto3"; - -package ics23; - -enum HashOp { - // NO_HASH is the default if no data passed. Note this is an illegal argument some places. - NO_HASH = 0; - SHA256 = 1; - SHA512 = 2; - KECCAK = 3; - RIPEMD160 = 4; - BITCOIN = 5; // ripemd160(sha256(x)) - SHA512_256 = 6; -} - -/** -LengthOp defines how to process the key and value of the LeafOp -to include length information. After encoding the length with the given -algorithm, the length will be prepended to the key and value bytes. -(Each one with it's own encoded length) -*/ -enum LengthOp { - // NO_PREFIX don't include any length info - NO_PREFIX = 0; - // VAR_PROTO uses protobuf (and go-amino) varint encoding of the length - VAR_PROTO = 1; - // VAR_RLP uses rlp int encoding of the length - VAR_RLP = 2; - // FIXED32_BIG uses big-endian encoding of the length as a 32 bit integer - FIXED32_BIG = 3; - // FIXED32_LITTLE uses little-endian encoding of the length as a 32 bit integer - FIXED32_LITTLE = 4; - // FIXED64_BIG uses big-endian encoding of the length as a 64 bit integer - FIXED64_BIG = 5; - // FIXED64_LITTLE uses little-endian encoding of the length as a 64 bit integer - FIXED64_LITTLE = 6; - // REQUIRE_32_BYTES is like NONE, but will fail if the input is not exactly 32 bytes (sha256 output) - REQUIRE_32_BYTES = 7; - // REQUIRE_64_BYTES is like NONE, but will fail if the input is not exactly 64 bytes (sha512 output) - REQUIRE_64_BYTES = 8; -} - -/** -ExistenceProof takes a key and a value and a set of steps to perform on it. -The result of peforming all these steps will provide a "root hash", which can -be compared to the value in a header. - -Since it is computationally infeasible to produce a hash collission for any of the used -cryptographic hash functions, if someone can provide a series of operations to transform -a given key and value into a root hash that matches some trusted root, these key and values -must be in the referenced merkle tree. - -The only possible issue is maliablity in LeafOp, such as providing extra prefix data, -which should be controlled by a spec. Eg. with lengthOp as NONE, - prefix = FOO, key = BAR, value = CHOICE -and - prefix = F, key = OOBAR, value = CHOICE -would produce the same value. - -With LengthOp this is tricker but not impossible. Which is why the "leafPrefixEqual" field -in the ProofSpec is valuable to prevent this mutability. And why all trees should -length-prefix the data before hashing it. -*/ -message ExistenceProof { - bytes key = 1; - bytes value = 2; - LeafOp leaf = 3; - repeated InnerOp path = 4; -} - -/* -NonExistenceProof takes a proof of two neighbors, one left of the desired key, -one right of the desired key. If both proofs are valid AND they are neighbors, -then there is no valid proof for the given key. -*/ -message NonExistenceProof { - bytes key = 1; // TODO: remove this as unnecessary??? we prove a range - ExistenceProof left = 2; - ExistenceProof right = 3; -} - -/* -CommitmentProof is either an ExistenceProof or a NonExistenceProof, or a Batch of such messages -*/ -message CommitmentProof { - oneof proof { - ExistenceProof exist = 1; - NonExistenceProof nonexist = 2; - BatchProof batch = 3; - CompressedBatchProof compressed = 4; - } -} - -/** -LeafOp represents the raw key-value data we wish to prove, and -must be flexible to represent the internal transformation from -the original key-value pairs into the basis hash, for many existing -merkle trees. - -key and value are passed in. So that the signature of this operation is: - leafOp(key, value) -> output - -To process this, first prehash the keys and values if needed (ANY means no hash in this case): - hkey = prehashKey(key) - hvalue = prehashValue(value) - -Then combine the bytes, and hash it - output = hash(prefix || length(hkey) || hkey || length(hvalue) || hvalue) -*/ -message LeafOp { - HashOp hash = 1; - HashOp prehash_key = 2; - HashOp prehash_value = 3; - LengthOp length = 4; - // prefix is a fixed bytes that may optionally be included at the beginning to differentiate - // a leaf node from an inner node. - bytes prefix = 5; -} - -/** -InnerOp represents a merkle-proof step that is not a leaf. -It represents concatenating two children and hashing them to provide the next result. - -The result of the previous step is passed in, so the signature of this op is: - innerOp(child) -> output - -The result of applying InnerOp should be: - output = op.hash(op.prefix || child || op.suffix) - - where the || operator is concatenation of binary data, -and child is the result of hashing all the tree below this step. - -Any special data, like prepending child with the length, or prepending the entire operation with -some value to differentiate from leaf nodes, should be included in prefix and suffix. -If either of prefix or suffix is empty, we just treat it as an empty string -*/ -message InnerOp { - HashOp hash = 1; - bytes prefix = 2; - bytes suffix = 3; -} - - -/** -ProofSpec defines what the expected parameters are for a given proof type. -This can be stored in the client and used to validate any incoming proofs. - - verify(ProofSpec, Proof) -> Proof | Error - -As demonstrated in tests, if we don't fix the algorithm used to calculate the -LeafHash for a given tree, there are many possible key-value pairs that can -generate a given hash (by interpretting the preimage differently). -We need this for proper security, requires client knows a priori what -tree format server uses. But not in code, rather a configuration object. -*/ -message ProofSpec { - // any field in the ExistenceProof must be the same as in this spec. - // except Prefix, which is just the first bytes of prefix (spec can be longer) - LeafOp leaf_spec = 1; - InnerSpec inner_spec = 2; - // max_depth (if > 0) is the maximum number of InnerOps allowed (mainly for fixed-depth tries) - int32 max_depth = 3; - // min_depth (if > 0) is the minimum number of InnerOps allowed (mainly for fixed-depth tries) - int32 min_depth = 4; -} - -/* -InnerSpec contains all store-specific structure info to determine if two proofs from a -given store are neighbors. - -This enables: - - isLeftMost(spec: InnerSpec, op: InnerOp) - isRightMost(spec: InnerSpec, op: InnerOp) - isLeftNeighbor(spec: InnerSpec, left: InnerOp, right: InnerOp) -*/ -message InnerSpec { - // Child order is the ordering of the children node, must count from 0 - // iavl tree is [0, 1] (left then right) - // merk is [0, 2, 1] (left, right, here) - repeated int32 child_order = 1; - int32 child_size = 2; - int32 min_prefix_length = 3; - int32 max_prefix_length = 4; - // empty child is the prehash image that is used when one child is nil (eg. 20 bytes of 0) - bytes empty_child = 5; - // hash is the algorithm that must be used for each InnerOp - HashOp hash = 6; -} - -/* -BatchProof is a group of multiple proof types than can be compressed -*/ -message BatchProof { - repeated BatchEntry entries = 1; -} - -// Use BatchEntry not CommitmentProof, to avoid recursion -message BatchEntry { - oneof proof { - ExistenceProof exist = 1; - NonExistenceProof nonexist = 2; - } -} - - -/****** all items here are compressed forms *******/ - -message CompressedBatchProof { - repeated CompressedBatchEntry entries = 1; - repeated InnerOp lookup_inners = 2; -} - -// Use BatchEntry not CommitmentProof, to avoid recursion -message CompressedBatchEntry { - oneof proof { - CompressedExistenceProof exist = 1; - CompressedNonExistenceProof nonexist = 2; - } -} - -message CompressedExistenceProof { - bytes key = 1; - bytes value = 2; - LeafOp leaf = 3; - // these are indexes into the lookup_inners table in CompressedBatchProof - repeated int32 path = 4; -} - -message CompressedNonExistenceProof { - bytes key = 1; // TODO: remove this as unnecessary??? we prove a range - CompressedExistenceProof left = 2; - CompressedExistenceProof right = 3; -} diff --git a/src/cosmospy_protobuf/osmosis/epochs/genesis.proto b/src/cosmospy_protobuf/osmosis/epochs/genesis.proto deleted file mode 100644 index cc9d5793..00000000 --- a/src/cosmospy_protobuf/osmosis/epochs/genesis.proto +++ /dev/null @@ -1,37 +0,0 @@ -syntax = "proto3"; -package osmosis.epochs.v1beta1; - -import "gogoproto/gogo.proto"; -import "google/protobuf/duration.proto"; -import "google/protobuf/timestamp.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/epochs/types"; - -message EpochInfo { - string identifier = 1; - google.protobuf.Timestamp start_time = 2 [ - (gogoproto.stdtime) = true, - (gogoproto.nullable) = false, - (gogoproto.moretags) = "yaml:\"start_time\"" - ]; - google.protobuf.Duration duration = 3 [ - (gogoproto.nullable) = false, - (gogoproto.stdduration) = true, - (gogoproto.jsontag) = "duration,omitempty", - (gogoproto.moretags) = "yaml:\"duration\"" - ]; - int64 current_epoch = 4; - google.protobuf.Timestamp current_epoch_start_time = 5 [ - (gogoproto.stdtime) = true, - (gogoproto.nullable) = false, - (gogoproto.moretags) = "yaml:\"current_epoch_start_time\"" - ]; - bool epoch_counting_started = 6; - reserved 7; - int64 current_epoch_start_height = 8; -} - -// GenesisState defines the epochs module's genesis state. -message GenesisState { - repeated EpochInfo epochs = 1 [ (gogoproto.nullable) = false ]; -} diff --git a/src/cosmospy_protobuf/osmosis/epochs/query.proto b/src/cosmospy_protobuf/osmosis/epochs/query.proto deleted file mode 100644 index 0e4776a5..00000000 --- a/src/cosmospy_protobuf/osmosis/epochs/query.proto +++ /dev/null @@ -1,30 +0,0 @@ -syntax = "proto3"; -package osmosis.epochs.v1beta1; - -import "gogoproto/gogo.proto"; -import "google/api/annotations.proto"; -import "cosmos/base/query/v1beta1/pagination.proto"; -import "osmosis/epochs/genesis.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/epochs/types"; - -// Query defines the gRPC querier service. -service Query { - // EpochInfos provide running epochInfos - rpc EpochInfos(QueryEpochsInfoRequest) returns (QueryEpochsInfoResponse) { - option (google.api.http).get = "/osmosis/epochs/v1beta1/epochs"; - } - // CurrentEpoch provide current epoch of specified identifier - rpc CurrentEpoch(QueryCurrentEpochRequest) - returns (QueryCurrentEpochResponse) { - option (google.api.http).get = "/osmosis/epochs/v1beta1/current_epoch"; - } -} - -message QueryEpochsInfoRequest {} -message QueryEpochsInfoResponse { - repeated EpochInfo epochs = 1 [ (gogoproto.nullable) = false ]; -} - -message QueryCurrentEpochRequest { string identifier = 1; } -message QueryCurrentEpochResponse { int64 current_epoch = 1; } \ No newline at end of file diff --git a/src/cosmospy_protobuf/osmosis/gamm/pool-models/balancer/balancerPool.proto b/src/cosmospy_protobuf/osmosis/gamm/pool-models/balancer/balancerPool.proto deleted file mode 100644 index f1a92e3f..00000000 --- a/src/cosmospy_protobuf/osmosis/gamm/pool-models/balancer/balancerPool.proto +++ /dev/null @@ -1,148 +0,0 @@ -syntax = "proto3"; -// this is a temporary package setup, needs migration logic -package osmosis.gamm.v1beta1; - -import "cosmos_proto/cosmos.proto"; -import "gogoproto/gogo.proto"; - -import "google/protobuf/duration.proto"; -import "google/protobuf/timestamp.proto"; - -import "cosmos/auth/v1beta1/auth.proto"; -import "cosmos/base/v1beta1/coin.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/gamm/pool-models/balancer"; - -// Parameters for changing the weights in a balancer pool smoothly from -// a start weight and end weight over a period of time. -// Currently, the only smooth change supported is linear changing between -// the two weights, but more types may be added in the future. -// When these parameters are set, the weight w(t) for pool time `t` is the -// following: -// t <= start_time: w(t) = initial_pool_weights -// start_time < t <= start_time + duration: -// w(t) = initial_pool_weights + (t - start_time) * -// (target_pool_weights - initial_pool_weights) / (duration) -// t > start_time + duration: w(t) = target_pool_weights -message SmoothWeightChangeParams { - // The start time for beginning the weight change. - // If a parameter change / pool instantiation leaves this blank, - // it should be generated by the state_machine as the current time. - google.protobuf.Timestamp start_time = 1 [ - (gogoproto.stdtime) = true, - (gogoproto.nullable) = false, - (gogoproto.moretags) = "yaml:\"start_time\"" - ]; - // Duration for the weights to change over - google.protobuf.Duration duration = 2 [ - (gogoproto.nullable) = false, - (gogoproto.stdduration) = true, - (gogoproto.jsontag) = "duration,omitempty", - (gogoproto.moretags) = "yaml:\"duration\"" - ]; - // The initial pool weights. These are copied from the pool's settings - // at the time of weight change instantiation. - // The amount PoolAsset.token.amount field is ignored if present, - // future type refactorings should just have a type with the denom & weight - // here. - repeated osmosis.gamm.v1beta1.PoolAsset initialPoolWeights = 3 [ - (gogoproto.moretags) = "yaml:\"initial_pool_weights\"", - (gogoproto.nullable) = false - ]; - // The target pool weights. The pool weights will change linearly with respect - // to time between start_time, and start_time + duration. The amount - // PoolAsset.token.amount field is ignored if present, future type - // refactorings should just have a type with the denom & weight here. - repeated osmosis.gamm.v1beta1.PoolAsset targetPoolWeights = 4 [ - (gogoproto.moretags) = "yaml:\"target_pool_weights\"", - (gogoproto.nullable) = false - ]; - // Intermediate variable for the 'slope' of pool weights. This is equal to - // (target_pool_weights - initial_pool_weights) / (duration) - // TODO: Work out precision, and decide if this is good to add - // repeated PoolAsset poolWeightSlope = 5 [ - // (gogoproto.moretags) = "yaml:\"pool_weight_slope\"", - // (gogoproto.nullable) = false - // ]; -} - -// PoolParams defined the parameters that will be managed by the pool -// governance in the future. This params are not managed by the chain -// governance. Instead they will be managed by the token holders of the pool. -// The pool's token holders are specified in future_pool_governor. -message PoolParams { - string swapFee = 1 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.moretags) = "yaml:\"swap_fee\"", - (gogoproto.nullable) = false - ]; - string exitFee = 2 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.moretags) = "yaml:\"exit_fee\"", - (gogoproto.nullable) = false - ]; - SmoothWeightChangeParams smoothWeightChangeParams = 3 [ - (gogoproto.moretags) = "yaml:\"smooth_weight_change_params\"", - (gogoproto.nullable) = true - ]; -} - -// Pool asset is an internal struct that combines the amount of the -// token in the pool, and its balancer weight. -// This is an awkward packaging of data, -// and should be revisited in a future state migration. -message PoolAsset { - // Coins we are talking about, - // the denomination must be unique amongst all PoolAssets for this pool. - cosmos.base.v1beta1.Coin token = 1 - [ (gogoproto.moretags) = "yaml:\"token\"", (gogoproto.nullable) = false ]; - // Weight that is not normalized. This weight must be less than 2^50 - string weight = 2 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.moretags) = "yaml:\"weight\"", - (gogoproto.nullable) = false - ]; -} - -message Pool { - option (gogoproto.goproto_getters) = false; - option (gogoproto.goproto_stringer) = false; - option (cosmos_proto.implements_interface) = "PoolI"; - - string address = 1 [ (gogoproto.moretags) = "yaml:\"address\"" ]; - uint64 id = 2; - - PoolParams poolParams = 3 [ - (gogoproto.moretags) = "yaml:\"balancer_pool_params\"", - (gogoproto.nullable) = false - ]; - - // This string specifies who will govern the pool in the future. - // Valid forms of this are: - // {token name},{duration} - // {duration} - // where {token name} if specified is the token which determines the - // governor, and if not specified is the LP token for this pool.duration is - // a time specified as 0w,1w,2w, etc. which specifies how long the token - // would need to be locked up to count in governance. 0w means no lockup. - // TODO: Further improve these docs - string future_pool_governor = 4 - [ (gogoproto.moretags) = "yaml:\"future_pool_governor\"" ]; - // sum of all LP tokens sent out - cosmos.base.v1beta1.Coin totalShares = 5 [ - (gogoproto.moretags) = "yaml:\"total_shares\"", - (gogoproto.nullable) = false - ]; - // These are assumed to be sorted by denomiation. - // They contain the pool asset and the information about the weight - repeated osmosis.gamm.v1beta1.PoolAsset poolAssets = 6 [ - (gogoproto.moretags) = "yaml:\"pool_assets\"", - (gogoproto.nullable) = false - ]; - // sum of all non-normalized pool weights - string totalWeight = 7 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.moretags) = "yaml:\"total_weight\"", - (gogoproto.nullable) = false - ]; -} diff --git a/src/cosmospy_protobuf/osmosis/gamm/pool-models/balancer/tx.proto b/src/cosmospy_protobuf/osmosis/gamm/pool-models/balancer/tx.proto deleted file mode 100644 index 9063c5a0..00000000 --- a/src/cosmospy_protobuf/osmosis/gamm/pool-models/balancer/tx.proto +++ /dev/null @@ -1,29 +0,0 @@ -syntax = "proto3"; -package osmosis.gamm.v1beta1; - -import "gogoproto/gogo.proto"; -import "osmosis/gamm/pool-models/balancer/balancerPool.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/gamm/pool-models/balancer"; - -service Msg { - rpc CreateBalancerPool(MsgCreateBalancerPool) - returns (MsgCreateBalancerPoolResponse); -} - -// ===================== MsgCreatePool -message MsgCreateBalancerPool { - string sender = 1 [ (gogoproto.moretags) = "yaml:\"sender\"" ]; - - PoolParams poolParams = 2 [ (gogoproto.moretags) = "yaml:\"pool_params\"" ]; - - repeated osmosis.gamm.v1beta1.PoolAsset poolAssets = 3 - [ (gogoproto.nullable) = false ]; - - string future_pool_governor = 4 - [ (gogoproto.moretags) = "yaml:\"future_pool_governor\"" ]; -} - -message MsgCreateBalancerPoolResponse { - uint64 pool_id = 1 [ (gogoproto.customname) = "PoolID" ]; -} diff --git a/src/cosmospy_protobuf/osmosis/gamm/pool-models/stableswap/stableswap_pool.proto b/src/cosmospy_protobuf/osmosis/gamm/pool-models/stableswap/stableswap_pool.proto deleted file mode 100644 index dc8f4cbd..00000000 --- a/src/cosmospy_protobuf/osmosis/gamm/pool-models/stableswap/stableswap_pool.proto +++ /dev/null @@ -1,66 +0,0 @@ -syntax = "proto3"; -package osmosis.gamm.stableswap.v1beta1; - -import "cosmos_proto/cosmos.proto"; -import "gogoproto/gogo.proto"; - -import "google/protobuf/duration.proto"; -import "google/protobuf/timestamp.proto"; - -import "cosmos/auth/v1beta1/auth.proto"; -import "cosmos/base/v1beta1/coin.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/gamm/pool-models/stableswap"; - -// PoolParams defined the parameters that will be managed by the pool -// governance in the future. This params are not managed by the chain -// governance. Instead they will be managed by the token holders of the pool. -// The pool's token holders are specified in future_pool_governor. -message PoolParams { - string swapFee = 1 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.moretags) = "yaml:\"swap_fee\"", - (gogoproto.nullable) = false - ]; - string exitFee = 2 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.moretags) = "yaml:\"exit_fee\"", - (gogoproto.nullable) = false - ]; -} - -// Pool is the stableswap Pool struct -message Pool { - option (gogoproto.goproto_getters) = false; - option (gogoproto.goproto_stringer) = false; - option (cosmos_proto.implements_interface) = "PoolI"; - - string address = 1 [ (gogoproto.moretags) = "yaml:\"address\"" ]; - uint64 id = 2; - - PoolParams poolParams = 3 [ - (gogoproto.moretags) = "yaml:\"stableswap_pool_params\"", - (gogoproto.nullable) = false - ]; - - // This string specifies who will govern the pool in the future. - // Valid forms of this are: - // {token name},{duration} - // {duration} - // where {token name} if specified is the token which determines the - // governor, and if not specified is the LP token for this pool.duration is - // a time specified as 0w,1w,2w, etc. which specifies how long the token - // would need to be locked up to count in governance. 0w means no lockup. - string future_pool_governor = 4 - [ (gogoproto.moretags) = "yaml:\"future_pool_governor\"" ]; - // sum of all LP shares - cosmos.base.v1beta1.Coin totalShares = 5 [ - (gogoproto.moretags) = "yaml:\"total_shares\"", - (gogoproto.nullable) = false - ]; - // assets in the pool - repeated cosmos.base.v1beta1.Coin poolLiquidity = 6 [ - (gogoproto.nullable) = false, - (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" - ]; -} diff --git a/src/cosmospy_protobuf/osmosis/gamm/pool-models/stableswap/tx.proto b/src/cosmospy_protobuf/osmosis/gamm/pool-models/stableswap/tx.proto deleted file mode 100644 index a6a5b269..00000000 --- a/src/cosmospy_protobuf/osmosis/gamm/pool-models/stableswap/tx.proto +++ /dev/null @@ -1,31 +0,0 @@ -syntax = "proto3"; -package osmosis.gamm.stableswap.v1beta1; - -import "cosmos/base/v1beta1/coin.proto"; -import "gogoproto/gogo.proto"; -import "osmosis/gamm/pool-models/stableswap/stableswap_pool.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/gamm/pool-models/stableswap"; - -service Msg { - rpc CreateStableswapPool(MsgCreateStableswapPool) - returns (MsgCreateStableswapPoolResponse); -} - -message MsgCreateStableswapPool { - string sender = 1 [ (gogoproto.moretags) = "yaml:\"sender\"" ]; - - PoolParams poolParams = 2 [ (gogoproto.moretags) = "yaml:\"pool_params\"" ]; - - repeated cosmos.base.v1beta1.Coin initial_pool_liquidity = 3 [ - (gogoproto.nullable) = false, - (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" - ]; - - string future_pool_governor = 4 - [ (gogoproto.moretags) = "yaml:\"future_pool_governor\"" ]; -} - -message MsgCreateStableswapPoolResponse { - uint64 pool_id = 1 [ (gogoproto.customname) = "PoolID" ]; -} diff --git a/src/cosmospy_protobuf/osmosis/gamm/v1beta1/genesis.proto b/src/cosmospy_protobuf/osmosis/gamm/v1beta1/genesis.proto deleted file mode 100644 index 4ef5340b..00000000 --- a/src/cosmospy_protobuf/osmosis/gamm/v1beta1/genesis.proto +++ /dev/null @@ -1,26 +0,0 @@ -syntax = "proto3"; -package osmosis.gamm.v1beta1; - -import "gogoproto/gogo.proto"; -import "google/protobuf/any.proto"; -import "cosmos_proto/cosmos.proto"; -import "cosmos/base/v1beta1/coin.proto"; - -// Params holds parameters for the incentives module -message Params { - repeated cosmos.base.v1beta1.Coin pool_creation_fee = 1 [ - (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins", - (gogoproto.moretags) = "yaml:\"pool_creation_fee\"", - (gogoproto.nullable) = false - ]; -} - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/gamm/types"; - -// GenesisState defines the gamm module's genesis state. -message GenesisState { - repeated google.protobuf.Any pools = 1 - [ (cosmos_proto.accepts_interface) = "PoolI" ]; - uint64 next_pool_number = 2; - Params params = 3 [ (gogoproto.nullable) = false ]; -} diff --git a/src/cosmospy_protobuf/osmosis/gamm/v1beta1/query.proto b/src/cosmospy_protobuf/osmosis/gamm/v1beta1/query.proto deleted file mode 100644 index 78867d6b..00000000 --- a/src/cosmospy_protobuf/osmosis/gamm/v1beta1/query.proto +++ /dev/null @@ -1,193 +0,0 @@ -syntax = "proto3"; -package osmosis.gamm.v1beta1; - -import "gogoproto/gogo.proto"; -import "osmosis/gamm/v1beta1/tx.proto"; - -import "cosmos/base/v1beta1/coin.proto"; -import "cosmos/base/query/v1beta1/pagination.proto"; -import "google/api/annotations.proto"; -import "google/protobuf/any.proto"; -import "cosmos_proto/cosmos.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/gamm/types"; - -service Query { - rpc Pools(QueryPoolsRequest) returns (QueryPoolsResponse) { - option (google.api.http).get = "/osmosis/gamm/v1beta1/pools"; - } - - rpc NumPools(QueryNumPoolsRequest) returns (QueryNumPoolsResponse) { - option (google.api.http).get = "/osmosis/gamm/v1beta1/num_pools"; - } - - rpc TotalLiquidity(QueryTotalLiquidityRequest) - returns (QueryTotalLiquidityResponse) { - option (google.api.http).get = "/osmosis/gamm/v1beta1/total_liquidity"; - } - - // Per Pool gRPC Endpoints - rpc Pool(QueryPoolRequest) returns (QueryPoolResponse) { - option (google.api.http).get = "/osmosis/gamm/v1beta1/pools/{poolId}"; - } - - rpc PoolParams(QueryPoolParamsRequest) returns (QueryPoolParamsResponse) { - option (google.api.http).get = - "/osmosis/gamm/v1beta1/pools/{poolId}/params"; - } - - rpc TotalPoolLiquidity(QueryTotalPoolLiquidityRequest) - returns (QueryTotalPoolLiquidityResponse) { - option (google.api.http).get = - "/osmosis/gamm/v1beta1/pools/{poolId}/total_pool_liquidity"; - } - - rpc TotalShares(QueryTotalSharesRequest) returns (QueryTotalSharesResponse) { - option (google.api.http).get = - "/osmosis/gamm/v1beta1/pools/{poolId}/total_shares"; - } - - // SpotPrice defines a gRPC query handler that returns the spot price given - // a base denomination and a quote denomination. - rpc SpotPrice(QuerySpotPriceRequest) returns (QuerySpotPriceResponse) { - option (google.api.http).get = - "/osmosis/gamm/v1beta1/pools/{poolId}/prices"; - } - - // Estimate the swap. - rpc EstimateSwapExactAmountIn(QuerySwapExactAmountInRequest) - returns (QuerySwapExactAmountInResponse) { - option (google.api.http).get = - "/osmosis/gamm/v1beta1/{poolId}/estimate/swap_exact_amount_in"; - } - - rpc EstimateSwapExactAmountOut(QuerySwapExactAmountOutRequest) - returns (QuerySwapExactAmountOutResponse) { - option (google.api.http).get = - "/osmosis/gamm/v1beta1/{poolId}/estimate/swap_exact_amount_out"; - } -} - -//=============================== Pool -message QueryPoolRequest { - uint64 poolId = 1 [ (gogoproto.moretags) = "yaml:\"pool_id\"" ]; -} -message QueryPoolResponse { - google.protobuf.Any pool = 1 [ (cosmos_proto.accepts_interface) = "PoolI" ]; -} - -//=============================== Pools -message QueryPoolsRequest { - // pagination defines an optional pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} -message QueryPoolsResponse { - repeated google.protobuf.Any pools = 1 - [ (cosmos_proto.accepts_interface) = "PoolI" ]; - - // pagination defines the pagination in the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -//=============================== NumPools -message QueryNumPoolsRequest {} -message QueryNumPoolsResponse { - uint64 numPools = 1 [ (gogoproto.moretags) = "yaml:\"num_pools\"" ]; -} - -//=============================== PoolParams -message QueryPoolParamsRequest { - uint64 poolId = 1 [ (gogoproto.moretags) = "yaml:\"pool_id\"" ]; -} -message QueryPoolParamsResponse { google.protobuf.Any params = 1; } - -//=============================== PoolLiquidity -message QueryTotalPoolLiquidityRequest { - uint64 poolId = 1 [ (gogoproto.moretags) = "yaml:\"pool_id\"" ]; -} - -message QueryTotalPoolLiquidityResponse { - repeated cosmos.base.v1beta1.Coin liquidity = 1 [ - (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins", - (gogoproto.moretags) = "yaml:\"liquidity\"", - (gogoproto.nullable) = false - ]; -} - -//=============================== TotalShares -message QueryTotalSharesRequest { - uint64 poolId = 1 [ (gogoproto.moretags) = "yaml:\"pool_id\"" ]; -} -message QueryTotalSharesResponse { - cosmos.base.v1beta1.Coin totalShares = 1 [ - (gogoproto.moretags) = "yaml:\"total_shares\"", - (gogoproto.nullable) = false - ]; -} - -// QuerySpotPriceRequest defines the gRPC request structure for a SpotPrice -// query. -message QuerySpotPriceRequest { - uint64 poolId = 1 [ (gogoproto.moretags) = "yaml:\"pool_id\"" ]; - string base_asset_denom = 2 - [ (gogoproto.moretags) = "yaml:\"base_asset_denom\"" ]; - string quote_asset_denom = 3 - [ (gogoproto.moretags) = "yaml:\"quote_asset_denom\"" ]; - reserved 4; - reserved "withSwapFee"; -} - -// QuerySpotPriceResponse defines the gRPC response structure for a SpotPrice -// query. -message QuerySpotPriceResponse { - // String of the Dec. Ex) 10.203uatom - string spotPrice = 1 [ (gogoproto.moretags) = "yaml:\"spot_price\"" ]; -} - -//=============================== EstimateSwapExactAmountIn -message QuerySwapExactAmountInRequest { - string sender = 1 [ (gogoproto.moretags) = "yaml:\"sender\"" ]; - uint64 poolId = 2 [ (gogoproto.moretags) = "yaml:\"pool_id\"" ]; - string tokenIn = 3 [ (gogoproto.moretags) = "yaml:\"token_in\"" ]; - repeated SwapAmountInRoute routes = 4 [ - (gogoproto.moretags) = "yaml:\"routes\"", - (gogoproto.nullable) = false - ]; -} - -message QuerySwapExactAmountInResponse { - string tokenOutAmount = 1 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.moretags) = "yaml:\"token_out_amount\"", - (gogoproto.nullable) = false - ]; -} - -//=============================== EstimateSwapExactAmountOut -message QuerySwapExactAmountOutRequest { - string sender = 1 [ (gogoproto.moretags) = "yaml:\"sender\"" ]; - uint64 poolId = 2 [ (gogoproto.moretags) = "yaml:\"pool_id\"" ]; - repeated SwapAmountOutRoute routes = 3 [ - (gogoproto.moretags) = "yaml:\"routes\"", - (gogoproto.nullable) = false - ]; - string tokenOut = 4 [ (gogoproto.moretags) = "yaml:\"token_out\"" ]; -} - -message QuerySwapExactAmountOutResponse { - string tokenInAmount = 1 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.moretags) = "yaml:\"token_in_amount\"", - (gogoproto.nullable) = false - ]; -} - -message QueryTotalLiquidityRequest {} - -message QueryTotalLiquidityResponse { - repeated cosmos.base.v1beta1.Coin liquidity = 1 [ - (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins", - (gogoproto.moretags) = "yaml:\"liquidity\"", - (gogoproto.nullable) = false - ]; -} diff --git a/src/cosmospy_protobuf/osmosis/gamm/v1beta1/tx.proto b/src/cosmospy_protobuf/osmosis/gamm/v1beta1/tx.proto deleted file mode 100644 index 13534ff3..00000000 --- a/src/cosmospy_protobuf/osmosis/gamm/v1beta1/tx.proto +++ /dev/null @@ -1,219 +0,0 @@ -syntax = "proto3"; -package osmosis.gamm.v1beta1; - -import "gogoproto/gogo.proto"; -import "cosmos/base/v1beta1/coin.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/gamm/types"; - -service Msg { - rpc JoinPool(MsgJoinPool) returns (MsgJoinPoolResponse); - rpc ExitPool(MsgExitPool) returns (MsgExitPoolResponse); - rpc SwapExactAmountIn(MsgSwapExactAmountIn) - returns (MsgSwapExactAmountInResponse); - rpc SwapExactAmountOut(MsgSwapExactAmountOut) - returns (MsgSwapExactAmountOutResponse); - rpc JoinSwapExternAmountIn(MsgJoinSwapExternAmountIn) - returns (MsgJoinSwapExternAmountInResponse); - rpc JoinSwapShareAmountOut(MsgJoinSwapShareAmountOut) - returns (MsgJoinSwapShareAmountOutResponse); - rpc ExitSwapExternAmountOut(MsgExitSwapExternAmountOut) - returns (MsgExitSwapExternAmountOutResponse); - rpc ExitSwapShareAmountIn(MsgExitSwapShareAmountIn) - returns (MsgExitSwapShareAmountInResponse); -} - -// ===================== MsgJoinPool -// This is really MsgJoinPoolNoSwap -message MsgJoinPool { - string sender = 1 [ (gogoproto.moretags) = "yaml:\"sender\"" ]; - uint64 poolId = 2 [ (gogoproto.moretags) = "yaml:\"pool_id\"" ]; - string shareOutAmount = 3 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.moretags) = "yaml:\"pool_amount_out\"", - (gogoproto.nullable) = false - ]; - repeated cosmos.base.v1beta1.Coin tokenInMaxs = 4 [ - (gogoproto.moretags) = "yaml:\"token_in_max_amounts\"", - (gogoproto.nullable) = false - ]; -} - -message MsgJoinPoolResponse {} - -// ===================== MsgExitPool -message MsgExitPool { - string sender = 1 [ (gogoproto.moretags) = "yaml:\"sender\"" ]; - uint64 poolId = 2 [ (gogoproto.moretags) = "yaml:\"pool_id\"" ]; - string shareInAmount = 3 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.moretags) = "yaml:\"share_in_amount\"", - (gogoproto.nullable) = false - ]; - - repeated cosmos.base.v1beta1.Coin tokenOutMins = 4 [ - (gogoproto.moretags) = "yaml:\"token_out_min_amounts\"", - (gogoproto.nullable) = false - ]; -} - -message MsgExitPoolResponse {} - -// ===================== MsgSwapExactAmountIn -message SwapAmountInRoute { - uint64 poolId = 1 [ (gogoproto.moretags) = "yaml:\"pool_id\"" ]; - string tokenOutDenom = 2 - [ (gogoproto.moretags) = "yaml:\"token_out_denom\"" ]; -} - -message MsgSwapExactAmountIn { - string sender = 1 [ (gogoproto.moretags) = "yaml:\"sender\"" ]; - repeated SwapAmountInRoute routes = 2 [ (gogoproto.nullable) = false ]; - cosmos.base.v1beta1.Coin tokenIn = 3 [ - (gogoproto.moretags) = "yaml:\"token_in\"", - (gogoproto.nullable) = false - ]; - string tokenOutMinAmount = 4 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.moretags) = "yaml:\"token_out_min_amount\"", - (gogoproto.nullable) = false - ]; -} - -message MsgSwapExactAmountInResponse { - string tokenOutAmount = 1 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.moretags) = "yaml:\"token_out_amount\"", - (gogoproto.nullable) = false - ]; -} - -// ===================== MsgSwapExactAmountOut -message SwapAmountOutRoute { - uint64 poolId = 1 [ (gogoproto.moretags) = "yaml:\"pool_id\"" ]; - string tokenInDenom = 2 [ (gogoproto.moretags) = "yaml:\"token_out_denom\"" ]; -} - -message MsgSwapExactAmountOut { - string sender = 1 [ (gogoproto.moretags) = "yaml:\"sender\"" ]; - repeated SwapAmountOutRoute routes = 2 [ (gogoproto.nullable) = false ]; - string tokenInMaxAmount = 3 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.moretags) = "yaml:\"token_in_max_amount\"", - (gogoproto.nullable) = false - ]; - cosmos.base.v1beta1.Coin tokenOut = 4 [ - (gogoproto.moretags) = "yaml:\"token_out\"", - (gogoproto.nullable) = false - ]; -} - -message MsgSwapExactAmountOutResponse { - string tokenInAmount = 1 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.moretags) = "yaml:\"token_in_amount\"", - (gogoproto.nullable) = false - ]; -} - -// ===================== MsgJoinSwapExternAmountIn -// TODO: Rename to MsgJoinSwapExactAmountIn -message MsgJoinSwapExternAmountIn { - string sender = 1 [ (gogoproto.moretags) = "yaml:\"sender\"" ]; - uint64 poolId = 2 [ (gogoproto.moretags) = "yaml:\"pool_id\"" ]; - cosmos.base.v1beta1.Coin tokenIn = 3 [ - (gogoproto.moretags) = "yaml:\"token_in\"", - (gogoproto.nullable) = false - ]; - string shareOutMinAmount = 4 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.moretags) = "yaml:\"share_out_min_amount\"", - (gogoproto.nullable) = false - ]; - // repeated cosmos.base.v1beta1.Coin tokensIn = 5 [ - // (gogoproto.moretags) = "yaml:\"tokens_in\"", - // (gogoproto.nullable) = false - // ]; -} - -message MsgJoinSwapExternAmountInResponse { - string shareOutAmount = 1 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.moretags) = "yaml:\"share_out_amount\"", - (gogoproto.nullable) = false - ]; -} - -// ===================== MsgJoinSwapShareAmountOut -message MsgJoinSwapShareAmountOut { - string sender = 1 [ (gogoproto.moretags) = "yaml:\"sender\"" ]; - uint64 poolId = 2 [ (gogoproto.moretags) = "yaml:\"pool_id\"" ]; - string tokenInDenom = 3 [ (gogoproto.moretags) = "yaml:\"token_in_denom\"" ]; - string shareOutAmount = 4 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.moretags) = "yaml:\"share_out_amount\"", - (gogoproto.nullable) = false - ]; - string tokenInMaxAmount = 5 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.moretags) = "yaml:\"token_in_max_amount\"", - (gogoproto.nullable) = false - ]; -} - -message MsgJoinSwapShareAmountOutResponse { - string tokenInAmount = 1 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.moretags) = "yaml:\"token_in_amount\"", - (gogoproto.nullable) = false - ]; -} - -// ===================== MsgExitSwapShareAmountIn -message MsgExitSwapShareAmountIn { - string sender = 1 [ (gogoproto.moretags) = "yaml:\"sender\"" ]; - uint64 poolId = 2 [ (gogoproto.moretags) = "yaml:\"pool_id\"" ]; - string tokenOutDenom = 3 - [ (gogoproto.moretags) = "yaml:\"token_out_denom\"" ]; - string shareInAmount = 4 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.moretags) = "yaml:\"share_in_amount\"", - (gogoproto.nullable) = false - ]; - string tokenOutMinAmount = 5 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.moretags) = "yaml:\"token_out_min_amount\"", - (gogoproto.nullable) = false - ]; -} - -message MsgExitSwapShareAmountInResponse { - string tokenOutAmount = 1 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.moretags) = "yaml:\"token_out_amount\"", - (gogoproto.nullable) = false - ]; -} - -// ===================== MsgExitSwapExternAmountOut -message MsgExitSwapExternAmountOut { - string sender = 1 [ (gogoproto.moretags) = "yaml:\"sender\"" ]; - uint64 poolId = 2 [ (gogoproto.moretags) = "yaml:\"pool_id\"" ]; - cosmos.base.v1beta1.Coin tokenOut = 3 [ - (gogoproto.moretags) = "yaml:\"token_out\"", - (gogoproto.nullable) = false - ]; - string shareInMaxAmount = 4 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.moretags) = "yaml:\"share_in_max_amount\"", - (gogoproto.nullable) = false - ]; -} - -message MsgExitSwapExternAmountOutResponse { - string shareInAmount = 1 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.moretags) = "yaml:\"share_in_amount\"", - (gogoproto.nullable) = false - ]; -} diff --git a/src/cosmospy_protobuf/osmosis/incentives/gauge.proto b/src/cosmospy_protobuf/osmosis/incentives/gauge.proto deleted file mode 100644 index 87c80cde..00000000 --- a/src/cosmospy_protobuf/osmosis/incentives/gauge.proto +++ /dev/null @@ -1,51 +0,0 @@ -syntax = "proto3"; -package osmosis.incentives; - -import "gogoproto/gogo.proto"; -import "google/protobuf/duration.proto"; -import "google/protobuf/timestamp.proto"; -import "cosmos/base/v1beta1/coin.proto"; -import "osmosis/lockup/lock.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/incentives/types"; - -message Gauge { - // unique ID of a Gauge - uint64 id = 1; - // flag to show if it's perpetual or multi-epoch - // distribution incentives by third party - bool is_perpetual = 2; - // Rewards are distributed to lockups that are are returned by at least one of - // these queries - osmosis.lockup.QueryCondition distribute_to = 3 - [ (gogoproto.nullable) = false ]; - // total amount of Coins that has been in the gauge. - // can distribute multiple coins - repeated cosmos.base.v1beta1.Coin coins = 4 [ - (gogoproto.nullable) = false, - (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" - ]; - // distribution start time - google.protobuf.Timestamp start_time = 5 [ - (gogoproto.stdtime) = true, - (gogoproto.nullable) = false, - (gogoproto.moretags) = "yaml:\"start_time\"" - ]; - // number of epochs distribution will be done - uint64 num_epochs_paid_over = 6; - // number of epochs distributed already - uint64 filled_epochs = 7; - // already distributed coins - repeated cosmos.base.v1beta1.Coin distributed_coins = 8 [ - (gogoproto.nullable) = false, - (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" - ]; -} - -message LockableDurationsInfo { - repeated google.protobuf.Duration lockable_durations = 1 [ - (gogoproto.nullable) = false, - (gogoproto.stdduration) = true, - (gogoproto.moretags) = "yaml:\"lockable_durations\"" - ]; -} \ No newline at end of file diff --git a/src/cosmospy_protobuf/osmosis/incentives/genesis.proto b/src/cosmospy_protobuf/osmosis/incentives/genesis.proto deleted file mode 100644 index b1abf386..00000000 --- a/src/cosmospy_protobuf/osmosis/incentives/genesis.proto +++ /dev/null @@ -1,22 +0,0 @@ -syntax = "proto3"; -package osmosis.incentives; - -import "gogoproto/gogo.proto"; -import "google/protobuf/duration.proto"; -import "osmosis/incentives/params.proto"; -import "osmosis/incentives/gauge.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/incentives/types"; - -// GenesisState defines the incentives module's genesis state. -message GenesisState { - // params defines all the parameters of the module - Params params = 1 [ (gogoproto.nullable) = false ]; - repeated Gauge gauges = 2 [ (gogoproto.nullable) = false ]; - repeated google.protobuf.Duration lockable_durations = 3 [ - (gogoproto.nullable) = false, - (gogoproto.stdduration) = true, - (gogoproto.moretags) = "yaml:\"lockable_durations\"" - ]; - uint64 last_gauge_id = 4; -} diff --git a/src/cosmospy_protobuf/osmosis/incentives/params.proto b/src/cosmospy_protobuf/osmosis/incentives/params.proto deleted file mode 100644 index 47709619..00000000 --- a/src/cosmospy_protobuf/osmosis/incentives/params.proto +++ /dev/null @@ -1,13 +0,0 @@ -syntax = "proto3"; -package osmosis.incentives; - -import "gogoproto/gogo.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/incentives/types"; - -// Params holds parameters for the incentives module -message Params { - // distribution epoch identifier - string distr_epoch_identifier = 1 - [ (gogoproto.moretags) = "yaml:\"distr_epoch_identifier\"" ]; -} diff --git a/src/cosmospy_protobuf/osmosis/incentives/query.proto b/src/cosmospy_protobuf/osmosis/incentives/query.proto deleted file mode 100644 index de04142e..00000000 --- a/src/cosmospy_protobuf/osmosis/incentives/query.proto +++ /dev/null @@ -1,164 +0,0 @@ -syntax = "proto3"; -package osmosis.incentives; - -import "gogoproto/gogo.proto"; -import "google/api/annotations.proto"; -import "google/protobuf/duration.proto"; -import "cosmos/base/v1beta1/coin.proto"; -import "cosmos/base/query/v1beta1/pagination.proto"; -import "osmosis/incentives/gauge.proto"; -import "osmosis/lockup/lock.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/incentives/types"; - -// Query defines the gRPC querier service. -service Query { - // returns coins that is going to be distributed - rpc ModuleToDistributeCoins(ModuleToDistributeCoinsRequest) - returns (ModuleToDistributeCoinsResponse) { - option (google.api.http).get = - "/osmosis/incentives/v1beta1/module_to_distribute_coins"; - } - // returns coins that are distributed by module so far - rpc ModuleDistributedCoins(ModuleDistributedCoinsRequest) - returns (ModuleDistributedCoinsResponse) { - option (google.api.http).get = - "/osmosis/incentives/v1beta1/module_distributed_coins"; - } - - // returns Gauge by id - rpc GaugeByID(GaugeByIDRequest) returns (GaugeByIDResponse) { - option (google.api.http).get = - "/osmosis/incentives/v1beta1/gauge_by_id/{id}"; - } - // returns gauges both upcoming and active - rpc Gauges(GaugesRequest) returns (GaugesResponse) { - option (google.api.http).get = "/osmosis/incentives/v1beta1/gauges"; - } - // returns active gauges - rpc ActiveGauges(ActiveGaugesRequest) returns (ActiveGaugesResponse) { - option (google.api.http).get = "/osmosis/incentives/v1beta1/active_gauges"; - } - // returns active gauges per denom - rpc ActiveGaugesPerDenom(ActiveGaugesPerDenomRequest) - returns (ActiveGaugesPerDenomResponse) { - option (google.api.http).get = - "/osmosis/incentives/v1beta1/active_gauges_per_denom"; - } - // returns scheduled gauges - rpc UpcomingGauges(UpcomingGaugesRequest) returns (UpcomingGaugesResponse) { - option (google.api.http).get = - "/osmosis/incentives/v1beta1/upcoming_gauges"; - } - // returns scheduled gauges per denom - rpc UpcomingGaugesPerDenom(UpcomingGaugesPerDenomRequest) - returns (UpcomingGaugesPerDenomResponse) { - option (google.api.http).get = - "/osmosis/incentives/v1beta1/upcoming_gauges_per_denom"; - } - - // RewardsEst returns an estimate of the rewards at a future specific time. - // The querier either provides an address or a set of locks - // for which they want to find the associated rewards. - rpc RewardsEst(RewardsEstRequest) returns (RewardsEstResponse) { - option (google.api.http).get = - "/osmosis/incentives/v1beta1/rewards_est/{owner}"; - } - // returns lockable durations that are valid to give incentives - rpc LockableDurations(QueryLockableDurationsRequest) - returns (QueryLockableDurationsResponse) { - option (google.api.http).get = - "/osmosis/incentives/v1beta1/lockable_durations"; - } -} - -message ModuleToDistributeCoinsRequest {} -message ModuleToDistributeCoinsResponse { - repeated cosmos.base.v1beta1.Coin coins = 1 [ - (gogoproto.nullable) = false, - (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" - ]; -} - -message ModuleDistributedCoinsRequest {} -message ModuleDistributedCoinsResponse { - repeated cosmos.base.v1beta1.Coin coins = 1 [ - (gogoproto.nullable) = false, - (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" - ]; -} - -message GaugeByIDRequest { uint64 id = 1; } -message GaugeByIDResponse { Gauge gauge = 1; } - -message GaugesRequest { - // pagination defines an pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 1; -} -message GaugesResponse { - repeated Gauge data = 1 [ (gogoproto.nullable) = false ]; - // pagination defines an pagination for the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -message ActiveGaugesRequest { - // pagination defines an pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 1; -} -message ActiveGaugesResponse { - repeated Gauge data = 1 [ (gogoproto.nullable) = false ]; - // pagination defines an pagination for the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -message ActiveGaugesPerDenomRequest { - string denom = 1; - // pagination defines an pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} -message ActiveGaugesPerDenomResponse { - repeated Gauge data = 1 [ (gogoproto.nullable) = false ]; - // pagination defines an pagination for the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -message UpcomingGaugesRequest { - // pagination defines an pagination for the request. - cosmos.base.query.v1beta1.PageRequest pagination = 1; -} -message UpcomingGaugesResponse { - repeated Gauge data = 1 [ (gogoproto.nullable) = false ]; - // pagination defines an pagination for the response. - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -message UpcomingGaugesPerDenomRequest { - string denom = 1; - cosmos.base.query.v1beta1.PageRequest pagination = 2; -} - -message UpcomingGaugesPerDenomResponse { - repeated Gauge upcoming_gauges = 1 [ (gogoproto.nullable) = false ]; - cosmos.base.query.v1beta1.PageResponse pagination = 2; -} - -message RewardsEstRequest { - string owner = 1 [ (gogoproto.moretags) = "yaml:\"owner\"" ]; - repeated uint64 lock_ids = 2; - int64 end_epoch = 3; -} -message RewardsEstResponse { - repeated cosmos.base.v1beta1.Coin coins = 1 [ - (gogoproto.nullable) = false, - (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" - ]; -} - -message QueryLockableDurationsRequest {} -message QueryLockableDurationsResponse { - repeated google.protobuf.Duration lockable_durations = 1 [ - (gogoproto.nullable) = false, - (gogoproto.stdduration) = true, - (gogoproto.moretags) = "yaml:\"lockable_durations\"" - ]; -} \ No newline at end of file diff --git a/src/cosmospy_protobuf/osmosis/incentives/tx.proto b/src/cosmospy_protobuf/osmosis/incentives/tx.proto deleted file mode 100644 index 06c76fc9..00000000 --- a/src/cosmospy_protobuf/osmosis/incentives/tx.proto +++ /dev/null @@ -1,50 +0,0 @@ -syntax = "proto3"; -package osmosis.incentives; - -import "gogoproto/gogo.proto"; -import "google/protobuf/timestamp.proto"; -import "cosmos/base/v1beta1/coin.proto"; -import "osmosis/incentives/gauge.proto"; -import "osmosis/lockup/lock.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/incentives/types"; - -service Msg { - rpc CreateGauge(MsgCreateGauge) returns (MsgCreateGaugeResponse); - rpc AddToGauge(MsgAddToGauge) returns (MsgAddToGaugeResponse); -} - -message MsgCreateGauge { - // flag to show if it's perpetual or multi-epoch - // distribution incentives by third party - bool is_perpetual = 1; - - string owner = 2 [ (gogoproto.moretags) = "yaml:\"owner\"" ]; - // distribute condition of a lock which meet one of these conditions - osmosis.lockup.QueryCondition distribute_to = 3 - [ (gogoproto.nullable) = false ]; - // can distribute multiple coins - repeated cosmos.base.v1beta1.Coin coins = 4 [ - (gogoproto.nullable) = false, - (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" - ]; - // distribution start time - google.protobuf.Timestamp start_time = 5 [ - (gogoproto.stdtime) = true, - (gogoproto.nullable) = false, - (gogoproto.moretags) = "yaml:\"timestamp\"" - ]; - // number of epochs distribution will be done - uint64 num_epochs_paid_over = 6; -} -message MsgCreateGaugeResponse {} - -message MsgAddToGauge { - string owner = 1 [ (gogoproto.moretags) = "yaml:\"owner\"" ]; - uint64 gauge_id = 2; - repeated cosmos.base.v1beta1.Coin rewards = 3 [ - (gogoproto.nullable) = false, - (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" - ]; -} -message MsgAddToGaugeResponse {} diff --git a/src/cosmospy_protobuf/osmosis/lockup/genesis.proto b/src/cosmospy_protobuf/osmosis/lockup/genesis.proto deleted file mode 100644 index 52f49808..00000000 --- a/src/cosmospy_protobuf/osmosis/lockup/genesis.proto +++ /dev/null @@ -1,14 +0,0 @@ -syntax = "proto3"; -package osmosis.lockup; - -import "gogoproto/gogo.proto"; -import "osmosis/lockup/lock.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/lockup/types"; - -// GenesisState defines the lockup module's genesis state. -message GenesisState { - uint64 last_lock_id = 1; - repeated PeriodLock locks = 2 [ (gogoproto.nullable) = false ]; - repeated SyntheticLock synthetic_locks = 3 [ (gogoproto.nullable) = false ]; -} diff --git a/src/cosmospy_protobuf/osmosis/lockup/lock.proto b/src/cosmospy_protobuf/osmosis/lockup/lock.proto deleted file mode 100644 index 16dcbabe..00000000 --- a/src/cosmospy_protobuf/osmosis/lockup/lock.proto +++ /dev/null @@ -1,93 +0,0 @@ -syntax = "proto3"; -package osmosis.lockup; - -import "gogoproto/gogo.proto"; -import "google/protobuf/duration.proto"; -import "google/protobuf/timestamp.proto"; -import "cosmos/base/v1beta1/coin.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/lockup/types"; - -// PeriodLock is a single unit of lock by period. It's a record of locked coin -// at a specific time. It stores owner, duration, unlock time and the amount of -// coins locked. -message PeriodLock { - uint64 ID = 1; - string owner = 2 [ (gogoproto.moretags) = "yaml:\"owner\"" ]; - google.protobuf.Duration duration = 3 [ - (gogoproto.nullable) = false, - (gogoproto.stdduration) = true, - (gogoproto.jsontag) = "duration,omitempty", - (gogoproto.moretags) = "yaml:\"duration\"" - ]; - google.protobuf.Timestamp end_time = 4 [ - (gogoproto.stdtime) = true, - (gogoproto.nullable) = false, - (gogoproto.moretags) = "yaml:\"end_time\"" - ]; - repeated cosmos.base.v1beta1.Coin coins = 5 [ - (gogoproto.nullable) = false, - (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" - ]; -} - -enum LockQueryType { - option (gogoproto.goproto_enum_prefix) = false; - - // Queries for locks that are longer than a certain duration - ByDuration = 0; - // Queries for lockups that started before a specific time - ByTime = 1; -} - -message QueryCondition { - // type of lock query, ByLockDuration | ByLockTime - LockQueryType lock_query_type = 1; - // What token denomination are we looking for lockups of - string denom = 2; - // valid when query condition is ByDuration - google.protobuf.Duration duration = 3 [ - (gogoproto.stdduration) = true, - (gogoproto.nullable) = false, - (gogoproto.moretags) = "yaml:\"duration\"" - ]; - // valid when query condition is ByTime - google.protobuf.Timestamp timestamp = 4 [ - (gogoproto.stdtime) = true, - (gogoproto.nullable) = false, - (gogoproto.moretags) = "yaml:\"timestamp\"" - ]; -} - -// SyntheticLock is a single unit of synthetic lockup -// TODO: Change this to have -// * underlying_lock_id -// * synthetic_coin -// * end_time -// * duration -// * owner -// We then index synthetic locks by the denom, just like we do with normal -// locks. Ideally we even get an interface, so we can re-use that same logic. -// I currently have no idea how reward distribution is supposed to be working... -// EVENTUALLY -// we make a "constrained_coin" field, which is what the current "coins" field -// is. Constrained coin field can be a #post-v7 feature, since we aren't -// allowing partial unlocks of synthetic lockups. -message SyntheticLock { - // underlying native lockup id for this synthetic lockup - uint64 underlying_lock_id = 1; - string synth_denom = 2; - // used for unbonding synthetic lockups, for active synthetic lockups, this - // value is set to uninitialized value - google.protobuf.Timestamp end_time = 3 [ - (gogoproto.stdtime) = true, - (gogoproto.nullable) = false, - (gogoproto.moretags) = "yaml:\"end_time\"" - ]; - google.protobuf.Duration duration = 4 [ - (gogoproto.nullable) = false, - (gogoproto.stdduration) = true, - (gogoproto.jsontag) = "duration,omitempty", - (gogoproto.moretags) = "yaml:\"duration\"" - ]; -} diff --git a/src/cosmospy_protobuf/osmosis/lockup/query.proto b/src/cosmospy_protobuf/osmosis/lockup/query.proto deleted file mode 100644 index 780a5e8c..00000000 --- a/src/cosmospy_protobuf/osmosis/lockup/query.proto +++ /dev/null @@ -1,289 +0,0 @@ -syntax = "proto3"; -package osmosis.lockup; - -import "gogoproto/gogo.proto"; -import "cosmos/base/v1beta1/coin.proto"; -import "google/api/annotations.proto"; -import "google/protobuf/timestamp.proto"; -import "google/protobuf/duration.proto"; -import "osmosis/lockup/lock.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/lockup/types"; - -// Query defines the gRPC querier service. -service Query { - // Return full balance of the module - rpc ModuleBalance(ModuleBalanceRequest) returns (ModuleBalanceResponse) { - option (google.api.http).get = "/osmosis/lockup/v1beta1/module_balance"; - } - // Return locked balance of the module - rpc ModuleLockedAmount(ModuleLockedAmountRequest) - returns (ModuleLockedAmountResponse) { - option (google.api.http).get = - "/osmosis/lockup/v1beta1/module_locked_amount"; - } - - // Returns unlockable coins which are not withdrawn yet - rpc AccountUnlockableCoins(AccountUnlockableCoinsRequest) - returns (AccountUnlockableCoinsResponse) { - option (google.api.http).get = - "/osmosis/lockup/v1beta1/account_unlockable_coins/{owner}"; - } - // Returns unlocking coins - rpc AccountUnlockingCoins(AccountUnlockingCoinsRequest) - returns (AccountUnlockingCoinsResponse) { - option (google.api.http).get = - "/osmosis/lockup/v1beta1/account_unlocking_coins/{owner}"; - } - // Return a locked coins that can't be withdrawn - rpc AccountLockedCoins(AccountLockedCoinsRequest) - returns (AccountLockedCoinsResponse) { - option (google.api.http).get = - "/osmosis/lockup/v1beta1/account_locked_coins/{owner}"; - } - - // Returns locked records of an account with unlock time beyond timestamp - rpc AccountLockedPastTime(AccountLockedPastTimeRequest) - returns (AccountLockedPastTimeResponse) { - option (google.api.http).get = - "/osmosis/lockup/v1beta1/account_locked_pasttime/{owner}"; - } - // Returns locked records of an account with unlock time beyond timestamp - // excluding tokens started unlocking - rpc AccountLockedPastTimeNotUnlockingOnly( - AccountLockedPastTimeNotUnlockingOnlyRequest) - returns (AccountLockedPastTimeNotUnlockingOnlyResponse) { - option (google.api.http).get = - "/osmosis/lockup/v1beta1/account_locked_pasttime_not_unlocking_only/" - "{owner}"; - } - // Returns unlocked records with unlock time before timestamp - rpc AccountUnlockedBeforeTime(AccountUnlockedBeforeTimeRequest) - returns (AccountUnlockedBeforeTimeResponse) { - option (google.api.http).get = - "/osmosis/lockup/v1beta1/account_unlocked_before_time/{owner}"; - } - - // Returns lock records by address, timestamp, denom - rpc AccountLockedPastTimeDenom(AccountLockedPastTimeDenomRequest) - returns (AccountLockedPastTimeDenomResponse) { - option (google.api.http).get = - "/osmosis/lockup/v1beta1/account_locked_pasttime_denom/{owner}"; - } - - // Returns total locked per denom with longer past given time - rpc LockedDenom(LockedDenomRequest) returns (LockedDenomResponse) { - option (google.api.http).get = "/osmosis/lockup/v1beta1/locked_denom"; - } - - // Returns lock record by id - rpc LockedByID(LockedRequest) returns (LockedResponse) { - option (google.api.http).get = - "/osmosis/lockup/v1beta1/locked_by_id/{lock_id}"; - } - - // Returns synthetic lockups by native lockup id - rpc SyntheticLockupsByLockupID(SyntheticLockupsByLockupIDRequest) - returns (SyntheticLockupsByLockupIDResponse) { - option (google.api.http).get = - "/osmosis/lockup/v1beta1/synthetic_lockups_by_lock_id/{lock_id}"; - } - - // Returns account locked records with longer duration - rpc AccountLockedLongerDuration(AccountLockedLongerDurationRequest) - returns (AccountLockedLongerDurationResponse) { - option (google.api.http).get = - "/osmosis/lockup/v1beta1/account_locked_longer_duration/{owner}"; - } - - // Returns account locked records with a specific duration - rpc AccountLockedDuration(AccountLockedDurationRequest) - returns (AccountLockedDurationResponse) { - option (google.api.http).get = - "/osmosis/lockup/v1beta1/account_locked_duration/{owner}"; - } - - // Returns account locked records with longer duration excluding tokens - // started unlocking - rpc AccountLockedLongerDurationNotUnlockingOnly( - AccountLockedLongerDurationNotUnlockingOnlyRequest) - returns (AccountLockedLongerDurationNotUnlockingOnlyResponse) { - option (google.api.http).get = - "/osmosis/lockup/v1beta1/" - "account_locked_longer_duration_not_unlocking_only/{owner}"; - } - // Returns account's locked records for a denom with longer duration - rpc AccountLockedLongerDurationDenom(AccountLockedLongerDurationDenomRequest) - returns (AccountLockedLongerDurationDenomResponse) { - option (google.api.http).get = - "/osmosis/lockup/v1beta1/account_locked_longer_duration_denom/{owner}"; - } -} - -message ModuleBalanceRequest {}; -message ModuleBalanceResponse { - repeated cosmos.base.v1beta1.Coin coins = 1 [ - (gogoproto.nullable) = false, - (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" - ]; -}; - -message ModuleLockedAmountRequest {}; -message ModuleLockedAmountResponse { - repeated cosmos.base.v1beta1.Coin coins = 1 [ - (gogoproto.nullable) = false, - (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" - ]; -}; - -message AccountUnlockableCoinsRequest { - string owner = 1 [ (gogoproto.moretags) = "yaml:\"owner\"" ]; -}; -message AccountUnlockableCoinsResponse { - repeated cosmos.base.v1beta1.Coin coins = 1 [ - (gogoproto.nullable) = false, - (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" - ]; -}; - -message AccountUnlockingCoinsRequest { - string owner = 1 [ (gogoproto.moretags) = "yaml:\"owner\"" ]; -} -message AccountUnlockingCoinsResponse { - repeated cosmos.base.v1beta1.Coin coins = 1 [ - (gogoproto.nullable) = false, - (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" - ]; -} - -message AccountLockedCoinsRequest { - string owner = 1 [ (gogoproto.moretags) = "yaml:\"owner\"" ]; -}; -message AccountLockedCoinsResponse { - repeated cosmos.base.v1beta1.Coin coins = 1 [ - (gogoproto.nullable) = false, - (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" - ]; -}; - -message AccountLockedPastTimeRequest { - string owner = 1 [ (gogoproto.moretags) = "yaml:\"owner\"" ]; - google.protobuf.Timestamp timestamp = 2 [ - (gogoproto.stdtime) = true, - (gogoproto.nullable) = false, - (gogoproto.moretags) = "yaml:\"timestamp\"" - ]; -}; -message AccountLockedPastTimeResponse { - repeated PeriodLock locks = 1 [ (gogoproto.nullable) = false ]; -}; - -message AccountLockedPastTimeNotUnlockingOnlyRequest { - string owner = 1 [ (gogoproto.moretags) = "yaml:\"owner\"" ]; - google.protobuf.Timestamp timestamp = 2 [ - (gogoproto.stdtime) = true, - (gogoproto.nullable) = false, - (gogoproto.moretags) = "yaml:\"timestamp\"" - ]; -}; -message AccountLockedPastTimeNotUnlockingOnlyResponse { - repeated PeriodLock locks = 1 [ (gogoproto.nullable) = false ]; -}; - -message AccountUnlockedBeforeTimeRequest { - string owner = 1 [ (gogoproto.moretags) = "yaml:\"owner\"" ]; - google.protobuf.Timestamp timestamp = 2 [ - (gogoproto.stdtime) = true, - (gogoproto.nullable) = false, - (gogoproto.moretags) = "yaml:\"timestamp\"" - ]; -}; -message AccountUnlockedBeforeTimeResponse { - repeated PeriodLock locks = 1 [ (gogoproto.nullable) = false ]; -} - -message AccountLockedPastTimeDenomRequest { - string owner = 1 [ (gogoproto.moretags) = "yaml:\"owner\"" ]; - google.protobuf.Timestamp timestamp = 2 [ - (gogoproto.stdtime) = true, - (gogoproto.nullable) = false, - (gogoproto.moretags) = "yaml:\"timestamp\"" - ]; - string denom = 3; -}; -message AccountLockedPastTimeDenomResponse { - repeated PeriodLock locks = 1 [ (gogoproto.nullable) = false ]; -}; - -message LockedDenomRequest { - string denom = 1; - google.protobuf.Duration duration = 2 [ - (gogoproto.stdduration) = true, - (gogoproto.nullable) = false, - (gogoproto.moretags) = "yaml:\"duration\"" - ]; -} -message LockedDenomResponse { - string amount = 1 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.moretags) = "yaml:\"amount\"", - (gogoproto.nullable) = false - ]; -} - -message LockedRequest { uint64 lock_id = 1; }; -message LockedResponse { PeriodLock lock = 1; }; - -message SyntheticLockupsByLockupIDRequest { uint64 lock_id = 1; } -message SyntheticLockupsByLockupIDResponse { - repeated SyntheticLock synthetic_locks = 1 [ (gogoproto.nullable) = false ]; -} - -message AccountLockedLongerDurationRequest { - string owner = 1 [ (gogoproto.moretags) = "yaml:\"owner\"" ]; - google.protobuf.Duration duration = 2 [ - (gogoproto.stdduration) = true, - (gogoproto.nullable) = false, - (gogoproto.moretags) = "yaml:\"duration\"" - ]; -}; -message AccountLockedLongerDurationResponse { - repeated PeriodLock locks = 1 [ (gogoproto.nullable) = false ]; -}; - -message AccountLockedDurationRequest { - string owner = 1 [ (gogoproto.moretags) = "yaml:\"owner\"" ]; - google.protobuf.Duration duration = 2 [ - (gogoproto.stdduration) = true, - (gogoproto.nullable) = false, - (gogoproto.moretags) = "yaml:\"duration\"" - ]; -}; -message AccountLockedDurationResponse { - repeated PeriodLock locks = 1 [ (gogoproto.nullable) = false ]; -}; - -message AccountLockedLongerDurationNotUnlockingOnlyRequest { - string owner = 1 [ (gogoproto.moretags) = "yaml:\"owner\"" ]; - google.protobuf.Duration duration = 2 [ - (gogoproto.stdduration) = true, - (gogoproto.nullable) = false, - (gogoproto.moretags) = "yaml:\"duration\"" - ]; -}; -message AccountLockedLongerDurationNotUnlockingOnlyResponse { - repeated PeriodLock locks = 1 [ (gogoproto.nullable) = false ]; -}; - -message AccountLockedLongerDurationDenomRequest { - string owner = 1 [ (gogoproto.moretags) = "yaml:\"owner\"" ]; - google.protobuf.Duration duration = 2 [ - (gogoproto.stdduration) = true, - (gogoproto.nullable) = false, - (gogoproto.moretags) = "yaml:\"duration\"" - ]; - string denom = 3; -}; -message AccountLockedLongerDurationDenomResponse { - repeated PeriodLock locks = 1 [ (gogoproto.nullable) = false ]; -}; diff --git a/src/cosmospy_protobuf/osmosis/lockup/tx.proto b/src/cosmospy_protobuf/osmosis/lockup/tx.proto deleted file mode 100644 index 5746ed5e..00000000 --- a/src/cosmospy_protobuf/osmosis/lockup/tx.proto +++ /dev/null @@ -1,51 +0,0 @@ -syntax = "proto3"; -package osmosis.lockup; - -import "gogoproto/gogo.proto"; -import "google/protobuf/duration.proto"; -import "cosmos/base/v1beta1/coin.proto"; -import "osmosis/lockup/lock.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/lockup/types"; - -// Msg defines the Msg service. -service Msg { - // LockTokens lock tokens - rpc LockTokens(MsgLockTokens) returns (MsgLockTokensResponse); - // BeginUnlockingAll begin unlocking all tokens - rpc BeginUnlockingAll(MsgBeginUnlockingAll) - returns (MsgBeginUnlockingAllResponse); - // MsgBeginUnlocking begins unlocking tokens by lock ID - rpc BeginUnlocking(MsgBeginUnlocking) returns (MsgBeginUnlockingResponse); -} - -message MsgLockTokens { - string owner = 1 [ (gogoproto.moretags) = "yaml:\"owner\"" ]; - google.protobuf.Duration duration = 2 [ - (gogoproto.nullable) = false, - (gogoproto.stdduration) = true, - (gogoproto.jsontag) = "duration,omitempty", - (gogoproto.moretags) = "yaml:\"duration\"" - ]; - repeated cosmos.base.v1beta1.Coin coins = 3 [ - (gogoproto.nullable) = false, - (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" - ]; -} -message MsgLockTokensResponse { uint64 ID = 1; } - -message MsgBeginUnlockingAll { - string owner = 1 [ (gogoproto.moretags) = "yaml:\"owner\"" ]; -} -message MsgBeginUnlockingAllResponse { repeated PeriodLock unlocks = 1; } - -message MsgBeginUnlocking { - string owner = 1 [ (gogoproto.moretags) = "yaml:\"owner\"" ]; - uint64 ID = 2; - // Amount of unlocking coins. Unlock all if not set. - repeated cosmos.base.v1beta1.Coin coins = 3 [ - (gogoproto.nullable) = false, - (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" - ]; -} -message MsgBeginUnlockingResponse { bool success = 1; } diff --git a/src/cosmospy_protobuf/osmosis/mint/v1beta1/genesis.proto b/src/cosmospy_protobuf/osmosis/mint/v1beta1/genesis.proto deleted file mode 100644 index 3a9112b6..00000000 --- a/src/cosmospy_protobuf/osmosis/mint/v1beta1/genesis.proto +++ /dev/null @@ -1,20 +0,0 @@ -syntax = "proto3"; -package osmosis.mint.v1beta1; - -import "gogoproto/gogo.proto"; -import "osmosis/mint/v1beta1/mint.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/mint/types"; - -// GenesisState defines the mint module's genesis state. -message GenesisState { - // minter is a space for holding current rewards information. - Minter minter = 1 [ (gogoproto.nullable) = false ]; - - // params defines all the paramaters of the module. - Params params = 2 [ (gogoproto.nullable) = false ]; - - // current halven period start epoch - int64 halven_started_epoch = 3 - [ (gogoproto.moretags) = "yaml:\"halven_started_epoch\"" ]; -} diff --git a/src/cosmospy_protobuf/osmosis/mint/v1beta1/mint.proto b/src/cosmospy_protobuf/osmosis/mint/v1beta1/mint.proto deleted file mode 100644 index 95490b84..00000000 --- a/src/cosmospy_protobuf/osmosis/mint/v1beta1/mint.proto +++ /dev/null @@ -1,97 +0,0 @@ -syntax = "proto3"; -package osmosis.mint.v1beta1; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/mint/types"; - -import "gogoproto/gogo.proto"; -import "google/protobuf/timestamp.proto"; -import "google/protobuf/any.proto"; -import "google/protobuf/duration.proto"; - -// Minter represents the minting state. -message Minter { - // current epoch provisions - string epoch_provisions = 1 [ - (gogoproto.moretags) = "yaml:\"epoch_provisions\"", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false - ]; -} - -message WeightedAddress { - string address = 1 [ (gogoproto.moretags) = "yaml:\"address\"" ]; - string weight = 2 [ - (gogoproto.moretags) = "yaml:\"weight\"", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false - ]; -} - -message DistributionProportions { - // staking defines the proportion of the minted minted_denom that is to be - // allocated as staking rewards. - string staking = 1 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.moretags) = "yaml:\"staking\"", - (gogoproto.nullable) = false - ]; - // pool_incentives defines the proportion of the minted minted_denom that is - // to be allocated as pool incentives. - string pool_incentives = 2 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.moretags) = "yaml:\"pool_incentives\"", - (gogoproto.nullable) = false - ]; - // developer_rewards defines the proportion of the minted minted_denom that is - // to be allocated to developer rewards address. - string developer_rewards = 3 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.moretags) = "yaml:\"developer_rewards\"", - (gogoproto.nullable) = false - ]; - // community_pool defines the proportion of the minted minted_denom that is - // to be allocated to the community pool. - string community_pool = 4 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.moretags) = "yaml:\"community_pool\"", - (gogoproto.nullable) = false - ]; -} - -// Params holds parameters for the mint module. -message Params { - option (gogoproto.goproto_stringer) = false; - - // type of coin to mint - string mint_denom = 1; - // epoch provisions from the first epoch - string genesis_epoch_provisions = 2 [ - (gogoproto.moretags) = "yaml:\"genesis_epoch_provisions\"", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false - ]; - // mint epoch identifier - string epoch_identifier = 3 - [ (gogoproto.moretags) = "yaml:\"epoch_identifier\"" ]; - // number of epochs take to reduce rewards - int64 reduction_period_in_epochs = 4 - [ (gogoproto.moretags) = "yaml:\"reduction_period_in_epochs\"" ]; - // reduction multiplier to execute on each period - string reduction_factor = 5 [ - (gogoproto.moretags) = "yaml:\"reduction_factor\"", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false - ]; - // distribution_proportions defines the proportion of the minted denom - DistributionProportions distribution_proportions = 6 - [ (gogoproto.nullable) = false ]; - // address to receive developer rewards - repeated WeightedAddress weighted_developer_rewards_receivers = 7 [ - (gogoproto.moretags) = "yaml:\"developer_rewards_receiver\"", - (gogoproto.nullable) = false - ]; - // start epoch to distribute minting rewards - int64 minting_rewards_distribution_start_epoch = 8 - [ (gogoproto.moretags) = - "yaml:\"minting_rewards_distribution_start_epoch\"" ]; -} diff --git a/src/cosmospy_protobuf/osmosis/mint/v1beta1/query.proto b/src/cosmospy_protobuf/osmosis/mint/v1beta1/query.proto deleted file mode 100644 index 83c55a5e..00000000 --- a/src/cosmospy_protobuf/osmosis/mint/v1beta1/query.proto +++ /dev/null @@ -1,45 +0,0 @@ -syntax = "proto3"; -package osmosis.mint.v1beta1; - -import "gogoproto/gogo.proto"; -import "google/api/annotations.proto"; -import "osmosis/mint/v1beta1/mint.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/mint/types"; - -// Query provides defines the gRPC querier service. -service Query { - // Params returns the total set of minting parameters. - rpc Params(QueryParamsRequest) returns (QueryParamsResponse) { - option (google.api.http).get = "/osmosis/mint/v1beta1/params"; - } - - // EpochProvisions current minting epoch provisions value. - rpc EpochProvisions(QueryEpochProvisionsRequest) - returns (QueryEpochProvisionsResponse) { - option (google.api.http).get = "/osmosis/mint/v1beta1/epoch_provisions"; - } -} - -// 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 ]; -} - -// QueryEpochProvisionsRequest is the request type for the -// Query/EpochProvisions RPC method. -message QueryEpochProvisionsRequest {} - -// QueryEpochProvisionsResponse is the response type for the -// Query/EpochProvisions RPC method. -message QueryEpochProvisionsResponse { - // epoch_provisions is the current minting per epoch provisions value. - bytes epoch_provisions = 1 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false - ]; -} diff --git a/src/cosmospy_protobuf/osmosis/pool-incentives/v1beta1/genesis.proto b/src/cosmospy_protobuf/osmosis/pool-incentives/v1beta1/genesis.proto deleted file mode 100644 index 6b4f4ba2..00000000 --- a/src/cosmospy_protobuf/osmosis/pool-incentives/v1beta1/genesis.proto +++ /dev/null @@ -1,23 +0,0 @@ -syntax = "proto3"; -package osmosis.poolincentives.v1beta1; - -import "gogoproto/gogo.proto"; -import "google/protobuf/duration.proto"; -import "osmosis/pool-incentives/v1beta1/incentives.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/pool-incentives/types"; - -// GenesisState defines the pool incentives module's genesis state. -message GenesisState { - // params defines all the paramaters of the module. - Params params = 1 [ (gogoproto.nullable) = false ]; - repeated google.protobuf.Duration lockable_durations = 2 [ - (gogoproto.nullable) = false, - (gogoproto.stdduration) = true, - (gogoproto.moretags) = "yaml:\"lockable_durations\"" - ]; - DistrInfo distr_info = 3 [ - (gogoproto.nullable) = true, - (gogoproto.moretags) = "yaml:\"distr_info\"" - ]; -} diff --git a/src/cosmospy_protobuf/osmosis/pool-incentives/v1beta1/gov.proto b/src/cosmospy_protobuf/osmosis/pool-incentives/v1beta1/gov.proto deleted file mode 100644 index d7c9c4c7..00000000 --- a/src/cosmospy_protobuf/osmosis/pool-incentives/v1beta1/gov.proto +++ /dev/null @@ -1,49 +0,0 @@ -syntax = "proto3"; -package osmosis.poolincentives.v1beta1; - -import "gogoproto/gogo.proto"; -import "osmosis/pool-incentives/v1beta1/incentives.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/pool-incentives/types"; - -// ReplacePoolIncentivesProposal is a gov Content type for updating the pool -// incentives. If a ReplacePoolIncentivesProposal passes, the proposal’s records -// override the existing DistrRecords set in the module. Each record has a -// specified gauge id and weight, and the incentives are distributed to each -// gauge according to weight/total_weight. The incentives are put in the fee -// pool and it is allocated to gauges and community pool by the DistrRecords -// configuration. Note that gaugeId=0 represents the community pool. -message ReplacePoolIncentivesProposal { - option (gogoproto.equal) = true; - option (gogoproto.goproto_getters) = false; - option (gogoproto.goproto_stringer) = false; - - string title = 1; - string description = 2; - repeated DistrRecord records = 3 [ (gogoproto.nullable) = false ]; -} - -// UpdatePoolIncentivesProposal is a gov Content type for updating the pool -// incentives. If a UpdatePoolIncentivesProposal passes, all the DistrRecords -// in the proposals are edited. An existing DistrRecord is not overriden unless -// explicitly included in the proposal. -// This differs from an ReplacePoolIncentivesProposal because it only does an -// in place update of the DistrRecords for gauges explicitly mentioned in the -// proposal. - -// For example: if the existing DistrRecords were: -// [(Gauge 0, 5), (Gauge 1, 6), (Gauge 2, 6)] -// An UpdatePoolIncentivesProposal includes -// [(Gauge 1, 0), (Gauge 2, 4), (Gauge 3, 10)] -// This would delete Gauge 1, Edit Gauge 2, and Add Gauge 3 -// The result DistrRecords in state would be: -// [(Gauge 0, 5), (Gauge 2, 4), (Gauge 3, 10)] -message UpdatePoolIncentivesProposal { - option (gogoproto.equal) = true; - option (gogoproto.goproto_getters) = false; - option (gogoproto.goproto_stringer) = false; - - string title = 1; - string description = 2; - repeated DistrRecord records = 3 [ (gogoproto.nullable) = false ]; -} diff --git a/src/cosmospy_protobuf/osmosis/pool-incentives/v1beta1/incentives.proto b/src/cosmospy_protobuf/osmosis/pool-incentives/v1beta1/incentives.proto deleted file mode 100644 index cb4ab408..00000000 --- a/src/cosmospy_protobuf/osmosis/pool-incentives/v1beta1/incentives.proto +++ /dev/null @@ -1,44 +0,0 @@ -syntax = "proto3"; -package osmosis.poolincentives.v1beta1; - -import "gogoproto/gogo.proto"; -import "google/protobuf/duration.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/pool-incentives/types"; - -message Params { - option (gogoproto.goproto_stringer) = false; - - // minted_denom is the denomination of the coin expected to be minted by the - // minting module. Pool-incentives module doesn’t actually mint the coin - // itself, but rather manages the distribution of coins that matches the - // defined minted_denom. - string minted_denom = 1 [ (gogoproto.moretags) = "yaml:\"minted_denom\"" ]; -} - -message LockableDurationsInfo { - repeated google.protobuf.Duration lockable_durations = 1 [ - (gogoproto.nullable) = false, - (gogoproto.stdduration) = true, - (gogoproto.moretags) = "yaml:\"lockable_durations\"" - ]; -} - -message DistrInfo { - string total_weight = 1 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.moretags) = "yaml:\"total_weight\"", - (gogoproto.nullable) = false - ]; - repeated DistrRecord records = 2 [ (gogoproto.nullable) = false ]; -} - -message DistrRecord { - option (gogoproto.equal) = true; - - uint64 gauge_id = 1 [ (gogoproto.moretags) = "yaml:\"gauge_id\"" ]; - string weight = 2 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.nullable) = false - ]; -} diff --git a/src/cosmospy_protobuf/osmosis/pool-incentives/v1beta1/query.proto b/src/cosmospy_protobuf/osmosis/pool-incentives/v1beta1/query.proto deleted file mode 100644 index 0af0a636..00000000 --- a/src/cosmospy_protobuf/osmosis/pool-incentives/v1beta1/query.proto +++ /dev/null @@ -1,102 +0,0 @@ -syntax = "proto3"; -package osmosis.poolincentives.v1beta1; - -import "gogoproto/gogo.proto"; -import "google/api/annotations.proto"; -import "google/protobuf/duration.proto"; -import "osmosis/incentives/gauge.proto"; -import "osmosis/pool-incentives/v1beta1/incentives.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/pool-incentives/types"; - -service Query { - // GaugeIds takes the pool id and returns the matching gauge ids and durations - rpc GaugeIds(QueryGaugeIdsRequest) returns (QueryGaugeIdsResponse) { - option (google.api.http).get = - "/osmosis/pool-incentives/v1beta1/gauge-ids/{pool_id}"; - } - - rpc DistrInfo(QueryDistrInfoRequest) returns (QueryDistrInfoResponse) { - option (google.api.http).get = - "/osmosis/pool-incentives/v1beta1/distr_info"; - } - - rpc Params(QueryParamsRequest) returns (QueryParamsResponse) { - option (google.api.http).get = "/osmosis/pool-incentives/v1beta1/params"; - } - - rpc LockableDurations(QueryLockableDurationsRequest) - returns (QueryLockableDurationsResponse) { - option (google.api.http).get = - "/osmosis/pool-incentives/v1beta1/lockable_durations"; - } - - rpc IncentivizedPools(QueryIncentivizedPoolsRequest) - returns (QueryIncentivizedPoolsResponse) { - option (google.api.http).get = - "/osmosis/pool-incentives/v1beta1/incentivized_pools"; - } - rpc ExternalIncentiveGauges(QueryExternalIncentiveGaugesRequest) - returns (QueryExternalIncentiveGaugesResponse) { - option (google.api.http).get = - "/osmosis/pool-incentives/v1beta1/external_incentive_gauges"; - } -} - -message QueryGaugeIdsRequest { - uint64 pool_id = 1 [ (gogoproto.moretags) = "yaml:\"pool_id\"" ]; -} -message QueryGaugeIdsResponse { - message GaugeIdWithDuration { - uint64 gauge_id = 1 [ (gogoproto.moretags) = "yaml:\"gauge_id\"" ]; - google.protobuf.Duration duration = 2 - [ (gogoproto.nullable) = false, (gogoproto.stdduration) = true ]; - } - - repeated GaugeIdWithDuration gauge_ids_with_duration = 1 - [ (gogoproto.moretags) = "yaml:\"gauge_ids_with_duration\"" ]; -} - -message QueryDistrInfoRequest {} -message QueryDistrInfoResponse { - DistrInfo distr_info = 1 [ - (gogoproto.nullable) = false, - (gogoproto.moretags) = "yaml:\"distr_info\"" - ]; -} - -message QueryParamsRequest {} -message QueryParamsResponse { - Params params = 1 [ (gogoproto.nullable) = false ]; -} - -message QueryLockableDurationsRequest {} -message QueryLockableDurationsResponse { - repeated google.protobuf.Duration lockable_durations = 1 [ - (gogoproto.nullable) = false, - (gogoproto.stdduration) = true, - (gogoproto.moretags) = "yaml:\"lockable_durations\"" - ]; -} - -message QueryIncentivizedPoolsRequest {} -message IncentivizedPool { - uint64 pool_id = 1 [ (gogoproto.moretags) = "yaml:\"pool_id\"" ]; - google.protobuf.Duration lockable_duration = 2 [ - (gogoproto.nullable) = false, - (gogoproto.stdduration) = true, - (gogoproto.moretags) = "yaml:\"lockable_duration\"" - ]; - uint64 gauge_id = 3 [ (gogoproto.moretags) = "yaml:\"gauge_id\"" ]; -} -message QueryIncentivizedPoolsResponse { - repeated IncentivizedPool incentivized_pools = 1 [ - (gogoproto.nullable) = false, - (gogoproto.moretags) = "yaml:\"incentivized_pools\"" - ]; -} - -message QueryExternalIncentiveGaugesRequest {} -message QueryExternalIncentiveGaugesResponse { - repeated osmosis.incentives.Gauge data = 1 [ (gogoproto.nullable) = false ]; -} diff --git a/src/cosmospy_protobuf/osmosis/store/v1beta1/tree.proto b/src/cosmospy_protobuf/osmosis/store/v1beta1/tree.proto deleted file mode 100644 index 85ef7f25..00000000 --- a/src/cosmospy_protobuf/osmosis/store/v1beta1/tree.proto +++ /dev/null @@ -1,19 +0,0 @@ -syntax = "proto3"; -package osmosis.store.v1beta1; - -import "gogoproto/gogo.proto"; -import "cosmos/base/v1beta1/coin.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/store"; - -message Node { repeated Child children = 1; } - -message Child { - bytes index = 1; - string accumulation = 2 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.nullable) = false - ]; -} - -message Leaf { Child leaf = 1; } diff --git a/src/cosmospy_protobuf/osmosis/superfluid/genesis.proto b/src/cosmospy_protobuf/osmosis/superfluid/genesis.proto deleted file mode 100644 index e195858d..00000000 --- a/src/cosmospy_protobuf/osmosis/superfluid/genesis.proto +++ /dev/null @@ -1,21 +0,0 @@ -syntax = "proto3"; -package osmosis.superfluid; - -import "gogoproto/gogo.proto"; -import "osmosis/superfluid/superfluid.proto"; -import "osmosis/superfluid/params.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/superfluid/types"; - -// GenesisState defines the module's genesis state. -message GenesisState { - Params params = 1 [ (gogoproto.nullable) = false ]; - repeated SuperfluidAsset superfluid_assets = 2 - [ (gogoproto.nullable) = false ]; - repeated OsmoEquivalentMultiplierRecord osmo_equivalent_multipliers = 3 - [ (gogoproto.nullable) = false ]; - repeated SuperfluidIntermediaryAccount intermediary_accounts = 4 - [ (gogoproto.nullable) = false ]; - repeated LockIdIntermediaryAccountConnection intemediary_account_connections = - 5 [ (gogoproto.nullable) = false ]; -} diff --git a/src/cosmospy_protobuf/osmosis/superfluid/gov.proto b/src/cosmospy_protobuf/osmosis/superfluid/gov.proto deleted file mode 100644 index 2ad153d1..00000000 --- a/src/cosmospy_protobuf/osmosis/superfluid/gov.proto +++ /dev/null @@ -1,31 +0,0 @@ -syntax = "proto3"; -package osmosis.superfluid.v1beta1; - -import "gogoproto/gogo.proto"; -import "osmosis/superfluid/superfluid.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/superfluid/types"; - -// SetSuperfluidAssetsProposal is a gov Content type to update the superfluid -// assets -message SetSuperfluidAssetsProposal { - option (gogoproto.equal) = true; - option (gogoproto.goproto_getters) = false; - option (gogoproto.goproto_stringer) = false; - - string title = 1; - string description = 2; - repeated SuperfluidAsset assets = 3 [ (gogoproto.nullable) = false ]; -} - -// RemoveSuperfluidAssetsProposal is a gov Content type to remove the superfluid -// assets by denom -message RemoveSuperfluidAssetsProposal { - option (gogoproto.equal) = true; - option (gogoproto.goproto_getters) = false; - option (gogoproto.goproto_stringer) = false; - - string title = 1; - string description = 2; - repeated string superfluid_asset_denoms = 3; -} diff --git a/src/cosmospy_protobuf/osmosis/superfluid/params.proto b/src/cosmospy_protobuf/osmosis/superfluid/params.proto deleted file mode 100644 index 79e43a9c..00000000 --- a/src/cosmospy_protobuf/osmosis/superfluid/params.proto +++ /dev/null @@ -1,18 +0,0 @@ -syntax = "proto3"; -package osmosis.superfluid; - -import "gogoproto/gogo.proto"; -import "google/protobuf/duration.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/superfluid/types"; - -// Params holds parameters for the superfluid module -message Params { - // the risk_factor is to be cut on OSMO equivalent value of lp tokens for - // superfluid staking, default: 5% - string minimum_risk_factor = 1 [ - (gogoproto.moretags) = "yaml:\"minimum_risk_factor\"", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false - ]; -} diff --git a/src/cosmospy_protobuf/osmosis/superfluid/query.proto b/src/cosmospy_protobuf/osmosis/superfluid/query.proto deleted file mode 100644 index eb0e510a..00000000 --- a/src/cosmospy_protobuf/osmosis/superfluid/query.proto +++ /dev/null @@ -1,255 +0,0 @@ -syntax = "proto3"; -package osmosis.superfluid; - -import "gogoproto/gogo.proto"; -import "cosmos/base/v1beta1/coin.proto"; -import "google/api/annotations.proto"; -import "google/protobuf/timestamp.proto"; -import "google/protobuf/duration.proto"; -import "osmosis/superfluid/superfluid.proto"; -import "osmosis/superfluid/params.proto"; -import "osmosis/lockup/lock.proto"; -import "cosmos/base/query/v1beta1/pagination.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/superfluid/types"; - -// Query defines the gRPC querier service. -service Query { - // Params returns the total set of minting parameters. - rpc Params(QueryParamsRequest) returns (QueryParamsResponse) { - option (google.api.http).get = "/osmosis/superfluid/v1beta1/params"; - } - - // Returns superfluid asset type - rpc AssetType(AssetTypeRequest) returns (AssetTypeResponse) { - option (google.api.http).get = "/osmosis/superfluid/v1beta1/asset_type"; - } - // Returns all superfluid asset types - rpc AllAssets(AllAssetsRequest) returns (AllAssetsResponse) { - option (google.api.http).get = "/osmosis/superfluid/v1beta1/all_assets"; - } - // Returns superfluid asset Multiplier - rpc AssetMultiplier(AssetMultiplierRequest) - returns (AssetMultiplierResponse) { - option (google.api.http).get = - "/osmosis/superfluid/v1beta1/asset_multiplier"; - } - // Returns all superfluid intermediary account - rpc AllIntermediaryAccounts(AllIntermediaryAccountsRequest) - returns (AllIntermediaryAccountsResponse) { - option (google.api.http).get = - "/osmosis/superfluid/v1beta1/all_intermediary_accounts"; - } - // Returns intermediary account connected to a superfluid staked lock by id - rpc ConnectedIntermediaryAccount(ConnectedIntermediaryAccountRequest) - returns (ConnectedIntermediaryAccountResponse) { - option (google.api.http).get = - "/osmosis/superfluid/v1beta1/connected_intermediary_account/{lock_id}"; - } - - // Returns the total amount of osmo superfluidly staked - // response denominated in uosmo - rpc TotalSuperfluidDelegations(TotalSuperfluidDelegationsRequest) - returns (TotalSuperfluidDelegationsResponse) { - option (google.api.http).get = - "/osmosis/superfluid/v1beta1/all_superfluid_delegations"; - } - - // Returns the coins superfluid delegated for a delegator, validator, denom - // triplet - rpc SuperfluidDelegationAmount(SuperfluidDelegationAmountRequest) - returns (SuperfluidDelegationAmountResponse) { - option (google.api.http).get = - "/osmosis/superfluid/v1beta1/superfluid_delegation_amount"; - } - - // Returns all the superfluid poistions for a specific delegator - rpc SuperfluidDelegationsByDelegator(SuperfluidDelegationsByDelegatorRequest) - returns (SuperfluidDelegationsByDelegatorResponse) { - option (google.api.http).get = "/osmosis/superfluid/v1beta1/" - "superfluid_delegations/{delegator_address}"; - } - - rpc SuperfluidUndelegationsByDelegator( - SuperfluidUndelegationsByDelegatorRequest) - returns (SuperfluidUndelegationsByDelegatorResponse) { - option (google.api.http).get = - "/osmosis/superfluid/v1beta1/" - "superfluid_undelegations_by_delegator/{delegator_address}"; - } - - // Returns all the superfluid positions of a specific denom delegated to one - // validator - rpc SuperfluidDelegationsByValidatorDenom( - SuperfluidDelegationsByValidatorDenomRequest) - returns (SuperfluidDelegationsByValidatorDenomResponse) { - option (google.api.http).get = - "/osmosis/superfluid/v1beta1/superfluid_delegations_by_validator_denom"; - } - - // Returns the amount of a specific denom delegated to a specific validator - // This is labeled an estimate, because the way it calculates the amount can - // lead rounding errors from the true delegated amount - rpc EstimateSuperfluidDelegatedAmountByValidatorDenom( - EstimateSuperfluidDelegatedAmountByValidatorDenomRequest) - returns (EstimateSuperfluidDelegatedAmountByValidatorDenomResponse) { - option (google.api.http).get = - "/osmosis/superfluid/v1beta1/" - "estimate_superfluid_delegation_amount_by_validator_denom"; - } - - // // Returns all the unbonding superfluid positions of a delegator - // rpc SuperfluidUnbondingsByDelegator(SuperfluidUnbondingsByDelegatorRequest) - // returns (SuperfluidUnbondingsByDelegatorResponse) { - // option (google.api.http).get = - // "/osmosis/superfluid/v1beta1/superfluid_unbondings/{delegator_address}"; - // } - - // // Returns all the unbonding superfluid positions of a specific denom - // unbonding from one validator rpc - // SuperfluidUnbondingsByValidatorDenom(SuperfluidUnbondingsByValidatorDenomRequest) - // returns (SuperfluidUnbondingsByValidatorDenomResponse) { - // option (google.api.http).get = - // "/osmosis/superfluid/v1beta1/superfluid_unbondings_by_validator_denom"; - // } -} - -message QueryParamsRequest {} -message QueryParamsResponse { - // params defines the parameters of the module. - Params params = 1 [ (gogoproto.nullable) = false ]; -} - -message AssetTypeRequest { string denom = 1; }; -message AssetTypeResponse { SuperfluidAssetType asset_type = 1; }; - -message AllAssetsRequest {}; -message AllAssetsResponse { - repeated SuperfluidAsset assets = 1 [ (gogoproto.nullable) = false ]; -}; - -message AssetMultiplierRequest { string denom = 1; }; -message AssetMultiplierResponse { - OsmoEquivalentMultiplierRecord osmo_equivalent_multiplier = 1; -}; - -message SuperfluidIntermediaryAccountInfo { - string denom = 1; - string val_addr = 2; - uint64 gauge_id = 3; - string address = 4; -} -message AllIntermediaryAccountsRequest { - cosmos.base.query.v1beta1.PageRequest pagination = 1; -}; -message AllIntermediaryAccountsResponse { - repeated SuperfluidIntermediaryAccountInfo accounts = 1 - [ (gogoproto.nullable) = false ]; - cosmos.base.query.v1beta1.PageResponse pagination = 2; -}; - -message ConnectedIntermediaryAccountRequest { uint64 lock_id = 1; } -message ConnectedIntermediaryAccountResponse { - SuperfluidIntermediaryAccountInfo account = 1; -} - -message TotalSuperfluidDelegationsRequest {} - -message TotalSuperfluidDelegationsResponse { - string totalDelegations = 1 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", - (gogoproto.moretags) = "yaml:\"total_superfluid_delegations\"", - (gogoproto.nullable) = false - ]; -} - -message SuperfluidDelegationAmountRequest { - string delegator_address = 1; - string validator_address = 2; - string denom = 3; -} - -message SuperfluidDelegationAmountResponse { - repeated cosmos.base.v1beta1.Coin amount = 1 [ - (gogoproto.nullable) = false, - (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" - ]; -} - -message SuperfluidDelegationsByDelegatorRequest { - string delegator_address = 1; -} - -message SuperfluidDelegationsByDelegatorResponse { - repeated SuperfluidDelegationRecord superfluid_delegation_records = 1 - [ (gogoproto.nullable) = false ]; - repeated cosmos.base.v1beta1.Coin total_delegated_coins = 2 [ - (gogoproto.nullable) = false, - (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" - ]; -} - -message SuperfluidUndelegationsByDelegatorRequest { - string delegator_address = 1; - string denom = 2; -} - -message SuperfluidUndelegationsByDelegatorResponse { - repeated SuperfluidDelegationRecord superfluid_delegation_records = 1 - [ (gogoproto.nullable) = false ]; - repeated cosmos.base.v1beta1.Coin total_undelegated_coins = 2 [ - (gogoproto.nullable) = false, - (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" - ]; - repeated osmosis.lockup.SyntheticLock synthetic_locks = 3 - [ (gogoproto.nullable) = false ]; -} - -message SuperfluidDelegationsByValidatorDenomRequest { - string validator_address = 1; - string denom = 2; -} - -message SuperfluidDelegationsByValidatorDenomResponse { - repeated SuperfluidDelegationRecord superfluid_delegation_records = 1 - [ (gogoproto.nullable) = false ]; -} - -message EstimateSuperfluidDelegatedAmountByValidatorDenomRequest { - string validator_address = 1; - string denom = 2; -} - -message EstimateSuperfluidDelegatedAmountByValidatorDenomResponse { - repeated cosmos.base.v1beta1.Coin total_delegated_coins = 1 [ - (gogoproto.nullable) = false, - (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" - ]; -} - -// message SuperfluidUnbondingsByDelegatorRequest { -// string delegator_address = 1; -// } - -// message SuperfluidUnbondingsByDelegatorResponse { -// repeated SuperfluidDelegationRecord superfluid_unbonding_records = 1 -// [ (gogoproto.nullable) = false ]; -// repeated cosmos.base.v1beta1.Coin total_unbonding_coins = 2 [ -// (gogoproto.nullable) = false, -// (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" -// ]; -// } - -// message SuperfluidUnbondingsByValidatorDenomRequest { -// string validator_address = 1; -// string denom = 2; -// } - -// message SuperfluidUnbondingsByValidatorDenomResponse { -// repeated SuperfluidDelegationRecord superfluid_unbonding_records = 1 -// [ (gogoproto.nullable) = false ]; -// repeated cosmos.base.v1beta1.Coin total_unbonding_coins = 2 [ -// (gogoproto.nullable) = false, -// (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" -// ]; -// } \ No newline at end of file diff --git a/src/cosmospy_protobuf/osmosis/superfluid/superfluid.proto b/src/cosmospy_protobuf/osmosis/superfluid/superfluid.proto deleted file mode 100644 index 2c3e83e9..00000000 --- a/src/cosmospy_protobuf/osmosis/superfluid/superfluid.proto +++ /dev/null @@ -1,69 +0,0 @@ -syntax = "proto3"; -package osmosis.superfluid; - -import "gogoproto/gogo.proto"; -import "google/protobuf/duration.proto"; -import "google/protobuf/timestamp.proto"; -import "cosmos/base/v1beta1/coin.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/superfluid/types"; - -enum SuperfluidAssetType { - option (gogoproto.goproto_enum_prefix) = false; - - SuperfluidAssetTypeNative = 0; - SuperfluidAssetTypeLPShare = 1; - // SuperfluidAssetTypeLendingShare = 2; // for now not exist -} - -// SuperfluidAsset stores the pair of superfluid asset type and denom pair -message SuperfluidAsset { - option (gogoproto.equal) = true; - option (gogoproto.goproto_getters) = false; - - string denom = 1; - SuperfluidAssetType asset_type = 2; -} - -// SuperfluidIntermediaryAccount takes the role of intermediary between LP token -// and OSMO tokens for superfluid staking -message SuperfluidIntermediaryAccount { - string denom = 1; - string val_addr = 2; - // perpetual gauge for rewards distribution - uint64 gauge_id = 3; -} - -// The Osmo-Equivalent-Multiplier Record for epoch N refers to the osmo worth we -// treat an LP share as having, for all of epoch N. Eventually this is intended -// to be set as the Time-weighted-average-osmo-backing for the entire duration -// of epoch N-1. (Thereby locking whats in use for epoch N as based on the prior -// epochs rewards) However for now, this is not the TWAP but instead the spot -// price at the boundary. For different types of assets in the future, it could -// change. -message OsmoEquivalentMultiplierRecord { - int64 epoch_number = 1; - // superfluid asset denom, can be LP token or native token - string denom = 2; - string multiplier = 3 [ - (gogoproto.moretags) = "yaml:\"multiplier\"", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false - ]; -} - -// SuperfluidDelegationRecord takes the role of intermediary between LP token -// and OSMO tokens for superfluid staking -message SuperfluidDelegationRecord { - string delegator_address = 1; - string validator_address = 2; - cosmos.base.v1beta1.Coin delegation_amount = 3 [ - (gogoproto.nullable) = false, - (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coin" - ]; -} - -message LockIdIntermediaryAccountConnection { - uint64 lock_id = 1; - string intermediary_account = 2; -} diff --git a/src/cosmospy_protobuf/osmosis/superfluid/tx.proto b/src/cosmospy_protobuf/osmosis/superfluid/tx.proto deleted file mode 100644 index e54282eb..00000000 --- a/src/cosmospy_protobuf/osmosis/superfluid/tx.proto +++ /dev/null @@ -1,70 +0,0 @@ -syntax = "proto3"; -package osmosis.superfluid; - -import "gogoproto/gogo.proto"; -import "google/protobuf/duration.proto"; -import "cosmos/base/v1beta1/coin.proto"; -import "osmosis/superfluid/superfluid.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/superfluid/types"; - -// Msg defines the Msg service. -service Msg { - // Execute superfluid delegation for a lockup - rpc SuperfluidDelegate(MsgSuperfluidDelegate) - returns (MsgSuperfluidDelegateResponse); - // Execute superfluid undelegation for a lockup - rpc SuperfluidUndelegate(MsgSuperfluidUndelegate) - returns (MsgSuperfluidUndelegateResponse); - // Execute superfluid redelegation for a lockup - // rpc SuperfluidRedelegate(MsgSuperfluidRedelegate) returns - // (MsgSuperfluidRedelegateResponse); - - // For a given lock that is being superfluidly undelegated, - // also unbond the underlying lock. - rpc SuperfluidUnbondLock(MsgSuperfluidUnbondLock) - returns (MsgSuperfluidUnbondLockResponse); - - // Execute lockup lock and superfluid delegation in a single msg - rpc LockAndSuperfluidDelegate(MsgLockAndSuperfluidDelegate) - returns (MsgLockAndSuperfluidDelegateResponse); -} - -message MsgSuperfluidDelegate { - string sender = 1 [ (gogoproto.moretags) = "yaml:\"sender\"" ]; - uint64 lock_id = 2; - string val_addr = 3; -} -message MsgSuperfluidDelegateResponse {} - -message MsgSuperfluidUndelegate { - string sender = 1 [ (gogoproto.moretags) = "yaml:\"sender\"" ]; - uint64 lock_id = 2; -} -message MsgSuperfluidUndelegateResponse {} - -message MsgSuperfluidUnbondLock { - string sender = 1 [ (gogoproto.moretags) = "yaml:\"sender\"" ]; - uint64 lock_id = 2; -} -message MsgSuperfluidUnbondLockResponse {} - -// message MsgSuperfluidRedelegate { -// string sender = 1 [ (gogoproto.moretags) = "yaml:\"sender\"" ]; -// uint64 lock_id = 2; -// string new_val_addr = 3; -// } -// message MsgSuperfluidRedelegateResponse {} - -// MsgLockAndSuperfluidDelegate locks coins with the unbonding period duration, -// and then does a superfluid lock from the newly created lockup, to the -// specified validator addr. -message MsgLockAndSuperfluidDelegate { - string sender = 1 [ (gogoproto.moretags) = "yaml:\"sender\"" ]; - repeated cosmos.base.v1beta1.Coin coins = 2 [ - (gogoproto.nullable) = false, - (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins" - ]; - string val_addr = 3; -} -message MsgLockAndSuperfluidDelegateResponse { uint64 ID = 1; } \ No newline at end of file diff --git a/src/cosmospy_protobuf/osmosis/tokenfactory/v1beta1/authorityMetadata.proto b/src/cosmospy_protobuf/osmosis/tokenfactory/v1beta1/authorityMetadata.proto deleted file mode 100644 index cf4f3129..00000000 --- a/src/cosmospy_protobuf/osmosis/tokenfactory/v1beta1/authorityMetadata.proto +++ /dev/null @@ -1,17 +0,0 @@ -syntax = "proto3"; -package osmosis.tokenfactory.v1beta1; - -import "gogoproto/gogo.proto"; -import "cosmos/base/v1beta1/coin.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/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\"" ]; -} diff --git a/src/cosmospy_protobuf/osmosis/tokenfactory/v1beta1/genesis.proto b/src/cosmospy_protobuf/osmosis/tokenfactory/v1beta1/genesis.proto deleted file mode 100644 index a8709542..00000000 --- a/src/cosmospy_protobuf/osmosis/tokenfactory/v1beta1/genesis.proto +++ /dev/null @@ -1,27 +0,0 @@ -syntax = "proto3"; -package osmosis.tokenfactory.v1beta1; - -import "gogoproto/gogo.proto"; -import "osmosis/tokenfactory/v1beta1/authorityMetadata.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/tokenfactory/types"; - -// GenesisState defines the tokenfactory module's genesis state. -message GenesisState { - option (gogoproto.equal) = true; - - repeated GenesisDenom factory_denoms = 1 [ - (gogoproto.moretags) = "yaml:\"factory_denoms\"", - (gogoproto.nullable) = false - ]; -} - -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 - ]; -} \ No newline at end of file diff --git a/src/cosmospy_protobuf/osmosis/tokenfactory/v1beta1/query.proto b/src/cosmospy_protobuf/osmosis/tokenfactory/v1beta1/query.proto deleted file mode 100644 index 48ebf6c6..00000000 --- a/src/cosmospy_protobuf/osmosis/tokenfactory/v1beta1/query.proto +++ /dev/null @@ -1,41 +0,0 @@ -syntax = "proto3"; -package osmosis.tokenfactory.v1beta1; - -import "gogoproto/gogo.proto"; -import "google/api/annotations.proto"; -import "cosmos/base/query/v1beta1/pagination.proto"; -import "osmosis/tokenfactory/v1beta1/authorityMetadata.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/tokenfactory/types"; - -// Query defines the gRPC querier service. -service Query { - rpc DenomAuthorityMetadata(QueryDenomAuthorityMetadataRequest) - returns (QueryDenomAuthorityMetadataResponse) { - option (google.api.http).get = - "/osmosis/tokenfactory/v1beta1/denoms/{denom}/authority_metadata"; - } - - rpc DenomsFromCreator(QueryDenomsFromCreatorRequest) - returns (QueryDenomsFromCreatorResponse) { - option (google.api.http).get = - "/osmosis/tokenfactory/v1beta1/denoms_from_creator/{creator}"; - } -} - -message QueryDenomAuthorityMetadataRequest { - string denom = 1 [ (gogoproto.moretags) = "yaml:\"denom\"" ]; -} -message QueryDenomAuthorityMetadataResponse { - DenomAuthorityMetadata authority_metadata = 1 [ - (gogoproto.moretags) = "yaml:\"authority_metadata\"", - (gogoproto.nullable) = false - ]; -} - -message QueryDenomsFromCreatorRequest { - string creator = 1 [ (gogoproto.moretags) = "yaml:\"denoms\"" ]; -} -message QueryDenomsFromCreatorResponse { - repeated string denoms = 1 [ (gogoproto.moretags) = "yaml:\"denoms\"" ]; -} \ No newline at end of file diff --git a/src/cosmospy_protobuf/osmosis/tokenfactory/v1beta1/tx.proto b/src/cosmospy_protobuf/osmosis/tokenfactory/v1beta1/tx.proto deleted file mode 100644 index 27507d61..00000000 --- a/src/cosmospy_protobuf/osmosis/tokenfactory/v1beta1/tx.proto +++ /dev/null @@ -1,88 +0,0 @@ -syntax = "proto3"; -package osmosis.tokenfactory.v1beta1; - -import "gogoproto/gogo.proto"; -import "cosmos/base/v1beta1/coin.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/tokenfactory/types"; - -// Msg defines the Msg service. -service Msg { - rpc CreateDenom(MsgCreateDenom) returns (MsgCreateDenomResponse); - rpc Mint(MsgMint) returns (MsgMintResponse); - rpc Burn(MsgBurn) returns (MsgBurnResponse); - // ForceTransfer is deactivated for now because we need to think through edge - // cases rpc ForceTransfer(MsgForceTransfer) returns - // (MsgForceTransferResponse); - rpc ChangeAdmin(MsgChangeAdmin) returns (MsgChangeAdminResponse); -} - -// MsgCreateDenom is the sdk.Msg type for allowing an account to create -// a new denom. It requires a sender address and a unique nonce -// (to allow accounts to create multiple denoms) -message MsgCreateDenom { - string sender = 1 [ (gogoproto.moretags) = "yaml:\"sender\"" ]; - string nonce = 2 [ (gogoproto.moretags) = "yaml:\"nonce\"" ]; -} - -// 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 require sender == mintToAddress -// but this restriction will be removed in the future. -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 require sender == burnFromAddress -// but this restriction will be removed in the future. -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 {} - -// // ===================== MsgForceTransfer -// 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 {} - -// 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 newAdmin = 3 [ (gogoproto.moretags) = "yaml:\"new_admin\"" ]; -} - -message MsgChangeAdminResponse {} \ No newline at end of file diff --git a/src/cosmospy_protobuf/osmosis/txfees/v1beta1/feetoken.proto b/src/cosmospy_protobuf/osmosis/txfees/v1beta1/feetoken.proto deleted file mode 100644 index c7cd36e3..00000000 --- a/src/cosmospy_protobuf/osmosis/txfees/v1beta1/feetoken.proto +++ /dev/null @@ -1,17 +0,0 @@ -syntax = "proto3"; -package osmosis.txfees.v1beta1; - -import "gogoproto/gogo.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/txfees/types"; - -// FeeToken is a struct that specifies a coin denom, and pool ID pair. -// This marks the token as eligible for use as a tx fee asset in Osmosis. -// Its price in osmo is derived through looking at the provided pool ID. -// The pool ID must have osmo as one of its assets. -message FeeToken { - option (gogoproto.equal) = true; - - string denom = 1 [ (gogoproto.moretags) = "yaml:\"denom\"" ]; - uint64 poolID = 2 [ (gogoproto.moretags) = "yaml:\"pool_id\"" ]; -} \ No newline at end of file diff --git a/src/cosmospy_protobuf/osmosis/txfees/v1beta1/genesis.proto b/src/cosmospy_protobuf/osmosis/txfees/v1beta1/genesis.proto deleted file mode 100644 index 9b6fb48c..00000000 --- a/src/cosmospy_protobuf/osmosis/txfees/v1beta1/genesis.proto +++ /dev/null @@ -1,13 +0,0 @@ -syntax = "proto3"; -package osmosis.txfees.v1beta1; - -import "gogoproto/gogo.proto"; -import "osmosis/txfees/v1beta1/feetoken.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/txfees/types"; - -// GenesisState defines the txfees module's genesis state. -message GenesisState { - string basedenom = 1; - repeated FeeToken feetokens = 2 [ (gogoproto.nullable) = false ]; -} diff --git a/src/cosmospy_protobuf/osmosis/txfees/v1beta1/gov.proto b/src/cosmospy_protobuf/osmosis/txfees/v1beta1/gov.proto deleted file mode 100644 index 253e822d..00000000 --- a/src/cosmospy_protobuf/osmosis/txfees/v1beta1/gov.proto +++ /dev/null @@ -1,25 +0,0 @@ -syntax = "proto3"; -package osmosis.txfees.v1beta1; - -import "gogoproto/gogo.proto"; -import "osmosis/txfees/v1beta1/feetoken.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/txfees/types"; - -// UpdateFeeTokenProposal is a gov Content type for adding a new whitelisted fee -// token. It must specify a denom along with gamm pool ID to use as a spot price -// calculator. It can be used to add a new denom to the whitelist It can also be -// used to update the Pool to associate with the denom. If Pool ID is set to 0, -// it will remove the denom from the whitelisted set. -message UpdateFeeTokenProposal { - option (gogoproto.equal) = true; - option (gogoproto.goproto_getters) = false; - option (gogoproto.goproto_stringer) = false; - - string title = 1 [ (gogoproto.moretags) = "yaml:\"title\"" ]; - string description = 2 [ (gogoproto.moretags) = "yaml:\"description\"" ]; - FeeToken feetoken = 3 [ - (gogoproto.moretags) = "yaml:\"fee_token\"", - (gogoproto.nullable) = false - ]; -} \ No newline at end of file diff --git a/src/cosmospy_protobuf/osmosis/txfees/v1beta1/query.proto b/src/cosmospy_protobuf/osmosis/txfees/v1beta1/query.proto deleted file mode 100644 index abb36616..00000000 --- a/src/cosmospy_protobuf/osmosis/txfees/v1beta1/query.proto +++ /dev/null @@ -1,71 +0,0 @@ -syntax = "proto3"; -package osmosis.txfees.v1beta1; - -import "gogoproto/gogo.proto"; -import "google/api/annotations.proto"; -import "google/protobuf/duration.proto"; - -import "osmosis/txfees/v1beta1/feetoken.proto"; - -option go_package = "github.com/osmosis-labs/osmosis/v7/x/txfees/types"; - -service Query { - // FeeTokens returns a list of all the whitelisted fee tokens and their - // corresponding pools It does not include the BaseDenom, which has its own - // query endpoint - rpc FeeTokens(QueryFeeTokensRequest) returns (QueryFeeTokensResponse) { - option (google.api.http).get = "/osmosis/txfees/v1beta1/fee_tokens"; - } - - rpc DenomSpotPrice(QueryDenomSpotPriceRequest) - returns (QueryDenomSpotPriceResponse) { - option (google.api.http).get = - "/osmosis/txfees/v1beta1/spot_price_by_denom"; - } - - rpc DenomPoolId(QueryDenomPoolIdRequest) returns (QueryDenomPoolIdResponse) { - option (google.api.http).get = - "/osmosis/txfees/v1beta1/denom_pool_id/{denom}"; - } - - rpc BaseDenom(QueryBaseDenomRequest) returns (QueryBaseDenomResponse) { - option (google.api.http).get = "/osmosis/txfees/v1beta1/base_denom"; - } -} - -message QueryFeeTokensRequest {} -message QueryFeeTokensResponse { - repeated FeeToken fee_tokens = 1 [ - (gogoproto.moretags) = "yaml:\"fee_tokens\"", - (gogoproto.nullable) = false - ]; -} - -// QueryDenomSpotPriceRequest defines grpc request structure for querying spot -// price for the specified tx fee denom -message QueryDenomSpotPriceRequest { - string denom = 1 [ (gogoproto.moretags) = "yaml:\"denom\"" ]; -} - -// QueryDenomSpotPriceRequest defines grpc response structure for querying spot -// price for the specified tx fee denom -message QueryDenomSpotPriceResponse { - uint64 poolID = 1 [ (gogoproto.moretags) = "yaml:\"pool_id\"" ]; - string spot_price = 2 [ - (gogoproto.moretags) = "yaml:\"spot_price\"", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false - ]; -} - -message QueryDenomPoolIdRequest { - string denom = 1 [ (gogoproto.moretags) = "yaml:\"denom\"" ]; -} -message QueryDenomPoolIdResponse { - uint64 poolID = 1 [ (gogoproto.moretags) = "yaml:\"pool_id\"" ]; -} - -message QueryBaseDenomRequest {} -message QueryBaseDenomResponse { - string base_denom = 1 [ (gogoproto.moretags) = "yaml:\"base_denom\"" ]; -} diff --git a/src/cosmospy_protobuf/tendermint/abci/types.proto b/src/cosmospy_protobuf/tendermint/abci/types.proto deleted file mode 100644 index d41a5226..00000000 --- a/src/cosmospy_protobuf/tendermint/abci/types.proto +++ /dev/null @@ -1,394 +0,0 @@ -syntax = "proto3"; -package tendermint.abci; - -option go_package = "github.com/tendermint/tendermint/abci/types"; - -// For more information on gogo.proto, see: -// https://github.com/gogo/protobuf/blob/master/extensions.md -import "tendermint/crypto/proof.proto"; -import "tendermint/types/types.proto"; -import "tendermint/crypto/keys.proto"; -import "tendermint/types/params.proto"; -import "google/protobuf/timestamp.proto"; -import "gogoproto/gogo.proto"; - -// This file is copied from http://github.com/tendermint/abci -// NOTE: When using custom types, mind the warnings. -// https://github.com/gogo/protobuf/blob/master/custom_types.md#warnings-and-issues - -//---------------------------------------- -// Request types - -message Request { - oneof value { - RequestEcho echo = 1; - RequestFlush flush = 2; - RequestInfo info = 3; - RequestSetOption set_option = 4; - RequestInitChain init_chain = 5; - RequestQuery query = 6; - RequestBeginBlock begin_block = 7; - RequestCheckTx check_tx = 8; - RequestDeliverTx deliver_tx = 9; - RequestEndBlock end_block = 10; - RequestCommit commit = 11; - RequestListSnapshots list_snapshots = 12; - RequestOfferSnapshot offer_snapshot = 13; - RequestLoadSnapshotChunk load_snapshot_chunk = 14; - RequestApplySnapshotChunk apply_snapshot_chunk = 15; - } -} - -message RequestEcho { - string message = 1; -} - -message RequestFlush {} - -message RequestInfo { - string version = 1; - uint64 block_version = 2; - uint64 p2p_version = 3; -} - -// nondeterministic -message RequestSetOption { - string key = 1; - string value = 2; -} - -message RequestInitChain { - google.protobuf.Timestamp time = 1 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; - string chain_id = 2; - ConsensusParams consensus_params = 3; - repeated ValidatorUpdate validators = 4 [(gogoproto.nullable) = false]; - bytes app_state_bytes = 5; - int64 initial_height = 6; -} - -message RequestQuery { - bytes data = 1; - string path = 2; - int64 height = 3; - bool prove = 4; -} - -message RequestBeginBlock { - bytes hash = 1; - tendermint.types.Header header = 2 [(gogoproto.nullable) = false]; - LastCommitInfo last_commit_info = 3 [(gogoproto.nullable) = false]; - repeated Evidence byzantine_validators = 4 [(gogoproto.nullable) = false]; -} - -enum CheckTxType { - NEW = 0 [(gogoproto.enumvalue_customname) = "New"]; - RECHECK = 1 [(gogoproto.enumvalue_customname) = "Recheck"]; -} - -message RequestCheckTx { - bytes tx = 1; - CheckTxType type = 2; -} - -message RequestDeliverTx { - bytes tx = 1; -} - -message RequestEndBlock { - int64 height = 1; -} - -message RequestCommit {} - -// lists available snapshots -message RequestListSnapshots {} - -// offers a snapshot to the application -message RequestOfferSnapshot { - Snapshot snapshot = 1; // snapshot offered by peers - bytes app_hash = 2; // light client-verified app hash for snapshot height -} - -// loads a snapshot chunk -message RequestLoadSnapshotChunk { - uint64 height = 1; - uint32 format = 2; - uint32 chunk = 3; -} - -// Applies a snapshot chunk -message RequestApplySnapshotChunk { - uint32 index = 1; - bytes chunk = 2; - string sender = 3; -} - -//---------------------------------------- -// Response types - -message Response { - oneof value { - ResponseException exception = 1; - ResponseEcho echo = 2; - ResponseFlush flush = 3; - ResponseInfo info = 4; - ResponseSetOption set_option = 5; - ResponseInitChain init_chain = 6; - ResponseQuery query = 7; - ResponseBeginBlock begin_block = 8; - ResponseCheckTx check_tx = 9; - ResponseDeliverTx deliver_tx = 10; - ResponseEndBlock end_block = 11; - ResponseCommit commit = 12; - ResponseListSnapshots list_snapshots = 13; - ResponseOfferSnapshot offer_snapshot = 14; - ResponseLoadSnapshotChunk load_snapshot_chunk = 15; - ResponseApplySnapshotChunk apply_snapshot_chunk = 16; - } -} - -// nondeterministic -message ResponseException { - string error = 1; -} - -message ResponseEcho { - string message = 1; -} - -message ResponseFlush {} - -message ResponseInfo { - string data = 1; - - string version = 2; - uint64 app_version = 3; - - int64 last_block_height = 4; - bytes last_block_app_hash = 5; -} - -// nondeterministic -message ResponseSetOption { - uint32 code = 1; - // bytes data = 2; - string log = 3; - string info = 4; -} - -message ResponseInitChain { - ConsensusParams consensus_params = 1; - repeated ValidatorUpdate validators = 2 [(gogoproto.nullable) = false]; - bytes app_hash = 3; -} - -message ResponseQuery { - uint32 code = 1; - // bytes data = 2; // use "value" instead. - string log = 3; // nondeterministic - string info = 4; // nondeterministic - int64 index = 5; - bytes key = 6; - bytes value = 7; - tendermint.crypto.ProofOps proof_ops = 8; - int64 height = 9; - string codespace = 10; -} - -message ResponseBeginBlock { - repeated Event events = 1 [(gogoproto.nullable) = false, (gogoproto.jsontag) = "events,omitempty"]; -} - -message ResponseCheckTx { - uint32 code = 1; - bytes data = 2; - string log = 3; // nondeterministic - string info = 4; // nondeterministic - int64 gas_wanted = 5 [json_name = "gas_wanted"]; - int64 gas_used = 6 [json_name = "gas_used"]; - repeated Event events = 7 [(gogoproto.nullable) = false, (gogoproto.jsontag) = "events,omitempty"]; - string codespace = 8; -} - -message ResponseDeliverTx { - uint32 code = 1; - bytes data = 2; - string log = 3; // nondeterministic - string info = 4; // nondeterministic - int64 gas_wanted = 5 [json_name = "gas_wanted"]; - int64 gas_used = 6 [json_name = "gas_used"]; - repeated Event events = 7 [(gogoproto.nullable) = false, (gogoproto.jsontag) = "events,omitempty"]; - string codespace = 8; -} - -message ResponseEndBlock { - repeated ValidatorUpdate validator_updates = 1 [(gogoproto.nullable) = false]; - ConsensusParams consensus_param_updates = 2; - repeated Event events = 3 [(gogoproto.nullable) = false, (gogoproto.jsontag) = "events,omitempty"]; -} - -message ResponseCommit { - // reserve 1 - bytes data = 2; - int64 retain_height = 3; -} - -message ResponseListSnapshots { - repeated Snapshot snapshots = 1; -} - -message ResponseOfferSnapshot { - Result result = 1; - - enum Result { - UNKNOWN = 0; // Unknown result, abort all snapshot restoration - ACCEPT = 1; // Snapshot accepted, apply chunks - ABORT = 2; // Abort all snapshot restoration - REJECT = 3; // Reject this specific snapshot, try others - REJECT_FORMAT = 4; // Reject all snapshots of this format, try others - REJECT_SENDER = 5; // Reject all snapshots from the sender(s), try others - } -} - -message ResponseLoadSnapshotChunk { - bytes chunk = 1; -} - -message ResponseApplySnapshotChunk { - Result result = 1; - repeated uint32 refetch_chunks = 2; // Chunks to refetch and reapply - repeated string reject_senders = 3; // Chunk senders to reject and ban - - enum Result { - UNKNOWN = 0; // Unknown result, abort all snapshot restoration - ACCEPT = 1; // Chunk successfully accepted - ABORT = 2; // Abort all snapshot restoration - RETRY = 3; // Retry chunk (combine with refetch and reject) - RETRY_SNAPSHOT = 4; // Retry snapshot (combine with refetch and reject) - REJECT_SNAPSHOT = 5; // Reject this snapshot, try others - } -} - -//---------------------------------------- -// Misc. - -// ConsensusParams contains all consensus-relevant parameters -// that can be adjusted by the abci app -message ConsensusParams { - BlockParams block = 1; - tendermint.types.EvidenceParams evidence = 2; - tendermint.types.ValidatorParams validator = 3; - tendermint.types.VersionParams version = 4; -} - -// BlockParams contains limits on the block size. -message BlockParams { - // Note: must be greater than 0 - int64 max_bytes = 1; - // Note: must be greater or equal to -1 - int64 max_gas = 2; -} - -message LastCommitInfo { - int32 round = 1; - repeated VoteInfo votes = 2 [(gogoproto.nullable) = false]; -} - -// Event allows application developers to attach additional information to -// ResponseBeginBlock, ResponseEndBlock, ResponseCheckTx and ResponseDeliverTx. -// Later, transactions may be queried using these events. -message Event { - string type = 1; - repeated EventAttribute attributes = 2 [(gogoproto.nullable) = false, (gogoproto.jsontag) = "attributes,omitempty"]; -} - -// EventAttribute is a single key-value pair, associated with an event. -message EventAttribute { - bytes key = 1; - bytes value = 2; - bool index = 3; // nondeterministic -} - -// TxResult contains results of executing the transaction. -// -// One usage is indexing transaction results. -message TxResult { - int64 height = 1; - uint32 index = 2; - bytes tx = 3; - ResponseDeliverTx result = 4 [(gogoproto.nullable) = false]; -} - -//---------------------------------------- -// Blockchain Types - -// Validator -message Validator { - bytes address = 1; // The first 20 bytes of SHA256(public key) - // PubKey pub_key = 2 [(gogoproto.nullable)=false]; - int64 power = 3; // The voting power -} - -// ValidatorUpdate -message ValidatorUpdate { - tendermint.crypto.PublicKey pub_key = 1 [(gogoproto.nullable) = false]; - int64 power = 2; -} - -// VoteInfo -message VoteInfo { - Validator validator = 1 [(gogoproto.nullable) = false]; - bool signed_last_block = 2; -} - -enum EvidenceType { - UNKNOWN = 0; - DUPLICATE_VOTE = 1; - LIGHT_CLIENT_ATTACK = 2; -} - -message Evidence { - EvidenceType type = 1; - // The offending validator - Validator validator = 2 [(gogoproto.nullable) = false]; - // The height when the offense occurred - int64 height = 3; - // The corresponding time where the offense occurred - google.protobuf.Timestamp time = 4 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; - // Total voting power of the validator set in case the ABCI application does - // not store historical validators. - // https://github.com/tendermint/tendermint/issues/4581 - int64 total_voting_power = 5; -} - -//---------------------------------------- -// State Sync Types - -message Snapshot { - uint64 height = 1; // The height at which the snapshot was taken - uint32 format = 2; // The application-specific snapshot format - uint32 chunks = 3; // Number of chunks in the snapshot - bytes hash = 4; // Arbitrary snapshot hash, equal only if identical - bytes metadata = 5; // Arbitrary application metadata -} - -//---------------------------------------- -// Service Definition - -service ABCIApplication { - rpc Echo(RequestEcho) returns (ResponseEcho); - rpc Flush(RequestFlush) returns (ResponseFlush); - rpc Info(RequestInfo) returns (ResponseInfo); - rpc SetOption(RequestSetOption) returns (ResponseSetOption); - rpc DeliverTx(RequestDeliverTx) returns (ResponseDeliverTx); - rpc CheckTx(RequestCheckTx) returns (ResponseCheckTx); - rpc Query(RequestQuery) returns (ResponseQuery); - rpc Commit(RequestCommit) returns (ResponseCommit); - rpc InitChain(RequestInitChain) returns (ResponseInitChain); - rpc BeginBlock(RequestBeginBlock) returns (ResponseBeginBlock); - rpc EndBlock(RequestEndBlock) returns (ResponseEndBlock); - rpc ListSnapshots(RequestListSnapshots) returns (ResponseListSnapshots); - rpc OfferSnapshot(RequestOfferSnapshot) returns (ResponseOfferSnapshot); - rpc LoadSnapshotChunk(RequestLoadSnapshotChunk) returns (ResponseLoadSnapshotChunk); - rpc ApplySnapshotChunk(RequestApplySnapshotChunk) returns (ResponseApplySnapshotChunk); -} diff --git a/src/cosmospy_protobuf/tendermint/crypto/keys.proto b/src/cosmospy_protobuf/tendermint/crypto/keys.proto deleted file mode 100644 index 16fd7adf..00000000 --- a/src/cosmospy_protobuf/tendermint/crypto/keys.proto +++ /dev/null @@ -1,17 +0,0 @@ -syntax = "proto3"; -package tendermint.crypto; - -option go_package = "github.com/tendermint/tendermint/proto/tendermint/crypto"; - -import "gogoproto/gogo.proto"; - -// PublicKey defines the keys available for use with Tendermint Validators -message PublicKey { - option (gogoproto.compare) = true; - option (gogoproto.equal) = true; - - oneof sum { - bytes ed25519 = 1; - bytes secp256k1 = 2; - } -} diff --git a/src/cosmospy_protobuf/tendermint/crypto/proof.proto b/src/cosmospy_protobuf/tendermint/crypto/proof.proto deleted file mode 100644 index 975df768..00000000 --- a/src/cosmospy_protobuf/tendermint/crypto/proof.proto +++ /dev/null @@ -1,41 +0,0 @@ -syntax = "proto3"; -package tendermint.crypto; - -option go_package = "github.com/tendermint/tendermint/proto/tendermint/crypto"; - -import "gogoproto/gogo.proto"; - -message Proof { - int64 total = 1; - int64 index = 2; - bytes leaf_hash = 3; - repeated bytes aunts = 4; -} - -message ValueOp { - // Encoded in ProofOp.Key. - bytes key = 1; - - // To encode in ProofOp.Data - Proof proof = 2; -} - -message DominoOp { - string key = 1; - string input = 2; - string output = 3; -} - -// ProofOp defines an operation used for calculating Merkle root -// The data could be arbitrary format, providing nessecary data -// for example neighbouring node hash -message ProofOp { - string type = 1; - bytes key = 2; - bytes data = 3; -} - -// ProofOps is Merkle proof defined by the list of ProofOps -message ProofOps { - repeated ProofOp ops = 1 [(gogoproto.nullable) = false]; -} diff --git a/src/cosmospy_protobuf/tendermint/libs/bits/types.proto b/src/cosmospy_protobuf/tendermint/libs/bits/types.proto deleted file mode 100644 index 3111d113..00000000 --- a/src/cosmospy_protobuf/tendermint/libs/bits/types.proto +++ /dev/null @@ -1,9 +0,0 @@ -syntax = "proto3"; -package tendermint.libs.bits; - -option go_package = "github.com/tendermint/tendermint/proto/tendermint/libs/bits"; - -message BitArray { - int64 bits = 1; - repeated uint64 elems = 2; -} diff --git a/src/cosmospy_protobuf/tendermint/p2p/types.proto b/src/cosmospy_protobuf/tendermint/p2p/types.proto deleted file mode 100644 index 216a6d8d..00000000 --- a/src/cosmospy_protobuf/tendermint/p2p/types.proto +++ /dev/null @@ -1,42 +0,0 @@ -syntax = "proto3"; -package tendermint.p2p; - -option go_package = "github.com/tendermint/tendermint/proto/tendermint/p2p"; - -import "gogoproto/gogo.proto"; -import "google/protobuf/timestamp.proto"; - -message ProtocolVersion { - uint64 p2p = 1 [(gogoproto.customname) = "P2P"]; - uint64 block = 2; - uint64 app = 3; -} - -message NodeInfo { - ProtocolVersion protocol_version = 1 [(gogoproto.nullable) = false]; - string node_id = 2 [(gogoproto.customname) = "NodeID"]; - string listen_addr = 3; - string network = 4; - string version = 5; - bytes channels = 6; - string moniker = 7; - NodeInfoOther other = 8 [(gogoproto.nullable) = false]; -} - -message NodeInfoOther { - string tx_index = 1; - string rpc_address = 2 [(gogoproto.customname) = "RPCAddress"]; -} - -message PeerInfo { - string id = 1 [(gogoproto.customname) = "ID"]; - repeated PeerAddressInfo address_info = 2; - google.protobuf.Timestamp last_connected = 3 [(gogoproto.stdtime) = true]; -} - -message PeerAddressInfo { - string address = 1; - google.protobuf.Timestamp last_dial_success = 2 [(gogoproto.stdtime) = true]; - google.protobuf.Timestamp last_dial_failure = 3 [(gogoproto.stdtime) = true]; - uint32 dial_failures = 4; -} diff --git a/src/cosmospy_protobuf/tendermint/types/block.proto b/src/cosmospy_protobuf/tendermint/types/block.proto deleted file mode 100644 index 84e9bb15..00000000 --- a/src/cosmospy_protobuf/tendermint/types/block.proto +++ /dev/null @@ -1,15 +0,0 @@ -syntax = "proto3"; -package tendermint.types; - -option go_package = "github.com/tendermint/tendermint/proto/tendermint/types"; - -import "gogoproto/gogo.proto"; -import "tendermint/types/types.proto"; -import "tendermint/types/evidence.proto"; - -message Block { - Header header = 1 [(gogoproto.nullable) = false]; - Data data = 2 [(gogoproto.nullable) = false]; - tendermint.types.EvidenceList evidence = 3 [(gogoproto.nullable) = false]; - Commit last_commit = 4; -} diff --git a/src/cosmospy_protobuf/tendermint/types/evidence.proto b/src/cosmospy_protobuf/tendermint/types/evidence.proto deleted file mode 100644 index d9548a43..00000000 --- a/src/cosmospy_protobuf/tendermint/types/evidence.proto +++ /dev/null @@ -1,38 +0,0 @@ -syntax = "proto3"; -package tendermint.types; - -option go_package = "github.com/tendermint/tendermint/proto/tendermint/types"; - -import "gogoproto/gogo.proto"; -import "google/protobuf/timestamp.proto"; -import "tendermint/types/types.proto"; -import "tendermint/types/validator.proto"; - -message Evidence { - oneof sum { - DuplicateVoteEvidence duplicate_vote_evidence = 1; - LightClientAttackEvidence light_client_attack_evidence = 2; - } -} - -// DuplicateVoteEvidence contains evidence of a validator signed two conflicting votes. -message DuplicateVoteEvidence { - tendermint.types.Vote vote_a = 1; - tendermint.types.Vote vote_b = 2; - int64 total_voting_power = 3; - int64 validator_power = 4; - google.protobuf.Timestamp timestamp = 5 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; -} - -// LightClientAttackEvidence contains evidence of a set of validators attempting to mislead a light client. -message LightClientAttackEvidence { - tendermint.types.LightBlock conflicting_block = 1; - int64 common_height = 2; - repeated tendermint.types.Validator byzantine_validators = 3; - int64 total_voting_power = 4; - google.protobuf.Timestamp timestamp = 5 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; -} - -message EvidenceList { - repeated Evidence evidence = 1 [(gogoproto.nullable) = false]; -} diff --git a/src/cosmospy_protobuf/tendermint/types/params.proto b/src/cosmospy_protobuf/tendermint/types/params.proto deleted file mode 100644 index 70789222..00000000 --- a/src/cosmospy_protobuf/tendermint/types/params.proto +++ /dev/null @@ -1,79 +0,0 @@ -syntax = "proto3"; -package tendermint.types; - -option go_package = "github.com/tendermint/tendermint/proto/tendermint/types"; - -import "gogoproto/gogo.proto"; -import "google/protobuf/duration.proto"; - -option (gogoproto.equal_all) = true; - -// ConsensusParams contains consensus critical parameters that determine the -// validity of blocks. -message ConsensusParams { - BlockParams block = 1 [(gogoproto.nullable) = false]; - EvidenceParams evidence = 2 [(gogoproto.nullable) = false]; - ValidatorParams validator = 3 [(gogoproto.nullable) = false]; - VersionParams version = 4 [(gogoproto.nullable) = false]; -} - -// BlockParams contains limits on the block size. -message BlockParams { - // Max block size, in bytes. - // Note: must be greater than 0 - int64 max_bytes = 1; - // Max gas per block. - // Note: must be greater or equal to -1 - int64 max_gas = 2; - // Minimum time increment between consecutive blocks (in milliseconds) If the - // block header timestamp is ahead of the system clock, decrease this value. - // - // Not exposed to the application. - int64 time_iota_ms = 3; -} - -// EvidenceParams determine how we handle evidence of malfeasance. -message EvidenceParams { - // Max age of evidence, in blocks. - // - // The basic formula for calculating this is: MaxAgeDuration / {average block - // time}. - int64 max_age_num_blocks = 1; - - // 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). - google.protobuf.Duration max_age_duration = 2 [(gogoproto.nullable) = false, (gogoproto.stdduration) = true]; - - // 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 - int64 max_bytes = 3; -} - -// ValidatorParams restrict the public key types validators can use. -// NOTE: uses ABCI pubkey naming, not Amino names. -message ValidatorParams { - option (gogoproto.populate) = true; - option (gogoproto.equal) = true; - - repeated string pub_key_types = 1; -} - -// VersionParams contains the ABCI application version. -message VersionParams { - option (gogoproto.populate) = true; - option (gogoproto.equal) = true; - - uint64 app_version = 1; -} - -// HashedParams is a subset of ConsensusParams. -// -// It is hashed into the Header.ConsensusHash. -message HashedParams { - int64 block_max_bytes = 1; - int64 block_max_gas = 2; -} diff --git a/src/cosmospy_protobuf/tendermint/types/types.proto b/src/cosmospy_protobuf/tendermint/types/types.proto deleted file mode 100644 index 57efc33c..00000000 --- a/src/cosmospy_protobuf/tendermint/types/types.proto +++ /dev/null @@ -1,153 +0,0 @@ -syntax = "proto3"; -package tendermint.types; - -option go_package = "github.com/tendermint/tendermint/proto/tendermint/types"; - -import "gogoproto/gogo.proto"; -import "google/protobuf/timestamp.proto"; -import "tendermint/crypto/proof.proto"; -import "tendermint/version/types.proto"; -import "tendermint/types/validator.proto"; - -// BlockIdFlag indicates which BlcokID the signature is for -enum BlockIDFlag { - option (gogoproto.goproto_enum_stringer) = true; - option (gogoproto.goproto_enum_prefix) = false; - - BLOCK_ID_FLAG_UNKNOWN = 0 [(gogoproto.enumvalue_customname) = "BlockIDFlagUnknown"]; - BLOCK_ID_FLAG_ABSENT = 1 [(gogoproto.enumvalue_customname) = "BlockIDFlagAbsent"]; - BLOCK_ID_FLAG_COMMIT = 2 [(gogoproto.enumvalue_customname) = "BlockIDFlagCommit"]; - BLOCK_ID_FLAG_NIL = 3 [(gogoproto.enumvalue_customname) = "BlockIDFlagNil"]; -} - -// SignedMsgType is a type of signed message in the consensus. -enum SignedMsgType { - option (gogoproto.goproto_enum_stringer) = true; - option (gogoproto.goproto_enum_prefix) = false; - - SIGNED_MSG_TYPE_UNKNOWN = 0 [(gogoproto.enumvalue_customname) = "UnknownType"]; - // Votes - SIGNED_MSG_TYPE_PREVOTE = 1 [(gogoproto.enumvalue_customname) = "PrevoteType"]; - SIGNED_MSG_TYPE_PRECOMMIT = 2 [(gogoproto.enumvalue_customname) = "PrecommitType"]; - - // Proposals - SIGNED_MSG_TYPE_PROPOSAL = 32 [(gogoproto.enumvalue_customname) = "ProposalType"]; -} - -// PartsetHeader -message PartSetHeader { - uint32 total = 1; - bytes hash = 2; -} - -message Part { - uint32 index = 1; - bytes bytes = 2; - tendermint.crypto.Proof proof = 3 [(gogoproto.nullable) = false]; -} - -// BlockID -message BlockID { - bytes hash = 1; - PartSetHeader part_set_header = 2 [(gogoproto.nullable) = false]; -} - -// -------------------------------- - -// Header defines the structure of a Tendermint block header. -message Header { - // basic block info - tendermint.version.Consensus version = 1 [(gogoproto.nullable) = false]; - string chain_id = 2 [(gogoproto.customname) = "ChainID"]; - int64 height = 3; - google.protobuf.Timestamp time = 4 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; - - // prev block info - BlockID last_block_id = 5 [(gogoproto.nullable) = false]; - - // hashes of block data - bytes last_commit_hash = 6; // commit from validators from the last block - bytes data_hash = 7; // transactions - - // hashes from the app output from the prev block - bytes validators_hash = 8; // validators for the current block - bytes next_validators_hash = 9; // validators for the next block - bytes consensus_hash = 10; // consensus params for current block - bytes app_hash = 11; // state after txs from the previous block - bytes last_results_hash = 12; // root hash of all results from the txs from the previous block - - // consensus info - bytes evidence_hash = 13; // evidence included in the block - bytes proposer_address = 14; // original proposer of the block -} - -// Data contains the set of transactions included in the block -message Data { - // 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. - repeated bytes txs = 1; -} - -// Vote represents a prevote, precommit, or commit vote from validators for -// consensus. -message Vote { - SignedMsgType type = 1; - int64 height = 2; - int32 round = 3; - BlockID block_id = 4 [(gogoproto.nullable) = false, (gogoproto.customname) = "BlockID"]; // zero if vote is nil. - google.protobuf.Timestamp timestamp = 5 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; - bytes validator_address = 6; - int32 validator_index = 7; - bytes signature = 8; -} - -// Commit contains the evidence that a block was committed by a set of validators. -message Commit { - int64 height = 1; - int32 round = 2; - BlockID block_id = 3 [(gogoproto.nullable) = false, (gogoproto.customname) = "BlockID"]; - repeated CommitSig signatures = 4 [(gogoproto.nullable) = false]; -} - -// CommitSig is a part of the Vote included in a Commit. -message CommitSig { - BlockIDFlag block_id_flag = 1; - bytes validator_address = 2; - google.protobuf.Timestamp timestamp = 3 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; - bytes signature = 4; -} - -message Proposal { - SignedMsgType type = 1; - int64 height = 2; - int32 round = 3; - int32 pol_round = 4; - BlockID block_id = 5 [(gogoproto.customname) = "BlockID", (gogoproto.nullable) = false]; - google.protobuf.Timestamp timestamp = 6 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; - bytes signature = 7; -} - -message SignedHeader { - Header header = 1; - Commit commit = 2; -} - -message LightBlock { - SignedHeader signed_header = 1; - tendermint.types.ValidatorSet validator_set = 2; -} - -message BlockMeta { - BlockID block_id = 1 [(gogoproto.customname) = "BlockID", (gogoproto.nullable) = false]; - int64 block_size = 2; - Header header = 3 [(gogoproto.nullable) = false]; - int64 num_txs = 4; -} - -// TxProof represents a Merkle proof of the presence of a transaction in the Merkle tree. -message TxProof { - bytes root_hash = 1; - bytes data = 2; - tendermint.crypto.Proof proof = 3; -} diff --git a/src/cosmospy_protobuf/tendermint/types/validator.proto b/src/cosmospy_protobuf/tendermint/types/validator.proto deleted file mode 100644 index 49860b96..00000000 --- a/src/cosmospy_protobuf/tendermint/types/validator.proto +++ /dev/null @@ -1,25 +0,0 @@ -syntax = "proto3"; -package tendermint.types; - -option go_package = "github.com/tendermint/tendermint/proto/tendermint/types"; - -import "gogoproto/gogo.proto"; -import "tendermint/crypto/keys.proto"; - -message ValidatorSet { - repeated Validator validators = 1; - Validator proposer = 2; - int64 total_voting_power = 3; -} - -message Validator { - bytes address = 1; - tendermint.crypto.PublicKey pub_key = 2 [(gogoproto.nullable) = false]; - int64 voting_power = 3; - int64 proposer_priority = 4; -} - -message SimpleValidator { - tendermint.crypto.PublicKey pub_key = 1; - int64 voting_power = 2; -} diff --git a/src/cosmospy_protobuf/tendermint/version/types.proto b/src/cosmospy_protobuf/tendermint/version/types.proto deleted file mode 100644 index 6061868b..00000000 --- a/src/cosmospy_protobuf/tendermint/version/types.proto +++ /dev/null @@ -1,24 +0,0 @@ -syntax = "proto3"; -package tendermint.version; - -option go_package = "github.com/tendermint/tendermint/proto/tendermint/version"; - -import "gogoproto/gogo.proto"; - -// App includes the protocol and software version for the application. -// This information is included in ResponseInfo. The App.Protocol can be -// updated in ResponseEndBlock. -message App { - uint64 protocol = 1; - string software = 2; -} - -// 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. -message Consensus { - option (gogoproto.equal) = true; - - uint64 block = 1; - uint64 app = 2; -} diff --git a/src/cosmospy_protobuf/umee/leverage/v1beta1/genesis.proto b/src/cosmospy_protobuf/umee/leverage/v1beta1/genesis.proto deleted file mode 100644 index dd1c60dd..00000000 --- a/src/cosmospy_protobuf/umee/leverage/v1beta1/genesis.proto +++ /dev/null @@ -1,54 +0,0 @@ -syntax = "proto3"; -package umeenetwork.umee.leverage.v1beta1; - -import "gogoproto/gogo.proto"; -import "cosmos/base/v1beta1/coin.proto"; -import "umee/leverage/v1beta1/leverage.proto"; - -option go_package = "github.com/umee-network/umee/v2/x/leverage/types"; - -// GenesisState defines the x/leverage module's genesis state. -message GenesisState { - Params params = 1 [(gogoproto.nullable) = false]; - repeated Token registry = 2 [(gogoproto.nullable) = false]; - repeated AdjustedBorrow adjusted_borrows = 3 [(gogoproto.nullable) = false]; - repeated CollateralSetting collateral_settings = 4 [(gogoproto.nullable) = false]; - repeated Collateral collateral = 5 [(gogoproto.nullable) = false]; - repeated cosmos.base.v1beta1.Coin reserves = 6 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; - int64 last_interest_time = 7; - repeated BadDebt bad_debts = 8 [(gogoproto.nullable) = false]; - repeated InterestScalar interest_scalars = 9 [(gogoproto.nullable) = false]; - repeated cosmos.base.v1beta1.Coin utoken_supply = 10 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; -} - -// AdjustedBorrow is a borrow struct used in the leverage module's genesis state. -message AdjustedBorrow { - string address = 1; - cosmos.base.v1beta1.DecCoin amount = 2 [(gogoproto.nullable) = false]; -} - -// CollateralSetting is a collateral setting struct used in the leverage module's genesis state. -message CollateralSetting { - string address = 1; - string denom = 2; -} - -// Collateral is a collateral struct used in the leverage module's genesis state. -message Collateral { - string address = 1; - cosmos.base.v1beta1.Coin amount = 2 [(gogoproto.nullable) = false]; -} - -// BadDebt is a bad debt instance used in the leverage module's genesis state. -message BadDebt { - string address = 1; - string denom = 2; -} - -// InterestScalar is an interest scalar used in the leverage module's genesis state. -message InterestScalar { - string denom = 1; - string scalar = 2 [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", (gogoproto.nullable) = false]; -} \ No newline at end of file diff --git a/src/cosmospy_protobuf/umee/leverage/v1beta1/gov.proto b/src/cosmospy_protobuf/umee/leverage/v1beta1/gov.proto deleted file mode 100644 index 2462ff95..00000000 --- a/src/cosmospy_protobuf/umee/leverage/v1beta1/gov.proto +++ /dev/null @@ -1,20 +0,0 @@ -syntax = "proto3"; -package umeenetwork.umee.leverage.v1beta1; - -import "gogoproto/gogo.proto"; -import "umee/leverage/v1beta1/leverage.proto"; - -option go_package = "github.com/umee-network/umee/v2/x/leverage/types"; - -// UpdateRegistryProposal defines a governance proposal type where the token -// registry can be updated in the Umee capital facility. Note, the registry -// defined in the proposal replaces the current registry in its entirety. -message UpdateRegistryProposal { - option (gogoproto.equal) = true; - option (gogoproto.goproto_getters) = false; - option (gogoproto.goproto_stringer) = false; - - string title = 1; - string description = 2; - repeated Token registry = 3 [(gogoproto.nullable) = false]; -} diff --git a/src/cosmospy_protobuf/umee/leverage/v1beta1/leverage.proto b/src/cosmospy_protobuf/umee/leverage/v1beta1/leverage.proto deleted file mode 100644 index d36b3fec..00000000 --- a/src/cosmospy_protobuf/umee/leverage/v1beta1/leverage.proto +++ /dev/null @@ -1,120 +0,0 @@ -syntax = "proto3"; -package umeenetwork.umee.leverage.v1beta1; - -import "gogoproto/gogo.proto"; - -option go_package = "github.com/umee-network/umee/v2/x/leverage/types"; - -// Params defines the parameters for the leverage module. -message Params { - option (gogoproto.goproto_stringer) = false; - // The complete_liquidation_threshold determines how far over their borrow limit a borrower - // must be in order for their positions to be liquidated fully in a single event. - string complete_liquidation_threshold = 2 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false, - (gogoproto.moretags) = "yaml:\"complete_liquidation_threshold\"" - ]; - // The minimum_close_factor determines the portion of a borrower's position that can be - // liquidated in a single event, when the borrower is just barely over their borrow limit. - string minimum_close_factor = 3 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false, - (gogoproto.moretags) = "yaml:\"minimum_close_factor\"" - ]; - // The oracle_reward_factor determines the portion of interest accrued on borrows that is - // sent to the oracle module to fund its reward pool. - string oracle_reward_factor = 4 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false, - (gogoproto.moretags) = "yaml:\"oracle_reward_factor\"" - ]; - // The small_liquidation_size determines the USD value at which a borrow is considered small - // enough to be liquidated in a single transaction, bypassing dynamic close factor. - string small_liquidation_size = 5 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false, - (gogoproto.moretags) = "yaml:\"small_liquidation_size\"" - ]; -} - -// Token defines a token, along with its capital metadata, in the Umee capital -// facility that can be loaned and borrowed. -message Token { - option (gogoproto.equal) = true; - - // The base_denom defines the denomination of the underlying base token. - string base_denom = 1 [(gogoproto.moretags) = "yaml:\"base_denom\""]; - - // The reserve factor defines what portion of accrued interest of the asset type - // goes to reserves. - string reserve_factor = 2 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false, - (gogoproto.moretags) = "yaml:\"reserve_factor\"" - ]; - - // The collateral_weight defines what amount of the total value of the asset - // can contribute to a users borrowing power. If the collateral_weight is zero, - // using this asset as collateral against borrowing will be disabled. - string collateral_weight = 3 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false, - (gogoproto.moretags) = "yaml:\"collateral_weight\"" - ]; - - // The liquidation_threshold defines what amount of the total value of the asset - // can contribute to a user's liquidation threshold (above which they become - // eligible for liquidation). - string liquidation_threshold = 4 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false, - (gogoproto.moretags) = "yaml:\"liquidation_threshold\"" - ]; - - // The base_borrow_rate defines the base interest rate for borrowing this - // asset. - string base_borrow_rate = 5 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false, - (gogoproto.moretags) = "yaml:\"base_borrow_rate\"" - ]; - - // The kink_borrow_rate defines the interest rate for borrowing this - // asset when utilization is at the 'kink' utilization value as defined - // on the utilization:interest graph. - string kink_borrow_rate = 6 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false, - (gogoproto.moretags) = "yaml:\"kink_borrow_rate\"" - ]; - - // The max_borrow_rate defines the interest rate for borrowing this - // asset (seen when utilization is 100%). - string max_borrow_rate = 7 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false, - (gogoproto.moretags) = "yaml:\"max_borrow_rate\"" - ]; - - // The kink_utilization_rate defines the borrow utilization rate for this - // asset where the 'kink' on the utilization:interest graph occurs. - string kink_utilization_rate = 8 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false, - (gogoproto.moretags) = "yaml:\"kink_utilization_rate\"" - ]; - - // The liquidation_incentive determines the portion of bonus collateral of - // a token type liquidators receive as a liquidation reward. - string liquidation_incentive = 9 [ - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false, - (gogoproto.moretags) = "yaml:\"liquidation_incentive\"" - ]; - - // The symbol_denom and exponent are solely used to update the oracle's accept - // list of allowed tokens. - string symbol_denom = 10 [(gogoproto.moretags) = "yaml:\"symbol_denom\""]; - uint32 exponent = 11 [(gogoproto.moretags) = "yaml:\"exponent\""]; -} diff --git a/src/cosmospy_protobuf/umee/leverage/v1beta1/query.proto b/src/cosmospy_protobuf/umee/leverage/v1beta1/query.proto deleted file mode 100644 index 1d1d29f9..00000000 --- a/src/cosmospy_protobuf/umee/leverage/v1beta1/query.proto +++ /dev/null @@ -1,390 +0,0 @@ -syntax = "proto3"; -package umeenetwork.umee.leverage.v1beta1; - -import "google/api/annotations.proto"; -import "umee/leverage/v1beta1/leverage.proto"; -import "gogoproto/gogo.proto"; -import "cosmos/base/v1beta1/coin.proto"; - -option go_package = "github.com/umee-network/umee/v2/x/leverage/types"; - -// Query defines the gRPC querier service. -service Query { - // RegisteredTokens queries for all the registered tokens. - rpc RegisteredTokens(QueryRegisteredTokens) returns (QueryRegisteredTokensResponse) { - option (google.api.http).get = "/umee/leverage/v1beta1/registered_tokens"; - } - - // Params queries the parameters of the x/leverage module. - rpc Params(QueryParamsRequest) returns (QueryParamsResponse) { - option (google.api.http).get = "/umee/leverage/v1beta1/params"; - } - - // Borrowed queries for the borrowed amount of a user by token denomination. - // If the denomination is not supplied, the total for each borrowed token is - // returned. - rpc Borrowed(QueryBorrowedRequest) returns (QueryBorrowedResponse) { - option (google.api.http).get = "/umee/leverage/v1beta1/borrowed"; - } - - // BorrowedValue queries for the usd value of the borrowed amount of a user - // by token denomination. If the denomination is not supplied, the sum across - // all borrowed tokens is returned. - rpc BorrowedValue(QueryBorrowedValueRequest) returns (QueryBorrowedValueResponse) { - option (google.api.http).get = "/umee/leverage/v1beta1/borrowed_value"; - } - - // Loaned queries for the amount of tokens loaned by a user by denomination. - // If the denomination is not supplied, the total for each loaned token is - // returned. - rpc Loaned(QueryLoanedRequest) returns (QueryLoanedResponse) { - option (google.api.http).get = "/umee/leverage/v1beta1/loaned"; - } - - // LoanedValue queries for the USD value loaned by a user by token - // denomination. If the denomination is not supplied, the sum across all - // loaned tokens is returned. - rpc LoanedValue(QueryLoanedValueRequest) returns (QueryLoanedValueResponse) { - option (google.api.http).get = "/umee/leverage/v1beta1/loaned_value"; - } - - // AvailableBorrow queries for the available amount to borrow of a specified denomination. - rpc AvailableBorrow(QueryAvailableBorrowRequest) returns (QueryAvailableBorrowResponse) { - option (google.api.http).get = "/umee/leverage/v1beta1/available_borrow"; - } - - // BorrowAPY queries for the borrow APY of a specified denomination. - rpc BorrowAPY(QueryBorrowAPYRequest) returns (QueryBorrowAPYResponse) { - option (google.api.http).get = "/umee/leverage/v1beta1/borrow_apy"; - } - - // LendAPY queries for the lend APY of a specified denomination. - rpc LendAPY(QueryLendAPYRequest) returns (QueryLendAPYResponse) { - option (google.api.http).get = "/umee/leverage/v1beta1/lend_apy"; - } - - // MarketSize queries for the Market Size in USD of a specified denomination, which - // is the USD value of total tokens loaned by all users plus borrow interest owed - // by all users. - rpc MarketSize(QueryMarketSizeRequest) returns (QueryMarketSizeResponse) { - option (google.api.http).get = "/umee/leverage/v1beta1/market_size"; - } - - // TokenMarketSize queries for the Market Size in base tokens of a specified denomination, - // which is the total tokens loaned by all users plus borrow interest owed by all users. - rpc TokenMarketSize(QueryTokenMarketSizeRequest) returns (QueryTokenMarketSizeResponse) { - option (google.api.http).get = "/umee/leverage/v1beta1/token_market_size"; - } - - // ReserveAmount queries for the amount reserved of a specified denomination. - // If the token is not valid, the reserved amount is zero. - rpc ReserveAmount(QueryReserveAmountRequest) returns (QueryReserveAmountResponse) { - option (google.api.http).get = "/umee/leverage/v1beta1/reserve_amount"; - } - - // CollateralSetting queries a borrower's collateral setting (enabled or disabled) - // for a specified uToken denomination. - rpc CollateralSetting(QueryCollateralSettingRequest) returns (QueryCollateralSettingResponse) { - option (google.api.http).get = "/umee/leverage/v1beta1/collateral_setting"; - } - - // Collateral queries the collateral amount of a user by token denomination. - // If the denomination is not supplied, all of the user's collateral tokens - // are returned. - rpc Collateral(QueryCollateralRequest) returns (QueryCollateralResponse) { - option (google.api.http).get = "/umee/leverage/v1beta1/collateral"; - } - - // CollateralValue queries for the total USD value of a user's collateral, or - // the USD value held as a given base asset's associated uToken denomination. - rpc CollateralValue(QueryCollateralValueRequest) returns (QueryCollateralValueResponse) { - option (google.api.http).get = "/umee/leverage/v1beta1/collateral_value"; - } - - // ExchangeRate queries the uToken exchange rate of a given uToken denomination. - rpc ExchangeRate(QueryExchangeRateRequest) returns (QueryExchangeRateResponse) { - option (google.api.http).get = "/umee/leverage/v1beta1/exchange_rate"; - } - - // BorrowLimit queries the borrow limit in USD of a given borrower. - rpc BorrowLimit(QueryBorrowLimitRequest) returns (QueryBorrowLimitResponse) { - option (google.api.http).get = "/umee/leverage/v1beta1/borrow_limit"; - } - - // LiquidationLimit queries the limit in USD above which a given borrower is eligible for liquidation. - rpc LiquidationLimit(QueryLiquidationLimitRequest) returns (QueryLiquidationLimitResponse) { - option (google.api.http).get = "/umee/leverage/v1beta1/liquidation_limit"; - } - - // LiquidationTargets queries a list of all borrower addresses eligible for liquidation. - rpc LiquidationTargets(QueryLiquidationTargetsRequest) returns (QueryLiquidationTargetsResponse) { - option (google.api.http).get = "/umee/leverage/v1beta1/liquidation_targets"; - } - - // MarketSummary queries a base asset's current borrowing and lending conditions. - rpc MarketSummary(QueryMarketSummaryRequest) returns (QueryMarketSummaryResponse) { - option (google.api.http).get = "/umee/leverage/v1/market_summary"; - } -} - -// QueryRegisteredTokens defines the request structure for the RegisteredTokens -// gRPC service handler. -message QueryRegisteredTokens {} - -// QueryAvailableBorrowRequest defines the request structure for the -// AvailableBorrow gRPC service handler. -message QueryAvailableBorrowRequest { - string denom = 1; -} - -// QueryAvailableBorrowResponse defines the response structure for the -// AvailableBorrow gRPC service handler. -message QueryAvailableBorrowResponse { - string amount = 1 - [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", (gogoproto.nullable) = false]; -} - -// QueryBorrowAPYRequest defines the request structure for the BorrowAPY -// gRPC service handler. -message QueryBorrowAPYRequest { - string denom = 1; -} - -// QueryBorrowAPYResponse defines the response structure for the BorrowAPY -// gRPC service handler. -message QueryBorrowAPYResponse { - string APY = 1 - [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", (gogoproto.nullable) = false]; -} - -// QueryLendAPYRequest defines the request structure for the LendAPY -// gRPC service handler. -message QueryLendAPYRequest { - string denom = 1; -} - -// QueryLendAPYResponse defines the response structure for the LendAPY -// gRPC service handler. -message QueryLendAPYResponse { - string APY = 1 - [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", (gogoproto.nullable) = false]; -} - -// QueryMarketSizeRequest defines the request structure for the Market Size in USD -// gRPC service handler. -message QueryMarketSizeRequest { - string denom = 1; -} - -// QueryMarketSizeResponse defines the response structure for the Market Size in USD -// gRPC service handler. -message QueryMarketSizeResponse { - string market_size_usd = 1 - [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", (gogoproto.nullable) = false]; -} - -// QueryTokenMarketSizeRequest defines the request structure for the Token Market Size -// gRPC service handler. -message QueryTokenMarketSizeRequest { - string denom = 1; -} - -// QueryTokenMarketSizeResponse defines the response structure for the Token Market Size -// gRPC service handler. -message QueryTokenMarketSizeResponse { - string market_size = 1 - [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", (gogoproto.nullable) = false]; -} - -// QueryRegisteredTokensResponse defines the response structure for the -// RegisteredTokens gRPC service handler. -message QueryRegisteredTokensResponse { - repeated Token registry = 1 [(gogoproto.nullable) = false]; -} - -// QueryParamsRequest defines the request structure for the Params gRPC service -// handler. -message QueryParamsRequest {} - -// QueryParamsResponse defines the response structure for the Params gRPC -// service handler. -message QueryParamsResponse { - Params params = 1 [(gogoproto.nullable) = false]; -} - -// QueryBorrowedRequest defines the request structure for the Borrowed gRPC -// service handler. -message QueryBorrowedRequest { - string address = 1; - string denom = 2; -} - -// QueryBorrowedResponse defines the response structure for the Borrowed gRPC -// service handler. -message QueryBorrowedResponse { - repeated cosmos.base.v1beta1.Coin borrowed = 1 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; -} - -// QueryBorrowedValueRequest defines the request structure for the BorrowedValue gRPC service handler. -message QueryBorrowedValueRequest { - string address = 1; - string denom = 2; -} - -// QueryBorrowedValueResponse defines the response structure for the BorrowedValue gRPC service handler. -message QueryBorrowedValueResponse { - string borrowed_value = 1 - [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", (gogoproto.nullable) = false]; -} - -// QueryCollateralValueRequest defines the request structure for the CollateralValue gRPC service handler. -message QueryCollateralValueRequest { - string address = 1; - string denom = 2; -} - -// QueryCollateralValueResponse defines the response structure for the CollateralValue gRPC service handler. -message QueryCollateralValueResponse { - string collateral_value = 1 - [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", (gogoproto.nullable) = false]; -} - -// QueryLoanedRequest defines the request structure for the Loaned gRPC service handler. -message QueryLoanedRequest { - string address = 1; - string denom = 2; -} - -// QueryLoanedResponse defines the response structure for the Loaned gRPC service handler. -message QueryLoanedResponse { - repeated cosmos.base.v1beta1.Coin loaned = 1 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; -} - -// QueryLoanedValueRequest defines the request structure for the LoanedValue gRPC service handler. -message QueryLoanedValueRequest { - string address = 1; - string denom = 2; -} - -// QueryLoanedValueResponse defines the response structure for the LoanedValue gRPC service handler. -message QueryLoanedValueResponse { - string loaned_value = 1 - [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", (gogoproto.nullable) = false]; -} - -// QueryReserveAmountRequest defines the request structure for the ReserveAmount -// gRPC service handler. -message QueryReserveAmountRequest { - string denom = 1; -} - -// QueryReserveAmountResponse defines the response structure for the ReserveAmount -// gRPC service handler. -message QueryReserveAmountResponse { - string amount = 1 [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", (gogoproto.nullable) = false]; -} - -// QueryCollateralSettingsRequest defines the request structure for the -// CollateralSetting gRPC service handler. -message QueryCollateralSettingRequest { - string address = 1; - string denom = 2; -} - -// QueryCollateralSettingsResponse defines the response structure for the -// CollateralSetting gRPC service handler. -message QueryCollateralSettingResponse { - bool enabled = 1; -} - -// QueryCollateralRequest defines the request structure for the Collateral gRPC -// service handler. -message QueryCollateralRequest { - string address = 1; - string denom = 2; -} - -// QueryCollateralResponse defines the response structure for the Collateral gRPC -// service handler. -message QueryCollateralResponse { - repeated cosmos.base.v1beta1.Coin collateral = 1 - [(gogoproto.nullable) = false, (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins"]; -} - -// QueryExchangeRateRequest defines the request structure for the ExchangeRate -// gRPC service handler. -message QueryExchangeRateRequest { - string denom = 1; -} - -// QueryExchangeRateResponse defines the response structure for the ExchangeRate -// gRPC service handler. -message QueryExchangeRateResponse { - string exchange_rate = 1 - [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", (gogoproto.nullable) = false]; -} - -// QueryBorrowLimitRequest defines the request structure for the BorrowLimit -// gRPC service handler. -message QueryBorrowLimitRequest { - string address = 1; -} - -// QueryBorrowLimitResponse defines the response structure for the BorrowLimit -// gRPC service handler. -message QueryBorrowLimitResponse { - string borrow_limit = 1 - [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", (gogoproto.nullable) = false]; -} - -// QueryLiquidationLimitRequest defines the request structure for the LiquidationLimit -// gRPC service handler. -message QueryLiquidationLimitRequest { - string address = 1; -} - -// QueryLiquidationLimitResponse defines the response structure for the LiquidationLimit -// gRPC service handler. -message QueryLiquidationLimitResponse { - string liquidation_limit = 1 - [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", (gogoproto.nullable) = false]; -} - -// QueryLiquidationTargetsRequest defines the request structure for the LiquidationTargets -// gRPC service handler. -message QueryLiquidationTargetsRequest {} - -// QueryLiquidationTargetsResponse defines the response structure for the LiquidationTargets -// gRPC service handler. -message QueryLiquidationTargetsResponse { - repeated string targets = 1; -} - -// QueryMarketSummaryRequest defines the request structure for the -// MarketSummary gRPC service handler. -message QueryMarketSummaryRequest { - string denom = 1; -} - -// QueryMarketSummaryResponse defines the response structure for the -// MarketSummary gRPC service handler. -message QueryMarketSummaryResponse { - string symbol_denom = 1; - uint32 exponent = 2; - string oracle_price = 3 - [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", (gogoproto.nullable) = true]; - string uToken_exchange_rate = 4 - [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", (gogoproto.nullable) = false]; - string lend_APY = 5 - [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", (gogoproto.nullable) = false]; - string borrow_APY = 6 - [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", (gogoproto.nullable) = false]; - string market_size = 7 - [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", (gogoproto.nullable) = false]; - string available_borrow = 8 - [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", (gogoproto.nullable) = false]; - string reserved = 9 - [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Int", (gogoproto.nullable) = false]; -} \ No newline at end of file diff --git a/src/cosmospy_protobuf/umee/leverage/v1beta1/tx.proto b/src/cosmospy_protobuf/umee/leverage/v1beta1/tx.proto deleted file mode 100644 index eac9296c..00000000 --- a/src/cosmospy_protobuf/umee/leverage/v1beta1/tx.proto +++ /dev/null @@ -1,100 +0,0 @@ -syntax = "proto3"; -package umeenetwork.umee.leverage.v1beta1; - -import "cosmos/base/v1beta1/coin.proto"; -import "gogoproto/gogo.proto"; - -option go_package = "github.com/umee-network/umee/v2/x/leverage/types"; - -// Msg defines the x/leverage module's Msg service. -service Msg { - // LendAsset defines a method for lending coins to the capital facility. - rpc LendAsset(MsgLendAsset) returns (MsgLendAssetResponse); - - // WithdrawAsset defines a method for withdrawing previously loaned coins from - // the capital facility. - rpc WithdrawAsset(MsgWithdrawAsset) returns (MsgWithdrawAssetResponse); - - // SetCollateral defines a method for users to enable or disable a uToken - // denomination in their wallet for use as collateral. - rpc SetCollateral(MsgSetCollateral) returns (MsgSetCollateralResponse); - - // BorrowAsset defines a method for borrowing coins from the capital facility. - rpc BorrowAsset(MsgBorrowAsset) returns (MsgBorrowAssetResponse); - - // RepayAsset defines a method for repaying borrowed coins to the capital facility. - rpc RepayAsset(MsgRepayAsset) returns (MsgRepayAssetResponse); - - // Liquidate defines a method for repaying a different user's borrowed coins to - // the capital facility in exchange for some of their collateral. - rpc Liquidate(MsgLiquidate) returns (MsgLiquidateResponse); -} - -// MsgLendAsset represents a lender's request to lend a base asset type to the -// module. -message MsgLendAsset { - string lender = 1; - cosmos.base.v1beta1.Coin amount = 2 [(gogoproto.nullable) = false]; -} - -// MsgWithdrawAsset represents a lender's request to withdraw a previously loaned -// base asset type from the module. Amount can either be exact uTokens to withdraw -// or equivalent base assets. -message MsgWithdrawAsset { - string lender = 1; - cosmos.base.v1beta1.Coin amount = 2 [(gogoproto.nullable) = false]; -} - -// MsgSetCollateral represents a lender's request to enable or disable -// a uToken type in their possession as collateral. -message MsgSetCollateral { - string borrower = 1; - string denom = 2; - bool enable = 3; -} - -// MsgBorrowAsset represents a lender's request to borrow a base asset type -// from the module. -message MsgBorrowAsset { - string borrower = 1; - cosmos.base.v1beta1.Coin amount = 2 [(gogoproto.nullable) = false]; -} - -// MsgRepayAsset represents a lender's request to repay a borrowed base asset type -// to the module. -message MsgRepayAsset { - string borrower = 1; - cosmos.base.v1beta1.Coin amount = 2 [(gogoproto.nullable) = false]; -} - -// MsgLiquidate represents a liquidator's request to repay a specific borrower's -// borrowed base asset type to the module in exchange for collateral reward. -message MsgLiquidate { - string liquidator = 1; - string borrower = 2; - cosmos.base.v1beta1.Coin repayment = 3 [(gogoproto.nullable) = false]; - cosmos.base.v1beta1.Coin reward = 4 [(gogoproto.nullable) = false]; -} - -// MsgLendAssetResponse defines the Msg/LendAsset response type. -message MsgLendAssetResponse {} - -// MsgWithdrawAssetResponse defines the Msg/WithdrawAsset response type. -message MsgWithdrawAssetResponse {} - -// MsgSetCollateralResponse defines the Msg/SetCollateral response type. -message MsgSetCollateralResponse {} - -// MsgBorrowAssetResponse defines the Msg/BorrowAsset response type. -message MsgBorrowAssetResponse {} - -// MsgRepayAssetResponse defines the Msg/RepayAsset response type. -message MsgRepayAssetResponse { - cosmos.base.v1beta1.Coin repaid = 1 [(gogoproto.nullable) = false]; -} - -// MsgLiquidateResponse defines the Msg/Liquidate response type. -message MsgLiquidateResponse { - cosmos.base.v1beta1.Coin repaid = 1 [(gogoproto.nullable) = false]; - cosmos.base.v1beta1.Coin reward = 2 [(gogoproto.nullable) = false]; -} diff --git a/src/cosmospy_protobuf/umee/oracle/v1beta1/genesis.proto b/src/cosmospy_protobuf/umee/oracle/v1beta1/genesis.proto deleted file mode 100644 index 4ea601aa..00000000 --- a/src/cosmospy_protobuf/umee/oracle/v1beta1/genesis.proto +++ /dev/null @@ -1,34 +0,0 @@ -syntax = "proto3"; -package umeenetwork.umee.oracle.v1beta1; - -import "gogoproto/gogo.proto"; -import "umee/oracle/v1beta1/oracle.proto"; -import "cosmos/base/v1beta1/coin.proto"; - -option go_package = "github.com/umee-network/umee/v2/x/oracle/types"; - -// GenesisState defines the oracle module's genesis state. -message GenesisState { - Params params = 1 [(gogoproto.nullable) = false]; - repeated FeederDelegation feeder_delegations = 2 [(gogoproto.nullable) = false]; - repeated ExchangeRateTuple exchange_rates = 3 - [(gogoproto.castrepeated) = "ExchangeRateTuples", (gogoproto.nullable) = false]; - repeated MissCounter miss_counters = 4 [(gogoproto.nullable) = false]; - repeated AggregateExchangeRatePrevote aggregate_exchange_rate_prevotes = 5 [(gogoproto.nullable) = false]; - repeated AggregateExchangeRateVote aggregate_exchange_rate_votes = 6 [(gogoproto.nullable) = false]; -} - -// FeederDelegation is the address for where oracle feeder authority are -// delegated to. By default this struct is only used at genesis to feed in -// default feeder addresses. -message FeederDelegation { - string feeder_address = 1; - string validator_address = 2; -} - -// MissCounter defines an miss counter and validator address pair used in -// oracle module's genesis state -message MissCounter { - string validator_address = 1; - uint64 miss_counter = 2; -} diff --git a/src/cosmospy_protobuf/umee/oracle/v1beta1/oracle.proto b/src/cosmospy_protobuf/umee/oracle/v1beta1/oracle.proto deleted file mode 100644 index 2440b4d7..00000000 --- a/src/cosmospy_protobuf/umee/oracle/v1beta1/oracle.proto +++ /dev/null @@ -1,98 +0,0 @@ -syntax = "proto3"; -package umeenetwork.umee.oracle.v1beta1; - -import "gogoproto/gogo.proto"; -import "cosmos/base/v1beta1/coin.proto"; - -option go_package = "github.com/umee-network/umee/v2/x/oracle/types"; - -// Params defines the parameters for the oracle module. -message Params { - option (gogoproto.equal) = true; - option (gogoproto.goproto_stringer) = false; - - uint64 vote_period = 1 [(gogoproto.moretags) = "yaml:\"vote_period\""]; - string vote_threshold = 2 [ - (gogoproto.moretags) = "yaml:\"vote_threshold\"", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false - ]; - string reward_band = 3 [ - (gogoproto.moretags) = "yaml:\"reward_band\"", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false - ]; - uint64 reward_distribution_window = 4 [(gogoproto.moretags) = "yaml:\"reward_distribution_window\""]; - repeated Denom accept_list = 5 [ - (gogoproto.moretags) = "yaml:\"accept_list\"", - (gogoproto.castrepeated) = "DenomList", - (gogoproto.nullable) = false - ]; - string slash_fraction = 6 [ - (gogoproto.moretags) = "yaml:\"slash_fraction\"", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false - ]; - uint64 slash_window = 7 [(gogoproto.moretags) = "yaml:\"slash_window\""]; - string min_valid_per_window = 8 [ - (gogoproto.moretags) = "yaml:\"min_valid_per_window\"", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false - ]; -} - -// Denom - the object to hold configurations of each denom -message Denom { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - option (gogoproto.goproto_stringer) = false; - - string base_denom = 1 [(gogoproto.moretags) = "yaml:\"base_denom\""]; - string symbol_denom = 2 [(gogoproto.moretags) = "yaml:\"symbol_denom\""]; - uint32 exponent = 3 [(gogoproto.moretags) = "yaml:\"exponent\""]; -} - -// AggregateExchangeRatePrevote - -// struct for aggregate prevoting on the ExchangeRateVote. -// The purpose of aggregate prevote is to hide vote exchange rates with hash -// which is formatted as hex string in SHA256("{salt}:{exchange -// rate}{denom},...,{exchange rate}{denom}:{voter}") -message AggregateExchangeRatePrevote { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - option (gogoproto.goproto_stringer) = false; - - string hash = 1 [(gogoproto.moretags) = "yaml:\"hash\""]; - string voter = 2 [(gogoproto.moretags) = "yaml:\"voter\""]; - uint64 submit_block = 3 [(gogoproto.moretags) = "yaml:\"submit_block\""]; -} - -// AggregateExchangeRateVote - struct for voting on -// the exchange rates of USD denominated in various assets. -message AggregateExchangeRateVote { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - option (gogoproto.goproto_stringer) = false; - - repeated ExchangeRateTuple exchange_rate_tuples = 1 [ - (gogoproto.moretags) = "yaml:\"exchange_rate_tuples\"", - (gogoproto.castrepeated) = "ExchangeRateTuples", - (gogoproto.nullable) = false - ]; - - string voter = 2 [(gogoproto.moretags) = "yaml:\"voter\""]; -} - -// ExchangeRateTuple - struct to store interpreted exchange rates data to store -message ExchangeRateTuple { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - option (gogoproto.goproto_stringer) = false; - - string denom = 1 [(gogoproto.moretags) = "yaml:\"denom\""]; - string exchange_rate = 2 [ - (gogoproto.moretags) = "yaml:\"exchange_rate\"", - (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Dec", - (gogoproto.nullable) = false - ]; -} diff --git a/src/cosmospy_protobuf/umee/oracle/v1beta1/query.proto b/src/cosmospy_protobuf/umee/oracle/v1beta1/query.proto deleted file mode 100644 index d8ed51c7..00000000 --- a/src/cosmospy_protobuf/umee/oracle/v1beta1/query.proto +++ /dev/null @@ -1,195 +0,0 @@ -syntax = "proto3"; -package umeenetwork.umee.oracle.v1beta1; - -import "gogoproto/gogo.proto"; -import "google/api/annotations.proto"; -import "umee/oracle/v1beta1/oracle.proto"; -import "cosmos/base/v1beta1/coin.proto"; - -option go_package = "github.com/umee-network/umee/v2/x/oracle/types"; - -// Query defines the gRPC querier service. -service Query { - // ExchangeRates returns exchange rates of all denoms, - // or, if specified, returns a single denom - rpc ExchangeRates(QueryExchangeRatesRequest) returns (QueryExchangeRatesResponse) { - option (google.api.http).get = "/umee/oracle/v1beta1/denoms/exchange_rates/{denom}"; - } - - // ActiveExchangeRates returns all active denoms - rpc ActiveExchangeRates(QueryActiveExchangeRatesRequest) returns (QueryActiveExchangeRatesResponse) { - option (google.api.http).get = "/umee/oracle/v1beta1/denoms/active_exchange_rates"; - } - - // FeederDelegation returns feeder delegation of a validator - rpc FeederDelegation(QueryFeederDelegationRequest) returns (QueryFeederDelegationResponse) { - option (google.api.http).get = "/umee/oracle/v1beta1/validators/{validator_addr}/feeder"; - } - - // MissCounter returns oracle miss counter of a validator - rpc MissCounter(QueryMissCounterRequest) returns (QueryMissCounterResponse) { - option (google.api.http).get = "/umee/oracle/v1beta1/validators/{validator_addr}/miss"; - } - - // AggregatePrevote returns an aggregate prevote of a validator - rpc AggregatePrevote(QueryAggregatePrevoteRequest) returns (QueryAggregatePrevoteResponse) { - option (google.api.http).get = "/umee/oracle/v1beta1/validators/{validator_addr}/aggregate_prevote"; - } - - // AggregatePrevotes returns aggregate prevotes of all validators - rpc AggregatePrevotes(QueryAggregatePrevotesRequest) returns (QueryAggregatePrevotesResponse) { - option (google.api.http).get = "/umee/oracle/v1beta1/validators/aggregate_prevotes"; - } - - // AggregateVote returns an aggregate vote of a validator - rpc AggregateVote(QueryAggregateVoteRequest) returns (QueryAggregateVoteResponse) { - option (google.api.http).get = "/umee/oracle/v1beta1/valdiators/{validator_addr}/aggregate_vote"; - } - - // AggregateVotes returns aggregate votes of all validators - rpc AggregateVotes(QueryAggregateVotesRequest) returns (QueryAggregateVotesResponse) { - option (google.api.http).get = "/umee/oracle/v1beta1/validators/aggregate_votes"; - } - - // Params queries all parameters. - rpc Params(QueryParamsRequest) returns (QueryParamsResponse) { - option (google.api.http).get = "/umee/oracle/v1beta1/params"; - } -} - -// QueryExchangeRatesRequest is the request type for the Query/ExchangeRate RPC -// method. -message QueryExchangeRatesRequest { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // denom defines the denomination to query for. - string denom = 1; -} - - -// QueryExchangeRatesResponse is response type for the -// Query/ExchangeRates RPC method. -message QueryExchangeRatesResponse { - // exchange_rates defines a list of the exchange rate for all whitelisted - // denoms. - repeated cosmos.base.v1beta1.DecCoin exchange_rates = 1 - [(gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.DecCoins", (gogoproto.nullable) = false]; -} - - -// QueryActiveExchangeRatesRequest is the request type for the Query/ActiveExchangeRates RPC method. -message QueryActiveExchangeRatesRequest {} - -// QueryActiveExchangeRatesResponse is response type for the -// Query/ActiveExchangeRates RPC method. -message QueryActiveExchangeRatesResponse { - // activeRates defines a list of the denomination which oracle prices aggreed - // upon. - repeated string active_rates = 1; -} - - -// QueryFeederDelegationRequest is the request type for the -// Query/FeederDelegation RPC method. -message QueryFeederDelegationRequest { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // validator defines the validator address to query for. - string validator_addr = 1; -} - -// QueryFeederDelegationResponse is response type for the -// Query/FeederDelegation RPC method. -message QueryFeederDelegationResponse { - // feeder_addr defines the feeder delegation of a validator - string feeder_addr = 1; -} - -// QueryMissCounterRequest is the request type for the Query/MissCounter RPC -// method. -message QueryMissCounterRequest { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // validator defines the validator address to query for. - string validator_addr = 1; -} - -// QueryMissCounterResponse is response type for the -// Query/MissCounter RPC method. -message QueryMissCounterResponse { - // miss_counter defines the oracle miss counter of a validator - uint64 miss_counter = 1; -} - -// QueryAggregatePrevoteRequest is the request type for the -// Query/AggregatePrevote RPC method. -message QueryAggregatePrevoteRequest { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // validator defines the validator address to query for. - string validator_addr = 1; -} - -// QueryAggregatePrevoteResponse is response type for the -// Query/AggregatePrevote RPC method. -message QueryAggregatePrevoteResponse { - // aggregate_prevote defines oracle aggregate prevote submitted by a validator - // in the current vote period - AggregateExchangeRatePrevote aggregate_prevote = 1 [(gogoproto.nullable) = false]; - ; -} - -// QueryAggregatePrevotesRequest is the request type for the -// Query/AggregatePrevotes RPC method. -message QueryAggregatePrevotesRequest {} - -// QueryAggregatePrevotesResponse is response type for the -// Query/AggregatePrevotes RPC method. -message QueryAggregatePrevotesResponse { - // aggregate_prevotes defines all oracle aggregate prevotes submitted in the - // current vote period - repeated AggregateExchangeRatePrevote aggregate_prevotes = 1 [(gogoproto.nullable) = false]; -} - -// QueryAggregateVoteRequest is the request type for the Query/AggregateVote RPC -// method. -message QueryAggregateVoteRequest { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - // validator defines the validator address to query for. - string validator_addr = 1; -} - -// QueryAggregateVoteResponse is response type for the -// Query/AggregateVote RPC method. -message QueryAggregateVoteResponse { - // aggregate_vote defines oracle aggregate vote submitted by a validator in - // the current vote period - AggregateExchangeRateVote aggregate_vote = 1 [(gogoproto.nullable) = false]; -} - -// QueryAggregateVotesRequest is the request type for the Query/AggregateVotes -// RPC method. -message QueryAggregateVotesRequest {} - -// QueryAggregateVotesResponse is response type for the -// Query/AggregateVotes RPC method. -message QueryAggregateVotesResponse { - // aggregate_votes defines all oracle aggregate votes submitted in the current - // vote period - repeated AggregateExchangeRateVote aggregate_votes = 1 [(gogoproto.nullable) = false]; -} - -// 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]; -} diff --git a/src/cosmospy_protobuf/umee/oracle/v1beta1/tx.proto b/src/cosmospy_protobuf/umee/oracle/v1beta1/tx.proto deleted file mode 100644 index a8da6299..00000000 --- a/src/cosmospy_protobuf/umee/oracle/v1beta1/tx.proto +++ /dev/null @@ -1,65 +0,0 @@ -syntax = "proto3"; -package umeenetwork.umee.oracle.v1beta1; - -import "gogoproto/gogo.proto"; - -option go_package = "github.com/umee-network/umee/v2/x/oracle/types"; - -// Msg defines the oracle Msg service. -service Msg { - // AggregateExchangeRatePrevote defines a method for submitting an aggregate - // exchange rate prevote. - rpc AggregateExchangeRatePrevote(MsgAggregateExchangeRatePrevote) returns (MsgAggregateExchangeRatePrevoteResponse); - - // AggregateExchangeRateVote defines a method for submitting an aggregate - // exchange rate vote. - rpc AggregateExchangeRateVote(MsgAggregateExchangeRateVote) returns (MsgAggregateExchangeRateVoteResponse); - - // DelegateFeedConsent defines a method for setting the feeder delegation. - rpc DelegateFeedConsent(MsgDelegateFeedConsent) returns (MsgDelegateFeedConsentResponse); -} - -// MsgAggregateExchangeRatePrevote represents a message to submit an aggregate -// exchange rate prevote. -message MsgAggregateExchangeRatePrevote { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - string hash = 1 [(gogoproto.moretags) = "yaml:\"hash\""]; - string feeder = 2 [(gogoproto.moretags) = "yaml:\"feeder\""]; - string validator = 3 [(gogoproto.moretags) = "yaml:\"validator\""]; -} - -// MsgAggregateExchangeRatePrevoteResponse defines the -// Msg/AggregateExchangeRatePrevote response type. -message MsgAggregateExchangeRatePrevoteResponse {} - -// MsgAggregateExchangeRateVote represents a message to submit anaggregate -// exchange rate vote. -message MsgAggregateExchangeRateVote { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - string salt = 1 [(gogoproto.moretags) = "yaml:\"salt\""]; - string exchange_rates = 2 [(gogoproto.moretags) = "yaml:\"exchange_rates\""]; - string feeder = 3 [(gogoproto.moretags) = "yaml:\"feeder\""]; - string validator = 4 [(gogoproto.moretags) = "yaml:\"validator\""]; -} - -// MsgAggregateExchangeRateVoteResponse defines the -// Msg/AggregateExchangeRateVote response type. -message MsgAggregateExchangeRateVoteResponse {} - -// MsgDelegateFeedConsent represents a message to delegate oracle voting rights -// to another address. -message MsgDelegateFeedConsent { - option (gogoproto.equal) = false; - option (gogoproto.goproto_getters) = false; - - string operator = 1 [(gogoproto.moretags) = "yaml:\"operator\""]; - string delegate = 2 [(gogoproto.moretags) = "yaml:\"delegate\""]; -} - -// MsgDelegateFeedConsentResponse defines the Msg/DelegateFeedConsent response -// type. -message MsgDelegateFeedConsentResponse {}