PHPackages                             jeanfprado/cashier - 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. jeanfprado/cashier

ActiveLibrary[Payment Processing](/categories/payments)

jeanfprado/cashier
==================

 Cashier provides a subscription billing services.

0.1.6(3y ago)025MITPHPPHP ^7.3|^8.0|^8.1

Since Apr 7Pushed 3y ago1 watchersCompare

[ Source](https://github.com/jeanfprado/cashier)[ Packagist](https://packagist.org/packages/jeanfprado/cashier)[ Docs](https://github.com/jeanfprado/cashier)[ RSS](/packages/jeanfprado-cashier/feed)WikiDiscussions main Synced 1mo ago

READMEChangelogDependencies (1)Versions (6)Used By (0)

Introduction
------------

[](#introduction)

Cashier provides a subscription billing services. It handles almost all of the boilerplate subscription billing code you are dreading writing. In addition to basic subscription management, Cashier can handle plans.

Documentation
-------------

[](#documentation)

- [`Installation`](#Installation)
- [`Configuration`](#Configuration)
    - [`Plan`](#Plan)
- [`Subscription`](#Subscription)
- [`Billing`](#Billing)

### `Installation`

[](#installation)

You can pull in the package via composer:

```
composer require jeanfprado/cashier
```

The package will automatically register itself.

### `Configuration`

[](#configuration)

#### Laravel without auto-discovery:

[](#laravel-without-auto-discovery)

If you don't use auto-discovery, add the CashierServiceProvider to the providers array in config/app.php

```
Jeanfprado\Cashier\CashierServiceProvider::class,
```

If you want to use the facade to log messages, add this to your facades in app.php:

```
'Cashier' => Jeanfprado\Cashier\Support\Facade\Cashier::class,
```

#### Copy the package config to your local config with the publish command:

[](#copy-the-package-config-to-your-local-config-with-the-publish-command)

```
php artisan vendor:publish --provider="Jeanfprado\Cashier\CashierServiceProvider"
```

### `Plan`

[](#plan)

Creating all plans from `config/cashier.php` via artisan

```
php artisan cashier:seed-plans
```

### `Subscription`

[](#subscription)

Before you create a subscription you need prepare what class will be `subscribable`

In `config/cashier.php` change key `model` to model that will be a `subscribable`.

Now in this model you need implements a contract. see example:

```
