简体   繁体   中英

Should I use SOAP or REST to automate external web service searching?

I hope to create an application which will send a barcode serial to this database:

http://www.upcdatabase.com/itemform.asp

which is a universal barcode repository for foods.

The food description is then returned to my application, which I will then identify the keyword of the food product, for example yogurt.

Once I have this keyword, I take it to this webpage:

http://nutridb.org/

And enter it into the search field, returning the nutritional values of the item, which I will then extract and present as information in my application.

I have been researching online and am confused as to how I can automate this process. Is it possible this can be done using REST and SOAP?

That upcdatabase site you mention has an XML-RPC interface to it, so I would say you are probably limited to that. You could use a RESTful approach to screen scrape but I looked at the HTML and there is little or no semantic markup in the HTML so it is going to be hard.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM