5

JCJC错别字检测系统API接口使用文档-添加黑名单、白名单词汇

 2 years ago
source link: https://blog.csdn.net/accesine960/article/details/116095794
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.

JCJC错别字检测系统API接口使用文档-添加黑名单、白名单词汇

original.png
田春峰 2021-04-24 17:01:08 18

JCJC错别字检测系统API接口使用文档-添加黑名单、白名单词汇

1、地址前缀:http://IP:PORT/spellcheck/

2、所有的接口调用:请使用 HTTP POST 方法,不支持 GET 方法

3、所有的接口调用:请使用 JSON POST 格式,不支持表单 FORM POST 的格式

4、字段:"content" 是需要提交的词语

对于 JCJC SaaS 版本的用户,地址前缀:

http://api.CuoBieZi.net/spellcheck/

对于 JCJC IaaS 版本的用户,地址前缀:

http://IP:8631/spellcheck/

IP 为私有化部署的服务器IP

添加白名单词汇:

http://IP:PORT/spellcheck/add_important_words

使用 JSON POST  的方法,不支持 Form POST 的方法。

如下代码所示:

添加完成词汇后,可以使用查询接口,检查插入的结果:

http://IP:PORT/spellcheck/list_words

可以参考 上述代码 ,替换接口地址调用

添加敏感词、黑名单词汇的接口:

http://IP:PORT/spellcheck/add_sensitive_words

可以参考 上述代码 ,替换接口地址调用

1)目前只支持简体中文的字符,且字符之间不包含空格

2)不支持ASCII 字符的黑名单词汇、白名单词汇

3)添加词汇是实时生效的

4)添加词汇采用的异步机制,返回的状态为接口调用是否成功的状态,不一定保证存储到数据中

更详细的说明请参考 PDF API 接口文档:https://download.csdn.net/download/accesine960/17516787  。


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK