-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: add missing proto files and lint
- Loading branch information
1 parent
f217136
commit 500b322
Showing
7 changed files
with
136 additions
and
43 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
syntax = "proto3"; | ||
package sedachain.pubkey.v1; | ||
|
||
import "gogoproto/gogo.proto"; | ||
import "cosmos_proto/cosmos.proto"; | ||
import "sedachain/pubkey/v1/pubkey.proto"; | ||
|
||
option go_package = "github.com/sedaprotocol/seda-chain/x/pubkey/types"; | ||
|
||
// GenesisState defines pubkey module's genesis state. | ||
message GenesisState { | ||
repeated ValidatorPubKeys validator_pub_keys = 1 [(gogoproto.nullable) = false]; | ||
} | ||
|
||
// ValidatorPubKeys defines a validator's list of registered public keys | ||
// primarily used in the x/pubkey genesis state. | ||
message ValidatorPubKeys { | ||
string validator_addr = 1 [(cosmos_proto.scalar) = "cosmos.ValidatorAddressString"]; | ||
repeated IndexedPubKey indexed_pub_keys = 2 [(gogoproto.nullable) = false]; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
syntax = "proto3"; | ||
package sedachain.pubkey.v1; | ||
|
||
import "gogoproto/gogo.proto"; | ||
import "google/protobuf/any.proto"; | ||
import "cosmos_proto/cosmos.proto"; | ||
|
||
option go_package = "github.com/sedaprotocol/seda-chain/x/pubkey/types"; | ||
|
||
// IndexPubKeyPair defines an index - public key pair. | ||
message IndexedPubKey { | ||
uint32 index = 1; | ||
google.protobuf.Any pub_key = 2 [(cosmos_proto.accepts_interface) = "cosmos.crypto.PubKey"]; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
syntax = "proto3"; | ||
package sedachain.pubkey.v1; | ||
|
||
import "google/api/annotations.proto"; | ||
import "gogoproto/gogo.proto"; | ||
import "cosmos_proto/cosmos.proto"; | ||
import "sedachain/pubkey/v1/genesis.proto"; | ||
|
||
option go_package = "github.com/sedaprotocol/seda-chain/x/pubkey/types"; | ||
|
||
// Query defines the gRPC querier service. | ||
service Query { | ||
// ValidatorKeys returns a given validator's registered keys. | ||
rpc ValidatorKeys(QueryValidatorKeysRequest) | ||
returns (QueryValidatorKeysResponse) { | ||
option (google.api.http).get = "/seda-chain/pubkey/validator_keys/{validator_addr}"; | ||
} | ||
} | ||
|
||
// QueryValidatorKeysRequest is request type for the Query/ValidatorKeys RPC method. | ||
message QueryValidatorKeysRequest { | ||
string validator_addr = 1 [(cosmos_proto.scalar) = "cosmos.ValidatorAddressString"]; | ||
} | ||
|
||
// QueryValidatorKeysResponse is response type for the Query/ValidatorKeys RPC method. | ||
message QueryValidatorKeysResponse { | ||
ValidatorPubKeys validator_pub_keys = 1 [(gogoproto.nullable) = false]; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
syntax = "proto3"; | ||
package sedachain.pubkey.v1; | ||
|
||
import "gogoproto/gogo.proto"; | ||
import "google/protobuf/any.proto"; | ||
import "cosmos_proto/cosmos.proto"; | ||
import "cosmos/msg/v1/msg.proto"; | ||
import "sedachain/pubkey/v1/pubkey.proto"; | ||
|
||
option go_package = "github.com/sedaprotocol/seda-chain/x/pubkey/types"; | ||
|
||
// Msg defines the pubkey Msg service. | ||
service Msg { | ||
option (cosmos.msg.v1.service) = true; | ||
|
||
// AddKey defines a method for registering a new public key. | ||
rpc AddKey(MsgAddKey) | ||
returns (MsgAddKeyResponse); | ||
} | ||
|
||
// MsgAddKey defines a message for registering a new public key. | ||
message MsgAddKey { | ||
option (cosmos.msg.v1.signer) = "validator_addr"; | ||
|
||
string validator_addr = 1 [(cosmos_proto.scalar) = "cosmos.ValidatorAddressString"]; | ||
repeated IndexedPubKey indexed_pub_keys = 2 [(gogoproto.nullable) = false]; | ||
} | ||
|
||
// MsgAddKeyResponse defines the Msg/MsgAddKey response type. | ||
message MsgAddKeyResponse {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters