jinjie / stripe-product-checkout
A very simple stripe checkout for SilverStripe
Installs: 10
Dependents: 0
Suggesters: 0
Security: 0
Stars: 1
Watchers: 2
Forks: 0
Open Issues: 0
Type:silverstripe-vendormodule
Requires
- bummzack/sortablefile: ^2.0
- silverstripe/cms: ^4
- silverstripe/framework: ^4
- silverstripe/lumberjack: ^2.0
- stripe/stripe-php: ^7.27
This package is auto-updated.
Last update: 2024-11-15 15:57:31 UTC
README
This does not intend to be a full e-commerce solution.
Installation
composer require jinjie/stripe-product-checkout
Configuration
Add Stripe keys to .env
file
STRIPE_PK="<PUBLISHABLE KEY>"
STRIPE_SK="<SECRET KEY>"
Extending
By default, only the product will be used in line_items in checkout. You can change this with something like below.
StripeProductCheckout\Controllers\ProductController:
extensions:
- MyProductExtension
// ...
public function updateCheckoutItems(&$items)
{
// Manipulate $items array here to be used in line_items
}
// ...