ajaxs/index.js
function readRawBody(req,res,rawBodyCallback,callbackScope) {

	if ( typeof req._body !== 'undefined' && req._body ) { 
		rawBodyCallback.call(callbackScope,req,res);
	} else {
		req.rawBody = '';
	  	req.setEncoding('utf8');

	  	req.on('data', function(chunk) { 
	    	req.rawBody += chunk;
	  	});

	  	req.on('end', function() {
	    	rawBodyCallback.call(callbackScope,req,res);
	  	});
	}
	
}
function readRawBody(req,res,rawBodyCallback,callbackScope) {

	if ( typeof req._body !== 'undefined' && req._body ) { 
		rawBodyCallback.call(callbackScope,req,res);
	} else {
		req.rawBody = '';
	  	req.setEncoding('utf8');

	  	req.on('data', function(chunk) { 
	    	req.rawBody += chunk;
	  	});

	  	req.on('end', function() {
	    	rawBodyCallback.call(callbackScope,req,res);
	  	});
	}
	
}
function readRawBody ( req , res , rawBodyCallback , callbackScope ) { if ( typeof req . _body !== 'undefined' && req . _body ) { rawBodyCallback . call ( callbackScope , req , res ) ; } else { req . rawBody = '' ; req . setEncoding ( 'utf8' ) ; req . on ( 'data' , function ( chunk ) { req . rawBody += chunk ; } ) ; req . on ( 'end' , function ( ) { rawBodyCallback . call ( callbackScope , req , res ) ; } ) ; } }
Asynchronous call to read the raw body from the request that we have deemed,
as an API request.

NOTE: This function implements a workaround if the middleware is placed
after the body parser in the connect stack.

@internal
@param { object } req an expressjs http request object.
@param { object } res an expressjs http response object.
@param { function } rawBodyCallback a callback function once the body has been read.
@param { object } callback scopt
Asynchronous call to read the raw body from the request that we have deemed as an API request .