Delete both types of images (UserIcon and TransactionIcon)

The POST /Files/deleteIcon API method is used to delete an uploaded file associated with a transaction or a user avatar. Depending on whether a transactionId is provided, it will either remove the file related to a specific transaction or delete the user’s avatar.

Functionality:

  • Deletes the file associated with the provided transactionId. If transactionId is not provided, it deletes the user's avatar file.

Request Parameters:

  • transactionId (optional): The ID of the transaction associated with the file to be deleted. If this parameter is omitted, the API will delete the user avatar.

Key Features:

  • Conditional Deletion: Deletes a file based on the presence of transactionId. If no transactionId is provided, the user’s avatar is deleted instead.
  • Flexible Management: Provides a way to manage and clean up both transaction-related files and user avatars efficiently.
  • Error Handling: Includes responses to handle cases where the file or avatar is not found or if the request is invalid.

📘

This API is useful for managing and removing files related to transactions or user profiles, ensuring that unnecessary or outdated files are properly handled.

Language
Credentials
Bearer
JWT
Click Try It! to start a request and see the response here!