The fastest way to hook up with the Azure Cosmos DB API for MongoDB is to head over to the Azure portal. Go on your account after which, at the left navigation menu, click on Quick Start. Quick Start is the best way to get code snippets to connect with your database.
Azure Cosmos DB enforces strict security necessities and requirements. Azure Cosmos DB debts require authentication and secure communication thru SSL, so make sure to use TLSv1.2.