PHPackages                             innoweb/silverstripe-silvershop-stripe - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Payment Processing](/categories/payments)
4. /
5. innoweb/silverstripe-silvershop-stripe

ActiveSilverstripe-vendormodule[Payment Processing](/categories/payments)

innoweb/silverstripe-silvershop-stripe
======================================

Adds stripe customer and creditcard saving to silvershop

2.1.1(8mo ago)43.5k9[1 PRs](https://github.com/xini/silverstripe-silvershop-stripe/pulls)BSD-3-ClausePHP

Since Dec 26Pushed 8mo ago1 watchersCompare

[ Source](https://github.com/xini/silverstripe-silvershop-stripe)[ Packagist](https://packagist.org/packages/innoweb/silverstripe-silvershop-stripe)[ RSS](/packages/innoweb-silverstripe-silvershop-stripe/feed)WikiDiscussions master Synced today

READMEChangelog (1)Dependencies (4)Versions (12)Used By (0)

SilverShop Stripe Support Module
================================

[](#silvershop-stripe-support-module)

Stripe uses a little different payment flow than other processors in that you have to do some clientside javascript work to set it up and you get a token back instead of credit card processing fields.

This module uses Omnipay's Stripe adapter but overrides SilverShop's default checkout component to inject the right JavaScript.

Based on [Mark Guinn's SS3 version](https://github.com/markguinn/silvershop-stripe), extended with saving of the token to the Member object for later use.

Requirements
------------

[](#requirements)

- [SilverStripe CMS](https://github.com/silverstripe/silverstripe-cms) 5
- [SilverShop Core](https://github.com/silvershop/silvershop-core/) 3.1+
- [Omnipay Stripe](https://github.com/thephpleague/omnipay-stripe) 3

uses [Stripe.js v3](https://stripe.com/docs/stripe-js)

Installation
------------

[](#installation)

```
composer require innoweb/silverstripe-silvershop-stripe

```

Configuration
-------------

[](#configuration)

### Payment Intents

[](#payment-intents)

Create a file at `app/_config/payment.yml` that looks something like the following:

```
---
Name: payment
---
SilverStripe\Omnipay\Model\Payment:
  allowed_gateways:
    - 'Stripe_PaymentIntents'

SilverStripe\Omnipay\GatewayInfo:
  Stripe_PaymentIntents:
    failureUrl: '/checkout/summary'
    parameters:
      apiKey: sk_test_SECRET-KEY-FOR-YOUR-TEST-ACCOUNT
      publishableKey: pk_test_PUBLISHABLE-KEY-FOR-TEST-ACCOUNT

---
Only:
  environment: 'live'
---
SilverStripe\Omnipay\GatewayInfo:
  Stripe_PaymentIntents:
    failureUrl: '/checkout/summary'
    parameters:
      apiKey: sk_live_SECRET-KEY-FOR-YOUR-LIVE-ACCOUNT
      publishableKey: pk_live_PUBLISHABLE-KEY-FOR-LIVE-ACCOUNT

```

If needed, the customer will be redirected to Stripe or his bank to verify the transaction via SCA or 3D-Secure.

A custom failure URL can be specified here for when a payment fails (for example, the card was declined).

#### Saving credit cards

[](#saving-credit-cards)

The `Stripe_PaymentIntents` gateway creates Stripe customers and cards when a payment is processed and stores their tokens in the Silverstripe database.

To disable the storage of card tokens and the use of previously stored cards in the checkout process, add the following to your config:

```
---
Name: app-stripe-config
After: silvershop-stripe-config
---
Innoweb\SilvershopStripe\Checkout\Components\StripeOnsitePayment:
  enable_saved_cards: false

```

This will disable storing creadit card tokens in the database and hide the field to select previsouly stored cards in the payment form.

Stripe still records the card tokens on their platform in order to be able to process refunds etc. But there is no reference to the cards in the Silverstripe database.

#### Selecting a previously stored card

[](#selecting-a-previously-stored-card)

To select an existing card, the cards are shown as radio buttons in the payment form.

When there are more than 3 cards stored for a user, the field is displayed as a dropdown.

You can change that threshold by adding the following to your config:

```
Innoweb\SilvershopStripe\Checkout\Components\StripeOnsitePayment:
  radio_button_limit: 100

```

#### Styling the card selection radio buttons

[](#styling-the-card-selection-radio-buttons)

The radio button labels include a rudimentary HTML structure to allow styling. You can add and amend the following styles to your CSS:

```
.field.optionset.existingCreditCards label .cc {
    display: inline-flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
    width: 100%;
    max-width: 20rem;
}
.field.optionset.existingCreditCards label .cc-brand {
    margin-right: auto;
}

```

### Stripe Charge (deprecated)

[](#stripe-charge-deprecated)

Create a file at `app/_config/payment.yml` that looks something like the following:

```
---
Name: payment
---
SilverStripe\Omnipay\Model\Payment:
  allowed_gateways:
    - 'Stripe'

SilverStripe\Omnipay\GatewayInfo:
  Stripe:
    parameters:
      apiKey: sk_test_SECRET-KEY-FOR-YOUR-TEST-ACCOUNT
      publishableKey: pk_test_PUBLISHABLE-KEY-FOR-TEST-ACCOUNT

---
Only:
  environment: 'live'
---
SilverStripe\Omnipay\GatewayInfo:
  Stripe:
    parameters:
      apiKey: sk_live_SECRET-KEY-FOR-YOUR-LIVE-ACCOUNT
      publishableKey: pk_live_PUBLISHABLE-KEY-FOR-LIVE-ACCOUNT

```

License
-------

[](#license)

BSD 3-Clause License, see [License](license.md)

###  Health Score

46

—

FairBetter than 92% of packages

Maintenance59

Moderate activity, may be stable

Popularity28

Limited adoption so far

Community14

Small or concentrated contributor base

Maturity68

Established project with proven stability

 Bus Factor1

Top contributor holds 83.9% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~248 days

Recently: every ~151 days

Total

11

Last Release

260d ago

Major Versions

1.0.0 → 2.0.0-beta12024-07-24

### Community

Maintainers

![](https://www.gravatar.com/avatar/0d2e71d7787401a7bd4916062346163897f89f455d650ab32b5d60cd14825ad3?d=identicon)[xini](/maintainers/xini)

---

Top Contributors

[![xini](https://avatars.githubusercontent.com/u/1152403?v=4)](https://github.com/xini "xini (26 commits)")[![AntonyThorpe](https://avatars.githubusercontent.com/u/1023740?v=4)](https://github.com/AntonyThorpe "AntonyThorpe (4 commits)")[![BettinaMaria98](https://avatars.githubusercontent.com/u/50010683?v=4)](https://github.com/BettinaMaria98 "BettinaMaria98 (1 commits)")

---

Tags

stripesilverstripecardcustomersilvershop

### Embed Badge

![Health badge](/badges/innoweb-silverstripe-silvershop-stripe/health.svg)

```
[![Health](https://phpackages.com/badges/innoweb-silverstripe-silvershop-stripe/health.svg)](https://phpackages.com/packages/innoweb-silverstripe-silvershop-stripe)
```

###  Alternatives

[silverstripe/framework

The SilverStripe framework

7313.7M2.8k](/packages/silverstripe-framework)[silvershop/core

Provides an ecommerce product catalog, shopping cart, and order management system

11341.0k49](/packages/silvershop-core)[sunnysideup/ecommerce

Silverstripe E-commerce Application

247.3k84](/packages/sunnysideup-ecommerce)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
