Getting an Internal Error Exception when Creating Negative Keywords to a Negative Keyword List

Julius Decena 0 Reputation points
2023-07-19T22:24:21.6433333+00:00

I'm trying to add negative keywords to a negative keyword list using Bing Ads .NET SDK but I'm receiving this error message:

The server was unable to process the request due to an internal error. For more information about the error, either turn on IncludeExceptionDetailInFaults (either from ServiceBehaviorAttribute or from the <serviceDebug> configuration behavior) on the server in order to send the exception information back to the client, or turn on tracing as per the Microsoft .NET Framework SDK documentation and inspect the server trace logs.

I don't have any problems with authentication, tokens, or with the SDK, since I am able to create/update/remove the keyword list.

Here is a code snippet on how I add the negative keywords:

var client = CampaignManagementServiceClient();

var listItems = new List<SharedListItem>();

listItems.Add(new NegativeKeyword() {
	Text = "Sample Text",
	MatchType = MatchType.Exact
});

var request = new AddListItemsToSharedListRequest()
{
	ListItems = listItems,
	SharedList = new SharedList() { Id = [valid negative keyword list ID] },
	CustomerId = [redacted],
	CustomerAccountId = [redacted],
	AuthenticationToken = [redacted],
	DeveloperToken = [redacted]
}

var response = client.AddListItemsToSharedList(request);
Microsoft Advertising API
Microsoft Advertising API
A Microsoft API that provides programmatic access to Microsoft Advertising to manage large campaigns or to integrate your marketing with other in-house systems.
416 questions
0 comments No comments
{count} votes

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.