Migrate local feeds partnership

You can use the Merchant API to share your inventories, stores, and sales data with Google for better visibility and management.

New features

In addition to the Content API features, Merchant API offers the following new features:

  • A method to retrieve the state of merchant-level properties related to the local feeds partnership integration
  • A method to send a notification to a retailer

For details on these methods, see Local feeds partnership API.

Requests

Use the following request URL format for the local feeds partnership API:

POST https://merchantapi.googleapis.com/lfp/v1beta/{parent}/lfpInventories:insert

For more information, see Method: accounts.lfpInventories.insert.

Here's a sample comparison of the Content API for Shopping to the local feeds partnership API for the request to insert an inventory:

Content API Merchant API
URL POST https://shoppingcontent.googleapis.com/content/v2.1/{merchantId}/pos/{targetMerchantId}/inventory POST https://merchantapi.googleapis.com/lfp/v1beta/{parent}/lfpInventories:insert
Identifiers {merchantId}/pos/{targetMerchantId} {parent}

Here's a sample comparison of the Content API for Shopping to the local feeds partnership API for the request to insert a sale:

Content API Merchant API
URL POST https://shoppingcontent.googleapis.com/content/v2.1/{merchantId}/pos/{targetMerchantId}/sale POST https://merchantapi.googleapis.com/lfp/v1beta/{parent}/lfpSales:insert
Identifiers {merchantId}/pos/{targetMerchantId} {parent}

Here's a sample comparison of the Content API for Shopping to the local feeds partnership API for the request to insert a store:

Content API Merchant API
URL POST https://shoppingcontent.googleapis.com/content/v2.1/{merchantId}/pos/{targetMerchantId}/store POST https://merchantapi.googleapis.com/lfp/v1beta/{parent}/lfpStores:insert
Identifiers {merchantId}/pos/{targetMerchantId} {parent}

Methods

Here's what changed for the store API methods in the local feeds partnership API:

Method URL in Content API for Shopping URL in Merchant API Identifiers in Content API for Shopping Identifiers in Merchant API Description
insert POST https://shoppingcontent.googleapis.com/content/v2.1/{merchantId}/pos/{targetMerchantId}/store POST https://merchantapi.googleapis.com/lfp/v1beta/{parent=accounts/*}/lfpStores:insert {merchantId}/pos/{targetMerchantId} {parent} parent is in the format of accounts/{lfpPartnerAccountId}
delete DELETE https://shoppingcontent.googleapis.com/content/v2.1/{merchantId}/pos/{targetMerchantId}/store/{storeCode} DELETE https://merchantapi.googleapis.com/lfp/v1beta/{name=accounts/*/lfpStores/*} {merchantId}/pos/{targetMerchantId}/store/{storeCode} {name} name is in the format of accounts/{lfpPartnerAccountId}/lfpStores/{targetMerchantId}~{storeCode}
get GET https://shoppingcontent.googleapis.com/content/v2.1/{merchantId}/pos/{targetMerchantId}/store/{storeCode} GET https://merchantapi.googleapis.com/lfp/v1beta/{name=accounts/*/lfpStores/*} {merchantId}/pos/{targetMerchantId}/store/{storeCode} {name} name is in the format of accounts/{lfpPartnerAccountId}/lfpStores/{targetMerchantId}~{storeCode}
list GET https://shoppingcontent.googleapis.com/content/v2.1/{merchantId}/pos/{targetMerchantId}/store GET https://merchantapi.googleapis.com/lfp/v1beta/{parent=accounts/*}/lfpStores /{merchantId}/pos/{targetMerchantId} {parent} {parent} is in the format of accounts/{lfpPartnerAccountId}

Here's what changed for the inventory API methods in the local feeds partnership API:

Method URL in Content API for Shopping URL in Merchant API Identifiers in Content API for Shopping Identifiers in Merchant API Description
insert POST https://shoppingcontent.googleapis.com/content/v2.1/{merchantId}/pos/{targetMerchantId}/store POST https://merchantapi.googleapis.com/lfp/v1beta/{parent}/lfpInventories:insert {merchantId}/pos/{targetMerchantId} {parent} parent is in the format of accounts/{lfpPartnerAccountId}

Here's what changed for the sales API methods in the local feeds partnership API:

Method URL in Content API for Shopping URL in Merchant API Identifiers in Content API for Shopping Identifiers in Merchant API Description
insert POST https://shoppingcontent.googleapis.com/content/v2.1/{merchantId}/pos/{targetMerchantId}/store POST https://merchantapi.googleapis.com/lfp/v1beta/{parent}/lfpSales:insert {merchantId}/pos/{targetMerchantId} {parent} {parent} is in the format of accounts/{lfpPartnerAccountId}

Resources

Here's what has changed for the store resource in the local feeds partnership API. Fields not included here are unchanged.

Content API for Shopping Merchant API Description
Not supported name: string Added new field to differentiate different stores
Not supported targetAccount: integer The merchant account to insert inventories for
targetCountry: string regionCode: string targetCountry has been renamed to regionCode
websiteUrl: string websiteUri: string websiteUrl has been renamed to websiteUri
kind: string Not supported kind isn't supported in the local feeds partnership API

Here's what has changed for inserting an inventory. Fields not included here are unchanged.

Content API for Shopping Merchant API Description
Not supported name: string Added new field to differentiate different inventories
Not supported targetAccount: integer The merchant account to insert inventories for.
targetCountry: string regionCode: string targetCountry has been renamed to regionCode. The CLDR territory code for the country where the product is sold.
itemId: string offerId: string itemId has been renamed to offerId
quantity: string quantity: string quantity has been updated to be optional
Not supported availability: string availability is required

price: {

object (Price)

}

price: {

object (Price)

}

Price definition has changed. For more information, see Price.
timestamp: string collectionTime: string timestamp has been renamed to collectionTime
kind: string Not supported kind isn't supported in the local feeds partnership API.

Here's what has changed for inserting a sale. Fields not included here are unchanged.

Content API for Shopping Merchant API Description
Not supported name: string Added new field to differentiate different inventories
Not supported targetAccount:integer The merchant account to insert sales for
targetCountry: string regionCode: string The CLDR territory code for the country where the product is sold.
itemId: string offerId: string itemId has been renamed to offerId

price: {

object (Price)

}

price: {

object (Price)

}

Price definition has changed. For more information, see Price.
timestamp: string saleTime: string timestamp has been renamed to saleTime
kind: string Not supported kind isn't supported in the local feeds partnership API.