capabilities.work

List and Batch Delete Objects

A 2-step recipe with Amazon S3. We can help you get access.

Recipe · 2 steps

List and Batch Delete Objects

List objects under a prefix then batch-delete a supplied set of keys.

  1. List the objects under the prefix so the caller can see what is about to be removed.
  2. Delete the supplied set of keys in a single DeleteObjects request, using quiet mode so only errors are returned.
What you'll need to have ready
  • bucket: The bucket to list and delete from.
  • prefix: The key prefix to scope the listing to.
  • objectsToDelete: The list of objects to delete, each an object with a Key (and optional VersionId).
For your developer

Arazzo workflow amazon-s3:list-and-batch-delete, 2 operations: ListObjectsV2 → DeleteObjects. Specs on APIs.io.