Mom-Portal/docs/API.md
KevinB-T 30894e7f27 Configure VM services and fix auth flow
- point MySQL and Whisper settings to the VM
- add VM MySQL bootstrap scripts and docs
- allow LAN Vite origins for CORS
- fix Express 5 validation assignment crash
- allow login with username or email
- prevent recursive auth refresh retries
2026-05-15 15:19:49 +05:30

47 lines
885 B
Markdown

# API Guide
Base path: `/api/v1`
All JSON responses follow:
```json
{
"success": true,
"message": "Transcript created",
"data": {}
}
```
## Auth
- `POST /auth/register`
- `POST /auth/login`
- `POST /auth/refresh`
- `GET /auth/me`
- `POST /auth/logout`
- `PATCH /auth/profile`
- `PATCH /auth/password`
- `POST /auth/forgot-password`
## Audio And Transcription
- `POST /audio/transcribe` accepts multipart field `audio`
- `GET /transcriptions/:id/status` returns queued, processing, completed, or failed
- `GET /transcriptions/whisper/health` checks Whisper VM and queue state
## Transcripts
- `GET /transcripts`
- `GET /transcripts/inbox`
- `GET /transcripts/sent`
- `GET /transcripts/:id`
- `PATCH /transcripts/:id`
- `DELETE /transcripts/:id`
- `POST /transcripts/send`
- `GET /transcripts/:id/audio`
- `GET /transcripts/:id/download`
## Users
- `GET /users?q=kevin`