This repo has a devcontainer environment making it easy to get started.
Configure your Azure Cosmos DB credentials as environment variables.
export COSMOS_ENDPOINT="<cosmos-account-URI>"
export COSMOS_KEY="<cosmos-account-PRIMARY-KEY>"💡 TIP: If you don't have an Azure Cosmos DB account, create a free account.
Run the quickstart sample app using the azure-cosmos package from PyPI.
pip install azure-cosmos
python 001-quickstart/app.pyIf you change the code, run the linter and code formatter.
pip install flake8
flake8 --verbose 001-quickstart/app.pypip install black
black --verbose 001-quickstart/app.pyIf you use a self-signed certificate to connect your Cosmos DB instance (Cosmos-emulator, Docker image, proxy, ...), you can define your own certificate in the REQUESTS_CA_BUNDLE environment variable :
export REQUESTS_CA_BUNDLE='/etc/ssl/certs/emulatorcert.pem'