@extends('layouts.app') @section('title', 'Google Pay') @section('content') @php $currentYear = (int) date('Y'); $expYears = range($currentYear, $currentYear + 15); $defaultGpDescriptor = 'COMMON.GOOGLEPAY.INAPP.PAYMENT'; @endphp

Google Pay

Load an order (same as card checkout), then pay with Google Pay. Uses Authorize.Net authCaptureTransaction with a Google Pay wallet token — separate from the card form.

← Card / manual checkout

@if($anetEnabled && ! $anetReady)
Authorize.Net is enabled but not configured. Add API credentials or disable the gateway.
@endif @if($errors->any())
@endif @if($error)
{{ $error }}
@endif @if(! $order)

Find order

Enter Record ID and/or Invoice number. Lookup runs automatically shortly after you stop typing.

You can use Record ID alone, invoice number alone, or both.

@endif @if($order)
@csrf @php $hidRecord = (string) old('record_id', ''); $hidOrder = (string) old('order_id', ''); $hidInvoice = (string) old('invoice_number', ''); if ($hidRecord === '' && ! empty($order['recordID'])) { $hidRecord = (string) $order['recordID']; } if ($hidOrder === '' && ! empty($order['orderID'])) { $hidOrder = (string) $order['orderID']; } if ($hidInvoice === '') { $inv = $order['InvoiceNumber'] ?? $order['invoiceNumber'] ?? null; if ($inv !== null && trim((string) $inv) !== '') { $hidInvoice = trim((string) $inv); } } $hidOrderLineItemId = (string) old('order_line_item_id', ''); if ($hidOrderLineItemId === '') { $items = $order['lineItems'] ?? $order['lineitems'] ?? null; if (is_array($items) && $items !== []) { $first = $items[0]; if (is_array($first)) { $oli = $first['orderLineItemID'] ?? $first['orderLineItemId'] ?? null; if ($oli !== null && $oli !== '') { $hidOrderLineItemId = (string) $oli; } } } } @endphp

Order details

Purchaser's name
@php $gpMaxPaymentUsd = isset($order['balanceAmount']) ? round((float) $order['balanceAmount'], 2) : null; @endphp
USD

Cannot exceed the API outstanding balance; partial payment is allowed.

@if($gpMaxPaymentUsd !== null) @endif

Billing address

Notes

@if($gpReady)

Google Pay

Tap the Google Pay button. Your card is tokenized by Google and charged through Authorize.Net — card data does not pass through this server.

@else

Google Pay unavailable

Enable GOOGLE_PAY_ENABLED=true, set GOOGLE_PAY_MERCHANT_ID (from Google Pay Business Console), and ensure Authorize.Net credentials are configured. Use card checkout meanwhile.

@endif

Note: Submitting the form without using the Google Pay button will fail validation. Use the button above when ready.

@if($gpReady) @endif @endif
@endsection