This guide shows how to integrate an application using Google Pay™ payments with Radial payments to process the transaction.

For additional information, see the following pages:

Integration with Google Pay

The first phase of the integration process involves creating the App that will use Google Pay. You must work directly with Google to add the Google Pay button to the application and retrieve the user's payment information.

This phase includes actions such as the following:

  • registering the application with Google
  • creating a signed APK
  • deploying the APK

For detailed steps, see the Google Developers website at https://developers.google.com/pay/api/android/guides/setup.

As you add Google Pay to your application, refer to these resources from Google:

Token Specification

There are two values that must be passed to Google Pay as part of the gateway tokenization specification. These configurations identify Radial as your payments processor and are necessary to enable proper tokenization and decryption of the Google Pay payload. This information is used when you fill out the payment tokenization method information as described in the Google Pay tutorial.

Token Specification Entry

value

gateway Obtain the gateway value from Radial
gatewayMerchantId Obtain the proper merchantId from Radial

The use of the token specification data can be seen here: https://developers.google.com/pay/api/android/guides/tutorial#tokenization

Supported Networks

Another configuration that can be made in the application integration with Google Pay is the supported networks for the transactions (see the Google Pay documentation for this implementation). Only the networks included in this configuration will appear in the the Google Pay popup, and it is important to make sure that this configuration only includes the networks that are supported by your integration with Radial.

The use of the supported networks data can be seen here: https://developers.google.com/pay/api/android/guides/tutorial#supported-card-networks

The current accepted networks for Radial are Amex, Discover, MasterCard, and Visa. These networks are supported for transactions settled in United States and Canada (USD, CAD).

For InApp there is also a card authorization method. This method should be set as both PAN_ONLY and CRYPTOGRAM_3D, because Radial supports the Android Device Tokens generated by the CRYTOGRAM_3D method.

Google Pay Json Example

{
  "protocolVersion":"ECv2",
  "signature":"MEUCIG39tbaQPwJe28U+UMsJmxUBUWSkwlOv9Ibohacer+CoAiEA8Wuq3lLUCwLQ06D2kErxaMg3b/oLDFbd2gcFze1zDqU\u003d",
  "intermediateSigningKey":{
    "signedKey": "{\"keyExpiration\":\"1542394027316\",\"keyValue\":\"MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAE/1+3HBVSbdv+j7NaArdgMyoSAM43yRydzqdg1TxodSzA96Dj4Mc1EiKroxxunavVIvdxGnJeFViTzFvzFRxyCw\\u003d\\u003d\"}",
    "signatures": ["MEYCIQDcXCoB4fYJF3EolxrE2zB+7THZCfKA7cWxSztKceXTCgIhAN/d5eBgx/1A6qKBdH0IS7/aQ7dO4MuEt26OrLCUxZnl"]
  },
  "signedMessage":"{\"tag\":\"TjkIKzIOvCrFvjf7/aeeL8/FZJ3tigaNnerag68hIaw\\u003d\",\"ephemeralPublicKey\":\"BLJoTmxP2z7M2N6JmaN786aJcT/L/OJfuJKQdIXcceuBBZ00sf5nm2+snxAJxeJ4HYFTdNH4MOJrH58GNDJ9lJw\\u003d\",\"encryptedMessage\":\"mleAf23XkKjj\"}"
} 

The main goal of the Google Pay integration above is to obtain the tokenization data block in JSON format. That block that will be parsed and used to create a Radial CreditCardAuthRequest (Digital Wallet Authorization Request) using the WalletPaymentInformation data block. The example below shows a JSON block returned from Google Pay and how those values map to the CreditCardAuthRequest values. More information about mapping json response with Radial CreditCardAuthRequest can be found here: Google Pay Processing

Test and Production

Google has two environments for Google Pay transactions: Test and Production. When you begin your integration with Google Pay the application will be in Test by default, which means that the integration with Google will always return back identical test data no matter what card is used to make the payment. These identical payloads can be used to test your integration with Radial. Radial's test systems accept these test payload values, since they are syntactically valid. After your application has been set to Production environment, the payloads returned will match the card information sent to Google Pay. These production payloads can be used to fully test the Radial integration with non-test values.