Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot assign to the Operations field of a Mutate request #351

Closed
Nilesailor opened this issue Feb 18, 2022 · 1 comment
Closed

Cannot assign to the Operations field of a Mutate request #351

Nilesailor opened this issue Feb 18, 2022 · 1 comment
Labels
bug Something isn't working

Comments

@Nilesailor
Copy link

I can successfully execute Mutate requests if I simply add the customerID and the Operations array as follows:

MutateAdGroupAdsResponse adsResponse = adsService.MutateAdGroupAds(account.AccountID, statusOperations);

However, I need to set the ResponseContentType to return the MutableResource. To do that, I set up a request, but doing this will not allow assignment of the operations to the Operations element. It throws a "cannot be assigned to -- it is read only" error. All of the Operations fields for Mutate Request objects appear to only have the "get;" defined.

image

So if we cannot create a request object, how do we get access to the ResponseContentType field?

@Nilesailor Nilesailor added the bug Something isn't working label Feb 18, 2022
@Nilesailor
Copy link
Author

Hmmmm... needed brackets around statusOperations even though statusOperations is a List. Feels strange, but I'll go with it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant