AI-generated Key Takeaways
-
Linking your Google Ads account to your Google Merchant Center account is required before creating a Shopping campaign.
-
The standard process for linking accounts involves sending a link request from Merchant Center and approving it in Google Ads.
-
Link requests can be sent through the Merchant Center web interface or the Content API for Shopping.
-
Link requests can be managed (approved or rejected) in the Google Ads web interface or via the Google Ads API.
-
Direct linking without an invitation is possible using the Google Ads API if the user is an administrator on both accounts.
Before you can create a Shopping campaign, you need to first link your Google Ads account to your Google Merchant Center account as follows:
- Send a link request from your Merchant Center account to your Google Ads account.
- Approve the link request in your Google Ads account.
Sending link requests from your Merchant Center account
There are two ways of sending a link request:
- Use the Merchant Center web interface to send a link request.
- Use the Content API for Shopping to
update the
adsLinksof yourAccount.
Managing link requests in your Google Ads account
You can change the status of Merchant Center links in your Google Ads account by using the Google Ads web interface to approve or reject an invitation. You can also update invitations or remove existing links using the Google Ads API as explained below.
List all Merchant Center invitations
You can run a Google Ads API report using the following GAQL query to retrieve a list of all pending invitations to link a Google Ads customer ID to a Merchant Center account.
SELECT
product_link_invitation.merchant_center.merchant_center_id,
product_link_invitation.type
FROM product_link_invitation
WHERE product_link_invitation.status = 'PENDING_APPROVAL'
AND product_link_invitation.type = 'MERCHANT_CENTER'
To retrieve all invitations, remove the filtering condition for the
product_link_invitation.status field in the query above.
Accept an invitation
You can approve the link by setting the product_link_invitation status to
ACCEPTED.
Construct an
UpdateProductLinkInvitationRequestobject and set thecustomer_idfield as the Google Ads customer ID.Set the
resource_namefield as the resource name of theproduct_link_invitation.Set the
product_link_invitation_statustoACCEPTED.Issue an
UpdateProductLinkInvitationAPI call.
If the invitation flow is attempted by a user who is already an
administrator on both accounts, then a
NO_INVITATION_REQUIRED
error is thrown. You can check for this error and fall back to the direct
link flow in such cases.
Reject an invitation
Rejecting an invitation is similar to accepting an
invitation except that the
product_link_invitation_status
field is set to REJECTED. If an invitation is rejected, it remains in the
REJECTED state and cannot be accepted. You must then create a new
invitation if required.
Direct linking without invitation
If the user attempting to link the Google Ads account to the Merchant Center account is an administrator on both accounts, then you can bypass the invitation step and link both accounts directly using the Google Ads API.
Construct a
CreateProductLinkRequestobject and set thecustomer_idfield as the Google Ads customer ID.Create a new
ProductLinkobject and set itsmerchant_center_idfield to the ID of the Merchant Center account.Set the
ProductLinkto theproduct_linkfield of the request object.Issue a
CreateProductLinkAPI call.
If direct linking is attempted by a user who doesn't have sufficient
permissions, then a
CREATION_NOT_PERMITTED
error is thrown. You can check for this error and fall back to the
invitation flow in such cases.
List all Merchant Center links
You can run a Google Ads API report using the following GAQL query to retrieve a list of links for a Google Ads customer ID.
SELECT
product_link.merchant_center.merchant_center_id,
product_link.product_link_id
FROM product_link
WHERE product_link.type = 'MERCHANT_CENTER'
Unlink a link
Take the following steps to unlink a link:
Construct a
RemoveProductLinkRequestobject and set thecustomer_idfield as the Google Ads customer ID.Set the
resource_nameas the resource name of theproduct_link.Issue a
RemoveProductLinkAPI call.
Business Manager
Business Manager is a unified representation of a business on Google. When you manage both your Google Ads account and your Merchant Center accounts using a Business Manager account, Business Manager automatically creates links between your Google Ads account and the Merchant Center account. You can retrieve these links using the Google Ads API, but these links cannot be mutated with the Google Ads API.