cURL
curl "https://api.ruseo.cn/api/englishwords?word=cancel"
查询英语单词详细信息,含音标、翻译、短语、同根词、近义词、例句等
https://api.ruseo.cn/api/englishwords
接口调用前需要确认的核心配置。
/api/englishwordsenglishwords必填参数必须传入,示例值可直接用于联调。
免费API不强制要求API Key,但如果您希望统计个人调用次数,请在请求时附加参数 key=您的API_KEY。
注册账号后即可获得API Key。
| 参数名 | 必填 | 类型 | 说明 | 示例值 |
|---|---|---|---|---|
key |
否 | string | 可选参数:携带此参数可统计您的个人调用次数。请注册账号获取API Key。 | YOUR_API_KEY |
word |
是 | string | 要查询的英语单词 | cancel |
优先使用示例地址测试请求参数是否正确。
https://api.ruseo.cn/api/englishwords?word=cancel
curl "https://api.ruseo.cn/api/englishwords?word=cancel"
$url = 'https://api.ruseo.cn/api/englishwords?word=cancel';
$response = file_get_contents($url);
$data = json_decode($response, true);
fetch('https://api.ruseo.cn/api/englishwords?word=cancel')
.then(res => res.json())
.then(data => console.log(data));
实际返回内容以接口脚本处理结果为准。
{
"code": 0,
"msg": "success",
"data": {
"route": "englishwords",
"example": true
}
}
| 参数名 | 类型 | 说明 | 示例值 |
|---|---|---|---|
success |
boolean | 是否成功 | true |
word |
string | 单词 | heat |
book_id |
string | 词书ID | CET4_2 |
uk_phone |
string | 英式音标 | hiːt |
us_phone |
string | 美式音标 | hit |
uk_speech |
string | 英式发音URL | https://dict.youdao.com/dictvoice?audio=heat&type=1 |
us_speech |
string | 美式发音URL | https://dict.youdao.com/dictvoice?audio=heat&type=2 |
translations |
array | 翻译列表 | |
translations[].pos |
string | 词性 | n |
translations[].tran_cn |
string | 中文释义 | 热,炎热 |
phrases |
array | 短语列表 | |
phrases[].p_content |
string | 英文短语 | heat transfer |
phrases[].p_cn |
string | 中文释义 | 热传递,传热 |
rel_words |
array | 同根词列表 | |
rel_words[].Pos |
string | 词性 | adj |
rel_words[].Hwds |
array | 同根词详情 | |
rel_words[].Hwds[].hwd |
string | 单词 | heated |
rel_words[].Hwds[].tran |
string | 释义 | 热的;激昂的 |
synonyms |
array | 近义词列表 | |
synonyms[].pos |
string | 词性 | n |
synonyms[].tran |
string | 释义 | 高温;压力;热度 |
synonyms[].Hwds |
array | 近义词详情 | |
synonyms[].Hwds[].word |
string | 近义词 | pressure |
sentences |
array | 例句列表 | |
sentences[].s_content |
string | 英文例句 | Ice needs heat to melt. |
sentences[].s_cn |
string | 中文翻译 | 冰需要热才能融化。 |
点击左侧“发送请求”查看结果...