#loopiiis
1 messages · Page 1 of 1 (latest)
Hello! I believe you just need the key itself. Are you following this guide? https://stripe.com/docs/issuing/cards/digital-wallets?platform=react-native
Yes! I tested with the key itself which is just a string but it required an object to be passed in i believe
so in terms of what is actually needed off the object is it just the secret?
Hm, interesting. You may need to pass the entire object then.
{
"id": "ephkey_1G4V6eEEs6YsaMZ2P1diLWdj",
"object": "ephemeral_key",
"associated_objects": [
{
"id": "ic_1GWQp6EESaYspYZ9uSEZOcq9",
"type": "issuing.card"
}
],
"created": 1586556828,
"expires": 1586560428,
"livemode": false,
"secret": "ek_test_YWNjdF8xRmdlTjZFRHelWWxwWVo5LEtLWFk0amJ2N0JOa0htU1JzEZkd2RpYkpJdnM_00z2ftxCGG"
}
Yep, that's the one.
so just "secret": "ek_test_YWNjdF8xRmdlTjZFRHelWWxwWVo5LEtLWFk0amJ2N0JOa0htU1JzEZkd2RpYkpJdnM_00z2ftxCGG" is needed basically on the object?
{
"id": "ephkey_1G4V6eEEs6YsaMZ2P1diLWdj",
"secret": "ek_test_YWNjdF8xRmdlTjZFRHelWWxwWVo5LEtLWFk0amJ2N0JOa0htU1JzEZkd2RpYkpJdnM_00z2ftxCGG"
}
So an object like this would be okay for the component?
just want to make sure all the properties needed from the key by AddToWallet button is covered in our backend mutation
Why not just pass the entire object?
I'm honestly not sure what the SDK expects to be present, and it might change in a future version, so passing the entire object seems like the best course of action.
Hmmm our backend dev said : " I don’t feel good about doing this raw payload straight from Stripe."
but if you think its best then we will do that!
thank you for your helpp
It's what we say to do in the docs here: https://stripe.com/docs/issuing/cards/digital-wallets?platform=react-native#update-your-backend
If that helps. 🙂
And then in the next step you fetch it and parse the JSON object.
yess we saw that and decided to change our api to return the whole object, originally we had an edpoint that just returned the secret for a stripe iframe for card details! So I guess maybe the backend dev was wondering if it would be bad to send the whole raw object
But i think that's what we'll do since it does follow the documentation!