fix(webhooks): Send full notification object to test endpoint
Build and Push Docker Image / build (push) Successful in 48s
Licence Check / Licence compatibility and copyright header verification (push) Successful in 1m9s
CI / Security audit (push) Successful in 1m23s
CI / Tests & coverage (push) Successful in 1m42s
Build and Push Docker Image / build (push) Successful in 48s
Licence Check / Licence compatibility and copyright header verification (push) Successful in 1m9s
CI / Security audit (push) Successful in 1m23s
CI / Tests & coverage (push) Successful in 1m42s
The /notifications/test endpoint requires the full notification object, not just the ID. Changed testSonarrWebhook() and testRadarrWebhook() to send the complete notification object (sonarrSofarr/radarrSofarr). Fixes: 400 validation error when testing webhooks
This commit is contained in:
+2
-2
@@ -1396,7 +1396,7 @@ async function testSonarrWebhook() {
|
||||
'Content-Type': 'application/json',
|
||||
'X-CSRF-Token': csrfToken || ''
|
||||
},
|
||||
body: JSON.stringify({ id: sonarrSofarr.id })
|
||||
body: JSON.stringify(sonarrSofarr)
|
||||
});
|
||||
if (!res.ok) throw new Error('Test failed');
|
||||
await fetchWebhookStatus();
|
||||
@@ -1424,7 +1424,7 @@ async function testRadarrWebhook() {
|
||||
'Content-Type': 'application/json',
|
||||
'X-CSRF-Token': csrfToken || ''
|
||||
},
|
||||
body: JSON.stringify({ id: radarrSofarr.id })
|
||||
body: JSON.stringify(radarrSofarr)
|
||||
});
|
||||
if (!res.ok) throw new Error('Test failed');
|
||||
await fetchWebhookStatus();
|
||||
|
||||
Reference in New Issue
Block a user