Google Pay

The Airship SDK provides tools to create Wallet passes and deep link them to Google Pay.

Create a pass request
Field field = new Field.Builder()
                       .setName("text")
                       .setValue("text value")
                       .setLabel("text label")
                       .build();

PassRequest passRequest = PassRequest.newBuilder()
                                     .setAuth("User Name", "Airship API key")
                                     .setTemplateId("template ID")
                                     .addField(field)
                                     .setTag("tag")
                                     .build();
Execute the pass request to fetch a pass object
passRequest.execute(new Callback() {
                @Override
                public void onResult(Pass pass) {
                  // Handle the pass
                }

                @Override
                public void onError(int errorCode) {
                    if (errorCode >= 500) {
                        // retry
                    }
                }
            });
Pass requests can be canceled at any time
passRequest.cancel();
Prompt the user to add the pass
pass.requestToSavePass(getApplicationContext());