提供意見
遷移帳戶連結
透過集合功能整理內容
你可以依據偏好儲存及分類內容。
帳戶關係的管理方式已從 Content API for Shopping 的單一 link
方法,演變為 Merchant API 中更精細且明確的系統。新版 API 會使用 AccountRelationship
和 AccountService
等專屬資源,定義一個帳戶提供給另一個帳戶的特定服務。詳情請參閱「帳戶之間的關係 」。
主要差異
關係和服務專屬資源 :在 Merchant API 中,AccountRelationship
資源會定義服務供應商和商家之間的連結,而 AccountService
資源則會指定提供的確切服務 (例如 accountAggregation
)。這會取代 Shopping Content API 中的一般 linkType
和 services
欄位。
明確的動作方法 :Merchant API 使用不同的方法來管理服務,例如 propose
、approve
和 reject
,而不是使用單一的 link
方法搭配 action
參數。
專屬的 Google 商家檔案連結 :連結至 Google 商家檔案 (先前是透過設定 googleMyBusinessLink
欄位處理),現在有專屬方法 gbpAccounts.linkGbpAccount
。
以服務形式建立客戶帳戶 :在進階帳戶下建立客戶帳戶,現在視為使用 accounts.createAndConfigure
方法提議 accountAggregation
服務。如要進一步瞭解帳戶,請參閱「Merchant Accounts API 」頁面。由於使用者可以存取進階帳戶和客戶帳戶,因此不需要握手。
要求
Merchant API 提供特定端點,用於管理不同類型的帳戶連結和服務:
商家 API 要求網址
建議新服務 :POST
https://merchantapi.googleapis.com/accounts/v1/
{parent=accounts/*}/services:propose
核准服務 :POST
https://merchantapi.googleapis.com/accounts/v1/
{name=accounts/*/services/*}:approve
拒絕服務 :POST
https://merchantapi.googleapis.com/accounts/v1/
{name=accounts/*/services/*}:reject
連結至 Google 商家檔案 :POST
https://merchantapi.googleapis.com/accounts/v1/
{parent=accounts/*}/gbpAccounts:linkGbpAccount
建立客戶帳戶 (帳戶匯總連結) :POST
https://merchantapi.googleapis.com/accounts/v1/
accounts:createAndConfigure
要求比較網址
要求說明
Content API for Shopping
Merchant API
連結帳戶 (例如第三方平台)
POST .../v2.1/{merchantId}/accounts/{accountId}/link
POST .../v1/{parent=accounts/*}/services:propose
連結至 Google 商家檔案
PUT .../v2.1/{merchantId}/accounts/{accountId}
(含 googleMyBusinessLink
欄位)
POST .../v1/{parent=accounts/*}/gbpAccounts:linkGbpAccount
建立客戶帳戶
POST .../v2.1/{merchantId}/accounts
POST .../v1/accounts:createAndConfigure
方法
Content API for Shopping 方法
Merchant API 方法
適用情形和注意事項
accounts.link
accountServices.propose
使用這個方法,以其他帳戶啟動新服務。
accounts.link
(含 action: "approve"
)
accountServices.approve
使用這個方法核准待處理的服務提案。
accounts.link
(含 action: "remove"
)
accountServices.reject
使用這個方法拒絕待處理或已建立的服務。
accounts.insert
(適用於客戶帳戶)
accounts.createAndConfigure
使用 accountAggregation
服務,在進階帳戶下建立新的客戶帳戶。
accounts.update
(含 googleMyBusinessLink
)
gbpAccounts.linkGbpAccount
請使用這個專屬方法,將 Merchant Center 帳戶連結至 Google 商家檔案。
accounts.update
(含 adsLinks
)
AccountRelationship
項資源
連結至 Google Ads 的作業是在 Google Ads 使用者介面中管理。產生的連結在 Merchant API 中會以 AccountRelationship
表示,可供查看但無法直接建立。
詳細欄位變更
Content API for Shopping
Merchant API
說明
AccountsLinkRequest.action
propose
、approve
、reject
方法
單一 action
欄位會替換為專屬 API 方法,用於服務生命週期的各項狀態變更。
AccountsLinkRequest.linkType
AccountService.service_type
一般 linkType
字串會替換為 AccountService
資源中的結構化 service_type
oneof 欄位,例如 productsManagement
或 accountAggregation
AccountsLinkRequest.services
AccountService.service_type
現在,字串型服務清單會以 AccountService
資源中選擇的特定 service_type
表示。
AccountsLinkRequest.linkedAccountId
ProposeAccountServiceRequest.provider
提供服務的帳戶 ID 現在已在 propose
要求的 provider
欄位中指定。
Account.googleMyBusinessLink
LinkGbpAccountRequest
含有 Google 商家檔案連結詳細資料的物件,會由 linkGbpAccount
方法的專屬要求訊息取代。
Account.adsLinks
AccountRelationship
Google Ads 連結會以 AccountRelationship
資源表示,其中 provider
為 providers/GOOGLE_ADS
。這類關係通常是在 Google Ads 使用者介面中管理。
提供意見
除非另有註明,否則本頁面中的內容是採用創用 CC 姓名標示 4.0 授權 ,程式碼範例則為阿帕契 2.0 授權 。詳情請參閱《Google Developers 網站政策 》。Java 是 Oracle 和/或其關聯企業的註冊商標。
上次更新時間:2025-08-08 (世界標準時間)。
想進一步說明嗎?
[[["容易理解","easyToUnderstand","thumb-up"],["確實解決了我的問題","solvedMyProblem","thumb-up"],["其他","otherUp","thumb-up"]],[["缺少我需要的資訊","missingTheInformationINeed","thumb-down"],["過於複雜/步驟過多","tooComplicatedTooManySteps","thumb-down"],["過時","outOfDate","thumb-down"],["翻譯問題","translationIssue","thumb-down"],["示例/程式碼問題","samplesCodeIssue","thumb-down"],["其他","otherDown","thumb-down"]],["上次更新時間:2025-08-08 (世界標準時間)。"],[],[]]