@lodestar/api 1.20.0-dev.c1532773c2 → 1.20.0-dev.d87a9018e6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +10 -17
- package/lib/beacon/client/beacon.d.ts +4 -3
- package/lib/beacon/client/beacon.js +3 -36
- package/lib/beacon/client/beacon.js.map +1 -1
- package/lib/beacon/client/config.d.ts +4 -3
- package/lib/beacon/client/config.js +3 -6
- package/lib/beacon/client/config.js.map +1 -1
- package/lib/beacon/client/debug.d.ts +4 -3
- package/lib/beacon/client/debug.js +4 -45
- package/lib/beacon/client/debug.js.map +1 -1
- package/lib/beacon/client/events.d.ts +5 -2
- package/lib/beacon/client/events.js +33 -35
- package/lib/beacon/client/events.js.map +1 -1
- package/lib/beacon/client/index.d.ts +6 -3
- package/lib/beacon/client/index.js +2 -2
- package/lib/beacon/client/index.js.map +1 -1
- package/lib/beacon/client/lightclient.d.ts +4 -3
- package/lib/beacon/client/lightclient.js +4 -7
- package/lib/beacon/client/lightclient.js.map +1 -1
- package/lib/beacon/client/lodestar.d.ts +4 -3
- package/lib/beacon/client/lodestar.js +4 -7
- package/lib/beacon/client/lodestar.js.map +1 -1
- package/lib/beacon/client/node.d.ts +4 -3
- package/lib/beacon/client/node.js +4 -7
- package/lib/beacon/client/node.js.map +1 -1
- package/lib/beacon/client/proof.d.ts +5 -4
- package/lib/beacon/client/proof.js +5 -61
- package/lib/beacon/client/proof.js.map +1 -1
- package/lib/beacon/client/validator.d.ts +4 -3
- package/lib/beacon/client/validator.js +4 -7
- package/lib/beacon/client/validator.js.map +1 -1
- package/lib/beacon/index.d.ts +5 -5
- package/lib/beacon/index.js.map +1 -1
- package/lib/beacon/routes/beacon/block.d.ts +286 -167
- package/lib/beacon/routes/beacon/block.js +317 -117
- package/lib/beacon/routes/beacon/block.js.map +1 -1
- package/lib/beacon/routes/beacon/index.d.ts +6 -588
- package/lib/beacon/routes/beacon/index.js +16 -26
- package/lib/beacon/routes/beacon/index.js.map +1 -1
- package/lib/beacon/routes/beacon/pool.d.ts +155 -117
- package/lib/beacon/routes/beacon/pool.js +146 -42
- package/lib/beacon/routes/beacon/pool.js.map +1 -1
- package/lib/beacon/routes/beacon/rewards.d.ts +113 -101
- package/lib/beacon/routes/beacon/rewards.js +98 -63
- package/lib/beacon/routes/beacon/rewards.js.map +1 -1
- package/lib/beacon/routes/beacon/state.d.ts +172 -226
- package/lib/beacon/routes/beacon/state.js +204 -126
- package/lib/beacon/routes/beacon/state.js.map +1 -1
- package/lib/beacon/routes/config.d.ts +21 -36
- package/lib/beacon/routes/config.js +45 -24
- package/lib/beacon/routes/config.js.map +1 -1
- package/lib/beacon/routes/debug.d.ts +22 -104
- package/lib/beacon/routes/debug.js +53 -45
- package/lib/beacon/routes/debug.js.map +1 -1
- package/lib/beacon/routes/events.d.ts +24 -20
- package/lib/beacon/routes/events.js +40 -18
- package/lib/beacon/routes/events.js.map +1 -1
- package/lib/beacon/routes/index.d.ts +19 -19
- package/lib/beacon/routes/index.js +1 -0
- package/lib/beacon/routes/index.js.map +1 -1
- package/lib/beacon/routes/lightclient.d.ts +34 -56
- package/lib/beacon/routes/lightclient.js +108 -48
- package/lib/beacon/routes/lightclient.js.map +1 -1
- package/lib/beacon/routes/lodestar.d.ts +74 -148
- package/lib/beacon/routes/lodestar.js +126 -77
- package/lib/beacon/routes/lodestar.js.map +1 -1
- package/lib/beacon/routes/node.d.ts +48 -82
- package/lib/beacon/routes/node.js +90 -57
- package/lib/beacon/routes/node.js.map +1 -1
- package/lib/beacon/routes/proof.d.ts +25 -31
- package/lib/beacon/routes/proof.js +44 -24
- package/lib/beacon/routes/proof.js.map +1 -1
- package/lib/beacon/routes/validator.d.ts +524 -325
- package/lib/beacon/routes/validator.js +468 -213
- package/lib/beacon/routes/validator.js.map +1 -1
- package/lib/beacon/server/beacon.d.ts +3 -4
- package/lib/beacon/server/beacon.js +4 -57
- package/lib/beacon/server/beacon.js.map +1 -1
- package/lib/beacon/server/config.d.ts +3 -4
- package/lib/beacon/server/config.js +4 -5
- package/lib/beacon/server/config.js.map +1 -1
- package/lib/beacon/server/debug.d.ts +3 -4
- package/lib/beacon/server/debug.js +4 -54
- package/lib/beacon/server/debug.js.map +1 -1
- package/lib/beacon/server/events.d.ts +4 -4
- package/lib/beacon/server/events.js +17 -23
- package/lib/beacon/server/events.js.map +1 -1
- package/lib/beacon/server/index.d.ts +7 -8
- package/lib/beacon/server/index.js +13 -14
- package/lib/beacon/server/index.js.map +1 -1
- package/lib/beacon/server/lightclient.d.ts +3 -4
- package/lib/beacon/server/lightclient.js +4 -5
- package/lib/beacon/server/lightclient.js.map +1 -1
- package/lib/beacon/server/lodestar.d.ts +3 -4
- package/lib/beacon/server/lodestar.js +4 -5
- package/lib/beacon/server/lodestar.js.map +1 -1
- package/lib/beacon/server/node.d.ts +3 -4
- package/lib/beacon/server/node.js +4 -18
- package/lib/beacon/server/node.js.map +1 -1
- package/lib/beacon/server/proof.d.ts +3 -4
- package/lib/beacon/server/proof.js +4 -36
- package/lib/beacon/server/proof.js.map +1 -1
- package/lib/beacon/server/validator.d.ts +3 -4
- package/lib/beacon/server/validator.js +4 -21
- package/lib/beacon/server/validator.js.map +1 -1
- package/lib/builder/client.d.ts +4 -6
- package/lib/builder/client.js +3 -9
- package/lib/builder/client.js.map +1 -1
- package/lib/builder/index.d.ts +8 -5
- package/lib/builder/index.js +4 -1
- package/lib/builder/index.js.map +1 -1
- package/lib/builder/routes.d.ts +25 -39
- package/lib/builder/routes.js +78 -34
- package/lib/builder/routes.js.map +1 -1
- package/lib/builder/server/index.d.ts +6 -6
- package/lib/builder/server/index.js +7 -8
- package/lib/builder/server/index.js.map +1 -1
- package/lib/index.d.ts +9 -6
- package/lib/index.js +5 -4
- package/lib/index.js.map +1 -1
- package/lib/keymanager/client.d.ts +4 -3
- package/lib/keymanager/client.js +4 -7
- package/lib/keymanager/client.js.map +1 -1
- package/lib/keymanager/index.d.ts +5 -4
- package/lib/keymanager/index.js +1 -1
- package/lib/keymanager/index.js.map +1 -1
- package/lib/keymanager/routes.d.ts +155 -177
- package/lib/keymanager/routes.js +236 -123
- package/lib/keymanager/routes.js.map +1 -1
- package/lib/keymanager/server/index.d.ts +6 -6
- package/lib/keymanager/server/index.js +7 -8
- package/lib/keymanager/server/index.js.map +1 -1
- package/lib/server/index.d.ts +2 -0
- package/lib/server/index.js +3 -0
- package/lib/server/index.js.map +1 -0
- package/lib/utils/client/error.d.ts +6 -0
- package/lib/utils/client/error.js +8 -0
- package/lib/utils/client/error.js.map +1 -0
- package/lib/utils/client/httpClient.d.ts +35 -75
- package/lib/utils/client/httpClient.js +201 -153
- package/lib/utils/client/httpClient.js.map +1 -1
- package/lib/utils/client/index.d.ts +6 -2
- package/lib/utils/client/index.js +6 -2
- package/lib/utils/client/index.js.map +1 -1
- package/lib/utils/client/method.d.ts +11 -0
- package/lib/utils/client/method.js +27 -0
- package/lib/utils/client/method.js.map +1 -0
- package/lib/utils/client/request.d.ts +33 -0
- package/lib/utils/client/request.js +66 -0
- package/lib/utils/client/request.js.map +1 -0
- package/lib/utils/client/response.d.ts +36 -0
- package/lib/utils/client/response.js +167 -0
- package/lib/utils/client/response.js.map +1 -0
- package/lib/utils/codecs.d.ts +28 -0
- package/lib/utils/codecs.js +105 -0
- package/lib/utils/codecs.js.map +1 -0
- package/lib/utils/fork.d.ts +7 -0
- package/lib/utils/fork.js +29 -0
- package/lib/utils/fork.js.map +1 -0
- package/lib/utils/headers.d.ts +37 -0
- package/lib/utils/headers.js +134 -0
- package/lib/utils/headers.js.map +1 -0
- package/lib/utils/httpStatusCode.js.map +1 -0
- package/lib/utils/index.d.ts +1 -1
- package/lib/utils/index.js +1 -1
- package/lib/utils/index.js.map +1 -1
- package/lib/utils/metadata.d.ts +88 -0
- package/lib/utils/metadata.js +126 -0
- package/lib/utils/metadata.js.map +1 -0
- package/lib/utils/schema.d.ts +31 -17
- package/lib/utils/schema.js +18 -6
- package/lib/utils/schema.js.map +1 -1
- package/lib/utils/serdes.d.ts +3 -0
- package/lib/utils/serdes.js +13 -0
- package/lib/utils/serdes.js.map +1 -1
- package/lib/utils/server/{errors.d.ts → error.d.ts} +2 -2
- package/lib/utils/server/{errors.js → error.js} +1 -1
- package/lib/utils/server/error.js.map +1 -0
- package/lib/utils/server/handler.d.ts +11 -0
- package/lib/utils/server/handler.js +115 -0
- package/lib/utils/server/handler.js.map +1 -0
- package/lib/utils/server/index.d.ts +5 -4
- package/lib/utils/server/index.js +5 -4
- package/lib/utils/server/index.js.map +1 -1
- package/lib/utils/server/method.d.ts +35 -0
- package/lib/utils/server/method.js +2 -0
- package/lib/utils/server/method.js.map +1 -0
- package/lib/utils/server/parser.d.ts +3 -0
- package/lib/utils/server/parser.js +20 -0
- package/lib/utils/server/parser.js.map +1 -0
- package/lib/utils/server/route.d.ts +20 -0
- package/lib/utils/server/route.js +19 -0
- package/lib/utils/server/route.js.map +1 -0
- package/lib/utils/types.d.ts +116 -104
- package/lib/utils/types.js +2 -155
- package/lib/utils/types.js.map +1 -1
- package/lib/utils/urlFormat.d.ts +2 -2
- package/lib/utils/urlFormat.js +3 -3
- package/lib/utils/urlFormat.js.map +1 -1
- package/lib/utils/wireFormat.d.ts +8 -0
- package/lib/utils/wireFormat.js +23 -0
- package/lib/utils/wireFormat.js.map +1 -0
- package/package.json +10 -7
- package/lib/interfaces.d.ts +0 -44
- package/lib/interfaces.js +0 -2
- package/lib/interfaces.js.map +0 -1
- package/lib/utils/acceptHeader.d.ts +0 -9
- package/lib/utils/acceptHeader.js +0 -62
- package/lib/utils/acceptHeader.js.map +0 -1
- package/lib/utils/client/client.d.ts +0 -29
- package/lib/utils/client/client.js +0 -88
- package/lib/utils/client/client.js.map +0 -1
- package/lib/utils/client/httpStatusCode.js.map +0 -1
- package/lib/utils/routes.d.ts +0 -6
- package/lib/utils/routes.js +0 -31
- package/lib/utils/routes.js.map +0 -1
- package/lib/utils/server/errors.js.map +0 -1
- package/lib/utils/server/genericJsonServer.d.ts +0 -13
- package/lib/utils/server/genericJsonServer.js +0 -32
- package/lib/utils/server/genericJsonServer.js.map +0 -1
- package/lib/utils/server/registerRoute.d.ts +0 -3
- package/lib/utils/server/registerRoute.js +0 -13
- package/lib/utils/server/registerRoute.js.map +0 -1
- package/lib/utils/server/types.d.ts +0 -22
- package/lib/utils/server/types.js +0 -2
- package/lib/utils/server/types.js.map +0 -1
- /package/lib/utils/{client/httpStatusCode.d.ts → httpStatusCode.d.ts} +0 -0
- /package/lib/utils/{client/httpStatusCode.js → httpStatusCode.js} +0 -0
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import { ChainForkConfig } from "@lodestar/config";
|
|
2
2
|
import { phase0 } from "@lodestar/types";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import { RoutesData, ReturnTypes } from "../../../utils/index.js";
|
|
3
|
+
import { Endpoint, RouteDefinitions } from "../../../utils/types.js";
|
|
4
|
+
import { EmptyArgs, EmptyMeta, EmptyRequest } from "../../../utils/codecs.js";
|
|
6
5
|
import * as block from "./block.js";
|
|
7
6
|
import * as pool from "./pool.js";
|
|
8
7
|
import * as state from "./state.js";
|
|
@@ -10,591 +9,10 @@ import * as rewards from "./rewards.js";
|
|
|
10
9
|
export { block, pool, state, rewards };
|
|
11
10
|
export { BroadcastValidation } from "./block.js";
|
|
12
11
|
export type { BlockId, BlockHeaderResponse } from "./block.js";
|
|
13
|
-
export type { AttestationFilters } from "./pool.js";
|
|
14
12
|
export type { BlockRewards, AttestationsRewards, IdealAttestationsReward, TotalAttestationsReward, SyncCommitteeRewards, } from "./rewards.js";
|
|
15
|
-
export type { StateId, ValidatorId, ValidatorStatus,
|
|
16
|
-
export type
|
|
17
|
-
getGenesis
|
|
18
|
-
[HttpStatusCode.OK]: {
|
|
19
|
-
data: phase0.Genesis;
|
|
20
|
-
};
|
|
21
|
-
}>>;
|
|
13
|
+
export type { StateId, ValidatorId, ValidatorStatus, FinalityCheckpoints, ValidatorResponse, ValidatorBalance, EpochCommitteeResponse, EpochSyncCommitteeResponse, } from "./state.js";
|
|
14
|
+
export type Endpoints = block.Endpoints & pool.Endpoints & state.Endpoints & rewards.Endpoints & {
|
|
15
|
+
getGenesis: Endpoint<"GET", EmptyArgs, EmptyRequest, phase0.Genesis, EmptyMeta>;
|
|
22
16
|
};
|
|
23
|
-
export declare
|
|
24
|
-
export type ReqTypes = {
|
|
25
|
-
[K in keyof ReturnType<typeof getReqSerializers>]: ReturnType<ReturnType<typeof getReqSerializers>[K]["writeReq"]>;
|
|
26
|
-
};
|
|
27
|
-
export declare function getReqSerializers(config: ChainForkConfig): {
|
|
28
|
-
getBlockRewards: import("../../../utils/types.js").ReqSerializer<(blockId: block.BlockId) => Promise<ApiClientResponse<{
|
|
29
|
-
200: {
|
|
30
|
-
data: rewards.BlockRewards;
|
|
31
|
-
executionOptimistic: boolean;
|
|
32
|
-
finalized: boolean;
|
|
33
|
-
};
|
|
34
|
-
}, HttpStatusCode.BAD_REQUEST | HttpStatusCode.NOT_FOUND>>, {
|
|
35
|
-
params: {
|
|
36
|
-
block_id: string;
|
|
37
|
-
};
|
|
38
|
-
}>;
|
|
39
|
-
getAttestationsRewards: import("../../../utils/types.js").ReqSerializer<(epoch: number, validatorIds?: state.ValidatorId[] | undefined) => Promise<ApiClientResponse<{
|
|
40
|
-
200: {
|
|
41
|
-
data: rewards.AttestationsRewards;
|
|
42
|
-
executionOptimistic: boolean;
|
|
43
|
-
finalized: boolean;
|
|
44
|
-
};
|
|
45
|
-
}, HttpStatusCode.BAD_REQUEST | HttpStatusCode.NOT_FOUND>>, {
|
|
46
|
-
params: {
|
|
47
|
-
epoch: number;
|
|
48
|
-
};
|
|
49
|
-
body: state.ValidatorId[];
|
|
50
|
-
}>;
|
|
51
|
-
getSyncCommitteeRewards: import("../../../utils/types.js").ReqSerializer<(blockId: block.BlockId, validatorIds?: state.ValidatorId[] | undefined) => Promise<ApiClientResponse<{
|
|
52
|
-
200: {
|
|
53
|
-
data: rewards.SyncCommitteeRewards;
|
|
54
|
-
executionOptimistic: boolean;
|
|
55
|
-
finalized: boolean;
|
|
56
|
-
};
|
|
57
|
-
}, HttpStatusCode.BAD_REQUEST | HttpStatusCode.NOT_FOUND>>, {
|
|
58
|
-
params: {
|
|
59
|
-
block_id: string;
|
|
60
|
-
};
|
|
61
|
-
body: state.ValidatorId[];
|
|
62
|
-
}>;
|
|
63
|
-
getStateRoot: import("../../../utils/types.js").ReqSerializer<(stateId: state.StateId) => Promise<ApiClientResponse<{
|
|
64
|
-
200: {
|
|
65
|
-
data: {
|
|
66
|
-
root: Uint8Array;
|
|
67
|
-
};
|
|
68
|
-
executionOptimistic: boolean;
|
|
69
|
-
finalized: boolean;
|
|
70
|
-
};
|
|
71
|
-
}, HttpStatusCode.BAD_REQUEST | HttpStatusCode.NOT_FOUND>>, {
|
|
72
|
-
params: {
|
|
73
|
-
state_id: string;
|
|
74
|
-
};
|
|
75
|
-
}>;
|
|
76
|
-
getStateFork: import("../../../utils/types.js").ReqSerializer<(stateId: state.StateId) => Promise<ApiClientResponse<{
|
|
77
|
-
200: {
|
|
78
|
-
data: import("@chainsafe/ssz").ValueOfFields<{
|
|
79
|
-
previousVersion: import("@chainsafe/ssz").ByteVectorType;
|
|
80
|
-
currentVersion: import("@chainsafe/ssz").ByteVectorType;
|
|
81
|
-
epoch: import("@chainsafe/ssz").UintNumberType;
|
|
82
|
-
}>;
|
|
83
|
-
executionOptimistic: boolean;
|
|
84
|
-
finalized: boolean;
|
|
85
|
-
};
|
|
86
|
-
}, HttpStatusCode.BAD_REQUEST | HttpStatusCode.NOT_FOUND>>, {
|
|
87
|
-
params: {
|
|
88
|
-
state_id: string;
|
|
89
|
-
};
|
|
90
|
-
}>;
|
|
91
|
-
getStateRandao: import("../../../utils/types.js").ReqSerializer<(stateId: state.StateId, epoch?: number | undefined) => Promise<ApiClientResponse<{
|
|
92
|
-
200: {
|
|
93
|
-
data: {
|
|
94
|
-
randao: Uint8Array;
|
|
95
|
-
};
|
|
96
|
-
executionOptimistic: boolean;
|
|
97
|
-
finalized: boolean;
|
|
98
|
-
};
|
|
99
|
-
}, HttpStatusCode.BAD_REQUEST | HttpStatusCode.NOT_FOUND>>, {
|
|
100
|
-
params: {
|
|
101
|
-
state_id: state.StateId;
|
|
102
|
-
};
|
|
103
|
-
query: {
|
|
104
|
-
epoch?: number | undefined;
|
|
105
|
-
};
|
|
106
|
-
}>;
|
|
107
|
-
getStateFinalityCheckpoints: import("../../../utils/types.js").ReqSerializer<(stateId: state.StateId) => Promise<ApiClientResponse<{
|
|
108
|
-
200: {
|
|
109
|
-
data: state.FinalityCheckpoints;
|
|
110
|
-
executionOptimistic: boolean;
|
|
111
|
-
finalized: boolean;
|
|
112
|
-
};
|
|
113
|
-
}, HttpStatusCode.BAD_REQUEST | HttpStatusCode.NOT_FOUND>>, {
|
|
114
|
-
params: {
|
|
115
|
-
state_id: string;
|
|
116
|
-
};
|
|
117
|
-
}>;
|
|
118
|
-
getStateValidators: import("../../../utils/types.js").ReqSerializer<(stateId: state.StateId, filters?: state.ValidatorFilters | undefined) => Promise<ApiClientResponse<{
|
|
119
|
-
200: {
|
|
120
|
-
data: state.ValidatorResponse[];
|
|
121
|
-
executionOptimistic: boolean;
|
|
122
|
-
finalized: boolean;
|
|
123
|
-
};
|
|
124
|
-
}, HttpStatusCode.BAD_REQUEST | HttpStatusCode.NOT_FOUND>>, {
|
|
125
|
-
params: {
|
|
126
|
-
state_id: state.StateId;
|
|
127
|
-
};
|
|
128
|
-
query: {
|
|
129
|
-
id?: state.ValidatorId[] | undefined;
|
|
130
|
-
status?: state.ValidatorStatus[] | undefined;
|
|
131
|
-
};
|
|
132
|
-
}>;
|
|
133
|
-
postStateValidators: import("../../../utils/types.js").ReqSerializer<(stateId: state.StateId, filters?: state.ValidatorFilters | undefined) => Promise<ApiClientResponse<{
|
|
134
|
-
200: {
|
|
135
|
-
data: state.ValidatorResponse[];
|
|
136
|
-
executionOptimistic: boolean;
|
|
137
|
-
finalized: boolean;
|
|
138
|
-
};
|
|
139
|
-
}, HttpStatusCode.BAD_REQUEST | HttpStatusCode.NOT_FOUND>>, {
|
|
140
|
-
params: {
|
|
141
|
-
state_id: state.StateId;
|
|
142
|
-
};
|
|
143
|
-
body: {
|
|
144
|
-
ids?: string[] | undefined;
|
|
145
|
-
statuses?: state.ValidatorStatus[] | undefined;
|
|
146
|
-
};
|
|
147
|
-
}>;
|
|
148
|
-
getStateValidator: import("../../../utils/types.js").ReqSerializer<(stateId: state.StateId, validatorId: state.ValidatorId) => Promise<ApiClientResponse<{
|
|
149
|
-
200: {
|
|
150
|
-
data: state.ValidatorResponse;
|
|
151
|
-
executionOptimistic: boolean;
|
|
152
|
-
finalized: boolean;
|
|
153
|
-
};
|
|
154
|
-
}, HttpStatusCode.BAD_REQUEST | HttpStatusCode.NOT_FOUND>>, {
|
|
155
|
-
params: {
|
|
156
|
-
state_id: state.StateId;
|
|
157
|
-
validator_id: state.ValidatorId;
|
|
158
|
-
};
|
|
159
|
-
}>;
|
|
160
|
-
getStateValidatorBalances: import("../../../utils/types.js").ReqSerializer<(stateId: state.StateId, indices?: state.ValidatorId[] | undefined) => Promise<ApiClientResponse<{
|
|
161
|
-
200: {
|
|
162
|
-
data: state.ValidatorBalance[];
|
|
163
|
-
executionOptimistic: boolean;
|
|
164
|
-
finalized: boolean;
|
|
165
|
-
};
|
|
166
|
-
}, HttpStatusCode.BAD_REQUEST>>, {
|
|
167
|
-
params: {
|
|
168
|
-
state_id: state.StateId;
|
|
169
|
-
};
|
|
170
|
-
query: {
|
|
171
|
-
id?: state.ValidatorId[] | undefined;
|
|
172
|
-
};
|
|
173
|
-
}>;
|
|
174
|
-
postStateValidatorBalances: import("../../../utils/types.js").ReqSerializer<(stateId: state.StateId, indices?: state.ValidatorId[] | undefined) => Promise<ApiClientResponse<{
|
|
175
|
-
200: {
|
|
176
|
-
data: state.ValidatorBalance[];
|
|
177
|
-
executionOptimistic: boolean;
|
|
178
|
-
finalized: boolean;
|
|
179
|
-
};
|
|
180
|
-
}, HttpStatusCode.BAD_REQUEST>>, {
|
|
181
|
-
params: {
|
|
182
|
-
state_id: state.StateId;
|
|
183
|
-
};
|
|
184
|
-
body?: string[] | undefined;
|
|
185
|
-
}>;
|
|
186
|
-
getEpochCommittees: import("../../../utils/types.js").ReqSerializer<(stateId: state.StateId, filters?: state.CommitteesFilters | undefined) => Promise<ApiClientResponse<{
|
|
187
|
-
200: {
|
|
188
|
-
data: state.EpochCommitteeResponse[];
|
|
189
|
-
executionOptimistic: boolean;
|
|
190
|
-
finalized: boolean;
|
|
191
|
-
};
|
|
192
|
-
}, HttpStatusCode.BAD_REQUEST | HttpStatusCode.NOT_FOUND>>, {
|
|
193
|
-
params: {
|
|
194
|
-
state_id: state.StateId;
|
|
195
|
-
};
|
|
196
|
-
query: {
|
|
197
|
-
slot?: number | undefined;
|
|
198
|
-
epoch?: number | undefined;
|
|
199
|
-
index?: number | undefined;
|
|
200
|
-
};
|
|
201
|
-
}>;
|
|
202
|
-
getEpochSyncCommittees: import("../../../utils/types.js").ReqSerializer<(stateId: state.StateId, epoch?: number | undefined) => Promise<ApiClientResponse<{
|
|
203
|
-
200: {
|
|
204
|
-
data: state.EpochSyncCommitteeResponse;
|
|
205
|
-
executionOptimistic: boolean;
|
|
206
|
-
finalized: boolean;
|
|
207
|
-
};
|
|
208
|
-
}, HttpStatusCode.BAD_REQUEST | HttpStatusCode.NOT_FOUND>>, {
|
|
209
|
-
params: {
|
|
210
|
-
state_id: state.StateId;
|
|
211
|
-
};
|
|
212
|
-
query: {
|
|
213
|
-
epoch?: number | undefined;
|
|
214
|
-
};
|
|
215
|
-
}>;
|
|
216
|
-
getPoolAttestations: import("../../../utils/types.js").ReqSerializer<(filters?: Partial<pool.AttestationFilters> | undefined) => Promise<ApiClientResponse<{
|
|
217
|
-
200: {
|
|
218
|
-
data: import("@chainsafe/ssz").ValueOfFields<{
|
|
219
|
-
aggregationBits: import("@chainsafe/ssz").BitListType;
|
|
220
|
-
data: import("@chainsafe/ssz").ContainerType<{
|
|
221
|
-
slot: import("@chainsafe/ssz").UintNumberType;
|
|
222
|
-
index: import("@chainsafe/ssz").UintNumberType;
|
|
223
|
-
beaconBlockRoot: import("@chainsafe/ssz").ByteVectorType;
|
|
224
|
-
source: import("@chainsafe/ssz").ContainerType<{
|
|
225
|
-
epoch: import("@chainsafe/ssz").UintNumberType;
|
|
226
|
-
root: import("@chainsafe/ssz").ByteVectorType;
|
|
227
|
-
}>;
|
|
228
|
-
target: import("@chainsafe/ssz").ContainerType<{
|
|
229
|
-
epoch: import("@chainsafe/ssz").UintNumberType;
|
|
230
|
-
root: import("@chainsafe/ssz").ByteVectorType;
|
|
231
|
-
}>;
|
|
232
|
-
}>;
|
|
233
|
-
signature: import("@chainsafe/ssz").ByteVectorType;
|
|
234
|
-
}>[];
|
|
235
|
-
};
|
|
236
|
-
}, HttpStatusCode.BAD_REQUEST>>, {
|
|
237
|
-
query: {
|
|
238
|
-
slot?: number | undefined;
|
|
239
|
-
committee_index?: number | undefined;
|
|
240
|
-
};
|
|
241
|
-
}>;
|
|
242
|
-
getPoolAttesterSlashings: import("../../../utils/types.js").ReqSerializer<() => Promise<ApiClientResponse<{
|
|
243
|
-
200: {
|
|
244
|
-
data: import("@chainsafe/ssz").ValueOfFields<{
|
|
245
|
-
attestation1: import("@chainsafe/ssz").ContainerType<{
|
|
246
|
-
attestingIndices: import("@chainsafe/ssz").ListBasicType<import("@chainsafe/ssz").UintNumberType>;
|
|
247
|
-
data: import("@chainsafe/ssz").ContainerType<{
|
|
248
|
-
slot: import("@chainsafe/ssz").UintBigintType;
|
|
249
|
-
index: import("@chainsafe/ssz").UintBigintType;
|
|
250
|
-
beaconBlockRoot: import("@chainsafe/ssz").ByteVectorType;
|
|
251
|
-
source: import("@chainsafe/ssz").ContainerType<{
|
|
252
|
-
epoch: import("@chainsafe/ssz").UintBigintType;
|
|
253
|
-
root: import("@chainsafe/ssz").ByteVectorType;
|
|
254
|
-
}>;
|
|
255
|
-
target: import("@chainsafe/ssz").ContainerType<{
|
|
256
|
-
epoch: import("@chainsafe/ssz").UintBigintType;
|
|
257
|
-
root: import("@chainsafe/ssz").ByteVectorType;
|
|
258
|
-
}>;
|
|
259
|
-
}>;
|
|
260
|
-
signature: import("@chainsafe/ssz").ByteVectorType;
|
|
261
|
-
}>;
|
|
262
|
-
attestation2: import("@chainsafe/ssz").ContainerType<{
|
|
263
|
-
attestingIndices: import("@chainsafe/ssz").ListBasicType<import("@chainsafe/ssz").UintNumberType>;
|
|
264
|
-
data: import("@chainsafe/ssz").ContainerType<{
|
|
265
|
-
slot: import("@chainsafe/ssz").UintBigintType;
|
|
266
|
-
index: import("@chainsafe/ssz").UintBigintType;
|
|
267
|
-
beaconBlockRoot: import("@chainsafe/ssz").ByteVectorType;
|
|
268
|
-
source: import("@chainsafe/ssz").ContainerType<{
|
|
269
|
-
epoch: import("@chainsafe/ssz").UintBigintType;
|
|
270
|
-
root: import("@chainsafe/ssz").ByteVectorType;
|
|
271
|
-
}>;
|
|
272
|
-
target: import("@chainsafe/ssz").ContainerType<{
|
|
273
|
-
epoch: import("@chainsafe/ssz").UintBigintType;
|
|
274
|
-
root: import("@chainsafe/ssz").ByteVectorType;
|
|
275
|
-
}>;
|
|
276
|
-
}>;
|
|
277
|
-
signature: import("@chainsafe/ssz").ByteVectorType;
|
|
278
|
-
}>;
|
|
279
|
-
}>[];
|
|
280
|
-
};
|
|
281
|
-
}>>, import("../../../utils/types.js").ReqGeneric>;
|
|
282
|
-
getPoolProposerSlashings: import("../../../utils/types.js").ReqSerializer<() => Promise<ApiClientResponse<{
|
|
283
|
-
200: {
|
|
284
|
-
data: import("@chainsafe/ssz").ValueOfFields<{
|
|
285
|
-
signedHeader1: import("@chainsafe/ssz").ContainerType<{
|
|
286
|
-
message: import("@chainsafe/ssz").ContainerType<{
|
|
287
|
-
slot: import("@chainsafe/ssz").UintBigintType;
|
|
288
|
-
proposerIndex: import("@chainsafe/ssz").UintNumberType;
|
|
289
|
-
parentRoot: import("@chainsafe/ssz").ByteVectorType;
|
|
290
|
-
stateRoot: import("@chainsafe/ssz").ByteVectorType;
|
|
291
|
-
bodyRoot: import("@chainsafe/ssz").ByteVectorType;
|
|
292
|
-
}>;
|
|
293
|
-
signature: import("@chainsafe/ssz").ByteVectorType;
|
|
294
|
-
}>;
|
|
295
|
-
signedHeader2: import("@chainsafe/ssz").ContainerType<{
|
|
296
|
-
message: import("@chainsafe/ssz").ContainerType<{
|
|
297
|
-
slot: import("@chainsafe/ssz").UintBigintType;
|
|
298
|
-
proposerIndex: import("@chainsafe/ssz").UintNumberType;
|
|
299
|
-
parentRoot: import("@chainsafe/ssz").ByteVectorType;
|
|
300
|
-
stateRoot: import("@chainsafe/ssz").ByteVectorType;
|
|
301
|
-
bodyRoot: import("@chainsafe/ssz").ByteVectorType;
|
|
302
|
-
}>;
|
|
303
|
-
signature: import("@chainsafe/ssz").ByteVectorType;
|
|
304
|
-
}>;
|
|
305
|
-
}>[];
|
|
306
|
-
};
|
|
307
|
-
}>>, import("../../../utils/types.js").ReqGeneric>;
|
|
308
|
-
getPoolVoluntaryExits: import("../../../utils/types.js").ReqSerializer<() => Promise<ApiClientResponse<{
|
|
309
|
-
200: {
|
|
310
|
-
data: import("@chainsafe/ssz").ValueOfFields<{
|
|
311
|
-
message: import("@chainsafe/ssz").ContainerType<{
|
|
312
|
-
epoch: import("@chainsafe/ssz").UintNumberType;
|
|
313
|
-
validatorIndex: import("@chainsafe/ssz").UintNumberType;
|
|
314
|
-
}>;
|
|
315
|
-
signature: import("@chainsafe/ssz").ByteVectorType;
|
|
316
|
-
}>[];
|
|
317
|
-
};
|
|
318
|
-
}>>, import("../../../utils/types.js").ReqGeneric>;
|
|
319
|
-
getPoolBlsToExecutionChanges: import("../../../utils/types.js").ReqSerializer<() => Promise<ApiClientResponse<{
|
|
320
|
-
200: {
|
|
321
|
-
data: import("@chainsafe/ssz").ValueOfFields<{
|
|
322
|
-
message: import("@chainsafe/ssz").ContainerType<{
|
|
323
|
-
validatorIndex: import("@chainsafe/ssz").UintNumberType;
|
|
324
|
-
fromBlsPubkey: import("@chainsafe/ssz").ByteVectorType;
|
|
325
|
-
toExecutionAddress: import("@lodestar/types/lib/utils/executionAddress.js").ExecutionAddressType;
|
|
326
|
-
}>;
|
|
327
|
-
signature: import("@chainsafe/ssz").ByteVectorType;
|
|
328
|
-
}>[];
|
|
329
|
-
};
|
|
330
|
-
}>>, import("../../../utils/types.js").ReqGeneric>;
|
|
331
|
-
submitPoolAttestations: import("../../../utils/types.js").ReqSerializer<(attestations: import("@chainsafe/ssz").ValueOfFields<{
|
|
332
|
-
aggregationBits: import("@chainsafe/ssz").BitListType;
|
|
333
|
-
data: import("@chainsafe/ssz").ContainerType<{
|
|
334
|
-
slot: import("@chainsafe/ssz").UintNumberType;
|
|
335
|
-
index: import("@chainsafe/ssz").UintNumberType;
|
|
336
|
-
beaconBlockRoot: import("@chainsafe/ssz").ByteVectorType;
|
|
337
|
-
source: import("@chainsafe/ssz").ContainerType<{
|
|
338
|
-
epoch: import("@chainsafe/ssz").UintNumberType;
|
|
339
|
-
root: import("@chainsafe/ssz").ByteVectorType;
|
|
340
|
-
}>;
|
|
341
|
-
target: import("@chainsafe/ssz").ContainerType<{
|
|
342
|
-
epoch: import("@chainsafe/ssz").UintNumberType;
|
|
343
|
-
root: import("@chainsafe/ssz").ByteVectorType;
|
|
344
|
-
}>;
|
|
345
|
-
}>;
|
|
346
|
-
signature: import("@chainsafe/ssz").ByteVectorType;
|
|
347
|
-
}>[]) => Promise<ApiClientResponse<{
|
|
348
|
-
200: void;
|
|
349
|
-
}, HttpStatusCode.BAD_REQUEST>>, {
|
|
350
|
-
body: unknown;
|
|
351
|
-
}>;
|
|
352
|
-
submitPoolAttesterSlashings: import("../../../utils/types.js").ReqSerializer<(slashing: import("@chainsafe/ssz").ValueOfFields<{
|
|
353
|
-
attestation1: import("@chainsafe/ssz").ContainerType<{
|
|
354
|
-
attestingIndices: import("@chainsafe/ssz").ListBasicType<import("@chainsafe/ssz").UintNumberType>;
|
|
355
|
-
data: import("@chainsafe/ssz").ContainerType<{
|
|
356
|
-
slot: import("@chainsafe/ssz").UintBigintType;
|
|
357
|
-
index: import("@chainsafe/ssz").UintBigintType;
|
|
358
|
-
beaconBlockRoot: import("@chainsafe/ssz").ByteVectorType;
|
|
359
|
-
source: import("@chainsafe/ssz").ContainerType<{
|
|
360
|
-
epoch: import("@chainsafe/ssz").UintBigintType;
|
|
361
|
-
root: import("@chainsafe/ssz").ByteVectorType;
|
|
362
|
-
}>;
|
|
363
|
-
target: import("@chainsafe/ssz").ContainerType<{
|
|
364
|
-
epoch: import("@chainsafe/ssz").UintBigintType;
|
|
365
|
-
root: import("@chainsafe/ssz").ByteVectorType;
|
|
366
|
-
}>;
|
|
367
|
-
}>;
|
|
368
|
-
signature: import("@chainsafe/ssz").ByteVectorType;
|
|
369
|
-
}>;
|
|
370
|
-
attestation2: import("@chainsafe/ssz").ContainerType<{
|
|
371
|
-
attestingIndices: import("@chainsafe/ssz").ListBasicType<import("@chainsafe/ssz").UintNumberType>;
|
|
372
|
-
data: import("@chainsafe/ssz").ContainerType<{
|
|
373
|
-
slot: import("@chainsafe/ssz").UintBigintType;
|
|
374
|
-
index: import("@chainsafe/ssz").UintBigintType;
|
|
375
|
-
beaconBlockRoot: import("@chainsafe/ssz").ByteVectorType;
|
|
376
|
-
source: import("@chainsafe/ssz").ContainerType<{
|
|
377
|
-
epoch: import("@chainsafe/ssz").UintBigintType;
|
|
378
|
-
root: import("@chainsafe/ssz").ByteVectorType;
|
|
379
|
-
}>;
|
|
380
|
-
target: import("@chainsafe/ssz").ContainerType<{
|
|
381
|
-
epoch: import("@chainsafe/ssz").UintBigintType;
|
|
382
|
-
root: import("@chainsafe/ssz").ByteVectorType;
|
|
383
|
-
}>;
|
|
384
|
-
}>;
|
|
385
|
-
signature: import("@chainsafe/ssz").ByteVectorType;
|
|
386
|
-
}>;
|
|
387
|
-
}>) => Promise<ApiClientResponse<{
|
|
388
|
-
200: void;
|
|
389
|
-
}, HttpStatusCode.BAD_REQUEST>>, {
|
|
390
|
-
body: unknown;
|
|
391
|
-
}>;
|
|
392
|
-
submitPoolProposerSlashings: import("../../../utils/types.js").ReqSerializer<(slashing: import("@chainsafe/ssz").ValueOfFields<{
|
|
393
|
-
signedHeader1: import("@chainsafe/ssz").ContainerType<{
|
|
394
|
-
message: import("@chainsafe/ssz").ContainerType<{
|
|
395
|
-
slot: import("@chainsafe/ssz").UintBigintType;
|
|
396
|
-
proposerIndex: import("@chainsafe/ssz").UintNumberType;
|
|
397
|
-
parentRoot: import("@chainsafe/ssz").ByteVectorType;
|
|
398
|
-
stateRoot: import("@chainsafe/ssz").ByteVectorType;
|
|
399
|
-
bodyRoot: import("@chainsafe/ssz").ByteVectorType;
|
|
400
|
-
}>;
|
|
401
|
-
signature: import("@chainsafe/ssz").ByteVectorType;
|
|
402
|
-
}>;
|
|
403
|
-
signedHeader2: import("@chainsafe/ssz").ContainerType<{
|
|
404
|
-
message: import("@chainsafe/ssz").ContainerType<{
|
|
405
|
-
slot: import("@chainsafe/ssz").UintBigintType;
|
|
406
|
-
proposerIndex: import("@chainsafe/ssz").UintNumberType;
|
|
407
|
-
parentRoot: import("@chainsafe/ssz").ByteVectorType;
|
|
408
|
-
stateRoot: import("@chainsafe/ssz").ByteVectorType;
|
|
409
|
-
bodyRoot: import("@chainsafe/ssz").ByteVectorType;
|
|
410
|
-
}>;
|
|
411
|
-
signature: import("@chainsafe/ssz").ByteVectorType;
|
|
412
|
-
}>;
|
|
413
|
-
}>) => Promise<ApiClientResponse<{
|
|
414
|
-
200: void;
|
|
415
|
-
}, HttpStatusCode.BAD_REQUEST>>, {
|
|
416
|
-
body: unknown;
|
|
417
|
-
}>;
|
|
418
|
-
submitPoolVoluntaryExit: import("../../../utils/types.js").ReqSerializer<(exit: import("@chainsafe/ssz").ValueOfFields<{
|
|
419
|
-
message: import("@chainsafe/ssz").ContainerType<{
|
|
420
|
-
epoch: import("@chainsafe/ssz").UintNumberType;
|
|
421
|
-
validatorIndex: import("@chainsafe/ssz").UintNumberType;
|
|
422
|
-
}>;
|
|
423
|
-
signature: import("@chainsafe/ssz").ByteVectorType;
|
|
424
|
-
}>) => Promise<ApiClientResponse<{
|
|
425
|
-
200: void;
|
|
426
|
-
}, HttpStatusCode.BAD_REQUEST>>, {
|
|
427
|
-
body: unknown;
|
|
428
|
-
}>;
|
|
429
|
-
submitPoolBlsToExecutionChange: import("../../../utils/types.js").ReqSerializer<(blsToExecutionChange: import("@chainsafe/ssz").ValueOfFields<{
|
|
430
|
-
message: import("@chainsafe/ssz").ContainerType<{
|
|
431
|
-
validatorIndex: import("@chainsafe/ssz").UintNumberType;
|
|
432
|
-
fromBlsPubkey: import("@chainsafe/ssz").ByteVectorType;
|
|
433
|
-
toExecutionAddress: import("@lodestar/types/lib/utils/executionAddress.js").ExecutionAddressType;
|
|
434
|
-
}>;
|
|
435
|
-
signature: import("@chainsafe/ssz").ByteVectorType;
|
|
436
|
-
}>[]) => Promise<ApiClientResponse<{
|
|
437
|
-
200: void;
|
|
438
|
-
}, HttpStatusCode.BAD_REQUEST>>, {
|
|
439
|
-
body: unknown;
|
|
440
|
-
}>;
|
|
441
|
-
submitPoolSyncCommitteeSignatures: import("../../../utils/types.js").ReqSerializer<(signatures: import("@chainsafe/ssz").ValueOfFields<{
|
|
442
|
-
slot: import("@chainsafe/ssz").UintNumberType;
|
|
443
|
-
beaconBlockRoot: import("@chainsafe/ssz").ByteVectorType;
|
|
444
|
-
validatorIndex: import("@chainsafe/ssz").UintNumberType;
|
|
445
|
-
signature: import("@chainsafe/ssz").ByteVectorType;
|
|
446
|
-
}>[]) => Promise<ApiClientResponse<{
|
|
447
|
-
200: void;
|
|
448
|
-
}, HttpStatusCode.BAD_REQUEST>>, {
|
|
449
|
-
body: unknown;
|
|
450
|
-
}>;
|
|
451
|
-
getBlock: import("../../../utils/types.js").ReqSerializer<(<T extends import("../../../interfaces.js").ResponseFormat = "json">(blockId: block.BlockId, format?: T | undefined) => Promise<block.BlockResponse<T>>), {
|
|
452
|
-
params: {
|
|
453
|
-
block_id: string;
|
|
454
|
-
};
|
|
455
|
-
headers: {
|
|
456
|
-
accept?: string | undefined;
|
|
457
|
-
};
|
|
458
|
-
}>;
|
|
459
|
-
getBlockV2: import("../../../utils/types.js").ReqSerializer<(<T_1 extends import("../../../interfaces.js").ResponseFormat = "json">(blockId: block.BlockId, format?: T_1 | undefined) => Promise<block.BlockV2Response<T_1>>), {
|
|
460
|
-
params: {
|
|
461
|
-
block_id: string;
|
|
462
|
-
};
|
|
463
|
-
headers: {
|
|
464
|
-
accept?: string | undefined;
|
|
465
|
-
};
|
|
466
|
-
}>;
|
|
467
|
-
getBlockAttestations: import("../../../utils/types.js").ReqSerializer<(blockId: block.BlockId) => Promise<ApiClientResponse<{
|
|
468
|
-
200: {
|
|
469
|
-
data: import("@chainsafe/ssz").ValueOfFields<{
|
|
470
|
-
aggregationBits: import("@chainsafe/ssz").BitListType;
|
|
471
|
-
data: import("@chainsafe/ssz").ContainerType<{
|
|
472
|
-
slot: import("@chainsafe/ssz").UintNumberType;
|
|
473
|
-
index: import("@chainsafe/ssz").UintNumberType;
|
|
474
|
-
beaconBlockRoot: import("@chainsafe/ssz").ByteVectorType;
|
|
475
|
-
source: import("@chainsafe/ssz").ContainerType<{
|
|
476
|
-
epoch: import("@chainsafe/ssz").UintNumberType;
|
|
477
|
-
root: import("@chainsafe/ssz").ByteVectorType;
|
|
478
|
-
}>;
|
|
479
|
-
target: import("@chainsafe/ssz").ContainerType<{
|
|
480
|
-
epoch: import("@chainsafe/ssz").UintNumberType;
|
|
481
|
-
root: import("@chainsafe/ssz").ByteVectorType;
|
|
482
|
-
}>;
|
|
483
|
-
}>;
|
|
484
|
-
signature: import("@chainsafe/ssz").ByteVectorType;
|
|
485
|
-
}>[];
|
|
486
|
-
executionOptimistic: boolean;
|
|
487
|
-
finalized: boolean;
|
|
488
|
-
};
|
|
489
|
-
}, HttpStatusCode.BAD_REQUEST | HttpStatusCode.NOT_FOUND>>, {
|
|
490
|
-
params: {
|
|
491
|
-
block_id: string;
|
|
492
|
-
};
|
|
493
|
-
}>;
|
|
494
|
-
getBlockHeader: import("../../../utils/types.js").ReqSerializer<(blockId: block.BlockId) => Promise<ApiClientResponse<{
|
|
495
|
-
200: {
|
|
496
|
-
data: block.BlockHeaderResponse;
|
|
497
|
-
executionOptimistic: boolean;
|
|
498
|
-
finalized: boolean;
|
|
499
|
-
};
|
|
500
|
-
}, HttpStatusCode.BAD_REQUEST | HttpStatusCode.NOT_FOUND>>, {
|
|
501
|
-
params: {
|
|
502
|
-
block_id: string;
|
|
503
|
-
};
|
|
504
|
-
}>;
|
|
505
|
-
getBlockHeaders: import("../../../utils/types.js").ReqSerializer<(filters: Partial<{
|
|
506
|
-
slot: number;
|
|
507
|
-
parentRoot: string;
|
|
508
|
-
}>) => Promise<ApiClientResponse<{
|
|
509
|
-
200: {
|
|
510
|
-
data: block.BlockHeaderResponse[];
|
|
511
|
-
executionOptimistic: boolean;
|
|
512
|
-
finalized: boolean;
|
|
513
|
-
};
|
|
514
|
-
}, HttpStatusCode.BAD_REQUEST>>, {
|
|
515
|
-
query: {
|
|
516
|
-
slot?: number | undefined;
|
|
517
|
-
parent_root?: string | undefined;
|
|
518
|
-
};
|
|
519
|
-
}>;
|
|
520
|
-
getBlockRoot: import("../../../utils/types.js").ReqSerializer<(blockId: block.BlockId) => Promise<ApiClientResponse<{
|
|
521
|
-
200: {
|
|
522
|
-
data: {
|
|
523
|
-
root: Uint8Array;
|
|
524
|
-
};
|
|
525
|
-
executionOptimistic: boolean;
|
|
526
|
-
finalized: boolean;
|
|
527
|
-
};
|
|
528
|
-
}, HttpStatusCode.BAD_REQUEST | HttpStatusCode.NOT_FOUND>>, {
|
|
529
|
-
params: {
|
|
530
|
-
block_id: string;
|
|
531
|
-
};
|
|
532
|
-
}>;
|
|
533
|
-
publishBlock: import("../../../utils/types.js").ReqSerializer<(blockOrContents: import("@lodestar/types/lib/allForks/types.js").SignedBeaconBlockOrContents) => Promise<ApiClientResponse<{
|
|
534
|
-
200: void;
|
|
535
|
-
202: void;
|
|
536
|
-
}, HttpStatusCode.BAD_REQUEST | HttpStatusCode.SERVICE_UNAVAILABLE>>, {
|
|
537
|
-
body: unknown;
|
|
538
|
-
}>;
|
|
539
|
-
publishBlockV2: import("../../../utils/types.js").ReqSerializer<(blockOrContents: import("@lodestar/types/lib/allForks/types.js").SignedBeaconBlockOrContents, opts?: {
|
|
540
|
-
broadcastValidation?: block.BroadcastValidation | undefined;
|
|
541
|
-
} | undefined) => Promise<ApiClientResponse<{
|
|
542
|
-
200: void;
|
|
543
|
-
202: void;
|
|
544
|
-
}, HttpStatusCode.BAD_REQUEST | HttpStatusCode.SERVICE_UNAVAILABLE>>, {
|
|
545
|
-
body: unknown;
|
|
546
|
-
query: {
|
|
547
|
-
broadcast_validation?: string | undefined;
|
|
548
|
-
};
|
|
549
|
-
}>;
|
|
550
|
-
publishBlindedBlock: import("../../../utils/types.js").ReqSerializer<(blindedBlock: import("@lodestar/types/lib/allForks/types.js").SignedBlindedBeaconBlock) => Promise<ApiClientResponse<{
|
|
551
|
-
200: void;
|
|
552
|
-
202: void;
|
|
553
|
-
}, HttpStatusCode.BAD_REQUEST | HttpStatusCode.SERVICE_UNAVAILABLE>>, {
|
|
554
|
-
body: unknown;
|
|
555
|
-
}>;
|
|
556
|
-
publishBlindedBlockV2: import("../../../utils/types.js").ReqSerializer<(blindedBlockOrContents: import("@lodestar/types/lib/allForks/types.js").SignedBlindedBeaconBlock, opts: {
|
|
557
|
-
broadcastValidation?: block.BroadcastValidation | undefined;
|
|
558
|
-
}) => Promise<ApiClientResponse<{
|
|
559
|
-
200: void;
|
|
560
|
-
202: void;
|
|
561
|
-
}, HttpStatusCode.BAD_REQUEST | HttpStatusCode.SERVICE_UNAVAILABLE>>, {
|
|
562
|
-
body: unknown;
|
|
563
|
-
query: {
|
|
564
|
-
broadcast_validation?: string | undefined;
|
|
565
|
-
};
|
|
566
|
-
}>;
|
|
567
|
-
getBlobSidecars: import("../../../utils/types.js").ReqSerializer<(blockId: block.BlockId, indices?: number[] | undefined) => Promise<ApiClientResponse<{
|
|
568
|
-
200: {
|
|
569
|
-
data: import("@chainsafe/ssz").ValueOfFields<{
|
|
570
|
-
index: import("@chainsafe/ssz").UintNumberType;
|
|
571
|
-
blob: import("@chainsafe/ssz").ByteVectorType;
|
|
572
|
-
kzgCommitment: import("@chainsafe/ssz").ByteVectorType;
|
|
573
|
-
kzgProof: import("@chainsafe/ssz").ByteVectorType;
|
|
574
|
-
signedBlockHeader: import("@chainsafe/ssz").ContainerType<{
|
|
575
|
-
message: import("@chainsafe/ssz").ContainerType<{
|
|
576
|
-
slot: import("@chainsafe/ssz").UintNumberType;
|
|
577
|
-
proposerIndex: import("@chainsafe/ssz").UintNumberType;
|
|
578
|
-
parentRoot: import("@chainsafe/ssz").ByteVectorType;
|
|
579
|
-
stateRoot: import("@chainsafe/ssz").ByteVectorType;
|
|
580
|
-
bodyRoot: import("@chainsafe/ssz").ByteVectorType;
|
|
581
|
-
}>;
|
|
582
|
-
signature: import("@chainsafe/ssz").ByteVectorType;
|
|
583
|
-
}>;
|
|
584
|
-
kzgCommitmentInclusionProof: import("@chainsafe/ssz").VectorCompositeType<import("@chainsafe/ssz").ByteVectorType>;
|
|
585
|
-
}>[];
|
|
586
|
-
executionOptimistic: boolean;
|
|
587
|
-
finalized: boolean;
|
|
588
|
-
};
|
|
589
|
-
}>>, {
|
|
590
|
-
params: {
|
|
591
|
-
block_id: string;
|
|
592
|
-
};
|
|
593
|
-
query: {
|
|
594
|
-
indices?: number[] | undefined;
|
|
595
|
-
};
|
|
596
|
-
}>;
|
|
597
|
-
getGenesis: import("../../../utils/types.js").ReqSerializer<() => void, import("../../../utils/types.js").ReqGeneric>;
|
|
598
|
-
};
|
|
599
|
-
export declare function getReturnTypes(): ReturnTypes<Api>;
|
|
17
|
+
export declare function getDefinitions(config: ChainForkConfig): RouteDefinitions<Endpoints>;
|
|
600
18
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1,39 +1,29 @@
|
|
|
1
1
|
import { ssz } from "@lodestar/types";
|
|
2
|
-
import {
|
|
3
|
-
import { reqEmpty, ContainerData } from "../../../utils/index.js";
|
|
2
|
+
import { EmptyRequestCodec, EmptyMetaCodec } from "../../../utils/codecs.js";
|
|
4
3
|
import * as block from "./block.js";
|
|
5
4
|
import * as pool from "./pool.js";
|
|
6
5
|
import * as state from "./state.js";
|
|
7
6
|
import * as rewards from "./rewards.js";
|
|
8
7
|
// See /packages/api/src/routes/index.ts for reasoning and instructions to add new routes
|
|
9
|
-
// NOTE: We choose to split the block, pool, and
|
|
8
|
+
// NOTE: We choose to split the block, pool, state and rewards namespaces so the files are not too big.
|
|
10
9
|
// However, for a consumer all these methods are within the same service "beacon"
|
|
11
10
|
export { block, pool, state, rewards };
|
|
12
11
|
export { BroadcastValidation } from "./block.js";
|
|
13
|
-
export
|
|
14
|
-
getGenesis: { url: "/eth/v1/beacon/genesis", method: "GET" },
|
|
15
|
-
...block.routesData,
|
|
16
|
-
...pool.routesData,
|
|
17
|
-
...state.routesData,
|
|
18
|
-
...rewards.routesData,
|
|
19
|
-
};
|
|
20
|
-
// eslint-disable-next-line @typescript-eslint/explicit-function-return-type
|
|
21
|
-
export function getReqSerializers(config) {
|
|
12
|
+
export function getDefinitions(config) {
|
|
22
13
|
return {
|
|
23
|
-
getGenesis:
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
...
|
|
34
|
-
...
|
|
35
|
-
...
|
|
36
|
-
...rewards.getReturnTypes(),
|
|
14
|
+
getGenesis: {
|
|
15
|
+
url: "/eth/v1/beacon/genesis",
|
|
16
|
+
method: "GET",
|
|
17
|
+
req: EmptyRequestCodec,
|
|
18
|
+
resp: {
|
|
19
|
+
data: ssz.phase0.Genesis,
|
|
20
|
+
meta: EmptyMetaCodec,
|
|
21
|
+
},
|
|
22
|
+
},
|
|
23
|
+
...block.getDefinitions(config),
|
|
24
|
+
...pool.getDefinitions(config),
|
|
25
|
+
...state.getDefinitions(config),
|
|
26
|
+
...rewards.getDefinitions(config),
|
|
37
27
|
};
|
|
38
28
|
}
|
|
39
29
|
//# sourceMappingURL=index.js.map
|