Overview
This is a complete rewrite of the original restify-endpoints project. This will support full auto-documentation as well as being able to be attached to restify, express, or a vanilla http service with a router attached.
Server Examples
Restify
var restify = var Endpointer = var endpoints = endpoints var server = restify; endpoints server
Express
var express = var endpoints = endpointsexpress
Vanilla HTTP
With vanilla node HTTP you'll need a router attached.
var http = var router = var endpoints = { } var server = http endpoints server
Additional Information
Afterware
This is only supported on restify
unless you add a server.on('after')
handler for express
or the vanilla http server. You'd need to emit the after
event AFTER the response has already been sent.