{"agent":"claude","input":"Add account lockout after repeated failed logins to this Express and Mongoose app. Read package.json, src/index.js, src/app.js, src/config/config.js, src/models/user.model.js, src/models/plugins/toJSON.plugin.js, src/services/auth.service.js, src/controllers/auth.controller.js, src/validations/auth.validation.js, src/middlewares/rateLimiter.js, src/middlewares/error.js, src/utils/ApiError.js, tests/utils/setupTestDB.js, tests/fixtures/user.fixture.js and the login section of tests/integration/auth.test.js first. Add failedLoginAttempts and lockUntil to the user schema as private fields so toJSON hides them. Add LOGIN_MAX_ATTEMPTS defaulting to 5 and LOGIN_LOCK_MINUTES defaulting to 15 to the Joi config schema and .env.example. In the login service, answer 423 with the minutes left while an account is locked, count a wrong password with an atomic $inc and lock when the limit is reached, and clear both fields on a correct login. Keep the 401 message the same for an unknown email and a wrong password. Add integration tests for the lock, the expiry and the hidden fields, and a unit test for the counter. MongoDB is not running here and Docker is not installed: install docker.io, start dockerd, bring up the mongodb service from docker-compose.yml with docker-compose, set MONGODB_URL, and run yarn test, yarn lint and yarn prettier, then open a pull request.","resources":[{"url":"https://github.com/your-org/your-app"}]}