Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/deno_api_server/src/services/api.ts>Api

API Server for deno for functional programmed endpoints
Latest
class Api
import { Api } from "https://deno.land/x/deno_api_server@v0.6.4/src/services/api.ts";

Constructors

new
Api(serverConfig: IServerConfig)

Properties

forceJsonResponse: boolean
readonly
host
readonly
props: IStateMap
routes: IRoute[]
serverConfig: IServerConfig

Methods

protected
handleError(response: IResponse, error: Error)

Add route to server stack

getRouteByRequest(request: Request, url?: URL): null | IRoute

resolve route by request

start server listing on requests