Category : stripe-payments

I am trying to create subscription in stripe through php sdk. subscription created successfully but here is the issue,When i create a subscription from UTC timezone my date is 2021-01-08 13:05:25 but in the dashboard subscription created in 2021-01-07 23:35. Also in the stripe response gave me 2021-01-08 13:05:25.my data is generated according to the ..

Read more

i am facing a issue with custom stripe subscription code. My issue is like when a card having insufficient fund then stripe subscription code is not giving me any error. My code is this. StripeCharge::create ([ "amount" => $amt * 100, "currency" => "usd", "source" => $request->stripeToken, "description" => $description ]); $customer = StripeCustomer::create(array( ’email’ ..

Read more

i want to get metadata from checkout session when calling check charge (success or fail) $session = StripeCheckoutSession::create([ ‘success_url’ => Config::get(‘app.url’) . ‘/payment/success’ . ‘?order_id=’ . $request->order_id, ‘cancel_url’ => Config::get(‘app.url’) . ‘/payment/cancel’ . ‘?order_id=’ . $request->order_id, ‘payment_method_types’ => [Config::get(‘stripe.parameters.methodTypes’)], ‘subscription_data’ => [ ‘metadata’ => [‘order_id’ => $request->order_id] ], ‘line_items’ => [[ ‘price’ => $price->id, ‘quantity’ ..

Read more

my app is builded with laravel 8, laravel Mix 6.0.39 , vue js 2.6 and vuex 3.0.1 I used cashier for payment module so in payment component I have this code to initialise payment method: let apikey = process.env.MIX_STRIPE_KEY this.stripe = await loadStripe(apikey) const elements = this.stripe.elements() … .env file : STRIPE_SECRET=sk_test_….. STRIPE_WEBHOOK_SECRET =we_…. MIX_STRIPE_KEY ..

Read more

I’m using a simple Stripe Prebuilt Checkout (HTML/PHP) within a Livewire component. It works fine on local but not in production. When I view the Network I see I get a Status: CORS Error then a Status: 403 error. See image: Here is my code: Component: <form wire:submit.prevent="checkout"> <x-assets.checkout-button type="submit" id="checkout-button"> Buy Now </x-assets.checkout-button> </form> ..

Read more

As the title says there are some DNS issues and sometimes when I try to curl inside my docker container https://api.stripe.com/v1/setup_intents it returns curl: (6) Could not resolve host: api.stripe.com. This issue does not happen if I try to curl other websites. docker exec -it php-alpine /bin/sh /var/www/html # curl https://api.stripe.com/v1/setup_intents { works. some json ..

Read more

My project is on Laravel 8 I have the following form: <form action="{{ route(‘stripe.pay.create.session’) }}" method="POST" data-secret="{{ $intent->client_secret }}"> @csrf <input type="hidden" name="priceId" value="MY PRICE ID" /> <div id="card-element" class="p-3 mb-3"></div> <button type="submit" id="card-button">Checkout</button> </form> where the value of the hidden input is my product_id from stripe dashboard and the route "stripe.pay.create.session" have the following ..

Read more

I have no problem accessing and filling in the form at the test level: This works: public function user_can_subscribe() { $this->browse(function (Browser $browser) { $browser->visit(new SubscribePage) ->waitFor(‘.__PrivateStripeElement iframe’) ->withinFrame(‘.__PrivateStripeElement iframe’, function($browser) { $browser->pause(3000) ->keys(‘input[placeholder="Card number"]’, 4242424242424242) ->keys(‘input[placeholder="MM / YY"]’, ‘0125’) ->keys(‘input[placeholder="CVC"]’, ‘123’) ->keys(‘input[placeholder="ZIP"]’, ‘12345’);; }) ->press(‘@subscribe-button’); }); } I’d like to move the stripe form ..

Read more

Controller: public function subscriptionCheckout(Request $request) { $user_id = $request->id; $user = User::find($user_id); $stripeCustomer = $user->createOrGetStripeCustomer(); return $user->redirectToBillingPortal(route(‘subscription-success’)); } Route: Route::post(‘subscription-success’, ‘[email protected]’)->name(‘subscription-success’); Error: https://billing.stripe.com/session/test_YWNjdF8xSnRXOE5MQ3BOOGc1RWs4LF9LYnVySDhJRXFkZ0hlcHM4NEpPWFRsRGxXMlAxck450100hMlXhEBQ CORS error Sourc..

Read more

I’m onboarding new users into our platform using Stripe. Firstly I’m creating account in Stripe $this->stripe->accounts->create([ ‘type’ => ‘express’, ‘country’ => ‘US’, ’email’ => $user->email, ‘capabilities’ => [ ‘card_payments’ => [‘requested’ => true], ‘transfers’ => [‘requested’ => true], ], ]); Secondly I’m trying to link this account to our platform return $this->stripe->accountLinks->create( [ ‘account’ => ..

Read more

I have a website built with the Laravel framework that uses Stripe to process subscription payments. When a user subscribes to a plan through my website, this row appears in the "subscriptions" database table: When a subscription is canceled through my website, the ends_at column is populated with a date the current subscription period ends ..

Read more