Skip to main content
Skip table of contents

Cosmos DB

Setup Guide

Follow these steps to connect Cosmos DB to your CData Virtuality account:

  1. In the Web UI, open the Sources page:

    Sources1.png
  2. Type Cosmos DB into the search field, then click the data source button:

    Screenshot from 2024-09-05 19-15-24.png

  3. On the Basic Settings tab of the new connection, enter a connection name or keep the default name.

  4. Enter your Cosmos DB account URL Account Endpoint. You can find this URL under the Keys blade of the Cosmos DB account.

  5. Select the Authentication method, then proceed to the relevant section and follow those instructions.

Authentication Methods

AccountKey

  1. Enter the master key token or resource token for connecting to the Cosmos DB REST API in the Account Key field.

  2. Use the Token Type field to specify whether the token you entered in the Account Key field is a master or resource token.

  3. In Cosmos DB, add the CData Connect static IP addresses to your connection whitelist.

  4. At the top of the CData Connect Add Cosmos DB Connection page, click Save & Test.

    • If the connection test succeeds, a message indicates that your connection has been created.

    • If the connection test fails, ensure that you entered your login information correctly with no stray spaces or other characters. Then, try again.

AzureAD

  1. Enter the OAuth Client Id assigned when you registered your Cosmos DB account for OAuth.

  2. Enter the OAuth Client Secret for your Cosmos DB account for OAuth.

  3. In Cosmos DB, add the CData Connect static IP addresses to your connection whitelist.

  4. At the top of the CData Connect Add Cosmos DB Connection page, click Save & Test.

    • If the connection test succeeds, a message indicates that your connection has been created.

    • If the connection test fails, ensure that you entered your login information correctly with no stray spaces or other characters. Then, try again.

AzureServicePrincipal

  1. Enter the Azure Tenant Id to connect to.

  2. Enter the OAuth Client Id found in your application settings.

  3. Enter your OAuth Client Secret.

  4. In Cosmos DB, add the CData Connect static IP addresses to your connection whitelist.

  5. At the top of the CData Connect Add Cosmos DB Connection page, click Save & Test.

    • If the connection test succeeds, a message indicates that your connection has been created.

    • If the connection test fails, ensure that you entered your login information correctly with no stray spaces or other characters. Then, try again.

More Information

For more details on the Cosmos DB driver, see this information page.

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.