Cookies on MGBrown.com

This web site uses some strictly nesessary cookies to make this web site work.

We would also like to set additional cookies to understand how you use MGBrown.com, remember your settings and improve our services.

Yahoo Search API Fixes

I have uploaded a new version of my Yahoo Search API for C# & VB.Net. It fixes the following two issues:

1. I updated a number of functions due to a missing "=" in some of the request parameters. This may result in altered behaviour as the parameters will no longer be ignored by Yahoo. The functions and parameters are listed below:

ImageSearch - Results
LocalSearch - Results
NewsSearch - Type
VideoSearch - Type

2. TestHarness was using the value "all" for the format parameter rather than "any". This was causing the Yahoo Web Service to return a Bad Request error. I have now corrected this.

The new code can be downloaded by visiting my Download page.

Comments

Re: Yahoo Search API Fixes

Nice work and thanks for sharing.

How did you get XSD.EXE to parse the response schema ? When I try this, I get the error: Undefined data type: 'token'.

C:\Projects>xsd LocalSearchResponse.xml /classes
Microsoft (R) Xml Schemas/DataTypes support utility
[Microsoft (R) .NET Framework, Version 2.0.50727.42]
Copyright (C) Microsoft Corporation. All rights reserved.
Error: There was an error processing 'LocalSearchResponse.xml'.
- Undefined data type: 'token'.


Henry

Comment from Henry Bruce at Thursday, 30 March 2006 01:43AM (GMT+00)

Re: Yahoo Search API Fixes


This is great info.
I spent time looking for samples using VB.NET including the overture yahoo search marketing forums and account support but had little success.
With the google adwords api, I built a web service and used the url to link in the .xml
Should I do the same with the two .xsd documents request/response and link the file path. I am not sure how to import the .xsd and use it as a web service so that all the classes and members are available within the namespace to program with.

Any help is appreciated, thanks
you can email me at rmehrer@netshops.com




Comment from Ron at Tuesday, 25 April 2006 04:30PM (GMT+00)

Re: Yahoo Search API Fixes

Suposing you have a new schema X.xsd you would need to run it through the xsd.exe tool to generate the classes required. The command line would look something like this:

xsd.exe schemas\v1\X.xsd /c /l:vb /namespace:Yahoo.API.NewResponse /out:Yahoo.API

This will generate a .vb file with the new classes in. You will need to include this in your project and add a function to the YahooSearchService class. Simply copy one of the other functions and change the namespace, request url and parameters.

Comment from Martin Brown at Wednesday, 26 April 2006 10:19AM (GMT+00)

Sorry, this post is no longer accepting comments.