Create a plan on the strip through Laravel

I want to create a plan from my strip app. The scenario is that users are paid different prices as recurring payments. Therefore, I want to create a plan for each user.

I am using laravel 5 and using "laravel/cashier": "~5.0"

+7
laravel stripe-payments laravel-5 laravel-cashier
source share
1 answer

laravel / cashier just does not use this feature. You are out of luck, as it is easy to just use the Stripe API, which should be loaded as a dependency in your vendor folder. If not, you can simply download it using the composer.

 composer require stripe/stripe-php 2.* 

You can use it with

 use \Stripe\Plan; Plan::create(array( "amount" => 2000, "interval" => "month", "name" => "Amazing Gold Plan", "currency" => "usd", "id" => "gold") ); 

You can read more here - https://stripe.com/docs/api#create_plan

+9
source share

All Articles