Delete Cosmos DB documents using API in ADF (Azure Data Factory)

Devashish Parmar (BLR GSS) 86 Reputation points
2022-11-14T08:06:26.877+00:00

I need help in deleting documents in Cosmos DB using ADF pipeline. I couldn't find any option in ADF so is there a way I can invoke delete API using ADF?

I am using Cosmos DB (SQL)

Azure Cosmos DB
Azure Cosmos DB
An Azure NoSQL database service for app development.
Azure Data Factory
Azure Data Factory
An Azure service for ingesting, preparing, and transforming data at scale.
{count} votes

1 answer

Sort by: Most helpful
  1. PRADEEPCHEEKATLA 91,576 Reputation points Moderator
    2022-11-15T08:01:19.18+00:00

    Hello @Devashish Parmar (BLR GSS) ,

    Thanks for the question and using MS Q&A platform.

    You can use the REST endpoint in Azure Data Factory to call Azure REST API for Delete Document in Cosmos DB (SQL).

    The Delete Document operation deletes an existing document in a collection.

    260432-image.png

    For more details, refer to Copy and transform data from and to a REST endpoint by using Azure Data Factory and MS Q&A thread which addressing similar issue.

    Hope this will help. Please let us know if any further queries.

    ------------------------------

    • Please don't forget to click on 130616-image.png or upvote 130671-image.png button whenever the information provided helps you. Original posters help the community find answers faster by identifying the correct answer. Here is how
    • Want a reminder to come back and check responses? Here is how to subscribe to a notification
    • If you are interested in joining the VM program and help shape the future of Q&A: Here is jhow you can be part of Q&A Volunteer Moderators
    0 comments No comments

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.