Does anyone know of a web service for finding word definitions that could return the results in JSON?
I found http://words.bighugelabs.com/api.php but nothing was found for definitions / dictionary.
Ideally, I would take a dictionary file and create my own API for it, but this is for demonstration and we need something short term that can be called from a javascript function.
wiktionary.org provides APIs like:
http://en.wikipedia.org/w/api.php?action=query&list=search&srsearch=Television&format=json
returns
{
"query": {"searchinfo": {"totalhits": 208862},
"search": [{
"ns": 0,
"title": "Television",
"snippet": "<span class='searchmatch'>Television<\/span> (TV) is a widely used telecommunication medium for transmitting and receiving moving images , either monochromatic (\"black <b>...<\/b> ",
"size": 28228,
"wordcount": 3566,
"timestamp": "2009-10-02T15:09:56Z"},
...
]},
"query-continue": {"search": {"sroffset":10}}
}
I think this is what you are looking for
- bighugelabs API - Json fromat
- aonaware services - XML โโformat
Not sure if it will suit your needs, but answer.com has webmaster tools that offer a variety of services, including dictionary search. Don't know if anyone can be called from javascript.
In no time, you can set up a reverse proxy on your server that allows AJAX to consume your favorite dictionary site, and then "clear" the definitions from the returned document. This is obviously not a long-term solution, but at one time, you probably won't run into problems.
It is a web service and several dictionaries:
http://services.aonaware.com/DictService/DictService.asmx
PS I missed the JSON part of your question.