openrosa-request-middleware

travis js-standard-style npm downloads

Very simple middleware to check for OpenRosa headers on a request and add OpenRosa headers to a response in an Express app, as defined by https://bitbucket.org/javarosa/javarosa/wiki/OpenRosaRequest

Usage

var OpenrosaMiddleware = require('openrosa-request-middleware');

app.use(OpenrosaMiddleware());

Note that it exports a factory that creates the middleware when invoked.

pass options = {strict: false} to ignore request headers

======================

See it on GitHub

Return to Code