Module: lib/server

Module with the server and endpoint configuration and handlers

Source:
Tutorials:

Methods

(inner) createEndpoints(endpointCb, callback)

Creates routes to the API endpoints

Parameters:
Name Type Description
endpointCb logEndpointEventCb

function passed to the endpoint handler to be invoked when done

callback function

function to be called upon completion

Source:

(inner) monitorSocket(callback)

Monitors socket client connections

Parameters:
Name Type Description
callback logEndpointEventCb
Source:

(inner) sendSocket(data)

Sends out data on socket

Parameters:
Name Type Description
data string
Source:

(inner) stopServer(callback)

Stops the API http server

Parameters:
Name Type Description
callback function

function called after stopping the server

Source:

Type Definitions

timeout()

Returns callback with timeout error

Source:

url

Starts the API http server

Type:
  • string
Source: