rocket
Meet
Merchant API
- the official successor to Content API for Shopping.
update
Get the latest
on new Merchant API features, bug fixes, and updates.
add_alert
Note: Content API for Shopping will be sunset on August 18, 2026.
REST Resource: accounts.credentials
Stay organized with collections
Save and categorize content based on your preferences.
Resource: AccountCredentials
Credentials allowing Google to call a partner's API on behalf of a merchant.
Fields |
purpose |
enum (AccountCredentialsPurpose )
Indicates to Google how Google should use these OAuth tokens.
|
accessToken |
string
An OAuth access token.
|
expiresIn |
string (int64 format)
The amount of time, in seconds, after which the access token is no longer valid.
|
AccountCredentialsPurpose
The purpose of a set of credentials.
Enums |
ACCOUNT_CREDENTIALS_PURPOSE_UNSPECIFIED |
Unknown purpose. |
SHOPIFY_ORDER_MANAGEMENT |
The credentials allow Google to manage Shopify orders on behalf of the merchant (deprecated). |
SHOPIFY_INTEGRATION |
The credentials allow Google to manage Shopify integration on behalf of the merchant. |
Methods |
|
Uploads credentials for the Merchant Center account. |
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-25 UTC.
[null,null,["Last updated 2025-02-25 UTC."],[[["\u003cp\u003eAccountCredentials enable Google to utilize a partner's API on behalf of a merchant, using OAuth tokens for access.\u003c/p\u003e\n"],["\u003cp\u003eThese credentials specify a purpose, such as managing Shopify integration, dictating how Google can leverage them.\u003c/p\u003e\n"],["\u003cp\u003eAccess tokens associated with AccountCredentials have a defined expiration period, ensuring security and requiring renewal.\u003c/p\u003e\n"],["\u003cp\u003eGoogle provides methods, like "create," to manage and upload these credentials for Merchant Center accounts.\u003c/p\u003e\n"]]],["AccountCredentials allow Google to access a partner's API for a merchant. This data includes the `purpose` (indicating how Google uses the tokens, e.g., Shopify integration), an `accessToken`, and `expiresIn` (token validity duration). The `create` method uploads these credentials to the Merchant Center account. The `purpose` can have enum values, such as `SHOPIFY_INTEGRATION`, allowing Google to manage Shopify integration for the merchant.\n"],null,["# REST Resource: accounts.credentials\n\n- [Resource: AccountCredentials](#AccountCredentials)\n - [JSON representation](#AccountCredentials.SCHEMA_REPRESENTATION)\n- [AccountCredentialsPurpose](#AccountCredentialsPurpose)\n- [Methods](#METHODS_SUMMARY)\n\nResource: AccountCredentials\n----------------------------\n\nCredentials allowing Google to call a partner's API on behalf of a merchant.\n\n| JSON representation |\n|----------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"purpose\": enum (/shopping-content/reference/rest/v2.1/accounts.credentials#AccountCredentialsPurpose), \"accessToken\": string, \"expiresIn\": string } ``` |\n\n| Fields ||\n|---------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `purpose` | `enum (`[AccountCredentialsPurpose](/shopping-content/reference/rest/v2.1/accounts.credentials#AccountCredentialsPurpose)`)` Indicates to Google how Google should use these OAuth tokens. |\n| `accessToken` | `string` An OAuth access token. |\n| `expiresIn` | `string (`[int64](https://developers.google.com/discovery/v1/type-format)` format)` The amount of time, in seconds, after which the access token is no longer valid. |\n\nAccountCredentialsPurpose\n-------------------------\n\nThe purpose of a set of credentials.\n\n| Enums ||\n|-------------------------------------------|--------------------------------------------------------------------------------------------------------------------------|\n| `ACCOUNT_CREDENTIALS_PURPOSE_UNSPECIFIED` | Unknown purpose. |\n| `SHOPIFY_ORDER_MANAGEMENT` | The credentials allow Google to manage Shopify orders on behalf of the merchant (deprecated). | This item is deprecated! |\n| `SHOPIFY_INTEGRATION` | The credentials allow Google to manage Shopify integration on behalf of the merchant. |\n\n| Methods ------- ||\n|---------------------------------------------------------------------------------|------------------------------------------------------|\n| ### [create](/shopping-content/reference/rest/v2.1/accounts.credentials/create) | Uploads credentials for the Merchant Center account. |"]]