diff --git a/lib/index-api.js b/lib/index-api.js index f91b6245..0eb9d8ba 100644 --- a/lib/index-api.js +++ b/lib/index-api.js @@ -90,6 +90,13 @@ module.exports = function(config, auth, storage) { stream.pipe(res) }) + app.get('/-/local', can('access'), function (req, res, next) { + storage.get_local(function (err, packages) { + if (err) return next(err) + res.status(200).json(packages) + }) + }) + // searching packages app.get('/-/all/:anything?', function(req, res, next) { var received_end = false