Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
APPLIES TO:
NoSQL
An Azure Cosmos DB for NoSQL account contains all of your Azure Cosmos DB resources: databases, containers, and items. The account provides a unique endpoint for various tools and SDKs to connect to Azure Cosmos DB and perform everyday operations. For more information about the resources in Azure Cosmos DB, see Azure Cosmos DB resource model.
- An Azure account with an active subscription. Create a trial subscription.
Create a single Azure Cosmos DB account using the API for NoSQL.
Create shell variables for accountName, resourceGroupName, and location.
# Variable for resource group name resourceGroupName="msdocs-cosmos" # Variable for location location="chinanorth" # Variable for account name with a randomnly generated suffix let suffix=$RANDOM*$RANDOM accountName="msdocs-$suffix"
If you haven't already, sign in to the Azure CLI using the
az login
command.Use the
az group create
command to create a new resource group in your subscription.az group create \ --name $resourceGroupName \ --location $location
Use the
az cosmosdb create
command to create a new Azure Cosmos DB for NoSQL account with default settings.az cosmosdb create \ --resource-group $resourceGroupName \ --name $accountName \ --locations regionName=$location
In this guide, you learned how to create an Azure Cosmos DB for NoSQL account. You can now create an application with your Azure Cosmos DB account.