Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions packages/api/src/beacon/routes/beacon/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ export type {BlockHeaderResponse, BlockId} from "./block.js";
export {BroadcastValidation} from "./block.js";
// TODO: Review if re-exporting all these types is necessary
export type {
BuilderId,
BuilderResponse,
BuilderStatus,
EpochCommitteeResponse,
Expand Down
3 changes: 2 additions & 1 deletion packages/api/src/beacon/routes/beacon/state.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ export type StateArgs = {
};

export type ValidatorId = string | number;
export type BuilderId = string | number;

export type {BuilderStatus, ValidatorStatus};

Expand Down Expand Up @@ -229,7 +230,7 @@ export type Endpoints = {
"POST",
StateArgs & {
/** Either hex encoded public key (any bytes48 with 0x prefix) or builder index */
builderIds?: ValidatorId[];
builderIds?: BuilderId[];
statuses?: BuilderStatus[];
},
{params: {state_id: string}; body: {ids?: string[]; statuses?: BuilderStatus[]}},
Expand Down
2 changes: 1 addition & 1 deletion packages/beacon-node/src/api/impl/beacon/state/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ type StateBuilderIndexResponse =
| {valid: false; code: number; reason: string};

export function getStateBuilderIndex(
id: routes.beacon.ValidatorId | BLSPubkey,
id: routes.beacon.BuilderId | BLSPubkey,
state: IBeaconStateViewGloas
): StateBuilderIndexResponse {
if (typeof id === "string") {
Expand Down