Download the PHP package lab404/laravel-stripe-server without Composer

On this page you can find all versions of the php package lab404/laravel-stripe-server. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package laravel-stripe-server

Laravel Stripe Server

Laravel Stripe Server is a library to handle Stripe SCA checkout for your models.

Requirements

Laravel support

Version Release
6.x, 7.x 1.1
6.x 1.0
5.8 0.3

Intended workflow

Example model:

Example listener:

Installation

  1. Require it with Composer:

  2. Configure your Stripe keys in config/services.php.

  3. Publish migrations and views with php artisan vendor:publish --tag=stripe-server.

  4. Migrate 2019_06_19_101000_create_stripe_checkouts_table.php.

  5. Schedule the command in app\Console\Kernel.php:

  6. Add the Lab404\StripeServer\Models\HasStripeCheckout or HasStripeCheckouts (if a model can have multiple checkouts) to your chargeable models.

Going deeper

Stripe documentation

Access the Stripe Manager

With facade:

With DI:

With container:

Available methods

Working with your models

Model with many checkouts

When a model has the Lab404\StripeServer\Models\HasStripeCheckouts you have access to the following methods and scopes:

Model with one checkout

When a model has the Lab404\StripeServer\Models\HasStripeCheckout you have access to the following methods and scopes:

Customize the StripeCheckout model

Configure model in config/stripe-server.php. Your custom model should extend the default one.

Customize the redirector

When you use the redirectSession() method, an instance of Illuminate\View\View is returned. You can do:

Artisan commands

stripe:checkout-session-completed

Get all checkout.session.completed Stripe events and dispatch the event CheckoutSessionCompleted for each with the succeeded status.

stripe:events

Get all Stripe events and dispatch StripeEvent for each one.

stripe:purge

Delete all unpaid StripeCheckout older than the given days. Customize with the --days option, defaults to 7. It's convenient to call it in a scheduler:

Nova

If you're using Laravel Nova you can add the Lab404\StripeServer\Nova\StripeCheckout resource:

This resource is not dynamically registered because it's quite simple and you may want to override it. More Nova features like Refund Action or Cards are coming.

TODOs and ideas

[x] Purge unpaid stripe checkouts
[ ] Refund
[ ] Nova actions

Tests

TODO

Contribute

This package is still in development, feel free to contribute!

Contributors

Licence

MIT


All versions of laravel-stripe-server with dependencies

PHP Build Version
Package Version
Requires php Version ^7.2
laravel/framework Version ^6.0 | ^7.0
stripe/stripe-php Version ^7.40
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package lab404/laravel-stripe-server contains the following files

Loading the files please wait ....