Add a verify_sendgrid_webhook_signature decorator to make Sendgrid Events webhook development easier#138
Conversation
d711cd2 to
c9998c0
Compare
|
This looks like a cool effort, thanks! Just please make sure that we support the Sendrid API versions that implement the webhook signature before spending more time on this. All supported sendgrid/django/python versions can be found in our test matrix |
5772fac to
b0a25e2
Compare
|
Sendgrid v5 doesn't have any support for webhooks. I'm not sure how to skip tests (and imports, etc.) when the But the tests with sendgrid v6 all pass when I run tox locally. Any advice or ideas? |
I have some utils for that. You can see the usage here: django-sendgrid-v5/test/test_mail.py Lines 21 to 24 in 5188d58 |
b0a25e2 to
c79eec1
Compare
…ents webhook development easier
c79eec1 to
9958045
Compare
9958045 to
44d1f03
Compare
|
Thanks for the pointers, got all the tests passing. This should be good to merge. |
sklarsa
left a comment
There was a problem hiding this comment.
lgtm, thank you! I'll cut a release shortly
Add a decorator that verifies the webhook signature for Sendgrid Events.
See: https://www.twilio.com/docs/sendgrid/for-developers/tracking-events/getting-started-event-webhook-security-features#sample-verification-libraries for more information.
Added tests and documentation.