diff --git a/config.json.example b/config.json.example index 124a790..634cc0c 100644 --- a/config.json.example +++ b/config.json.example @@ -9,6 +9,7 @@ "discordFirstTimeSubmissionsWebhookURL": null, //URL from discord if you would like notifications when someone makes a first time submission [optional] "discordCompletelyIncorrectReportWebhookURL": null, //URL from discord if you would like notifications when someone reports a submission as completely incorrect [optional] "neuralBlockURL": null, // URL to check submissions against neural block. Ex. https://ai.neuralblock.app + "discordNeuralBlockRejectWebhookURL": null, //URL from discord if you would like notifications when NeuralBlock rejects a submission [optional] "proxySubmission": null, // Base url to proxy submissions to persist // e.g. https://sponsor.ajay.app (no trailing slash) "behindProxy": "X-Forwarded-For", //Options: "X-Forwarded-For", "Cloudflare", "X-Real-IP", anything else will mean it is not behind a proxy. True defaults to "X-Forwarded-For" "db": "./databases/sponsorTimes.db", diff --git a/test.json b/test.json index 6950605..841322e 100644 --- a/test.json +++ b/test.json @@ -4,9 +4,10 @@ "globalSalt": "testSalt", "adminUserID": "testUserId", "youtubeAPIKey": "", - "discordReportChannelWebhookURL": "http://127.0.0.1:8081/ReportChannelWebhook", - "discordFirstTimeSubmissionsWebhookURL": "http://127.0.0.1:8081/FirstTimeSubmissionsWebhook", + "discordReportChannelWebhookURL": "http://127.0.0.1:8081/ReportChannelWebhook", + "discordFirstTimeSubmissionsWebhookURL": "http://127.0.0.1:8081/FirstTimeSubmissionsWebhook", "discordCompletelyIncorrectReportWebhookURL": "http://127.0.0.1:8081/CompletelyIncorrectReportWebhook", + "discordNeuralBlockRejectWebhookURL": "http://127.0.0.1:8081/NeuralBlockRejectWebhook", "neuralBlockURL": "http://127.0.0.1:8081/NeuralBlock", "behindProxy": true, "db": "./test/databases/sponsorTimes.db", diff --git a/test/mocks.js b/test/mocks.js index ad8bceb..ddf7f19 100644 --- a/test/mocks.js +++ b/test/mocks.js @@ -16,6 +16,9 @@ app.post('/CompletelyIncorrectReportWebhook', (req, res) => { }); // Testing NeuralBlock +app.post('/NeuralBlockRejectWebhook', (req, res) => { + res.sendStatus(200); +}); app.get('/NeuralBlock/api/checkSponsorSegments', (req, res) => { if (req.query.vid === "LevkAjUE6d4") { @@ -45,4 +48,4 @@ app.post('/CustomWebhook', (req, res) => { module.exports = function createMockServer(callback) { return app.listen(config.mockPort, callback); -} \ No newline at end of file +}