#nikolay_code
1 messages ยท Page 1 of 1 (latest)
๐ Welcome to your new thread!
โฒ๏ธ We'll be here soon! Typically we respond in a few minutes, but sometimes we might take a bit longer if the server is busy or if you have a particularly tricky question.
โฑ๏ธ We close idle threads, which makes them read-only. Once a thread is closed it won't be reopened, but you can always start a new thread if you have another question.
๐ This thread will always be available, even after it's closed. You can find it again using Discord's search, or you can save this link: https://discord.com/channels/841573134531821608/1381704863423004712
๐ Have more to share? Add more details, code, screenshots, videos, etc. below.
Below are links to other discussions we've had with you in the past week in case you want to review that information. If your question is related to one of these previous discussions, please provide a comprehensive summary of the current state and what you need help with now. We help many users simultaneously, so a summary allows us to resolve your issue as soon as possible.
- nikolay_code, 3 hours ago, 24 messages
File 1:
File 2:
- Default Payment method create
- using stripe elements (embedded stripe elements for Card number, CVC and expiry date)
- Subscription created, payment intent also created however isn't be sent back from stripe
From Stripe
payment_intent.canceled
Inspect event detail in Workbench
Event data
{
"id": "pi_3RXmsn1VlpCPYqMR1XPGDNdO",
"object": "payment_intent",
"last_payment_error": null,
"livemode": false,
"next_action": null,
"status": "canceled",
"amount": 100,
"amount_capturable": 0,
"amount_details": {
"tip": {
}
},
"amount_received": 0,
"application": null,
"application_fee_amount": null,
"automatic_payment_methods": null,
"canceled_at": 1749485989,
"cancellation_reason": "void_invoice",
"capture_method": "automatic",
"client_secret": "pi_3RXmsn1VlpCPYqMR1XPGDNdO_secret_AnSIDC0U9kZncFfuKPkSJBsR0",
"confirmation_method": "automatic",
"created": 1749403185,
"currency": "gbp",
"customer": "cus_SSiJPCeSwTyZqd",
"description": "Subscription creation",
"latest_charge": null,
"metadata": {
},
"on_behalf_of": null,
"payment_method": "pm_1RXmsl1VlpCPYqMRWAfktNkQ",
"payment_method_configuration_details": null,
"payment_method_options": {
"card": {
"installments": null,
"mandate_options": null,
"network": null,
"request_three_d_secure": "automatic"
}
},
"payment_method_types": [
"card"
],
"processing": null,
"receipt_email": null,
"review": null,
"setup_future_usage": "off_session",
"shipping": null,
"source": null,
"statement_descriptor": null,
"statement_descriptor_suffix": null,
"transfer_data": null,
"transfer_group": null
}
Hide lines
Main problem: SCA (SAD2) widget isnt opening, used a test card which is meant to force the widget to open, reason from my debug.log: no payment intent
hello, can you see the chat history?
Hello
Yes hang on.. Trying to look at the PaymentIntent you've shared..
did you read my code? I can't find any problems with either the php or JS file, if there is please could you let me know
I'm trying to read through but there's a lot of code.. I can't look at your complete code base.
Have you added logging to your code to see if you're seeing any errors?
SCA (SAD2) widget <--- what is that? Stripe does not have a widget such as that.
here are my logs part 1:
[09-Jun-2025 18:53:52 UTC] ---- payments-api.php START ----
[09-Jun-2025 18:53:52 UTC] Request method: POST
[09-Jun-2025 18:53:52 UTC] Raw POST data:
[09-Jun-2025 18:53:52 UTC] $_POST: Array
(
[cs_booking_nonce] => 5ae374b68c
[_wp_http_referer] => /checkout/
[firstName] => Stripe
[lastName] => Test
[email] => stripe_developer@develop.com
[phone] => 0000000000
[swimmerFirstName] => Stripe
[swimmerLastName] => Developer
[swimmerAge] => 99
[swimmerAbility] => Beginner
[lesson_type] => private
[lesson-category] => adult
[payment-plan] => price_1RJe2j1VlpCPYqMR8UkiOwNI
[cardName] => Stripe Developer
[address] => Stripe Head Office
[city] => Stripe
[postCode] => ln43ds
[payment_method_id] => pm_1RYApP1VlpCPYqMRaeGzmiiS
[payment-plan-name] => Starter
[lessonCategory] => adult
[form_version] => v1.0.0
[submitted_at] => 1749495230918
)
part 2:
[09-Jun-2025 18:53:52 UTC] โ
Security check passed
[09-Jun-2025 18:53:52 UTC] โ
Core inputs sanitized: first=Stripe, last=Test, email=stripe_developer@develop.com, plan=price_1RJe2j1VlpCPYqMR8UkiOwNI
[09-Jun-2025 18:53:52 UTC] โน๏ธ payment_method_id from form: 'pm_1RYApP1VlpCPYqMRaeGzmiiS'
[09-Jun-2025 18:53:52 UTC] โ
Extended inputs sanitized
[09-Jun-2025 18:53:52 UTC] โ
Metadata compiled: Array
(
[first_name] => Stripe
[last_name] => Test
[card_name] => Stripe Developer
[phone] => 0000000000
[email] => stripe_developer@develop.com
[address] => Stripe Head Office
[city] => Stripe
[postcode] => ln43ds
[payment-plan] => price_1RJe2j1VlpCPYqMR8UkiOwNI
[payment-plan-name] => Starter
[swimmer_first_name] => Stripe
[swimmer_last_name] => Developer
[swimmer_age] => 99
[swimmer_ability] => Beginner
[lesson_type] => private
[lesson_category] => adult
[form_version] => v1.0.0
[submitted_at] => 1749495230918
[user_agent] => Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/17.6 Safari/605.1.15
)
[09-Jun-2025 18:53:52 UTC] โ
Stripe initialized
[09-Jun-2025 18:53:52 UTC] โน๏ธ Idempotency key: sub_1dbb0633622afc8107eb65d885b5b832
[09-Jun-2025 18:53:52 UTC] โน๏ธ Creating Stripe customer for stripe_developer@develop.com with payment_method=pm_1RYApP1VlpCPYqMRaeGzmiiS
part 3:
[09-Jun-2025 18:53:52 UTC] โ
Customer created: id=cus_ST73cTqbPle4kt
[09-Jun-2025 18:53:52 UTC] โน๏ธ Customer.payment_method: pm_1RYApP1VlpCPYqMRaeGzmiiS
[09-Jun-2025 18:53:52 UTC] โ
PM pm_1RYApP1VlpCPYqMRaeGzmiiS correctly attached to Customer.invoice_settings.default_payment_method
[09-Jun-2025 18:53:52 UTC] โน๏ธ Creating subscription for customer cus_ST73cTqbPle4kt with PM=pm_1RYApP1VlpCPYqMRaeGzmiiS
[09-Jun-2025 18:53:54 UTC] โ
Subscription created: id=sub_1RYApQ1VlpCPYqMRxXnxzXTM, status=incomplete
[09-Jun-2025 18:53:54 UTC] โน๏ธ Subscription.default_payment_method: pm_1RYApP1VlpCPYqMRaeGzmiiS
[09-Jun-2025 18:53:54 UTC] โ
PM pm_1RYApP1VlpCPYqMRaeGzmiiS correctly set as Subscription.default_payment_method
[09-Jun-2025 18:53:54 UTC] โ No PaymentIntent on expanded invoice
So there's clearly an error about PaymentIntent property missing on the invoice right?
Starting 2025-03-31.basil API version, we don't have payment_intent as a property on the Invoice anymore..
This is part of the recent API version change - https://docs.stripe.com/changelog/basil/2025-03-31/add-support-for-multiple-partial-payments-on-invoices
Of course, so where is it?
thanks for the help so far btw
here is what stripe said just now when i made the test payment:
From Stripe
payment_intent.created
Inspect event detail in Workbench
Event data
{
"id": "pi_3RYApR1VlpCPYqMR0qu8dHY4",
"object": "payment_intent",
"last_payment_error": null,
"livemode": false,
"next_action": null,
"status": "requires_payment_method",
"amount": 100,
"amount_capturable": 0,
"amount_details": {
"tip": {
}
},
"amount_received": 0,
"application": null,
"application_fee_amount": null,
"automatic_payment_methods": null,
"canceled_at": null,
"cancellation_reason": null,
"capture_method": "automatic",
"client_secret": "pi_3RYApR1VlpCPYqMR0qu8dHY4_secret_fuAvXnU8sken1cgAiVXv2JsBA",
"confirmation_method": "automatic",
"created": 1749495233,
"currency": "gbp",
"customer": "cus_ST73cTqbPle4kt",
"description": "Subscription creation",
"latest_charge": null,
"metadata": {
},
"on_behalf_of": null,
"payment_method": null,
"payment_method_configuration_details": null,
"payment_method_options": {
"card": {
"installments": null,
"mandate_options": null,
"network": null,
"request_three_d_secure": "automatic"
}
},
"payment_method_types": [
"card"
],
"processing": null,
"receipt_email": null,
"review": null,
"setup_future_usage": "off_session",
"shipping": null,
"source": null,
"statement_descriptor": null,
"statement_descriptor_suffix": null,
"transfer_data": null,
"transfer_group": null
}
did you check the doc I linked? It describes where the payment information has moved ๐
let me know if you've found it ๐
This is likely the most relevant part to your usecase - https://docs.stripe.com/changelog/basil/2025-03-31/add-support-for-multiple-partial-payments-on-invoices#use-for-payment-element-integrations
ok, i'm attempting to fix this, working with chatgpt. Can youl leave the thread open?
sure