{"name":"restify-logger","version":"1.0.0","description":"A custom logger for restify","main":"lib/index.js","scripts":{"test":"echo \"Error: no test specified\" && exit 1"},"repository":{"type":"git","url":"https://github.com/AnyFetch/restify-logger.git"},"keywords":["restify","logger"],"author":{"name":"Quentin Buathier","email":"quentin.buathier@epitech.eu"},"license":"MIT","bugs":{"url":"https://github.com/AnyFetch/restify-logger/issues"},"homepage":"https://github.com/AnyFetch/restify-logger","dependencies":{"morgan":"^1.3.2"},"gitHead":"27c730b232f9b0bcb68f32781e866ebc07716d18","_id":"restify-logger@1.0.0","_shasum":"b0276dd216ce9314d11c9cb0afe59e4eae1fd8fa","_from":".","_npmVersion":"2.0.2","_nodeVersion":"0.10.32","_npmUser":{"name":"quentin01","email":"quentin.buathier@epitech.eu"},"maintainers":[{"name":"quentin01","email":"quentin.buathier@epitech.eu"}],"dist":{"shasum":"b0276dd216ce9314d11c9cb0afe59e4eae1fd8fa","tarball":"http://registry-npm.ywwl.com/restify-logger/download/restify-logger-1.0.0.tgz","integrity":"sha512-6cZJJjzK44UWuvdu9aerlR7q9gmYoxEiy2akJ1cMbCA48iO1t6Y3HlD9Lnxful2baWIiGh/ZulfJ3adwhuU+yw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIAFw3UuNuuL4hYh1YF5H7Cok09GoocJOEopFob9uoAtAAiEAxXpKddTVXS/Hd4/TJ7GE59GP2McBuuhlWPS5ts5vBfM="}],"size":1913,"noattachment":false,"key":"/restify-logger/-/restify-logger-1.0.0.tgz"},"directories":{},"readme":"# Restify logger\n> Visit http://anyfetch.com for details about AnyFetch.\n\nCustomizable logger for Restify based on [mogan](https://github.com/expressjs/morgan).\n\n# Usage\n\n```js\nvar logger = require('restify-logger');\n\n// You can use the skip parameter to skip some requests\napp.use(logger('custom', {\n  skip: function (req) {\n    return process.env.NODE_ENV === \"test\" || req.method === \"OPTIONS\" || req.url === \"/status\";\n  }\n}));\n```\n\nThis will display:\n```\nDELETE ???:/user/542d5154d0db17c03ecd1499 25ms 204\n```\n\n## Overriding tokens\nYou can specify a function to be used by the `user` token:\n```js\n// Overwrite the default user function, that only writes '???:'\nlogger.token('user', function(req) {\n  return (req.user && req.user.email || '???') + ':';\n});\n```\n\nThis will display:\n```\nDELETE test@anyfetch.com:/user/542d5154d0db17c03ecd1499 25ms 204\n```\n\n## Overriding formats\n```js\nvar logger = require('restify-logger');\n\n// morgan syntax\nlogger.format('my-simple-format', ':method :url :status')\napp.use(logger('my-simple-format'));\n```\n\nThis will display:\n```\nDELETE /user/542d5154d0db17c03ecd1499 204\n```\n\n\nSupport: `support@anyfetch.com`.\n","publish_time":1412265819947,"_cnpm_publish_time":1412265819947,"dist-tags":{"latest":"2.0.1"}}