model.count

Count document(s) in a collection

Arguments

options (object)

Returns

A promise

Example

await user.count({ query: { name: "Martin Luther" }}) // 4