Claim App
Employee expense claims (EXPENSES, MEAL, MILEAGE, OT) with per-user workspaces, Excel/PDF export, and optional Google sign-in.
Stack
| Layer | Tech |
|---|---|
| API | FastAPI, MongoDB, openpyxl, LibreOffice (PDF from Excel on Linux) |
| Web | React, Tailwind |
| Deploy | Render + MongoDB Atlas (+ Cloudflare R2 for attachments) |
Local development
Backend (port 8002)
cd backend
copy .env.example .env # Windows: set MONGO_URL, DB_NAME=claim, PORT=8002
pip install -r requirements.txt
# or: backend\start-local.bat
python -m uvicorn server:app --reload --host 0.0.0.0 --port 8002
Health: http://localhost:8002/api/health
Frontend
cd frontend
copy .env.example .env # REACT_APP_BACKEND_URL=http://localhost:8002
yarn install
yarn start
# or: frontend\start.bat
Default UI: http://localhost:3000
Docker (optional)
docker compose -f docker-compose.claim.yml up --build
The compose file expects MongoDB to be running as a localhost service on the host machine. The backend container reaches it via host.docker.internal:27017. See docs/deploy/docker.md for full details, port map, and gotchas.
Deploy on Render + GitHub auto-deploy
- Push this repository to GitHub (for example
skysyaz/claim). - In Render: New → Blueprint → connect the GitHub repo and branch (
main). - Set secret env vars (
sync: falsein the dashboard) — see docs/deploy/render.md. - Auto-Deploy is enabled in
render.yaml(autoDeploy: true). Each new commit on the connected branch triggers a redeploy of the API (and rebuild of the static site when its files change).
To connect an existing service manually: service → Settings → Build & Deploy → Auto-Deploy = Yes, branch = main.
Full checklist: docs/deploy/README.md
Repository layout
backend/ # FastAPI API
frontend/ # React app
Claim Template/ # Excel templates
docs/deploy/ # Render deployment guide
render.yaml # Render Blueprint
License
See LICENSE.
Webhook test
Webhook test 2
Description
Languages
Python
47.9%
JavaScript
47.3%
TypeScript
2%
CSS
1%
Batchfile
0.5%
Other
1.3%