mirror of
https://gitlab.com/pulsechaincom/prysm-pulse.git
synced 2024-12-31 23:41:22 +00:00
881ad77c52
* add block endpoint * handle err * check for nil block Co-authored-by: prylabs-bulldozer[bot] <58059840+prylabs-bulldozer[bot]@users.noreply.github.com>
62 lines
1.7 KiB
Protocol Buffer
62 lines
1.7 KiB
Protocol Buffer
syntax = "proto3";
|
|
|
|
package ethereum.beacon.rpc.v1;
|
|
|
|
import "proto/beacon/p2p/v1/types.proto";
|
|
import "google/api/annotations.proto";
|
|
import "google/protobuf/empty.proto";
|
|
|
|
// Debug service API
|
|
//
|
|
// The debug service in Prysm provides API access to various utilities
|
|
// for debugging the beacon node's functionality at runtime, such as being able
|
|
// to retrieve the beacon state by block root or state root from the node directly.
|
|
service Debug {
|
|
// Returns a beacon state by filter criteria from the beacon node.
|
|
rpc GetBeaconState(BeaconStateRequest) returns (SSZResponse) {
|
|
option (google.api.http) = {
|
|
get: "/eth/v1alpha1/debug/state"
|
|
};
|
|
}
|
|
// Returns a beacon state by filter criteria from the beacon node.
|
|
rpc GetBlock(BlockRequest) returns (SSZResponse) {
|
|
option (google.api.http) = {
|
|
get: "/eth/v1alpha1/debug/block"
|
|
};
|
|
}
|
|
// SetLoggingLevel sets the log-level of the beacon node programmatically.
|
|
rpc SetLoggingLevel(LoggingLevelRequest) returns (google.protobuf.Empty) {
|
|
option (google.api.http) = {
|
|
post: "/eth/v1alpha1/debug/logging"
|
|
};
|
|
}
|
|
}
|
|
|
|
message BeaconStateRequest {
|
|
oneof query_filter {
|
|
// The slot corresponding to a desired beacon state.
|
|
uint64 slot = 1;
|
|
|
|
// The block root corresponding to a desired beacon state.
|
|
bytes block_root = 2;
|
|
}
|
|
}
|
|
|
|
message BlockRequest {
|
|
bytes block_root = 1;
|
|
}
|
|
|
|
message SSZResponse {
|
|
// Returns an ssz-encoded byte slice as a response.
|
|
bytes encoded = 1;
|
|
}
|
|
|
|
message LoggingLevelRequest {
|
|
// The logging levels available in Prysm as an enum.
|
|
enum Level {
|
|
INFO = 0;
|
|
DEBUG = 1;
|
|
TRACE = 2;
|
|
}
|
|
Level level = 1;
|
|
} |