Transactions API will be deprecated on May 3, 2023, ahead of the Conversational Actions sunset on June 13, 2023. For more information, see Conversational Actions sunset.
{// Union field payment_option can be only one of the following:"googleProvidedOptions": {object(GoogleProvidedPaymentOptions)},"actionProvidedOptions": {object(ActionProvidedPaymentOptions)}// End of list of possible types for union field payment_option.}
Fields
Union field payment_option. Options for payment. payment_option can be only one of the following:
Required field for requesting Google provided payment instrument. These tokenization parameters will be used for generating payment token for use in transaction. The app should get these parameters from their payment gateway.
The app allows cards from any card network listed here being used in transaction. By default, Amex, Visa, MC and Discover are supported.
prepaidCardDisallowed
boolean
If true, disallow prepaid cards from being used in the transaction.
billingAddressRequired
boolean
If true, billing address will be returned.
PaymentMethodTokenizationParameters
Partner MUST specify the tokenization parameters if payment methods user saved with Google will be used in the transaction. Partner should be able to get these parameters from its own Payment Gateway.
If tokenizationType is set to PAYMENT_GATEWAY then the list of parameters should contain payment gateway specific parameters required to tokenize payment method as well as parameter with the name "gateway" with the value set to one of the gateways that we support e.g. "stripe" or "braintree". A sample tokenization configuration used for Stripe in JSON format. {
"gateway" : "stripe",
"stripe:publishableKey" : "pk_1234",
"stripe:version" : "1.5"
} A sample tokenization configuration used for Braintree in JSON format. {
"gateway" : "braintree",
"braintree:merchantId" : "abc"
"braintree:sdkVersion" : "1.4.0"
"braintree:apiVersion" : "v1"
"braintree:clientKey" : "production_a12b34"
"braintree:authorizationFingerprint" : "production_a12b34"
} A sample configuration used for Adyen in JSON format. {
"gateway" : "adyen",
"gatewayMerchantId" : "gateway-merchant-id"
} If tokenizationType is set to DIRECT, integrators must specify a parameter named "publicKey" which will contain an Elliptic Curve public key using the uncompressed point format and base64 encoded. This publicKey will be used by Google to encrypt the payment information. Example of the parameter in JSON format: { "publicKey": "base64encoded..." }
An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.
Name of the instrument displayed on the receipt. Required for action-provided payment info. For PAYMENT_CARD, this could be "VISA-1234". For BANK, this could be "Chase Checking-1234". For LOYALTY_PROGRAM, this could be "Starbuck's points". For ON_FULFILLMENT, this could be something like "pay on delivery".
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2024-09-18 UTC."],[[["This documentation details the deprecated Orders version 2 API for payment options associated with an order, recommending migration to Orders version 3."],["It outlines two main payment options: GoogleProvidedPaymentOptions, requiring specific parameters for using Google-saved payment methods, and ActionProvidedPaymentOptions, for payment methods provided within the Action."],["Both GoogleProvidedPaymentOptions and ActionProvidedPaymentOptions necessitate providing specific parameters and display names for a successful transaction."],["Developers should retrieve tokenization parameters from their payment gateway for GoogleProvidedPaymentOptions and define payment type and display name for ActionProvidedPaymentOptions."],["Card networks, prepaid card restrictions, and billing address requirements can be specified within GoogleProvidedPaymentOptions."]]],[]]