DarkW1nter
DarkW1nter

Reputation: 2861

DocumentDB document link for Azure Cosmos DB

If I have an Azure Cosmos database with the following setup

Database name: MyDatabase

Collection: MyCollection

How would I use UriFactory to create a document link to use in CreateDocumentAsync(documentLink, document)?

I had a look at the Microsoft documentation here but this seems to use a document id to delete the document, I want to create a document instead.

Upvotes: 1

Views: 2751

Answers (1)

DarkW1nter
DarkW1nter

Reputation: 2861

Uri myUri = UriFactory.CreateDocumentCollectionUri("MyDatabase", "MyCollection");

Upvotes: 4

Related Questions