WebSpellChecker.net Wiki

Home

Web API


The WebSpellChecker.net Web API provides suggestions for spelling and grammar corrections for a specified text.

Subscribing


To subscribe to Web API, please sign-up for our hosted service and get your Long customer ID (LCID)

Request url

http://www.webspellchecker.net/spellcheck3/script/ssrv.cgi?cmd=command&parameter=value&customerid=LCID

Web API commands

ParameterCommands
cmdcheck_spelling, user dictionary, grammar_check, api_version

?cmd=check_spelling

Parameter Possible ValuesDescription
format json, xml Response format: JSON or XML (default)
callback any JSON callback function: format=json
out_type positions, wordswords - returns misspelled, words and suggestions, positions - returns position in text of misspellings and suggestions (default: words)
ignore_all_caps 0, 1If ignore_all_caps is set to “1“, all-caps words will be ignored (default: “0”)
ignore_words_with_numbers 0, 1 If ignore_words_with_numbers is set to “1”, all words with numbers will be ignored (default: “0”)
ignore_mixed_case 0, 1 If ignore_mixed_case is set to “1”, all mixed case words will be ignored (default: “0“)
ignore_domain_names 0, 1 If ignore_domain_names is set to “1”, all domain names will be ignores (default: “0“)
text any (UTF-8) A plain text that will be spell checked. If any tags are found in the text, they will be interpreted as a plain text as well
slangen_US en_GB pt_BR, da_DK, nl_NL, en_CA, fi_FI, fr_FR, fr_CA, de_DE, el_GR, it_IT, nb_NO, pt_PT, es_ES, sv_SE Language: en_US (default)
user_dictionary any User dictionary that will be used while spell checking
custom_dictionary any Custom dictionary that will be used while spell checking
user_wordlist any A coma-separated list of additional dictionary words that will be used while spell checking
version 1.0 Web API version
customerid Long Customer ID (LCID)

?cmd=grammar_check

Parameter Possible ValuesDescription
format json, xml Response format: JSON or XML (default)
callback any JSON callback function: format=json
text any (UTF-8) plain text that will be spell checked. If any tags found in text will be interpreted as a plain text as well
slangen_US en_GB Language: en_US (default)
version 1.0 Web API version
customerid Long Customer ID (LCID)

?cmd=user_dictionary

Parameter Possible ValuesDescription
format json, xml Response format: JSON or XML (default)
callback any JSON callback function: format=json
action create, rename, delete, addword, deleteword, editword, check, getdict create, rename, delete - performs an appropriate action with a user dictionary, addword action adds a word to a user dictionary, deleteword action removes a word from a user dictionary, editword action allows to replace a misspelled word with a correct one, check - checks if a user dictionary exists on the server,
getdict - returns the content of a user dictionary (it with JSON format only)
customerid The Hosted customers should use the Long Customer ID (LCID) which they received in the attached .ini file of the subscription email or “Download configuration file” from the user admin area. Long Customer ID (LCID)
&action=create
Parameter Possible ValuesDescription
name any User dictionary name
wordlist any Coma-separated values that will be added to a created dictionary
&action=delete
Parameter Possible ValuesDescription
name any User dictionary name
&action=rename
Parameter Possible valuesdescription
name any User dictionary name
new_name any New User dictionary name
&action=check
Parameter Possible ValuesDescription
name any User dictionary name
&action=addword
Parameter Possible ValuesDescription
name any User dictionary name
word any A word that will be added
&action=deleteword
Parameter Possible ValuesDescription
name any User dictionary name
word any A word that will be removed
&action=editword
Parameter Possible ValuesDescription
name any User dictionary name
word any A misspelled word that will be replaced
new_word any A correct word that will be replaced with the misspelled one

Usage Examples

Spell Check Request

http://www.webspellchecker.net/spellcheck3/script/ssrv.cgi?cmd=check_spelling&customerid=1:ua3xw1-2XyGJ3-GWruD3-6OFNT1-oXcuB1-nR6Bp4-hgQHc-EcYng3-sdRXG3-NOfFk&version=1.0&out_type=words&slang=en_US&callback=cc&format=xml&text=These+are+an+examples+of+a+sentences+with+two+misspelled+words+and+gramar+problems

Spell Check Response

<?xml version="1.0" encoding="utf-8"?>
<spellcheck>
<misspelling>
<word>texttt</word>
<suggestions>
<suggestion>text</suggestion>
<suggestion>texts</suggestion>
<suggestion>Tex</suggestion>
<suggestion>extent</suggestion>
<suggestion>exit</suggestion>
<suggestion>extant</suggestion>
<suggestion>extort</suggestion>
<suggestion>sextet</suggestion>
<suggestion>stet</suggestion>
<suggestion>extents</suggestion>
<suggestion>stetted</suggestion>
<suggestion>test</suggestion>
<suggestion>extorts</suggestion>
<suggestion>tatty</suggestion>
<suggestion>testate</suggestion>
</suggestions>
</misspelling>
</spellcheck>

Grammar Check Request

http://www.webspellchecker.net/spellcheck3/script/ssrv.cgi?cmd=grammar_check&customerid=1:ua3xw1-2XyGJ3-GWruD3-6OFNT1-oXcuB1-nR6Bp4-hgQHc-EcYng3-sdRXG3-NOfFk&version=1.0&out_type=words&slang=en_US&callback=cc&format=xml&text=These+are+an+examples+of+a+sentences+with+two+misspelled+words+and+gramar+problems

Grammar Check Response

<?xml version="1.0" encoding="utf-8"?>
<grammar_check>
<grammar_problem>
<phrase>an examples of</phrase>
<description>
Plural noun "examples" conflicts with modifier "an."
</description>
<suggestions>
<suggestion>an example of</suggestion>
<suggestion>examples of</suggestion>
</suggestions>
</grammar_problem>
</grammar_check>