Home › Forums › Stripe Payments Plugin › Prefill email on payment OR send custom email to Stripe
- This topic has 4 replies, 2 voices, and was last updated 3 weeks, 1 day ago by
Admin.
-
AuthorPosts
-
May 3, 2025 at 7:04 pm #5483
mariuselz
ParticipantHello,
I am having an issue and I was wondering if there is a way to send/prefill the email to payment form or to Stripe when creating a subscription.
My flow:
1. User goes to https://mywebsite.com/asp-payment-box/?product_id=1350
2. Fills in the details and presses Pay, or pays with Apple/Google Pay. Then the data is sent to Stripe for purchasing the subscription.
3. I catch the payment in my API with an action (asp_stripe_payment_completed)
4. In my API, I update my DB based on Stripe payment email (because I am able to see the Stripe object in the asp_stripe_payment_completed callback)My problem:
In my DB, the user is “[email protected]”
In Stripe, especially if user pays by Apple/Google Pay, the email can be different (for example “[email protected]”)
This causes an issue in my DB updating, my code will look for “[email protected]” and it will not update the correct user ([email protected])Looking forward for any ideas. Much appreciated, thank you!
Best,
MariusMay 4, 2025 at 5:00 am #5493Admin
KeymasterHi, the use case you described will require custom code development. We’ve sent you an email with more details, please reply to that email.
May 14, 2025 at 1:06 pm #5539Admin
KeymasterWe’ve created an example addon that demonstrates how to capture a custom piece of information via a query parameter on the payment page and pass it to the Stripe API as metadata. Sharing it here in case it’s helpful:
July 29, 2025 at 4:11 pm #5603mariuselz
ParticipantHi, thank you for this information.
Does it work with the “email” as well? I am asking because I’m aware this field might be sensitive, maybe it cannot be overwritten?
Looking forward to your reply, thank you!
Best,
MariusJuly 31, 2025 at 7:47 am #5604Admin
KeymasterThe earlier example in this thread talks about sending the data to Stripe as as metadata (additional data).
If you want to pre-fill the standard email field’s data when the page is loaded, you can try the following example to see if that can work for your scenario:
-
AuthorPosts
- You must be logged in to reply to this topic.