Constructors
constructor
- new RestLib(options?: { server?: ServerOptions }): RestLib
Parameters
Optional options: { server?: ServerOptions }
Optional server?: ServerOptions
Methods
delete
Parameters
path: string
Rest ...listeners: Listener[]
error
Parameters
handler: (ctx: Context, error: Error) => void
get
Parameters
path: string
Rest ...listeners: Listener[]
listen
- listen(port: number, callback: Function): RestLib
Parameters
port: number
callback: Function
patch
Parameters
path: string
Rest ...listeners: Listener[]
post
Parameters
path: string
Rest ...listeners: Listener[]
put
Parameters
path: string
Rest ...listeners: Listener[]
Class for handling REST http requests