Everything below covers the open-source edition. Notes on the complete edition sit at the bottom of the page.
Python 3.11 or newer, and one of the fastapi-data releases from GitHub. Polars, FastAPI, uvicorn, and pytest are pulled in by pip install -e ..
git clone https://github.com/FauziMatakupan/\
fastapi-data.git
cd fastapi-data
python -m venv .venv && source .venv/bin/activate
pip install -e .
uvicorn app.main:app --reload
API server defaults to port 8000. The docs page, generated from the OpenAPI schema, lives at /docs.
Settings read from environment variables or a .env file.
| Setting | Default | What it does |
|---|---|---|
APP_NAME | FastAPI-Data | Shown on /docs |
ENVIRONMENT | development | Reported by /health |
API_V1_PREFIX | /api/v1 | Route prefix |
DATA_DIR | ./data | Upload target directory |
MAX_UPLOAD_MB | 100 | Declared limit, not enforced by the upload endpoint yet |
Multipart form with a file field. Accepts .csv, .parquet, .pq. Everything else returns 415. The response carries a dataset_id, which is abs(hash(filename)) & 0xFFFFFFFF, so the same filename in one process always lands on the same path and the second upload writes over the first.
curl -s -F "file=@sample.csv" localhost:8000/api/v1/data/upload
{"dataset_id": "891903036.csv", "size_bytes": 49}
Dtype, null count, and distinct count per column, for every column in the upload. Scalar JSON keyed by column name. Unknown dataset returns 404.
Numeric columns only. Count, mean, std, min, p25, median, p75, max. Quartiles are interpolated linearly — Polars' default nearest mode snaps to a real value and disagrees with everything else you would compare against.
{"status": "ok", "environment": "development"}
Same engine, same JSON contract. Around that core:
coerce=True fixes stringified numbers quietly, strict=False tolerates extra columns, failures emit row-level errors.