From 543b9be2c1b1a7650f455086938e72bc4879e94a Mon Sep 17 00:00:00 2001 From: Oliver Akins Date: Tue, 9 Aug 2022 19:11:28 -0600 Subject: [PATCH] Add header info file for Nightbot --- src/schemas/nightbot.ts | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 src/schemas/nightbot.ts diff --git a/src/schemas/nightbot.ts b/src/schemas/nightbot.ts new file mode 100644 index 0000000..c9f5996 --- /dev/null +++ b/src/schemas/nightbot.ts @@ -0,0 +1,21 @@ +import Joi from "joi"; + +export const nightbotCustomHeadersSchema = Joi.object({ + "nightbot-response-url": Joi + .string() + .uri({ scheme: `https` }) + .optional(), + "nightbot-user": Joi + .string() + .optional(), + "nightbot-channel": Joi + .string() + .optional(), +}) +.and( + "nightbot-response-url", + "nightbot-user", + "nightbot-channel", +) +.meta({ className: `nightbotCustomHeaders` }) +.description(`The custom headers Nightbot makes requests with`); \ No newline at end of file