Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: provide first-class ssz support on api #6749

Merged
merged 292 commits into from
Jun 10, 2024
Merged
Changes from 1 commit
Commits
Show all changes
292 commits
Select commit Hold shift + click to select a range
0f03542
Add config route definitions
wemeetagain Nov 4, 2023
2d80b97
Add debug route definitions
wemeetagain Nov 5, 2023
5e5feda
Add events route description
wemeetagain Nov 5, 2023
3ecf5fb
Add lightclient route definitions
wemeetagain Nov 7, 2023
ec2d09b
Merge branch 'unstable' into cayman/ssz-api
nflaig Nov 9, 2023
94379d7
Flatten function params
nflaig Nov 9, 2023
44dd312
Type safety for optional params in write / parse req
nflaig Nov 9, 2023
592d396
Method args are optional if only optional props
nflaig Nov 9, 2023
de5249e
Fix genesisValidatorsRoot type issue
nflaig Nov 11, 2023
36e0017
Revert requiring all params in write / parse req
nflaig Nov 11, 2023
698e655
Update http client errors
nflaig Nov 18, 2023
4cf91b3
Add lodestar route definitions
wemeetagain Nov 8, 2023
1b556ff
Add node route definitions
wemeetagain Nov 20, 2023
e1bc382
Add proof route definitions
wemeetagain Nov 20, 2023
d0e82d0
Add builder route definitions
wemeetagain Nov 28, 2023
6c9379a
Add validator route definitions
wemeetagain Dec 1, 2023
f605775
Merge branch 'unstable' into cayman/ssz-api
nflaig Dec 4, 2023
f8713f1
Application method response can be void
nflaig Dec 5, 2023
645d5d5
Generic options can be passed to application methods
nflaig Dec 5, 2023
9f6ada9
Default endpoint request type has body property
nflaig Dec 5, 2023
6e8f24d
Improve types of transform methods
nflaig Dec 5, 2023
9ec57ad
Export server types from index (to be removed)
nflaig Dec 5, 2023
66c5fa3
Update config api impl
nflaig Dec 5, 2023
9656959
Update lightclient api impl
nflaig Dec 5, 2023
2249d80
Update events api impl
nflaig Dec 5, 2023
3a174f4
Update lodestar api impl
nflaig Dec 5, 2023
a9061ec
Update proof api impl
nflaig Dec 5, 2023
4d71245
Update node api impl
nflaig Dec 5, 2023
ca7efde
Update debug api impl
nflaig Dec 5, 2023
df42c15
Update state api impl
nflaig Dec 5, 2023
48efe33
Update pool api impl
nflaig Dec 5, 2023
8efa4b1
Update blocks api impl
nflaig Dec 5, 2023
895586a
Partially update validator api impl
nflaig Dec 5, 2023
6b39a0d
Update beacon routes export
nflaig Dec 5, 2023
e1964ee
Align submitPoolBlsToExecutionChange method args
nflaig Dec 5, 2023
b9c78b5
Filters are always a object
nflaig Dec 5, 2023
13b65fc
Update errors messages
nflaig Dec 5, 2023
25201d4
Merge branch 'unstable' into cayman/ssz-api
nflaig Dec 7, 2023
19c5b80
Add beacon client methods
wemeetagain Dec 8, 2023
bac340e
Merge branch 'unstable' into cayman/ssz-api
nflaig Jan 4, 2024
b5c16da
Add missing routeId label to stream time metric
nflaig Jan 4, 2024
34b624d
Fix json casing in codecs
nflaig Jan 7, 2024
ad9aaa3
Apply remaining changes from #6227
nflaig Jan 7, 2024
c470aa7
Produce block apis only have version meta
nflaig Jan 7, 2024
766a3b8
Add block values meta to all produce block apis
nflaig Jan 7, 2024
bd8ce9b
Merge branch 'unstable' into cayman/ssz-api
nflaig Jan 30, 2024
19282ff
Apply changes from #6337
nflaig Jan 30, 2024
64a5a4a
Merge branch 'unstable' into cayman/ssz-api
nflaig Jan 30, 2024
5703852
Handle unsafe version in WithMeta and WithVersion
nflaig Jan 31, 2024
4a93ae0
Restore server api error
nflaig Feb 2, 2024
d13e06e
Update fastify route types
nflaig Feb 2, 2024
ed17f09
Update server routes / handlers
nflaig Feb 2, 2024
4fa4f1b
Merge branch 'unstable' into cayman/ssz-api
nflaig Feb 2, 2024
64635d1
Remove unnecessary type cast
nflaig Feb 2, 2024
00cf670
Restore per route clients
nflaig Feb 2, 2024
0ad4a0f
Fix beacon route types
nflaig Feb 2, 2024
be3aa85
Remove option to patch fetch from http client
nflaig Feb 3, 2024
f936887
Update eventstream client, remove fetch override
nflaig Feb 3, 2024
4c7b0c9
Use StringType for validator status until #6059
nflaig Feb 3, 2024
4f3d563
Remove empty fetch.ts file
nflaig Feb 3, 2024
e39c169
Add a few todos
nflaig Feb 3, 2024
e52c5e3
Update builder client and server routes
nflaig Feb 3, 2024
ed73024
Update beacon exports
nflaig Feb 3, 2024
9ae9cc8
Update api index exports
nflaig Feb 3, 2024
41b4275
Update builder index imports
nflaig Feb 3, 2024
575a5b8
Improve type safety of schema definitions
nflaig Feb 4, 2024
5c78a7a
Add headers to fastify schema
nflaig Feb 4, 2024
7cc6cd7
Fix schema definition type
nflaig Feb 4, 2024
3301e04
Add missing schemas to route definitions
nflaig Feb 4, 2024
80c49c4
Fix response codec type
nflaig Feb 4, 2024
344601a
Remove response codec type casts
nflaig Feb 4, 2024
19865a8
Merge branch 'unstable' into cayman/ssz-api
nflaig Feb 7, 2024
fe3b848
Fix casing in json only codec
nflaig Feb 25, 2024
89d1c56
Reuse EmptyResponseCodec
nflaig Feb 25, 2024
cce5d5c
Update base rest api server
nflaig Feb 25, 2024
5a0138d
Update keymanager routes, client and server
nflaig Feb 25, 2024
ca3979d
Reuse data types in keymanager impl
nflaig Feb 26, 2024
5d12287
Do not await setting headers, not a promise
nflaig Mar 4, 2024
355982f
Improve type safety of empty codecs
nflaig Mar 4, 2024
10b0a02
Only require to implement supported req methods
nflaig Mar 4, 2024
c9f804a
Handle requests that only support one format
nflaig Mar 5, 2024
913e422
Handle responses that only support one format
nflaig Mar 5, 2024
ae71b39
Add json / ssz only req codecs
nflaig Mar 5, 2024
718a368
Update only support errors
nflaig Mar 5, 2024
29ce1be
Fix assertion
nflaig Mar 5, 2024
06ed1fb
Set correct accept header if only supports one format
nflaig Mar 7, 2024
804f456
Merge branch 'unstable' into cayman/ssz-api
nflaig Mar 7, 2024
e844434
Fix eslint / prettier issues
nflaig Mar 7, 2024
b7e2168
More formatting fixes
nflaig Mar 9, 2024
473ffa8
Fix fallback request retries in case of http errors
nflaig Mar 9, 2024
03b192c
Formatting of res.error
nflaig Mar 9, 2024
a94b49f
Add add retry functionality to http client (from #6387)
nflaig Mar 9, 2024
013d078
Merge branch 'unstable' into cayman/ssz-api
nflaig Mar 9, 2024
b7f3f14
Update rewards routes and server (#6178 and #6260)
nflaig Mar 10, 2024
d6de9b9
Allow to omit body in ssz req if not defined
nflaig Mar 10, 2024
797c44e
Always set metadata headers in response
nflaig Mar 11, 2024
85d128f
Cache wire format in api response
nflaig Mar 11, 2024
336e714
Only call raw body for json meta
nflaig Mar 11, 2024
64d24c0
Update api package tests (wip)
nflaig Mar 12, 2024
265166b
Test json and ssz format in generic server tests
nflaig Mar 14, 2024
6ee6e82
Add a bunch of todos
nflaig Mar 14, 2024
6968bf7
Fix a few broken route definitions
nflaig Mar 14, 2024
7e5b2de
Fix partial config test
nflaig Mar 14, 2024
f5db555
Another todo note
nflaig Mar 14, 2024
09a2a24
Stringify body of json requests
nflaig Mar 14, 2024
282bb85
Override default response json method
nflaig Mar 14, 2024
c3afb0b
Merge branch 'unstable' into cayman/ssz-api
nflaig Mar 14, 2024
c3aab95
Validate external consensus version headers in request
nflaig Mar 25, 2024
f6e45e8
Add error handling todo
nflaig Mar 25, 2024
aaf0082
Merge branch 'unstable' into cayman/ssz-api
nflaig Mar 29, 2024
3313af3
Skip body schema validation for ssz request bodies
nflaig Apr 1, 2024
ad9fb4a
Clean up generic server tests
nflaig Apr 1, 2024
73a2496
Pass node, proof, events generic tests
nflaig Apr 1, 2024
f1d953f
Use enum for media types
nflaig Apr 1, 2024
2c4ec05
Fix a bunch of route definitions
nflaig Apr 23, 2024
229c6bf
Add justified to blockid type
nflaig Apr 23, 2024
1a5a9cb
Properly handle booleans, remove block values codec
nflaig Apr 23, 2024
369108c
Create Uint8Array test data without allocating Buffer
nflaig Apr 23, 2024
63fc5b6
Let fastify handle Buffer conversion
nflaig Apr 23, 2024
42bb74a
Convert Buffer to Uint8Array in content type parser
nflaig Apr 23, 2024
3c54655
Fix build issues
nflaig Apr 23, 2024
5bd5776
Fix fork type in builder routes
nflaig Apr 26, 2024
9657539
Add some notes
nflaig Apr 26, 2024
553010c
Properly parse request headers
nflaig Apr 26, 2024
74565ac
Fix incorrect type assumptions in transform
nflaig Apr 26, 2024
d1bd088
Generic server tests are passing (except lightclient)
nflaig Apr 26, 2024
37bfb45
Correctly handle APIs with empty responses
nflaig Apr 26, 2024
0ce86e4
Update getHeader return type to reflect no bid responses
nflaig Apr 26, 2024
c20bc02
Do not append '?' to URL if query string is empty
nflaig Apr 26, 2024
b24c625
Let server handler set status code for parsing errors
nflaig Apr 26, 2024
15bdac2
Remove unused import
nflaig Apr 26, 2024
efddef5
Rename function, request specific
nflaig Apr 26, 2024
052fad9
Completely drop ssz support from getSpec
nflaig Apr 27, 2024
dc91a18
Spec tests are passing against latest releases
nflaig Apr 27, 2024
52a5baf
Merge branch 'unstable' into cayman/ssz-api
nflaig Apr 27, 2024
ff40a34
Drop unused fastify route config
nflaig Apr 27, 2024
2c9afef
Drop ssz request from builder routes, not yet supported
nflaig Apr 27, 2024
b3d84db
Remove import
nflaig Apr 27, 2024
c679daa
Apply change from #6695
nflaig Apr 27, 2024
948dad9
Update execution optimistic meta
nflaig Apr 27, 2024
81a96d4
Apply changes from #6645
nflaig Apr 27, 2024
87a96ad
Add workaround to fix epoch committees type issue
nflaig Apr 27, 2024
07f308c
Add todo to fix inefficient state conversion
nflaig Apr 27, 2024
1721a5d
Convert committee to normal array
nflaig Apr 27, 2024
8218615
Apply changes from #6655
nflaig Apr 28, 2024
4de4ad9
Align args of validators endpoints
nflaig Apr 28, 2024
75f105c
Convert indices to str in rewards apis
nflaig Apr 28, 2024
4723f62
Update api spec version of README badges
nflaig Apr 28, 2024
d73e951
Revert table formatting changes
nflaig Apr 28, 2024
6285732
Make this accessible for class-basd API implementations
nflaig Apr 28, 2024
ce8d68a
Throw err if metadata is accessed for failed response
nflaig Apr 28, 2024
05337d4
Add assertOk to api response
nflaig Apr 28, 2024
fc18206
Tweak api error message
nflaig Apr 28, 2024
9210b41
Update operationIds match spec value
nflaig Apr 28, 2024
63bc119
Add missing version to blob sidecars metadata
nflaig Apr 28, 2024
d7a02a2
Test headers and ssz bodies against spec
nflaig Apr 28, 2024
6570127
Minor reordering of code in spec parsing
nflaig Apr 28, 2024
9d6a61a
submitBlindedBlock throws err if fork is not execution
nflaig Apr 29, 2024
5aae4b7
responseOk might be undefined
nflaig Apr 29, 2024
0f50ab7
Remove statusOk from route definition
nflaig Apr 29, 2024
aae534a
Remove stale comment
nflaig Apr 29, 2024
e5f9284
Less build errors in beacon-node
nflaig Apr 29, 2024
f64678d
getBlobSidecars return version from server impl
nflaig Apr 29, 2024
903aca4
Update validator produce block impl
nflaig Apr 29, 2024
e73e75a
More expressive pool method args
nflaig Apr 30, 2024
1c7b44f
Application methods might be undefined in mock implementations
nflaig May 1, 2024
6bc290a
Adress open TODOs in server handler
nflaig May 1, 2024
90a8e84
Api response methods are synchronous now
nflaig May 1, 2024
3db4992
Fix all remaining build issues
nflaig May 1, 2024
fd482c2
Merge branch 'unstable' into cayman/ssz-api
nflaig May 1, 2024
02f142a
Use more performant from/toHex in server api impls
nflaig May 1, 2024
432748a
Clean up some TODOs
nflaig May 2, 2024
c202ced
Fix ApiError type
nflaig May 2, 2024
ce46422
Errors related to parsing return a 400 status code
nflaig May 2, 2024
b1162c4
Simplify method binding
nflaig May 2, 2024
389fa67
Forward api context to application methods
nflaig May 3, 2024
c4f815b
There is no easy way to make generic opts typesafe
nflaig May 3, 2024
3c25528
Better separation of server / client code
nflaig May 3, 2024
dc4c42f
Fix comment about missing builder bid
nflaig May 3, 2024
dc78ac8
Remove todo, not worth the change / extra indentation
nflaig May 3, 2024
8c9508e
Rename route definitions functions
nflaig May 3, 2024
91e51db
Return 400 if data passed to keymanager is invalid
nflaig May 3, 2024
6806267
Properly handle response metadata headers
nflaig May 3, 2024
f86524b
Fix lint issues
nflaig May 3, 2024
bb0c1b1
Add header jsdoc
nflaig May 3, 2024
cb20160
Move metadata related code into separate file
nflaig May 6, 2024
44eeb5c
Remove ssz from POST requests without body
nflaig May 6, 2024
d2266d6
Only set content-type header if body exists
nflaig May 6, 2024
be6ef4e
Fix headers extra
nflaig May 6, 2024
770b3bf
POST requests without body are handled similar to GET requests
nflaig May 6, 2024
9775722
Fix http client options tests
nflaig May 6, 2024
fff444a
Improve validation and type safety of JSON metadata
nflaig May 6, 2024
bfd036a
Merge branch 'unstable' into cayman/ssz-api
nflaig May 6, 2024
282b8d3
Add type guard for request without body
nflaig May 6, 2024
e97a1bc
Differentiate based on body instead of GET vs POST
nflaig May 6, 2024
050b511
More renaming
nflaig May 6, 2024
527b4e9
Simplify RequestCode type
nflaig May 6, 2024
36167da
Review routes, improve validation
nflaig May 7, 2024
700da90
Merge branch 'unstable' into cayman/ssz-api
nflaig May 7, 2024
93b71a8
Remaining local diff
nflaig May 7, 2024
a795926
Fix accept header handling if only support one wire format
nflaig May 8, 2024
639ff63
Update 406 error to more closely match spec example
nflaig May 8, 2024
95b109d
Merge branch 'unstable' into cayman/ssz-api
nflaig May 8, 2024
fda2d25
Enforce version header via custom check instead of schema
nflaig May 10, 2024
ef50b31
Merge branch 'unstable' into cayman/ssz-api
nflaig May 13, 2024
3211e9d
Use ssz as default request wire format
nflaig May 14, 2024
0235196
Log failure to receive head event to verbose
nflaig May 16, 2024
40e5467
Do not set default value for context
nflaig May 23, 2024
613f803
Update getClient return type to better align with method name
nflaig May 23, 2024
a667575
Consistent pattern to get route definitions
nflaig May 23, 2024
26d3017
Merge branch 'unstable' into cayman/ssz-api
nflaig May 23, 2024
efaecc7
Dedupe api client type for builder and keymanager
nflaig May 23, 2024
bde4299
Fix fallback logic if server returns http error
nflaig May 24, 2024
a1af1ce
Update head event error logging
nflaig May 24, 2024
8606807
Merge branch 'unstable' into cayman/ssz-api
nflaig May 24, 2024
6a11417
Retry 415 errors with JSON and cache SSZ not supported
nflaig May 27, 2024
1512a5e
Use fetch spy to assert call times
nflaig May 27, 2024
7a8503b
Update comment
nflaig May 27, 2024
3f44119
Update getLightClientUpdatesByRange endpoint meta
nflaig May 27, 2024
28133d7
Do not forward ssz bytes of blinded block to publishBlock
nflaig May 27, 2024
a073e44
Fix lightclient e2e tests
nflaig May 27, 2024
17808bf
Version header in publishBlock api is optional
nflaig May 28, 2024
0085dcf
Reduce type duplication
nflaig May 29, 2024
6e1b7f5
Add option to override request init in route definition
nflaig May 29, 2024
5925900
Add JsonOnlyResp codec
nflaig May 29, 2024
07713f0
Validate boolean str value from headers
nflaig May 29, 2024
7876937
Document default wire formats
nflaig May 29, 2024
f343652
Simplify merging of inits in http client
nflaig May 30, 2024
fd19368
Remove type hacks from fetchBeaconHealth
nflaig May 30, 2024
109a7b3
Reduce call stack in http client
nflaig May 31, 2024
b59df63
Add .ssz() equivalent method for json to api response
nflaig May 31, 2024
380bd56
More http client tests
nflaig May 31, 2024
1f5ac49
Ensure topics query is provided to eventstream api
nflaig May 31, 2024
93e87cb
Validate request content type in handler
nflaig May 31, 2024
40ae804
Review routes, fix param docs, no empty comments
nflaig Jun 1, 2024
8b59f50
Fix typo
nflaig Jun 1, 2024
f9f0874
Add note about builder spec not supporting ssz
nflaig Jun 2, 2024
bb30a60
Consistently move keymanager jsdoc to routes
nflaig Jun 2, 2024
1ff33cc
Sanitize user provided init values before merging
nflaig Jun 2, 2024
c1c8ed7
Merge branch 'unstable' into cayman/ssz-api
nflaig Jun 2, 2024
f777b31
Remove unused ssz only codec
nflaig Jun 3, 2024
76d4e59
Allow passing wire formats as string literals
nflaig Jun 3, 2024
12f4c97
chore: review proof routes (#6843)
nflaig Jun 3, 2024
3c7957d
chore: review lightclient routes (#6842)
nflaig Jun 3, 2024
785a641
chore: review node routes (#6844)
nflaig Jun 3, 2024
f21fc3c
feat: add cli flags to configure http wire format (#6840)
nflaig Jun 3, 2024
1da5eb0
Merge branch 'unstable' into cayman/ssz-api
nflaig Jun 5, 2024
859c790
Review PR, mostly cosmetic changes
nflaig Jun 6, 2024
302c5e4
Fix event stream error handling
nflaig Jun 6, 2024
907f221
Merge branch 'unstable' into cayman/ssz-api
nflaig Jun 8, 2024
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
Next Next commit
Add config route definitions
  • Loading branch information
wemeetagain committed Nov 4, 2023
commit 0f035421c827af87404176674729b3647b959d7e
128 changes: 72 additions & 56 deletions packages/api/src/beacon/routes/config.ts
Original file line number Diff line number Diff line change
@@ -1,42 +1,53 @@
import {ByteVectorType, ContainerType} from "@chainsafe/ssz";
import {BeaconPreset} from "@lodestar/params";
import {ChainConfig} from "@lodestar/config";
import {Bytes32, UintNum64, phase0, ssz} from "@lodestar/types";
import {mapValues} from "@lodestar/utils";
import {
ArrayOf,
ReqEmpty,
reqEmpty,
ReturnTypes,
ReqSerializers,
RoutesData,
sameType,
ContainerData,
} from "../../utils/index.js";
import {HttpStatusCode} from "../../utils/client/httpStatusCode.js";
import {ApiClientResponse} from "../../interfaces.js";
/* eslint-disable @typescript-eslint/naming-convention */
import {ContainerType, ValueOf} from "@chainsafe/ssz";
import {StringType, ssz} from "@lodestar/types";
import {ArrayOf, EmptyArgs, EmptyGetRequestCodec, EmptyMeta, EmptyMetaCodec, EmptyRequest} from "../../utils/codecs.js";
import {Endpoint, RouteDefinitions} from "../../utils/index.js";

// See /packages/api/src/routes/index.ts for reasoning and instructions to add new routes

export type DepositContract = {
chainId: UintNum64;
address: Bytes32;
};
export const DepositContractType = new ContainerType({
chainId: ssz.UintNum64,
address: ssz.Bytes32,
});
export const StringRecordType = ArrayOf(
new ContainerType({
key: new StringType(),
value: new StringType(),
})
);
export const ForkListType = ArrayOf(ssz.phase0.Fork);

export type Spec = BeaconPreset & ChainConfig;
export type DepositContract = ValueOf<typeof DepositContractType>;
export type StringRecord = ValueOf<typeof StringRecordType>;
export type ForkList = ValueOf<typeof ForkListType>;

export type Api = {
export type Endpoints = {
/**
* Get deposit contract address.
* Retrieve Eth1 deposit contract address and chain ID.
*/
getDepositContract(): Promise<ApiClientResponse<{[HttpStatusCode.OK]: {data: DepositContract}}>>;
getDepositContract: Endpoint<
//
"GET",
EmptyArgs,
EmptyRequest,
DepositContract,
EmptyMeta
>;

/**
* Get scheduled upcoming forks.
* Retrieve all scheduled upcoming forks this node is aware of.
*/
getForkSchedule(): Promise<ApiClientResponse<{[HttpStatusCode.OK]: {data: phase0.Fork[]}}>>;
getForkSchedule: Endpoint<
//
"GET",
EmptyArgs,
EmptyRequest,
ForkList,
EmptyMeta
>;

/**
* Retrieve specification configuration used on this node. The configuration should include:
Expand All @@ -48,37 +59,42 @@ export type Api = {
* - any value starting with 0x in the spec is returned as a hex string
* - numeric values are returned as a quoted integer
*/
getSpec(): Promise<ApiClientResponse<{[HttpStatusCode.OK]: {data: Record<string, string>}}>>;
};

/**
* Define javascript values for each route
*/
export const routesData: RoutesData<Api> = {
getDepositContract: {url: "/eth/v1/config/deposit_contract", method: "GET"},
getForkSchedule: {url: "/eth/v1/config/fork_schedule", method: "GET"},
getSpec: {url: "/eth/v1/config/spec", method: "GET"},
getSpec: Endpoint<
//
"GET",
EmptyArgs,
EmptyRequest,
StringRecord,
EmptyMeta
>;
};

export type ReqTypes = {[K in keyof Api]: ReqEmpty};

export function getReqSerializers(): ReqSerializers<Api, ReqTypes> {
return mapValues(routesData, () => reqEmpty);
}

/* eslint-disable @typescript-eslint/naming-convention */
export function getReturnTypes(): ReturnTypes<Api> {
const DepositContract = new ContainerType(
{
chainId: ssz.UintNum64,
address: new ByteVectorType(20),
export const definitions: RouteDefinitions<Endpoints> = {
getDepositContract: {
url: "/eth/v1/config/deposit_contract",
method: "GET",
req: EmptyGetRequestCodec,
resp: {
data: DepositContractType,
meta: EmptyMetaCodec,
},
{jsonCase: "eth2"}
);

return {
getDepositContract: ContainerData(DepositContract),
getForkSchedule: ContainerData(ArrayOf(ssz.phase0.Fork)),
getSpec: ContainerData(sameType()),
};
}
},
getForkSchedule: {
url: "/eth/v1/config/fork_schedule",
method: "GET",
req: EmptyGetRequestCodec,
resp: {
data: ForkListType,
meta: EmptyMetaCodec,
},
},
getSpec: {
url: "/eth/v1/config/spec",
method: "GET",
req: EmptyGetRequestCodec,
resp: {
data: StringRecordType,
meta: EmptyMetaCodec,
},
},
};