From d937435bce903b6b81e7bf6a912f07adb0cae2aa Mon Sep 17 00:00:00 2001 From: Arshad Kazmi Date: Fri, 19 Oct 2018 15:33:46 +0530 Subject: [PATCH 1/2] Function names to match with routes --- sms/dlr-flask.py | 2 +- voice/handle-user-input.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/sms/dlr-flask.py b/sms/dlr-flask.py index fed8d4f..ec35021 100644 --- a/sms/dlr-flask.py +++ b/sms/dlr-flask.py @@ -4,7 +4,7 @@ app = Flask(__name__) @app.route('/webhooks/delivery-receipt', methods=['GET', 'POST']) -def delivery_receipt(): +def inbound_sms(): if request.is_json: pprint(request.get_json()) else: diff --git a/voice/handle-user-input.py b/voice/handle-user-input.py index a1e80d4..cb565f6 100755 --- a/voice/handle-user-input.py +++ b/voice/handle-user-input.py @@ -26,7 +26,7 @@ def answer_call(): @app.route("/webhooks/dtmf", methods=['POST']) -def inout_webhook(): +def input_webhook(): data = request.get_json() pprint(data) ncco =[ From e04cb80f17ee21feb1767783b4db1500f8203c20 Mon Sep 17 00:00:00 2001 From: Arshad Kazmi Date: Mon, 22 Oct 2018 21:34:24 +0530 Subject: [PATCH 2/2] Reverted wrong changes, Made correct function name changes --- sms/dlr-flask.py | 2 +- sms/receive-flask.py | 2 +- voice/handle-user-input.py | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/sms/dlr-flask.py b/sms/dlr-flask.py index ec35021..fed8d4f 100644 --- a/sms/dlr-flask.py +++ b/sms/dlr-flask.py @@ -4,7 +4,7 @@ app = Flask(__name__) @app.route('/webhooks/delivery-receipt', methods=['GET', 'POST']) -def inbound_sms(): +def delivery_receipt(): if request.is_json: pprint(request.get_json()) else: diff --git a/sms/receive-flask.py b/sms/receive-flask.py index 8151f95..9fbe3a3 100644 --- a/sms/receive-flask.py +++ b/sms/receive-flask.py @@ -4,7 +4,7 @@ app = Flask(__name__) @app.route('/webhooks/inbound-sms', methods=['GET', 'POST']) -def delivery_receipt(): +def inbound_sms(): if request.is_json: pprint(request.get_json()) else: diff --git a/voice/handle-user-input.py b/voice/handle-user-input.py index cb565f6..3c686c6 100755 --- a/voice/handle-user-input.py +++ b/voice/handle-user-input.py @@ -26,7 +26,7 @@ def answer_call(): @app.route("/webhooks/dtmf", methods=['POST']) -def input_webhook(): +def dtmf(): data = request.get_json() pprint(data) ncco =[