Silo is a lightweight, local object storage server accessible over HTTP. It maps object keys directly to a directory structure on the local filesystem while mitigating path traversal attacks.
Uploads a file to the specified key.
PUT /objects/:key
Downloads the file at the specified key.
GET /objects/:key
Deletes the file at the specified key. Empty parent directories are automatically cleaned up.
DELETE /objects/:key
Returns a JSON array of all object keys.
GET /objects
Parameters:
prefix(optional): Filter the listed keys by a specific path prefix. (e.g.,GET /objects?prefix=images/)
All objects are stored in the data/ directory relative to the process's current working directory.
Ensure dependencies are installed and run the server directly via tsx:
npm install
npx tsx src/store.tsThe server will listen on port 4000 by default.