I am building a C# ASP.net core web application which connects to MongoDB. My aim is to get data from MongoDB in form of pages, for example if I have 100 documents of a certain collection I would like to get 10 documents after ID=X and 10 documents before ID=X.
What is the right syntax to get data like that knowing ID of a document (Previous 10 documents as well as Next 10 documents)?