added debugging prints
This commit is contained in:
parent
d720481c26
commit
9a9174f687
@ -22,6 +22,7 @@ def is_command(command:str)->bool:
|
||||
def handle_command(command, rest):
|
||||
if command == "!echo":
|
||||
message = "Got payload [%s]" % rest
|
||||
print(message)
|
||||
return flask.make_response("{message:\"%s\"}" % message, 200, {"Content-Type": "application/json"})
|
||||
|
||||
@api.route('/api/v1/command', methods=['GET'])
|
||||
|
||||
@ -1,10 +1,11 @@
|
||||
from json import loads
|
||||
import re
|
||||
from json import loads
|
||||
from urllib.parse import urlencode
|
||||
|
||||
import requests
|
||||
import twitch
|
||||
import twitch.chat
|
||||
from urllib.parse import urlencode, quote_plus
|
||||
|
||||
import config as config
|
||||
import credentials
|
||||
from cooldowns import Cooldown_Module
|
||||
@ -98,6 +99,7 @@ class Twitch_Module():
|
||||
url = "http://localhost:5000/api/v1/exec?%s" % params
|
||||
resp = requests.get(url)
|
||||
if resp.status_code == 200:
|
||||
print("Got the following message: %s" % resp.text)
|
||||
data = loads(resp.text)
|
||||
msg = data['message']
|
||||
if msg is not None:
|
||||
|
||||
Loading…
Reference in New Issue
Block a user