Proposal for widening use case to GoCardless (and others)
After a lot of research and discussion with @mattwire, I think this is the way to go.
- changes schema (upgrader included): adding indexes, fields, modifying existing fields to be more efficent, using 'new' not NULL for status.
- a PaymentprocessorWebhook record describes and event, not the contents of a webhook. These are one and the same in systems where one event = one webhook, but for others (e.g. GoCardless) this is an important distiction.
- To implement this, Payment processor extensions only need to tweak their handlePaymentNotification method, and add a new processWebhookEvent() method.
- Existing Stripe support (legacy code) has been kept for backwards compat.
- Docs updated a lot, with sample/pseudo code.
Edited by Rich