{"library":"mongodb-handler","type":"library","category":null,"description":"The mongodb-handler package (v3.0.0) is a lightweight wrapper around the official MongoDB Node.js driver, designed to simplify common database operations like insert, update, delete, and aggregation. It provides a global event listener to notify on operations and supports both callback and Promise/async-await patterns. The module uses the MDBHANDLER_CONSTRING environment variable for configuration, defaulting to 'mongodb://localhost:27017/mdbtest'. It offers an options object to define collection, document, query, and userId for event tracking. The package is released infrequently with no recent updates; v2 introduced promises and event listener improvements. Compared to Mongoose or the native driver, it reduces boilerplate but lacks schema validation and is less actively maintained.","language":"javascript","status":"maintenance","version":"3.0.0","tags":["javascript","mongodb","global"],"last_verified":"Sun Jun 07","install":[{"cmd":"npm install mongodb-handler","imports":["const mdbhandler = require('mongodb-handler');","const mdbhandler = require('mongodb-handler'); const connection = mdbhandler.start();","connection.on('ready', (msg) => console.log(msg));"]},{"cmd":"yarn add mongodb-handler","imports":[]},{"cmd":"pnpm add mongodb-handler","imports":[]}],"homepage":"https://github.com/werbasinnotec/mongodb-handler#readme","github":"ssh://git@github.com/werbasinnotec/mongodb-handler","docs":null,"changelog":null,"pypi":null,"npm":"mongodb-handler","openapi_spec":null,"status_page":null,"smithery":null,"compatibility":null}