openVocab logoopenVocab

Basic English

basic-en

词典说明
基础英语单词查询词库,当前项目仅提供这一套固定词典。
语言:en
接口:`/api/dict/basic-en?word=hello`
返回:JSON
用途:单词查询

调用方式

使用固定的 basic-en 路径进行查询。

接口说明
使用 GET 请求查询 basic-en 词典中的单词。
请求地址
`/api/dict/basic-en?word=单词`
可选参数
fields 可指定返回字段,例如 fields=us,translations。 不传时返回完整字段。
示例
curl "/api/dict/basic-en?word=hello"
curl "/api/dict/basic-en?word=hello&fields=us,translations"
返回字段
成功时返回 {"success": true, "data": {...}}
字段说明
以下是 `data` 对象中常见字段的含义。
wordstring

单词本体,通常就是查询词本身。

usstring

美式音标。

ukstring

英式音标。

translationstring

首选短译,适合列表、卡片和快速展示。

translationsarray

基础释义列表。每一项通常包含 `translation` 和 `type`。

phrasesarray

常见短语列表。每一项通常包含 `phrase` 和 `translation`。

sentencesarray

例句列表。每一项通常包含 `sentence` 和 `translation`。

示例返回
下面展示的是 `data` 字段内部的典型结构。
{
  "word": "hello",
  "us": "hɛˈlo, hə-",
  "uk": "hə'ləʊ; he-",
  "translation": "喂",
  "translations": [
    {
      "translation": "喂",
      "type": "int"
    }
  ],
  "phrases": [
    {
      "phrase": "say hello",
      "translation": "打招呼;问好"
    },
    {
      "phrase": "hello everyone",
      "translation": "大家好"
    }
  ],
  "sentences": [
    {
      "sentence": "Hello, John! How are you?",
      "translation": "喂,约翰!你好吗?"
    }
  ]
}
在线测试
输入单词后直接调用 `basic-en` 查询接口。
返回首页在线测试