Skip to main content

基于 OneBot 适配器的 NoneBot2 百度翻译插件, 可以调用百度翻译 API 实现常用语种之间的互译

Project description

nonebot

Nonebot_Plugin_BaiduTranslate

✨ 基于OneBot适配器的NoneBot2百度翻译插件 ✨

功能

  • 可以调用百度翻译 API 实现常用语种之间的互译

安装

  • 使用 nb-cli
nb plugin install nonebot_plugin_baidutranslate
  • 使用 pip
pip install nonebot_plugin_baidutranslate

如何使用

.env 配置项

# 以下均为百度翻译配置,见 https://fanyi-api.baidu.com/doc/21
appid = "xxx"  # 你的 APP ID,在百度翻译的开发者中心里可以找到
key = "xxx"    # 你的密钥,在百度翻译的开发者中心里可以找到
salt = "xxx"   # 随机字符串

各配置项的含义如上。

指令

使用以下指令触发,需加上指令前缀

x翻x [内容]

图片示例

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

nonebot_plugin_baidutranslate-0.1.0.tar.gz (6.0 kB view hashes)

Uploaded Source

Built Distribution

nonebot_plugin_baidutranslate-0.1.0-py2.py3-none-any.whl (7.7 kB view hashes)

Uploaded Python 2 Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page