Skip to content

Latest commit

 

History

History

webhook-test-project

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 

README.md

Webhook Test Project (Flask)

This example project helps you validate Python SDK webhook signature verification locally.

What it includes

  • receiver.py: local webhook endpoint that verifies and parses events
  • send_test_webhook.py: sends a signed test webhook request to your local endpoint

Setup

cd packages/python-sdk/example/webhook-test-project
python -m venv .venv
source .venv/bin/activate
pip install -r requirements.txt

Run

Terminal 1:

python receiver.py

Terminal 2:

python send_test_webhook.py

You should see:

  • 200 response from the receiver
  • parsed webhook event output in the receiver terminal

Environment variables

  • BYTESEND_WEBHOOK_SECRET (default: whsec_test)
  • WEBHOOK_URL (default: http://127.0.0.1:8000/webhook)

Use the same BYTESEND_WEBHOOK_SECRET for both scripts.