<div style="text-align: center">
<h1>Karas</h1><br>
<p>这是一个基于<a href="https://github.com/project-mirai/mirai-api-http">mirai-api-http</a>的轻量级,高性能qq消息处理与发送框架 </p>
</div>
## Version
![Mirai-API-API-Version](https://img.shields.io/badge/mirai--http--api->=2.5.0-brightgreen.svg?style=plastic)
![python-Version](https://img.shields.io/badge/python->=3.7-brightgreen.svg?style=plastic)
![karas-Version](https://img.shields.io/badge/karas-0.2.11-brightgreen.svg?style=plastic)
## 使用
- 使用pip安装本项目
```shell script
pip3 install karas_py
```
- 一个群聊复读机实例:
(async)
```python
from karas.box import Yurine,MessageChain,Group
yurine = Yurine(
host="localhost",
port=8080,
qq=114514,
verifyKey="1919810"
)
@yurine.listen("GroupMessage")
async def gm_event(group:Group, message: MessageChain):
# async send message
await yurine.sendGroup(group, message)
yurine.run_forever()
```
(sync send message)
```python
from karas.box import Yurine,MessageChain,Group, Plain
yurine = Yurine(
host="localhost",
port=8080,
qq=114514,
verifyKey="1919810"
).start()
yurine.sendFriend(1808107177, [Plain("Hello World")])
yurine.close()
```
## 实例
[ATRI](https://github.com/ShiroDoMain/ATRI-qqbot)使用了该框架开发,Bot的qq为1977987864
## Notice
该框架目前处于开发中状态,如果您在使用过程中发现了bug或者您有好的建议,请尽情提出您的[issues](https://github.com/ShiroDoMain/Karas/issues/new)
## 开源
该框架遵循AGPL-3.0协议开源,
```
iTXTech Mirai Console Loader
Copyright (C) 2020-2022 iTX Technologies
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU Affero General Public License as
published by the Free Software Foundation, either version 3 of the
License, or (at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU Affero General Public License for more details.
You should have received a copy of the GNU Affero General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
```
## 鸣谢
本项目使用了[JetBrains](https://www.jetbrains.com/?from=karas)的工具[PyCharm](https://www.jetbrains.com/pycharm/?from=karas)开发
感谢JetBrains公司为开源项目提供的授权和支持
![https://www.jetbrains.com/?from=karas](https://avatars.githubusercontent.com/u/878437?s=200&v=4)
Raw data
{
"_id": null,
"home_page": "https://github.com/ShiroDoMain/Karas",
"name": "karas-py",
"maintainer": "",
"docs_url": null,
"requires_python": "",
"maintainer_email": "",
"keywords": "qqbot async",
"author": "ShiroDoMain",
"author_email": "b1808107177@gmail.com",
"download_url": "https://files.pythonhosted.org/packages/a6/ba/e04ab18970d15ca301da5de5bc801d11ed96eec2d92a85447af1691ffcc3/karas_py-0.2.11.tar.gz",
"platform": null,
"description": "<div style=\"text-align: center\">\n <h1>Karas</h1><br>\n<p>\u8fd9\u662f\u4e00\u4e2a\u57fa\u4e8e<a href=\"https://github.com/project-mirai/mirai-api-http\">mirai-api-http</a>\u7684\u8f7b\u91cf\u7ea7\uff0c\u9ad8\u6027\u80fdqq\u6d88\u606f\u5904\u7406\u4e0e\u53d1\u9001\u6846\u67b6 </p>\n</div>\n\n## Version \n![Mirai-API-API-Version](https://img.shields.io/badge/mirai--http--api->=2.5.0-brightgreen.svg?style=plastic)\n![python-Version](https://img.shields.io/badge/python->=3.7-brightgreen.svg?style=plastic)\n![karas-Version](https://img.shields.io/badge/karas-0.2.11-brightgreen.svg?style=plastic) \n## \u4f7f\u7528 \n- \u4f7f\u7528pip\u5b89\u88c5\u672c\u9879\u76ee \n```shell script\npip3 install karas_py\n``` \n- \u4e00\u4e2a\u7fa4\u804a\u590d\u8bfb\u673a\u5b9e\u4f8b: \n(async)\n```python\nfrom karas.box import Yurine,MessageChain,Group\nyurine = Yurine(\n host=\"localhost\",\n port=8080,\n qq=114514,\n verifyKey=\"1919810\"\n)\n\n@yurine.listen(\"GroupMessage\")\nasync def gm_event(group:Group, message: MessageChain):\n # async send message\n await yurine.sendGroup(group, message)\n\nyurine.run_forever()\n``` \n(sync send message)\n```python\nfrom karas.box import Yurine,MessageChain,Group, Plain\nyurine = Yurine(\n host=\"localhost\",\n port=8080,\n qq=114514,\n verifyKey=\"1919810\"\n).start()\n\nyurine.sendFriend(1808107177, [Plain(\"Hello World\")])\n\nyurine.close()\n```\n\n## \u5b9e\u4f8b\n[ATRI](https://github.com/ShiroDoMain/ATRI-qqbot)\u4f7f\u7528\u4e86\u8be5\u6846\u67b6\u5f00\u53d1\uff0cBot\u7684qq\u4e3a1977987864 \n\n## Notice \n\u8be5\u6846\u67b6\u76ee\u524d\u5904\u4e8e\u5f00\u53d1\u4e2d\u72b6\u6001\uff0c\u5982\u679c\u60a8\u5728\u4f7f\u7528\u8fc7\u7a0b\u4e2d\u53d1\u73b0\u4e86bug\u6216\u8005\u60a8\u6709\u597d\u7684\u5efa\u8bae\uff0c\u8bf7\u5c3d\u60c5\u63d0\u51fa\u60a8\u7684[issues](https://github.com/ShiroDoMain/Karas/issues/new)\n\n## \u5f00\u6e90\n\u8be5\u6846\u67b6\u9075\u5faaAGPL-3.0\u534f\u8bae\u5f00\u6e90\uff0c\n```\niTXTech Mirai Console Loader\nCopyright (C) 2020-2022 iTX Technologies\n\nThis program is free software: you can redistribute it and/or modify\nit under the terms of the GNU Affero General Public License as\npublished by the Free Software Foundation, either version 3 of the\nLicense, or (at your option) any later version.\n\nThis program is distributed in the hope that it will be useful,\nbut WITHOUT ANY WARRANTY; without even the implied warranty of\nMERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\nGNU Affero General Public License for more details.\n\nYou should have received a copy of the GNU Affero General Public License\nalong with this program. If not, see <http://www.gnu.org/licenses/>.\n```\n\n\n## \u9e23\u8c22 \n\u672c\u9879\u76ee\u4f7f\u7528\u4e86[JetBrains](https://www.jetbrains.com/?from=karas)\u7684\u5de5\u5177[PyCharm](https://www.jetbrains.com/pycharm/?from=karas)\u5f00\u53d1 \n\u611f\u8c22JetBrains\u516c\u53f8\u4e3a\u5f00\u6e90\u9879\u76ee\u63d0\u4f9b\u7684\u6388\u6743\u548c\u652f\u6301 \n![https://www.jetbrains.com/?from=karas](https://avatars.githubusercontent.com/u/878437?s=200&v=4)\n\n",
"bugtrack_url": null,
"license": "GNU Affero General Public License v3.0",
"summary": "\u4e00\u4e2a\u57fa\u4e8emirai-api-http\u7684\u9ad8\u6027\u80fdqq\u6d88\u606f\u5904\u7406\u6846\u67b6",
"version": "0.2.11",
"project_urls": {
"Homepage": "https://github.com/ShiroDoMain/Karas"
},
"split_keywords": [
"qqbot",
"async"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "a6bae04ab18970d15ca301da5de5bc801d11ed96eec2d92a85447af1691ffcc3",
"md5": "f00e1ef19d3c95eaeb840fada2742da9",
"sha256": "f43a61bfa43ea9004c868553d8031dd7c505dce5a0b9aa98e535a9ded79499dc"
},
"downloads": -1,
"filename": "karas_py-0.2.11.tar.gz",
"has_sig": false,
"md5_digest": "f00e1ef19d3c95eaeb840fada2742da9",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 40442,
"upload_time": "2023-06-14T02:48:35",
"upload_time_iso_8601": "2023-06-14T02:48:35.409974Z",
"url": "https://files.pythonhosted.org/packages/a6/ba/e04ab18970d15ca301da5de5bc801d11ed96eec2d92a85447af1691ffcc3/karas_py-0.2.11.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2023-06-14 02:48:35",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "ShiroDoMain",
"github_project": "Karas",
"travis_ci": false,
"coveralls": false,
"github_actions": false,
"requirements": [],
"lcname": "karas-py"
}