File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -17,7 +17,7 @@ Installation
1717Configuration
1818-------------
1919
20- import and configure the library with your Castle API secret.
20+ Import and configure the library with your Castle API secret.
2121
2222.. code :: python
2323
@@ -231,6 +231,20 @@ Exceptions
231231level HTTP response. You can also choose to catch a more `finegrained
232232error <https://github.com/castle/castle-python/blob/master/castle/errors.py> `__.
233233
234+ Webhooks
235+ --------
236+
237+ Castle uses webhooks to notify about ``$incident.confirmed `` or `$review.opened ` events.
238+ Each webhook has ``X-Castle-Signature `` header that allows verifying webhook's source.
239+
240+ .. code :: python
241+
242+ from castle.webhooks.verify import WebhooksVerify
243+
244+ # Verify the webhook, passed as a Request object
245+ WebhooksVerify.call(webhook_request)
246+ # WebhookVerificationError is raised when the signature is not matching
247+
234248 Documentation
235249-------------
236250
You can’t perform that action at this time.
0 commit comments