https://github.com/okfde/froide-payment
https://github.com/okfde/froide-payment
fragdenstaat
Last synced: 6 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/okfde/froide-payment
- Owner: okfde
- License: mit
- Created: 2019-03-12T20:41:45.000Z (over 7 years ago)
- Default Branch: main
- Last Pushed: 2026-01-12T16:26:20.000Z (7 months ago)
- Last Synced: 2026-01-12T21:58:06.475Z (7 months ago)
- Topics: fragdenstaat
- Language: Python
- Size: 572 KB
- Stars: 2
- Watchers: 8
- Forks: 3
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Froide payment
A Django app that allows running payment campaigns on FOI requests.
## Configure Stripe Webhooks
Include `payments.urls` in root URL pattern.
```python
urlpatterns = [
...
url(r'^payments/', include('payments.urls')),
...
]
```
### Webhook for Credit Card Payments via Payment Intents
Configure these event types:
- `payment_intent.payment_failed`
- `payment_intent.succeeded`
- `customer.subscription.created`
- `customer.subscription.updated`
- `customer.subscription.deleted`
- `invoice.payment_action_required`
- `invoice.upcoming`
- `invoice.created`
Use this URL on your domain:
```
/payments/process/creditcard/
```
### Webhook for SEPA Payments
Configure these event types:
- `payment_intent.processing`
- `charge.dispute.closed`
- `invoice.payment_action_required`
- `invoice.upcoming`
- `invoice.created`
- `invoice.finalized`
- `payment_intent.succeeded`
- `payment_intent.payment_failed`
- `customer.subscription.created`
- `customer.subscription.deleted`
Use this URL on your domain:
```
/payments/process/sepa/
```
### Webhook for Sofort Payments
Configure these event types:
- `charge.succeeded`
- `charge.failed`
- `source.chargeable`
- `source.failed`
Use this URL on your domain:
```
/payments/process/sofort/
```
### Webhook for Paypal Payments
Configure these event types:
-
Use this URL on your domain:
```
/payments/process/paypal/
```
## Configure Payment variants
```python
PAYMENT_VARIANTS = {
# 'default': ('payments.dummy.DummyProvider', {})
'creditcard': ('froide_payment.provider.StripeIntentProvider', {
# Test API keys
'public_key': '',
'secret_key': '',
# separate Webhook signing secret
'signing_secret': '',
}),
'sepa': ('froide_payment.provider.StripeSourceProvider', {
# Test API keys
'public_key': '',
'secret_key': '',
# separate Webhook signing secret
'signing_secret': '',
}),
'paypal': ('payments.paypal.PaypalProvider', {
'client_id': '',
'secret': '',
'endpoint': '',
'capture': True,
'webhook_id': ''
}),
'sofort': ('froide_payment.provider.StripeSofortProvider', {
# Test API keys
'public_key': '',
'secret_key': '',
# separate Webhook signing secret
'signing_secret': '',
}),
}
```