From 80f01aec07c1f7e27bf75bb7c147f1b699c73d85 Mon Sep 17 00:00:00 2001 From: PCoder Date: Wed, 25 Dec 2019 12:36:47 +0530 Subject: [PATCH] Add steps to be followed for tax_id updated webhook --- webhook/views.py | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/webhook/views.py b/webhook/views.py index 38c18d51..17718b13 100644 --- a/webhook/views.py +++ b/webhook/views.py @@ -14,6 +14,27 @@ from utils.tasks import send_plain_email_task logger = logging.getLogger(__name__) +# Things to do for webhooks feature +# 1. Uninstall old version and install a more recent version of stripe +# ``` +# source venv/bin/activate +# ./manage.py shell +# pip uninstall stripe +# pip install stripe==2.24.1 +# ``` +# 2. Create tax id updated webhook +# ``` +# ./manage.py webhook --create \ +# --webhook_endpoint https://datacenterlight.ch/en-us/webhooks/ \ +# --events_csv customer.tax_id.updated +# ``` +# +# 3. From the secret obtained in 2, setup an environment variable +# ``` +# WEBHOOK_SECRET='whsec......' +# ``` + + @require_POST @csrf_exempt def handle_webhook(request):