Update configs for NB discord URLs

This commit is contained in:
Andrew Lee 2020-09-05 16:56:23 -04:00
parent ba68969943
commit e8116de4bb
3 changed files with 8 additions and 3 deletions

View file

@ -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",

View file

@ -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",

View file

@ -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);
}
}