REST File Management API

This REST API allows clients to upload, read (download), update (replace), delete, and administer files on a server. Each file has four unique endpoints (URLs) generated at upload time, corresponding to the different operations.

Check this link to test the API with a user client: https://file.leosdisciple.com/manager/

Overview

  1. Upload a File
  2. Read (Download) a File
  3. Update (Replace) a File
  4. Delete a File
  5. Admin (Retrieve Links)

Usage Details

  1. Upload Process
  2. Reading a File
  3. Updating a File
  4. Deleting a File
  5. Admin / Retrieve Links

Technical Notes

Example Client Flows

  1. Client Uploads a file, receives the JSON response with 4 links, and stores them.
  2. To View/Download, the client calls GET read_url.
  3. To Replace/Update, the client calls POST update_url with a new file.
  4. To Delete, the client calls DELETE delete_url.
  5. If the client only has the admin_id, it can retrieve the 4 links again by calling GET admin_url.

Summary

This API offers a straightforward mechanism to manage files via unique URLs for each operation. By separating file operations into distinct endpoints (read, update, delete, admin), the API ensures that each link is specialized and only reveals the intended functionality (e.g., read, update, or delete) to whoever possesses the correct URL/ID. This design is flexible for integrating into front-end applications, single-page apps, or even third-party services needing file hosting and management.