Hi there,
Thank you very much for the code snippet and the explanation above. I've 
been pulling my hair out in the last few days ...

So after the client accepts the Ads invitation, all done and dusted, my 
next step is linking the Merchant account with this client Ads account
I can update the Merchant to include the AdsId and see it go through --> OK

Question: how can I accept the invitation 
<https://developers.google.com/adwords/shopping/full-automation/articles/t16> 
from Merchant by using Ads API (again, not Adwords), 
I already tried GetCustomerManagerLink but have no idea what to put in 
ResourceName

Please help


On Thursday, 21 March 2019 06:37:42 UTC+11, googleadsapi-forumadvisor wrote:
>
> Hello Jakub,
>
> For the AdWords API 
> <https://developers.google.com/adwords/api/docs/reference/release-notes/v201809>
>  the 
> client libraries are available here 
> <https://developers.google.com/adwords/api/docs/clientlibraries> and for 
> the Google Ads API 
> <https://developers.google.com/google-ads/api/docs/release-notes> the 
> client libraries available here 
> <https://developers.google.com/google-ads/api/docs/client-libs>. Using 
> AdWords API you can try the ManagedCustomerService 
> <https://developers.google.com/adwords/api/docs/reference/v201809/ManagedCustomerService#mutatelink>
>  and 
> can refer the Linking accounts section of this guide 
> <https://developers.google.com/adwords/api/docs/guides/accounts-overview#managedcustomerservice>
>  for 
> more information about the ManagedCustomerService.
>
> If you are using the Google Ads API, you should use 
> CustomerClientLinkService.MutateCustomerClientLink 
> <https://developers.google.com/google-ads/api/reference/rpc/google.ads.googleads.v1.services#google.ads.googleads.v1.services.CustomerClientLinkService>
>  service. 
> Below is the code sample to extend the invitation to the client account in 
> Java. Since the examples are not available in out client libraries I can 
> provide sample in Java only at this point of time. You can try the similar 
> steps in PHP to extend the invitation. Likewise you have to update the 
> ManagerLinkStatus to ACTIVE from the client account to accept the 
> invitation.
>
> Code Snippet Below in Java to extend the invitation to the client account 
> from the manager account:
>
> private void runExample(
> GoogleAdsClient googleAdsClient, long customerId) {
> try (CustomerClientLinkServiceClient customerClientLinkServiceClient = 
> googleAdsClient.getCustomerClientLinkServiceClient()) 
> {
>       //Creating resource name for customer
>       String customerResourceName = 
> ResourceNames.customer(123456789L);//the client account to which you are 
> expanding the invitation. 
>
>       //Creating customerClientLink object
>       CustomerClientLink customerClientLink = 
> CustomerClientLink.newBuilder()
>      .setClientCustomer(StringValue.of(customerResourceName))
>      .setStatus(ManagerLinkStatus.PENDING)
>      .build();
>
>      //creating operation for the mutate request
>      CustomerClientLinkOperation operation = 
> CustomerClientLinkOperation.newBuilder()
>      .setCreate(customerClientLink)
>      .build();
>
>      // Send the operation in a mutate request.
>     MutateCustomerClientLinkResponse response =
>     customerClientLinkServiceClient.mutateCustomerClientLink("18xxxxxx17", 
> operation);// Your manager account Id should be placed in the mutate call.
>     // Print the resource name of each updated object. 
>     System.out.println(response.getResult());
>     }
> }
>
> Please elaborate if you have any further questions.
>
> Regards,
> Sai Teja, Google Ads API Team
>
>
> =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
> Also find us on our blog and discussion group:
>     http://googleadsdeveloper.blogspot.com/search/label/adwords_api
>     https://developers.google.com/adwords/api/community/
> =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
>
> Was your question answered? Please rate your experience with us by taking 
> a short survey.
> If not -- reply to this email and tell us what else we can do to help.
>
> Take Survey 
> <https://support.google.com/google-ads/contact/survey_transactional?caseid=8-4353000024999&hl=en&ctx=1>
>
> Also find us on our blog and discussion group:
> http://googleadsdeveloper.blogspot.com/search/label/adwords_api
> https://developers.google.com/adwords/api/community/
> On 03/20/19 07:13:19 [email protected] <javascript:> wrote:
>
> Hi Everyone !
>
> I am facing the same problem with Ads Api.
>
> I have created new account X under My manager account Y.
> I would like to link random new user with ads account Z to my newly 
> created account X.
>
> But that way I should be able to manage account X as manager and also user 
> will see this account X under his manager account Z.
>
> is it possible?
>
> Do somebody know the code in PHP for that operation?
> Also what library should I use the AdWords Api or Ads Api ?
>
> -- 
> -- 
> =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
> Also find us on our blog:
> https://googleadsdeveloper.blogspot.com/
> =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
>  
> You received this message because you are subscribed to the Google
> Groups "AdWords API and Google Ads API Forum" group.
> To post to this group, send email to [email protected]
> To unsubscribe from this group, send email to
> [email protected]
> For more options, visit this group at
> http://groups.google.com/group/adwords-api?hl=en
> --- 
> You received this message because you are subscribed to the Google Groups 
> "AdWords API and Google Ads API Forum" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to [email protected].
> Visit this group at https://groups.google.com/group/adwords-api.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/adwords-api/72a06e46-9670-4825-af62-c8633b1ddb15%40googlegroups.com
>  
> <https://groups.google.com/d/msgid/adwords-api/72a06e46-9670-4825-af62-c8633b1ddb15%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
> For more options, visit https://groups.google.com/d/optout.
>
>

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog:
https://googleadsdeveloper.blogspot.com/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API and Google Ads API Forum" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/adwords-api?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"AdWords API and Google Ads API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
Visit this group at https://groups.google.com/group/adwords-api.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/fb4a8f01-dabd-4322-87d5-32a616d9441b%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
  • Re: [PH... ludovic . web2roi
    • RE... googleadsapi-forumadvisor via AdWords API and Google Ads API Forum
  • Re: [PH... ludovic . web2roi
  • Re: [PH... ludovic . web2roi
    • RE... googleadsapi-forumadvisor via AdWords API and Google Ads API Forum
  • Re: [PH... ludovic . web2roi
  • Re: [PH... ludovic . web2roi
    • RE... googleadsapi-forumadvisor via AdWords API and Google Ads API Forum
  • Re: [PH... Kuba Dev
    • RE... googleadsapi-forumadvisor via AdWords API and Google Ads API Forum
      • ... Van Vu
        • ... Kuba Dev
          • ... googleadsapi-forumadvisor via AdWords API and Google Ads API Forum
            • ... Van Vu
              • ... googleadsapi-forumadvisor via AdWords API and Google Ads API Forum

Reply via email to