Skip to main content

一个币安(Binance)插件,提供行情、交易、资产查询和实时价格预警功能。

Project description

NoneBotPluginLogo

NoneBotPluginText

nonebot-plugin-binance

✨ NoneBot 插件简单描述 ✨

license pypi python

一个币安 NoneBot2 插件

📖 介绍

通过集成币安官方 API,为用户提供行情查询、K线图表、资产管理、实盘交易及价格监控等功能。

💿 安装

使用 nb-cli 安装 在 nonebot2 项目的根目录下打开命令行, 输入以下指令即可安装
nb plugin install nonebot-plugin-binance
使用包管理器安装 在 nonebot2 项目的插件目录下, 打开命令行, 根据你使用的包管理器, 输入相应的安装命令
pip
pip install nonebot-plugin-binance
pdm
pdm add nonebot-plugin-binance
poetry
poetry add nonebot-plugin-binance
conda
conda install nonebot-plugin-binance

打开 nonebot2 项目根目录下的 pyproject.toml 文件, 在 [tool.nonebot] 部分追加写入

plugins = ["nonebot_plugin_binance"]

⚙️ 配置

必填配置

在 nonebot2 项目的.env文件中添加下表中的必填配置

配置项 必填 默认值 说明
binance_master_key 用于加密用户API的主密钥

可选配置

在 nonebot2 项目的.env文件中添加下表中的可选配置

配置项 必填 默认值 说明
binance_api_proxy 币安API的代理URL,如果您的服务器无法直接访问币安,请设置此项
binance_renderer_proxy 用于下载图片、字体等渲染资源的代理,如果服务器访问Github等网络不稳定,请设置此项
binance_ws_proxy 币安WebSocket的代理URL,如果需要的话

🎉 使用

主密钥

可以使用以下代码生成:

from cryptography.fernet import Fernet; print(Fernet.generate_key().decode())

指令表

使用bn help查看帮助

效果图

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_binance-0.0.9.tar.gz (41.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

nonebot_plugin_binance-0.0.9-py3-none-any.whl (50.4 kB view details)

Uploaded Python 3

File details

Details for the file nonebot_plugin_binance-0.0.9.tar.gz.

File metadata

  • Download URL: nonebot_plugin_binance-0.0.9.tar.gz
  • Upload date:
  • Size: 41.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for nonebot_plugin_binance-0.0.9.tar.gz
Algorithm Hash digest
SHA256 dffd920d97a8795b066e35292b5a018892a88eedfe377439c9e02e72b799b81c
MD5 70cb354c354f22d2490e3ab8ee77e19a
BLAKE2b-256 c02fc128937e997d5ae5fcbc78ccd07d943050692bfd8817a41c859cf1b5261d

See more details on using hashes here.

File details

Details for the file nonebot_plugin_binance-0.0.9-py3-none-any.whl.

File metadata

File hashes

Hashes for nonebot_plugin_binance-0.0.9-py3-none-any.whl
Algorithm Hash digest
SHA256 58b3f9c0b7df64b41e274d6da45de79a480e903eaae4083d43d77ef73ca9fb4b
MD5 f97e9471d8b8f05eaa790d138d95a32a
BLAKE2b-256 b1655cf55f20d67a8b8ed65c6dbb5a5c05d1459bfef66c61f2376230b087059c

See more details on using hashes here.

Supported by

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