From 7631527f465a28d13cad163039baa61364617b4b Mon Sep 17 00:00:00 2001 From: Wild Dragon Dev Date: Wed, 3 Jun 2026 22:11:15 +0000 Subject: [PATCH] fix(capture): add auth header to finalize call in POST /capture/stop --- services/capture/src/routes/capture.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/services/capture/src/routes/capture.js b/services/capture/src/routes/capture.js index f9444aa..628023f 100644 --- a/services/capture/src/routes/capture.js +++ b/services/capture/src/routes/capture.js @@ -484,7 +484,10 @@ router.post('/stop', async (req, res) => { const mamResponse = await fetch(`${MAM_API_URL}/api/v1/assets/${completedSession.assetId}/${path}`, { method: 'POST', - headers: { 'Content-Type': 'application/json' }, + headers: { + 'Content-Type': 'application/json', + ...(MAM_API_TOKEN ? { Authorization: `Bearer ${MAM_API_TOKEN}` } : { 'X-Requested-With': 'dragonflight-ui' }), + }, body: JSON.stringify(body), }); if (!mamResponse.ok) {