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/{MERCHANT_ID}/pos/{TARGETMERCHANT_ID}/inventory POST https://merchantapi.googleapis.com/lfp/v1beta/{PARENT}/lfpInventories:insert
Identifiers {MERCHANT_ID}/pos/{TARGETMERCHANT_ID} {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/{MERCHANT_ID}/pos/{TARGETMERCHANT_ID}/sale POST https://merchantapi.googleapis.com/lfp/v1beta/{PARENT}/lfpSales:insert
Identifiers {MERCHANT_ID}/pos/{TARGETMERCHANT_ID} {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/{MERCHANT_ID}/pos/{TARGETMERCHANT_ID}/store POST https://merchantapi.googleapis.com/lfp/v1beta/{PARENT}/lfpStores:insert
Identifiers {MERCHANT_ID}/pos/{TARGETMERCHANT_ID} {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/{MERCHANT_ID}/pos/{TARGETMERCHANT_ID}/store POST https://merchantapi.googleapis.com/lfp/v1beta/{parent=accounts/*}/lfpStores:insert {MERCHANT_ID}/pos/{TARGETMERCHANT_ID} {PARENT} parent is in the format of accounts/{IFP_PARTNER_ACCOUNT_ID}
delete DELETE https://shoppingcontent.googleapis.com/content/v2.1/{MERCHANT_ID}/pos/{TARGETMERCHANT_ID}/store/{STORE_CODE} DELETE https://merchantapi.googleapis.com/lfp/v1beta/{name=accounts/*/lfpStores/*} {MERCHANT_ID}/pos/{TARGETMERCHANT_ID}/store/{STORE_CODE} {NAME} name is in the format of accounts/{IFP_PARTNER_ACCOUNT_ID}/lfpStores/{TARGETMERCHANT_ID}~{STORE_CODE}
get GET https://shoppingcontent.googleapis.com/content/v2.1/{MERCHANT_ID}/pos/{TARGETMERCHANT_ID}/store/{STORE_CODE} GET https://merchantapi.googleapis.com/lfp/v1beta/{name=accounts/*/lfpStores/*} {MERCHANT_ID}/pos/{TARGETMERCHANT_ID}/store/{STORE_CODE} {NAME} name is in the format of accounts/{IFP_PARTNER_ACCOUNT_ID}/lfpStores/{TARGETMERCHANT_ID}~{STORE_CODE}
list GET https://shoppingcontent.googleapis.com/content/v2.1/{MERCHANT_ID}/pos/{TARGETMERCHANT_ID}/store GET https://merchantapi.googleapis.com/lfp/v1beta/{parent=accounts/*}/lfpStores /{MERCHANT_ID}/pos/{TARGETMERCHANT_ID} {PARENT} {PARENT} is in the format of accounts/{IFP_PARTNER_ACCOUNT_ID}

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/{MERCHANT_ID}/pos/{TARGETMERCHANT_ID}/store POST https://merchantapi.googleapis.com/lfp/v1beta/{PARENT}/lfpInventories:insert {MERCHANT_ID}/pos/{TARGETMERCHANT_ID} {PARENT} parent is in the format of accounts/{IFP_PARTNER_ACCOUNT_ID}

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/{MERCHANT_ID}/pos/{TARGETMERCHANT_ID}/store POST https://merchantapi.googleapis.com/lfp/v1beta/{PARENT}/lfpSales:insert {MERCHANT_ID}/pos/{TARGETMERCHANT_ID} {PARENT} {PARENT} is in the format of accounts/{IFP_PARTNER_ACCOUNT_ID}

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.