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

ActiveLibrary[Payment Processing](/categories/payments)

bulletdigitalsolutions/doctrine-cashier
=======================================

Enables you to use cashier on doctrine

v1.0.8(1y ago)01.3kMITPHPPHP ^8.0

Since Jul 5Pushed 1y ago2 watchersCompare

[ Source](https://github.com/BulletDigitalSolutions/doctrine-cashier)[ Packagist](https://packagist.org/packages/bulletdigitalsolutions/doctrine-cashier)[ Docs](https://github.com/bulletdigitalsolutions/doctrine-cashier)[ RSS](/packages/bulletdigitalsolutions-doctrine-cashier/feed)WikiDiscussions master Synced today

READMEChangelog (9)Dependencies (7)Versions (13)Used By (0)

Very short description of the package
=====================================

[](#very-short-description-of-the-package)

This package is in early development and not yet tested for production use.
---------------------------------------------------------------------------

[](#this-package-is-in-early-development-and-not-yet-tested-for-production-use)

[![Latest Version on Packagist](https://camo.githubusercontent.com/067e2203dbbb41f09a2c248e1ddda1bec9bbf42124773aee483eacc3e19e6f49/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f62756c6c65746469676974616c736f6c7574696f6e732f646f637472696e652d636173686965722e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/bulletdigitalsolutions/doctrine-cashier)[![Total Downloads](https://camo.githubusercontent.com/c0d4dc4328a98bc5faa422b10de67a57e61d0704d89ee3060b262d936f0c3682/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f62756c6c65746469676974616c736f6c7574696f6e732f646f637472696e652d636173686965722e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/bulletdigitalsolutions/doctrine-cashier)[![GitHub Actions](https://github.com/bulletdigitalsolutions/doctrine-cashier/actions/workflows/main.yml/badge.svg)](https://github.com/bulletdigitalsolutions/doctrine-cashier/actions/workflows/main.yml/badge.svg)

This is where your description should go. Try and limit it to a paragraph or two, and maybe throw in a mention of what PSRs you support to avoid any confusion with users and contributors.

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

[](#installation)

You can install the package via composer:

```
composer require bulletdigitalsolutions/doctrine-cashier
```

Usage
-----

[](#usage)

Your user entity should extend the BillableEntity class

```
/**
 * @ORM\Table()
 * @ORM\Entity
 * @Gedmo\Loggable(logEntryClass="App\Entities\Audit")
 */
class User extends BillableEntity
```

Your user entity must implement getRepository, which returns a repository that implement BillableEntityContract

```
public function getRepository()
{
    return app(UserContract::class);
}
```

```
class UserRepository extends CoreRepository implements UserContract
{
    use TwoFactorRepository, BillableRepository;
```

You should then extend the Subscription and SubscriptionItem entities

```
