<img src="https://cdn4.iconfinder.com/data/icons/social-media-and-logos-12/32/Logo_telegram_Airplane_Air_plane_paper_airplane-33-256.png" align="right" width="131" />
# TGConvertor


This module is small util for easy converting Telegram sessions to various formats (Telethon, Pyrogram, Tdata)
<hr/>
## Installation
```
$ pip install TGConvertor
```
## Quickstart
```python
from TGConvertor.manager.manager import SessionManager
from pathlib import Path
API_ID = 123
API_HASH = "Your API HASH"
def main():
session = SessionManager.from_tdata_folder(Path("TDATA/tdata"))
res = session.to_pyrogram_string()
print(res)
if __name__ == "__main__":
main()
```
### How it works
> An authorization session consists of an authorization key and some additional data required to connect. The module
> simply extracts this data and creates an instance of TelegramSession based on it, the methods of which are convenient to
> use to convert to the format you need.
Raw data
{
"_id": null,
"home_page": "https://github.com/nazar220160/TGConvertor",
"name": "TGConvertor",
"maintainer": "",
"docs_url": null,
"requires_python": "",
"maintainer_email": "",
"keywords": "",
"author": "nazar220160",
"author_email": "nazar.fedorowych@gmail.com",
"download_url": "https://files.pythonhosted.org/packages/66/06/c318cb4bebaefcc361bfce9eeab5ba9ca94a763f6f9441ca09474e5f5d4a/TGConvertor-0.0.8.tar.gz",
"platform": null,
"description": "<img src=\"https://cdn4.iconfinder.com/data/icons/social-media-and-logos-12/32/Logo_telegram_Airplane_Air_plane_paper_airplane-33-256.png\" align=\"right\" width=\"131\" />\n\n# TGConvertor\n\n\n\n\nThis module is small util for easy converting Telegram sessions to various formats (Telethon, Pyrogram, Tdata)\n<hr/>\n\n## Installation\n\n```\n$ pip install TGConvertor\n```\n\n## Quickstart\n\n```python\nfrom TGConvertor.manager.manager import SessionManager\nfrom pathlib import Path\n\nAPI_ID = 123\nAPI_HASH = \"Your API HASH\"\n\n\ndef main():\n session = SessionManager.from_tdata_folder(Path(\"TDATA/tdata\"))\n res = session.to_pyrogram_string()\n print(res)\n\n\nif __name__ == \"__main__\":\n main()\n```\n\n### How it works\n\n> An authorization session consists of an authorization key and some additional data required to connect. The module\n> simply extracts this data and creates an instance of TelegramSession based on it, the methods of which are convenient to\n> use to convert to the format you need.\n",
"bugtrack_url": null,
"license": "",
"summary": "This module is small util for easy converting Telegram sessions to various formats",
"version": "0.0.8",
"project_urls": {
"Homepage": "https://github.com/nazar220160/TGConvertor"
},
"split_keywords": [],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "2867add4088b013db5dbeb841f85ce393ebbe18a2e4dfb76351785b52a1df2dc",
"md5": "d8493f524db53ae417e1a69eced170f6",
"sha256": "1fb306b0f6f88ee5d5ae36208a76b21652339762255765360fd1fe4bf4bffd3c"
},
"downloads": -1,
"filename": "TGConvertor-0.0.8-py3-none-any.whl",
"has_sig": false,
"md5_digest": "d8493f524db53ae417e1a69eced170f6",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": null,
"size": 10359,
"upload_time": "2024-01-23T04:33:30",
"upload_time_iso_8601": "2024-01-23T04:33:30.608722Z",
"url": "https://files.pythonhosted.org/packages/28/67/add4088b013db5dbeb841f85ce393ebbe18a2e4dfb76351785b52a1df2dc/TGConvertor-0.0.8-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "6606c318cb4bebaefcc361bfce9eeab5ba9ca94a763f6f9441ca09474e5f5d4a",
"md5": "d4db2cd7fd78e147bde671253b7fd276",
"sha256": "2aaea5473c3118915e623fb47a3bf925cc1b90cb09a26226e3ed8132c566eef5"
},
"downloads": -1,
"filename": "TGConvertor-0.0.8.tar.gz",
"has_sig": false,
"md5_digest": "d4db2cd7fd78e147bde671253b7fd276",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 8103,
"upload_time": "2024-01-23T04:33:32",
"upload_time_iso_8601": "2024-01-23T04:33:32.369383Z",
"url": "https://files.pythonhosted.org/packages/66/06/c318cb4bebaefcc361bfce9eeab5ba9ca94a763f6f9441ca09474e5f5d4a/TGConvertor-0.0.8.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-01-23 04:33:32",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "nazar220160",
"github_project": "TGConvertor",
"travis_ci": false,
"coveralls": false,
"github_actions": false,
"lcname": "tgconvertor"
}