Integrating External Spell Checking
It is possible to create your own Web API endpoints and integrate your own spell checking and suggestions into the Writer.
Last updated
It is possible to create your own Web API endpoints and integrate your own spell checking and suggestions into the Writer.
Last updated
In order to enable the spellcheck integration, the Writer's server-config needs to be edited. The following should be added to your server-config's external
-config object:
The headers
-properties are useful if you need to send additional headers to your API.
Remember, the writer service needs to be restarted for server config changes to take effect
Your API needs to be able to handle the following requests to integrate with spell checking and suggestion.
Language codes from the writer are sent in the format [language-identifier]_[region_identifier]
. Where [language-identifier]
follows the ISO 639-1 standard, which is two letters, lowercased. The [region-identifier]
follows the ISO 3166-2 standard, which is two letters, uppercased.
Examples: sv_SE
, en_GB
, en_US
, nl_NL
The API must be able to receive the following request on an endpoint you define:
The API should respond with a single array containing the misspelled words in the same json-format as they were sent, if no words were misspelled, response should contain an empty array.
Response Format
Example Request
The API should be able to perform the call below, and output an array of the misspelled words, or an empty array.
Output:
The API must be able to receive the following request on an endpoint you define:
Request
Response
The API should respond with a single array containing the misspelled words in the same json-format as they were sent, if no words were misspelled, response should be an empty array.
Response Format
Example Request
The API should be able to perform the call below, and output an array of words, or an empty array.
Output
Field
Description
external.spellcheck
Contains the configuration for external spellchecking endpoints.
external.spellcheck.check
Optional Object containing configuration for external spellcheck requests.
external.spellcheck.check.url
Required Full url and path to your check request implementation.
external.spellcheck.check.headers
Optional Key-value object with extra header's which will be used in the request to your API.
external.spellcheck.suggestion
Optional Object containing configuration for external suggestion requests.
external.spellcheck.suggestion.url
Required Full url and path to your suggestion request implementation.
external.spellcheck.suggestion.headers
Optional Key-value object with extra header's which will be used in the request to your API.