PHPackages                             64robots/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. 64robots/stripe

ActiveLibrary[Payment Processing](/categories/payments)

64robots/stripe
===============

A package to add stripe integration 64 robots packages

1.11.0(5y ago)57.0k11MITPHPPHP ^7.1CI failing

Since Jan 7Pushed 6mo ago3 watchersCompare

[ Source](https://github.com/64robots/stripe)[ Packagist](https://packagist.org/packages/64robots/stripe)[ RSS](/packages/64robots-stripe/feed)WikiDiscussions master Synced 6d ago

READMEChangelog (10)Dependencies (7)Versions (28)Used By (1)

Add stripe integration to laravel applications
==============================================

[](#add-stripe-integration-to-laravel-applications)

This package makes it easier to add stripe integrations to laravel applications

Installation and setup
----------------------

[](#installation-and-setup)

To get the latest version, simply require the package using [Composer](https://getcomposer.org):

```
$ composer require 64robots/stripe
```

Once installed, this package will automatically register its service provider.

To publish the config file to `config/stripe.php` run:

```
$ php artisan vendor:publish --provider="R64\Stripe\StripeServiceProvider" --tag="config"
```

Usage
-----

[](#usage)

The class you'd propably interact with the most is `PaymentProcessor` class. The processor class can be injected into other classes or can be resolved from the container.

```
use R64\Stripe\PaymentProcessor;
.
.
.

$processor = app(PaymentProcessor::class);

$charge = $processor->createCharge([
    'customer' => 'cus_GVIiC06JWCq1mo',
    'amount' => 100,
    'currency' => 'USD',
    'source' => 'tok_visa'
]);

```

### Charges

[](#charges)

- To charge a credit or a debit card, you create a Charge object. You can create a charge using the `createCharge` method on the `PaymentProcessor` class. A `R64\Stripe\Objects\Charge` object would be returned.

```
$charge = $processor->createCharge([
    'customer' => 'cus_GVIiC06JWCq1mo',
    'amount' => 100,
    'currency' => 'USD',
    'source' => 'tok_visa'
]);

```

### Customers

[](#customers)

The processor allows you to create, update, list customers and get a single customer.

- To create a customer, use the `createCustomer` method on the processor. A `R64\Stripe\Objects\Customer` object would be returned.

```
$customer = $processor->createCustomer([
    'description' => 'Customer for jenny.rosen@example.com',
    'source' => 'tok_visa',
    'email' => jenny.rosen@example.com,
    'metadata' => [
        'first_name' => Rosen,
        'last_name' => Gina,
    ]
]);

```

- To update a customer, use the `updateCustomer` method on the processor. A `R64\Stripe\Objects\Customer` object would be returned.

```
$customer = $processor->updateCustomer([
    'id' => 1,
    'email' => jenny.rosen@example.com,
    'description' => Update jenny.rosen@example.com details,
    'source' => 'tok_visa'
]);

```

- To get a single customer, use the `getCustomer` method on the processor. A `R64\Stripe\Objects\Customer` object would be returned.

```
$customer = $processor->getCustomer('cus_GVIiC06JWCq1mo');

```

### Card

[](#card)

You can get a card, create and update a card using the processor.

- To get a single card details, use the `getCard` method on the processor. A `R64\Stripe\Objects\Card` object would be returned.

```
$card = $processor->getCard('cus_GVIiC06JWCq1mo', 'card_1FyI6w2eZvKYlo2COseWzZAo');

```

- To create a card, use the `createCard` method on the processor. A `R64\Stripe\Objects\Card` object would be returned.

```
$card = $processor->createCard([
    'source' => 'tok_visa'
]);

```

- To update a card, use the `updateCard` method on the processor. A `R64\Stripe\Objects\Card` object would be returned.

```
$card = $processor->updateCard(
    'cus_GVIiC06JWCq1mo',
    'card_1FyI6w2eZvKYlo2COseWzZAo',
    [
        'name' => 'Jenny Rosen'
    ]
);

```

### Plan and Subscription

[](#plan-and-subscription)

Plans define the base price, currency, and billing cycle for subscriptions.

- To create a product, use the `createProduct` method on the processor. A `R64\Stripe\Objects\Product` object would be returned.

```
$product = $processor->createProduct([
    'name' => 'Monthly membership base fee',
    'type' => 'service',
]);

```

- To create a plan, use the `createPlan` method on the processor. A `R64\Stripe\Objects\Plan` object would be returned.

```
$plan = $processor->createPlan([
    'product' => ['name' => 'Gold special'],
    'nickname' => 'special,
    'interval' => 'month',
    'billing_scheme' => 'per_unit',
    'amount' => 100,
    'currency' => 'usd'
]);

```

- To create a subscription, use the `createSubscription` method on the processor. A `R64\Stripe\Objects\Subscription` object would be returned.

```
$subscription = $processor->createSubscription([
    'customer' => 'cus_GVIiC06JWCq1mo',
    'items' => [
        [
            'object' => 'list',
            'plan' => plan_GVIh1z2696UJyR
        ]
    ]
]);

```

- To create an invoice, use the `createInvoice` method on the processor. A `R64\Stripe\Objects\Invoice` object would be returned.

```
$invoice = $processor->createInvoice([
    'customer' => 'cus_GVIiC06JWCq1mo',
    'subscription' => 'sub_DUVhBH3LKxekhs',
]);

```

- To create an invoice item, use the `createInvoiceItem` method on the processor. A `R64\Stripe\Objects\InvoiceItem` object would be returned.

```
$invoiceItem = $processor->createInvoiceItem([
    'customer' => 'cus_GVIiC06JWCq1mo',
    'subscription' => 'sub_DUVhBH3LKxekhs',
    'amount' => 100,
    'currency' => 'usd',
]);

```

- To get an invoice details, use the `getInvoice` method. A `R64\Stripe\Objects\Invoice` object would be returned.

```
$invoice = $this->processor->getInvoice('in_1FJSdj2eZvKYlo2CCyOhyNxj');

```

- To get a subscription details, use the `getSubscription` method. A `R64\Stripe\Objects\Subscription` object would be returned.

```
$subscription = $this->processor->getSubscription(sub_DUVhBH3LKxekhs);

```

### Card Holder

[](#card-holder)

You can create, update and get a card holder's details.

- To create a card holder, use the `createCardHolder` method. A `R64\Stripe\Objects\CardHolder` object would be returned.

```
$cardHolder = $processor->createCardHolder([
    'type' => 'individual',
    'name' => 'Jenny Rosen',
    'email' => 'jenny.rosen@example.com',
    'phone_number' => '+18888675309',
    'billing' => [
        'name' => 'Jenny Rosen',
        'address' => [
        'line1' => '1234 Main Street',
        'city' => 'San Francisco',
        'state' => 'CA',
        'country' => 'US',
        'postal_code' => '94111',
        ],
    ],
]);

```

- To update a card holders details, use the `updateCardHolder` method. A `R64\Stripe\Objects\CardHolder` object would be returned.

```
$cardHolder = $processor->updateCardHolder([
    'ich_1Ccy6F2eZvKYlo2ClnIm9bs4',
    [
        'metadata' => [
            'order_id' => '6735'
        ]
    ]
])

```

- To retrieve a card holder, use the `getCardHolder` method. A `R64\Stripe\Objects\CardHolder` object would be returned.

```
$cardHolder = $processor->getCardHolder('ich_1Ccy6F2eZvKYlo2ClnIm9bs4');

```

###  Health Score

41

—

FairBetter than 89% of packages

Maintenance46

Moderate activity, may be stable

Popularity27

Limited adoption so far

Community18

Small or concentrated contributor base

Maturity62

Established project with proven stability

 Bus Factor2

2 contributors hold 50%+ of commits

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 ~111 days

Recently: every ~369 days

Total

20

Last Release

206d ago

PHP version history (2 changes)v1.0.0PHP ^7.1

v1.1.3PHP ^7.1|^8.0

### Community

Maintainers

![](https://www.gravatar.com/avatar/88e19e84d31e5f50eb2e338915669ae04f507a643fa24f88afc870520d8bef23?d=identicon)[64robots](/maintainers/64robots)

![](https://www.gravatar.com/avatar/d9789811ef6a364a9920860c12abf5c3ae889c20436364d008c5b5a0b454b49f?d=identicon)[NtimYeboah](/maintainers/NtimYeboah)

---

Top Contributors

[![jonrobinson](https://avatars.githubusercontent.com/u/1872553?v=4)](https://github.com/jonrobinson "jonrobinson (22 commits)")[![NtimYeboah](https://avatars.githubusercontent.com/u/8011922?v=4)](https://github.com/NtimYeboah "NtimYeboah (19 commits)")[![mmanzano](https://avatars.githubusercontent.com/u/1055699?v=4)](https://github.com/mmanzano "mmanzano (13 commits)")[![MichalGallovic](https://avatars.githubusercontent.com/u/5698422?v=4)](https://github.com/MichalGallovic "MichalGallovic (5 commits)")[![EdgarSidawi](https://avatars.githubusercontent.com/u/48221327?v=4)](https://github.com/EdgarSidawi "EdgarSidawi (1 commits)")

---

Tags

stripe64RobotsR64

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/64robots-stripe/health.svg)

```
[![Health](https://phpackages.com/badges/64robots-stripe/health.svg)](https://phpackages.com/packages/64robots-stripe)
```

###  Alternatives

[simonhamp/laravel-stripe-connect

1343.1k](/packages/simonhamp-laravel-stripe-connect)[musahmusah/laravel-multipayment-gateways

A Laravel Package that makes implementation of multiple payment Gateways endpoints and webhooks seamless

852.2k1](/packages/musahmusah-laravel-multipayment-gateways)[flux-se/sylius-stripe-plugin

Sylius Stripe plugin using Payment Request

1029.3k](/packages/flux-se-sylius-stripe-plugin)

PHPackages © 2026

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