Files Storage (Local & S3)
Microbase stores uploaded files on local disk (DATA_DIR=./storage) by default and supports hot-swapping to any S3-compatible storage (AWS S3, Cloudflare R2, MinIO).
Configuring S3 via microbase.conf
Section titled “Configuring S3 via microbase.conf”S3_ENABLED=trueS3_ENDPOINT=https://<account>.r2.cloudflarestorage.comS3_BUCKET=microbase-filesS3_REGION=autoS3_ACCESS_KEY=your-access-keyS3_SECRET_KEY=your-secret-keyS3_FORCE_PATH_STYLE=trueThumbnails & File Tokens
Section titled “Thumbnails & File Tokens”- Request resized thumbnails on the fly:
GET /api/files/:collection/:recordId/:filename?thumb=300x300(enforces pixel & dimension limits to prevent image-bomb DoS). - For protected collections, request a short-lived token via
POST /api/files/tokenand pass?token=<FILE_TOKEN>.