Bugfix on REST API middlewares and bumped up version for NPM