Clear old voice files
POST /v1/voice/cleanup — Delete persisted voice audio (spoken replies + mic recordings) on chat messages older than `older_than_days` (default 30
POST /v1/voice/cleanup
Delete persisted voice audio (spoken replies + mic recordings) on chat messages older than older_than_days (default 30, range 0-3650). The message rows stay; only the audio file + its metadata key are removed, so an old reply read aloud again re-synthesizes on demand. Returns counts + bytes freed.
| Method | POST |
| Path | /v1/voice/cleanup |
| Auth | Authorization: Bearer <token> required when GATEWAY_AUTH_TOKEN is set |
| Category | voice |
Request body
{ "older_than_days": 30 }Response body
{ "ok": true, "older_than_days": 30, "deleted_files": 12, "freed_bytes": 345678, "messages_affected": 9 }