diff options
| author | 2023-08-09 14:36:37 +0800 | |
|---|---|---|
| committer | 2023-08-09 14:36:37 +0800 | |
| commit | 85ec2f7dc55a672b07272a50f11eb86460f38671 (patch) | |
| tree | 8517989c8cc6444df8ae7ae50802a3b81766b01f /tests/plugins/test2.py | |
| parent | 642a278b1e2cc11fee587b933413a30c057753c1 (diff) | |
| download | HydroRoll-85ec2f7dc55a672b07272a50f11eb86460f38671.tar.gz HydroRoll-85ec2f7dc55a672b07272a50f11eb86460f38671.zip | |
feat:all
Diffstat (limited to 'tests/plugins/test2.py')
| -rw-r--r-- | tests/plugins/test2.py | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/tests/plugins/test2.py b/tests/plugins/test2.py new file mode 100644 index 0000000..45b37a9 --- /dev/null +++ b/tests/plugins/test2.py @@ -0,0 +1,15 @@ +from flask import Flask, request + +class Webhooks: + app = Flask(__name__) + requests = request + payload = None + + @app.route('/', method=['POST', 'GET']) + async def handle_webhook(self): + self.payload = await request.get_json() + # 在这里处理接收到的数据 + return 'Webhook received' + + # app.run(host='0.0.0.0',port=3000) + |
