Error objects
Stay organized with collections
Save and categorize content based on your preferences.
This reference describes the Google Pay API error object options to use with your website.
Error objects are objects that are returned by a rejected promise from a client JavaScript
method.
PaymentsError
This object contains details about errors returned by client JavaScript methods. Errors might not
be displayed in a user-facing dialog.
Property |
Type |
Description |
statusCode |
string |
Short code that describes the type of error. |
statusMessage |
string |
Developer-facing message that describes the error encountered and possible
steps to correct it. |
Common errors
This object displays errors that you might encounter across all JavaScript methods. Be sure
to check the developer console for additional error messages.
Status Code |
Description |
BUYER_ACCOUNT_ERROR |
The current Google user is unable to provide payment information. |
DEVELOPER_ERROR |
A passed parameter is improperly formatted.
An
error
message may appear in the browser console
for all configured environments. |
MERCHANT_ACCOUNT_ERROR |
The site accessing the Google Pay API does not have the right permission. This could
be due to either an incorrect configuration or an incorrect merchant identifier set
in the request. Check the statusMessage field for more details. If you
continue to have trouble,
please contact
support. |
INTERNAL_ERROR |
General server error. |
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-02-10 UTC.
[[["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 2025-02-10 UTC."],[[["This reference guide details Google Pay API error objects for websites."],["These error objects provide information about why a Google Pay request failed."],["The `PaymentsError` object includes a status code and message to help you debug."],["Common Google Pay API errors include buyer, developer, and merchant account issues."],["Refer to the linked resources for details on request and response objects related to Google Pay."]]],["The provided content outlines Google Pay API error objects and related components for website integration. `PaymentsError` objects, returned from rejected promises, detail errors with `statusCode` and `statusMessage`. Common error codes include `BUYER_ACCOUNT_ERROR`, `DEVELOPER_ERROR`, `MERCHANT_ACCOUNT_ERROR`, and `INTERNAL_ERROR`, indicating issues with user accounts, parameter formatting, merchant permissions, and general server malfunctions, respectively. The document also references request and response objects, each with specific structures, described in separate pages.\n"]]