#aditya_10116
1 messages · Page 1 of 1 (latest)
Hello aditya_10116, we'll be with you shortly! 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.
• https://discord.com/channels/841573134531821608/1164170555910529024, 0 days ago, 12 messages
• https://discord.com/channels/841573134531821608/1164159303146549278, 0 days ago, 15 messages
• https://discord.com/channels/841573134531821608/1164117629141794856, 0 days ago, 26 messages
hi! I'm a bit confused, what code is this? What is setBrandChangeCallback and what class is PaymentBsBinding? I'm not familiar with these being part of the Stripe SDKs.
This code is from Android studio written in Java.
I am creating an custom UI to receive user's card details
Sharing screenshot.
While in the code I am trying to listen to the brand changes as soon as user enters card number into the card number edit text with the function setCompletionCallback$payments_core_release
ah hmm, ok.
I haven't used Java for an Android app in years and don't have a project using CardNumberEditText set up right now but I can try see what I find. Were their particular docs you were looking at that told you to write that code or that it's even possible to listen to that event?
No, I am trying it myself.
shouldn't you be using this instead? https://stripe.dev/stripe-android/payments-core/com.stripe.android.view/-card-multiline-widget/index.html
or the docs at https://stripe.com/docs/payments/accept-a-payment?platform=android&ui=custom for a one-line input
Yes, I tried using that. But that is not customizable.
I'm pretty sure CardNumberEditText is an internal class, not something you use directly
what customisation specifically do you need?
As in this image
I am not able to set the background color or borders or text or hint colors.
I think it's possible somehow, but I haven't looked at these components in multiple years now, we really suggest using the PaymentSheet instead and that's where all our ongoing work and knowledge goes. But let me see what I can find.
I tried using Payment sheet. However, the flow I am trying to establish needs to create a payment method out of the card details entered by user within PaymentSheet. But, Payment sheet does not have any way to do that.
to be clear, it does, that is what https://stripe.com/docs/payments/finalize-payments-on-the-server?platform=android is for
what exact flow is it that you need?
as for customising the CardForm component I think it's possible since I was able to do things with it in our React Native wrapper SDK , not sure right now how to do it using Android directly. I think you edit the layout XML and pass style the same as any other Android component but sorry, I haven't looked at this stuff in a while so my brain is still warming up.
Oh yes! It took my whole day on that.. I tried ..idk every way to customize it .. with styles and what not..
It does not respond to any of the code...
Basically, I am facing problem related to creating a subscription on stripe.
not surprising since we still don't have docs for how to do that with our mobile SDKs, unfortantely
YES!.. I almost crawled through every documentations of yours..
my colleague Tarzan explained earlier today though how to do it, you create a Subscription on the backend using default_incomplete and then you can use the latest_invoice.payment_intent on the app with PaymentSheet.
OK? That is new.
not sure what you mean. It's this conversation you had.
basically the way to implement this is https://stripe.com/docs/billing/subscriptions/build-subscriptions?ui=elements but to use the mobile SDK and PaymentSheet on the frontend to confirm the PaymentIntent client_secret, instead of the stripe.js Elements on the web. I can help you with that, since I know it's not clear, but that is the overall idea
Ok. That's great!
Let me go through this docs and can I ping you back once I am clear with that ?
well I will not be here later but you can ask in the channel yes, or open a support ticket at https://support.stripe.com/?contact=true
yes
from your backend, yes.
now to show the payment sheet..
I just use the client secret to present payment sheet..
yep
am I suppose to pass the subscription ID in any way to the payment sheet?
no, it doesn't need it
Oh my god! Thanks a lot!! you are a savior!
IG that will definitely work... maybe I just skipped this part everytime!
Thanks again!
it should work, I just implemented it there myself while were talking
I am thrilled! Thanks!
Perfect!!