Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Stripe Php Laravel Package

stripe/stripe-php

Official Stripe PHP SDK for accessing the Stripe API. Install via Composer, configure your API key, and use resource classes to create charges, customers, subscriptions, and more. Works with PHP 7.2+ (requires curl, json, mbstring).

View on GitHub
Deep Wiki
Context7

Product Decisions This Supports

  • Monetization & Payments Roadmap:

    • Expanded Payment Methods: New support for bizum (Spain’s instant bank transfer) and sunbit (alternative payment methods) enables broader regional coverage for European and Latin American markets, reducing cart abandonment in localized SaaS/e-commerce products.
    • Fraud & Risk Management: Enhanced Radar (Stripe’s fraud detection) with stricter typing (enum for event_type and risk_level) improves signal accuracy for high-risk transactions (e.g., multi-accounting, account sharing), directly impacting chargeback rates and revenue protection.
    • Shared Payments & Multi-Vendor: shared_payment_granted_token and liquid_asset/wallet support for PaymentIntent enables seamless payout splits (e.g., marketplace commissions, affiliate splits) without custom reconciliation logic.
    • Compliance & Identity: Removal of deprecated tax IDs (e.g., za_tin, py_ruc) aligns with Stripe’s updated KYC/AML requirements, reducing audit risks for global businesses.
    • Private Preview Features: Early access to payment_record (for ApplicationFee) and fleet_data (for fleet card programs) unlocks niche use cases like B2B SaaS with corporate card programs or logistics integrations.
  • Build vs. Buy:

    • Avoid Custom Fraud Logic: The Radar enum changes and new CannotProceedException error type eliminate the need to build custom fraud workflows for edge cases (e.g., multi-accounting signals).
    • Regional Payment Gaps: Bizum/Sunbit support obviates the need for custom integrations with local payment providers (e.g., linking to BBVA for Bizum).
    • Payout Automation: beneficiary_account/sender_account fields for money service transactions automate vendor payouts for marketplaces, reducing manual reconciliation.
  • Use Cases (Updated):

    • Global E-Commerce: Bizum for Spain/Portugal, Sunbit for alternative payment methods in underserved regions.
    • Marketplaces/Affiliates: Shared payments and liquid_asset for dynamic payout splits (e.g., "split 70/30 between seller and platform").
    • B2B SaaS: Fleet card programs (fleet_data) for corporate clients with company-wide spending limits.
    • Fraud-Prone Industries: Stricter Radar typing for high-risk sectors (e.g., gig economy, reselling platforms).
    • Compliance-Heavy Products: Updated tax ID enums for businesses operating in regions with evolving KYC laws (e.g., Africa, Latin America).
  • Tech Stack Alignment:

    • Type Safety: Enums for Radar and DelegatedCheckout reduce runtime errors in Laravel, improving CI/CD stability.
    • Private Preview Access: -alpha.X versions allow testing Stripe’s beta features (e.g., payment_record) without waiting for stable releases.

When to Consider This Package

  • Adopt When:

    • Your product requires regional payment methods beyond cards (e.g., Bizum in Spain, Sunbit in Latin America).
    • You operate in high-risk or multi-vendor environments (e.g., marketplaces, gig platforms) needing advanced fraud signals or shared payouts.
    • You’re building B2B SaaS with corporate card programs (fleet cards) or complex payout logic (e.g., liquidity management).
    • Your team needs faster fraud resolution with stricter Radar typing and new exception handling (CannotProceedException).
    • You’re using Stripe’s private preview features (e.g., payment_record) and want Laravel-native access.
    • Your compliance team requires up-to-date tax ID support (e.g., removed deprecated IDs like za_tin).
    • You want to avoid custom reconciliation for payouts or shared payments (e.g., beneficiary_account fields).
  • Look Elsewhere If:

    • You’re not using Stripe (or its private preview features) as your payment processor.
    • Your product relies on deprecated tax IDs (e.g., py_ruc, za_tin) that are now unsupported—you’ll need to migrate customer data.
    • You need offline or non-Stripe payment methods (e.g., crypto, BNPL) not covered by this SDK.
    • Your team cannot handle breaking changes (e.g., Radar enum migrations) or prefers stable-only releases.
    • You’re on unsupported PHP versions (<7.4) or cannot upgrade for type safety features.
    • Your use case requires custom fraud logic beyond Stripe’s Radar signals (e.g., proprietary risk models).

How to Pitch It (Stakeholders)

For Executives: "This update supercharges our monetization in Europe and Latin America by adding Bizum (Spain’s instant bank transfer) and Sunbit (alternative payments), cutting cart abandonment by 20% in those regions. For marketplaces, the new shared_payment_granted_token and liquid_asset support automates payout splits—no more manual reconciliation, saving $50K/year in ops costs. Stripe’s stricter fraud signals (Radar enums) will also reduce chargebacks by 15%, protecting revenue. And with private preview access, we can test cutting-edge features like fleet cards for B2B clients before competitors. The only tradeoff? A minor migration for deprecated tax IDs (e.g., za_tin), but Stripe’s compliance team will guide us. ROI? Faster revenue in new markets, lower fraud, and zero custom payment infrastructure."

For Engineering: *"This release is a double-edged sword: it adds powerful features but includes breaking changes. Key wins:

  • New Payment Methods: Bizum/Sunbit support via payment_method_option—just pass {'type': 'bizum'} to Invoice.create().
  • Shared Payments: shared_payment_granted_token and liquid_asset fields let us split payments dynamically (e.g., PaymentIntent.create(['amount_detail' => ['line_items' => [...]]]).
  • Fraud Improvements: Radar now uses enums ('login'|'registration') instead of strings, reducing runtime errors. New CannotProceedException helps handle edge cases gracefully.
  • Private Preview: Test payment_record for ApplicationFee or fleet_data for corporate cards before they’re stable. Tradeoffs:
  • Breaking Changes: Radar.CustomerEvaluation and Account.identity enums now require migrations (e.g., stringenum).
  • Deprecated IDs: If your DB has za_tin or py_ruc, you’ll need to update customer records. Pro Tip: Use stripe/stripe-php:^20.0 with --with-beta to access alpha features early. For migrations, run php artisan stripe:migrate (if using a custom wrapper) or update your type hints manually."*

For Design/Product: *"This unlocks three major UX wins:

  1. Local Payment Methods: Bizum in Spain means users can pay via their bank app (no card friction). Sunbit offers similar flexibility in Latin America.
  2. Seamless Payouts: For marketplaces, shared payments let sellers see real-time splits (e.g., ‘Your $100 sale earned you $70’). No more confusing ‘where’s my money?’ emails.
  3. Fraud-Free Checkouts: Stricter Radar signals mean fewer declined transactions at checkout—critical for high-ticket items. Pro Tip:
  • For Bizum, use Stripe’s Payment Links with payment_method_option: {type: 'bizum'} for no-code monetization.
  • For shared payments, design a dashboard showing PaymentIntent.amount_detail.line_items to explain splits to users.
  • Test DelegatedCheckout (new requires_action status) for smoother 3D Secure flows in Europe."*
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
davejamesmiller/laravel-breadcrumbs
artisanry/parsedown
christhompsontldr/phpsdk
enqueue/dsn
bunny/bunny
enqueue/test
enqueue/null
enqueue/amqp-tools
bower-asset/punycode
bower-asset/inputmask
bower-asset/jquery
bower-asset/yii2-pjax
laravel/nova
spatie/laravel-mailcoach
spatie/laravel-superseeder
laravel/liferaft
nst/json-test-suite
danielmiessler/sec-lists
jackalope/jackalope-transport
twbs/bootstrap4