You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/cosmos-db/connect-mongodb-account.md
+15-13Lines changed: 15 additions & 13 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,18 +1,17 @@
1
1
---
2
2
title: Connect a MongoDB application to Azure Cosmos DB
3
3
description: Learn how to connect a MongoDB app to Azure Cosmos DB by getting the connection string from Azure portal
4
-
author: markjbrown
5
-
ms.author: mjbrown
4
+
author: timsander1
5
+
ms.author: tisande
6
6
ms.service: cosmos-db
7
7
ms.subservice: cosmosdb-mongo
8
8
ms.topic: conceptual
9
-
ms.date: 12/02/2019
9
+
ms.date: 03/19/2020
10
10
ms.reviewer: sngun
11
-
12
11
---
13
-
14
12
# Connect a MongoDB application to Azure Cosmos DB
15
-
Learn how to connect your MongoDB app to an Azure Cosmos DB by using a MongoDB connection string. You can then use an Azure Cosmos database as the data store for your MongoDB app.
13
+
14
+
Learn how to connect your MongoDB app to an Azure Cosmos DB by using a MongoDB connection string. You can then use an Azure Cosmos database as the data store for your MongoDB app.
16
15
17
16
This tutorial provides two ways to retrieve connection string information:
18
17
@@ -21,27 +20,30 @@ This tutorial provides two ways to retrieve connection string information:
21
20
22
21
## Prerequisites
23
22
24
-
- An Azure account. If you don't have an Azure account, create a [free Azure account](https://azure.microsoft.com/free/) now.
23
+
- An Azure account. If you don't have an Azure account, create a [free Azure account](https://azure.microsoft.com/free/) now.
25
24
- A Cosmos account. For instructions, see [Build a web app using Azure Cosmos DB's API for MongoDB and .NET SDK](create-mongodb-dotnet.md).
26
25
27
-
## <aid="QuickstartConnection"></a>Get the MongoDB connection string by using the quick start
26
+
## Get the MongoDB connection string by using the quick start
27
+
28
28
1. In an Internet browser, sign in to the [Azure portal](https://portal.azure.com).
29
-
2. In the **Azure Cosmos DB** blade, select the API.
30
-
3. In the left pane of the account blade, click **Quick start**.
29
+
2. In the **Azure Cosmos DB** blade, select the API.
30
+
3. In the left pane of the account blade, click **Quick start**.
31
31
4. Choose your platform (**.NET**, **Node.js**, **MongoDB Shell**, **Java**, **Python**). If you don't see your driver or tool listed, don't worry--we continuously document more connection code snippets. Please comment below on what you'd like to see. To learn how to craft your own connection, read [Get the account's connection string information](#GetCustomConnection).
32
32
5. Copy and paste the code snippet into your MongoDB app.
## <aid="GetCustomConnection"></a> Get the MongoDB connection string to customize
36
+
## Get the MongoDB connection string to customize
37
+
37
38
1. In an Internet browser, sign in to the [Azure portal](https://portal.azure.com).
38
-
2. In the **Azure Cosmos DB** blade, select the API.
39
-
3. In the left pane of the account blade, click **Connection String**.
39
+
2. In the **Azure Cosmos DB** blade, select the API.
40
+
3. In the left pane of the account blade, click **Connection String**.
40
41
4. The **Connection String** blade opens. It has all the information necessary to connect to the account by using a driver for MongoDB, including a preconstructed connection string.
0 commit comments