xCardNum
field to the encoded token above.xDigitalWalletType
to GooglePay
.xAmount
to transactionInfo.totalPrice
- this is the consumer-approved amount from the Google Pay payment sheet.xCommand
- Set to one of the values that start with cc:
like cc:sale
, cc:auth
, etc.xBillFirstName
xBillLastName
xBillStreet
xBillCity
xBillState
xBillZip
data-ifields-id="igp"
as part of <iframe> tagdata-ifields-oninit="gpRequest.initGP"
as part of <iframe> tag where “gpRequest.initGP“ is a function name that initializes a Google Pay Objectdata-ifields-oninit
has the name of this functionupdateAmount
enableGooglePay
call.amountField
specified - in this case, the Google Pay total amount will be automatically updated whenever the amount has changed.amountField
is not specified - in this case, it’s up to you to provide the correct amount for Google Pay. One of the ways to do it is to call window.ckGooglePay.updateAmount
manually.iframeField
specified - this value will be used to communicate, with Google Pay button.
This option is especially helpful for Angular clients using shadow DOM.iframeField
is not specified - its value will be calculated based on data-ifields-id
attribute.
In this case, it must be set to “igp“: data-ifields-id="igp"
.amountField
amount
.
Could be either the name of the field (String) or the
field itself (Object)iframeField
ckGooglePay.enableGooglePay({amountField: 'amount'});