SpringMultipartRestAPI is a Spring Boot application designed to facilitate the uploading, downloading, and deleting of files through a RESTful API. This project leverages Spring's powerful features to handle multipart file uploads, serving files, and managing file deletion securely and efficiently.
To get started with SpringMultipartRestAPI, ensure you have Java and Maven installed on your system. Follow these steps to run the application:
Clone the repository:
git clone https://github.com/yourusername/SpringMultipartRestAPI.git
cd SpringMultipartRestAPIRun the application using Maven:
mvn spring-boot:runThis command will start the Spring Boot application on the default port (8080). You can access the application at http://localhost:8080.
The application defines the following RESTful endpoints:
Uploading a file:
Use a tool like Postman or a CURL command to upload a file:
curl -F "file=@path/to/your/file.txt" http://localhost:8080/api/savesync/uploadDownloading a file:
Access the provided URL from the list files endpoint or use a tool like wget:
wget http://localhost:8080/api/savesync/files/yourfile.txtDeleting a file:
Use a CURL command to delete a file:
curl -X DELETE http://localhost:8080/api/savesync/files/yourfile.txtContributions are welcome! Please feel free to submit a pull request or create an issue for any feature requests or bug reports.