If you haven't yet done so, please take a minute to read the quickstart to get an idea of how Mongoose works. If you are migrating from 7.x to 8.x please take a moment to read the migration guide. Defining your schema Creating a model Ids Instance methods Statics Query Helpers Indexes Virtuals Aliases Options With ES6 Classes Pluggable Further Reading Defining your schema Everything in Mongoose st