Click here to Skip to main content
15,886,519 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
app.config

program.cs
    static void Main(string[] args)
    {
        // Instantiate Amazon ProductAdvertisingAPI client
        AWSECommerceServicePortTypeClient amazonClient = new AWSECommerceServicePortTypeClient();

        // prepare an ItemSearch request
        ItemSearchRequest request = new ItemSearchRequest();
        request.SearchIndex = "Books";
        request.Title = "WCF";
        request.ResponseGroup = new string[] { "Small" };

        ItemSearch itemSearch = new ItemSearch();
        itemSearch.Request = new ItemSearchRequest[] { request };
        itemSearch.AWSAccessKeyId = ConfigurationManager.AppSettings["accessKeyId"];
        itemSearch.AWSAccessKeyId = ConfigurationManager.AppSettings["secretKey"];
        itemSearch.AssociateTag = "my value";

        // send the ItemSearch request
        ItemSearchResponse response = amazonClient.ItemSearch(itemSearch);

        // write out the results from the ItemSearch request
        foreach (var item in response.Items[0].Item)
        {
            Console.WriteLine(item.ItemAttributes.Title);
        }
        Console.WriteLine("done...enter any key to continue>");
        Console.ReadLine();

    }
}


What I have tried:

I tried to sign it but with no hope

signingBehavior which in the app.config build succeded bud has blue line under it said invalid child element signingBehavior , is that the problem but the build succeeded I don't know any one have any idea
Posted
v2
Comments
Karthik_Mahalingam 18-Sep-16 2:12am    
inner exception?
Sarah Mohammed77 22-Sep-16 8:52am    
https://msdn.microsoft.com/query/dev12.query?appId=Dev12IDEF1&l=EN-US&k=k(EHWeb);k(TargetFrameworkMoniker-.NETFramework,Version%3Dv4.0);k(DevLang-csharp)&rd=true


this link for inner exception
Sarah Mohammed77 22-Sep-16 10:17am    
the namspace is "http://webservices.amazon.com/AWSECommerceService/2011-08-01"

1 solution

 
Share this answer
 
Comments
Sarah Mohammed77 17-Sep-16 8:49am    
same error 400 bad request the errors happened with me in all the amazon samples
Then please contact their support.
Sarah Mohammed77 22-Sep-16 10:05am    
could you give me email so I can send my issue

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900