2022-10-09 11:41:15 +00:00
|
|
|
syntax = "proto3";
|
|
|
|
|
|
|
|
package lightrpc;
|
|
|
|
|
|
|
|
import "beacon_block.proto";
|
|
|
|
|
|
|
|
message GossipRequest {}
|
|
|
|
|
2022-10-09 15:49:27 +00:00
|
|
|
enum GossipType {
|
|
|
|
// Lightclient gossip
|
|
|
|
LightClientFinalityUpdateGossipType = 0;
|
|
|
|
LightClientOptimisticUpdateGossipType = 1;
|
|
|
|
// Legacy gossip
|
|
|
|
BeaconBlockGossipType = 2;
|
|
|
|
}
|
|
|
|
|
|
|
|
message GossipData {
|
|
|
|
bytes data = 1; // SSZ encoded data
|
|
|
|
GossipType type = 2;
|
|
|
|
}
|
|
|
|
|
2022-10-10 13:58:31 +00:00
|
|
|
message RequestData {
|
|
|
|
bytes data = 1; // SSZ encoded data
|
|
|
|
string topic = 2;
|
|
|
|
}
|
|
|
|
|
|
|
|
message ResponseData {
|
|
|
|
bytes data = 1; // prefix-stripped SSZ encoded data
|
|
|
|
bool error = 2; // did the peer encounter an error
|
|
|
|
}
|
|
|
|
|
2022-10-09 11:41:15 +00:00
|
|
|
service Sentinel {
|
2022-10-09 15:49:27 +00:00
|
|
|
rpc SubscribeGossip(GossipRequest) returns (stream GossipData);
|
2022-10-10 13:58:31 +00:00
|
|
|
rpc SendRequest(RequestData) returns (ResponseData);
|
2022-10-09 11:41:15 +00:00
|
|
|
}
|