Open thienlnam opened 9 months ago
Job added to Upwork: https://www.upwork.com/jobs/~01e91e840e65f1cbba
Triggered auto assignment to Contributor-plus team member for initial proposal review - @akinwale (External
)
Triggered auto assignment to @lschurr (NewFeature
), see https://stackoverflowteams.com/c/expensify/questions/14418#:~:text=BugZero%20process%20steps%20for%20feature%20requests for more details.
:warning: It looks like this issue is labelled as a New Feature but not tied to any GitHub Project. Keep in mind that all new features should be tied to GitHub Projects in order to properly track external CAP software time :warning:
Hey @suneox, I copied what was relevant from the issue into this description
Hey @thienlnam - are we just waiting for proposals on this one?
📣 It's been a week! Do we have any satisfactory proposals yet? Do we need to adjust the bounty for this issue? 💸
Upwork job price has been updated to $1000
Updated the bounty since this is a more intensive - let's give it another week and then we can hand it to our expert contributors? cc @lschurr
The problem identified is that users may find it unintuitive to manually input their virtual card details into the Apple Pay or Google Pay wallet apps.
New Feature
The proposed solution is to create a new package that will handle the process of adding a Expensify NewDot Virtual Card to the Google Pay/Apple Pay Wallet by creating a new package that will return the necessary parameters and call native methods for adding the card to the wallet
First we need to call native modules to fetch specific native variables:
Mutual Parameters:
react-native-device-info
library to fetch the current version of the application.For Android:
getGoogleTransactionId()
method.react-native-device-info
library.For iOS:
PKAddPaymentPassRequest
class for adding payment passes to Apple Pay.PKAddPaymentPassRequest
class.PKAddPaymentPassRequest
class.Fetch return values:
For Android:
opaquePaymentCard
, userAddress
, network
, tokenServiceProvider
, displayName
, and lastDigits
. We can integrate the Android Push Provisioning API using the official documentation provided by Google.For iOS:
encryptedPassData
, activationData
, and ephemeralPublicKey
, we'll need to use Apple's PassKit framework. This framework provides APIs for adding passes to Apple Wallet and managing pass data.N/A
Note: While I've outlined the proposed solution based on the current understanding of the problem and available resources, I'm open to exploring alternative approaches suggested by the team.
Could you review the proposal @akinwale?
@brunovjk Can you add some details such like what native methods you are going to use to fetch the items we'll need to pass to CreateDigitalWallet?
Do we already have the entitlements necessary to add cards to apple like mentioned here: https://developer.apple.com/documentation/passkit_apple_pay_and_wallet/pkaddpaymentpassrequest?language=objc ?
@brunovjk Can you add some details such like what native methods you are going to use to fetch the items we'll need to pass to CreateDigitalWallet?
Updated Added detailed steps for fetching parameters and executing tokenization process.
cc: @thienlnam
@brunovjk's proposal looks good to me. However, the relevant API to handle adding cards to to Google Pay is the Android Push Provisioning API, not the Google Pay API which is used for checkout.
@thienlnam Looks like special access is required to be able to view the documentation (for the Android API), while the iOS view controller requires a special entitlement.
Android
iOS
🎀👀🎀 C+ reviewed.
Updated Updated the Android section to reflect the correct API usage. Thanks, @akinwale, for the review and correction.
Are we good to assigne this to @brunovjk? @akinwale @thienlnam?
Yup - let's get started on this - thanks! Let us know if you need any additional permissions. Before we create the library - let's just start with a branch in App so we can ensure it all works before we move it to a new library
❌ There was an error making the offer to @akinwale for the Reviewer role. The BZ member will need to manually hire the contributor.
❌ There was an error making the offer to @brunovjk for the Contributor role. The BZ member will need to manually hire the contributor.
let's get started on this
I'm diving straight into. Setting up the branch and will keep you posted here throughout the week. When I run into permissions and/or need further information, I'll be sure to ask. Thank you.
react-native-wallet
Library and Native Module:react-native-wallet
folder and run npx create-react-native-library
to initialize the library.react-native-device-info
to fetch the app version.walletAccountID
, deviceID
).certificates
, nonce
, nonceSignature
).CreateDigitalWallet
functionality in JavaScript.react-native-wallet
library.This checklist will be updated as we progress and when necessary. Any feedback is welcome.
@thienlnam I've confirmed the need for permissions to access both Android Push Provisioning API
and the PKAddPaymentPassViewController
. These APIs require special permissions typically granted to card issuers. I've looked into the steps required to request access, but it seems we'll need to navigate some bureaucratic processes with Google and Apple.
You must provide a corporate email address for access to the issuer developer's site
You need special permission from Apple to submit apps with this key enabled. For more information, contact apple-pay-inquiries@apple.com
I'm wondering if anyone on the team has experience with obtaining these permissions or knows someone who does.
Next: To proceed with the next steps, particularly on Android, authorization is required to access the documentation.
@AndrewGable Probably knows best from our OldApp - do you remember going through this process / do we need to again with NewDot?
We have the permissions, but you probably will have to work with @joekaufmanexpensify to get it added to the NewApp ID until we can add this to HybridApp.
Sure, happy to help if I can. @AndrewGable mind clarifying a bit more what this means:
to get it added to the NewApp ID until we can add this to HybridApp.
I'm not super sure based on this what I'm supposed to be helping with.
In the past we've had to provide our OldApp ID for Apple/Google to whitelist (I believe this was shared with Marqeta?), we will need to do the same for the NewApp ID
Hey @joekaufmanexpensify, I hope this message finds you well. I'm working on integrating the React Native Wallet but need guidance on permissions.
Accessing the Android Push Provisioning API
and PKAddPaymentPassViewController
requires special permissions. I'm unsure how to proceed with Expensify's existing ones. Could you provide direction on obtaining these permissions?
Thanks for your help!
Got it. So this issue is adding support for in-app tokenization of virtual cards from NewDot to Apple and Google Pay? If so, that sounds great, and happy to get the app whitelisted with Apple and Google via Marqeta.
If Marqeta just needs to work with Apple and Google to whitelist the new app so we can access the Apple/Google Pay APIs for it, can you share the NewApp ID or point me in the direction of where I can find it so I can pass that along to Marqeta?
com.chat.expensify.chat
com.expensify.chat
What's the latest here @joekaufmanexpensify @AndrewGable @brunovjk?
@joekaufmanexpensify is currently handling the process of whitelisting the New App with Apple and Google. Meanwhile, I'm in the process of identifying the necessary native modules for Android and iOS platforms. While iOS seems straightforward, I'm encountering difficulties accessing the documentation for Android: "To access restricted sections of our Device Tokenization documentation, you must be signed into a Google Account that's been authorized to view that content. Partners must use a Google Account associated with their corporate email address rather than a personal account." Currently, I don't have such an account configured. @lschurr @thienlnam Should we obtain it from Expensify, or should I procure it independently? Thank you.
Yep. I just asked Marqeta to whitelist the new app IDs here!
In process of whitelisting the New App with Apple and Google. In process of identifying the necessary native modules for Android and iOS platforms.
Currently, I don't have such an account configured. @lschurr @thienlnam Should we obtain it from Expensify, or should I procure it independently? Thank you.
Ah good question, I can sign up for access with my account and give you third party access - however it seems like you'll need to sign an NDA with Google to do so. Can you provide me the email you intend to use?
Can you provide me the email you intend to use?
brunovjk@gmail.com
you'll need to sign an NDA with Google
Great, I'll research further. Do you know if there is a cost for this? Thank you very much @thienlnam.
Nope there shouldn't be a cost associated with having to sign their NDA, but let us know if there is
Start implementing 'PKAddPaymentPassViewController'. @thienlnam We use Swift and Java, right?
Yep. I just asked Marqeta to whitelist the new app IDs here!
Did we have any updates? I don't have access to the link above to check.
I can sign up for access with my account and give you third party access
@thienlnam Sorry to bother, but did you have the chance to invite me? Thank you.
They got back to me and provided access - I had you listed as a third party developer. Did you get sent an NDA for you to sign?
Great! I just registered, google will send the NDA within one business day, they said. Thank you very much @thienlnam
In the process of signing the NDA Google to begin implementing Android Push Provisioning API.
Hey @thienlnam - Can you help me associate this feature with a wave or VIP project? Is this part of wave-collect or vip-split? Or something else?
They got back to me and provided access - I had you listed as a third party developer. Did you get sent an NDA for you to sign?
Hi @thienlnam, Could you please share the corporate email address you used to grant me access? I need it to proceed with signing the NDA requested by Google Support. Thank you.
Hi @thienlnam, Could you please share the corporate email address you used to grant me access? I need it to proceed with signing the NDA requested by Google Support. Thank you.
jack@expensify.com
Hey @thienlnam - Can you help me associate this feature with a wave or VIP project? Is this part of wave-collect or vip-split? Or something else?
This would be part of wave-collect - cc @joekaufmanexpensify to confirm here, here was the original issue
Android: Waiting for response from Google support. Apple: Implementing 'PKAddPaymentPassViewController'
Android: Waiting for response from Google support. Apple: Implementing 'PKAddPaymentPassViewController'
Same as above. If I don't hear from Google Support by the beginning of next week, I will create a Google Workspace in my name to continue, we at least need to access the documentation now.
Update: Same as above
To support tokenization in NewDot which is adding a virtual card to Apple / Google Pay, we will need access to some native methods.
Problem: Apple Pay and Google Pay are table stakes in the card market today. We support both of them for physical and virtual cards. Going forward, members will be able to access their virtual card details in NewDot. However, it isn't intuitive to know that you can copy your virtual card details, and manually key them into the Apple/Google wallet apps to tokenize your virtual card.
We're going to create a new package that will return the necessary parameters and call native methods for adding a card to the wallet
The endpoint we want to call is CreateDigitalWallet. We will need to call native modules to fetch specific native variables to call CreateDigitalWallet
Then once we have the return values, we will call the native modules to add these to apple / google wallets
CreateDigitalWallet Summary
The parameters required for the new CreateDigitalWallet API/auth command are:
appVersion
walletAccountID
2.deviceID
certificates
2.nonce
3.nonceSignature
The return values for the new CreateDigitalWallet API/auth command are:
cardToken
opaquePaymentCard
2.userAddress
3.network
4.tokenServiceProvider
5.displayName
6.lastDigits
encryptedPassData
2.activationData
3.ephemeralPublicKey
Upwork Automation - Do Not Edit