From 9c5acd2b99b7391ba0d7f6fef91b78b3f2fa159e Mon Sep 17 00:00:00 2001 From: Someone Date: Mon, 5 Sep 2022 21:27:01 +0200 Subject: [PATCH] modules/CommandCurriculaSave.py --- modules/CommandCurriculaSave.py | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/modules/CommandCurriculaSave.py b/modules/CommandCurriculaSave.py index 33d2a17..5c4f52a 100644 --- a/modules/CommandCurriculaSave.py +++ b/modules/CommandCurriculaSave.py @@ -7,7 +7,8 @@ from inspect import cleandoc # pylint: disable=wrong-import-position from AbstractCommand import AbstractCommand -class CommandCurriculaSave(AbstractCommand): +from AbstractPublicWS import AbstractPublicWS +class CommandCurriculaSave(AbstractCommand,AbstractPublicWS): TRIGGER = "curricula-save" CONFIG = {"display_name": "somebot-command", "auto_complete": True, "auto_complete_hint": "", @@ -43,3 +44,9 @@ class CommandCurriculaSave(AbstractCommand): def on_POST_interactive(self, request, data): if data["context"]["action"] == "delete_self": self.bot.api.delete_post(data["post_id"]) + + def on_public_GET(self, request, data): + request.respond_public(200, {"asdf":"qwer"}) + + def on_public_POST(self, request, data): + return 'post-qwer' -- 2.43.0