Giter Club home page Giter Club logo

yirimirai's Introduction

YiriMirai

公告:本项目原开发者已放弃对 YiriMirai 的维护,最后一个完全支持的 mirai-api-http 版本为 2.5。如果有人愿意继续维护此项目,请与原开发者联系。

在新的维护者到来前,建议换用 Graia Ariadne 等活跃维护的项目,也请关注原开发者的下一代 QQ 无头客户端支持库 awr

本项目现由 XYCode-Kerman 进行维护,新版本将于不久后发布


Licence PyPI Python Version Document CodeFactor

一个轻量级、低耦合度的基于 mirai-api-http 的 Python SDK。

本项目适用于 mirai-api-http 2.0 以上版本

安装

从 PyPI 安装:

pip install yiri-mirai
# 或者使用 poetry
poetry add yiri-mirai

此外,你还可以克隆这个仓库到本地,然后使用 poetry 安装:

git clone [email protected]:Wybxc/YiriMirai.git
cd YiriMirai
poetry install

使用

from mirai import Mirai, FriendMessage, WebSocketAdapter

if __name__ == '__main__':
    bot = Mirai(12345678, adapter=WebSocketAdapter(
        verify_key='your_verify_key', host='localhost', port=6090
    ))

    @bot.on(FriendMessage)
    async def on_friend_message(event: FriendMessage):
        if str(event.message_chain) == '你好':
            await bot.send(event, 'Hello World!')

    bot.run()

更多信息参看文档文档镜像

社区

QQ 群:766952599(链接

Github Discussion(链接

Discord(链接

Star History Chart

开源协议

由于 mirai 及 mirai-api-http 均采用了 AGPL-3.0 开源协议,本项目同样采用 AGPL-3.0 协议。

请注意,AGPL-3.0 是传染性协议。如果你的项目引用了 YiriMirai,请在发布时公开源代码,并同样采用 AGPL-3.0 协议。

yirimirai's People

Contributors

wybxc avatar xycode-kerman avatar rockchinq avatar zyckk4 avatar pyup-bot avatar

Stargazers

 avatar  avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.