Challenge LabBeginner

Azure Cosmos DB for NoSQL Database and Container Setup

Independently create an Azure Cosmos DB for NoSQL account, set up a database and container with a partition key, and add JSON items.

30 minEstimated time
1Guided step
AutoVerification
IsolatedSandbox
Azure Cosmos DB for NoSQL Database and Container Setup

Lab overview

Azure Cosmos DB is Microsoft's globally distributed, multi-model database service, built for applications that need single-digit-millisecond response times and the ability to scale throughput and storage elastically across regions. Its most widely used flavor — the API for NoSQL — stores schema-free JSON documents and is the native, most feature-rich option, with a familiar SQL-like language for querying your data.

The single most important design decision in Cosmos DB is the partition key. A container scales horizontally by spreading its items across logical partitions keyed on a property you choose — for product data, something like /category. A well-chosen key distributes both data and request volume evenly; a poor one creates "hot" partitions that throttle under load. And because the partition key is fixed at container creation and can't be changed afterward without recreating the container, getting it right up front is part of the job.

This challenge tests your ability to stand up the foundational Cosmos DB infrastructure for a product inventory system. Starting from an empty resource group, you'll create a Cosmos DB for NoSQL account, design the database and container with an appropriate partition key, and populate the container with data — end to end, your way.

Objectives

By completing this beginner-level challenge, you will be able to:

  • Create an Azure Cosmos DB for NoSQL account in a resource group
  • Create a database named InventoryDB in the Cosmos DB account
  • Create a Products container with /category as the partition key
  • Add JSON document items to a Cosmos DB container

Prerequisites

You'll get the most out of this challenge if you're already comfortable with:

  • Navigating the Azure Portal
  • Basic JSON document structure
  • Core database concepts (databases, containers/collections, and records)

Verified against your live environment

An automated validation engine inspects your actual resources and configurations as you work. Completion means the task was performed — not multiple choice, real-world proficiency.

[CHECK] validation_activelive
Inspecting deployed resources...
Verifying configuration state...
✓ Step requirements satisfied

More labs like this

Related reading

PremiumIncluded in Premium
Duration
30 min
Steps
1

Environment

Live Cloud Environment

Every lab includes

  • Real environment, pre-credentialed
  • Automated checks on every step
  • Isolated sandbox, auto cleanup
  • AI-recommended next steps

Lab curriculum

  1. 01

    Challenge Scenario - Azure Cosmos DB for NoSQL Database and Container Setup

    4 automated checks

Skills validated

Azure Cosmos DB

Not the lab you were looking for?

Browse 150+ hands-on labs across AWS, Azure, Kubernetes, Docker, and cloud security.

Explore the catalog