Friday, October 18, 2013

Overview of Google Wallet APIs

Talk by Nasir Khan, developer advocate at Google, Inc.

Google Wallet has been implemented as the primary payment processor for all Google services including Play, Drive and Chrome. It is also used across the Internet through the 'pay with Google' button. In the real world you find payment options at kiosks as well as transaction details in your phone but now you can transmit money through Google Wallet to other users.

Google Wallet works like any ordinary wallet in how it keeps your payments, offers, loyalty and more in one secure app.
In the past couple years transactions and accounts have grown year after year.
The APIs involved are:
1. Instant Buy API on Web and mWeb
2. Instant Buy API on Android for physical goods
3. Digital Goods API on Web
4. In-app Billing on Android for digital goods
5. Wallet objects API for loyalty and offers

The challenge for mobile commerce is that 97 percent of users abandon a mobile purchase in mid-flow. This has been accounted to browsing but other statistics show a significant amount of shoppers abandoning purchases already in the cart. To solve this, Google uses Instant Buy. Instant buy provides a faster checkout, allows users to skip registration and sign-in, features enhanced security, has a lightweight integration and includes no additional fees.

This works by having users access their Google Wallet, grab their information that is stored there and sends it to the merchant or payment processor. The information sent isn't the actual information of the user but a proxy card that keeps the user safe behind a level of security as well as the shipping and billing information needed.

The Instant Buy API includes simple JavaScript API for back end independent integration, a JavaScript library that renders the Google Wallet button assets and a Web application needed to implement the payment. The API also uses JSON Web Tokens that are cryptographically signed and base64url encoded to verify the originator of the message and includes the signature that is used shared secretly and verified by the Web tokens.

The Buy with Google Button can be implemented in as few as four lines of HTML or five lines of JavaScript. This uses the Masked Wallet call that gives the masked payment credentials, shipping address, billing address and phone number to the application. Clicking the button sends the request  and the information is encrypted.

Clicking through the prompts send the full wallet request which will have the full, exact amount including tax and shipping. The response will contain the Proxy card details and billing address that is backed by the security and encryption found earlier.

The Instant Buy Architecture is part of Google Play Services and so every device running Android 2.2 and higher will have it installed. To utilize it a thin client library is compiled in your app. To set this up, establish a connection to Google Play Services.  This will fetch a masked wallet. The user then clicks on the button and it will then prompt whether or not there is a Google Wallet account already active and whether it is set as default payment. If not, it will work through the authorization prompts. If the user is already authorized then it will move immediately to the confirmation page. The user has to confirm to get the actual full wallet. This is the first point in the whole transaction that the full wallet information is sent.

Some of the apps already using Google Wallet that show increased productivity:
TabbedOut: 25% Google Wallet Purchases
Rue lala: 50% are return customers
Fancy: 20% Conversions 14% basket size

Digital Goods API is also known as the in-app payments API. It is optimized for digital content and is used through the apps. This was designed to let developers handle their app while Google handles the payment.

This API is built around three principles. First a streamlined experience that provides and easy way for consumers to navigate the payment process. Second is a simple integration so developers will feel no stress in implementing them in their applications. Last is attractive pricing, which is run completely through Google at the most aggressive pricing in the industry.

The Wallet Objects API is here to solve the fat wallet challenge. The first part of the challenge is the quantity of cards including loyalty cards, points cards and credit cards. The second is the time consuming sign-up involved for each and every card. Third are the lost benefits. It is estimated that 16 billion dollars in points go unused every year. The Google Wallet Objects API is here to have everything in one place.

This brings back to the three things the Objects API brings, all of your cards in one place, little to no enrollment and a deeper engagement in the programs you are enrolled in. This is designed to be easily integrated into existing loyalty systems.

Two million users have used the new app in the past three weeks since the last app launch. This includes a 23% increase in the Alaska Airlines Mileage Plan since the App launch.
For more information, go to

No comments: