# Delete Documents **POST /action/deleteMany** Delete multiple documents that match a query. ## Servers - Global App: https://data.mongodb-api.com/app/your-app-id/endpoint/data/v1 (Global App) - Local App: https://us-east-1.aws.data.mongodb-api.com/app/your-app-id/endpoint/data/v1 (Local App) ## Authentication methods - Access token - Email & Password - Api key - Custom jwt ## Parameters ### Body: application/json (object) - **dataSource** (string) The name of a linked MongoDB Atlas data source. This is commonly `"mongodb-atlas"` though it may be different in your App if you chose a different name when you created the data source. - **database** (string) The name of a database in the specified data source. - **collection** (string) The name of a collection in the specified database. - **filter** (object) A MongoDB query filter that matches documents. For a list of all query operators that the Data API supports, see [Query Operators](https://www.mongodb.com/zh-cn/docs/atlas/app-services/mongodb/crud-and-aggregation-apis/#query-operators). ## Responses ### 200 Deleted #### Body: application/json (object) - **deletedCount** () The number of documents that were deleted. ### 400 The request was malformed or incomplete. #### Body: application/json (object) - **error** (string) A message that describes the error. - **error_code** (string) The error type. - **link** (string) A link to a [log entry](https://www.mongodb.com/zh-cn/docs/atlas/app-services/logs/endpoint/) for the failed operation. ### 401 The authenticated user does not have permission to access this endpoint. #### Body: application/json (object) - **error** (string) A message that describes the error. - **error_code** (string) The error type. - **link** (string) A link to a [log entry](https://www.mongodb.com/zh-cn/docs/atlas/app-services/logs/endpoint/) for the failed operation. [Powered by Bump.sh](https://bump.sh)