UNPKG

@lodestar/api

Version:

A Typescript REST client for the Ethereum Consensus API

8 lines (6 loc) 397 B
import {ChainForkConfig} from "@lodestar/config"; import {ApplicationMethods, FastifyRoutes, createFastifyRoutes} from "../../utils/server/index.js"; import {Endpoints, getDefinitions} from "../routes/debug.js"; export function getRoutes(config: ChainForkConfig, methods: ApplicationMethods<Endpoints>): FastifyRoutes<Endpoints> { return createFastifyRoutes(getDefinitions(config), methods); }