1

There are several applications that allow to save a new credit card to a Google Pay. Upon pressing the button, the Google Pay opens with a credit card data pre-filled. However, I couldn't find any mentions of Intents or any API that allow to do that. How do I implement a "save credit/debit card to Google Pay" functionality inside an Android app?

Phantômaxx
  • 37,901
  • 21
  • 84
  • 115
Alehar
  • 639
  • 5
  • 16

2 Answers2

1

I don't think what you are after is directly supported.

One question that I have for you is why do you want to save the card? Is it for the purpose of making a payment or for storing it for later use?

If the purpose is to make a payment, then I would suggest integrating with the Google Pay Android APIs which will give the user the option to either select from an existing set of payment methods or add and save a new payment method for immediate use.

If the purpose is to save a card for later use and you also happen to be a card issuer, then you can achieve this with push provisioning. See answer here.

Soc
  • 7,425
  • 4
  • 13
  • 30
0

In order to save a credit card detail, your app needs to comply with PCI compliance i.e. Payment Card Industry Data Security Standard (PCI DSS).

Here is checklist for PCI standards : https://www.akamai.com/us/en/resources/pci-compliance-checklist.jsp

In short, its not easy. Big industries do that and develop their own APIs and it takes thousands of dollars every month to remain compliant. Therefore, You will hardly find any open source API for saving credit card information.

Pankaj Sati
  • 2,441
  • 1
  • 14
  • 21
  • Let's suppose the app is already PCI DSS compliant. It would still need an API provided by Google Pay, no? No matter how big the company is, they would still need some entry point to Google Pay - either documented or not. And - mind you - I don't want to save a credit card details inside the app, I want to save them in Google Pay through the app. – Alehar Feb 07 '19 at 15:43
  • Can you name an app that does this ? – Pankaj Sati Feb 07 '19 at 15:45
  • Apps that do this are e.g. Raiffeisen Pay, Sberbank of Russia – Alehar Feb 07 '19 at 15:51
  • No idea about them. These applications might have done a contract with Google to authorize them to save credit cards. Lets suppose that there is an open souce API that every developer can use to save credit cards information. Handling the security of such an API would be very crucial because already due to a privacy breach due to a bug in Google+, Google is completely shutting it down in April. – Pankaj Sati Feb 07 '19 at 16:02
  • Maybe I haven't made myself clear. I'm not talking about saving credit card info inside my own app. I'm talking about a button that would open a Google Pay window with card number pre-filled. The custom app wouldn't have to store the data, that's not the requirement. Requirement is just to open a Google Pay "add new card" window. – Alehar Feb 07 '19 at 16:11