Name | asgi_aiogram JSON |
Version |
0.1.2
JSON |
| download |
home_page | None |
Summary | fast ASGI wraper for aiogram |
upload_time | 2024-11-10 23:59:14 |
maintainer | None |
docs_url | None |
author | RootShinobi |
requires_python | <4.0,>=3.9 |
license | MIT |
keywords |
|
VCS |
|
bugtrack_url |
|
requirements |
No requirements were recorded.
|
Travis-CI |
No Travis.
|
coveralls test coverage |
No coveralls.
|
__base usage__
```python
from aiogram import Dispatcher, Bot
from asgi_aiogram import ASGIAiogram
from asgi_aiogram.strategy import SingleStrategy
dp = Dispatcher()
@dp.startup()
async def startup(dispatcher: Dispatcher, bot: Bot):
await bot.close()
await bot.set_webhook(
url='https://example.com/bot',
allowed_updates=dispatcher.resolve_used_update_types()
)
bot = Bot(token="<token>")
app = ASGIAiogram(
dispatcher=dp,
strategy=SingleStrategy(bot=bot, path="/bot")
)
```
```commandline
uvicorn main:app
```
Raw data
{
"_id": null,
"home_page": null,
"name": "asgi_aiogram",
"maintainer": null,
"docs_url": null,
"requires_python": "<4.0,>=3.9",
"maintainer_email": null,
"keywords": null,
"author": "RootShinobi",
"author_email": "111008396+RootShinobi@users.noreply.github.com",
"download_url": "https://files.pythonhosted.org/packages/ed/25/b1e71ccdffe31bb880cab24d996b63355019525572c73b1a5c374f062b17/asgi_aiogram-0.1.2.tar.gz",
"platform": null,
"description": "__base usage__\n```python\nfrom aiogram import Dispatcher, Bot\nfrom asgi_aiogram import ASGIAiogram\nfrom asgi_aiogram.strategy import SingleStrategy\n\ndp = Dispatcher()\n\n@dp.startup()\nasync def startup(dispatcher: Dispatcher, bot: Bot):\n await bot.close()\n await bot.set_webhook(\n url='https://example.com/bot',\n allowed_updates=dispatcher.resolve_used_update_types()\n )\n\nbot = Bot(token=\"<token>\")\napp = ASGIAiogram(\n dispatcher=dp,\n strategy=SingleStrategy(bot=bot, path=\"/bot\")\n)\n```\n\n```commandline\nuvicorn main:app\n```\n",
"bugtrack_url": null,
"license": "MIT",
"summary": "fast ASGI wraper for aiogram",
"version": "0.1.2",
"project_urls": null,
"split_keywords": [],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "88b1fa60272bf63335ffd26f369ff810498a5af44844873a3dc8b0c8d4c9d66c",
"md5": "931612b8ef937f6ecbcf91bccdafc03e",
"sha256": "f3e1ce31b56795cebb844ca7127fa605aaf6d01e33c48cb4a4c865814efd8e51"
},
"downloads": -1,
"filename": "asgi_aiogram-0.1.2-py3-none-any.whl",
"has_sig": false,
"md5_digest": "931612b8ef937f6ecbcf91bccdafc03e",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": "<4.0,>=3.9",
"size": 6581,
"upload_time": "2024-11-10T23:59:13",
"upload_time_iso_8601": "2024-11-10T23:59:13.029224Z",
"url": "https://files.pythonhosted.org/packages/88/b1/fa60272bf63335ffd26f369ff810498a5af44844873a3dc8b0c8d4c9d66c/asgi_aiogram-0.1.2-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "ed25b1e71ccdffe31bb880cab24d996b63355019525572c73b1a5c374f062b17",
"md5": "fcab65af5ee2d17be7002d63ea514ff5",
"sha256": "f994e53e0fb79d8d79833d3b23d92a29365daeefe155ec7ef432113e59baa1b6"
},
"downloads": -1,
"filename": "asgi_aiogram-0.1.2.tar.gz",
"has_sig": false,
"md5_digest": "fcab65af5ee2d17be7002d63ea514ff5",
"packagetype": "sdist",
"python_version": "source",
"requires_python": "<4.0,>=3.9",
"size": 4082,
"upload_time": "2024-11-10T23:59:14",
"upload_time_iso_8601": "2024-11-10T23:59:14.639048Z",
"url": "https://files.pythonhosted.org/packages/ed/25/b1e71ccdffe31bb880cab24d996b63355019525572c73b1a5c374f062b17/asgi_aiogram-0.1.2.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-11-10 23:59:14",
"github": false,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"lcname": "asgi_aiogram"
}