Directus (flagbit) icon

Directus (flagbit)

Consume Directus API

File → Delete Multiple

AI-generated

Overview

This node operation deletes multiple files based on an array of primary keys provided as input. It is useful in scenarios where you need to remove several files from a system or database in a single action, such as cleaning up unused or outdated files in bulk.

Use Case Examples

  1. Deleting multiple user-uploaded files by specifying their unique IDs.
  2. Removing a batch of temporary files after processing.

Properties

Name Meaning
Keys (JSON) An array of primary keys of the files to be deleted. This input is required and must be provided in JSON format.

Output

JSON

  • deletedFiles - List or confirmation of files that were successfully deleted.

Dependencies

  • Requires API authentication to the file management system or database where files are stored.

Troubleshooting

  • Ensure the 'Keys (JSON)' input is a valid JSON array of existing file primary keys; invalid or non-existent keys will cause errors.
  • Check API authentication credentials if deletion fails due to permission issues.
  • Error messages may indicate missing or malformed input; verify the JSON format and required fields.

Discussion