OPERATION_NOT_PERMITTED_FOR_CONTEXT

1,323 views
Skip to first unread message

JustRide with Vinay

unread,
Jul 7, 2021, 1:41:09 PM7/7/21
to AdWords API and Google Ads API Forum
Fault: errors {
  error_code {
    context_error: OPERATION_NOT_PERMITTED_FOR_CONTEXT
  }
  message: "The operation is not allowed for the given context."
  location {
    field_path_elements {
      field_name: "operations"
      index: 0
    }
  }

Google Ads API Forum Advisor

unread,
Jul 7, 2021, 9:37:30 PM7/7/21
to pvina...@gmail.com, adwor...@googlegroups.com

Hello there,

Thank you for raising this to us.

So our team can better check on the issue, could you share with us the following details below?

Please send the requested details via the Reply privately to author option. If this option is not available, you may send the details directly to our googleadsa...@google.com alias instead.

Regards,

Google Logo
Mark Kevin Albios
Google Ads API Team
 


ref:_00D1U1174p._5004Q2JZPPz:ref

Aditya Naukri

unread,
Aug 5, 2021, 2:30:50 AM8/5/21
to AdWords API and Google Ads API Forum
I am also facing the same issue. I am trying to link my Customer Match UserList to the campaign. Getting the following error using the code:
 

CampaignCriterionServiceClient campaignCriterionServiceClient = googleAdsClient.getLatestVersion().createCampaignCriterionServiceClient();
  UserListInfo userListInfo = UserListInfo.newBuilder().setUserList(userList).build();
  CampaignCriterion campaignCriterion = CampaignCriterion.newBuilder().setCampaign(ResourceNames.campaign(customerId, campaignId)).mergeUserList(userListInfo).build();
  
  CampaignCriterionOperation criterionOperation = CampaignCriterionOperation.newBuilder().setCreate(campaignCriterion).build();
  
  MutateCampaignCriteriaResponse response = campaignCriterionServiceClient.mutateCampaignCriteria(Long.toString(customerId), ImmutableList.of(criterionOperation)); 

ERROR:

request_id: "2aU6KGGvOVHmF06kHCreNA"
Status: Status{code=INVALID_ARGUMENT, description=Request contains an invalid argument., cause=null}.Request ID 2aU6KGGvOVHmF06kHCreNA failed due to GoogleAdsException. Underlying errors:  Error 0: error_code {  context_error: OPERATION_NOT_PERMITTED_FOR_CONTEXT}message: "The operation is not allowed for the given context."trigger {  string_value: "DISPLAY(DISPLAY_FULL_AUTOMATION)"}location {  field_path_elements {    field_name: "operations"    index: 0  }  field_path_elements {    field_name: "create"  }  field_path_elements {    field_name: "user_list"  }}

Google Ads API Forum Advisor

unread,
Aug 6, 2021, 3:44:30 AM8/6/21
to testnaukrica...@gmail.com, adwor...@googlegroups.com
Hi,

I noticed that you posted on several threads regarding your concern. Our team recommends that we continue discussions on a single thread instead, for better tracking of issues.

That being said, you may refer to my response to your concern in this thread, to address the OPERATION_NOT_PERMITTED_FOR_CONTEXT error and also the other error you mentioned, concerning Smart Display Campaigns.

Best regards,

Google Logo
Peter Laurence Napa Oliquino
Google Ads API Team
 


ref:_00D1U1174p._5004Q2JZPPz:ref
Reply all
Reply to author
Forward
0 new messages