#Svenson
1 messages · Page 1 of 1 (latest)
I can try! What issues are you running in to?
hey, thank you!
I am trying to implement it as a plugin for capacitor app
I am getting this
this is my implementation
I am new to Java so sorry if I am making some stupid mistake
I do not program in Java usually
You're using Capacitor? Not something we officially support
yeah, but does this Java code looks okay or I am missing something?
I dont see a http req for Ephemeral keys, unlike I see it in swift documentation for adding to Apple Wallet
You'd do it on your backend: https://stripe.com/docs/issuing/cards/digital-wallets?platform=Android#update-your-backend
Your code looks ok I guess. Are you able to provide more context from the exception? There's not much detail there, nothing specific to Stripe anyway
I have that on the backend, but when do I call that req from clinet?
before calling this function for provision or?
It'd be after this step. Can you log out the REQUEST_CIODE value returned from PushProvisioningActivityStarter? https://stripe.com/docs/issuing/cards/digital-wallets?platform=Android#update-your-backend:~:text=If the provisioning encountered an error%2C a PushProvisioningActivityStarter.Error will be returned with a code and a message.The message is a developer-friendly text explaining the error. The code can have the following values%3A
what are the logs in logcat when it crashes?
"java.lang.reflect.InvocationTargetException
at java.lang.reflect.Method.invoke(Native Method)"
" Caused by: java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.String com.x.plugins.Wallet.Wallet.startP()' on a null object reference"
hmm, I mean there are multiple things that could be null there. You pass this but that Wallet class does not have a constructor. You pass an empty string instead of an instance of a class that implements the EphemeralKeyProvider interface
yeah, I notice that about keyProvider, dont know when to call that req for ephKeys. I guess before calling provision right?
what would I place as constructor
you don't call it directly yourself, you have a class with a method that makes the request, and you pass an instance of that class to the SDK, the SDK will call it when it needs to.