Stripe Payment Module for LiBilling
  • PHP 94.5%
  • Blade 5.5%
Find a file
Troy Siedsma a47087268e Webhook hardening: throttle endpoint, serialize refund cap check
- Throttle the inbound webhook per IP (240/min) as an abuse/amplification
  backstop; signature verification still fails closed and Stripe retries on 429.
- Wrap the refund record-modify-write in a transaction with a row lock on the
  original payment so two DISTINCT partial refunds delivered concurrently can't
  both read a stale cumulative and over-refund. The refund-id unique only
  backstopped exact duplicates.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-26 03:57:06 +00:00
config Re-platform onto LiBilling/libilling-stripe Forgejo origin 2026-05-22 13:14:19 +00:00
resources Re-platform onto LiBilling/libilling-stripe Forgejo origin 2026-05-22 13:14:19 +00:00
routes Webhook hardening: throttle endpoint, serialize refund cap check 2026-06-26 03:57:06 +00:00
src Webhook hardening: throttle endpoint, serialize refund cap check 2026-06-26 03:57:06 +00:00
.gitattributes Re-platform onto LiBilling/libilling-stripe Forgejo origin 2026-05-22 13:14:19 +00:00
.gitignore Re-platform onto LiBilling/libilling-stripe Forgejo origin 2026-05-22 13:14:19 +00:00
CHANGELOG.md Re-platform onto LiBilling/libilling-stripe Forgejo origin 2026-05-22 13:14:19 +00:00
composer.json Standardize composer.json + README + LICENSE 2026-05-22 15:04:04 +00:00
CONTRIBUTING.md Re-platform onto LiBilling/libilling-stripe Forgejo origin 2026-05-22 13:14:19 +00:00
LICENSE.md LICENSE: Copyright (c) Lithium Holdings, LLC 2026-05-22 15:13:49 +00:00
README.md Standardize composer.json + README + LICENSE 2026-05-22 15:04:04 +00:00

LiBilling Stripe Payment Gateway Module

A LiBilling payment gateway module for Stripe. Provides credit card management, subscription billing, one-time charges, refunds, and Stripe Checkout through Laravel Cashier.

Features

  • Subscription Billing: Recurring charges via Stripe subscriptions
  • One-Time Charges: Single payment processing
  • Refunds: Full and partial refund support
  • Stripe Checkout: Hosted checkout sessions
  • Webhooks: Stripe webhook event processing
  • Card Management: Customer card add, remove, and default management

Installation

This package is loaded as a local Composer path repository. No separate installation is needed when developing within the LiBilling monorepo.

For standalone installation:

composer require libilling/libilling-stripe

Configuration

Stripe is configured through Laravel Cashier's standard environment variables:

STRIPE_KEY=pk_test_xxxxx
STRIPE_SECRET=sk_test_xxxxx
STRIPE_WEBHOOK_SECRET=whsec_xxxxx

Publish the package config if you need additional options:

php artisan vendor:publish --tag=libilling-stripe

Capabilities

Declared via supports() using GatewayCapability constants:

  • charge: One-time credit card charges
  • refund: Full and partial refunds
  • subscription: Recurring billing via Stripe subscriptions
  • checkout: Stripe Checkout sessions
  • webhooks: Stripe webhook event processing
  • card_management: Customer card add/remove/default management

Dependencies

  • laravel/cashier: Laravel Cashier for Stripe
  • lithiumhosting/laravel-stripe-billing: Extended Stripe billing utilities

Testing

vendor/bin/sail artisan test --filter=ModuleSystemTest

License

LiBilling is (C) Lithium Holdings, LLC. All components except for third-party modules and select packages with their own license are licensed under a Commercial License. Contact licensing@lithiumholdings.com for licensing enquiries. Any dissemination of material herein is prohibited without expressed written consent of Lithium Holdings.

This package, libilling-stripe is licensed under The MIT License (MIT). Please see License File for more information.

Is it any good?

Yes.

When people first hear about a new product, they frequently ask if it is any good. A Hacker News user remarked:

Note to self: Starting immediately, all raganwald projects will have a "Is it any good?" section in the readme, and the answer shall be "yes.".