Summary
The confirmCardPayment() method in localstripe's JavaScript client fails with a 400 Bad Request error when processing payments that require 3DS authentication. This affects the standard Stripe payment flow and prevents successful payment completion.
Environment
- localstripe version: latest (docker container)
- Browser: Chrome 140.0.0.0 on Linux
- Test card:
4242424242424242 (standard Stripe test card)
Steps to Reproduce
- Create a PaymentIntent via the API
- Use
Stripe().confirmCardPayment() with any card number (even non-3DS cards trigger authentication unexpectedly)
- Complete the 3DS authentication popup that appears
- Observe 400 Bad Request error
Expected Behavior
- Non-3DS cards like
4242424242424242 should complete without authentication
- 3DS cards should complete successfully after authentication
- Webhooks should fire upon successful payment
Actual Behavior
- All cards trigger 3DS authentication (unexpected for
4242424242424242)
- Authentication fails with 400 Bad Request
- Payment never completes
- No webhooks are fired
Logs
localstripe container logs:
::ffff:172.24.0.8 [19/Oct/2025:06:24:53 +0000] "POST /v1/payment_intents HTTP/1.1" 200 860 "-" "Stripe/V1 .NetBindings/47.0.0"
::ffff:172.24.0.8 [19/Oct/2025:06:24:53 +0000] "GET /v1/payment_intents/pi_VW7ht0vF2JtFyD HTTP/1.1" 200 860 "-" "Stripe/V1 .NetBindings/47.0.0"
::ffff:172.24.0.1 [19/Oct/2025:06:24:55 +0000] "POST /v1/payment_intents/pi_VW7ht0vF2JtFyD/_authenticate?success=true HTTP/1.1" 400 418 "http://localhost:8888/" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/140.0.0.0 Safari/537.36"
Client-side logs:
Creating payment intent for amount: 10
Payment intent created: pi_VW7ht0vF2JtFyD
localstripe: Stripe().confirmCardPayment()
POST http://localhost:8420/v1/payment_intents/pi_VW7ht0vF2JtFyD/_authenticate?success=true 400 (Bad Request)
Payment confirmation error: {message: 'Bad request', type: 'invalid_request_error'}
Summary
The
confirmCardPayment()method in localstripe's JavaScript client fails with a 400 Bad Request error when processing payments that require 3DS authentication. This affects the standard Stripe payment flow and prevents successful payment completion.Environment
4242424242424242(standard Stripe test card)Steps to Reproduce
Stripe().confirmCardPayment()with any card number (even non-3DS cards trigger authentication unexpectedly)Expected Behavior
4242424242424242should complete without authenticationActual Behavior
4242424242424242)Logs
localstripe container logs:
Client-side logs: